function yI(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 u of o.addedNodes)u.tagName==="LINK"&&u.rel==="modulepreload"&&n(u)}).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 Hl=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Ue(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var ih={exports:{}},hs={},ah={exports:{}},Ie={};/** * @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 aS;function gI(){if(aS)return Ie;aS=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),o=Symbol.for("react.provider"),u=Symbol.for("react.context"),l=Symbol.for("react.forward_ref"),f=Symbol.for("react.suspense"),d=Symbol.for("react.memo"),v=Symbol.for("react.lazy"),p=Symbol.iterator;function m(L){return L===null||typeof L!="object"?null:(L=p&&L[p]||L["@@iterator"],typeof L=="function"?L:null)}var b={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},O=Object.assign,x={};function g(L,U,oe){this.props=L,this.context=U,this.refs=x,this.updater=oe||b}g.prototype.isReactComponent={},g.prototype.setState=function(L,U){if(typeof L!="object"&&typeof L!="function"&&L!=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,L,U,"setState")},g.prototype.forceUpdate=function(L){this.updater.enqueueForceUpdate(this,L,"forceUpdate")};function E(){}E.prototype=g.prototype;function A(L,U,oe){this.props=L,this.context=U,this.refs=x,this.updater=oe||b}var T=A.prototype=new E;T.constructor=A,O(T,g.prototype),T.isPureReactComponent=!0;var P=Array.isArray,_=Object.prototype.hasOwnProperty,j={current:null},N={key:!0,ref:!0,__self:!0,__source:!0};function R(L,U,oe){var ce,me={},Pe=null,De=null;if(U!=null)for(ce in U.ref!==void 0&&(De=U.ref),U.key!==void 0&&(Pe=""+U.key),U)_.call(U,ce)&&!N.hasOwnProperty(ce)&&(me[ce]=U[ce]);var Ae=arguments.length-2;if(Ae===1)me.children=oe;else if(1>>1,U=H[L];if(0>>1;Li(me,Z))Pei(De,me)?(H[L]=De,H[Pe]=Z,L=Pe):(H[L]=me,H[ce]=Z,L=ce);else if(Pei(De,Z))H[L]=De,H[Pe]=Z,L=Pe;else break e}}return ee}function i(H,ee){var Z=H.sortIndex-ee.sortIndex;return Z!==0?Z:H.id-ee.id}if(typeof performance=="object"&&typeof performance.now=="function"){var o=performance;e.unstable_now=function(){return o.now()}}else{var u=Date,l=u.now();e.unstable_now=function(){return u.now()-l}}var f=[],d=[],v=1,p=null,m=3,b=!1,O=!1,x=!1,g=typeof setTimeout=="function"?setTimeout:null,E=typeof clearTimeout=="function"?clearTimeout:null,A=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function T(H){for(var ee=r(d);ee!==null;){if(ee.callback===null)n(d);else if(ee.startTime<=H)n(d),ee.sortIndex=ee.expirationTime,t(f,ee);else break;ee=r(d)}}function P(H){if(x=!1,T(H),!O)if(r(f)!==null)O=!0,Y(_);else{var ee=r(d);ee!==null&&J(P,ee.startTime-H)}}function _(H,ee){O=!1,x&&(x=!1,E(R),R=-1),b=!0;var Z=m;try{for(T(ee),p=r(f);p!==null&&(!(p.expirationTime>ee)||H&&!B());){var L=p.callback;if(typeof L=="function"){p.callback=null,m=p.priorityLevel;var U=L(p.expirationTime<=ee);ee=e.unstable_now(),typeof U=="function"?p.callback=U:p===r(f)&&n(f),T(ee)}else n(f);p=r(f)}if(p!==null)var oe=!0;else{var ce=r(d);ce!==null&&J(P,ce.startTime-ee),oe=!1}return oe}finally{p=null,m=Z,b=!1}}var j=!1,N=null,R=-1,D=5,W=-1;function B(){return!(e.unstable_now()-WH||125L?(H.sortIndex=Z,t(d,H),r(f)===null&&H===r(d)&&(x?(E(R),R=-1):x=!0,J(P,Z-L))):(H.sortIndex=U,t(f,H),O||b||(O=!0,Y(_))),H},e.unstable_shouldYield=B,e.unstable_wrapCallback=function(H){var ee=m;return function(){var Z=m;m=ee;try{return H.apply(this,arguments)}finally{m=Z}}}})(uh)),uh}var cS;function OI(){return cS||(cS=1,sh.exports=SI()),sh.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 fS;function _I(){if(fS)return Yt;fS=1;var e=Q0(),t=OI();function r(a){for(var s="https://reactjs.org/docs/error-decoder.html?invariant="+a,c=1;c"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),f=Object.prototype.hasOwnProperty,d=/^[: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]*$/,v={},p={};function m(a){return f.call(p,a)?!0:f.call(v,a)?!1:d.test(a)?p[a]=!0:(v[a]=!0,!1)}function b(a,s,c,h){if(c!==null&&c.type===0)return!1;switch(typeof s){case"function":case"symbol":return!0;case"boolean":return h?!1:c!==null?!c.acceptsBooleans:(a=a.toLowerCase().slice(0,5),a!=="data-"&&a!=="aria-");default:return!1}}function O(a,s,c,h){if(s===null||typeof s>"u"||b(a,s,c,h))return!0;if(h)return!1;if(c!==null)switch(c.type){case 3:return!s;case 4:return s===!1;case 5:return isNaN(s);case 6:return isNaN(s)||1>s}return!1}function x(a,s,c,h,y,S,k){this.acceptsBooleans=s===2||s===3||s===4,this.attributeName=h,this.attributeNamespace=y,this.mustUseProperty=c,this.propertyName=a,this.type=s,this.sanitizeURL=S,this.removeEmptyString=k}var g={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(a){g[a]=new x(a,0,!1,a,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(a){var s=a[0];g[s]=new x(s,1,!1,a[1],null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(function(a){g[a]=new x(a,2,!1,a.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(a){g[a]=new x(a,2,!1,a,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(a){g[a]=new x(a,3,!1,a.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(function(a){g[a]=new x(a,3,!0,a,null,!1,!1)}),["capture","download"].forEach(function(a){g[a]=new x(a,4,!1,a,null,!1,!1)}),["cols","rows","size","span"].forEach(function(a){g[a]=new x(a,6,!1,a,null,!1,!1)}),["rowSpan","start"].forEach(function(a){g[a]=new x(a,5,!1,a.toLowerCase(),null,!1,!1)});var E=/[\-:]([a-z])/g;function A(a){return a[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(a){var s=a.replace(E,A);g[s]=new x(s,1,!1,a,null,!1,!1)}),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(a){var s=a.replace(E,A);g[s]=new x(s,1,!1,a,"http://www.w3.org/1999/xlink",!1,!1)}),["xml:base","xml:lang","xml:space"].forEach(function(a){var s=a.replace(E,A);g[s]=new x(s,1,!1,a,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(function(a){g[a]=new x(a,1,!1,a.toLowerCase(),null,!1,!1)}),g.xlinkHref=new x("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(function(a){g[a]=new x(a,1,!1,a.toLowerCase(),null,!0,!0)});function T(a,s,c,h){var y=g.hasOwnProperty(s)?g[s]:null;(y!==null?y.type!==0:h||!(2$||y[k]!==S[$]){var F=` `+y[k].replace(" at new "," at ");return a.displayName&&F.includes("")&&(F=F.replace("",a.displayName)),F}while(1<=k&&0<=$);break}}}finally{oe=!1,Error.prepareStackTrace=c}return(a=a?a.displayName||a.name:"")?U(a):""}function me(a){switch(a.tag){case 5:return U(a.type);case 16:return U("Lazy");case 13:return U("Suspense");case 19:return U("SuspenseList");case 0:case 2:case 15:return a=ce(a.type,!1),a;case 11:return a=ce(a.type.render,!1),a;case 1:return a=ce(a.type,!0),a;default:return""}}function Pe(a){if(a==null)return null;if(typeof a=="function")return a.displayName||a.name||null;if(typeof a=="string")return a;switch(a){case N:return"Fragment";case j:return"Portal";case D:return"Profiler";case R:return"StrictMode";case z:return"Suspense";case G:return"SuspenseList"}if(typeof a=="object")switch(a.$$typeof){case B:return(a.displayName||"Context")+".Consumer";case W:return(a._context.displayName||"Context")+".Provider";case M:var s=a.render;return a=a.displayName,a||(a=s.displayName||s.name||"",a=a!==""?"ForwardRef("+a+")":"ForwardRef"),a;case V:return s=a.displayName||null,s!==null?s:Pe(a.type)||"Memo";case Y:s=a._payload,a=a._init;try{return Pe(a(s))}catch{}}return null}function De(a){var s=a.type;switch(a.tag){case 24:return"Cache";case 9:return(s.displayName||"Context")+".Consumer";case 10:return(s._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return a=s.render,a=a.displayName||a.name||"",s.displayName||(a!==""?"ForwardRef("+a+")":"ForwardRef");case 7:return"Fragment";case 5:return s;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return Pe(s);case 8:return s===R?"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 s=="function")return s.displayName||s.name||null;if(typeof s=="string")return s}return null}function Ae(a){switch(typeof a){case"boolean":case"number":case"string":case"undefined":return a;case"object":return a;default:return""}}function ae(a){var s=a.type;return(a=a.nodeName)&&a.toLowerCase()==="input"&&(s==="checkbox"||s==="radio")}function ge(a){var s=ae(a)?"checked":"value",c=Object.getOwnPropertyDescriptor(a.constructor.prototype,s),h=""+a[s];if(!a.hasOwnProperty(s)&&typeof c<"u"&&typeof c.get=="function"&&typeof c.set=="function"){var y=c.get,S=c.set;return Object.defineProperty(a,s,{configurable:!0,get:function(){return y.call(this)},set:function(k){h=""+k,S.call(this,k)}}),Object.defineProperty(a,s,{enumerable:c.enumerable}),{getValue:function(){return h},setValue:function(k){h=""+k},stopTracking:function(){a._valueTracker=null,delete a[s]}}}}function Te(a){a._valueTracker||(a._valueTracker=ge(a))}function ne(a){if(!a)return!1;var s=a._valueTracker;if(!s)return!0;var c=s.getValue(),h="";return a&&(h=ae(a)?a.checked?"true":"false":a.value),a=h,a!==c?(s.setValue(a),!0):!1}function We(a){if(a=a||(typeof document<"u"?document:void 0),typeof a>"u")return null;try{return a.activeElement||a.body}catch{return a.body}}function Ne(a,s){var c=s.checked;return Z({},s,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:c??a._wrapperState.initialChecked})}function Ce(a,s){var c=s.defaultValue==null?"":s.defaultValue,h=s.checked!=null?s.checked:s.defaultChecked;c=Ae(s.value!=null?s.value:c),a._wrapperState={initialChecked:h,initialValue:c,controlled:s.type==="checkbox"||s.type==="radio"?s.checked!=null:s.value!=null}}function Je(a,s){s=s.checked,s!=null&&T(a,"checked",s,!1)}function st(a,s){Je(a,s);var c=Ae(s.value),h=s.type;if(c!=null)h==="number"?(c===0&&a.value===""||a.value!=c)&&(a.value=""+c):a.value!==""+c&&(a.value=""+c);else if(h==="submit"||h==="reset"){a.removeAttribute("value");return}s.hasOwnProperty("value")?Wr(a,s.type,c):s.hasOwnProperty("defaultValue")&&Wr(a,s.type,Ae(s.defaultValue)),s.checked==null&&s.defaultChecked!=null&&(a.defaultChecked=!!s.defaultChecked)}function Er(a,s,c){if(s.hasOwnProperty("value")||s.hasOwnProperty("defaultValue")){var h=s.type;if(!(h!=="submit"&&h!=="reset"||s.value!==void 0&&s.value!==null))return;s=""+a._wrapperState.initialValue,c||s===a.value||(a.value=s),a.defaultValue=s}c=a.name,c!==""&&(a.name=""),a.defaultChecked=!!a._wrapperState.initialChecked,c!==""&&(a.name=c)}function Wr(a,s,c){(s!=="number"||We(a.ownerDocument)!==a)&&(c==null?a.defaultValue=""+a._wrapperState.initialValue:a.defaultValue!==""+c&&(a.defaultValue=""+c))}var Hr=Array.isArray;function Wt(a,s,c,h){if(a=a.options,s){s={};for(var y=0;y"+s.valueOf().toString()+"",s=Du.firstChild;a.firstChild;)a.removeChild(a.firstChild);for(;s.firstChild;)a.appendChild(s.firstChild)}});function Co(a,s){if(s){var c=a.firstChild;if(c&&c===a.lastChild&&c.nodeType===3){c.nodeValue=s;return}}a.textContent=s}var ko={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},wM=["Webkit","ms","Moz","O"];Object.keys(ko).forEach(function(a){wM.forEach(function(s){s=s+a.charAt(0).toUpperCase()+a.substring(1),ko[s]=ko[a]})});function xx(a,s,c){return s==null||typeof s=="boolean"||s===""?"":c||typeof s!="number"||s===0||ko.hasOwnProperty(a)&&ko[a]?(""+s).trim():s+"px"}function wx(a,s){a=a.style;for(var c in s)if(s.hasOwnProperty(c)){var h=c.indexOf("--")===0,y=xx(c,s[c],h);c==="float"&&(c="cssFloat"),h?a.setProperty(c,y):a[c]=y}}var SM=Z({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 md(a,s){if(s){if(SM[a]&&(s.children!=null||s.dangerouslySetInnerHTML!=null))throw Error(r(137,a));if(s.dangerouslySetInnerHTML!=null){if(s.children!=null)throw Error(r(60));if(typeof s.dangerouslySetInnerHTML!="object"||!("__html"in s.dangerouslySetInnerHTML))throw Error(r(61))}if(s.style!=null&&typeof s.style!="object")throw Error(r(62))}}function yd(a,s){if(a.indexOf("-")===-1)return typeof s.is=="string";switch(a){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var gd=null;function bd(a){return a=a.target||a.srcElement||window,a.correspondingUseElement&&(a=a.correspondingUseElement),a.nodeType===3?a.parentNode:a}var xd=null,na=null,ia=null;function Sx(a){if(a=Jo(a)){if(typeof xd!="function")throw Error(r(280));var s=a.stateNode;s&&(s=ol(s),xd(a.stateNode,a.type,s))}}function Ox(a){na?ia?ia.push(a):ia=[a]:na=a}function _x(){if(na){var a=na,s=ia;if(ia=na=null,Sx(a),s)for(a=0;a>>=0,a===0?32:31-(RM(a)/MM|0)|0}var zu=64,Uu=4194304;function $o(a){switch(a&-a){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64: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 a&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return a&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return a}}function Wu(a,s){var c=a.pendingLanes;if(c===0)return 0;var h=0,y=a.suspendedLanes,S=a.pingedLanes,k=c&268435455;if(k!==0){var $=k&~y;$!==0?h=$o($):(S&=k,S!==0&&(h=$o(S)))}else k=c&~y,k!==0?h=$o(k):S!==0&&(h=$o(S));if(h===0)return 0;if(s!==0&&s!==h&&(s&y)===0&&(y=h&-h,S=s&-s,y>=S||y===16&&(S&4194240)!==0))return s;if((h&4)!==0&&(h|=c&16),s=a.entangledLanes,s!==0)for(a=a.entanglements,s&=h;0c;c++)s.push(a);return s}function Io(a,s,c){a.pendingLanes|=s,s!==536870912&&(a.suspendedLanes=0,a.pingedLanes=0),a=a.eventTimes,s=31-Ar(s),a[s]=c}function LM(a,s){var c=a.pendingLanes&~s;a.pendingLanes=s,a.suspendedLanes=0,a.pingedLanes=0,a.expiredLanes&=s,a.mutableReadLanes&=s,a.entangledLanes&=s,s=a.entanglements;var h=a.eventTimes;for(a=a.expirationTimes;0=Wo),Zx=" ",Jx=!1;function ew(a,s){switch(a){case"keyup":return d$.indexOf(s.keyCode)!==-1;case"keydown":return s.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function tw(a){return a=a.detail,typeof a=="object"&&"data"in a?a.data:null}var sa=!1;function h$(a,s){switch(a){case"compositionend":return tw(s);case"keypress":return s.which!==32?null:(Jx=!0,Zx);case"textInput":return a=s.data,a===Zx&&Jx?null:a;default:return null}}function v$(a,s){if(sa)return a==="compositionend"||!Ld&&ew(a,s)?(a=Kx(),Xu=Nd=Fn=null,sa=!1,a):null;switch(a){case"paste":return null;case"keypress":if(!(s.ctrlKey||s.altKey||s.metaKey)||s.ctrlKey&&s.altKey){if(s.char&&1=s)return{node:c,offset:s-a};a=h}e:{for(;c;){if(c.nextSibling){c=c.nextSibling;break e}c=c.parentNode}c=void 0}c=uw(c)}}function cw(a,s){return a&&s?a===s?!0:a&&a.nodeType===3?!1:s&&s.nodeType===3?cw(a,s.parentNode):"contains"in a?a.contains(s):a.compareDocumentPosition?!!(a.compareDocumentPosition(s)&16):!1:!1}function fw(){for(var a=window,s=We();s instanceof a.HTMLIFrameElement;){try{var c=typeof s.contentWindow.location.href=="string"}catch{c=!1}if(c)a=s.contentWindow;else break;s=We(a.document)}return s}function qd(a){var s=a&&a.nodeName&&a.nodeName.toLowerCase();return s&&(s==="input"&&(a.type==="text"||a.type==="search"||a.type==="tel"||a.type==="url"||a.type==="password")||s==="textarea"||a.contentEditable==="true")}function _$(a){var s=fw(),c=a.focusedElem,h=a.selectionRange;if(s!==c&&c&&c.ownerDocument&&cw(c.ownerDocument.documentElement,c)){if(h!==null&&qd(c)){if(s=h.start,a=h.end,a===void 0&&(a=s),"selectionStart"in c)c.selectionStart=s,c.selectionEnd=Math.min(a,c.value.length);else if(a=(s=c.ownerDocument||document)&&s.defaultView||window,a.getSelection){a=a.getSelection();var y=c.textContent.length,S=Math.min(h.start,y);h=h.end===void 0?S:Math.min(h.end,y),!a.extend&&S>h&&(y=h,h=S,S=y),y=lw(c,S);var k=lw(c,h);y&&k&&(a.rangeCount!==1||a.anchorNode!==y.node||a.anchorOffset!==y.offset||a.focusNode!==k.node||a.focusOffset!==k.offset)&&(s=s.createRange(),s.setStart(y.node,y.offset),a.removeAllRanges(),S>h?(a.addRange(s),a.extend(k.node,k.offset)):(s.setEnd(k.node,k.offset),a.addRange(s)))}}for(s=[],a=c;a=a.parentNode;)a.nodeType===1&&s.push({element:a,left:a.scrollLeft,top:a.scrollTop});for(typeof c.focus=="function"&&c.focus(),c=0;c=document.documentMode,ua=null,zd=null,Go=null,Ud=!1;function dw(a,s,c){var h=c.window===c?c.document:c.nodeType===9?c:c.ownerDocument;Ud||ua==null||ua!==We(h)||(h=ua,"selectionStart"in h&&qd(h)?h={start:h.selectionStart,end:h.selectionEnd}:(h=(h.ownerDocument&&h.ownerDocument.defaultView||window).getSelection(),h={anchorNode:h.anchorNode,anchorOffset:h.anchorOffset,focusNode:h.focusNode,focusOffset:h.focusOffset}),Go&&Vo(Go,h)||(Go=h,h=nl(zd,"onSelect"),0pa||(a.current=tp[pa],tp[pa]=null,pa--)}function Xe(a,s){pa++,tp[pa]=a.current,a.current=s}var Wn={},Nt=Un(Wn),Ht=Un(!1),mi=Wn;function ha(a,s){var c=a.type.contextTypes;if(!c)return Wn;var h=a.stateNode;if(h&&h.__reactInternalMemoizedUnmaskedChildContext===s)return h.__reactInternalMemoizedMaskedChildContext;var y={},S;for(S in c)y[S]=s[S];return h&&(a=a.stateNode,a.__reactInternalMemoizedUnmaskedChildContext=s,a.__reactInternalMemoizedMaskedChildContext=y),y}function Kt(a){return a=a.childContextTypes,a!=null}function sl(){tt(Ht),tt(Nt)}function jw(a,s,c){if(Nt.current!==Wn)throw Error(r(168));Xe(Nt,s),Xe(Ht,c)}function Aw(a,s,c){var h=a.stateNode;if(s=s.childContextTypes,typeof h.getChildContext!="function")return c;h=h.getChildContext();for(var y in h)if(!(y in s))throw Error(r(108,De(a)||"Unknown",y));return Z({},c,h)}function ul(a){return a=(a=a.stateNode)&&a.__reactInternalMemoizedMergedChildContext||Wn,mi=Nt.current,Xe(Nt,a),Xe(Ht,Ht.current),!0}function Tw(a,s,c){var h=a.stateNode;if(!h)throw Error(r(169));c?(a=Aw(a,s,mi),h.__reactInternalMemoizedMergedChildContext=a,tt(Ht),tt(Nt),Xe(Nt,a)):tt(Ht),Xe(Ht,c)}var un=null,ll=!1,rp=!1;function Cw(a){un===null?un=[a]:un.push(a)}function I$(a){ll=!0,Cw(a)}function Hn(){if(!rp&&un!==null){rp=!0;var a=0,s=Ke;try{var c=un;for(Ke=1;a>=k,y-=k,ln=1<<32-Ar(s)+y|c<Ee?(Pt=we,we=null):Pt=we.sibling;var Fe=re(K,we,X[Ee],ue);if(Fe===null){we===null&&(we=Pt);break}a&&we&&Fe.alternate===null&&s(K,we),q=S(Fe,q,Ee),xe===null?ye=Fe:xe.sibling=Fe,xe=Fe,we=Pt}if(Ee===X.length)return c(K,we),nt&&gi(K,Ee),ye;if(we===null){for(;EeEe?(Pt=we,we=null):Pt=we.sibling;var ei=re(K,we,Fe.value,ue);if(ei===null){we===null&&(we=Pt);break}a&&we&&ei.alternate===null&&s(K,we),q=S(ei,q,Ee),xe===null?ye=ei:xe.sibling=ei,xe=ei,we=Pt}if(Fe.done)return c(K,we),nt&&gi(K,Ee),ye;if(we===null){for(;!Fe.done;Ee++,Fe=X.next())Fe=se(K,Fe.value,ue),Fe!==null&&(q=S(Fe,q,Ee),xe===null?ye=Fe:xe.sibling=Fe,xe=Fe);return nt&&gi(K,Ee),ye}for(we=h(K,we);!Fe.done;Ee++,Fe=X.next())Fe=fe(we,K,Ee,Fe.value,ue),Fe!==null&&(a&&Fe.alternate!==null&&we.delete(Fe.key===null?Ee:Fe.key),q=S(Fe,q,Ee),xe===null?ye=Fe:xe.sibling=Fe,xe=Fe);return a&&we.forEach(function(mI){return s(K,mI)}),nt&&gi(K,Ee),ye}function dt(K,q,X,ue){if(typeof X=="object"&&X!==null&&X.type===N&&X.key===null&&(X=X.props.children),typeof X=="object"&&X!==null){switch(X.$$typeof){case _:e:{for(var ye=X.key,xe=q;xe!==null;){if(xe.key===ye){if(ye=X.type,ye===N){if(xe.tag===7){c(K,xe.sibling),q=y(xe,X.props.children),q.return=K,K=q;break e}}else if(xe.elementType===ye||typeof ye=="object"&&ye!==null&&ye.$$typeof===Y&&Iw(ye)===xe.type){c(K,xe.sibling),q=y(xe,X.props),q.ref=es(K,xe,X),q.return=K,K=q;break e}c(K,xe);break}else s(K,xe);xe=xe.sibling}X.type===N?(q=Ei(X.props.children,K.mode,ue,X.key),q.return=K,K=q):(ue=Dl(X.type,X.key,X.props,null,K.mode,ue),ue.ref=es(K,q,X),ue.return=K,K=ue)}return k(K);case j:e:{for(xe=X.key;q!==null;){if(q.key===xe)if(q.tag===4&&q.stateNode.containerInfo===X.containerInfo&&q.stateNode.implementation===X.implementation){c(K,q.sibling),q=y(q,X.children||[]),q.return=K,K=q;break e}else{c(K,q);break}else s(K,q);q=q.sibling}q=Jp(X,K.mode,ue),q.return=K,K=q}return k(K);case Y:return xe=X._init,dt(K,q,xe(X._payload),ue)}if(Hr(X))return he(K,q,X,ue);if(ee(X))return ve(K,q,X,ue);pl(K,X)}return typeof X=="string"&&X!==""||typeof X=="number"?(X=""+X,q!==null&&q.tag===6?(c(K,q.sibling),q=y(q,X),q.return=K,K=q):(c(K,q),q=Zp(X,K.mode,ue),q.return=K,K=q),k(K)):c(K,q)}return dt}var ga=Dw(!0),Lw=Dw(!1),hl=Un(null),vl=null,ba=null,up=null;function lp(){up=ba=vl=null}function cp(a){var s=hl.current;tt(hl),a._currentValue=s}function fp(a,s,c){for(;a!==null;){var h=a.alternate;if((a.childLanes&s)!==s?(a.childLanes|=s,h!==null&&(h.childLanes|=s)):h!==null&&(h.childLanes&s)!==s&&(h.childLanes|=s),a===c)break;a=a.return}}function xa(a,s){vl=a,up=ba=null,a=a.dependencies,a!==null&&a.firstContext!==null&&((a.lanes&s)!==0&&(Vt=!0),a.firstContext=null)}function pr(a){var s=a._currentValue;if(up!==a)if(a={context:a,memoizedValue:s,next:null},ba===null){if(vl===null)throw Error(r(308));ba=a,vl.dependencies={lanes:0,firstContext:a}}else ba=ba.next=a;return s}var bi=null;function dp(a){bi===null?bi=[a]:bi.push(a)}function Bw(a,s,c,h){var y=s.interleaved;return y===null?(c.next=c,dp(s)):(c.next=y.next,y.next=c),s.interleaved=c,fn(a,h)}function fn(a,s){a.lanes|=s;var c=a.alternate;for(c!==null&&(c.lanes|=s),c=a,a=a.return;a!==null;)a.childLanes|=s,c=a.alternate,c!==null&&(c.childLanes|=s),c=a,a=a.return;return c.tag===3?c.stateNode:null}var Kn=!1;function pp(a){a.updateQueue={baseState:a.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function Fw(a,s){a=a.updateQueue,s.updateQueue===a&&(s.updateQueue={baseState:a.baseState,firstBaseUpdate:a.firstBaseUpdate,lastBaseUpdate:a.lastBaseUpdate,shared:a.shared,effects:a.effects})}function dn(a,s){return{eventTime:a,lane:s,tag:0,payload:null,callback:null,next:null}}function Vn(a,s,c){var h=a.updateQueue;if(h===null)return null;if(h=h.shared,(Be&2)!==0){var y=h.pending;return y===null?s.next=s:(s.next=y.next,y.next=s),h.pending=s,fn(a,c)}return y=h.interleaved,y===null?(s.next=s,dp(h)):(s.next=y.next,y.next=s),h.interleaved=s,fn(a,c)}function ml(a,s,c){if(s=s.updateQueue,s!==null&&(s=s.shared,(c&4194240)!==0)){var h=s.lanes;h&=a.pendingLanes,c|=h,s.lanes=c,jd(a,c)}}function qw(a,s){var c=a.updateQueue,h=a.alternate;if(h!==null&&(h=h.updateQueue,c===h)){var y=null,S=null;if(c=c.firstBaseUpdate,c!==null){do{var k={eventTime:c.eventTime,lane:c.lane,tag:c.tag,payload:c.payload,callback:c.callback,next:null};S===null?y=S=k:S=S.next=k,c=c.next}while(c!==null);S===null?y=S=s:S=S.next=s}else y=S=s;c={baseState:h.baseState,firstBaseUpdate:y,lastBaseUpdate:S,shared:h.shared,effects:h.effects},a.updateQueue=c;return}a=c.lastBaseUpdate,a===null?c.firstBaseUpdate=s:a.next=s,c.lastBaseUpdate=s}function yl(a,s,c,h){var y=a.updateQueue;Kn=!1;var S=y.firstBaseUpdate,k=y.lastBaseUpdate,$=y.shared.pending;if($!==null){y.shared.pending=null;var F=$,Q=F.next;F.next=null,k===null?S=Q:k.next=Q,k=F;var ie=a.alternate;ie!==null&&(ie=ie.updateQueue,$=ie.lastBaseUpdate,$!==k&&($===null?ie.firstBaseUpdate=Q:$.next=Q,ie.lastBaseUpdate=F))}if(S!==null){var se=y.baseState;k=0,ie=Q=F=null,$=S;do{var re=$.lane,fe=$.eventTime;if((h&re)===re){ie!==null&&(ie=ie.next={eventTime:fe,lane:0,tag:$.tag,payload:$.payload,callback:$.callback,next:null});e:{var he=a,ve=$;switch(re=s,fe=c,ve.tag){case 1:if(he=ve.payload,typeof he=="function"){se=he.call(fe,se,re);break e}se=he;break e;case 3:he.flags=he.flags&-65537|128;case 0:if(he=ve.payload,re=typeof he=="function"?he.call(fe,se,re):he,re==null)break e;se=Z({},se,re);break e;case 2:Kn=!0}}$.callback!==null&&$.lane!==0&&(a.flags|=64,re=y.effects,re===null?y.effects=[$]:re.push($))}else fe={eventTime:fe,lane:re,tag:$.tag,payload:$.payload,callback:$.callback,next:null},ie===null?(Q=ie=fe,F=se):ie=ie.next=fe,k|=re;if($=$.next,$===null){if($=y.shared.pending,$===null)break;re=$,$=re.next,re.next=null,y.lastBaseUpdate=re,y.shared.pending=null}}while(!0);if(ie===null&&(F=se),y.baseState=F,y.firstBaseUpdate=Q,y.lastBaseUpdate=ie,s=y.shared.interleaved,s!==null){y=s;do k|=y.lane,y=y.next;while(y!==s)}else S===null&&(y.shared.lanes=0);Si|=k,a.lanes=k,a.memoizedState=se}}function zw(a,s,c){if(a=s.effects,s.effects=null,a!==null)for(s=0;sc?c:4,a(!0);var h=gp.transition;gp.transition={};try{a(!1),s()}finally{Ke=c,gp.transition=h}}function s1(){return hr().memoizedState}function F$(a,s,c){var h=Qn(a);if(c={lane:h,action:c,hasEagerState:!1,eagerState:null,next:null},u1(a))l1(s,c);else if(c=Bw(a,s,c,h),c!==null){var y=Ft();Mr(c,a,h,y),c1(c,s,h)}}function q$(a,s,c){var h=Qn(a),y={lane:h,action:c,hasEagerState:!1,eagerState:null,next:null};if(u1(a))l1(s,y);else{var S=a.alternate;if(a.lanes===0&&(S===null||S.lanes===0)&&(S=s.lastRenderedReducer,S!==null))try{var k=s.lastRenderedState,$=S(k,c);if(y.hasEagerState=!0,y.eagerState=$,Tr($,k)){var F=s.interleaved;F===null?(y.next=y,dp(s)):(y.next=F.next,F.next=y),s.interleaved=y;return}}catch{}finally{}c=Bw(a,s,y,h),c!==null&&(y=Ft(),Mr(c,a,h,y),c1(c,s,h))}}function u1(a){var s=a.alternate;return a===ot||s!==null&&s===ot}function l1(a,s){is=xl=!0;var c=a.pending;c===null?s.next=s:(s.next=c.next,c.next=s),a.pending=s}function c1(a,s,c){if((c&4194240)!==0){var h=s.lanes;h&=a.pendingLanes,c|=h,s.lanes=c,jd(a,c)}}var Ol={readContext:pr,useCallback:Rt,useContext:Rt,useEffect:Rt,useImperativeHandle:Rt,useInsertionEffect:Rt,useLayoutEffect:Rt,useMemo:Rt,useReducer:Rt,useRef:Rt,useState:Rt,useDebugValue:Rt,useDeferredValue:Rt,useTransition:Rt,useMutableSource:Rt,useSyncExternalStore:Rt,useId:Rt,unstable_isNewReconciler:!1},z$={readContext:pr,useCallback:function(a,s){return Xr().memoizedState=[a,s===void 0?null:s],a},useContext:pr,useEffect:Jw,useImperativeHandle:function(a,s,c){return c=c!=null?c.concat([a]):null,wl(4194308,4,r1.bind(null,s,a),c)},useLayoutEffect:function(a,s){return wl(4194308,4,a,s)},useInsertionEffect:function(a,s){return wl(4,2,a,s)},useMemo:function(a,s){var c=Xr();return s=s===void 0?null:s,a=a(),c.memoizedState=[a,s],a},useReducer:function(a,s,c){var h=Xr();return s=c!==void 0?c(s):s,h.memoizedState=h.baseState=s,a={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:a,lastRenderedState:s},h.queue=a,a=a.dispatch=F$.bind(null,ot,a),[h.memoizedState,a]},useRef:function(a){var s=Xr();return a={current:a},s.memoizedState=a},useState:Qw,useDebugValue:Pp,useDeferredValue:function(a){return Xr().memoizedState=a},useTransition:function(){var a=Qw(!1),s=a[0];return a=B$.bind(null,a[1]),Xr().memoizedState=a,[s,a]},useMutableSource:function(){},useSyncExternalStore:function(a,s,c){var h=ot,y=Xr();if(nt){if(c===void 0)throw Error(r(407));c=c()}else{if(c=s(),_t===null)throw Error(r(349));(wi&30)!==0||Kw(h,s,c)}y.memoizedState=c;var S={value:c,getSnapshot:s};return y.queue=S,Jw(Gw.bind(null,h,S,a),[a]),h.flags|=2048,ss(9,Vw.bind(null,h,S,c,s),void 0,null),c},useId:function(){var a=Xr(),s=_t.identifierPrefix;if(nt){var c=cn,h=ln;c=(h&~(1<<32-Ar(h)-1)).toString(32)+c,s=":"+s+"R"+c,c=as++,0<\/script>",a=a.removeChild(a.firstChild)):typeof h.is=="string"?a=k.createElement(c,{is:h.is}):(a=k.createElement(c),c==="select"&&(k=a,h.multiple?k.multiple=!0:h.size&&(k.size=h.size))):a=k.createElementNS(a,c),a[Vr]=s,a[Zo]=h,C1(a,s,!1,!1),s.stateNode=a;e:{switch(k=yd(c,h),c){case"dialog":et("cancel",a),et("close",a),y=h;break;case"iframe":case"object":case"embed":et("load",a),y=h;break;case"video":case"audio":for(y=0;yPa&&(s.flags|=128,h=!0,us(S,!1),s.lanes=4194304)}else{if(!h)if(a=gl(k),a!==null){if(s.flags|=128,h=!0,c=a.updateQueue,c!==null&&(s.updateQueue=c,s.flags|=4),us(S,!0),S.tail===null&&S.tailMode==="hidden"&&!k.alternate&&!nt)return Mt(s),null}else 2*ft()-S.renderingStartTime>Pa&&c!==1073741824&&(s.flags|=128,h=!0,us(S,!1),s.lanes=4194304);S.isBackwards?(k.sibling=s.child,s.child=k):(c=S.last,c!==null?c.sibling=k:s.child=k,S.last=k)}return S.tail!==null?(s=S.tail,S.rendering=s,S.tail=s.sibling,S.renderingStartTime=ft(),s.sibling=null,c=at.current,Xe(at,h?c&1|2:c&1),s):(Mt(s),null);case 22:case 23:return Xp(),h=s.memoizedState!==null,a!==null&&a.memoizedState!==null!==h&&(s.flags|=8192),h&&(s.mode&1)!==0?(nr&1073741824)!==0&&(Mt(s),s.subtreeFlags&6&&(s.flags|=8192)):Mt(s),null;case 24:return null;case 25:return null}throw Error(r(156,s.tag))}function Y$(a,s){switch(ip(s),s.tag){case 1:return Kt(s.type)&&sl(),a=s.flags,a&65536?(s.flags=a&-65537|128,s):null;case 3:return wa(),tt(Ht),tt(Nt),yp(),a=s.flags,(a&65536)!==0&&(a&128)===0?(s.flags=a&-65537|128,s):null;case 5:return vp(s),null;case 13:if(tt(at),a=s.memoizedState,a!==null&&a.dehydrated!==null){if(s.alternate===null)throw Error(r(340));ya()}return a=s.flags,a&65536?(s.flags=a&-65537|128,s):null;case 19:return tt(at),null;case 4:return wa(),null;case 10:return cp(s.type._context),null;case 22:case 23:return Xp(),null;case 24:return null;default:return null}}var jl=!1,$t=!1,Q$=typeof WeakSet=="function"?WeakSet:Set,de=null;function Oa(a,s){var c=a.ref;if(c!==null)if(typeof c=="function")try{c(null)}catch(h){ut(a,s,h)}else c.current=null}function Dp(a,s,c){try{c()}catch(h){ut(a,s,h)}}var R1=!1;function Z$(a,s){if(Xd=Vu,a=fw(),qd(a)){if("selectionStart"in a)var c={start:a.selectionStart,end:a.selectionEnd};else e:{c=(c=a.ownerDocument)&&c.defaultView||window;var h=c.getSelection&&c.getSelection();if(h&&h.rangeCount!==0){c=h.anchorNode;var y=h.anchorOffset,S=h.focusNode;h=h.focusOffset;try{c.nodeType,S.nodeType}catch{c=null;break e}var k=0,$=-1,F=-1,Q=0,ie=0,se=a,re=null;t:for(;;){for(var fe;se!==c||y!==0&&se.nodeType!==3||($=k+y),se!==S||h!==0&&se.nodeType!==3||(F=k+h),se.nodeType===3&&(k+=se.nodeValue.length),(fe=se.firstChild)!==null;)re=se,se=fe;for(;;){if(se===a)break t;if(re===c&&++Q===y&&($=k),re===S&&++ie===h&&(F=k),(fe=se.nextSibling)!==null)break;se=re,re=se.parentNode}se=fe}c=$===-1||F===-1?null:{start:$,end:F}}else c=null}c=c||{start:0,end:0}}else c=null;for(Yd={focusedElem:a,selectionRange:c},Vu=!1,de=s;de!==null;)if(s=de,a=s.child,(s.subtreeFlags&1028)!==0&&a!==null)a.return=s,de=a;else for(;de!==null;){s=de;try{var he=s.alternate;if((s.flags&1024)!==0)switch(s.tag){case 0:case 11:case 15:break;case 1:if(he!==null){var ve=he.memoizedProps,dt=he.memoizedState,K=s.stateNode,q=K.getSnapshotBeforeUpdate(s.elementType===s.type?ve:kr(s.type,ve),dt);K.__reactInternalSnapshotBeforeUpdate=q}break;case 3:var X=s.stateNode.containerInfo;X.nodeType===1?X.textContent="":X.nodeType===9&&X.documentElement&&X.removeChild(X.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(r(163))}}catch(ue){ut(s,s.return,ue)}if(a=s.sibling,a!==null){a.return=s.return,de=a;break}de=s.return}return he=R1,R1=!1,he}function ls(a,s,c){var h=s.updateQueue;if(h=h!==null?h.lastEffect:null,h!==null){var y=h=h.next;do{if((y.tag&a)===a){var S=y.destroy;y.destroy=void 0,S!==void 0&&Dp(s,c,S)}y=y.next}while(y!==h)}}function Al(a,s){if(s=s.updateQueue,s=s!==null?s.lastEffect:null,s!==null){var c=s=s.next;do{if((c.tag&a)===a){var h=c.create;c.destroy=h()}c=c.next}while(c!==s)}}function Lp(a){var s=a.ref;if(s!==null){var c=a.stateNode;switch(a.tag){case 5:a=c;break;default:a=c}typeof s=="function"?s(a):s.current=a}}function M1(a){var s=a.alternate;s!==null&&(a.alternate=null,M1(s)),a.child=null,a.deletions=null,a.sibling=null,a.tag===5&&(s=a.stateNode,s!==null&&(delete s[Vr],delete s[Zo],delete s[ep],delete s[M$],delete s[$$])),a.stateNode=null,a.return=null,a.dependencies=null,a.memoizedProps=null,a.memoizedState=null,a.pendingProps=null,a.stateNode=null,a.updateQueue=null}function $1(a){return a.tag===5||a.tag===3||a.tag===4}function I1(a){e:for(;;){for(;a.sibling===null;){if(a.return===null||$1(a.return))return null;a=a.return}for(a.sibling.return=a.return,a=a.sibling;a.tag!==5&&a.tag!==6&&a.tag!==18;){if(a.flags&2||a.child===null||a.tag===4)continue e;a.child.return=a,a=a.child}if(!(a.flags&2))return a.stateNode}}function Bp(a,s,c){var h=a.tag;if(h===5||h===6)a=a.stateNode,s?c.nodeType===8?c.parentNode.insertBefore(a,s):c.insertBefore(a,s):(c.nodeType===8?(s=c.parentNode,s.insertBefore(a,c)):(s=c,s.appendChild(a)),c=c._reactRootContainer,c!=null||s.onclick!==null||(s.onclick=al));else if(h!==4&&(a=a.child,a!==null))for(Bp(a,s,c),a=a.sibling;a!==null;)Bp(a,s,c),a=a.sibling}function Fp(a,s,c){var h=a.tag;if(h===5||h===6)a=a.stateNode,s?c.insertBefore(a,s):c.appendChild(a);else if(h!==4&&(a=a.child,a!==null))for(Fp(a,s,c),a=a.sibling;a!==null;)Fp(a,s,c),a=a.sibling}var Tt=null,Nr=!1;function Gn(a,s,c){for(c=c.child;c!==null;)D1(a,s,c),c=c.sibling}function D1(a,s,c){if(Kr&&typeof Kr.onCommitFiberUnmount=="function")try{Kr.onCommitFiberUnmount(qu,c)}catch{}switch(c.tag){case 5:$t||Oa(c,s);case 6:var h=Tt,y=Nr;Tt=null,Gn(a,s,c),Tt=h,Nr=y,Tt!==null&&(Nr?(a=Tt,c=c.stateNode,a.nodeType===8?a.parentNode.removeChild(c):a.removeChild(c)):Tt.removeChild(c.stateNode));break;case 18:Tt!==null&&(Nr?(a=Tt,c=c.stateNode,a.nodeType===8?Jd(a.parentNode,c):a.nodeType===1&&Jd(a,c),qo(a)):Jd(Tt,c.stateNode));break;case 4:h=Tt,y=Nr,Tt=c.stateNode.containerInfo,Nr=!0,Gn(a,s,c),Tt=h,Nr=y;break;case 0:case 11:case 14:case 15:if(!$t&&(h=c.updateQueue,h!==null&&(h=h.lastEffect,h!==null))){y=h=h.next;do{var S=y,k=S.destroy;S=S.tag,k!==void 0&&((S&2)!==0||(S&4)!==0)&&Dp(c,s,k),y=y.next}while(y!==h)}Gn(a,s,c);break;case 1:if(!$t&&(Oa(c,s),h=c.stateNode,typeof h.componentWillUnmount=="function"))try{h.props=c.memoizedProps,h.state=c.memoizedState,h.componentWillUnmount()}catch($){ut(c,s,$)}Gn(a,s,c);break;case 21:Gn(a,s,c);break;case 22:c.mode&1?($t=(h=$t)||c.memoizedState!==null,Gn(a,s,c),$t=h):Gn(a,s,c);break;default:Gn(a,s,c)}}function L1(a){var s=a.updateQueue;if(s!==null){a.updateQueue=null;var c=a.stateNode;c===null&&(c=a.stateNode=new Q$),s.forEach(function(h){var y=sI.bind(null,a,h);c.has(h)||(c.add(h),h.then(y,y))})}}function Rr(a,s){var c=s.deletions;if(c!==null)for(var h=0;hy&&(y=k),h&=~S}if(h=y,h=ft()-h,h=(120>h?120:480>h?480:1080>h?1080:1920>h?1920:3e3>h?3e3:4320>h?4320:1960*eI(h/1960))-h,10a?16:a,Yn===null)var h=!1;else{if(a=Yn,Yn=null,Rl=0,(Be&6)!==0)throw Error(r(331));var y=Be;for(Be|=4,de=a.current;de!==null;){var S=de,k=S.child;if((de.flags&16)!==0){var $=S.deletions;if($!==null){for(var F=0;F<$.length;F++){var Q=$[F];for(de=Q;de!==null;){var ie=de;switch(ie.tag){case 0:case 11:case 15:ls(8,ie,S)}var se=ie.child;if(se!==null)se.return=ie,de=se;else for(;de!==null;){ie=de;var re=ie.sibling,fe=ie.return;if(M1(ie),ie===Q){de=null;break}if(re!==null){re.return=fe,de=re;break}de=fe}}}var he=S.alternate;if(he!==null){var ve=he.child;if(ve!==null){he.child=null;do{var dt=ve.sibling;ve.sibling=null,ve=dt}while(ve!==null)}}de=S}}if((S.subtreeFlags&2064)!==0&&k!==null)k.return=S,de=k;else e:for(;de!==null;){if(S=de,(S.flags&2048)!==0)switch(S.tag){case 0:case 11:case 15:ls(9,S,S.return)}var K=S.sibling;if(K!==null){K.return=S.return,de=K;break e}de=S.return}}var q=a.current;for(de=q;de!==null;){k=de;var X=k.child;if((k.subtreeFlags&2064)!==0&&X!==null)X.return=k,de=X;else e:for(k=q;de!==null;){if($=de,($.flags&2048)!==0)try{switch($.tag){case 0:case 11:case 15:Al(9,$)}}catch(ye){ut($,$.return,ye)}if($===k){de=null;break e}var ue=$.sibling;if(ue!==null){ue.return=$.return,de=ue;break e}de=$.return}}if(Be=y,Hn(),Kr&&typeof Kr.onPostCommitFiberRoot=="function")try{Kr.onPostCommitFiberRoot(qu,a)}catch{}h=!0}return h}finally{Ke=c,vr.transition=s}}return!1}function Y1(a,s,c){s=Sa(c,s),s=h1(a,s,1),a=Vn(a,s,1),s=Ft(),a!==null&&(Io(a,1,s),Xt(a,s))}function ut(a,s,c){if(a.tag===3)Y1(a,a,c);else for(;s!==null;){if(s.tag===3){Y1(s,a,c);break}else if(s.tag===1){var h=s.stateNode;if(typeof s.type.getDerivedStateFromError=="function"||typeof h.componentDidCatch=="function"&&(Xn===null||!Xn.has(h))){a=Sa(c,a),a=v1(s,a,1),s=Vn(s,a,1),a=Ft(),s!==null&&(Io(s,1,a),Xt(s,a));break}}s=s.return}}function aI(a,s,c){var h=a.pingCache;h!==null&&h.delete(s),s=Ft(),a.pingedLanes|=a.suspendedLanes&c,_t===a&&(Ct&c)===c&&(yt===4||yt===3&&(Ct&130023424)===Ct&&500>ft()-Up?_i(a,0):zp|=c),Xt(a,s)}function Q1(a,s){s===0&&((a.mode&1)===0?s=1:(s=Uu,Uu<<=1,(Uu&130023424)===0&&(Uu=4194304)));var c=Ft();a=fn(a,s),a!==null&&(Io(a,s,c),Xt(a,c))}function oI(a){var s=a.memoizedState,c=0;s!==null&&(c=s.retryLane),Q1(a,c)}function sI(a,s){var c=0;switch(a.tag){case 13:var h=a.stateNode,y=a.memoizedState;y!==null&&(c=y.retryLane);break;case 19:h=a.stateNode;break;default:throw Error(r(314))}h!==null&&h.delete(s),Q1(a,c)}var Z1;Z1=function(a,s,c){if(a!==null)if(a.memoizedProps!==s.pendingProps||Ht.current)Vt=!0;else{if((a.lanes&c)===0&&(s.flags&128)===0)return Vt=!1,G$(a,s,c);Vt=(a.flags&131072)!==0}else Vt=!1,nt&&(s.flags&1048576)!==0&&kw(s,fl,s.index);switch(s.lanes=0,s.tag){case 2:var h=s.type;El(a,s),a=s.pendingProps;var y=ha(s,Nt.current);xa(s,c),y=xp(null,s,h,a,y,c);var S=wp();return s.flags|=1,typeof y=="object"&&y!==null&&typeof y.render=="function"&&y.$$typeof===void 0?(s.tag=1,s.memoizedState=null,s.updateQueue=null,Kt(h)?(S=!0,ul(s)):S=!1,s.memoizedState=y.state!==null&&y.state!==void 0?y.state:null,pp(s),y.updater=_l,s.stateNode=y,y._reactInternals=s,jp(s,h,a,c),s=kp(null,s,h,!0,S,c)):(s.tag=0,nt&&S&&np(s),Bt(null,s,y,c),s=s.child),s;case 16:h=s.elementType;e:{switch(El(a,s),a=s.pendingProps,y=h._init,h=y(h._payload),s.type=h,y=s.tag=lI(h),a=kr(h,a),y){case 0:s=Cp(null,s,h,a,c);break e;case 1:s=_1(null,s,h,a,c);break e;case 11:s=b1(null,s,h,a,c);break e;case 14:s=x1(null,s,h,kr(h.type,a),c);break e}throw Error(r(306,h,""))}return s;case 0:return h=s.type,y=s.pendingProps,y=s.elementType===h?y:kr(h,y),Cp(a,s,h,y,c);case 1:return h=s.type,y=s.pendingProps,y=s.elementType===h?y:kr(h,y),_1(a,s,h,y,c);case 3:e:{if(P1(s),a===null)throw Error(r(387));h=s.pendingProps,S=s.memoizedState,y=S.element,Fw(a,s),yl(s,h,null,c);var k=s.memoizedState;if(h=k.element,S.isDehydrated)if(S={element:h,isDehydrated:!1,cache:k.cache,pendingSuspenseBoundaries:k.pendingSuspenseBoundaries,transitions:k.transitions},s.updateQueue.baseState=S,s.memoizedState=S,s.flags&256){y=Sa(Error(r(423)),s),s=E1(a,s,h,c,y);break e}else if(h!==y){y=Sa(Error(r(424)),s),s=E1(a,s,h,c,y);break e}else for(rr=zn(s.stateNode.containerInfo.firstChild),tr=s,nt=!0,Cr=null,c=Lw(s,null,h,c),s.child=c;c;)c.flags=c.flags&-3|4096,c=c.sibling;else{if(ya(),h===y){s=pn(a,s,c);break e}Bt(a,s,h,c)}s=s.child}return s;case 5:return Uw(s),a===null&&op(s),h=s.type,y=s.pendingProps,S=a!==null?a.memoizedProps:null,k=y.children,Qd(h,y)?k=null:S!==null&&Qd(h,S)&&(s.flags|=32),O1(a,s),Bt(a,s,k,c),s.child;case 6:return a===null&&op(s),null;case 13:return j1(a,s,c);case 4:return hp(s,s.stateNode.containerInfo),h=s.pendingProps,a===null?s.child=ga(s,null,h,c):Bt(a,s,h,c),s.child;case 11:return h=s.type,y=s.pendingProps,y=s.elementType===h?y:kr(h,y),b1(a,s,h,y,c);case 7:return Bt(a,s,s.pendingProps,c),s.child;case 8:return Bt(a,s,s.pendingProps.children,c),s.child;case 12:return Bt(a,s,s.pendingProps.children,c),s.child;case 10:e:{if(h=s.type._context,y=s.pendingProps,S=s.memoizedProps,k=y.value,Xe(hl,h._currentValue),h._currentValue=k,S!==null)if(Tr(S.value,k)){if(S.children===y.children&&!Ht.current){s=pn(a,s,c);break e}}else for(S=s.child,S!==null&&(S.return=s);S!==null;){var $=S.dependencies;if($!==null){k=S.child;for(var F=$.firstContext;F!==null;){if(F.context===h){if(S.tag===1){F=dn(-1,c&-c),F.tag=2;var Q=S.updateQueue;if(Q!==null){Q=Q.shared;var ie=Q.pending;ie===null?F.next=F:(F.next=ie.next,ie.next=F),Q.pending=F}}S.lanes|=c,F=S.alternate,F!==null&&(F.lanes|=c),fp(S.return,c,s),$.lanes|=c;break}F=F.next}}else if(S.tag===10)k=S.type===s.type?null:S.child;else if(S.tag===18){if(k=S.return,k===null)throw Error(r(341));k.lanes|=c,$=k.alternate,$!==null&&($.lanes|=c),fp(k,c,s),k=S.sibling}else k=S.child;if(k!==null)k.return=S;else for(k=S;k!==null;){if(k===s){k=null;break}if(S=k.sibling,S!==null){S.return=k.return,k=S;break}k=k.return}S=k}Bt(a,s,y.children,c),s=s.child}return s;case 9:return y=s.type,h=s.pendingProps.children,xa(s,c),y=pr(y),h=h(y),s.flags|=1,Bt(a,s,h,c),s.child;case 14:return h=s.type,y=kr(h,s.pendingProps),y=kr(h.type,y),x1(a,s,h,y,c);case 15:return w1(a,s,s.type,s.pendingProps,c);case 17:return h=s.type,y=s.pendingProps,y=s.elementType===h?y:kr(h,y),El(a,s),s.tag=1,Kt(h)?(a=!0,ul(s)):a=!1,xa(s,c),d1(s,h,y),jp(s,h,y,c),kp(null,s,h,!0,a,c);case 19:return T1(a,s,c);case 22:return S1(a,s,c)}throw Error(r(156,s.tag))};function J1(a,s){return Nx(a,s)}function uI(a,s,c,h){this.tag=a,this.key=c,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=s,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=h,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function mr(a,s,c,h){return new uI(a,s,c,h)}function Qp(a){return a=a.prototype,!(!a||!a.isReactComponent)}function lI(a){if(typeof a=="function")return Qp(a)?1:0;if(a!=null){if(a=a.$$typeof,a===M)return 11;if(a===V)return 14}return 2}function Jn(a,s){var c=a.alternate;return c===null?(c=mr(a.tag,s,a.key,a.mode),c.elementType=a.elementType,c.type=a.type,c.stateNode=a.stateNode,c.alternate=a,a.alternate=c):(c.pendingProps=s,c.type=a.type,c.flags=0,c.subtreeFlags=0,c.deletions=null),c.flags=a.flags&14680064,c.childLanes=a.childLanes,c.lanes=a.lanes,c.child=a.child,c.memoizedProps=a.memoizedProps,c.memoizedState=a.memoizedState,c.updateQueue=a.updateQueue,s=a.dependencies,c.dependencies=s===null?null:{lanes:s.lanes,firstContext:s.firstContext},c.sibling=a.sibling,c.index=a.index,c.ref=a.ref,c}function Dl(a,s,c,h,y,S){var k=2;if(h=a,typeof a=="function")Qp(a)&&(k=1);else if(typeof a=="string")k=5;else e:switch(a){case N:return Ei(c.children,y,S,s);case R:k=8,y|=8;break;case D:return a=mr(12,c,s,y|2),a.elementType=D,a.lanes=S,a;case z:return a=mr(13,c,s,y),a.elementType=z,a.lanes=S,a;case G:return a=mr(19,c,s,y),a.elementType=G,a.lanes=S,a;case J:return Ll(c,y,S,s);default:if(typeof a=="object"&&a!==null)switch(a.$$typeof){case W:k=10;break e;case B:k=9;break e;case M:k=11;break e;case V:k=14;break e;case Y:k=16,h=null;break e}throw Error(r(130,a==null?a:typeof a,""))}return s=mr(k,c,s,y),s.elementType=a,s.type=h,s.lanes=S,s}function Ei(a,s,c,h){return a=mr(7,a,h,s),a.lanes=c,a}function Ll(a,s,c,h){return a=mr(22,a,h,s),a.elementType=J,a.lanes=c,a.stateNode={isHidden:!1},a}function Zp(a,s,c){return a=mr(6,a,null,s),a.lanes=c,a}function Jp(a,s,c){return s=mr(4,a.children!==null?a.children:[],a.key,s),s.lanes=c,s.stateNode={containerInfo:a.containerInfo,pendingChildren:null,implementation:a.implementation},s}function cI(a,s,c,h,y){this.tag=s,this.containerInfo=a,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=Ed(0),this.expirationTimes=Ed(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Ed(0),this.identifierPrefix=h,this.onRecoverableError=y,this.mutableSourceEagerHydrationData=null}function eh(a,s,c,h,y,S,k,$,F){return a=new cI(a,s,c,$,F),s===1?(s=1,S===!0&&(s|=8)):s=0,S=mr(3,null,null,s),a.current=S,S.stateNode=a,S.memoizedState={element:h,isDehydrated:c,cache:null,transitions:null,pendingSuspenseBoundaries:null},pp(S),a}function fI(a,s,c){var h=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(t){console.error(t)}}return e(),oh.exports=_I(),oh.exports}var pS;function PI(){if(pS)return Kl;pS=1;var e=$T();return Kl.createRoot=e.createRoot,Kl.hydrateRoot=e.hydrateRoot,Kl}var EI=PI();const jI=Ue(EI);var AI=$T();const Ma=Ue(AI);/** * @remix-run/router v1.23.2 * * 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 Is(){return Is=Object.assign?Object.assign.bind():function(e){for(var t=1;t"u")throw new Error(t)}function bf(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function CI(){return Math.random().toString(36).substr(2,8)}function vS(e,t){return{usr:e.state,key:e.key,idx:t}}function xg(e,t,r,n){return r===void 0&&(r=null),Is({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof t=="string"?Gi(t):t,{state:r,key:t&&t.key||n||CI()})}function dc(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 Gi(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 kI(e,t,r,n){n===void 0&&(n={});let{window:i=document.defaultView,v5Compat:o=!1}=n,u=i.history,l=ii.Pop,f=null,d=v();d==null&&(d=0,u.replaceState(Is({},u.state,{idx:d}),""));function v(){return(u.state||{idx:null}).idx}function p(){l=ii.Pop;let g=v(),E=g==null?null:g-d;d=g,f&&f({action:l,location:x.location,delta:E})}function m(g,E){l=ii.Push;let A=xg(x.location,g,E);r&&r(A,g),d=v()+1;let T=vS(A,d),P=x.createHref(A);try{u.pushState(T,"",P)}catch(_){if(_ instanceof DOMException&&_.name==="DataCloneError")throw _;i.location.assign(P)}o&&f&&f({action:l,location:x.location,delta:1})}function b(g,E){l=ii.Replace;let A=xg(x.location,g,E);r&&r(A,g),d=v();let T=vS(A,d),P=x.createHref(A);u.replaceState(T,"",P),o&&f&&f({action:l,location:x.location,delta:0})}function O(g){let E=i.location.origin!=="null"?i.location.origin:i.location.href,A=typeof g=="string"?g:dc(g);return A=A.replace(/ $/,"%20"),ct(E,"No window.location.(origin|href) available to create URL for href: "+A),new URL(A,E)}let x={get action(){return l},get location(){return e(i,u)},listen(g){if(f)throw new Error("A history only accepts one active listener");return i.addEventListener(hS,p),f=g,()=>{i.removeEventListener(hS,p),f=null}},createHref(g){return t(i,g)},createURL:O,encodeLocation(g){let E=O(g);return{pathname:E.pathname,search:E.search,hash:E.hash}},push:m,replace:b,go(g){return u.go(g)}};return x}var mS;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(mS||(mS={}));function NI(e,t,r){return r===void 0&&(r="/"),RI(e,t,r)}function RI(e,t,r,n){let i=typeof t=="string"?Gi(t):t,o=Wa(i.pathname||"/",r);if(o==null)return null;let u=IT(e);MI(u);let l=null;for(let f=0;l==null&&f{let f={relativePath:l===void 0?o.path||"":l,caseSensitive:o.caseSensitive===!0,childrenIndex:u,route:o};f.relativePath.startsWith("/")&&(ct(f.relativePath.startsWith(n),'Absolute route path "'+f.relativePath+'" nested under path '+('"'+n+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),f.relativePath=f.relativePath.slice(n.length));let d=oi([n,f.relativePath]),v=r.concat(f);o.children&&o.children.length>0&&(ct(o.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+d+'".')),IT(o.children,t,v,d)),!(o.path==null&&!o.index)&&t.push({path:d,score:qI(d,o.index),routesMeta:v})};return e.forEach((o,u)=>{var l;if(o.path===""||!((l=o.path)!=null&&l.includes("?")))i(o,u);else for(let f of DT(o.path))i(o,u,f)}),t}function DT(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 u=DT(n.join("/")),l=[];return l.push(...u.map(f=>f===""?o:[o,f].join("/"))),i&&l.push(...u),l.map(f=>e.startsWith("/")&&f===""?"/":f)}function MI(e){e.sort((t,r)=>t.score!==r.score?r.score-t.score:zI(t.routesMeta.map(n=>n.childrenIndex),r.routesMeta.map(n=>n.childrenIndex)))}const $I=/^:[\w-]+$/,II=3,DI=2,LI=1,BI=10,FI=-2,yS=e=>e==="*";function qI(e,t){let r=e.split("/"),n=r.length;return r.some(yS)&&(n+=FI),t&&(n+=DI),r.filter(i=>!yS(i)).reduce((i,o)=>i+($I.test(o)?II:o===""?LI:BI),n)}function zI(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 UI(e,t,r){let{routesMeta:n}=e,i={},o="/",u=[];for(let l=0;l{let{paramName:m,isOptional:b}=v;if(m==="*"){let x=l[p]||"";u=o.slice(0,o.length-x.length).replace(/(.)\/+$/,"$1")}const O=l[p];return b&&!O?d[m]=void 0:d[m]=(O||"").replace(/%2F/g,"/"),d},{}),pathname:o,pathnameBase:u,pattern:e}}function WI(e,t,r){t===void 0&&(t=!1),r===void 0&&(r=!0),bf(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,(u,l,f)=>(n.push({paramName:l,isOptional:f!=null}),f?"/?([^\\/]+)?":"/([^\\/]+)"));return e.endsWith("*")?(n.push({paramName:"*"}),i+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):r?i+="\\/*$":e!==""&&e!=="/"&&(i+="(?:(?=\\/|$))"),[new RegExp(i,t?void 0:"i"),n]}function HI(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return bf(!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 Wa(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)||"/"}const KI=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,VI=e=>KI.test(e);function GI(e,t){t===void 0&&(t="/");let{pathname:r,search:n="",hash:i=""}=typeof e=="string"?Gi(e):e,o;if(r)if(VI(r))o=r;else{if(r.includes("//")){let u=r;r=r.replace(/\/\/+/g,"/"),bf(!1,"Pathnames cannot have embedded double slashes - normalizing "+(u+" -> "+r))}r.startsWith("/")?o=gS(r.substring(1),"/"):o=gS(r,t)}else o=t;return{pathname:o,search:QI(n),hash:ZI(i)}}function gS(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 lh(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 XI(e){return e.filter((t,r)=>r===0||t.route.path&&t.route.path.length>0)}function LT(e,t){let r=XI(e);return t?r.map((n,i)=>i===r.length-1?n.pathname:n.pathnameBase):r.map(n=>n.pathnameBase)}function BT(e,t,r,n){n===void 0&&(n=!1);let i;typeof e=="string"?i=Gi(e):(i=Is({},e),ct(!i.pathname||!i.pathname.includes("?"),lh("?","pathname","search",i)),ct(!i.pathname||!i.pathname.includes("#"),lh("#","pathname","hash",i)),ct(!i.search||!i.search.includes("#"),lh("#","search","hash",i)));let o=e===""||i.pathname==="",u=o?"/":i.pathname,l;if(u==null)l=r;else{let p=t.length-1;if(!n&&u.startsWith("..")){let m=u.split("/");for(;m[0]==="..";)m.shift(),p-=1;i.pathname=m.join("/")}l=p>=0?t[p]:"/"}let f=GI(i,l),d=u&&u!=="/"&&u.endsWith("/"),v=(o||u===".")&&r.endsWith("/");return!f.pathname.endsWith("/")&&(d||v)&&(f.pathname+="/"),f}const oi=e=>e.join("/").replace(/\/\/+/g,"/"),YI=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),QI=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,ZI=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;function JI(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}const FT=["post","put","patch","delete"];new Set(FT);const e2=["get",...FT];new Set(e2);/** * React Router v6.30.3 * * 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 Ds(){return Ds=Object.assign?Object.assign.bind():function(e){for(var t=1;t{l.current=!0}),C.useCallback(function(d,v){if(v===void 0&&(v={}),!l.current)return;if(typeof d=="number"){n.go(d);return}let p=BT(d,JSON.parse(u),o,v.relative==="path");e==null&&t!=="/"&&(p.pathname=p.pathname==="/"?t:oi([t,p.pathname])),(v.replace?n.replace:n.push)(p,v.state,v)},[t,n,u,o,e])}const n2=C.createContext(null);function i2(e){let t=C.useContext(kn).outlet;return t&&C.createElement(n2.Provider,{value:e},t)}function WT(){let{matches:e}=C.useContext(kn),t=e[e.length-1];return t?t.params:{}}function Sf(e,t){let{relative:r}=t===void 0?{}:t,{future:n}=C.useContext(li),{matches:i}=C.useContext(kn),{pathname:o}=yo(),u=JSON.stringify(LT(i,n.v7_relativeSplatPath));return C.useMemo(()=>BT(e,JSON.parse(u),o,r==="path"),[e,u,o,r])}function a2(e,t){return o2(e,t)}function o2(e,t,r,n){Ou()||ct(!1);let{navigator:i}=C.useContext(li),{matches:o}=C.useContext(kn),u=o[o.length-1],l=u?u.params:{};u&&u.pathname;let f=u?u.pathnameBase:"/";u&&u.route;let d=yo(),v;if(t){var p;let g=typeof t=="string"?Gi(t):t;f==="/"||(p=g.pathname)!=null&&p.startsWith(f)||ct(!1),v=g}else v=d;let m=v.pathname||"/",b=m;if(f!=="/"){let g=f.replace(/^\//,"").split("/");b="/"+m.replace(/^\//,"").split("/").slice(g.length).join("/")}let O=NI(e,{pathname:b}),x=f2(O&&O.map(g=>Object.assign({},g,{params:Object.assign({},l,g.params),pathname:oi([f,i.encodeLocation?i.encodeLocation(g.pathname).pathname:g.pathname]),pathnameBase:g.pathnameBase==="/"?f:oi([f,i.encodeLocation?i.encodeLocation(g.pathnameBase).pathname:g.pathnameBase])})),o,r,n);return t&&x?C.createElement(wf.Provider,{value:{location:Ds({pathname:"/",search:"",hash:"",state:null,key:"default"},v),navigationType:ii.Pop}},x):x}function s2(){let e=v2(),t=JI(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)"};return C.createElement(C.Fragment,null,C.createElement("h2",null,"Unexpected Application Error!"),C.createElement("h3",{style:{fontStyle:"italic"}},t),r?C.createElement("pre",{style:i},r):null,null)}const u2=C.createElement(s2,null);class l2 extends C.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!==void 0?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!==void 0?C.createElement(kn.Provider,{value:this.props.routeContext},C.createElement(zT.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function c2(e){let{routeContext:t,match:r,children:n}=e,i=C.useContext(xf);return i&&i.static&&i.staticContext&&(r.route.errorElement||r.route.ErrorBoundary)&&(i.staticContext._deepestRenderedBoundaryId=r.route.id),C.createElement(kn.Provider,{value:t},n)}function f2(e,t,r,n){var i;if(t===void 0&&(t=[]),r===void 0&&(r=null),n===void 0&&(n=null),e==null){var o;if(!r)return null;if(r.errors)e=r.matches;else if((o=n)!=null&&o.v7_partialHydration&&t.length===0&&!r.initialized&&r.matches.length>0)e=r.matches;else return null}let u=e,l=(i=r)==null?void 0:i.errors;if(l!=null){let v=u.findIndex(p=>p.route.id&&(l==null?void 0:l[p.route.id])!==void 0);v>=0||ct(!1),u=u.slice(0,Math.min(u.length,v+1))}let f=!1,d=-1;if(r&&n&&n.v7_partialHydration)for(let v=0;v=0?u=u.slice(0,d+1):u=[u[0]];break}}}return u.reduceRight((v,p,m)=>{let b,O=!1,x=null,g=null;r&&(b=l&&p.route.id?l[p.route.id]:void 0,x=p.route.errorElement||u2,f&&(d<0&&m===0?(y2("route-fallback"),O=!0,g=null):d===m&&(O=!0,g=p.route.hydrateFallbackElement||null)));let E=t.concat(u.slice(0,m+1)),A=()=>{let T;return b?T=x:O?T=g:p.route.Component?T=C.createElement(p.route.Component,null):p.route.element?T=p.route.element:T=v,C.createElement(c2,{match:p,routeContext:{outlet:v,matches:E,isDataRoute:r!=null},children:T})};return r&&(p.route.ErrorBoundary||p.route.errorElement||m===0)?C.createElement(l2,{location:r.location,revalidation:r.revalidation,component:x,error:b,children:A(),routeContext:{outlet:null,matches:E,isDataRoute:!0}}):A()},null)}var HT=(function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e})(HT||{}),KT=(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})(KT||{});function d2(e){let t=C.useContext(xf);return t||ct(!1),t}function p2(e){let t=C.useContext(qT);return t||ct(!1),t}function h2(e){let t=C.useContext(kn);return t||ct(!1),t}function VT(e){let t=h2(),r=t.matches[t.matches.length-1];return r.route.id||ct(!1),r.route.id}function v2(){var e;let t=C.useContext(zT),r=p2(),n=VT();return t!==void 0?t:(e=r.errors)==null?void 0:e[n]}function m2(){let{router:e}=d2(HT.UseNavigateStable),t=VT(KT.UseNavigateStable),r=C.useRef(!1);return UT(()=>{r.current=!0}),C.useCallback(function(i,o){o===void 0&&(o={}),r.current&&(typeof i=="number"?e.navigate(i):e.navigate(i,Ds({fromRouteId:t},o)))},[e,t])}const bS={};function y2(e,t,r){bS[e]||(bS[e]=!0)}function g2(e,t){e==null||e.v7_startTransition,e==null||e.v7_relativeSplatPath}function b2(e){return i2(e.context)}function Ci(e){ct(!1)}function x2(e){let{basename:t="/",children:r=null,location:n,navigationType:i=ii.Pop,navigator:o,static:u=!1,future:l}=e;Ou()&&ct(!1);let f=t.replace(/^\/*/,"/"),d=C.useMemo(()=>({basename:f,navigator:o,static:u,future:Ds({v7_relativeSplatPath:!1},l)}),[f,l,o,u]);typeof n=="string"&&(n=Gi(n));let{pathname:v="/",search:p="",hash:m="",state:b=null,key:O="default"}=n,x=C.useMemo(()=>{let g=Wa(v,f);return g==null?null:{location:{pathname:g,search:p,hash:m,state:b,key:O},navigationType:i}},[f,v,p,m,b,O,i]);return x==null?null:C.createElement(li.Provider,{value:d},C.createElement(wf.Provider,{children:r,value:x}))}function w2(e){let{children:t,location:r}=e;return a2(Sg(t),r)}new Promise(()=>{});function Sg(e,t){t===void 0&&(t=[]);let r=[];return C.Children.forEach(e,(n,i)=>{if(!C.isValidElement(n))return;let o=[...t,i];if(n.type===C.Fragment){r.push.apply(r,Sg(n.props.children,o));return}n.type!==Ci&&ct(!1),!n.props.index||!n.props.children||ct(!1);let u={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&&(u.children=Sg(n.props.children,o)),r.push(u)}),r}/** * React Router DOM v6.30.3 * * 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 pc(){return pc=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&(r[i]=e[i]);return r}function S2(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function O2(e,t){return e.button===0&&(!t||t==="_self")&&!S2(e)}function Og(e){return e===void 0&&(e=""),new URLSearchParams(typeof e=="string"||Array.isArray(e)||e instanceof URLSearchParams?e:Object.keys(e).reduce((t,r)=>{let n=e[r];return t.concat(Array.isArray(n)?n.map(i=>[r,i]):[[r,n]])},[]))}function _2(e,t){let r=Og(e);return t&&t.forEach((n,i)=>{r.has(i)||t.getAll(i).forEach(o=>{r.append(i,o)})}),r}const P2=["onClick","relative","reloadDocument","replace","state","target","to","preventScrollReset","viewTransition"],E2=["aria-current","caseSensitive","className","end","style","to","viewTransition","children"],j2="6";try{window.__reactRouterVersion=j2}catch{}const A2=C.createContext({isTransitioning:!1}),T2="startTransition",xS=wI[T2];function C2(e){let{basename:t,children:r,future:n,window:i}=e,o=C.useRef();o.current==null&&(o.current=TI({window:i,v5Compat:!0}));let u=o.current,[l,f]=C.useState({action:u.action,location:u.location}),{v7_startTransition:d}=n||{},v=C.useCallback(p=>{d&&xS?xS(()=>f(p)):f(p)},[f,d]);return C.useLayoutEffect(()=>u.listen(v),[u,v]),C.useEffect(()=>g2(n),[n]),C.createElement(x2,{basename:t,children:r,location:l.location,navigationType:l.action,navigator:u,future:n})}const k2=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",N2=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,Ls=C.forwardRef(function(t,r){let{onClick:n,relative:i,reloadDocument:o,replace:u,state:l,target:f,to:d,preventScrollReset:v,viewTransition:p}=t,m=GT(t,P2),{basename:b}=C.useContext(li),O,x=!1;if(typeof d=="string"&&N2.test(d)&&(O=d,k2))try{let T=new URL(window.location.href),P=d.startsWith("//")?new URL(T.protocol+d):new URL(d),_=Wa(P.pathname,b);P.origin===T.origin&&_!=null?d=_+P.search+P.hash:x=!0}catch{}let g=t2(d,{relative:i}),E=M2(d,{replace:u,state:l,target:f,preventScrollReset:v,relative:i,viewTransition:p});function A(T){n&&n(T),T.defaultPrevented||E(T)}return C.createElement("a",pc({},m,{href:O||g,onClick:x||o?n:A,ref:r,target:f}))}),Vl=C.forwardRef(function(t,r){let{"aria-current":n="page",caseSensitive:i=!1,className:o="",end:u=!1,style:l,to:f,viewTransition:d,children:v}=t,p=GT(t,E2),m=Sf(f,{relative:p.relative}),b=yo(),O=C.useContext(qT),{navigator:x,basename:g}=C.useContext(li),E=O!=null&&I2(m)&&d===!0,A=x.encodeLocation?x.encodeLocation(m).pathname:m.pathname,T=b.pathname,P=O&&O.navigation&&O.navigation.location?O.navigation.location.pathname:null;i||(T=T.toLowerCase(),P=P?P.toLowerCase():null,A=A.toLowerCase()),P&&g&&(P=Wa(P,g)||P);const _=A!=="/"&&A.endsWith("/")?A.length-1:A.length;let j=T===A||!u&&T.startsWith(A)&&T.charAt(_)==="/",N=P!=null&&(P===A||!u&&P.startsWith(A)&&P.charAt(A.length)==="/"),R={isActive:j,isPending:N,isTransitioning:E},D=j?n:void 0,W;typeof o=="function"?W=o(R):W=[o,j?"active":null,N?"pending":null,E?"transitioning":null].filter(Boolean).join(" ");let B=typeof l=="function"?l(R):l;return C.createElement(Ls,pc({},p,{"aria-current":D,className:W,ref:r,style:B,to:f,viewTransition:d}),typeof v=="function"?v(R):v)});var _g;(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmit="useSubmit",e.UseSubmitFetcher="useSubmitFetcher",e.UseFetcher="useFetcher",e.useViewTransitionState="useViewTransitionState"})(_g||(_g={}));var wS;(function(e){e.UseFetcher="useFetcher",e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"})(wS||(wS={}));function R2(e){let t=C.useContext(xf);return t||ct(!1),t}function M2(e,t){let{target:r,replace:n,state:i,preventScrollReset:o,relative:u,viewTransition:l}=t===void 0?{}:t,f=_u(),d=yo(),v=Sf(e,{relative:u});return C.useCallback(p=>{if(O2(p,r)){p.preventDefault();let m=n!==void 0?n:dc(d)===dc(v);f(e,{replace:m,state:i,preventScrollReset:o,relative:u,viewTransition:l})}},[d,f,v,n,i,r,e,o,u,l])}function $2(e){let t=C.useRef(Og(e)),r=C.useRef(!1),n=yo(),i=C.useMemo(()=>_2(n.search,r.current?null:t.current),[n.search]),o=_u(),u=C.useCallback((l,f)=>{const d=Og(typeof l=="function"?l(i):l);r.current=!0,o("?"+d,f)},[o,i]);return[i,u]}function I2(e,t){t===void 0&&(t={});let r=C.useContext(A2);r==null&&ct(!1);let{basename:n}=R2(_g.useViewTransitionState),i=Sf(e,{relative:t.relative});if(!r.isTransitioning)return!1;let o=Wa(r.currentLocation.pathname,n)||r.currentLocation.pathname,u=Wa(r.nextLocation.pathname,n)||r.nextLocation.pathname;return wg(i.pathname,u)!=null||wg(i.pathname,o)!=null}const D2={"nav.dashboard":{fr:"Dashboard",en:"Dashboard"},"nav.sessions":{fr:"Sessions",en:"Sessions"},"nav.users":{fr:"Utilisateurs",en:"Users"},"dashboard.title":{fr:"Dashboard",en:"Dashboard"},"dashboard.totalSessions":{fr:"Sessions",en:"Sessions"},"dashboard.totalUsers":{fr:"Utilisateurs",en:"Users"},"dashboard.successRate":{fr:"Taux de réussite",en:"Success Rate"},"dashboard.avgPrecision":{fr:"Précision moy.",en:"Avg. Precision"},"dashboard.sessionsByType":{fr:"Sessions par type",en:"Sessions by Type"},"dashboard.monthlyActivity":{fr:"Activité mensuelle",en:"Monthly Activity"},"dashboard.recentSessions":{fr:"Sessions récentes",en:"Recent Sessions"},"dashboard.topPrecision":{fr:"Top Précision",en:"Top Precision"},"sessions.title":{fr:"Sessions",en:"Sessions"},"sessions.sessionType":{fr:"Type de session",en:"Session Type"},"sessions.allTypes":{fr:"Tous les types",en:"All Types"},"sessions.result":{fr:"Résultat",en:"Result"},"sessions.all":{fr:"Tous",en:"All"},"sessions.success":{fr:"Réussi",en:"Success"},"sessions.failed":{fr:"Échoué",en:"Failed"},"sessions.search":{fr:"Scénario, map, nom...",en:"Scenario, map, name..."},"sessions.noSession":{fr:"Aucune session trouvée",en:"No session found"},"session.backToSessions":{fr:"Retour aux sessions",en:"Back to Sessions"},"session.notFound":{fr:"Session non trouvée",en:"Session not found"},"session.score":{fr:"Score",en:"Score"},"session.duration":{fr:"Durée",en:"Duration"},"session.enemiesHit":{fr:"Ennemis touchés",en:"Enemies Hit"},"session.civiliansHit":{fr:"Civils touchés",en:"Civilians Hit"},"session.damageTaken":{fr:"Dégâts reçus",en:"Damage Taken"},"session.participants":{fr:"Participants",en:"Participants"},"session.objectives":{fr:"Objectifs",en:"Objectives"},"session.hitDistribution":{fr:"Répartition des impacts",en:"Hit Distribution"},"session.shotDetails":{fr:"Détail des tirs",en:"Shot Details"},"table.date":{fr:"Date",en:"Date"},"table.type":{fr:"Type",en:"Type"},"table.scenario":{fr:"Scénario",en:"Scenario"},"table.map":{fr:"Map",en:"Map"},"table.score":{fr:"Score",en:"Score"},"table.enemies":{fr:"Ennemis",en:"Enemies"},"table.civilians":{fr:"Civils",en:"Civilians"},"table.duration":{fr:"Durée",en:"Duration"},"table.result":{fr:"Résultat",en:"Result"},"table.user":{fr:"Utilisateur",en:"User"},"table.shotsFired":{fr:"Tirs effectués",en:"Shots Fired"},"table.shotsMissed":{fr:"Tirs manqués",en:"Shots Missed"},"table.enemiesHit":{fr:"Ennemis touchés",en:"Enemies Hit"},"table.civiliansHit":{fr:"Civils touchés",en:"Civilians Hit"},"table.avgPrecision":{fr:"Précision moy.",en:"Avg. Precision"},"table.reactionTime":{fr:"Temps réaction",en:"Reaction Time"},"table.hitsReceivedIA":{fr:"Tirs reçus (IA)",en:"Hits from IA"},"table.enemiesKilled":{fr:"Ennemis tués",en:"Enemies Killed"},"table.civiliansKilled":{fr:"Civils tués",en:"Civilians Killed"},"table.username":{fr:"Username",en:"Username"},"table.name":{fr:"Nom",en:"Name"},"table.avgReaction":{fr:"Réaction moy.",en:"Avg. Reaction"},"table.lastConnection":{fr:"Dernière connexion",en:"Last Connection"},"shot.index":{fr:"#",en:"#"},"shot.shooter":{fr:"Tireur",en:"Shooter"},"shot.impactType":{fr:"Type impact",en:"Impact Type"},"shot.target":{fr:"Cible",en:"Target"},"shot.boneZone":{fr:"Os/Zone",en:"Bone/Zone"},"shot.precision":{fr:"Précision",en:"Precision"},"shot.distance":{fr:"Distance",en:"Distance"},"shot.reaction":{fr:"Réaction",en:"Reaction"},"shot.killed":{fr:"Tué",en:"Killed"},"shot.time":{fr:"Temps",en:"Time"},"users.title":{fr:"Utilisateurs",en:"Users"},"users.search":{fr:"Rechercher par nom, prénom ou username...",en:"Search by name or username..."},"users.noUser":{fr:"Aucun utilisateur trouvé",en:"No user found"},"user.backToUsers":{fr:"Retour aux utilisateurs",en:"Back to Users"},"user.notFound":{fr:"Utilisateur non trouvé",en:"User not found"},"user.male":{fr:"Homme",en:"Male"},"user.female":{fr:"Femme",en:"Female"},"user.leftHanded":{fr:"Gaucher",en:"Left-handed"},"user.rightHanded":{fr:"Droitier",en:"Right-handed"},"user.height":{fr:"Taille",en:"Height"},"user.avatar":{fr:"Avatar",en:"Avatar"},"user.weapon":{fr:"Arme",en:"Weapon"},"user.sessions":{fr:"Sessions",en:"Sessions"},"user.totalTime":{fr:"Temps total",en:"Total Time"},"user.avgPrecision":{fr:"Précision moy.",en:"Avg. Precision"},"user.avgReaction":{fr:"Réaction moy.",en:"Avg. Reaction"},"user.shotsFired":{fr:"Tirs effectués",en:"Shots Fired"},"user.enemiesKilled":{fr:"Ennemis tués",en:"Enemies Killed"},"user.detailedStats":{fr:"Statistiques globales détaillées",en:"Detailed Global Statistics"},"user.shots":{fr:"Tirs",en:"Shots"},"user.hitsReceived":{fr:"Tirs reçus",en:"Hits Received"},"user.eliminations":{fr:"Éliminations",en:"Eliminations"},"user.precisionEvolution":{fr:"Évolution Précision / Temps de réaction",en:"Precision / Reaction Time Evolution"},"user.sessionTypeDistrib":{fr:"Répartition par type de session",en:"Distribution by Session Type"},"user.sessionHistory":{fr:"Historique des sessions",en:"Session History"},"user.noSession":{fr:"Aucune session",en:"No sessions"},"stats.shotsFired":{fr:"Tirs effectués",en:"Shots fired"},"stats.shotsMissed":{fr:"Tirs manqués",en:"Shots missed"},"stats.enemiesHit":{fr:"Ennemis touchés",en:"Enemies hit"},"stats.civiliansHit":{fr:"Civils touchés",en:"Civilians hit"},"stats.policeHit":{fr:"Police touchée",en:"Police hit"},"stats.fromEnemyIA":{fr:"Depuis IA ennemie",en:"From enemy AI"},"stats.fromEnemyUsers":{fr:"Depuis joueurs ennemis",en:"From enemy players"},"stats.fromPolice":{fr:"Depuis police (tir ami)",en:"From police (friendly fire)"},"stats.enemiesKilled":{fr:"Ennemis tués",en:"Enemies killed"},"stats.civiliansKilled":{fr:"Civils tués",en:"Civilians killed"},"stats.policeKilled":{fr:"Police tuée",en:"Police killed"},"obj.civilian":{fr:"Protection civils",en:"Civilian Protection"},"obj.time":{fr:"Temps",en:"Time"},"obj.enemy":{fr:"Ennemis",en:"Enemies"},"obj.health":{fr:"Santé",en:"Health"},"obj.precision":{fr:"Précision",en:"Precision"},"obj.reactTime":{fr:"Temps de réaction",en:"Reaction Time"},"obj.ammoLimit":{fr:"Munitions",en:"Ammo"},"obj.target":{fr:"Cibles",en:"Targets"},"obj.overall":{fr:"Global",en:"Overall"},"sessionType.0":{fr:"Stand de Tir",en:"Fire Range"},"sessionType.1":{fr:"Challenge",en:"Challenge"},"sessionType.2":{fr:"Protection",en:"Protect"},"sessionType.3":{fr:"Désescalade",en:"De-Escalation"},"sessionType.4":{fr:"Terrorisme",en:"Terrorism"},"sessionType.5":{fr:"Incendie",en:"Fire Extinction"},"sessionType.6":{fr:"Récupération",en:"Recovering"},"sessionType.7":{fr:"Tir Longue Distance",en:"Long Range"},"hitType.enemy":{fr:"Ennemi",en:"Enemy"},"hitType.civilian":{fr:"Civil",en:"Civilian"},"hitType.police":{fr:"Police",en:"Police"},"hitType.object":{fr:"Objet",en:"Object"},"hitType.paperTarget":{fr:"Cible Papier",en:"Paper Target"},"hitType.target":{fr:"Cible",en:"Target"},"hitType.deadBody":{fr:"Corps",en:"Dead Body"},"badge.success":{fr:"Réussi",en:"Success"},"badge.failed":{fr:"Échoué",en:"Failed"},"badge.killed":{fr:"Tué",en:"Killed"},"firerange.personalStats":{fr:"Statistiques personnelles",en:"Personal Statistics"},"firerange.shotsFired":{fr:"Tirs effectués",en:"Shots Fired"},"firerange.shotsMissed":{fr:"Tirs manqués",en:"Missed Shots"},"firerange.avgPrecision":{fr:"Précision moyenne",en:"Average Precision"},"firerange.precisionChart":{fr:"Précision des tirs durant la session",en:"Shots Precision During Session"},"firerange.targetView":{fr:"Impacts sur la cible",en:"Target Hits"},"chart.sessions":{fr:"Sessions",en:"Sessions"},"chart.precision":{fr:"Précision",en:"Precision"},"chart.reactionTime":{fr:"Temps réaction (ms)",en:"Reaction Time (ms)"},"print.btn":{fr:"Imprimer",en:"Print"},"print.generatedOn":{fr:"Généré le",en:"Generated on"},loading:{fr:"Chargement...",en:"Loading..."},noData:{fr:"Aucune donnée",en:"No data"}},XT=C.createContext(null);function L2({children:e}){const[t,r]=C.useState(()=>{const o=localStorage.getItem("proserve-lang");return o==="en"||o==="fr"?o:"fr"}),n=C.useCallback(o=>{r(o),localStorage.setItem("proserve-lang",o)},[]),i=C.useCallback(o=>{var u;return((u=D2[o])==null?void 0:u[t])||o},[t]);return w.jsx(XT.Provider,{value:{lang:t,setLang:n,t:i},children:e})}function zr(){const e=C.useContext(XT);if(!e)throw new Error("useI18n must be used within I18nProvider");return e}var ch={exports:{}};/*! Copyright (c) 2018 Jed Watson. Licensed under the MIT License (MIT), see http://jedwatson.github.io/classnames */var SS;function B2(){return SS||(SS=1,(function(e){(function(){var t={}.hasOwnProperty;function r(){for(var o="",u=0;ue!=null?String(e):t||null;function Pg(){return Pg=Object.assign?Object.assign.bind():function(e){for(var t=1;t1?v-1:0),m=1;m{e=Re(e,"navbar-brand");const o=r||(n.href?"a":"span");return w.jsx(o,{...n,ref:i,className:Oe(t,e)})});eC.displayName="NavbarBrand";function J0(e){return e&&e.ownerDocument||document}function V2(e){var t=J0(e);return t&&t.defaultView||window}function G2(e,t){return V2(e).getComputedStyle(e,t)}var X2=/([A-Z])/g;function Y2(e){return e.replace(X2,"-$1").toLowerCase()}var Q2=/^ms-/;function Gl(e){return Y2(e).replace(Q2,"-ms-")}var Z2=/^((translate|rotate|scale)(X|Y|Z|3d)?|matrix(3d)?|perspective|skew(X|Y)?)$/i;function J2(e){return!!(e&&Z2.test(e))}function Sn(e,t){var r="",n="";if(typeof t=="string")return e.style.getPropertyValue(Gl(t))||G2(e).getPropertyValue(Gl(t));Object.keys(t).forEach(function(i){var o=t[i];!o&&o!==0?e.style.removeProperty(Gl(i)):J2(i)?n+=i+"("+o+") ":r+=Gl(i)+": "+o+";"}),n&&(r+="transform: "+n+";"),e.style.cssText+=";"+r}var fh={exports:{}},dh,_S;function eD(){if(_S)return dh;_S=1;var e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return dh=e,dh}var ph,PS;function tD(){if(PS)return ph;PS=1;var e=eD();function t(){}function r(){}return r.resetWarningCache=t,ph=function(){function n(u,l,f,d,v,p){if(p!==e){var m=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw m.name="Invariant Violation",m}}n.isRequired=n;function i(){return n}var o={array:n,bigint:n,bool:n,func:n,number:n,object:n,string:n,symbol:n,any:n,arrayOf:i,element:n,elementType:n,instanceOf:i,node:n,objectOf:i,oneOf:i,oneOfType:i,shape:i,exact:i,checkPropTypes:r,resetWarningCache:t};return o.PropTypes=o,o},ph}var ES;function rD(){return ES||(ES=1,fh.exports=tD()()),fh.exports}var nD=rD();const $e=Ue(nD),jS={disabled:!1},tC=I.createContext(null);var iD=function(t){return t.scrollTop},Ps="unmounted",ti="exited",Br="entering",yn="entered",Bs="exiting",Nn=(function(e){W2(t,e);function t(n,i){var o;o=e.call(this,n,i)||this;var u=i,l=u&&!u.isMounting?n.enter:n.appear,f;return o.appearStatus=null,n.in?l?(f=ti,o.appearStatus=Br):f=yn:n.unmountOnExit||n.mountOnEnter?f=Ps:f=ti,o.state={status:f},o.nextCallback=null,o}t.getDerivedStateFromProps=function(i,o){var u=i.in;return u&&o.status===Ps?{status:ti}:null};var r=t.prototype;return r.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},r.componentDidUpdate=function(i){var o=null;if(i!==this.props){var u=this.state.status;this.props.in?u!==Br&&u!==yn&&(o=Br):(u===Br||u===yn)&&(o=Bs)}this.updateStatus(!1,o)},r.componentWillUnmount=function(){this.cancelNextCallback()},r.getTimeouts=function(){var i=this.props.timeout,o,u,l;return o=u=l=i,i!=null&&typeof i!="number"&&(o=i.exit,u=i.enter,l=i.appear!==void 0?i.appear:u),{exit:o,enter:u,appear:l}},r.updateStatus=function(i,o){if(i===void 0&&(i=!1),o!==null)if(this.cancelNextCallback(),o===Br){if(this.props.unmountOnExit||this.props.mountOnEnter){var u=this.props.nodeRef?this.props.nodeRef.current:Ma.findDOMNode(this);u&&iD(u)}this.performEnter(i)}else this.performExit();else this.props.unmountOnExit&&this.state.status===ti&&this.setState({status:Ps})},r.performEnter=function(i){var o=this,u=this.props.enter,l=this.context?this.context.isMounting:i,f=this.props.nodeRef?[l]:[Ma.findDOMNode(this),l],d=f[0],v=f[1],p=this.getTimeouts(),m=l?p.appear:p.enter;if(!i&&!u||jS.disabled){this.safeSetState({status:yn},function(){o.props.onEntered(d)});return}this.props.onEnter(d,v),this.safeSetState({status:Br},function(){o.props.onEntering(d,v),o.onTransitionEnd(m,function(){o.safeSetState({status:yn},function(){o.props.onEntered(d,v)})})})},r.performExit=function(){var i=this,o=this.props.exit,u=this.getTimeouts(),l=this.props.nodeRef?void 0:Ma.findDOMNode(this);if(!o||jS.disabled){this.safeSetState({status:ti},function(){i.props.onExited(l)});return}this.props.onExit(l),this.safeSetState({status:Bs},function(){i.props.onExiting(l),i.onTransitionEnd(u.exit,function(){i.safeSetState({status:ti},function(){i.props.onExited(l)})})})},r.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},r.safeSetState=function(i,o){o=this.setNextCallback(o),this.setState(i,o)},r.setNextCallback=function(i){var o=this,u=!0;return this.nextCallback=function(l){u&&(u=!1,o.nextCallback=null,i(l))},this.nextCallback.cancel=function(){u=!1},this.nextCallback},r.onTransitionEnd=function(i,o){this.setNextCallback(o);var u=this.props.nodeRef?this.props.nodeRef.current:Ma.findDOMNode(this),l=i==null&&!this.props.addEndListener;if(!u||l){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var f=this.props.nodeRef?[this.nextCallback]:[u,this.nextCallback],d=f[0],v=f[1];this.props.addEndListener(d,v)}i!=null&&setTimeout(this.nextCallback,i)},r.render=function(){var i=this.state.status;if(i===Ps)return null;var o=this.props,u=o.children;o.in,o.mountOnEnter,o.unmountOnExit,o.appear,o.enter,o.exit,o.timeout,o.addEndListener,o.onEnter,o.onEntering,o.onEntered,o.onExit,o.onExiting,o.onExited,o.nodeRef;var l=YT(o,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return I.createElement(tC.Provider,{value:null},typeof u=="function"?u(i,l):I.cloneElement(I.Children.only(u),l))},t})(I.Component);Nn.contextType=tC;Nn.propTypes={};function ja(){}Nn.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:ja,onEntering:ja,onEntered:ja,onExit:ja,onExiting:ja,onExited:ja};Nn.UNMOUNTED=Ps;Nn.EXITED=ti;Nn.ENTERING=Br;Nn.ENTERED=yn;Nn.EXITING=Bs;function aD(e){return e.code==="Escape"||e.keyCode===27}function oD(){const e=C.version.split(".");return{major:+e[0],minor:+e[1],patch:+e[2]}}function go(e){if(!e||typeof e=="function")return null;const{major:t}=oD();return t>=19?e.props.ref:e.ref}const _f=!!(typeof window<"u"&&window.document&&window.document.createElement);var jg=!1,Ag=!1;try{var hh={get passive(){return jg=!0},get once(){return Ag=jg=!0}};_f&&(window.addEventListener("test",hh,hh),window.removeEventListener("test",hh,!0))}catch{}function sD(e,t,r,n){if(n&&typeof n!="boolean"&&!Ag){var i=n.once,o=n.capture,u=r;!Ag&&i&&(u=r.__once||function l(f){this.removeEventListener(t,l,o),r.call(this,f)},r.__once=u),e.addEventListener(t,u,jg?n:o)}e.addEventListener(t,r,n)}function uD(e,t,r,n){var i=n&&typeof n!="boolean"?n.capture:n;e.removeEventListener(t,r,i),r.__once&&e.removeEventListener(t,r.__once,i)}function vc(e,t,r,n){return sD(e,t,r,n),function(){uD(e,t,r,n)}}function lD(e,t,r,n){if(n===void 0&&(n=!0),e){var i=document.createEvent("HTMLEvents");i.initEvent(t,r,n),e.dispatchEvent(i)}}function cD(e){var t=Sn(e,"transitionDuration")||"",r=t.indexOf("ms")===-1?1e3:1;return parseFloat(t)*r}function fD(e,t,r){r===void 0&&(r=5);var n=!1,i=setTimeout(function(){n||lD(e,"transitionend",!0)},t+r),o=vc(e,"transitionend",function(){n=!0},{once:!0});return function(){clearTimeout(i),o()}}function dD(e,t,r,n){r==null&&(r=cD(e)||0);var i=fD(e,r,n),o=vc(e,"transitionend",t);return function(){i(),o()}}function AS(e,t){const r=Sn(e,t)||"",n=r.indexOf("ms")===-1?1e3:1;return parseFloat(r)*n}function eb(e,t){const r=AS(e,"transitionDuration"),n=AS(e,"transitionDelay"),i=dD(e,o=>{o.target===e&&(i(),t(o))},r+n)}function vs(...e){return e.filter(t=>t!=null).reduce((t,r)=>{if(typeof r!="function")throw new Error("Invalid Argument Type, must only provide functions, undefined, or null.");return t===null?r:function(...i){t.apply(this,i),r.apply(this,i)}},null)}function rC(e){e.offsetHeight}const TS=e=>!e||typeof e=="function"?e:t=>{e.current=t};function pD(e,t){const r=TS(e),n=TS(t);return i=>{r&&r(i),n&&n(i)}}function hD(e,t){return C.useMemo(()=>pD(e,t),[e,t])}function vD(e){return e&&"setState"in e?Ma.findDOMNode(e):e??null}const Pf=I.forwardRef(({onEnter:e,onEntering:t,onEntered:r,onExit:n,onExiting:i,onExited:o,addEndListener:u,children:l,childRef:f,...d},v)=>{const p=C.useRef(null),m=hD(p,f),b=j=>{m(vD(j))},O=j=>N=>{j&&p.current&&j(p.current,N)},x=C.useCallback(O(e),[e]),g=C.useCallback(O(t),[t]),E=C.useCallback(O(r),[r]),A=C.useCallback(O(n),[n]),T=C.useCallback(O(i),[i]),P=C.useCallback(O(o),[o]),_=C.useCallback(O(u),[u]);return w.jsx(Nn,{ref:v,...d,onEnter:x,onEntered:E,onEntering:g,onExit:A,onExited:P,onExiting:T,addEndListener:_,nodeRef:p,children:typeof l=="function"?(j,N)=>l(j,{...N,ref:b}):I.cloneElement(l,{ref:b})})});Pf.displayName="TransitionWrapper";const mD={height:["marginTop","marginBottom"],width:["marginLeft","marginRight"]};function yD(e,t){const r=`offset${e[0].toUpperCase()}${e.slice(1)}`,n=t[r],i=mD[e];return n+parseInt(Sn(t,i[0]),10)+parseInt(Sn(t,i[1]),10)}const gD={[ti]:"collapse",[Bs]:"collapsing",[Br]:"collapsing",[yn]:"collapse show"},nC=I.forwardRef(({onEnter:e,onEntering:t,onEntered:r,onExit:n,onExiting:i,className:o,children:u,dimension:l="height",in:f=!1,timeout:d=300,mountOnEnter:v=!1,unmountOnExit:p=!1,appear:m=!1,getDimensionValue:b=yD,...O},x)=>{const g=typeof l=="function"?l():l,E=C.useMemo(()=>vs(j=>{j.style[g]="0"},e),[g,e]),A=C.useMemo(()=>vs(j=>{const N=`scroll${g[0].toUpperCase()}${g.slice(1)}`;j.style[g]=`${j[N]}px`},t),[g,t]),T=C.useMemo(()=>vs(j=>{j.style[g]=null},r),[g,r]),P=C.useMemo(()=>vs(j=>{j.style[g]=`${b(g,j)}px`,rC(j)},n),[n,b,g]),_=C.useMemo(()=>vs(j=>{j.style[g]=null},i),[g,i]);return w.jsx(Pf,{ref:x,addEndListener:eb,...O,"aria-expanded":O.role?f:null,onEnter:E,onEntering:A,onEntered:T,onExit:P,onExiting:_,childRef:go(u),in:f,timeout:d,mountOnEnter:v,unmountOnExit:p,appear:m,children:(j,N)=>I.cloneElement(u,{...N,className:Oe(o,u.props.className,gD[j],g==="width"&&"collapse-horizontal")})})});nC.displayName="Collapse";const bo=C.createContext(null);bo.displayName="NavbarContext";const iC=C.forwardRef(({children:e,bsPrefix:t,...r},n)=>{t=Re(t,"navbar-collapse");const i=C.useContext(bo);return w.jsx(nC,{in:!!(i&&i.expanded),...r,children:w.jsx("div",{ref:n,className:t,children:e})})});iC.displayName="NavbarCollapse";function bD(e){const t=C.useRef(e);return C.useEffect(()=>{t.current=e},[e]),t}function Ef(e){const t=bD(e);return C.useCallback(function(...r){return t.current&&t.current(...r)},[t])}const aC=C.forwardRef(({bsPrefix:e,className:t,children:r,label:n="Toggle navigation",as:i="button",onClick:o,...u},l)=>{e=Re(e,"navbar-toggler");const{onToggle:f,expanded:d}=C.useContext(bo)||{},v=Ef(p=>{o&&o(p),f&&f()});return i==="button"&&(u.type="button"),w.jsx(i,{...u,ref:l,onClick:v,"aria-label":n,className:Oe(t,e,!d&&"collapsed"),children:r||w.jsx("span",{className:`${e}-icon`})})});aC.displayName="NavbarToggle";const xD=typeof global<"u"&&global.navigator&&global.navigator.product==="ReactNative",wD=typeof document<"u",SD=wD||xD?C.useLayoutEffect:C.useEffect,Tg=new WeakMap,CS=(e,t)=>{if(!e||!t)return;const r=Tg.get(t)||new Map;Tg.set(t,r);let n=r.get(e);return n||(n=t.matchMedia(e),n.refCount=0,r.set(n.media,n)),n};function OD(e,t=typeof window>"u"?void 0:window){const r=CS(e,t),[n,i]=C.useState(()=>r?r.matches:!1);return SD(()=>{let o=CS(e,t);if(!o)return i(!1);let u=Tg.get(t);const l=()=>{i(o.matches)};return o.refCount++,o.addListener(l),l(),()=>{o.removeListener(l),o.refCount--,o.refCount<=0&&(u==null||u.delete(o.media)),o=void 0}},[e]),n}function _D(e){const t=Object.keys(e);function r(l,f){return l===f?f:l?`${l} and ${f}`:f}function n(l){return t[Math.min(t.indexOf(l)+1,t.length-1)]}function i(l){const f=n(l);let d=e[f];return typeof d=="number"?d=`${d-.2}px`:d=`calc(${d} - 0.2px)`,`(max-width: ${d})`}function o(l){let f=e[l];return typeof f=="number"&&(f=`${f}px`),`(min-width: ${f})`}function u(l,f,d){let v;typeof l=="object"?(v=l,d=f,f=!0):(f=f||!0,v={[l]:f});let p=C.useMemo(()=>Object.entries(v).reduce((m,[b,O])=>((O==="up"||O===!0)&&(m=r(m,o(b))),(O==="down"||O===!0)&&(m=r(m,i(b))),m),""),[JSON.stringify(v)]);return OD(p,d)}return u}const PD=_D({xs:0,sm:576,md:768,lg:992,xl:1200,xxl:1400});function vh(e){e===void 0&&(e=J0());try{var t=e.activeElement;return!t||!t.nodeName?null:t}catch{return e.body}}function kS(e,t){if(e.contains)return e.contains(t);if(e.compareDocumentPosition)return e===t||!!(e.compareDocumentPosition(t)&16)}function ED(){const e=C.useRef(!0),t=C.useRef(()=>e.current);return C.useEffect(()=>(e.current=!0,()=>{e.current=!1}),[]),t.current}function jD(e){const t=C.useRef(e);return t.current=e,t}function AD(e){const t=jD(e);C.useEffect(()=>()=>t.current(),[])}function TD(e){const t=C.useRef(null);return C.useEffect(()=>{t.current=e}),t.current}function CD(e){const t=C.useRef(e);return C.useEffect(()=>{t.current=e},[e]),t}function gn(e){const t=CD(e);return C.useCallback(function(...r){return t.current&&t.current(...r)},[t])}const kD="data-rr-ui-",ND="rrUi";function jf(e){return`${kD}${e}`}function RD(e){return`${ND}${e}`}function MD(e=document){const t=e.defaultView;return Math.abs(t.innerWidth-e.documentElement.clientWidth)}const NS=jf("modal-open");class tb{constructor({ownerDocument:t,handleContainerOverflow:r=!0,isRTL:n=!1}={}){this.handleContainerOverflow=r,this.isRTL=n,this.modals=[],this.ownerDocument=t}getScrollbarWidth(){return MD(this.ownerDocument)}getElement(){return(this.ownerDocument||document).body}setModalAttributes(t){}removeModalAttributes(t){}setContainerStyle(t){const r={overflow:"hidden"},n=this.isRTL?"paddingLeft":"paddingRight",i=this.getElement();t.style={overflow:i.style.overflow,[n]:i.style[n]},t.scrollBarWidth&&(r[n]=`${parseInt(Sn(i,n)||"0",10)+t.scrollBarWidth}px`),i.setAttribute(NS,""),Sn(i,r)}reset(){[...this.modals].forEach(t=>this.remove(t))}removeContainerStyle(t){const r=this.getElement();r.removeAttribute(NS),Object.assign(r.style,t.style)}add(t){let r=this.modals.indexOf(t);return r!==-1||(r=this.modals.length,this.modals.push(t),this.setModalAttributes(t),r!==0)||(this.state={scrollBarWidth:this.getScrollbarWidth(),style:{}},this.handleContainerOverflow&&this.setContainerStyle(this.state)),r}remove(t){const r=this.modals.indexOf(t);r!==-1&&(this.modals.splice(r,1),!this.modals.length&&this.handleContainerOverflow&&this.removeContainerStyle(this.state),this.removeModalAttributes(t))}isTopModal(t){return!!this.modals.length&&this.modals[this.modals.length-1]===t}}const oC=C.createContext(_f?window:void 0);oC.Provider;function rb(){return C.useContext(oC)}const mh=(e,t)=>_f?e==null?(t||J0()).body:(typeof e=="function"&&(e=e()),e&&"current"in e&&(e=e.current),e&&("nodeType"in e||e.getBoundingClientRect)?e:null):null;function $D(e,t){const r=rb(),[n,i]=C.useState(()=>mh(e,r==null?void 0:r.document));if(!n){const o=mh(e);o&&i(o)}return C.useEffect(()=>{},[t,n]),C.useEffect(()=>{const o=mh(e);o!==n&&i(o)},[e,n]),n}const RS=e=>!e||typeof e=="function"?e:t=>{e.current=t};function ID(e,t){const r=RS(e),n=RS(t);return i=>{r&&r(i),n&&n(i)}}function Af(e,t){return C.useMemo(()=>ID(e,t),[e,t])}const DD=typeof global<"u"&&global.navigator&&global.navigator.product==="ReactNative",LD=typeof document<"u",MS=LD||DD?C.useLayoutEffect:C.useEffect;function BD({children:e,in:t,onExited:r,mountOnEnter:n,unmountOnExit:i}){const o=C.useRef(null),u=C.useRef(t),l=gn(r);C.useEffect(()=>{t?u.current=!0:l(o.current)},[t,l]);const f=Af(o,go(e)),d=C.cloneElement(e,{ref:f});return t?d:i||!u.current&&n?null:d}const FD=["onEnter","onEntering","onEntered","onExit","onExiting","onExited","addEndListener","children"];function qD(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function zD(e){let{onEnter:t,onEntering:r,onEntered:n,onExit:i,onExiting:o,onExited:u,addEndListener:l,children:f}=e,d=qD(e,FD);const v=C.useRef(null),p=Af(v,go(f)),m=P=>_=>{P&&v.current&&P(v.current,_)},b=C.useCallback(m(t),[t]),O=C.useCallback(m(r),[r]),x=C.useCallback(m(n),[n]),g=C.useCallback(m(i),[i]),E=C.useCallback(m(o),[o]),A=C.useCallback(m(u),[u]),T=C.useCallback(m(l),[l]);return Object.assign({},d,{nodeRef:v},t&&{onEnter:b},r&&{onEntering:O},n&&{onEntered:x},i&&{onExit:g},o&&{onExiting:E},u&&{onExited:A},l&&{addEndListener:T},{children:typeof f=="function"?(P,_)=>f(P,Object.assign({},_,{ref:p})):C.cloneElement(f,{ref:p})})}const UD=["component"];function WD(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}const HD=C.forwardRef((e,t)=>{let{component:r}=e,n=WD(e,UD);const i=zD(n);return w.jsx(r,Object.assign({ref:t},i))});function KD({in:e,onTransition:t}){const r=C.useRef(null),n=C.useRef(!0),i=gn(t);return MS(()=>{if(!r.current)return;let o=!1;return i({in:e,element:r.current,initial:n.current,isStale:()=>o}),()=>{o=!0}},[e,i]),MS(()=>(n.current=!1,()=>{n.current=!0}),[]),r}function VD({children:e,in:t,onExited:r,onEntered:n,transition:i}){const[o,u]=C.useState(!t);t&&o&&u(!1);const l=KD({in:!!t,onTransition:d=>{const v=()=>{d.isStale()||(d.in?n==null||n(d.element,d.initial):(u(!0),r==null||r(d.element)))};Promise.resolve(i(d)).then(v,p=>{throw d.in||u(!0),p})}}),f=Af(l,go(e));return o&&!t?null:C.cloneElement(e,{ref:f})}function $S(e,t,r){return e?w.jsx(HD,Object.assign({},r,{component:e})):t?w.jsx(VD,Object.assign({},r,{transition:t})):w.jsx(BD,Object.assign({},r))}const GD=["show","role","className","style","children","backdrop","keyboard","onBackdropClick","onEscapeKeyDown","transition","runTransition","backdropTransition","runBackdropTransition","autoFocus","enforceFocus","restoreFocus","restoreFocusOptions","renderDialog","renderBackdrop","manager","container","onShow","onHide","onExit","onExited","onExiting","onEnter","onEntering","onEntered"];function XD(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}let yh;function YD(e){return yh||(yh=new tb({ownerDocument:e==null?void 0:e.document})),yh}function QD(e){const t=rb(),r=e||YD(t),n=C.useRef({dialog:null,backdrop:null});return Object.assign(n.current,{add:()=>r.add(n.current),remove:()=>r.remove(n.current),isTopModal:()=>r.isTopModal(n.current),setDialogRef:C.useCallback(i=>{n.current.dialog=i},[]),setBackdropRef:C.useCallback(i=>{n.current.backdrop=i},[])})}const sC=C.forwardRef((e,t)=>{let{show:r=!1,role:n="dialog",className:i,style:o,children:u,backdrop:l=!0,keyboard:f=!0,onBackdropClick:d,onEscapeKeyDown:v,transition:p,runTransition:m,backdropTransition:b,runBackdropTransition:O,autoFocus:x=!0,enforceFocus:g=!0,restoreFocus:E=!0,restoreFocusOptions:A,renderDialog:T,renderBackdrop:P=Ce=>w.jsx("div",Object.assign({},Ce)),manager:_,container:j,onShow:N,onHide:R=()=>{},onExit:D,onExited:W,onExiting:B,onEnter:M,onEntering:z,onEntered:G}=e,V=XD(e,GD);const Y=rb(),J=$D(j),H=QD(_),ee=ED(),Z=TD(r),[L,U]=C.useState(!r),oe=C.useRef(null);C.useImperativeHandle(t,()=>H,[H]),_f&&!Z&&r&&(oe.current=vh(Y==null?void 0:Y.document)),r&&L&&U(!1);const ce=gn(()=>{if(H.add(),ge.current=vc(document,"keydown",Ae),ae.current=vc(document,"focus",()=>setTimeout(Pe),!0),N&&N(),x){var Ce,Je;const st=vh((Ce=(Je=H.dialog)==null?void 0:Je.ownerDocument)!=null?Ce:Y==null?void 0:Y.document);H.dialog&&st&&!kS(H.dialog,st)&&(oe.current=st,H.dialog.focus())}}),me=gn(()=>{if(H.remove(),ge.current==null||ge.current(),ae.current==null||ae.current(),E){var Ce;(Ce=oe.current)==null||Ce.focus==null||Ce.focus(A),oe.current=null}});C.useEffect(()=>{!r||!J||ce()},[r,J,ce]),C.useEffect(()=>{L&&me()},[L,me]),AD(()=>{me()});const Pe=gn(()=>{if(!g||!ee()||!H.isTopModal())return;const Ce=vh(Y==null?void 0:Y.document);H.dialog&&Ce&&!kS(H.dialog,Ce)&&H.dialog.focus()}),De=gn(Ce=>{Ce.target===Ce.currentTarget&&(d==null||d(Ce),l===!0&&R())}),Ae=gn(Ce=>{f&&aD(Ce)&&H.isTopModal()&&(v==null||v(Ce),Ce.defaultPrevented||R())}),ae=C.useRef(),ge=C.useRef(),Te=(...Ce)=>{U(!0),W==null||W(...Ce)};if(!J)return null;const ne=Object.assign({role:n,ref:H.setDialogRef,"aria-modal":n==="dialog"?!0:void 0},V,{style:o,className:i,tabIndex:-1});let We=T?T(ne):w.jsx("div",Object.assign({},ne,{children:C.cloneElement(u,{role:"document"})}));We=$S(p,m,{unmountOnExit:!0,mountOnEnter:!0,appear:!0,in:!!r,onExit:D,onExiting:B,onExited:Te,onEnter:M,onEntering:z,onEntered:G,children:We});let Ne=null;return l&&(Ne=P({ref:H.setBackdropRef,onClick:De}),Ne=$S(b,O,{in:!!r,appear:!0,mountOnEnter:!0,unmountOnExit:!0,children:Ne})),w.jsx(w.Fragment,{children:Ma.createPortal(w.jsxs(w.Fragment,{children:[Ne,We]}),J)})});sC.displayName="Modal";const ZD=Object.assign(sC,{Manager:tb}),JD={[Br]:"show",[yn]:"show"},uC=C.forwardRef(({className:e,children:t,transitionClasses:r={},onEnter:n,...i},o)=>{const u={in:!1,timeout:300,mountOnEnter:!1,unmountOnExit:!1,appear:!1,...i},l=C.useCallback((f,d)=>{rC(f),n==null||n(f,d)},[n]);return w.jsx(Pf,{ref:o,addEndListener:eb,...u,onEnter:l,childRef:go(t),children:(f,d)=>C.cloneElement(t,{...d,className:Oe("fade",e,t.props.className,JD[f],r[f])})})});uC.displayName="Fade";const lC=C.forwardRef(({className:e,bsPrefix:t,as:r="div",...n},i)=>(t=Re(t,"offcanvas-body"),w.jsx(r,{ref:i,className:Oe(e,t),...n})));lC.displayName="OffcanvasBody";const eL={[Br]:"show",[yn]:"show"},cC=C.forwardRef(({bsPrefix:e,className:t,children:r,in:n=!1,mountOnEnter:i=!1,unmountOnExit:o=!1,appear:u=!1,...l},f)=>(e=Re(e,"offcanvas"),w.jsx(Pf,{ref:f,addEndListener:eb,in:n,mountOnEnter:i,unmountOnExit:o,appear:u,...l,childRef:go(r),children:(d,v)=>C.cloneElement(r,{...v,className:Oe(t,r.props.className,(d===Br||d===Bs)&&`${e}-toggling`,eL[d])})})));cC.displayName="OffcanvasToggling";const fC=C.createContext({onHide(){}}),tL={"aria-label":$e.string,onClick:$e.func,variant:$e.oneOf(["white"])},nb=C.forwardRef(({className:e,variant:t,"aria-label":r="Close",...n},i)=>w.jsx("button",{ref:i,type:"button",className:Oe("btn-close",t&&`btn-close-${t}`,e),"aria-label":r,...n}));nb.displayName="CloseButton";nb.propTypes=tL;const dC=C.forwardRef(({closeLabel:e="Close",closeVariant:t,closeButton:r=!1,onHide:n,children:i,...o},u)=>{const l=C.useContext(fC),f=Ef(()=>{l==null||l.onHide(),n==null||n()});return w.jsxs("div",{ref:u,...o,children:[i,r&&w.jsx(nb,{"aria-label":e,variant:t,onClick:f})]})});dC.displayName="AbstractModalHeader";const pC=C.forwardRef(({bsPrefix:e,className:t,closeLabel:r="Close",closeButton:n=!1,...i},o)=>(e=Re(e,"offcanvas-header"),w.jsx(dC,{ref:o,...i,className:Oe(t,e),closeLabel:r,closeButton:n})));pC.displayName="OffcanvasHeader";const ib=(e=>C.forwardRef((t,r)=>w.jsx("div",{...t,ref:r,className:Oe(t.className,e)}))),rL=ib("h5"),hC=C.forwardRef(({className:e,bsPrefix:t,as:r=rL,...n},i)=>(t=Re(t,"offcanvas-title"),w.jsx(r,{ref:i,className:Oe(e,t),...n})));hC.displayName="OffcanvasTitle";function nL(e,t){return e.classList?e.classList.contains(t):(" "+(e.className.baseVal||e.className)+" ").indexOf(" "+t+" ")!==-1}function iL(e,t){e.classList?e.classList.add(t):nL(e,t)||(typeof e.className=="string"?e.className=e.className+" "+t:e.setAttribute("class",(e.className&&e.className.baseVal||"")+" "+t))}var aL=Function.prototype.bind.call(Function.prototype.call,[].slice);function ki(e,t){return aL(e.querySelectorAll(t))}function IS(e,t){return e.replace(new RegExp("(^|\\s)"+t+"(?:\\s|$)","g"),"$1").replace(/\s+/g," ").replace(/^\s*|\s*$/g,"")}function oL(e,t){e.classList?e.classList.remove(t):typeof e.className=="string"?e.className=IS(e.className,t):e.setAttribute("class",IS(e.className&&e.className.baseVal||"",t))}const Aa={FIXED_CONTENT:".fixed-top, .fixed-bottom, .is-fixed, .sticky-top",STICKY_CONTENT:".sticky-top",NAVBAR_TOGGLER:".navbar-toggler"};class vC extends tb{adjustAndStore(t,r,n){const i=r.style[t];r.dataset[t]=i,Sn(r,{[t]:`${parseFloat(Sn(r,t))+n}px`})}restore(t,r){const n=r.dataset[t];n!==void 0&&(delete r.dataset[t],Sn(r,{[t]:n}))}setContainerStyle(t){super.setContainerStyle(t);const r=this.getElement();if(iL(r,"modal-open"),!t.scrollBarWidth)return;const n=this.isRTL?"paddingLeft":"paddingRight",i=this.isRTL?"marginLeft":"marginRight";ki(r,Aa.FIXED_CONTENT).forEach(o=>this.adjustAndStore(n,o,t.scrollBarWidth)),ki(r,Aa.STICKY_CONTENT).forEach(o=>this.adjustAndStore(i,o,-t.scrollBarWidth)),ki(r,Aa.NAVBAR_TOGGLER).forEach(o=>this.adjustAndStore(i,o,t.scrollBarWidth))}removeContainerStyle(t){super.removeContainerStyle(t);const r=this.getElement();oL(r,"modal-open");const n=this.isRTL?"paddingLeft":"paddingRight",i=this.isRTL?"marginLeft":"marginRight";ki(r,Aa.FIXED_CONTENT).forEach(o=>this.restore(n,o)),ki(r,Aa.STICKY_CONTENT).forEach(o=>this.restore(i,o)),ki(r,Aa.NAVBAR_TOGGLER).forEach(o=>this.restore(i,o))}}let gh;function sL(e){return gh||(gh=new vC(e)),gh}function uL(e){return w.jsx(cC,{...e})}function lL(e){return w.jsx(uC,{...e})}const mC=C.forwardRef(({bsPrefix:e,className:t,children:r,"aria-labelledby":n,placement:i="start",responsive:o,show:u=!1,backdrop:l=!0,keyboard:f=!0,scroll:d=!1,onEscapeKeyDown:v,onShow:p,onHide:m,container:b,autoFocus:O=!0,enforceFocus:x=!0,restoreFocus:g=!0,restoreFocusOptions:E,onEntered:A,onExit:T,onExiting:P,onEnter:_,onEntering:j,onExited:N,backdropClassName:R,manager:D,renderStaticNode:W=!1,...B},M)=>{const z=C.useRef();e=Re(e,"offcanvas");const[G,V]=C.useState(!1),Y=Ef(m),J=PD(o||"xs","up");C.useEffect(()=>{V(o?u&&!J:u)},[u,o,J]);const H=C.useMemo(()=>({onHide:Y}),[Y]);function ee(){return D||(d?(z.current||(z.current=new vC({handleContainerOverflow:!1})),z.current):sL())}const Z=(ce,...me)=>{ce&&(ce.style.visibility="visible"),_==null||_(ce,...me)},L=(ce,...me)=>{ce&&(ce.style.visibility=""),N==null||N(...me)},U=C.useCallback(ce=>w.jsx("div",{...ce,className:Oe(`${e}-backdrop`,R)}),[R,e]),oe=ce=>w.jsx("div",{...ce,...B,className:Oe(t,o?`${e}-${o}`:e,`${e}-${i}`),"aria-labelledby":n,children:r});return w.jsxs(w.Fragment,{children:[!G&&(o||W)&&oe({}),w.jsx(fC.Provider,{value:H,children:w.jsx(ZD,{show:G,ref:M,backdrop:l,container:b,keyboard:f,autoFocus:O,enforceFocus:x&&!d,restoreFocus:g,restoreFocusOptions:E,onEscapeKeyDown:v,onShow:p,onHide:Y,onEnter:Z,onEntering:j,onEntered:A,onExit:T,onExiting:P,onExited:L,manager:ee(),transition:uL,backdropTransition:lL,renderBackdrop:U,renderDialog:oe})})]})});mC.displayName="Offcanvas";const cL=Object.assign(mC,{Body:lC,Header:pC,Title:hC}),yC=C.forwardRef(({onHide:e,...t},r)=>{const n=C.useContext(bo),i=Ef(()=>{n==null||n.onToggle==null||n.onToggle(),e==null||e()});return w.jsx(cL,{ref:r,show:!!(n!=null&&n.expanded),...t,renderStaticNode:!0,onHide:i})});yC.displayName="NavbarOffcanvas";const gC=C.forwardRef(({className:e,bsPrefix:t,as:r="span",...n},i)=>(t=Re(t,"navbar-text"),w.jsx(r,{ref:i,className:Oe(e,t),...n})));gC.displayName="NavbarText";const bC=C.forwardRef((e,t)=>{const{bsPrefix:r,expand:n=!0,variant:i="light",bg:o,fixed:u,sticky:l,className:f,as:d="nav",expanded:v,onToggle:p,onSelect:m,collapseOnSelect:b=!1,...O}=QT(e,{expanded:"onToggle"}),x=Re(r,"navbar"),g=C.useCallback((...T)=>{m==null||m(...T),b&&v&&(p==null||p(!1))},[m,b,v,p]);O.role===void 0&&d!=="nav"&&(O.role="navigation");let E=`${x}-expand`;typeof n=="string"&&(E=`${E}-${n}`);const A=C.useMemo(()=>({onToggle:()=>p==null?void 0:p(!v),bsPrefix:x,expanded:!!v,expand:n}),[x,v,n,p]);return w.jsx(bo.Provider,{value:A,children:w.jsx(hc.Provider,{value:g,children:w.jsx(d,{ref:t,...O,className:Oe(f,x,n&&E,i&&`${x}-${i}`,o&&`bg-${o}`,l&&`sticky-${l}`,u&&`fixed-${u}`)})})})});bC.displayName="Navbar";const Xl=Object.assign(bC,{Brand:eC,Collapse:iC,Offcanvas:yC,Text:gC,Toggle:aC});function fL(){const[,e]=C.useReducer(t=>t+1,0);return e}const ab=C.createContext(null);ab.displayName="NavContext";const xC=C.createContext(null),dL=["as","disabled"];function pL(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function hL(e){return!e||e.trim()==="#"}function wC({tagName:e,disabled:t,href:r,target:n,rel:i,role:o,onClick:u,tabIndex:l=0,type:f}){e||(r!=null||n!=null||i!=null?e="a":e="button");const d={tagName:e};if(e==="button")return[{type:f||"button",disabled:t},d];const v=m=>{if((t||e==="a"&&hL(r))&&m.preventDefault(),t){m.stopPropagation();return}u==null||u(m)},p=m=>{m.key===" "&&(m.preventDefault(),v(m))};return e==="a"&&(r||(r="#"),t&&(r=void 0)),[{role:o??"button",disabled:void 0,tabIndex:t?void 0:l,href:r,target:e==="a"?n:void 0,"aria-disabled":t||void 0,rel:e==="a"?i:void 0,onClick:v,onKeyDown:p},d]}const SC=C.forwardRef((e,t)=>{let{as:r,disabled:n}=e,i=pL(e,dL);const[o,{tagName:u}]=wC(Object.assign({tagName:r,disabled:n},i));return w.jsx(u,Object.assign({},i,o,{ref:t}))});SC.displayName="Button";const vL=["as","active","eventKey"];function mL(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function OC({key:e,onClick:t,active:r,id:n,role:i,disabled:o}){const u=C.useContext(hc),l=C.useContext(ab),f=C.useContext(xC);let d=r;const v={role:i};if(l){!i&&l.role==="tablist"&&(v.role="tab");const p=l.getControllerId(e??null),m=l.getControlledId(e??null);v[jf("event-key")]=e,v.id=p||n,d=r==null&&e!=null?l.activeKey===e:r,(d||!(f!=null&&f.unmountOnExit)&&!(f!=null&&f.mountOnEnter))&&(v["aria-controls"]=m)}return v.role==="tab"&&(v["aria-selected"]=d,d||(v.tabIndex=-1),o&&(v.tabIndex=-1,v["aria-disabled"]=!0)),v.onClick=gn(p=>{o||(t==null||t(p),e!=null&&u&&!p.isPropagationStopped()&&u(e,p))}),[v,{isActive:d}]}const _C=C.forwardRef((e,t)=>{let{as:r=SC,active:n,eventKey:i}=e,o=mL(e,vL);const[u,l]=OC(Object.assign({key:Z0(i,o.href),active:n},o));return u[jf("active")]=l.isActive,w.jsx(r,Object.assign({},o,u,{ref:t}))});_C.displayName="NavItem";const yL=["as","onSelect","activeKey","role","onKeyDown"];function gL(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}const DS=()=>{},LS=jf("event-key"),PC=C.forwardRef((e,t)=>{let{as:r="div",onSelect:n,activeKey:i,role:o,onKeyDown:u}=e,l=gL(e,yL);const f=fL(),d=C.useRef(!1),v=C.useContext(hc),p=C.useContext(xC);let m,b;p&&(o=o||"tablist",i=p.activeKey,m=p.getControlledId,b=p.getControllerId);const O=C.useRef(null),x=T=>{const P=O.current;if(!P)return null;const _=ki(P,`[${LS}]:not([aria-disabled=true])`),j=P.querySelector("[aria-selected=true]");if(!j||j!==document.activeElement)return null;const N=_.indexOf(j);if(N===-1)return null;let R=N+T;return R>=_.length&&(R=0),R<0&&(R=_.length-1),_[R]},g=(T,P)=>{T!=null&&(n==null||n(T,P),v==null||v(T,P))},E=T=>{if(u==null||u(T),!p)return;let P;switch(T.key){case"ArrowLeft":case"ArrowUp":P=x(-1);break;case"ArrowRight":case"ArrowDown":P=x(1);break;default:return}P&&(T.preventDefault(),g(P.dataset[RD("EventKey")]||null,T),d.current=!0,f())};C.useEffect(()=>{if(O.current&&d.current){const T=O.current.querySelector(`[${LS}][aria-selected=true]`);T==null||T.focus()}d.current=!1});const A=Af(t,O);return w.jsx(hc.Provider,{value:g,children:w.jsx(ab.Provider,{value:{role:o,activeKey:Z0(i),getControlledId:m||DS,getControllerId:b||DS},children:w.jsx(r,Object.assign({},l,{onKeyDown:E,ref:A,role:o}))})})});PC.displayName="Nav";const bL=Object.assign(PC,{Item:_C}),ob=C.createContext(null);ob.displayName="CardHeaderContext";const EC=C.forwardRef(({className:e,bsPrefix:t,as:r="div",...n},i)=>(t=Re(t,"nav-item"),w.jsx(r,{ref:i,className:Oe(e,t),...n})));EC.displayName="NavItem";const xL=["onKeyDown"];function wL(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function SL(e){return!e||e.trim()==="#"}const sb=C.forwardRef((e,t)=>{let{onKeyDown:r}=e,n=wL(e,xL);const[i]=wC(Object.assign({tagName:"a"},n)),o=gn(u=>{i.onKeyDown(u),r==null||r(u)});return SL(n.href)||n.role==="button"?w.jsx("a",Object.assign({ref:t},n,i,{onKeyDown:o})):w.jsx("a",Object.assign({ref:t},n,{onKeyDown:r}))});sb.displayName="Anchor";const jC=C.forwardRef(({bsPrefix:e,className:t,as:r=sb,active:n,eventKey:i,disabled:o=!1,...u},l)=>{e=Re(e,"nav-link");const[f,d]=OC({key:Z0(i,u.href),active:n,disabled:o,...u});return w.jsx(r,{...u,...f,ref:l,disabled:o,className:Oe(t,e,o&&"disabled",d.isActive&&"active")})});jC.displayName="NavLink";const AC=C.forwardRef((e,t)=>{const{as:r="div",bsPrefix:n,variant:i,fill:o=!1,justify:u=!1,navbar:l,navbarScroll:f,className:d,activeKey:v,...p}=QT(e,{activeKey:"onSelect"}),m=Re(n,"nav");let b,O,x=!1;const g=C.useContext(bo),E=C.useContext(ob);return g?(b=g.bsPrefix,x=l??!0):E&&({cardHeaderBsPrefix:O}=E),w.jsx(bL,{as:r,ref:t,activeKey:v,className:Oe(d,{[m]:!x,[`${b}-nav`]:x,[`${b}-nav-scroll`]:x&&f,[`${O}-${i}`]:!!O,[`${m}-${i}`]:!!i,[`${m}-fill`]:o,[`${m}-justified`]:u}),...p})});AC.displayName="Nav";const Yl=Object.assign(AC,{Item:EC,Link:jC}),ub=C.forwardRef(({bsPrefix:e,fluid:t=!1,as:r="div",className:n,...i},o)=>{const u=Re(e,"container"),l=typeof t=="string"?`-${t}`:"-fluid";return w.jsx(r,{ref:o,...i,className:Oe(n,t?`${u}${l}`:u)})});ub.displayName="Container";const OL="/ProserveReport/",_L=`${OL}logo.png`;function PL(){const{lang:e,setLang:t,t:r}=zr();return w.jsx(Xl,{bg:"dark",variant:"dark",expand:"lg",className:"app-navbar",children:w.jsxs(ub,{fluid:!0,children:[w.jsxs(Xl.Brand,{as:Vl,to:"/",className:"fw-bold d-flex align-items-center gap-2",children:[w.jsx("img",{src:_L,alt:"Logo",className:"brand-logo"}),w.jsxs("span",{children:[w.jsx("span",{className:"brand-proserve",children:"PROSERVE"}),w.jsx("span",{className:"brand-report ms-2",children:"Report"})]})]}),w.jsx(Xl.Toggle,{"aria-controls":"main-nav"}),w.jsxs(Xl.Collapse,{id:"main-nav",children:[w.jsxs(Yl,{className:"me-auto",children:[w.jsx(Yl.Link,{as:Vl,to:"/",end:!0,children:r("nav.dashboard")}),w.jsx(Yl.Link,{as:Vl,to:"/sessions",children:r("nav.sessions")}),w.jsx(Yl.Link,{as:Vl,to:"/users",children:r("nav.users")})]}),w.jsxs("div",{className:"lang-switcher",children:[w.jsx("button",{className:`lang-btn ${e==="fr"?"active":""}`,onClick:()=>t("fr"),children:"FR"}),w.jsx("button",{className:`lang-btn ${e==="en"?"active":""}`,onClick:()=>t("en"),children:"EN"})]})]})]})})}function EL(){return w.jsxs("div",{className:"app-layout",children:[w.jsx(PL,{}),w.jsx(ub,{fluid:!0,className:"main-content py-4 px-4",children:w.jsx(b2,{})})]})}const wr=C.forwardRef(({bsPrefix:e,className:t,as:r="div",...n},i)=>{const o=Re(e,"row"),u=ZT(),l=JT(),f=`${o}-cols`,d=[];return u.forEach(v=>{const p=n[v];delete n[v];let m;p!=null&&typeof p=="object"?{cols:m}=p:m=p;const b=v!==l?`-${v}`:"";m!=null&&d.push(`${f}${b}-${m}`)}),w.jsx(r,{ref:i,...n,className:Oe(t,o,...d)})});wr.displayName="Row";function jL({as:e,bsPrefix:t,className:r,...n}){t=Re(t,"col");const i=ZT(),o=JT(),u=[],l=[];return i.forEach(f=>{const d=n[f];delete n[f];let v,p,m;typeof d=="object"&&d!=null?{span:v,offset:p,order:m}=d:v=d;const b=f!==o?`-${f}`:"";v&&u.push(v===!0?`${t}${b}`:`${t}${b}-${v}`),m!=null&&l.push(`order${b}-${m}`),p!=null&&l.push(`offset${b}-${p}`)}),[{...n,className:Oe(r,...u,...l)},{as:e,bsPrefix:t,spans:u}]}const Le=C.forwardRef((e,t)=>{const[{className:r,...n},{as:i="div",bsPrefix:o,spans:u}]=jL(e);return w.jsx(i,{...n,ref:t,className:Oe(r,!u.length&&o)})});Le.displayName="Col";const lb=C.forwardRef(({className:e,bsPrefix:t,as:r="div",...n},i)=>(t=Re(t,"card-body"),w.jsx(r,{ref:i,className:Oe(e,t),...n})));lb.displayName="CardBody";const TC=C.forwardRef(({className:e,bsPrefix:t,as:r="div",...n},i)=>(t=Re(t,"card-footer"),w.jsx(r,{ref:i,className:Oe(e,t),...n})));TC.displayName="CardFooter";const CC=C.forwardRef(({bsPrefix:e,className:t,as:r="div",...n},i)=>{const o=Re(e,"card-header"),u=C.useMemo(()=>({cardHeaderBsPrefix:o}),[o]);return w.jsx(ob.Provider,{value:u,children:w.jsx(r,{ref:i,...n,className:Oe(t,o)})})});CC.displayName="CardHeader";const kC=C.forwardRef(({bsPrefix:e,className:t,variant:r,as:n="img",...i},o)=>{const u=Re(e,"card-img");return w.jsx(n,{ref:o,className:Oe(r?`${u}-${r}`:u,t),...i})});kC.displayName="CardImg";const NC=C.forwardRef(({className:e,bsPrefix:t,as:r="div",...n},i)=>(t=Re(t,"card-img-overlay"),w.jsx(r,{ref:i,className:Oe(e,t),...n})));NC.displayName="CardImgOverlay";const RC=C.forwardRef(({className:e,bsPrefix:t,as:r="a",...n},i)=>(t=Re(t,"card-link"),w.jsx(r,{ref:i,className:Oe(e,t),...n})));RC.displayName="CardLink";const AL=ib("h6"),MC=C.forwardRef(({className:e,bsPrefix:t,as:r=AL,...n},i)=>(t=Re(t,"card-subtitle"),w.jsx(r,{ref:i,className:Oe(e,t),...n})));MC.displayName="CardSubtitle";const $C=C.forwardRef(({className:e,bsPrefix:t,as:r="p",...n},i)=>(t=Re(t,"card-text"),w.jsx(r,{ref:i,className:Oe(e,t),...n})));$C.displayName="CardText";const TL=ib("h5"),IC=C.forwardRef(({className:e,bsPrefix:t,as:r=TL,...n},i)=>(t=Re(t,"card-title"),w.jsx(r,{ref:i,className:Oe(e,t),...n})));IC.displayName="CardTitle";const DC=C.forwardRef(({bsPrefix:e,className:t,bg:r,text:n,border:i,body:o=!1,children:u,as:l="div",...f},d)=>{const v=Re(e,"card");return w.jsx(l,{ref:d,...f,className:Oe(t,v,r&&`bg-${r}`,n&&`text-${n}`,i&&`border-${i}`),children:o?w.jsx(lb,{children:u}):u})});DC.displayName="Card";const be=Object.assign(DC,{Img:kC,Title:IC,Subtitle:MC,Body:lb,Link:RC,Text:$C,Header:CC,Footer:TC,ImgOverlay:NC}),Sr=C.forwardRef(({bsPrefix:e,className:t,striped:r,bordered:n,borderless:i,hover:o,size:u,variant:l,responsive:f,...d},v)=>{const p=Re(e,"table"),m=Oe(t,p,l&&`${p}-${l}`,u&&`${p}-${u}`,r&&`${p}-${typeof r=="string"?`striped-${r}`:"striped"}`,n&&`${p}-bordered`,i&&`${p}-borderless`,o&&`${p}-hover`),b=w.jsx("table",{...d,className:m,ref:v});if(f){let O=`${p}-responsive`;return typeof f=="string"&&(O=`${O}-${f}`),w.jsx("div",{className:O,children:b})}return b});Sr.displayName="Table";const CL="/proserve";async function rn(e,t={}){const r=new URLSearchParams;for(const[i,o]of Object.entries(t))r.append(i,String(o));const n=await fetch(`${CL}/${e}`,{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded"},body:r.toString()});if(!n.ok)throw new Error(`API error: ${n.status} ${n.statusText}`);return n.json()}async function LC(e=-1){return(await rn("lists/all_sessions.php",{typeId:e})).stats||[]}async function kL(e,t=-1){return(await rn("lists/sessions_for_user.php",{userId:e,typeId:t})).stats||[]}async function NL(e){return(await rn("session/get.php",{sessionId:e})).session||null}async function BC(){return(await rn("lists/all_users.php")).stats||[]}async function RL(e){return(await rn("user/get.php",{userId:e})).user||null}async function ML(e){return(await rn("lists/users_in_session.php",{sessionId:e})).stats||[]}async function $L(e,t=-1){return(await rn("stats/get.php",{sessionId:e,userId:t})).stats||[]}async function IL(e,t=-1,r=-1){const n={sessionId:e};return t>0&&(n.userId=t),r>=0&&(n.sessionType=r),(await rn("stats/get.php",n)).stats||[]}async function DL(e,t=-1){const r={sessionId:e};return t>0&&(r.userId=t),(await rn("session/getobjectives.php",r)).participation||null}async function LL(e,t=!0){var n;return((n=(await rn("stats/userhistory.php",{userId:e,sessionId:-1,quickMode:t?"true":"false"})).stats)==null?void 0:n[0])||null}function Dt({title:e,value:t,subtitle:r,color:n="#4a90d9",onClick:i}){return w.jsx(be,{className:`stat-card h-100${i?" clickable-row":""}`,onClick:i,style:i?{cursor:"pointer"}:void 0,children:w.jsxs(be.Body,{className:"text-center",children:[w.jsx(be.Subtitle,{className:"mb-2 text-muted-custom",children:e}),w.jsx(be.Title,{className:"stat-value",style:{color:n},children:t}),r&&w.jsx("small",{className:"text-muted-custom",children:r})]})})}const Fa=C.forwardRef(({bsPrefix:e,bg:t="primary",pill:r=!1,text:n,className:i,as:o="span",...u},l)=>{const f=Re(e,"badge");return w.jsx(o,{ref:l,...u,className:Oe(i,f,r&&"rounded-pill",n&&`text-${n}`,t&&`bg-${t}`)})});Fa.displayName="Badge";function Tf({success:e,score:t}){const{t:r}=zr();return w.jsxs(Fa,{bg:e?"success":"danger",children:[t!==void 0&&w.jsx("span",{className:"me-1",children:t}),r(e?"badge.success":"badge.failed")]})}var cc=(e=>(e[e.FireRange=0]="FireRange",e[e.Challenge=1]="Challenge",e[e.Protect=2]="Protect",e[e.DeEscalation=3]="DeEscalation",e[e.Terrorism=4]="Terrorism",e[e.FireExtinction=5]="FireExtinction",e[e.Recovering=6]="Recovering",e[e.LongRange=7]="LongRange",e))(cc||{});const BL={0:"Stand de Tir",1:"Challenge",2:"Protection",3:"Désescalade",4:"Terrorisme",5:"Incendie",6:"Récupération",7:"Tir Longue Distance"},FC={0:"#4a90d9",1:"#9b59b6",2:"#27ae60",3:"#f39c12",4:"#e74c3c",5:"#e67e22",6:"#1abc9c",7:"#2980b9"},FL={0:"Ennemi",1:"Civil",2:"Police",3:"Objet",4:"Cible Papier",5:"Cible",6:"Corps"};function Fs({typeId:e}){const{t}=zr(),r=t(`sessionType.${e}`),n=FC[e]||"#6c757d";return w.jsx(Fa,{style:{backgroundColor:n},className:"session-type-badge",children:r})}const qC=C.forwardRef(({bsPrefix:e,variant:t,animation:r="border",size:n,as:i="div",className:o,...u},l)=>{e=Re(e,"spinner");const f=`${e}-${r}`;return w.jsx(i,{ref:l,...u,className:Oe(o,f,n&&`${f}-${n}`,t&&`text-${t}`)})});qC.displayName="Spinner";function Pu(){const{t:e}=zr();return w.jsxs("div",{className:"d-flex justify-content-center align-items-center py-5",children:[w.jsx(qC,{animation:"border",variant:"primary"}),w.jsx("span",{className:"ms-3 text-muted-custom",children:e("loading")})]})}function zC(e){var t,r,n="";if(typeof e=="string"||typeof e=="number")n+=e;else if(typeof e=="object")if(Array.isArray(e)){var i=e.length;for(t=0;t-1}return Xh=t,Xh}var Yh,mO;function nB(){if(mO)return Yh;mO=1;var e=kf();function t(r,n){var i=this.__data__,o=e(i,r);return o<0?(++this.size,i.push([r,n])):i[o][1]=n,this}return Yh=t,Yh}var Qh,yO;function Nf(){if(yO)return Qh;yO=1;var e=JL(),t=eB(),r=tB(),n=rB(),i=nB();function o(u){var l=-1,f=u==null?0:u.length;for(this.clear();++l0?1:-1},$i=function(t){return qi(t)&&t.indexOf("%")===t.length-1},le=function(t){return EB(t)&&!ju(t)},jB=function(t){return ke(t)},wt=function(t){return le(t)||qi(t)},AB=0,So=function(t){var r=++AB;return"".concat(t||"").concat(r)},zt=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(!le(t)&&!qi(t))return n;var o;if($i(t)){var u=t.indexOf("%");o=r*parseFloat(t.slice(0,u))/100}else o=+t;return ju(o)&&(o=n),i&&o>r&&(o=r),o},ni=function(t){if(!t)return null;var r=Object.keys(t);return r&&r.length?t[r[0]]:null},TB=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 IB(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function kg(e){"@babel/helpers - typeof";return kg=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},kg(e)}var HO={click:"onClick",mousedown:"onMouseDown",mouseup:"onMouseUp",mouseover:"onMouseOver",mousemove:"onMouseMove",mouseout:"onMouseOut",mouseenter:"onMouseEnter",mouseleave:"onMouseLeave",touchcancel:"onTouchCancel",touchend:"onTouchEnd",touchmove:"onTouchMove",touchstart:"onTouchStart",contextmenu:"onContextMenu",dblclick:"onDoubleClick"},On=function(t){return typeof t=="string"?t:t?t.displayName||t.name||"Component":""},KO=null,Ov=null,gb=function e(t){if(t===KO&&Array.isArray(Ov))return Ov;var r=[];return C.Children.forEach(t,function(n){ke(n)||(SB.isFragment(n)?r=r.concat(e(n.props.children)):r.push(n))}),Ov=r,KO=t,r};function cr(e,t){var r=[],n=[];return Array.isArray(t)?n=t.map(function(i){return On(i)}):n=[On(t)],gb(e).forEach(function(i){var o=lr(i,"type.displayName")||lr(i,"type.name");n.indexOf(o)!==-1&&r.push(i)}),r}function or(e,t){var r=cr(e,t);return r&&r[0]}var VO=function(t){if(!t||!t.props)return!1;var r=t.props,n=r.width,i=r.height;return!(!le(n)||n<=0||!le(i)||i<=0)},DB=["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"],LB=function(t){return t&&t.type&&qi(t.type)&&DB.indexOf(t.type)>=0},BB=function(t){return t&&kg(t)==="object"&&"clipDot"in t},FB=function(t,r,n,i){var o,u=(o=Sv==null?void 0:Sv[i])!==null&&o!==void 0?o:[];return r.startsWith("data-")||!je(t)&&(i&&u.includes(r)||NB.includes(r))||n&&yb.includes(r)},Se=function(t,r,n){if(!t||typeof t=="function"||typeof t=="boolean")return null;var i=t;if(C.isValidElement(t)&&(i=t.props),!wo(i))return null;var o={};return Object.keys(i).forEach(function(u){var l;FB((l=i)===null||l===void 0?void 0:l[u],u,r,n)&&(o[u]=i[u])}),o},Ng=function e(t,r){if(t===r)return!0;var n=C.Children.count(t);if(n!==C.Children.count(r))return!1;if(n===0)return!0;if(n===1)return GO(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 HB(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function Mg(e){var t=e.children,r=e.width,n=e.height,i=e.viewBox,o=e.className,u=e.style,l=e.title,f=e.desc,d=WB(e,UB),v=i||{width:r,height:n,x:0,y:0},p=Me("recharts-surface",o);return I.createElement("svg",Rg({},Se(d,!0,"svg"),{className:p,width:r,height:n,style:u,viewBox:"".concat(v.x," ").concat(v.y," ").concat(v.width," ").concat(v.height)}),I.createElement("title",null,l),I.createElement("desc",null,f),t)}var KB=["children","className"];function $g(){return $g=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 GB(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}var qe=I.forwardRef(function(e,t){var r=e.children,n=e.className,i=VB(e,KB),o=Me("recharts-layer",n);return I.createElement("g",$g({className:o},Se(i,!0),{ref:t}),r)}),qr=function(t,r){for(var n=arguments.length,i=new Array(n>2?n-2:0),o=2;oo?0:o+r),n=n>o?o:n,n<0&&(n+=o),o=r>n?0:n-r>>>0,r>>>=0;for(var u=Array(o);++i=o?r:e(r,n,i)}return Pv=t,Pv}var Ev,ZO;function YC(){if(ZO)return Ev;ZO=1;var e="\\ud800-\\udfff",t="\\u0300-\\u036f",r="\\ufe20-\\ufe2f",n="\\u20d0-\\u20ff",i=t+r+n,o="\\ufe0e\\ufe0f",u="\\u200d",l=RegExp("["+u+e+i+o+"]");function f(d){return l.test(d)}return Ev=f,Ev}var jv,JO;function QB(){if(JO)return jv;JO=1;function e(t){return t.split("")}return jv=e,jv}var Av,e_;function ZB(){if(e_)return Av;e_=1;var e="\\ud800-\\udfff",t="\\u0300-\\u036f",r="\\ufe20-\\ufe2f",n="\\u20d0-\\u20ff",i=t+r+n,o="\\ufe0e\\ufe0f",u="["+e+"]",l="["+i+"]",f="\\ud83c[\\udffb-\\udfff]",d="(?:"+l+"|"+f+")",v="[^"+e+"]",p="(?:\\ud83c[\\udde6-\\uddff]){2}",m="[\\ud800-\\udbff][\\udc00-\\udfff]",b="\\u200d",O=d+"?",x="["+o+"]?",g="(?:"+b+"(?:"+[v,p,m].join("|")+")"+x+O+")*",E=x+O+g,A="(?:"+[v+l+"?",l,p,m,u].join("|")+")",T=RegExp(f+"(?="+f+")|"+A+E,"g");function P(_){return _.match(T)||[]}return Av=P,Av}var Tv,t_;function JB(){if(t_)return Tv;t_=1;var e=QB(),t=YC(),r=ZB();function n(i){return t(i)?r(i):e(i)}return Tv=n,Tv}var Cv,r_;function eF(){if(r_)return Cv;r_=1;var e=YB(),t=YC(),r=JB(),n=KC();function i(o){return function(u){u=n(u);var l=t(u)?r(u):void 0,f=l?l[0]:u.charAt(0),d=l?e(l,1).join(""):u.slice(1);return f[o]()+d}}return Cv=i,Cv}var kv,n_;function tF(){if(n_)return kv;n_=1;var e=eF(),t=e("toUpperCase");return kv=t,kv}var rF=tF();const $f=Ue(rF);function Qe(e){return function(){return e}}const QC=Math.cos,gc=Math.sin,Ur=Math.sqrt,bc=Math.PI,If=2*bc,Ig=Math.PI,Dg=2*Ig,Ni=1e-6,nF=Dg-Ni;function ZC(e){this._+=e[0];for(let t=1,r=e.length;t=0))throw new Error(`invalid digits: ${e}`);if(t>15)return ZC;const r=10**t;return function(n){this._+=n[0];for(let i=1,o=n.length;iNi)if(!(Math.abs(p*f-d*v)>Ni)||!o)this._append`L${this._x1=t},${this._y1=r}`;else{let b=n-u,O=i-l,x=f*f+d*d,g=b*b+O*O,E=Math.sqrt(x),A=Math.sqrt(m),T=o*Math.tan((Ig-Math.acos((x+m-g)/(2*E*A)))/2),P=T/A,_=T/E;Math.abs(P-1)>Ni&&this._append`L${t+P*v},${r+P*p}`,this._append`A${o},${o},0,0,${+(p*b>v*O)},${this._x1=t+_*f},${this._y1=r+_*d}`}}arc(t,r,n,i,o,u){if(t=+t,r=+r,n=+n,u=!!u,n<0)throw new Error(`negative radius: ${n}`);let l=n*Math.cos(i),f=n*Math.sin(i),d=t+l,v=r+f,p=1^u,m=u?i-o:o-i;this._x1===null?this._append`M${d},${v}`:(Math.abs(this._x1-d)>Ni||Math.abs(this._y1-v)>Ni)&&this._append`L${d},${v}`,n&&(m<0&&(m=m%Dg+Dg),m>nF?this._append`A${n},${n},0,1,${p},${t-l},${r-f}A${n},${n},0,1,${p},${this._x1=d},${this._y1=v}`:m>Ni&&this._append`A${n},${n},0,${+(m>=Ig)},${p},${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 bb(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 aF(t)}function xb(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function JC(e){this._context=e}JC.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._context.lineTo(e,t);break}}};function Df(e){return new JC(e)}function ek(e){return e[0]}function tk(e){return e[1]}function rk(e,t){var r=Qe(!0),n=null,i=Df,o=null,u=bb(l);e=typeof e=="function"?e:e===void 0?ek:Qe(e),t=typeof t=="function"?t:t===void 0?tk:Qe(t);function l(f){var d,v=(f=xb(f)).length,p,m=!1,b;for(n==null&&(o=i(b=u())),d=0;d<=v;++d)!(d=b;--O)l.point(T[O],P[O]);l.lineEnd(),l.areaEnd()}E&&(T[m]=+e(g,m,p),P[m]=+t(g,m,p),l.point(n?+n(g,m,p):T[m],r?+r(g,m,p):P[m]))}if(A)return l=null,A+""||null}function v(){return rk().defined(i).curve(u).context(o)}return d.x=function(p){return arguments.length?(e=typeof p=="function"?p:Qe(+p),n=null,d):e},d.x0=function(p){return arguments.length?(e=typeof p=="function"?p:Qe(+p),d):e},d.x1=function(p){return arguments.length?(n=p==null?null:typeof p=="function"?p:Qe(+p),d):n},d.y=function(p){return arguments.length?(t=typeof p=="function"?p:Qe(+p),r=null,d):t},d.y0=function(p){return arguments.length?(t=typeof p=="function"?p:Qe(+p),d):t},d.y1=function(p){return arguments.length?(r=p==null?null:typeof p=="function"?p:Qe(+p),d):r},d.lineX0=d.lineY0=function(){return v().x(e).y(t)},d.lineY1=function(){return v().x(e).y(r)},d.lineX1=function(){return v().x(n).y(t)},d.defined=function(p){return arguments.length?(i=typeof p=="function"?p:Qe(!!p),d):i},d.curve=function(p){return arguments.length?(u=p,o!=null&&(l=u(o)),d):u},d.context=function(p){return arguments.length?(p==null?o=l=null:l=u(o=p),d):o},d}class nk{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 oF(e){return new nk(e,!0)}function sF(e){return new nk(e,!1)}const wb={draw(e,t){const r=Ur(t/bc);e.moveTo(r,0),e.arc(0,0,r,0,If)}},uF={draw(e,t){const r=Ur(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()}},ik=Ur(1/3),lF=ik*2,cF={draw(e,t){const r=Ur(t/lF),n=r*ik;e.moveTo(0,-r),e.lineTo(n,0),e.lineTo(0,r),e.lineTo(-n,0),e.closePath()}},fF={draw(e,t){const r=Ur(t),n=-r/2;e.rect(n,n,r,r)}},dF=.8908130915292852,ak=gc(bc/10)/gc(7*bc/10),pF=gc(If/10)*ak,hF=-QC(If/10)*ak,vF={draw(e,t){const r=Ur(t*dF),n=pF*r,i=hF*r;e.moveTo(0,-r),e.lineTo(n,i);for(let o=1;o<5;++o){const u=If*o/5,l=QC(u),f=gc(u);e.lineTo(f*r,-l*r),e.lineTo(l*n-f*i,f*n+l*i)}e.closePath()}},Nv=Ur(3),mF={draw(e,t){const r=-Ur(t/(Nv*3));e.moveTo(0,r*2),e.lineTo(-Nv*r,-r),e.lineTo(Nv*r,-r),e.closePath()}},yr=-.5,gr=Ur(3)/2,Lg=1/Ur(12),yF=(Lg/2+1)*3,gF={draw(e,t){const r=Ur(t/yF),n=r/2,i=r*Lg,o=n,u=r*Lg+r,l=-o,f=u;e.moveTo(n,i),e.lineTo(o,u),e.lineTo(l,f),e.lineTo(yr*n-gr*i,gr*n+yr*i),e.lineTo(yr*o-gr*u,gr*o+yr*u),e.lineTo(yr*l-gr*f,gr*l+yr*f),e.lineTo(yr*n+gr*i,yr*i-gr*n),e.lineTo(yr*o+gr*u,yr*u-gr*o),e.lineTo(yr*l+gr*f,yr*f-gr*l),e.closePath()}};function bF(e,t){let r=null,n=bb(i);e=typeof e=="function"?e:Qe(e||wb),t=typeof t=="function"?t:Qe(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:Qe(o),i):e},i.size=function(o){return arguments.length?(t=typeof o=="function"?o:Qe(+o),i):t},i.context=function(o){return arguments.length?(r=o??null,i):r},i}function xc(){}function wc(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 ok(e){this._context=e}ok.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:wc(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:wc(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function xF(e){return new ok(e)}function sk(e){this._context=e}sk.prototype={areaStart:xc,areaEnd:xc,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:wc(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function wF(e){return new sk(e)}function uk(e){this._context=e}uk.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:wc(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function SF(e){return new uk(e)}function lk(e){this._context=e}lk.prototype={areaStart:xc,areaEnd:xc,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 OF(e){return new lk(e)}function i_(e){return e<0?-1:1}function a_(e,t,r){var n=e._x1-e._x0,i=t-e._x1,o=(e._y1-e._y0)/(n||i<0&&-0),u=(r-e._y1)/(i||n<0&&-0),l=(o*i+u*n)/(n+i);return(i_(o)+i_(u))*Math.min(Math.abs(o),Math.abs(u),.5*Math.abs(l))||0}function o_(e,t){var r=e._x1-e._x0;return r?(3*(e._y1-e._y0)/r-t)/2:t}function Rv(e,t,r){var n=e._x0,i=e._y0,o=e._x1,u=e._y1,l=(o-n)/3;e._context.bezierCurveTo(n+l,i+l*t,o-l,u-l*r,o,u)}function Sc(e){this._context=e}Sc.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:Rv(this,this._t0,o_(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,Rv(this,o_(this,r=a_(this,e,t)),r);break;default:Rv(this,this._t0,r=a_(this,e,t));break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=r}}};function ck(e){this._context=new fk(e)}(ck.prototype=Object.create(Sc.prototype)).point=function(e,t){Sc.prototype.point.call(this,t,e)};function fk(e){this._context=e}fk.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 _F(e){return new Sc(e)}function PF(e){return new ck(e)}function dk(e){this._context=e}dk.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=s_(e),i=s_(t),o=0,u=1;u=0;--t)i[t]=(u[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 jF(e){return new Lf(e,.5)}function AF(e){return new Lf(e,0)}function TF(e){return new Lf(e,1)}function Ha(e,t){if((u=e.length)>1)for(var r=1,n,i,o=e[t[0]],u,l=o.length;r=0;)r[t]=t;return r}function CF(e,t){return e[t]}function kF(e){const t=[];return t.key=e,t}function NF(){var e=Qe([]),t=Bg,r=Ha,n=CF;function i(o){var u=Array.from(e.apply(this,arguments),kF),l,f=u.length,d=-1,v;for(const p of o)for(l=0,++d;l0){for(var r,n,i=0,o=e[0].length,u;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,u;n=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function qF(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}var pk={symbolCircle:wb,symbolCross:uF,symbolDiamond:cF,symbolSquare:fF,symbolStar:vF,symbolTriangle:mF,symbolWye:gF},zF=Math.PI/180,UF=function(t){var r="symbol".concat($f(t));return pk[r]||wb},WF=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*zF;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}},HF=function(t,r){pk["symbol".concat($f(t))]=r},Sb=function(t){var r=t.type,n=r===void 0?"circle":r,i=t.size,o=i===void 0?64:i,u=t.sizeType,l=u===void 0?"area":u,f=FF(t,IF),d=l_(l_({},f),{},{type:n,size:o,sizeType:l}),v=function(){var g=UF(n),E=bF().type(g).size(WF(o,l,n));return E()},p=d.className,m=d.cx,b=d.cy,O=Se(d,!0);return m===+m&&b===+b&&o===+o?I.createElement("path",Fg({},O,{className:Me("recharts-symbols",p),transform:"translate(".concat(m,", ").concat(b,")"),d:v()})):null};Sb.registerSymbol=HF;function Ka(e){"@babel/helpers - typeof";return Ka=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},Ka(e)}function qg(){return qg=Object.assign?Object.assign.bind():function(e){for(var t=1;t`);var A=b.inactive?d:b.color;return I.createElement("li",qg({className:g,style:p,key:"legend-item-".concat(O)},zi(n.props,b,O)),I.createElement(Mg,{width:u,height:u,viewBox:v,style:m},n.renderIcon(b)),I.createElement("span",{className:"recharts-legend-item-text",style:{color:A}},x?x(E,b,O):E))})}},{key:"render",value:function(){var n=this.props,i=n.payload,o=n.layout,u=n.align;if(!i||!i.length)return null;var l={padding:0,margin:0,textAlign:o==="horizontal"?u:"left"};return I.createElement("ul",{className:"recharts-default-legend",style:l},this.renderItems())}}])})(C.PureComponent);zs(Ob,"displayName","Legend");zs(Ob,"defaultProps",{iconSize:14,layout:"horizontal",align:"center",verticalAlign:"middle",inactiveColor:"#ccc"});var Mv,f_;function t3(){if(f_)return Mv;f_=1;var e=Nf();function t(){this.__data__=new e,this.size=0}return Mv=t,Mv}var $v,d_;function r3(){if(d_)return $v;d_=1;function e(t){var r=this.__data__,n=r.delete(t);return this.size=r.size,n}return $v=e,$v}var Iv,p_;function n3(){if(p_)return Iv;p_=1;function e(t){return this.__data__.get(t)}return Iv=e,Iv}var Dv,h_;function i3(){if(h_)return Dv;h_=1;function e(t){return this.__data__.has(t)}return Dv=e,Dv}var Lv,v_;function a3(){if(v_)return Lv;v_=1;var e=Nf(),t=pb(),r=hb(),n=200;function i(o,u){var l=this.__data__;if(l instanceof e){var f=l.__data__;if(!t||f.lengthb))return!1;var x=p.get(u),g=p.get(l);if(x&&g)return x==l&&g==u;var E=-1,A=!0,T=f&i?new e:void 0;for(p.set(u,l),p.set(l,u);++E-1&&n%1==0&&n-1&&r%1==0&&r<=e}return om=t,om}var sm,B_;function g3(){if(B_)return sm;B_=1;var e=Rn(),t=jb(),r=Mn(),n="[object Arguments]",i="[object Array]",o="[object Boolean]",u="[object Date]",l="[object Error]",f="[object Function]",d="[object Map]",v="[object Number]",p="[object Object]",m="[object RegExp]",b="[object Set]",O="[object String]",x="[object WeakMap]",g="[object ArrayBuffer]",E="[object DataView]",A="[object Float32Array]",T="[object Float64Array]",P="[object Int8Array]",_="[object Int16Array]",j="[object Int32Array]",N="[object Uint8Array]",R="[object Uint8ClampedArray]",D="[object Uint16Array]",W="[object Uint32Array]",B={};B[A]=B[T]=B[P]=B[_]=B[j]=B[N]=B[R]=B[D]=B[W]=!0,B[n]=B[i]=B[g]=B[o]=B[E]=B[u]=B[l]=B[f]=B[d]=B[v]=B[p]=B[m]=B[b]=B[O]=B[x]=!1;function M(z){return r(z)&&t(z.length)&&!!B[e(z)]}return sm=M,sm}var um,F_;function Ok(){if(F_)return um;F_=1;function e(t){return function(r){return t(r)}}return um=e,um}var js={exports:{}};js.exports;var q_;function b3(){return q_||(q_=1,(function(e,t){var r=UC(),n=t&&!t.nodeType&&t,i=n&&!0&&e&&!e.nodeType&&e,o=i&&i.exports===n,u=o&&r.process,l=(function(){try{var f=i&&i.require&&i.require("util").types;return f||u&&u.binding&&u.binding("util")}catch{}})();e.exports=l})(js,js.exports)),js.exports}var lm,z_;function _k(){if(z_)return lm;z_=1;var e=g3(),t=Ok(),r=b3(),n=r&&r.isTypedArray,i=n?t(n):e;return lm=i,lm}var cm,U_;function x3(){if(U_)return cm;U_=1;var e=v3(),t=Pb(),r=Jt(),n=Sk(),i=Eb(),o=_k(),u=Object.prototype,l=u.hasOwnProperty;function f(d,v){var p=r(d),m=!p&&t(d),b=!p&&!m&&n(d),O=!p&&!m&&!b&&o(d),x=p||m||b||O,g=x?e(d.length,String):[],E=g.length;for(var A in d)(v||l.call(d,A))&&!(x&&(A=="length"||b&&(A=="offset"||A=="parent")||O&&(A=="buffer"||A=="byteLength"||A=="byteOffset")||i(A,E)))&&g.push(A);return g}return cm=f,cm}var fm,W_;function w3(){if(W_)return fm;W_=1;var e=Object.prototype;function t(r){var n=r&&r.constructor,i=typeof n=="function"&&n.prototype||e;return r===i}return fm=t,fm}var dm,H_;function Pk(){if(H_)return dm;H_=1;function e(t,r){return function(n){return t(r(n))}}return dm=e,dm}var pm,K_;function S3(){if(K_)return pm;K_=1;var e=Pk(),t=e(Object.keys,Object);return pm=t,pm}var hm,V_;function O3(){if(V_)return hm;V_=1;var e=w3(),t=S3(),r=Object.prototype,n=r.hasOwnProperty;function i(o){if(!e(o))return t(o);var u=[];for(var l in Object(o))n.call(o,l)&&l!="constructor"&&u.push(l);return u}return hm=i,hm}var vm,G_;function Au(){if(G_)return vm;G_=1;var e=fb(),t=jb();function r(n){return n!=null&&t(n.length)&&!e(n)}return vm=r,vm}var mm,X_;function Bf(){if(X_)return mm;X_=1;var e=x3(),t=O3(),r=Au();function n(i){return r(i)?e(i):t(i)}return mm=n,mm}var ym,Y_;function _3(){if(Y_)return ym;Y_=1;var e=f3(),t=h3(),r=Bf();function n(i){return e(i,r,t)}return ym=n,ym}var gm,Q_;function P3(){if(Q_)return gm;Q_=1;var e=_3(),t=1,r=Object.prototype,n=r.hasOwnProperty;function i(o,u,l,f,d,v){var p=l&t,m=e(o),b=m.length,O=e(u),x=O.length;if(b!=x&&!p)return!1;for(var g=b;g--;){var E=m[g];if(!(p?E in u:n.call(u,E)))return!1}var A=v.get(o),T=v.get(u);if(A&&T)return A==u&&T==o;var P=!0;v.set(o,u),v.set(u,o);for(var _=p;++g-1}return Wm=t,Wm}var Hm,_P;function H3(){if(_P)return Hm;_P=1;function e(t,r,n){for(var i=-1,o=t==null?0:t.length;++i=u){var E=d?null:i(f);if(E)return o(E);O=!1,m=n,g=new e}else g=d?[]:x;e:for(;++p=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function oq(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function sq(e){return e.value}function uq(e,t){if(I.isValidElement(e))return I.cloneElement(e,t);if(typeof e=="function")return I.createElement(e,t);t.ref;var r=aq(t,Q3);return I.createElement(Ob,r)}var NP=1,_n=(function(e){function t(){var r;Z3(this,t);for(var n=arguments.length,i=new Array(n),o=0;oNP||Math.abs(i.height-this.lastBoundingBox.height)>NP)&&(this.lastBoundingBox.width=i.width,this.lastBoundingBox.height=i.height,n&&n(i)):(this.lastBoundingBox.width!==-1||this.lastBoundingBox.height!==-1)&&(this.lastBoundingBox.width=-1,this.lastBoundingBox.height=-1,n&&n(null))}},{key:"getBBoxSnapshot",value:function(){return this.lastBoundingBox.width>=0&&this.lastBoundingBox.height>=0?vn({},this.lastBoundingBox):{width:0,height:0}}},{key:"getDefaultPosition",value:function(n){var i=this.props,o=i.layout,u=i.align,l=i.verticalAlign,f=i.margin,d=i.chartWidth,v=i.chartHeight,p,m;if(!n||(n.left===void 0||n.left===null)&&(n.right===void 0||n.right===null))if(u==="center"&&o==="vertical"){var b=this.getBBoxSnapshot();p={left:((d||0)-b.width)/2}}else p=u==="right"?{right:f&&f.right||0}:{left:f&&f.left||0};if(!n||(n.top===void 0||n.top===null)&&(n.bottom===void 0||n.bottom===null))if(l==="middle"){var O=this.getBBoxSnapshot();m={top:((v||0)-O.height)/2}}else m=l==="bottom"?{bottom:f&&f.bottom||0}:{top:f&&f.top||0};return vn(vn({},p),m)}},{key:"render",value:function(){var n=this,i=this.props,o=i.content,u=i.width,l=i.height,f=i.wrapperStyle,d=i.payloadUniqBy,v=i.payload,p=vn(vn({position:"absolute",width:u||"auto",height:l||"auto"},this.getDefaultPosition(f)),f);return I.createElement("div",{className:"recharts-legend-wrapper",style:p,ref:function(b){n.wrapperNode=b}},uq(o,vn(vn({},this.props),{},{payload:Ck(v,d,sq)})))}}],[{key:"getWithHeight",value:function(n,i){var o=vn(vn({},this.defaultProps),n.props),u=o.layout;return u==="vertical"&&le(n.props.height)?{height:n.props.height}:u==="horizontal"?{width:n.props.width||i}:null}}])})(C.PureComponent);Ff(_n,"displayName","Legend");Ff(_n,"defaultProps",{iconSize:14,layout:"horizontal",align:"center",verticalAlign:"bottom"});var Ym,RP;function lq(){if(RP)return Ym;RP=1;var e=Eu(),t=Pb(),r=Jt(),n=e?e.isConcatSpreadable:void 0;function i(o){return r(o)||t(o)||!!(n&&o&&o[n])}return Ym=i,Ym}var Qm,MP;function Rk(){if(MP)return Qm;MP=1;var e=wk(),t=lq();function r(n,i,o,u,l){var f=-1,d=n.length;for(o||(o=t),l||(l=[]);++f0&&o(v)?i>1?r(v,i-1,o,u,l):e(l,v):u||(l[l.length]=v)}return l}return Qm=r,Qm}var Zm,$P;function cq(){if($P)return Zm;$P=1;function e(t){return function(r,n,i){for(var o=-1,u=Object(r),l=i(r),f=l.length;f--;){var d=l[t?f:++o];if(n(u[d],d,u)===!1)break}return r}}return Zm=e,Zm}var Jm,IP;function fq(){if(IP)return Jm;IP=1;var e=cq(),t=e();return Jm=t,Jm}var ey,DP;function Mk(){if(DP)return ey;DP=1;var e=fq(),t=Bf();function r(n,i){return n&&e(n,i,t)}return ey=r,ey}var ty,LP;function dq(){if(LP)return ty;LP=1;var e=Au();function t(r,n){return function(i,o){if(i==null)return i;if(!e(i))return r(i,o);for(var u=i.length,l=n?u:-1,f=Object(i);(n?l--:++ln||l&&f&&v&&!d&&!p||o&&f&&v||!i&&v||!u)return 1;if(!o&&!l&&!p&&r=d)return v;var p=i[o];return v*(p=="desc"?-1:1)}}return r.index-n.index}return oy=t,oy}var sy,WP;function mq(){if(WP)return sy;WP=1;var e=vb(),t=mb(),r=an(),n=$k(),i=pq(),o=Ok(),u=vq(),l=Oo(),f=Jt();function d(v,p,m){p.length?p=e(p,function(x){return f(x)?function(g){return t(g,x.length===1?x[0]:x)}:x}):p=[l];var b=-1;p=e(p,o(r));var O=n(v,function(x,g,E){var A=e(p,function(T){return T(x)});return{criteria:A,index:++b,value:x}});return i(O,function(x,g){return u(x,g,m)})}return sy=d,sy}var uy,HP;function yq(){if(HP)return uy;HP=1;function e(t,r,n){switch(n.length){case 0:return t.call(r);case 1:return t.call(r,n[0]);case 2:return t.call(r,n[0],n[1]);case 3:return t.call(r,n[0],n[1],n[2])}return t.apply(r,n)}return uy=e,uy}var ly,KP;function gq(){if(KP)return ly;KP=1;var e=yq(),t=Math.max;function r(n,i,o){return i=t(i===void 0?n.length-1:i,0),function(){for(var u=arguments,l=-1,f=t(u.length-i,0),d=Array(f);++l0){if(++o>=e)return arguments[0]}else o=0;return i.apply(void 0,arguments)}}return py=n,py}var hy,QP;function Sq(){if(QP)return hy;QP=1;var e=xq(),t=wq(),r=t(e);return hy=r,hy}var vy,ZP;function Oq(){if(ZP)return vy;ZP=1;var e=Oo(),t=gq(),r=Sq();function n(i,o){return r(t(i,o,e),i+"")}return vy=n,vy}var my,JP;function qf(){if(JP)return my;JP=1;var e=db(),t=Au(),r=Eb(),n=ci();function i(o,u,l){if(!n(l))return!1;var f=typeof u;return(f=="number"?t(l)&&r(u,l.length):f=="string"&&u in l)?e(l[u],o):!1}return my=i,my}var yy,eE;function _q(){if(eE)return yy;eE=1;var e=Rk(),t=mq(),r=Oq(),n=qf(),i=r(function(o,u){if(o==null)return[];var l=u.length;return l>1&&n(o,u[0],u[1])?u=[]:l>2&&n(u[0],u[1],u[2])&&(u=[u[0]]),t(o,e(u,1),[])});return yy=i,yy}var Pq=_q();const Cb=Ue(Pq);function Us(e){"@babel/helpers - typeof";return Us=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},Us(e)}function Wg(){return Wg=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=t.x),"".concat(ms,"-left"),le(r)&&t&&le(t.x)&&r=t.y),"".concat(ms,"-top"),le(n)&&t&&le(t.y)&&nx?Math.max(v,f[n]):Math.max(p,f[n])}function Fq(e){var t=e.translateX,r=e.translateY,n=e.useTranslate3d;return{transform:n?"translate3d(".concat(t,"px, ").concat(r,"px, 0)"):"translate(".concat(t,"px, ").concat(r,"px)")}}function qq(e){var t=e.allowEscapeViewBox,r=e.coordinate,n=e.offsetTopLeft,i=e.position,o=e.reverseDirection,u=e.tooltipBox,l=e.useTranslate3d,f=e.viewBox,d,v,p;return u.height>0&&u.width>0&&r?(v=nE({allowEscapeViewBox:t,coordinate:r,key:"x",offsetTopLeft:n,position:i,reverseDirection:o,tooltipDimension:u.width,viewBox:f,viewBoxDimension:f.width}),p=nE({allowEscapeViewBox:t,coordinate:r,key:"y",offsetTopLeft:n,position:i,reverseDirection:o,tooltipDimension:u.height,viewBox:f,viewBoxDimension:f.height}),d=Fq({translateX:v,translateY:p,useTranslate3d:l})):d=Lq,{cssProperties:d,cssClasses:Bq({translateX:v,translateY:p,coordinate:r})}}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 iE(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 aE(e){for(var t=1;toE||Math.abs(n.height-this.state.lastBoundingBox.height)>oE)&&this.setState({lastBoundingBox:{width:n.width,height:n.height}})}else(this.state.lastBoundingBox.width!==-1||this.state.lastBoundingBox.height!==-1)&&this.setState({lastBoundingBox:{width:-1,height:-1}})}},{key:"componentDidMount",value:function(){document.addEventListener("keydown",this.handleKeyDown),this.updateBBox()}},{key:"componentWillUnmount",value:function(){document.removeEventListener("keydown",this.handleKeyDown)}},{key:"componentDidUpdate",value:function(){var n,i;this.props.active&&this.updateBBox(),this.state.dismissed&&(((n=this.props.coordinate)===null||n===void 0?void 0:n.x)!==this.state.dismissedAtCoordinate.x||((i=this.props.coordinate)===null||i===void 0?void 0:i.y)!==this.state.dismissedAtCoordinate.y)&&(this.state.dismissed=!1)}},{key:"render",value:function(){var n=this,i=this.props,o=i.active,u=i.allowEscapeViewBox,l=i.animationDuration,f=i.animationEasing,d=i.children,v=i.coordinate,p=i.hasPayload,m=i.isAnimationActive,b=i.offset,O=i.position,x=i.reverseDirection,g=i.useTranslate3d,E=i.viewBox,A=i.wrapperStyle,T=qq({allowEscapeViewBox:u,coordinate:v,offsetTopLeft:b,position:O,reverseDirection:x,tooltipBox:this.state.lastBoundingBox,useTranslate3d:g,viewBox:E}),P=T.cssClasses,_=T.cssProperties,j=aE(aE({transition:m&&o?"transform ".concat(l,"ms ").concat(f):void 0},_),{},{pointerEvents:"none",visibility:!this.state.dismissed&&o&&p?"visible":"hidden",position:"absolute",top:0,left:0},A);return I.createElement("div",{tabIndex:-1,className:P,style:j,ref:function(R){n.wrapperNode=R}},d)}}])})(C.PureComponent),Qq=function(){return!(typeof window<"u"&&window.document&&window.document.createElement&&window.setTimeout)},Yi={isSsr:Qq()};function Xa(e){"@babel/helpers - typeof";return Xa=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},Xa(e)}function sE(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 uE(e){for(var t=1;t0;return I.createElement(Yq,{allowEscapeViewBox:u,animationDuration:l,animationEasing:f,isAnimationActive:m,active:o,coordinate:v,hasPayload:j,offset:b,position:g,reverseDirection:E,useTranslate3d:A,viewBox:T,wrapperStyle:P},sz(d,uE(uE({},this.props),{},{payload:_})))}}])})(C.PureComponent);kb(Qt,"displayName","Tooltip");kb(Qt,"defaultProps",{accessibilityLayer:!1,allowEscapeViewBox:{x:!1,y:!1},animationDuration:400,animationEasing:"ease",contentStyle:{},coordinate:{x:0,y:0},cursor:!0,cursorStyle:{},filterNull:!0,isAnimationActive:!Yi.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 by,lE;function uz(){if(lE)return by;lE=1;var e=nn(),t=function(){return e.Date.now()};return by=t,by}var xy,cE;function lz(){if(cE)return xy;cE=1;var e=/\s/;function t(r){for(var n=r.length;n--&&e.test(r.charAt(n)););return n}return xy=t,xy}var wy,fE;function cz(){if(fE)return wy;fE=1;var e=lz(),t=/^\s+/;function r(n){return n&&n.slice(0,e(n)+1).replace(t,"")}return wy=r,wy}var Sy,dE;function qk(){if(dE)return Sy;dE=1;var e=cz(),t=ci(),r=xo(),n=NaN,i=/^[-+]0x[0-9a-f]+$/i,o=/^0b[01]+$/i,u=/^0o[0-7]+$/i,l=parseInt;function f(d){if(typeof d=="number")return d;if(r(d))return n;if(t(d)){var v=typeof d.valueOf=="function"?d.valueOf():d;d=t(v)?v+"":v}if(typeof d!="string")return d===0?d:+d;d=e(d);var p=o.test(d);return p||u.test(d)?l(d.slice(2),p?2:8):i.test(d)?n:+d}return Sy=f,Sy}var Oy,pE;function fz(){if(pE)return Oy;pE=1;var e=ci(),t=uz(),r=qk(),n="Expected a function",i=Math.max,o=Math.min;function u(l,f,d){var v,p,m,b,O,x,g=0,E=!1,A=!1,T=!0;if(typeof l!="function")throw new TypeError(n);f=r(f)||0,e(d)&&(E=!!d.leading,A="maxWait"in d,m=A?i(r(d.maxWait)||0,f):m,T="trailing"in d?!!d.trailing:T);function P(z){var G=v,V=p;return v=p=void 0,g=z,b=l.apply(V,G),b}function _(z){return g=z,O=setTimeout(R,f),E?P(z):b}function j(z){var G=z-x,V=z-g,Y=f-G;return A?o(Y,m-V):Y}function N(z){var G=z-x,V=z-g;return x===void 0||G>=f||G<0||A&&V>=m}function R(){var z=t();if(N(z))return D(z);O=setTimeout(R,j(z))}function D(z){return O=void 0,T&&v?P(z):(v=p=void 0,b)}function W(){O!==void 0&&clearTimeout(O),g=0,v=x=p=O=void 0}function B(){return O===void 0?b:D(t())}function M(){var z=t(),G=N(z);if(v=arguments,p=this,x=z,G){if(O===void 0)return _(x);if(A)return clearTimeout(O),O=setTimeout(R,f),P(x)}return O===void 0&&(O=setTimeout(R,f)),b}return M.cancel=W,M.flush=B,M}return Oy=u,Oy}var _y,hE;function dz(){if(hE)return _y;hE=1;var e=fz(),t=ci(),r="Expected a function";function n(i,o,u){var l=!0,f=!0;if(typeof i!="function")throw new TypeError(r);return t(u)&&(l="leading"in u?!!u.leading:l,f="trailing"in u?!!u.trailing:f),e(i,o,{leading:l,maxWait:o,trailing:f})}return _y=n,_y}var pz=dz();const zk=Ue(pz);function Hs(e){"@babel/helpers - typeof";return Hs=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},Hs(e)}function vE(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 Jl(e){for(var t=1;te.length)&&(t=e.length);for(var r=0,n=new Array(t);r0&&(z=zk(z,x,{trailing:!0,leading:!1}));var G=new ResizeObserver(z),V=_.current.getBoundingClientRect(),Y=V.width,J=V.height;return B(Y,J),G.observe(_.current),function(){G.disconnect()}},[B,x]);var M=C.useMemo(function(){var z=D.containerWidth,G=D.containerHeight;if(z<0||G<0)return null;qr($i(u)||$i(f),`The width(%s) and height(%s) are both fixed numbers, maybe you don't need to use a ResponsiveContainer.`,u,f),qr(!r||r>0,"The aspect(%s) must be greater than zero.",r);var V=$i(u)?z:u,Y=$i(f)?G:f;r&&r>0&&(V?Y=V/r:Y&&(V=Y*r),m&&Y>m&&(Y=m)),qr(V>0||Y>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.`,V,Y,u,f,v,p,r);var J=!Array.isArray(b)&&On(b.type).endsWith("Chart");return I.Children.map(b,function(H){return I.isValidElement(H)?C.cloneElement(H,Jl({width:V,height:Y},J?{style:Jl({height:"100%",width:"100%",maxHeight:Y,maxWidth:V},H.props.style)}:{})):H})},[r,b,f,m,p,v,D,u]);return I.createElement("div",{id:g?"".concat(g):void 0,className:Me("recharts-responsive-container",E),style:Jl(Jl({},P),{},{width:u,height:f,minWidth:v,minHeight:p,maxHeight:m}),ref:_},M)}),Tu=function(t){return null};Tu.displayName="Cell";function Vs(e){"@babel/helpers - typeof";return Vs=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},Vs(e)}function yE(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 Gg(e){for(var t=1;t1&&arguments[1]!==void 0?arguments[1]:{};if(t==null||Yi.isSsr)return{width:0,height:0};var n=jz(r),i=JSON.stringify({text:t,copyStyle:n});if(Ta.widthCache[i])return Ta.widthCache[i];try{var o=document.getElementById(gE);o||(o=document.createElement("span"),o.setAttribute("id",gE),o.setAttribute("aria-hidden","true"),document.body.appendChild(o));var u=Gg(Gg({},Ez),n);Object.assign(o.style,u),o.textContent="".concat(t);var l=o.getBoundingClientRect(),f={width:l.width,height:l.height};return Ta.widthCache[i]=f,++Ta.cacheCount>Pz&&(Ta.cacheCount=0,Ta.widthCache={}),f}catch{return{width:0,height:0}}},Az=function(t){return{top:t.top+window.scrollY-document.documentElement.clientTop,left:t.left+window.scrollX-document.documentElement.clientLeft}};function Gs(e){"@babel/helpers - typeof";return Gs=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},Gs(e)}function jc(e,t){return Nz(e)||kz(e,t)||Cz(e,t)||Tz()}function Tz(){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 Cz(e,t){if(e){if(typeof e=="string")return bE(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 bE(e,t)}}function bE(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 Kz(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function PE(e,t){return Yz(e)||Xz(e,t)||Gz(e,t)||Vz()}function Vz(){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 Gz(e,t){if(e){if(typeof e=="string")return EE(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 EE(e,t)}}function EE(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 V.reduce(function(Y,J){var H=J.word,ee=J.width,Z=Y[Y.length-1];if(Z&&(i==null||o||Z.width+ee+nJ.width?Y:J})};if(!v)return b;for(var x="…",g=function(V){var Y=p.slice(0,V),J=Kk({breakAll:d,style:f,children:Y+x}).wordsWithComputedWidth,H=m(J),ee=H.length>u||O(H).width>Number(i);return[ee,H]},E=0,A=p.length-1,T=0,P;E<=A&&T<=p.length-1;){var _=Math.floor((E+A)/2),j=_-1,N=g(j),R=PE(N,2),D=R[0],W=R[1],B=g(_),M=PE(B,1),z=M[0];if(!D&&!z&&(E=_+1),D&&z&&(A=_-1),!D&&z){P=W;break}T++}return P||b},jE=function(t){var r=ke(t)?[]:t.toString().split(Hk);return[{words:r}]},Zz=function(t){var r=t.width,n=t.scaleToFit,i=t.children,o=t.style,u=t.breakAll,l=t.maxLines;if((r||n)&&!Yi.isSsr){var f,d,v=Kk({breakAll:u,children:i,style:o});if(v){var p=v.wordsWithComputedWidth,m=v.spaceWidth;f=p,d=m}else return jE(i);return Qz({breakAll:u,children:i,maxLines:l,style:o},f,d,r,n)}return jE(i)},AE="#808080",Ui=function(t){var r=t.x,n=r===void 0?0:r,i=t.y,o=i===void 0?0:i,u=t.lineHeight,l=u===void 0?"1em":u,f=t.capHeight,d=f===void 0?"0.71em":f,v=t.scaleToFit,p=v===void 0?!1:v,m=t.textAnchor,b=m===void 0?"start":m,O=t.verticalAnchor,x=O===void 0?"end":O,g=t.fill,E=g===void 0?AE:g,A=_E(t,Wz),T=C.useMemo(function(){return Zz({breakAll:A.breakAll,children:A.children,maxLines:A.maxLines,scaleToFit:p,style:A.style,width:A.width})},[A.breakAll,A.children,A.maxLines,p,A.style,A.width]),P=A.dx,_=A.dy,j=A.angle,N=A.className,R=A.breakAll,D=_E(A,Hz);if(!wt(n)||!wt(o))return null;var W=n+(le(P)?P:0),B=o+(le(_)?_:0),M;switch(x){case"start":M=Py("calc(".concat(d,")"));break;case"middle":M=Py("calc(".concat((T.length-1)/2," * -").concat(l," + (").concat(d," / 2))"));break;default:M=Py("calc(".concat(T.length-1," * -").concat(l,")"));break}var z=[];if(p){var G=T[0].width,V=A.width;z.push("scale(".concat((le(V)?V/G:1)/G,")"))}return j&&z.push("rotate(".concat(j,", ").concat(W,", ").concat(B,")")),z.length&&(D.transform=z.join(" ")),I.createElement("text",Xg({},Se(D,!0),{x:W,y:B,className:Me("recharts-text",N),textAnchor:b,fill:E.includes("url")?AE:E}),T.map(function(Y,J){var H=Y.words.join(R?"":" ");return I.createElement("tspan",{x:W,dy:J===0?M:l,key:"".concat(H,"-").concat(J)},H)}))};function si(e,t){return e==null||t==null?NaN:et?1:e>=t?0:NaN}function Jz(e,t){return e==null||t==null?NaN:te?1:t>=e?0:NaN}function Nb(e){let t,r,n;e.length!==2?(t=si,r=(l,f)=>si(e(l),f),n=(l,f)=>e(l)-f):(t=e===si||e===Jz?e:eU,r=e,n=e);function i(l,f,d=0,v=l.length){if(d>>1;r(l[p],f)<0?d=p+1:v=p}while(d>>1;r(l[p],f)<=0?d=p+1:v=p}while(dd&&n(l[p-1],f)>-n(l[p],f)?p-1:p}return{left:i,center:u,right:o}}function eU(){return 0}function Vk(e){return e===null?NaN:+e}function*tU(e,t){for(let r of e)r!=null&&(r=+r)>=r&&(yield r)}const rU=Nb(si),Cu=rU.right;Nb(Vk).center;class TE extends Map{constructor(t,r=aU){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(CE(this,t))}has(t){return super.has(CE(this,t))}set(t,r){return super.set(nU(this,t),r)}delete(t){return super.delete(iU(this,t))}}function CE({_intern:e,_key:t},r){const n=t(r);return e.has(n)?e.get(n):r}function nU({_intern:e,_key:t},r){const n=t(r);return e.has(n)?e.get(n):(e.set(n,r),r)}function iU({_intern:e,_key:t},r){const n=t(r);return e.has(n)&&(r=e.get(n),e.delete(n)),r}function aU(e){return e!==null&&typeof e=="object"?e.valueOf():e}function oU(e=si){if(e===si)return Gk;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 Gk(e,t){return(e==null||!(e>=e))-(t==null||!(t>=t))||(et?1:0)}const sU=Math.sqrt(50),uU=Math.sqrt(10),lU=Math.sqrt(2);function Ac(e,t,r){const n=(t-e)/Math.max(0,r),i=Math.floor(Math.log10(n)),o=n/Math.pow(10,i),u=o>=sU?10:o>=uU?5:o>=lU?2:1;let l,f,d;return i<0?(d=Math.pow(10,-i)/u,l=Math.round(e*d),f=Math.round(t*d),l/dt&&--f,d=-d):(d=Math.pow(10,i)*u,l=Math.round(e/d),f=Math.round(t/d),l*dt&&--f),f0))return[];if(e===t)return[e];const n=t=i))return[];const l=o-i+1,f=new Array(l);if(n)if(u<0)for(let d=0;d=n)&&(r=n);return r}function NE(e,t){let r;for(const n of e)n!=null&&(r>n||r===void 0&&n>=n)&&(r=n);return r}function Xk(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?Gk:oU(i);n>r;){if(n-r>600){const f=n-r+1,d=t-r+1,v=Math.log(f),p=.5*Math.exp(2*v/3),m=.5*Math.sqrt(v*p*(f-p)/f)*(d-f/2<0?-1:1),b=Math.max(r,Math.floor(t-d*p/f+m)),O=Math.min(n,Math.floor(t+(f-d)*p/f+m));Xk(e,t,b,O,i)}const o=e[t];let u=r,l=n;for(ys(e,r,t),i(e[n],o)>0&&ys(e,r,n);u0;)--l}i(e[r],o)===0?ys(e,r,l):(++l,ys(e,l,n)),l<=t&&(r=l+1),t<=l&&(n=l-1)}return e}function ys(e,t,r){const n=e[t];e[t]=e[r],e[r]=n}function cU(e,t,r){if(e=Float64Array.from(tU(e)),!(!(n=e.length)||isNaN(t=+t))){if(t<=0||n<2)return NE(e);if(t>=1)return kE(e);var n,i=(n-1)*t,o=Math.floor(i),u=kE(Xk(e,o).subarray(0,o+1)),l=NE(e.subarray(o+1));return u+(l-u)*(i-o)}}function fU(e,t,r=Vk){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),u=+r(e[o],o,e),l=+r(e[o+1],o+1,e);return u+(l-u)*(i-o)}}function dU(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?tc(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):r===4?tc(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=hU.exec(e))?new Zt(t[1],t[2],t[3],1):(t=vU.exec(e))?new Zt(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=mU.exec(e))?tc(t[1],t[2],t[3],t[4]):(t=yU.exec(e))?tc(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=gU.exec(e))?BE(t[1],t[2]/100,t[3]/100,1):(t=bU.exec(e))?BE(t[1],t[2]/100,t[3]/100,t[4]):RE.hasOwnProperty(e)?IE(RE[e]):e==="transparent"?new Zt(NaN,NaN,NaN,0):null}function IE(e){return new Zt(e>>16&255,e>>8&255,e&255,1)}function tc(e,t,r,n){return n<=0&&(e=t=r=NaN),new Zt(e,t,r,n)}function SU(e){return e instanceof ku||(e=Zs(e)),e?(e=e.rgb(),new Zt(e.r,e.g,e.b,e.opacity)):new Zt}function e0(e,t,r,n){return arguments.length===1?SU(e):new Zt(e,t,r,n??1)}function Zt(e,t,r,n){this.r=+e,this.g=+t,this.b=+r,this.opacity=+n}Mb(Zt,e0,Qk(ku,{brighter(e){return e=e==null?Tc:Math.pow(Tc,e),new Zt(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?Ys:Math.pow(Ys,e),new Zt(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new Zt(Bi(this.r),Bi(this.g),Bi(this.b),Cc(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:DE,formatHex:DE,formatHex8:OU,formatRgb:LE,toString:LE}));function DE(){return`#${Ii(this.r)}${Ii(this.g)}${Ii(this.b)}`}function OU(){return`#${Ii(this.r)}${Ii(this.g)}${Ii(this.b)}${Ii((isNaN(this.opacity)?1:this.opacity)*255)}`}function LE(){const e=Cc(this.opacity);return`${e===1?"rgb(":"rgba("}${Bi(this.r)}, ${Bi(this.g)}, ${Bi(this.b)}${e===1?")":`, ${e})`}`}function Cc(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function Bi(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function Ii(e){return e=Bi(e),(e<16?"0":"")+e.toString(16)}function BE(e,t,r,n){return n<=0?e=t=r=NaN:r<=0||r>=1?e=t=NaN:t<=0&&(e=NaN),new Fr(e,t,r,n)}function Zk(e){if(e instanceof Fr)return new Fr(e.h,e.s,e.l,e.opacity);if(e instanceof ku||(e=Zs(e)),!e)return new Fr;if(e instanceof Fr)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),u=NaN,l=o-i,f=(o+i)/2;return l?(t===o?u=(r-n)/l+(r0&&f<1?0:u,new Fr(u,l,f,e.opacity)}function _U(e,t,r,n){return arguments.length===1?Zk(e):new Fr(e,t,r,n??1)}function Fr(e,t,r,n){this.h=+e,this.s=+t,this.l=+r,this.opacity=+n}Mb(Fr,_U,Qk(ku,{brighter(e){return e=e==null?Tc:Math.pow(Tc,e),new Fr(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?Ys:Math.pow(Ys,e),new Fr(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 Zt(Ey(e>=240?e-240:e+120,i,n),Ey(e,i,n),Ey(e<120?e+240:e-120,i,n),this.opacity)},clamp(){return new Fr(FE(this.h),rc(this.s),rc(this.l),Cc(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=Cc(this.opacity);return`${e===1?"hsl(":"hsla("}${FE(this.h)}, ${rc(this.s)*100}%, ${rc(this.l)*100}%${e===1?")":`, ${e})`}`}}));function FE(e){return e=(e||0)%360,e<0?e+360:e}function rc(e){return Math.max(0,Math.min(1,e||0))}function Ey(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 $b=e=>()=>e;function PU(e,t){return function(r){return e+r*t}}function EU(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 jU(e){return(e=+e)==1?Jk:function(t,r){return r-t?EU(t,r,e):$b(isNaN(t)?r:t)}}function Jk(e,t){var r=t-e;return r?PU(e,r):$b(isNaN(e)?t:e)}const qE=(function e(t){var r=jU(t);function n(i,o){var u=r((i=e0(i)).r,(o=e0(o)).r),l=r(i.g,o.g),f=r(i.b,o.b),d=Jk(i.opacity,o.opacity);return function(v){return i.r=u(v),i.g=l(v),i.b=f(v),i.opacity=d(v),i+""}}return n.gamma=e,n})(1);function AU(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),l[u]?l[u]+=o:l[++u]=o),(n=n[0])===(i=i[0])?l[u]?l[u]+=i:l[++u]=i:(l[++u]=null,f.push({i:u,x:kc(n,i)})),r=jy.lastIndex;return rt&&(r=e,e=t,t=r),function(n){return Math.max(e,Math.min(t,n))}}function BU(e,t,r){var n=e[0],i=e[1],o=t[0],u=t[1];return i2?FU:BU,f=d=null,p}function p(m){return m==null||isNaN(m=+m)?o:(f||(f=l(e.map(n),t,r)))(n(u(m)))}return p.invert=function(m){return u(i((d||(d=l(t,e.map(n),kc)))(m)))},p.domain=function(m){return arguments.length?(e=Array.from(m,Nc),v()):e.slice()},p.range=function(m){return arguments.length?(t=Array.from(m),v()):t.slice()},p.rangeRound=function(m){return t=Array.from(m),r=Ib,v()},p.clamp=function(m){return arguments.length?(u=m?!0:Ut,v()):u!==Ut},p.interpolate=function(m){return arguments.length?(r=m,v()):r},p.unknown=function(m){return arguments.length?(o=m,p):o},function(m,b){return n=m,i=b,v()}}function Db(){return zf()(Ut,Ut)}function qU(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function Rc(e,t){if(!isFinite(e)||e===0)return null;var r=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"),n=e.slice(0,r);return[n.length>1?n[0]+n.slice(2):n,+e.slice(r+1)]}function Ya(e){return e=Rc(Math.abs(e)),e?e[1]:NaN}function zU(e,t){return function(r,n){for(var i=r.length,o=[],u=0,l=e[0],f=0;i>0&&l>0&&(f+l+1>n&&(l=Math.max(1,n-f)),o.push(r.substring(i-=l,i+l)),!((f+=l+1)>n));)l=e[u=(u+1)%e.length];return o.reverse().join(t)}}function UU(e){return function(t){return t.replace(/[0-9]/g,function(r){return e[+r]})}}var WU=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function Js(e){if(!(t=WU.exec(e)))throw new Error("invalid format: "+e);var t;return new Lb({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]})}Js.prototype=Lb.prototype;function Lb(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+""}Lb.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 HU(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 Mc;function KU(e,t){var r=Rc(e,t);if(!r)return Mc=void 0,e.toPrecision(t);var n=r[0],i=r[1],o=i-(Mc=Math.max(-8,Math.min(8,Math.floor(i/3)))*3)+1,u=n.length;return o===u?n:o>u?n+new Array(o-u+1).join("0"):o>0?n.slice(0,o)+"."+n.slice(o):"0."+new Array(1-o).join("0")+Rc(e,Math.max(0,t+o-1))[0]}function UE(e,t){var r=Rc(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 WE={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:qU,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)=>UE(e*100,t),r:UE,s:KU,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function HE(e){return e}var KE=Array.prototype.map,VE=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function VU(e){var t=e.grouping===void 0||e.thousands===void 0?HE:zU(KE.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?HE:UU(KE.call(e.numerals,String)),u=e.percent===void 0?"%":e.percent+"",l=e.minus===void 0?"−":e.minus+"",f=e.nan===void 0?"NaN":e.nan+"";function d(p,m){p=Js(p);var b=p.fill,O=p.align,x=p.sign,g=p.symbol,E=p.zero,A=p.width,T=p.comma,P=p.precision,_=p.trim,j=p.type;j==="n"?(T=!0,j="g"):WE[j]||(P===void 0&&(P=12),_=!0,j="g"),(E||b==="0"&&O==="=")&&(E=!0,b="0",O="=");var N=(m&&m.prefix!==void 0?m.prefix:"")+(g==="$"?r:g==="#"&&/[boxX]/.test(j)?"0"+j.toLowerCase():""),R=(g==="$"?n:/[%p]/.test(j)?u:"")+(m&&m.suffix!==void 0?m.suffix:""),D=WE[j],W=/[defgprs%]/.test(j);P=P===void 0?6:/[gprs]/.test(j)?Math.max(1,Math.min(21,P)):Math.max(0,Math.min(20,P));function B(M){var z=N,G=R,V,Y,J;if(j==="c")G=D(M)+G,M="";else{M=+M;var H=M<0||1/M<0;if(M=isNaN(M)?f:D(Math.abs(M),P),_&&(M=HU(M)),H&&+M==0&&x!=="+"&&(H=!1),z=(H?x==="("?x:l:x==="-"||x==="("?"":x)+z,G=(j==="s"&&!isNaN(M)&&Mc!==void 0?VE[8+Mc/3]:"")+G+(H&&x==="("?")":""),W){for(V=-1,Y=M.length;++VJ||J>57){G=(J===46?i+M.slice(V+1):M.slice(V))+G,M=M.slice(0,V);break}}}T&&!E&&(M=t(M,1/0));var ee=z.length+M.length+G.length,Z=ee>1)+z+M+G+Z.slice(ee);break;default:M=Z+z+M+G;break}return o(M)}return B.toString=function(){return p+""},B}function v(p,m){var b=Math.max(-8,Math.min(8,Math.floor(Ya(m)/3)))*3,O=Math.pow(10,-b),x=d((p=Js(p),p.type="f",p),{suffix:VE[8+b/3]});return function(g){return x(O*g)}}return{format:d,formatPrefix:v}}var nc,Bb,eN;GU({thousands:",",grouping:[3],currency:["$",""]});function GU(e){return nc=VU(e),Bb=nc.format,eN=nc.formatPrefix,nc}function XU(e){return Math.max(0,-Ya(Math.abs(e)))}function YU(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(Ya(t)/3)))*3-Ya(Math.abs(e)))}function QU(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,Ya(t)-Ya(e))+1}function tN(e,t,r,n){var i=Zg(e,t,r),o;switch(n=Js(n??",f"),n.type){case"s":{var u=Math.max(Math.abs(e),Math.abs(t));return n.precision==null&&!isNaN(o=YU(i,u))&&(n.precision=o),eN(n,u)}case"":case"e":case"g":case"p":case"r":{n.precision==null&&!isNaN(o=QU(i,Math.max(Math.abs(e),Math.abs(t))))&&(n.precision=o-(n.type==="e"));break}case"f":case"%":{n.precision==null&&!isNaN(o=XU(i))&&(n.precision=o-(n.type==="%")*2);break}}return Bb(n)}function fi(e){var t=e.domain;return e.ticks=function(r){var n=t();return Yg(n[0],n[n.length-1],r??10)},e.tickFormat=function(r,n){var i=t();return tN(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,u=n[i],l=n[o],f,d,v=10;for(l0;){if(d=Qg(u,l,r),d===f)return n[i]=u,n[o]=l,t(n);if(d>0)u=Math.floor(u/d)*d,l=Math.ceil(l/d)*d;else if(d<0)u=Math.ceil(u*d)/d,l=Math.floor(l*d)/d;else break;f=d}return e},e}function $c(){var e=Db();return e.copy=function(){return Nu(e,$c())},Pr.apply(e,arguments),fi(e)}function rN(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,Nc),r):e.slice()},r.unknown=function(n){return arguments.length?(t=n,r):t},r.copy=function(){return rN(e).unknown(t)},e=arguments.length?Array.from(e,Nc):[0,1],fi(r)}function nN(e,t){e=e.slice();var r=0,n=e.length-1,i=e[r],o=e[n],u;return oMath.pow(e,t)}function r4(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 YE(e){return(t,r)=>-e(-t,r)}function Fb(e){const t=e(GE,XE),r=t.domain;let n=10,i,o;function u(){return i=r4(n),o=t4(n),r()[0]<0?(i=YE(i),o=YE(o),e(ZU,JU)):e(GE,XE),t}return t.base=function(l){return arguments.length?(n=+l,u()):n},t.domain=function(l){return arguments.length?(r(l),u()):r()},t.ticks=l=>{const f=r();let d=f[0],v=f[f.length-1];const p=v0){for(;m<=b;++m)for(O=1;Ov)break;E.push(x)}}else for(;m<=b;++m)for(O=n-1;O>=1;--O)if(x=m>0?O/o(-m):O*o(m),!(xv)break;E.push(x)}E.length*2{if(l==null&&(l=10),f==null&&(f=n===10?"s":","),typeof f!="function"&&(!(n%1)&&(f=Js(f)).precision==null&&(f.trim=!0),f=Bb(f)),l===1/0)return f;const d=Math.max(1,n*l/t.ticks().length);return v=>{let p=v/o(Math.round(i(v)));return p*nr(nN(r(),{floor:l=>o(Math.floor(i(l))),ceil:l=>o(Math.ceil(i(l)))})),t}function iN(){const e=Fb(zf()).domain([1,10]);return e.copy=()=>Nu(e,iN()).base(e.base()),Pr.apply(e,arguments),e}function QE(e){return function(t){return Math.sign(t)*Math.log1p(Math.abs(t/e))}}function ZE(e){return function(t){return Math.sign(t)*Math.expm1(Math.abs(t))*e}}function qb(e){var t=1,r=e(QE(t),ZE(t));return r.constant=function(n){return arguments.length?e(QE(t=+n),ZE(t)):t},fi(r)}function aN(){var e=qb(zf());return e.copy=function(){return Nu(e,aN()).constant(e.constant())},Pr.apply(e,arguments)}function JE(e){return function(t){return t<0?-Math.pow(-t,e):Math.pow(t,e)}}function n4(e){return e<0?-Math.sqrt(-e):Math.sqrt(e)}function i4(e){return e<0?-e*e:e*e}function zb(e){var t=e(Ut,Ut),r=1;function n(){return r===1?e(Ut,Ut):r===.5?e(n4,i4):e(JE(r),JE(1/r))}return t.exponent=function(i){return arguments.length?(r=+i,n()):r},fi(t)}function Ub(){var e=zb(zf());return e.copy=function(){return Nu(e,Ub()).exponent(e.exponent())},Pr.apply(e,arguments),e}function a4(){return Ub.apply(null,arguments).exponent(.5)}function ej(e){return Math.sign(e)*e*e}function o4(e){return Math.sign(e)*Math.sqrt(Math.abs(e))}function oN(){var e=Db(),t=[0,1],r=!1,n;function i(o){var u=o4(e(o));return isNaN(u)?n:r?Math.round(u):u}return i.invert=function(o){return e.invert(ej(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,Nc)).map(ej)),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 oN(e.domain(),t).round(r).clamp(e.clamp()).unknown(n)},Pr.apply(i,arguments),fi(i)}function sN(){var e=[],t=[],r=[],n;function i(){var u=0,l=Math.max(1,t.length);for(r=new Array(l-1);++u0?r[l-1]:e[0],l=r?[n[r-1],t]:[n[d-1],n[d]]},u.unknown=function(f){return arguments.length&&(o=f),u},u.thresholds=function(){return n.slice()},u.copy=function(){return uN().domain([e,t]).range(i).unknown(o)},Pr.apply(fi(u),arguments)}function lN(){var e=[.5],t=[0,1],r,n=1;function i(o){return o!=null&&o<=o?t[Cu(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 u=t.indexOf(o);return[e[u-1],e[u]]},i.unknown=function(o){return arguments.length?(r=o,i):r},i.copy=function(){return lN().domain(e).range(t).unknown(r)},Pr.apply(i,arguments)}const Ay=new Date,Ty=new Date;function St(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 u=i(o),l=i.ceil(o);return o-u(t(o=new Date(+o),u==null?1:Math.floor(u)),o),i.range=(o,u,l)=>{const f=[];if(o=i.ceil(o),l=l==null?1:Math.floor(l),!(o0))return f;let d;do f.push(d=new Date(+o)),t(o,l),e(o);while(dSt(u=>{if(u>=u)for(;e(u),!o(u);)u.setTime(u-1)},(u,l)=>{if(u>=u)if(l<0)for(;++l<=0;)for(;t(u,-1),!o(u););else for(;--l>=0;)for(;t(u,1),!o(u););}),r&&(i.count=(o,u)=>(Ay.setTime(+o),Ty.setTime(+u),e(Ay),e(Ty),Math.floor(r(Ay,Ty))),i.every=o=>(o=Math.floor(o),!isFinite(o)||!(o>0)?null:o>1?i.filter(n?u=>n(u)%o===0:u=>i.count(0,u)%o===0):i)),i}const Ic=St(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);Ic.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?St(t=>{t.setTime(Math.floor(t/e)*e)},(t,r)=>{t.setTime(+t+r*e)},(t,r)=>(r-t)/e):Ic);Ic.range;const bn=1e3,Or=bn*60,xn=Or*60,jn=xn*24,Wb=jn*7,tj=jn*30,Cy=jn*365,Di=St(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*bn)},(e,t)=>(t-e)/bn,e=>e.getUTCSeconds());Di.range;const Hb=St(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*bn)},(e,t)=>{e.setTime(+e+t*Or)},(e,t)=>(t-e)/Or,e=>e.getMinutes());Hb.range;const Kb=St(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*Or)},(e,t)=>(t-e)/Or,e=>e.getUTCMinutes());Kb.range;const Vb=St(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*bn-e.getMinutes()*Or)},(e,t)=>{e.setTime(+e+t*xn)},(e,t)=>(t-e)/xn,e=>e.getHours());Vb.range;const Gb=St(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*xn)},(e,t)=>(t-e)/xn,e=>e.getUTCHours());Gb.range;const Ru=St(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*Or)/jn,e=>e.getDate()-1);Ru.range;const Uf=St(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/jn,e=>e.getUTCDate()-1);Uf.range;const cN=St(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/jn,e=>Math.floor(e/jn));cN.range;function Qi(e){return St(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())*Or)/Wb)}const Wf=Qi(0),Dc=Qi(1),s4=Qi(2),u4=Qi(3),Qa=Qi(4),l4=Qi(5),c4=Qi(6);Wf.range;Dc.range;s4.range;u4.range;Qa.range;l4.range;c4.range;function Zi(e){return St(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)/Wb)}const Hf=Zi(0),Lc=Zi(1),f4=Zi(2),d4=Zi(3),Za=Zi(4),p4=Zi(5),h4=Zi(6);Hf.range;Lc.range;f4.range;d4.range;Za.range;p4.range;h4.range;const Xb=St(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());Xb.range;const Yb=St(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());Yb.range;const An=St(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());An.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:St(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)});An.range;const Tn=St(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());Tn.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:St(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)});Tn.range;function fN(e,t,r,n,i,o){const u=[[Di,1,bn],[Di,5,5*bn],[Di,15,15*bn],[Di,30,30*bn],[o,1,Or],[o,5,5*Or],[o,15,15*Or],[o,30,30*Or],[i,1,xn],[i,3,3*xn],[i,6,6*xn],[i,12,12*xn],[n,1,jn],[n,2,2*jn],[r,1,Wb],[t,1,tj],[t,3,3*tj],[e,1,Cy]];function l(d,v,p){const m=vg).right(u,m);if(b===u.length)return e.every(Zg(d/Cy,v/Cy,p));if(b===0)return Ic.every(Math.max(Zg(d,v,p),1));const[O,x]=u[m/u[b-1][2]53)return null;"w"in ne||(ne.w=1),"Z"in ne?(Ne=Ny(gs(ne.y,0,1)),Ce=Ne.getUTCDay(),Ne=Ce>4||Ce===0?Lc.ceil(Ne):Lc(Ne),Ne=Uf.offset(Ne,(ne.V-1)*7),ne.y=Ne.getUTCFullYear(),ne.m=Ne.getUTCMonth(),ne.d=Ne.getUTCDate()+(ne.w+6)%7):(Ne=ky(gs(ne.y,0,1)),Ce=Ne.getDay(),Ne=Ce>4||Ce===0?Dc.ceil(Ne):Dc(Ne),Ne=Ru.offset(Ne,(ne.V-1)*7),ne.y=Ne.getFullYear(),ne.m=Ne.getMonth(),ne.d=Ne.getDate()+(ne.w+6)%7)}else("W"in ne||"U"in ne)&&("w"in ne||(ne.w="u"in ne?ne.u%7:"W"in ne?1:0),Ce="Z"in ne?Ny(gs(ne.y,0,1)).getUTCDay():ky(gs(ne.y,0,1)).getDay(),ne.m=0,ne.d="W"in ne?(ne.w+6)%7+ne.W*7-(Ce+5)%7:ne.w+ne.U*7-(Ce+6)%7);return"Z"in ne?(ne.H+=ne.Z/100|0,ne.M+=ne.Z%100,Ny(ne)):ky(ne)}}function R(ae,ge,Te,ne){for(var We=0,Ne=ge.length,Ce=Te.length,Je,st;We=Ce)return-1;if(Je=ge.charCodeAt(We++),Je===37){if(Je=ge.charAt(We++),st=_[Je in rj?ge.charAt(We++):Je],!st||(ne=st(ae,Te,ne))<0)return-1}else if(Je!=Te.charCodeAt(ne++))return-1}return ne}function D(ae,ge,Te){var ne=d.exec(ge.slice(Te));return ne?(ae.p=v.get(ne[0].toLowerCase()),Te+ne[0].length):-1}function W(ae,ge,Te){var ne=b.exec(ge.slice(Te));return ne?(ae.w=O.get(ne[0].toLowerCase()),Te+ne[0].length):-1}function B(ae,ge,Te){var ne=p.exec(ge.slice(Te));return ne?(ae.w=m.get(ne[0].toLowerCase()),Te+ne[0].length):-1}function M(ae,ge,Te){var ne=E.exec(ge.slice(Te));return ne?(ae.m=A.get(ne[0].toLowerCase()),Te+ne[0].length):-1}function z(ae,ge,Te){var ne=x.exec(ge.slice(Te));return ne?(ae.m=g.get(ne[0].toLowerCase()),Te+ne[0].length):-1}function G(ae,ge,Te){return R(ae,t,ge,Te)}function V(ae,ge,Te){return R(ae,r,ge,Te)}function Y(ae,ge,Te){return R(ae,n,ge,Te)}function J(ae){return u[ae.getDay()]}function H(ae){return o[ae.getDay()]}function ee(ae){return f[ae.getMonth()]}function Z(ae){return l[ae.getMonth()]}function L(ae){return i[+(ae.getHours()>=12)]}function U(ae){return 1+~~(ae.getMonth()/3)}function oe(ae){return u[ae.getUTCDay()]}function ce(ae){return o[ae.getUTCDay()]}function me(ae){return f[ae.getUTCMonth()]}function Pe(ae){return l[ae.getUTCMonth()]}function De(ae){return i[+(ae.getUTCHours()>=12)]}function Ae(ae){return 1+~~(ae.getUTCMonth()/3)}return{format:function(ae){var ge=j(ae+="",T);return ge.toString=function(){return ae},ge},parse:function(ae){var ge=N(ae+="",!1);return ge.toString=function(){return ae},ge},utcFormat:function(ae){var ge=j(ae+="",P);return ge.toString=function(){return ae},ge},utcParse:function(ae){var ge=N(ae+="",!0);return ge.toString=function(){return ae},ge}}}var rj={"-":"",_:" ",0:"0"},At=/^\s*\d+/,x4=/^%/,w4=/[\\^$*+?|[\]().{}]/g;function ze(e,t,r){var n=e<0?"-":"",i=(n?-e:e)+"",o=i.length;return n+(o[t.toLowerCase(),r]))}function O4(e,t,r){var n=At.exec(t.slice(r,r+1));return n?(e.w=+n[0],r+n[0].length):-1}function _4(e,t,r){var n=At.exec(t.slice(r,r+1));return n?(e.u=+n[0],r+n[0].length):-1}function P4(e,t,r){var n=At.exec(t.slice(r,r+2));return n?(e.U=+n[0],r+n[0].length):-1}function E4(e,t,r){var n=At.exec(t.slice(r,r+2));return n?(e.V=+n[0],r+n[0].length):-1}function j4(e,t,r){var n=At.exec(t.slice(r,r+2));return n?(e.W=+n[0],r+n[0].length):-1}function nj(e,t,r){var n=At.exec(t.slice(r,r+4));return n?(e.y=+n[0],r+n[0].length):-1}function ij(e,t,r){var n=At.exec(t.slice(r,r+2));return n?(e.y=+n[0]+(+n[0]>68?1900:2e3),r+n[0].length):-1}function A4(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 T4(e,t,r){var n=At.exec(t.slice(r,r+1));return n?(e.q=n[0]*3-3,r+n[0].length):-1}function C4(e,t,r){var n=At.exec(t.slice(r,r+2));return n?(e.m=n[0]-1,r+n[0].length):-1}function aj(e,t,r){var n=At.exec(t.slice(r,r+2));return n?(e.d=+n[0],r+n[0].length):-1}function k4(e,t,r){var n=At.exec(t.slice(r,r+3));return n?(e.m=0,e.d=+n[0],r+n[0].length):-1}function oj(e,t,r){var n=At.exec(t.slice(r,r+2));return n?(e.H=+n[0],r+n[0].length):-1}function N4(e,t,r){var n=At.exec(t.slice(r,r+2));return n?(e.M=+n[0],r+n[0].length):-1}function R4(e,t,r){var n=At.exec(t.slice(r,r+2));return n?(e.S=+n[0],r+n[0].length):-1}function M4(e,t,r){var n=At.exec(t.slice(r,r+3));return n?(e.L=+n[0],r+n[0].length):-1}function $4(e,t,r){var n=At.exec(t.slice(r,r+6));return n?(e.L=Math.floor(n[0]/1e3),r+n[0].length):-1}function I4(e,t,r){var n=x4.exec(t.slice(r,r+1));return n?r+n[0].length:-1}function D4(e,t,r){var n=At.exec(t.slice(r));return n?(e.Q=+n[0],r+n[0].length):-1}function L4(e,t,r){var n=At.exec(t.slice(r));return n?(e.s=+n[0],r+n[0].length):-1}function sj(e,t){return ze(e.getDate(),t,2)}function B4(e,t){return ze(e.getHours(),t,2)}function F4(e,t){return ze(e.getHours()%12||12,t,2)}function q4(e,t){return ze(1+Ru.count(An(e),e),t,3)}function dN(e,t){return ze(e.getMilliseconds(),t,3)}function z4(e,t){return dN(e,t)+"000"}function U4(e,t){return ze(e.getMonth()+1,t,2)}function W4(e,t){return ze(e.getMinutes(),t,2)}function H4(e,t){return ze(e.getSeconds(),t,2)}function K4(e){var t=e.getDay();return t===0?7:t}function V4(e,t){return ze(Wf.count(An(e)-1,e),t,2)}function pN(e){var t=e.getDay();return t>=4||t===0?Qa(e):Qa.ceil(e)}function G4(e,t){return e=pN(e),ze(Qa.count(An(e),e)+(An(e).getDay()===4),t,2)}function X4(e){return e.getDay()}function Y4(e,t){return ze(Dc.count(An(e)-1,e),t,2)}function Q4(e,t){return ze(e.getFullYear()%100,t,2)}function Z4(e,t){return e=pN(e),ze(e.getFullYear()%100,t,2)}function J4(e,t){return ze(e.getFullYear()%1e4,t,4)}function e8(e,t){var r=e.getDay();return e=r>=4||r===0?Qa(e):Qa.ceil(e),ze(e.getFullYear()%1e4,t,4)}function t8(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+ze(t/60|0,"0",2)+ze(t%60,"0",2)}function uj(e,t){return ze(e.getUTCDate(),t,2)}function r8(e,t){return ze(e.getUTCHours(),t,2)}function n8(e,t){return ze(e.getUTCHours()%12||12,t,2)}function i8(e,t){return ze(1+Uf.count(Tn(e),e),t,3)}function hN(e,t){return ze(e.getUTCMilliseconds(),t,3)}function a8(e,t){return hN(e,t)+"000"}function o8(e,t){return ze(e.getUTCMonth()+1,t,2)}function s8(e,t){return ze(e.getUTCMinutes(),t,2)}function u8(e,t){return ze(e.getUTCSeconds(),t,2)}function l8(e){var t=e.getUTCDay();return t===0?7:t}function c8(e,t){return ze(Hf.count(Tn(e)-1,e),t,2)}function vN(e){var t=e.getUTCDay();return t>=4||t===0?Za(e):Za.ceil(e)}function f8(e,t){return e=vN(e),ze(Za.count(Tn(e),e)+(Tn(e).getUTCDay()===4),t,2)}function d8(e){return e.getUTCDay()}function p8(e,t){return ze(Lc.count(Tn(e)-1,e),t,2)}function h8(e,t){return ze(e.getUTCFullYear()%100,t,2)}function v8(e,t){return e=vN(e),ze(e.getUTCFullYear()%100,t,2)}function m8(e,t){return ze(e.getUTCFullYear()%1e4,t,4)}function y8(e,t){var r=e.getUTCDay();return e=r>=4||r===0?Za(e):Za.ceil(e),ze(e.getUTCFullYear()%1e4,t,4)}function g8(){return"+0000"}function lj(){return"%"}function cj(e){return+e}function fj(e){return Math.floor(+e/1e3)}var Ca,mN,yN;b8({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 b8(e){return Ca=b4(e),mN=Ca.format,Ca.parse,yN=Ca.utcFormat,Ca.utcParse,Ca}function x8(e){return new Date(e)}function w8(e){return e instanceof Date?+e:+new Date(+e)}function Qb(e,t,r,n,i,o,u,l,f,d){var v=Db(),p=v.invert,m=v.domain,b=d(".%L"),O=d(":%S"),x=d("%I:%M"),g=d("%I %p"),E=d("%a %d"),A=d("%b %d"),T=d("%B"),P=d("%Y");function _(j){return(f(j)t(i/(e.length-1)))},r.quantiles=function(n){return Array.from({length:n+1},(i,o)=>cU(e,o/n))},r.copy=function(){return wN(t).domain(e)},$n.apply(r,arguments)}function Vf(){var e=0,t=.5,r=1,n=1,i,o,u,l,f,d=Ut,v,p=!1,m;function b(x){return isNaN(x=+x)?m:(x=.5+((x=+v(x))-o)*(n*xr}return My=e,My}var $y,vj;function E8(){if(vj)return $y;vj=1;var e=Gf(),t=PN(),r=Oo();function n(i){return i&&i.length?e(i,r,t):void 0}return $y=n,$y}var j8=E8();const Xf=Ue(j8);var Iy,mj;function EN(){if(mj)return Iy;mj=1;function e(t,r){return te.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};pe.decimalPlaces=pe.dp=function(){var e=this,t=e.d.length-1,r=(t-e.e)*rt;if(t=e.d[t],t)for(;t%10==0;t/=10)r--;return r<0?0:r};pe.dividedBy=pe.div=function(e){return Pn(this,new this.constructor(e))};pe.dividedToIntegerBy=pe.idiv=function(e){var t=this,r=t.constructor;return Ge(Pn(t,new r(e),0,1),r.precision)};pe.equals=pe.eq=function(e){return!this.cmp(e)};pe.exponent=function(){return vt(this)};pe.greaterThan=pe.gt=function(e){return this.cmp(e)>0};pe.greaterThanOrEqualTo=pe.gte=function(e){return this.cmp(e)>=0};pe.isInteger=pe.isint=function(){return this.e>this.d.length-2};pe.isNegative=pe.isneg=function(){return this.s<0};pe.isPositive=pe.ispos=function(){return this.s>0};pe.isZero=function(){return this.s===0};pe.lessThan=pe.lt=function(e){return this.cmp(e)<0};pe.lessThanOrEqualTo=pe.lte=function(e){return this.cmp(e)<1};pe.logarithm=pe.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(ur))throw Error(_r+"NaN");if(r.s<1)throw Error(_r+(r.s?"NaN":"-Infinity"));return r.eq(ur)?new n(0):(it=!1,t=Pn(eu(r,o),eu(e,o),o),it=!0,Ge(t,i))};pe.minus=pe.sub=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?CN(t,e):AN(t,(e.s=-e.s,e))};pe.modulo=pe.mod=function(e){var t,r=this,n=r.constructor,i=n.precision;if(e=new n(e),!e.s)throw Error(_r+"NaN");return r.s?(it=!1,t=Pn(r,e,0,1).times(e),it=!0,r.minus(t)):Ge(new n(r),i)};pe.naturalExponential=pe.exp=function(){return TN(this)};pe.naturalLogarithm=pe.ln=function(){return eu(this)};pe.negated=pe.neg=function(){var e=new this.constructor(this);return e.s=-e.s||0,e};pe.plus=pe.add=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?AN(t,e):CN(t,(e.s=-e.s,e))};pe.precision=pe.sd=function(e){var t,r,n,i=this;if(e!==void 0&&e!==!!e&&e!==1&&e!==0)throw Error(Fi+e);if(t=vt(i)+1,n=i.d.length-1,r=n*rt+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};pe.squareRoot=pe.sqrt=function(){var e,t,r,n,i,o,u,l=this,f=l.constructor;if(l.s<1){if(!l.s)return new f(0);throw Error(_r+"NaN")}for(e=vt(l),it=!1,i=Math.sqrt(+l),i==0||i==1/0?(t=Qr(l.d),(t.length+e)%2==0&&(t+="0"),i=Math.sqrt(t),e=Eo((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 f(t)):n=new f(i.toString()),r=f.precision,i=u=r+3;;)if(o=n,n=o.plus(Pn(l,o,u+2)).times(.5),Qr(o.d).slice(0,u)===(t=Qr(n.d)).slice(0,u)){if(t=t.slice(u-3,u+1),i==u&&t=="4999"){if(Ge(o,r+1,0),o.times(o).eq(l)){n=o;break}}else if(t!="9999")break;u+=4}return it=!0,Ge(n,r)};pe.times=pe.mul=function(e){var t,r,n,i,o,u,l,f,d,v=this,p=v.constructor,m=v.d,b=(e=new p(e)).d;if(!v.s||!e.s)return new p(0);for(e.s*=v.s,r=v.e+e.e,f=m.length,d=b.length,f=0;){for(t=0,i=f+n;i>n;)l=o[i]+b[n]*m[i-n-1]+t,o[i--]=l%Et|0,t=l/Et|0;o[i]=(o[i]+t)%Et|0}for(;!o[--u];)o.pop();return t?++r:o.shift(),e.d=o,e.e=r,it?Ge(e,p.precision):e};pe.toDecimalPlaces=pe.todp=function(e,t){var r=this,n=r.constructor;return r=new n(r),e===void 0?r:(en(e,0,Po),t===void 0?t=n.rounding:en(t,0,8),Ge(r,e+vt(r)+1,t))};pe.toExponential=function(e,t){var r,n=this,i=n.constructor;return e===void 0?r=Wi(n,!0):(en(e,0,Po),t===void 0?t=i.rounding:en(t,0,8),n=Ge(new i(n),e+1,t),r=Wi(n,!0,e+1)),r};pe.toFixed=function(e,t){var r,n,i=this,o=i.constructor;return e===void 0?Wi(i):(en(e,0,Po),t===void 0?t=o.rounding:en(t,0,8),n=Ge(new o(i),e+vt(i)+1,t),r=Wi(n.abs(),!1,e+vt(n)+1),i.isneg()&&!i.isZero()?"-"+r:r)};pe.toInteger=pe.toint=function(){var e=this,t=e.constructor;return Ge(new t(e),vt(e)+1,t.rounding)};pe.toNumber=function(){return+this};pe.toPower=pe.pow=function(e){var t,r,n,i,o,u,l=this,f=l.constructor,d=12,v=+(e=new f(e));if(!e.s)return new f(ur);if(l=new f(l),!l.s){if(e.s<1)throw Error(_r+"Infinity");return l}if(l.eq(ur))return l;if(n=f.precision,e.eq(ur))return Ge(l,n);if(t=e.e,r=e.d.length-1,u=t>=r,o=l.s,u){if((r=v<0?-v:v)<=jN){for(i=new f(ur),t=Math.ceil(n/rt+4),it=!1;r%2&&(i=i.times(l),Sj(i.d,t)),r=Eo(r/2),r!==0;)l=l.times(l),Sj(l.d,t);return it=!0,e.s<0?new f(ur).div(i):Ge(i,n)}}else if(o<0)throw Error(_r+"NaN");return o=o<0&&e.d[Math.max(t,r)]&1?-1:1,l.s=1,it=!1,i=e.times(eu(l,n+d)),it=!0,i=TN(i),i.s=o,i};pe.toPrecision=function(e,t){var r,n,i=this,o=i.constructor;return e===void 0?(r=vt(i),n=Wi(i,r<=o.toExpNeg||r>=o.toExpPos)):(en(e,1,Po),t===void 0?t=o.rounding:en(t,0,8),i=Ge(new o(i),e,t),r=vt(i),n=Wi(i,e<=r||r<=o.toExpNeg,e)),n};pe.toSignificantDigits=pe.tosd=function(e,t){var r=this,n=r.constructor;return e===void 0?(e=n.precision,t=n.rounding):(en(e,1,Po),t===void 0?t=n.rounding:en(t,0,8)),Ge(new n(r),e,t)};pe.toString=pe.valueOf=pe.val=pe.toJSON=pe[Symbol.for("nodejs.util.inspect.custom")]=function(){var e=this,t=vt(e),r=e.constructor;return Wi(e,t<=r.toExpNeg||t>=r.toExpPos)};function AN(e,t){var r,n,i,o,u,l,f,d,v=e.constructor,p=v.precision;if(!e.s||!t.s)return t.s||(t=new v(e)),it?Ge(t,p):t;if(f=e.d,d=t.d,u=e.e,i=t.e,f=f.slice(),o=u-i,o){for(o<0?(n=f,o=-o,l=d.length):(n=d,i=u,l=f.length),u=Math.ceil(p/rt),l=u>l?u+1:l+1,o>l&&(o=l,n.length=1),n.reverse();o--;)n.push(0);n.reverse()}for(l=f.length,o=d.length,l-o<0&&(o=l,n=d,d=f,f=n),r=0;o;)r=(f[--o]=f[o]+d[o]+r)/Et|0,f[o]%=Et;for(r&&(f.unshift(r),++i),l=f.length;f[--l]==0;)f.pop();return t.d=f,t.e=i,it?Ge(t,p):t}function en(e,t,r){if(e!==~~e||er)throw Error(Fi+e)}function Qr(e){var t,r,n,i=e.length-1,o="",u=e[0];if(i>0){for(o+=u,t=1;tu?1:-1;else for(l=f=0;li[l]?1:-1;break}return f}function r(n,i,o){for(var u=0;o--;)n[o]-=u,u=n[o]1;)n.shift()}return function(n,i,o,u){var l,f,d,v,p,m,b,O,x,g,E,A,T,P,_,j,N,R,D=n.constructor,W=n.s==i.s?1:-1,B=n.d,M=i.d;if(!n.s)return new D(n);if(!i.s)throw Error(_r+"Division by zero");for(f=n.e-i.e,N=M.length,_=B.length,b=new D(W),O=b.d=[],d=0;M[d]==(B[d]||0);)++d;if(M[d]>(B[d]||0)&&--f,o==null?A=o=D.precision:u?A=o+(vt(n)-vt(i))+1:A=o,A<0)return new D(0);if(A=A/rt+2|0,d=0,N==1)for(v=0,M=M[0],A++;(d<_||v)&&A--;d++)T=v*Et+(B[d]||0),O[d]=T/M|0,v=T%M|0;else{for(v=Et/(M[0]+1)|0,v>1&&(M=e(M,v),B=e(B,v),N=M.length,_=B.length),P=N,x=B.slice(0,N),g=x.length;g=Et/2&&++j;do v=0,l=t(M,x,N,g),l<0?(E=x[0],N!=g&&(E=E*Et+(x[1]||0)),v=E/j|0,v>1?(v>=Et&&(v=Et-1),p=e(M,v),m=p.length,g=x.length,l=t(p,x,m,g),l==1&&(v--,r(p,N16)throw Error(ex+vt(e));if(!e.s)return new v(ur);for(it=!1,l=p,u=new v(.03125);e.abs().gte(.1);)e=e.times(u),d+=5;for(n=Math.log(Ri(2,d))/Math.LN10*2+5|0,l+=n,r=i=o=new v(ur),v.precision=l;;){if(i=Ge(i.times(e),l),r=r.times(++f),u=o.plus(Pn(i,r,l)),Qr(u.d).slice(0,l)===Qr(o.d).slice(0,l)){for(;d--;)o=Ge(o.times(o),l);return v.precision=p,t==null?(it=!0,Ge(o,p)):o}o=u}}function vt(e){for(var t=e.e*rt,r=e.d[0];r>=10;r/=10)t++;return t}function qy(e,t,r){if(t>e.LN10.sd())throw it=!0,r&&(e.precision=r),Error(_r+"LN10 precision limit exceeded");return Ge(new e(e.LN10),t)}function ri(e){for(var t="";e--;)t+="0";return t}function eu(e,t){var r,n,i,o,u,l,f,d,v,p=1,m=10,b=e,O=b.d,x=b.constructor,g=x.precision;if(b.s<1)throw Error(_r+(b.s?"NaN":"-Infinity"));if(b.eq(ur))return new x(0);if(t==null?(it=!1,d=g):d=t,b.eq(10))return t==null&&(it=!0),qy(x,d);if(d+=m,x.precision=d,r=Qr(O),n=r.charAt(0),o=vt(b),Math.abs(o)<15e14){for(;n<7&&n!=1||n==1&&r.charAt(1)>3;)b=b.times(e),r=Qr(b.d),n=r.charAt(0),p++;o=vt(b),n>1?(b=new x("0."+r),o++):b=new x(n+"."+r.slice(1))}else return f=qy(x,d+2,g).times(o+""),b=eu(new x(n+"."+r.slice(1)),d-m).plus(f),x.precision=g,t==null?(it=!0,Ge(b,g)):b;for(l=u=b=Pn(b.minus(ur),b.plus(ur),d),v=Ge(b.times(b),d),i=3;;){if(u=Ge(u.times(v),d),f=l.plus(Pn(u,new x(i),d)),Qr(f.d).slice(0,d)===Qr(l.d).slice(0,d))return l=l.times(2),o!==0&&(l=l.plus(qy(x,d+2,g).times(o+""))),l=Pn(l,new x(p),d),x.precision=g,t==null?(it=!0,Ge(l,g)):l;l=f,i+=2}}function wj(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=Eo(r/rt),e.d=[],n=(r+1)%rt,r<0&&(n+=rt),nBc||e.e<-Bc))throw Error(ex+r)}else e.s=0,e.e=0,e.d=[0];return e}function Ge(e,t,r){var n,i,o,u,l,f,d,v,p=e.d;for(u=1,o=p[0];o>=10;o/=10)u++;if(n=t-u,n<0)n+=rt,i=t,d=p[v=0];else{if(v=Math.ceil((n+1)/rt),o=p.length,v>=o)return e;for(d=o=p[v],u=1;o>=10;o/=10)u++;n%=rt,i=n-rt+u}if(r!==void 0&&(o=Ri(10,u-i-1),l=d/o%10|0,f=t<0||p[v+1]!==void 0||d%o,f=r<4?(l||f)&&(r==0||r==(e.s<0?3:2)):l>5||l==5&&(r==4||f||r==6&&(n>0?i>0?d/Ri(10,u-i):0:p[v-1])%10&1||r==(e.s<0?8:7))),t<1||!p[0])return f?(o=vt(e),p.length=1,t=t-o-1,p[0]=Ri(10,(rt-t%rt)%rt),e.e=Eo(-t/rt)||0):(p.length=1,p[0]=e.e=e.s=0),e;if(n==0?(p.length=v,o=1,v--):(p.length=v+1,o=Ri(10,rt-n),p[v]=i>0?(d/Ri(10,u-i)%Ri(10,i)|0)*o:0),f)for(;;)if(v==0){(p[0]+=o)==Et&&(p[0]=1,++e.e);break}else{if(p[v]+=o,p[v]!=Et)break;p[v--]=0,o=1}for(n=p.length;p[--n]===0;)p.pop();if(it&&(e.e>Bc||e.e<-Bc))throw Error(ex+vt(e));return e}function CN(e,t){var r,n,i,o,u,l,f,d,v,p,m=e.constructor,b=m.precision;if(!e.s||!t.s)return t.s?t.s=-t.s:t=new m(e),it?Ge(t,b):t;if(f=e.d,p=t.d,n=t.e,d=e.e,f=f.slice(),u=d-n,u){for(v=u<0,v?(r=f,u=-u,l=p.length):(r=p,n=d,l=f.length),i=Math.max(Math.ceil(b/rt),l)+2,u>i&&(u=i,r.length=1),r.reverse(),i=u;i--;)r.push(0);r.reverse()}else{for(i=f.length,l=p.length,v=i0;--i)f[l++]=0;for(i=p.length;i>u;){if(f[--i]0?o=o.charAt(0)+"."+o.slice(1)+ri(n):u>1&&(o=o.charAt(0)+"."+o.slice(1)),o=o+(i<0?"e":"e+")+i):i<0?(o="0."+ri(-i-1)+o,r&&(n=r-u)>0&&(o+=ri(n))):i>=u?(o+=ri(i+1-u),r&&(n=r-i-1)>0&&(o=o+"."+ri(n))):((n=i+1)0&&(i+1===u&&(o+="."),o+=ri(n))),e.s<0?"-"+o:o}function Sj(e,t){if(e.length>t)return e.length=t,!0}function kN(e){var t,r,n;function i(o){var u=this;if(!(u instanceof i))return new i(o);if(u.constructor=i,o instanceof i){u.s=o.s,u.e=o.e,u.d=(o=o.d)?o.slice():o;return}if(typeof o=="number"){if(o*0!==0)throw Error(Fi+o);if(o>0)u.s=1;else if(o<0)o=-o,u.s=-1;else{u.s=0,u.e=0,u.d=[0];return}if(o===~~o&&o<1e7){u.e=0,u.d=[o];return}return wj(u,o.toString())}else if(typeof o!="string")throw Error(Fi+o);if(o.charCodeAt(0)===45?(o=o.slice(1),u.s=-1):u.s=1,D8.test(o))wj(u,o);else throw Error(Fi+o)}if(i.prototype=pe,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=kN,i.config=i.set=L8,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(Fi+r+": "+n);if((n=e[r="LN10"])!==void 0)if(n==Math.LN10)this[r]=new this(n);else throw Error(Fi+r+": "+n);return this}var tx=kN(I8);ur=new tx(1);const Ve=tx;function B8(e){return U8(e)||z8(e)||q8(e)||F8()}function F8(){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 q8(e,t){if(e){if(typeof e=="string")return n0(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 n0(e,t)}}function z8(e){if(typeof Symbol<"u"&&Symbol.iterator in Object(e))return Array.from(e)}function U8(e){if(Array.isArray(e))return n0(e)}function n0(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-u,Oj(function(){for(var l=arguments.length,f=new Array(l),d=0;de.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 u=e[Symbol.iterator](),l;!(n=(l=u.next()).done)&&(r.push(l.value),!(t&&r.length===t));n=!0);}catch(f){i=!0,o=f}finally{try{!n&&u.return!=null&&u.return()}finally{if(i)throw o}}return r}}function i6(e){if(Array.isArray(e))return e}function IN(e){var t=tu(e,2),r=t[0],n=t[1],i=r,o=n;return r>n&&(i=n,o=r),[i,o]}function DN(e,t,r){if(e.lte(0))return new Ve(0);var n=Zf.getDigitCount(e.toNumber()),i=new Ve(10).pow(n),o=e.div(i),u=n!==1?.05:.1,l=new Ve(Math.ceil(o.div(u).toNumber())).add(r).mul(u),f=l.mul(i);return t?f:new Ve(Math.ceil(f))}function a6(e,t,r){var n=1,i=new Ve(e);if(!i.isint()&&r){var o=Math.abs(e);o<1?(n=new Ve(10).pow(Zf.getDigitCount(e)-1),i=new Ve(Math.floor(i.div(n).toNumber())).mul(n)):o>1&&(i=new Ve(Math.floor(e)))}else e===0?i=new Ve(Math.floor((t-1)/2)):r||(i=new Ve(Math.floor(e)));var u=Math.floor((t-1)/2),l=V8(K8(function(f){return i.add(new Ve(f-u).mul(n)).toNumber()}),i0);return l(0,t)}function LN(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 Ve(0),tickMin:new Ve(0),tickMax:new Ve(0)};var o=DN(new Ve(t).sub(e).div(r-1),n,i),u;e<=0&&t>=0?u=new Ve(0):(u=new Ve(e).add(t).div(2),u=u.sub(new Ve(u).mod(o)));var l=Math.ceil(u.sub(e).div(o).toNumber()),f=Math.ceil(new Ve(t).sub(u).div(o).toNumber()),d=l+f+1;return d>r?LN(e,t,r,n,i+1):(d0?f+(r-d):f,l=t>0?l:l+(r-d)),{step:o,tickMin:u.sub(new Ve(l).mul(o)),tickMax:u.add(new Ve(f).mul(o))})}function o6(e){var t=tu(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,u=Math.max(i,2),l=IN([r,n]),f=tu(l,2),d=f[0],v=f[1];if(d===-1/0||v===1/0){var p=v===1/0?[d].concat(o0(i0(0,i-1).map(function(){return 1/0}))):[].concat(o0(i0(0,i-1).map(function(){return-1/0})),[v]);return r>n?a0(p):p}if(d===v)return a6(d,i,o);var m=LN(d,v,u,o),b=m.step,O=m.tickMin,x=m.tickMax,g=Zf.rangeStep(O,x.add(new Ve(.1).mul(b)),b);return r>n?a0(g):g}function s6(e,t){var r=tu(e,2),n=r[0],i=r[1],o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,u=IN([n,i]),l=tu(u,2),f=l[0],d=l[1];if(f===-1/0||d===1/0)return[n,i];if(f===d)return[f];var v=Math.max(t,2),p=DN(new Ve(d).sub(f).div(v-1),o,0),m=[].concat(o0(Zf.rangeStep(new Ve(f),new Ve(d).sub(new Ve(.99).mul(p)),p)),[d]);return n>i?a0(m):m}var u6=MN(o6),l6=MN(s6),c6="Invariant failed";function Hi(e,t){throw new Error(c6)}var f6=["offset","layout","width","dataKey","data","dataPointFormatter","xAxis","yAxis"];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 Fc(){return Fc=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 g6(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function b6(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function x6(e,t){for(var r=0;re.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,u=-1,l=(r=n==null?void 0:n.length)!==null&&r!==void 0?r:0;if(l<=1)return 0;if(o&&o.axisType==="angleAxis"&&Math.abs(Math.abs(o.range[1]-o.range[0])-360)<=1e-6)for(var f=o.range,d=0;d0?i[d-1].coordinate:i[l-1].coordinate,p=i[d].coordinate,m=d>=l-1?i[0].coordinate:i[d+1].coordinate,b=void 0;if(qt(p-v)!==qt(m-p)){var O=[];if(qt(m-p)===qt(f[1]-f[0])){b=m;var x=p+f[1]-f[0];O[0]=Math.min(x,(x+v)/2),O[1]=Math.max(x,(x+v)/2)}else{b=v;var g=m+f[1]-f[0];O[0]=Math.min(p,(g+p)/2),O[1]=Math.max(p,(g+p)/2)}var E=[Math.min(p,(b+p)/2),Math.max(p,(b+p)/2)];if(t>E[0]&&t<=E[1]||t>=O[0]&&t<=O[1]){u=i[d].index;break}}else{var A=Math.min(v,m),T=Math.max(v,m);if(t>(A+p)/2&&t<=(T+p)/2){u=i[d].index;break}}}else for(var P=0;P0&&P(n[P].coordinate+n[P-1].coordinate)/2&&t<=(n[P].coordinate+n[P+1].coordinate)/2||P===l-1&&t>(n[P].coordinate+n[P-1].coordinate)/2){u=n[P].index;break}return u},rx=function(t){var r,n=t,i=n.type.displayName,o=(r=t.type)!==null&&r!==void 0&&r.defaultProps?lt(lt({},t.type.defaultProps),t.props):t.props,u=o.stroke,l=o.fill,f;switch(i){case"Line":f=u;break;case"Area":case"Radar":f=u&&u!=="none"?u:l;break;default:f=l;break}return f},D6=function(t){var r=t.barSize,n=t.totalSize,i=t.stackGroups,o=i===void 0?{}:i;if(!o)return{};for(var u={},l=Object.keys(o),f=0,d=l.length;f=0});if(E&&E.length){var A=E[0].type.defaultProps,T=A!==void 0?lt(lt({},A),E[0].props):E[0].props,P=T.barSize,_=T[g];u[_]||(u[_]=[]);var j=ke(P)?r:P;u[_].push({item:E[0],stackList:E.slice(1),barSize:ke(j)?void 0:zt(j,n,0)})}}return u},L6=function(t){var r=t.barGap,n=t.barCategoryGap,i=t.bandSize,o=t.sizeList,u=o===void 0?[]:o,l=t.maxBarSize,f=u.length;if(f<1)return null;var d=zt(r,i,0,!0),v,p=[];if(u[0].barSize===+u[0].barSize){var m=!1,b=i/f,O=u.reduce(function(P,_){return P+_.barSize||0},0);O+=(f-1)*d,O>=i&&(O-=(f-1)*d,d=0),O>=i&&b>0&&(m=!0,b*=.9,O=f*b);var x=(i-O)/2>>0,g={offset:x-d,size:0};v=u.reduce(function(P,_){var j={item:_.item,position:{offset:g.offset+g.size+d,size:m?b:_.barSize}},N=[].concat(Ej(P),[j]);return g=N[N.length-1].position,_.stackList&&_.stackList.length&&_.stackList.forEach(function(R){N.push({item:R,position:g})}),N},p)}else{var E=zt(n,i,0,!0);i-2*E-(f-1)*d<=0&&(d=0);var A=(i-2*E-(f-1)*d)/f;A>1&&(A>>=0);var T=l===+l?Math.min(A,l):A;v=u.reduce(function(P,_,j){var N=[].concat(Ej(P),[{item:_.item,position:{offset:E+(A+d)*j+(A-T)/2,size:T}}]);return _.stackList&&_.stackList.length&&_.stackList.forEach(function(R){N.push({item:R,position:N[N.length-1].position})}),N},p)}return v},B6=function(t,r,n,i){var o=n.children,u=n.width,l=n.margin,f=u-(l.left||0)-(l.right||0),d=zN({children:o,legendWidth:f});if(d){var v=i||{},p=v.width,m=v.height,b=d.align,O=d.verticalAlign,x=d.layout;if((x==="vertical"||x==="horizontal"&&O==="middle")&&b!=="center"&&le(t[b]))return lt(lt({},t),{},Ua({},b,t[b]+(p||0)));if((x==="horizontal"||x==="vertical"&&b==="center")&&O!=="middle"&&le(t[O]))return lt(lt({},t),{},Ua({},O,t[O]+(m||0)))}return t},F6=function(t,r,n){return ke(r)?!0:t==="horizontal"?r==="yAxis":t==="vertical"||n==="x"?r==="xAxis":n==="y"?r==="yAxis":!0},UN=function(t,r,n,i,o){var u=r.props.children,l=cr(u,$u).filter(function(d){return F6(i,o,d.props.direction)});if(l&&l.length){var f=l.map(function(d){return d.props.dataKey});return t.reduce(function(d,v){var p=xt(v,n);if(ke(p))return d;var m=Array.isArray(p)?[Yf(p),Xf(p)]:[p,p],b=f.reduce(function(O,x){var g=xt(v,x,0),E=m[0]-Math.abs(Array.isArray(g)?g[0]:g),A=m[1]+Math.abs(Array.isArray(g)?g[1]:g);return[Math.min(E,O[0]),Math.max(A,O[1])]},[1/0,-1/0]);return[Math.min(b[0],d[0]),Math.max(b[1],d[1])]},[1/0,-1/0])}return null},q6=function(t,r,n,i,o){var u=r.map(function(l){return UN(t,l,n,o,i)}).filter(function(l){return!ke(l)});return u&&u.length?u.reduce(function(l,f){return[Math.min(l[0],f[0]),Math.max(l[1],f[1])]},[1/0,-1/0]):null},WN=function(t,r,n,i,o){var u=r.map(function(f){var d=f.props.dataKey;return n==="number"&&d&&UN(t,f,d,i)||ks(t,d,n,o)});if(n==="number")return u.reduce(function(f,d){return[Math.min(f[0],d[0]),Math.max(f[1],d[1])]},[1/0,-1/0]);var l={};return u.reduce(function(f,d){for(var v=0,p=d.length;v=2?qt(l[0]-l[1])*2*d:d,r&&(t.ticks||t.niceTicks)){var v=(t.ticks||t.niceTicks).map(function(p){var m=o?o.indexOf(p):p;return{coordinate:i(m)+d,value:p,offset:d}});return v.filter(function(p){return!ju(p.coordinate)})}return t.isCategorical&&t.categoricalDomain?t.categoricalDomain.map(function(p,m){return{coordinate:i(p)+d,value:p,index:m,offset:d}}):i.ticks&&!n?i.ticks(t.tickCount).map(function(p){return{coordinate:i(p)+d,value:p,offset:d}}):i.domain().map(function(p,m){return{coordinate:i(p)+d,value:o?o[p]:p,index:m,offset:d}})},zy=new WeakMap,ic=function(t,r){if(typeof r!="function")return t;zy.has(t)||zy.set(t,new WeakMap);var n=zy.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},VN=function(t,r,n){var i=t.scale,o=t.type,u=t.layout,l=t.axisType;if(i==="auto")return u==="radial"&&l==="radiusAxis"?{scale:Xs(),realScaleType:"band"}:u==="radial"&&l==="angleAxis"?{scale:$c(),realScaleType:"linear"}:o==="category"&&r&&(r.indexOf("LineChart")>=0||r.indexOf("AreaChart")>=0||r.indexOf("ComposedChart")>=0&&!n)?{scale:Cs(),realScaleType:"point"}:o==="category"?{scale:Xs(),realScaleType:"band"}:{scale:$c(),realScaleType:"linear"};if(qi(i)){var f="scale".concat($f(i));return{scale:(dj[f]||Cs)(),realScaleType:dj[f]?f:"point"}}return je(i)?{scale:i}:{scale:Cs(),realScaleType:"point"}},Aj=1e-4,GN=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])-Aj,u=Math.max(i[0],i[1])+Aj,l=t(r[0]),f=t(r[n-1]);(lu||fu)&&t.domain([r[0],r[n-1]])}},z6=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[l][n][0]=o,t[l][n][1]=o+f,o=t[l][n][1]):(t[l][n][0]=u,t[l][n][1]=u+f,u=t[l][n][1])}},H6=function(t){var r=t.length;if(!(r<=0))for(var n=0,i=t[0].length;n=0?(t[u][n][0]=o,t[u][n][1]=o+l,o=t[u][n][1]):(t[u][n][0]=0,t[u][n][1]=0)}},K6={sign:W6,expand:RF,none:Ha,silhouette:MF,wiggle:$F,positive:H6},V6=function(t,r,n){var i=r.map(function(l){return l.props.dataKey}),o=K6[n],u=NF().keys(i).value(function(l,f){return+xt(l,f,0)}).order(Bg).offset(o);return u(t)},G6=function(t,r,n,i,o,u){if(!t)return null;var l=u?r.reverse():r,f={},d=l.reduce(function(p,m){var b,O=(b=m.type)!==null&&b!==void 0&&b.defaultProps?lt(lt({},m.type.defaultProps),m.props):m.props,x=O.stackId,g=O.hide;if(g)return p;var E=O[n],A=p[E]||{hasStack:!1,stackGroups:{}};if(wt(x)){var T=A.stackGroups[x]||{numericAxisId:n,cateAxisId:i,items:[]};T.items.push(m),A.hasStack=!0,A.stackGroups[x]=T}else A.stackGroups[So("_stackId_")]={numericAxisId:n,cateAxisId:i,items:[m]};return lt(lt({},p),{},Ua({},E,A))},f),v={};return Object.keys(d).reduce(function(p,m){var b=d[m];if(b.hasStack){var O={};b.stackGroups=Object.keys(b.stackGroups).reduce(function(x,g){var E=b.stackGroups[g];return lt(lt({},x),{},Ua({},g,{numericAxisId:n,cateAxisId:i,items:E.items,stackedData:V6(t,E.items,o)}))},O)}return lt(lt({},p),{},Ua({},m,b))},v)},XN=function(t,r){var n=r.realScaleType,i=r.type,o=r.tickCount,u=r.originalDomain,l=r.allowDecimals,f=n||r.scale;if(f!=="auto"&&f!=="linear")return null;if(o&&i==="number"&&u&&(u[0]==="auto"||u[1]==="auto")){var d=t.domain();if(!d.length)return null;var v=u6(d,o,l);return t.domain([Yf(v),Xf(v)]),{niceTicks:v}}if(o&&i==="number"){var p=t.domain(),m=l6(p,o,l);return{niceTicks:m}}return null};function Tj(e){var t=e.axis,r=e.ticks,n=e.bandSize,i=e.entry,o=e.index,u=e.dataKey;if(t.type==="category"){if(!t.allowDuplicatedCategory&&t.dataKey&&!ke(i[t.dataKey])){var l=mc(r,"value",i[t.dataKey]);if(l)return l.coordinate+n/2}return r[o]?r[o].coordinate+n/2:null}var f=xt(i,ke(u)?t.dataKey:u);return ke(f)?null:t.scale(f)}var Cj=function(t){var r=t.axis,n=t.ticks,i=t.offset,o=t.bandSize,u=t.entry,l=t.index;if(r.type==="category")return n[l]?n[l].coordinate+i:null;var f=xt(u,r.dataKey,r.domain[l]);return ke(f)?null:r.scale(f)-o/2+i},X6=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]},Y6=function(t,r){var n,i=(n=t.type)!==null&&n!==void 0&&n.defaultProps?lt(lt({},t.type.defaultProps),t.props):t.props,o=i.stackId;if(wt(o)){var u=r[o];if(u){var l=u.items.indexOf(t);return l>=0?u.stackedData[l]:null}}return null},Q6=function(t){return t.reduce(function(r,n){return[Yf(n.concat([r[0]]).filter(le)),Xf(n.concat([r[1]]).filter(le))]},[1/0,-1/0])},YN=function(t,r,n){return Object.keys(t).reduce(function(i,o){var u=t[o],l=u.stackedData,f=l.reduce(function(d,v){var p=Q6(v.slice(r,n+1));return[Math.min(d[0],p[0]),Math.max(d[1],p[1])]},[1/0,-1/0]);return[Math.min(f[0],i[0]),Math.max(f[1],i[1])]},[1/0,-1/0]).map(function(i){return i===1/0||i===-1/0?0:i})},kj=/^dataMin[\s]*-[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,Nj=/^dataMax[\s]*\+[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,c0=function(t,r,n){if(je(t))return t(r,n);if(!Array.isArray(t))return r;var i=[];if(le(t[0]))i[0]=n?t[0]:Math.min(t[0],r[0]);else if(kj.test(t[0])){var o=+kj.exec(t[0])[1];i[0]=r[0]-o}else je(t[0])?i[0]=t[0](r[0]):i[0]=r[0];if(le(t[1]))i[1]=n?t[1]:Math.max(t[1],r[1]);else if(Nj.test(t[1])){var u=+Nj.exec(t[1])[1];i[1]=r[1]+u}else je(t[1])?i[1]=t[1](r[1]):i[1]=r[1];return i},zc=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=Cb(r,function(p){return p.coordinate}),u=1/0,l=1,f=o.length;le.length)&&(t=e.length);for(var r=0,n=new Array(t);r2&&arguments[2]!==void 0?arguments[2]:{top:0,right:0,bottom:0,left:0};return Math.min(Math.abs(t-(n.left||0)-(n.right||0)),Math.abs(r-(n.top||0)-(n.bottom||0)))/2},o5=function(t,r,n,i,o){var u=t.width,l=t.height,f=t.startAngle,d=t.endAngle,v=zt(t.cx,u,u/2),p=zt(t.cy,l,l/2),m=JN(u,l,n),b=zt(t.innerRadius,m,0),O=zt(t.outerRadius,m,m*.8),x=Object.keys(r);return x.reduce(function(g,E){var A=r[E],T=A.domain,P=A.reversed,_;if(ke(A.range))i==="angleAxis"?_=[f,d]:i==="radiusAxis"&&(_=[b,O]),P&&(_=[_[1],_[0]]);else{_=A.range;var j=_,N=e5(j,2);f=N[0],d=N[1]}var R=VN(A,o),D=R.realScaleType,W=R.scale;W.domain(T).range(_),GN(W);var B=XN(W,mn(mn({},A),{},{realScaleType:D})),M=mn(mn(mn({},A),B),{},{range:_,radius:O,realScaleType:D,scale:W,cx:v,cy:p,innerRadius:b,outerRadius:O,startAngle:f,endAngle:d});return mn(mn({},g),{},ZN({},E,M))},{})},s5=function(t,r){var n=t.x,i=t.y,o=r.x,u=r.y;return Math.sqrt(Math.pow(n-o,2)+Math.pow(i-u,2))},u5=function(t,r){var n=t.x,i=t.y,o=r.cx,u=r.cy,l=s5({x:n,y:i},{x:o,y:u});if(l<=0)return{radius:l};var f=(n-o)/l,d=Math.acos(f);return i>u&&(d=2*Math.PI-d),{radius:l,angle:a5(d),angleInRadian:d}},l5=function(t){var r=t.startAngle,n=t.endAngle,i=Math.floor(r/360),o=Math.floor(n/360),u=Math.min(i,o);return{startAngle:r-u*360,endAngle:n-u*360}},c5=function(t,r){var n=r.startAngle,i=r.endAngle,o=Math.floor(n/360),u=Math.floor(i/360),l=Math.min(o,u);return t+l*360},Ij=function(t,r){var n=t.x,i=t.y,o=u5({x:n,y:i},r),u=o.radius,l=o.angle,f=r.innerRadius,d=r.outerRadius;if(ud)return!1;if(u===0)return!0;var v=l5(r),p=v.startAngle,m=v.endAngle,b=l,O;if(p<=m){for(;b>m;)b-=360;for(;b=p&&b<=m}else{for(;b>p;)b-=360;for(;b=m&&b<=p}return O?mn(mn({},r),{},{radius:u,angle:c5(b,r)}):null},eR=function(t){return!C.isValidElement(t)&&!je(t)&&typeof t!="boolean"?t.className:""};function au(e){"@babel/helpers - typeof";return au=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},au(e)}var f5=["offset"];function d5(e){return m5(e)||v5(e)||h5(e)||p5()}function p5(){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 h5(e,t){if(e){if(typeof e=="string")return f0(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 f0(e,t)}}function v5(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function m5(e){if(Array.isArray(e))return f0(e)}function f0(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 g5(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function Dj(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 bt(e){for(var t=1;t=0?1:-1,T,P;i==="insideStart"?(T=b+A*u,P=x):i==="insideEnd"?(T=O-A*u,P=!x):i==="end"&&(T=O+A*u,P=x),P=E<=0?P:!P;var _=Ze(d,v,g,T),j=Ze(d,v,g,T+(P?1:-1)*359),N="M".concat(_.x,",").concat(_.y,` A`).concat(g,",").concat(g,",0,1,").concat(P?0:1,`, `).concat(j.x,",").concat(j.y),R=ke(t.id)?So("recharts-radial-line-"):t.id;return I.createElement("text",ou({},n,{dominantBaseline:"central",className:Me("recharts-radial-bar-label",l)}),I.createElement("defs",null,I.createElement("path",{id:R,d:N})),I.createElement("textPath",{xlinkHref:"#".concat(R)},r))},P5=function(t){var r=t.viewBox,n=t.offset,i=t.position,o=r,u=o.cx,l=o.cy,f=o.innerRadius,d=o.outerRadius,v=o.startAngle,p=o.endAngle,m=(v+p)/2;if(i==="outside"){var b=Ze(u,l,d+n,m),O=b.x,x=b.y;return{x:O,y:x,textAnchor:O>=u?"start":"end",verticalAnchor:"middle"}}if(i==="center")return{x:u,y:l,textAnchor:"middle",verticalAnchor:"middle"};if(i==="centerTop")return{x:u,y:l,textAnchor:"middle",verticalAnchor:"start"};if(i==="centerBottom")return{x:u,y:l,textAnchor:"middle",verticalAnchor:"end"};var g=(f+d)/2,E=Ze(u,l,g,m),A=E.x,T=E.y;return{x:A,y:T,textAnchor:"middle",verticalAnchor:"middle"}},E5=function(t){var r=t.viewBox,n=t.parentViewBox,i=t.offset,o=t.position,u=r,l=u.x,f=u.y,d=u.width,v=u.height,p=v>=0?1:-1,m=p*i,b=p>0?"end":"start",O=p>0?"start":"end",x=d>=0?1:-1,g=x*i,E=x>0?"end":"start",A=x>0?"start":"end";if(o==="top"){var T={x:l+d/2,y:f-p*i,textAnchor:"middle",verticalAnchor:b};return bt(bt({},T),n?{height:Math.max(f-n.y,0),width:d}:{})}if(o==="bottom"){var P={x:l+d/2,y:f+v+m,textAnchor:"middle",verticalAnchor:O};return bt(bt({},P),n?{height:Math.max(n.y+n.height-(f+v),0),width:d}:{})}if(o==="left"){var _={x:l-g,y:f+v/2,textAnchor:E,verticalAnchor:"middle"};return bt(bt({},_),n?{width:Math.max(_.x-n.x,0),height:v}:{})}if(o==="right"){var j={x:l+d+g,y:f+v/2,textAnchor:A,verticalAnchor:"middle"};return bt(bt({},j),n?{width:Math.max(n.x+n.width-j.x,0),height:v}:{})}var N=n?{width:d,height:v}:{};return o==="insideLeft"?bt({x:l+g,y:f+v/2,textAnchor:A,verticalAnchor:"middle"},N):o==="insideRight"?bt({x:l+d-g,y:f+v/2,textAnchor:E,verticalAnchor:"middle"},N):o==="insideTop"?bt({x:l+d/2,y:f+m,textAnchor:"middle",verticalAnchor:O},N):o==="insideBottom"?bt({x:l+d/2,y:f+v-m,textAnchor:"middle",verticalAnchor:b},N):o==="insideTopLeft"?bt({x:l+g,y:f+m,textAnchor:A,verticalAnchor:O},N):o==="insideTopRight"?bt({x:l+d-g,y:f+m,textAnchor:E,verticalAnchor:O},N):o==="insideBottomLeft"?bt({x:l+g,y:f+v-m,textAnchor:A,verticalAnchor:b},N):o==="insideBottomRight"?bt({x:l+d-g,y:f+v-m,textAnchor:E,verticalAnchor:b},N):wo(o)&&(le(o.x)||$i(o.x))&&(le(o.y)||$i(o.y))?bt({x:l+zt(o.x,d),y:f+zt(o.y,v),textAnchor:"end",verticalAnchor:"end"},N):bt({x:l+d/2,y:f+v/2,textAnchor:"middle",verticalAnchor:"middle"},N)},j5=function(t){return"cx"in t&&le(t.cx)};function jt(e){var t=e.offset,r=t===void 0?5:t,n=y5(e,f5),i=bt({offset:r},n),o=i.viewBox,u=i.position,l=i.value,f=i.children,d=i.content,v=i.className,p=v===void 0?"":v,m=i.textBreakAll;if(!o||ke(l)&&ke(f)&&!C.isValidElement(d)&&!je(d))return null;if(C.isValidElement(d))return C.cloneElement(d,i);var b;if(je(d)){if(b=C.createElement(d,i),C.isValidElement(b))return b}else b=S5(i);var O=j5(o),x=Se(i,!0);if(O&&(u==="insideStart"||u==="insideEnd"||u==="end"))return _5(i,b,x);var g=O?P5(i):E5(i);return I.createElement(Ui,ou({className:Me("recharts-label",p)},x,g,{breakAll:m}),b)}jt.displayName="Label";var tR=function(t){var r=t.cx,n=t.cy,i=t.angle,o=t.startAngle,u=t.endAngle,l=t.r,f=t.radius,d=t.innerRadius,v=t.outerRadius,p=t.x,m=t.y,b=t.top,O=t.left,x=t.width,g=t.height,E=t.clockWise,A=t.labelViewBox;if(A)return A;if(le(x)&&le(g)){if(le(p)&&le(m))return{x:p,y:m,width:x,height:g};if(le(b)&&le(O))return{x:b,y:O,width:x,height:g}}return le(p)&&le(m)?{x:p,y:m,width:0,height:0}:le(r)&&le(n)?{cx:r,cy:n,startAngle:o||i||0,endAngle:u||i||0,innerRadius:d||0,outerRadius:v||f||l||0,clockWise:E}:t.viewBox?t.viewBox:{}},A5=function(t,r){return t?t===!0?I.createElement(jt,{key:"label-implicit",viewBox:r}):wt(t)?I.createElement(jt,{key:"label-implicit",viewBox:r,value:t}):C.isValidElement(t)?t.type===jt?C.cloneElement(t,{key:"label-implicit",viewBox:r}):I.createElement(jt,{key:"label-implicit",content:t,viewBox:r}):je(t)?I.createElement(jt,{key:"label-implicit",content:t,viewBox:r}):wo(t)?I.createElement(jt,ou({viewBox:r},t,{key:"label-implicit"})):null:null},T5=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=tR(t),u=cr(i,jt).map(function(f,d){return C.cloneElement(f,{viewBox:r||o,key:"label-".concat(d)})});if(!n)return u;var l=A5(t.label,r||o);return[l].concat(d5(u))};jt.parseViewBox=tR;jt.renderCallByParent=T5;var Uy,Lj;function C5(){if(Lj)return Uy;Lj=1;function e(t){var r=t==null?0:t.length;return r?t[r-1]:void 0}return Uy=e,Uy}var k5=C5();const N5=Ue(k5);function su(e){"@babel/helpers - typeof";return su=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},su(e)}var R5=["valueAccessor"],M5=["data","dataKey","clockWise","id","textBreakAll"];function $5(e){return B5(e)||L5(e)||D5(e)||I5()}function I5(){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 D5(e,t){if(e){if(typeof e=="string")return d0(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 d0(e,t)}}function L5(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function B5(e){if(Array.isArray(e))return d0(e)}function d0(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 U5(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}var W5=function(t){return Array.isArray(t.value)?N5(t.value):t.value};function En(e){var t=e.valueAccessor,r=t===void 0?W5:t,n=qj(e,R5),i=n.data,o=n.dataKey,u=n.clockWise,l=n.id,f=n.textBreakAll,d=qj(n,M5);return!i||!i.length?null:I.createElement(qe,{className:"recharts-label-list"},i.map(function(v,p){var m=ke(o)?r(v,p):xt(v&&v.payload,o),b=ke(l)?{}:{id:"".concat(l,"-").concat(p)};return I.createElement(jt,Wc({},Se(v,!0),d,b,{parentViewBox:v.parentViewBox,value:m,textBreakAll:f,viewBox:jt.parseViewBox(ke(u)?v:Fj(Fj({},v),{},{clockWise:u})),key:"label-".concat(p),index:p}))}))}En.displayName="LabelList";function H5(e,t){return e?e===!0?I.createElement(En,{key:"labelList-implicit",data:t}):I.isValidElement(e)||je(e)?I.createElement(En,{key:"labelList-implicit",data:t,content:e}):wo(e)?I.createElement(En,Wc({data:t},e,{key:"labelList-implicit"})):null:null}function K5(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=cr(n,En).map(function(u,l){return C.cloneElement(u,{data:t,key:"labelList-".concat(l)})});if(!r)return i;var o=H5(e.label,t);return[o].concat($5(i))}En.renderCallByParent=K5;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 p0(){return p0=Object.assign?Object.assign.bind():function(e){for(var t=1;t180),",").concat(+(u>d),`, `).concat(p.x,",").concat(p.y,` `);if(i>0){var b=Ze(r,n,i,u),O=Ze(r,n,i,d);m+="L ".concat(O.x,",").concat(O.y,` A `).concat(i,",").concat(i,`,0, `).concat(+(Math.abs(f)>180),",").concat(+(u<=d),`, `).concat(b.x,",").concat(b.y," Z")}else m+="L ".concat(r,",").concat(n," Z");return m},Q5=function(t){var r=t.cx,n=t.cy,i=t.innerRadius,o=t.outerRadius,u=t.cornerRadius,l=t.forceCornerRadius,f=t.cornerIsExternal,d=t.startAngle,v=t.endAngle,p=qt(v-d),m=ac({cx:r,cy:n,radius:o,angle:d,sign:p,cornerRadius:u,cornerIsExternal:f}),b=m.circleTangency,O=m.lineTangency,x=m.theta,g=ac({cx:r,cy:n,radius:o,angle:v,sign:-p,cornerRadius:u,cornerIsExternal:f}),E=g.circleTangency,A=g.lineTangency,T=g.theta,P=f?Math.abs(d-v):Math.abs(d-v)-x-T;if(P<0)return l?"M ".concat(O.x,",").concat(O.y,` a`).concat(u,",").concat(u,",0,0,1,").concat(u*2,`,0 a`).concat(u,",").concat(u,",0,0,1,").concat(-u*2,`,0 `):rR({cx:r,cy:n,innerRadius:i,outerRadius:o,startAngle:d,endAngle:v});var _="M ".concat(O.x,",").concat(O.y,` A`).concat(u,",").concat(u,",0,0,").concat(+(p<0),",").concat(b.x,",").concat(b.y,` A`).concat(o,",").concat(o,",0,").concat(+(P>180),",").concat(+(p<0),",").concat(E.x,",").concat(E.y,` A`).concat(u,",").concat(u,",0,0,").concat(+(p<0),",").concat(A.x,",").concat(A.y,` `);if(i>0){var j=ac({cx:r,cy:n,radius:i,angle:d,sign:p,isExternal:!0,cornerRadius:u,cornerIsExternal:f}),N=j.circleTangency,R=j.lineTangency,D=j.theta,W=ac({cx:r,cy:n,radius:i,angle:v,sign:-p,isExternal:!0,cornerRadius:u,cornerIsExternal:f}),B=W.circleTangency,M=W.lineTangency,z=W.theta,G=f?Math.abs(d-v):Math.abs(d-v)-D-z;if(G<0&&u===0)return"".concat(_,"L").concat(r,",").concat(n,"Z");_+="L".concat(M.x,",").concat(M.y,` A`).concat(u,",").concat(u,",0,0,").concat(+(p<0),",").concat(B.x,",").concat(B.y,` A`).concat(i,",").concat(i,",0,").concat(+(G>180),",").concat(+(p>0),",").concat(N.x,",").concat(N.y,` A`).concat(u,",").concat(u,",0,0,").concat(+(p<0),",").concat(R.x,",").concat(R.y,"Z")}else _+="L".concat(r,",").concat(n,"Z");return _},Z5={cx:0,cy:0,innerRadius:0,outerRadius:0,startAngle:0,endAngle:0,cornerRadius:0,forceCornerRadius:!1,cornerIsExternal:!1},nR=function(t){var r=Uj(Uj({},Z5),t),n=r.cx,i=r.cy,o=r.innerRadius,u=r.outerRadius,l=r.cornerRadius,f=r.forceCornerRadius,d=r.cornerIsExternal,v=r.startAngle,p=r.endAngle,m=r.className;if(u0&&Math.abs(v-p)<360?g=Q5({cx:n,cy:i,innerRadius:o,outerRadius:u,cornerRadius:Math.min(x,O/2),forceCornerRadius:f,cornerIsExternal:d,startAngle:v,endAngle:p}):g=rR({cx:n,cy:i,innerRadius:o,outerRadius:u,startAngle:v,endAngle:p}),I.createElement("path",p0({},Se(r,!0),{className:b,d:g,role:"img"}))};function lu(e){"@babel/helpers - typeof";return lu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},lu(e)}function h0(){return h0=Object.assign?Object.assign.bind():function(e){for(var t=1;toW.call(e,t));function Ji(e,t){return e===t||!e&&!t&&e!==e&&t!==t}const lW="__v",cW="__o",fW="_owner",{getOwnPropertyDescriptor:Gj,keys:Xj}=Object;function dW(e,t){return e.byteLength===t.byteLength&&Kc(new Uint8Array(e),new Uint8Array(t))}function pW(e,t,r){let n=e.length;if(t.length!==n)return!1;for(;n-- >0;)if(!r.equals(e[n],t[n],n,n,e,t,r))return!1;return!0}function hW(e,t){return e.byteLength===t.byteLength&&Kc(new Uint8Array(e.buffer,e.byteOffset,e.byteLength),new Uint8Array(t.buffer,t.byteOffset,t.byteLength))}function vW(e,t){return Ji(e.getTime(),t.getTime())}function mW(e,t){return e.name===t.name&&e.message===t.message&&e.cause===t.cause&&e.stack===t.stack}function yW(e,t){return e===t}function Yj(e,t,r){const n=e.size;if(n!==t.size)return!1;if(!n)return!0;const i=new Array(n),o=e.entries();let u,l,f=0;for(;(u=o.next())&&!u.done;){const d=t.entries();let v=!1,p=0;for(;(l=d.next())&&!l.done;){if(i[p]){p++;continue}const m=u.value,b=l.value;if(r.equals(m[0],b[0],f,p,e,t,r)&&r.equals(m[1],b[1],m[0],b[0],e,t,r)){v=i[p]=!0;break}p++}if(!v)return!1;f++}return!0}const gW=Ji;function bW(e,t,r){const n=Xj(e);let i=n.length;if(Xj(t).length!==i)return!1;for(;i-- >0;)if(!iR(e,t,r,n[i]))return!1;return!0}function Os(e,t,r){const n=Vj(e);let i=n.length;if(Vj(t).length!==i)return!1;let o,u,l;for(;i-- >0;)if(o=n[i],!iR(e,t,r,o)||(u=Gj(e,o),l=Gj(t,o),(u||l)&&(!u||!l||u.configurable!==l.configurable||u.enumerable!==l.enumerable||u.writable!==l.writable)))return!1;return!0}function xW(e,t){return Ji(e.valueOf(),t.valueOf())}function wW(e,t){return e.source===t.source&&e.flags===t.flags}function Qj(e,t,r){const n=e.size;if(n!==t.size)return!1;if(!n)return!0;const i=new Array(n),o=e.values();let u,l;for(;(u=o.next())&&!u.done;){const f=t.values();let d=!1,v=0;for(;(l=f.next())&&!l.done;){if(!i[v]&&r.equals(u.value,l.value,u.value,l.value,e,t,r)){d=i[v]=!0;break}v++}if(!d)return!1}return!0}function Kc(e,t){let r=e.byteLength;if(t.byteLength!==r||e.byteOffset!==t.byteOffset)return!1;for(;r-- >0;)if(e[r]!==t[r])return!1;return!0}function SW(e,t){return e.hostname===t.hostname&&e.pathname===t.pathname&&e.protocol===t.protocol&&e.port===t.port&&e.hash===t.hash&&e.username===t.username&&e.password===t.password}function iR(e,t,r,n){return(n===fW||n===cW||n===lW)&&(e.$$typeof||t.$$typeof)?!0:uW(t,n)&&r.equals(e[n],t[n],n,n,e,t,r)}const OW="[object ArrayBuffer]",_W="[object Arguments]",PW="[object Boolean]",EW="[object DataView]",jW="[object Date]",AW="[object Error]",TW="[object Map]",CW="[object Number]",kW="[object Object]",NW="[object RegExp]",RW="[object Set]",MW="[object String]",$W={"[object Int8Array]":!0,"[object Uint8Array]":!0,"[object Uint8ClampedArray]":!0,"[object Int16Array]":!0,"[object Uint16Array]":!0,"[object Int32Array]":!0,"[object Uint32Array]":!0,"[object Float16Array]":!0,"[object Float32Array]":!0,"[object Float64Array]":!0,"[object BigInt64Array]":!0,"[object BigUint64Array]":!0},IW="[object URL]",DW=Object.prototype.toString;function LW({areArrayBuffersEqual:e,areArraysEqual:t,areDataViewsEqual:r,areDatesEqual:n,areErrorsEqual:i,areFunctionsEqual:o,areMapsEqual:u,areNumbersEqual:l,areObjectsEqual:f,arePrimitiveWrappersEqual:d,areRegExpsEqual:v,areSetsEqual:p,areTypedArraysEqual:m,areUrlsEqual:b,unknownTagComparators:O}){return function(g,E,A){if(g===E)return!0;if(g==null||E==null)return!1;const T=typeof g;if(T!==typeof E)return!1;if(T!=="object")return T==="number"?l(g,E,A):T==="function"?o(g,E,A):!1;const P=g.constructor;if(P!==E.constructor)return!1;if(P===Object)return f(g,E,A);if(Array.isArray(g))return t(g,E,A);if(P===Date)return n(g,E,A);if(P===RegExp)return v(g,E,A);if(P===Map)return u(g,E,A);if(P===Set)return p(g,E,A);const _=DW.call(g);if(_===jW)return n(g,E,A);if(_===NW)return v(g,E,A);if(_===TW)return u(g,E,A);if(_===RW)return p(g,E,A);if(_===kW)return typeof g.then!="function"&&typeof E.then!="function"&&f(g,E,A);if(_===IW)return b(g,E,A);if(_===AW)return i(g,E,A);if(_===_W)return f(g,E,A);if($W[_])return m(g,E,A);if(_===OW)return e(g,E,A);if(_===EW)return r(g,E,A);if(_===PW||_===CW||_===MW)return d(g,E,A);if(O){let j=O[_];if(!j){const N=sW(g);N&&(j=O[N])}if(j)return j(g,E,A)}return!1}}function BW({circular:e,createCustomConfig:t,strict:r}){let n={areArrayBuffersEqual:dW,areArraysEqual:r?Os:pW,areDataViewsEqual:hW,areDatesEqual:vW,areErrorsEqual:mW,areFunctionsEqual:yW,areMapsEqual:r?Wy(Yj,Os):Yj,areNumbersEqual:gW,areObjectsEqual:r?Os:bW,arePrimitiveWrappersEqual:xW,areRegExpsEqual:wW,areSetsEqual:r?Wy(Qj,Os):Qj,areTypedArraysEqual:r?Wy(Kc,Os):Kc,areUrlsEqual:SW,unknownTagComparators:void 0};if(t&&(n=Object.assign({},n,t(n))),e){const i=sc(n.areArraysEqual),o=sc(n.areMapsEqual),u=sc(n.areObjectsEqual),l=sc(n.areSetsEqual);n=Object.assign({},n,{areArraysEqual:i,areMapsEqual:o,areObjectsEqual:u,areSetsEqual:l})}return n}function FW(e){return function(t,r,n,i,o,u,l){return e(t,r,l)}}function qW({circular:e,comparator:t,createState:r,equals:n,strict:i}){if(r)return function(l,f){const{cache:d=e?new WeakMap:void 0,meta:v}=r();return t(l,f,{cache:d,equals:n,meta:v,strict:i})};if(e)return function(l,f){return t(l,f,{cache:new WeakMap,equals:n,meta:void 0,strict:i})};const o={cache:void 0,equals:n,meta:void 0,strict:i};return function(l,f){return t(l,f,o)}}const zW=pi();pi({strict:!0});pi({circular:!0});pi({circular:!0,strict:!0});pi({createInternalComparator:()=>Ji});pi({strict:!0,createInternalComparator:()=>Ji});pi({circular:!0,createInternalComparator:()=>Ji});pi({circular:!0,createInternalComparator:()=>Ji,strict:!0});function pi(e={}){const{circular:t=!1,createInternalComparator:r,createState:n,strict:i=!1}=e,o=BW(e),u=LW(o),l=r?r(u):FW(u);return qW({circular:t,comparator:u,createState:n,equals:l,strict:i})}function UW(e){typeof requestAnimationFrame<"u"&&requestAnimationFrame(e)}function Zj(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):UW(i)};requestAnimationFrame(n)}function v0(e){"@babel/helpers - typeof";return v0=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},v0(e)}function WW(e){return GW(e)||VW(e)||KW(e)||HW()}function HW(){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 KW(e,t){if(e){if(typeof e=="string")return Jj(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 Jj(e,t)}}function Jj(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:E<0?0:E},x=function(E){for(var A=E>1?1:E,T=A,P=0;P<8;++P){var _=p(T)-A,j=b(T);if(Math.abs(_-A)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,u=t.dt,l=u===void 0?17:u,f=function(v,p,m){var b=-(v-p)*n,O=m*o,x=m+(b-O)*l/1e3,g=m*l/1e3+v;return Math.abs(g-p)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 PH(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 Hy(e){return TH(e)||AH(e)||jH(e)||EH()}function EH(){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 jH(e,t){if(e){if(typeof e=="string")return x0(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 x0(e,t)}}function AH(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function TH(e){if(Array.isArray(e))return x0(e)}function x0(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 Xc(e){return Xc=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Xc(e)}var tn=(function(e){MH(r,e);var t=$H(r);function r(n,i){var o;CH(this,r),o=t.call(this,n,i);var u=o.props,l=u.isActive,f=u.attributeName,d=u.from,v=u.to,p=u.steps,m=u.children,b=u.duration;if(o.handleStyleChange=o.handleStyleChange.bind(O0(o)),o.changeStyle=o.changeStyle.bind(O0(o)),!l||b<=0)return o.state={style:{}},typeof m=="function"&&(o.state={style:v}),S0(o);if(p&&p.length)o.state={style:p[0].style};else if(d){if(typeof m=="function")return o.state={style:d},S0(o);o.state={style:f?As({},f,d):d}}else o.state={style:{}};return o}return NH(r,[{key:"componentDidMount",value:function(){var i=this.props,o=i.isActive,u=i.canBegin;this.mounted=!0,!(!o||!u)&&this.runAnimation(this.props)}},{key:"componentDidUpdate",value:function(i){var o=this.props,u=o.isActive,l=o.canBegin,f=o.attributeName,d=o.shouldReAnimate,v=o.to,p=o.from,m=this.state.style;if(l){if(!u){var b={style:f?As({},f,v):v};this.state&&m&&(f&&m[f]!==v||!f&&m!==v)&&this.setState(b);return}if(!(zW(i.to,v)&&i.canBegin&&i.isActive)){var O=!i.canBegin||!i.isActive;this.manager&&this.manager.stop(),this.stopJSAnimation&&this.stopJSAnimation();var x=O||d?p:i.to;if(this.state&&m){var g={style:f?As({},f,x):x};(f&&m[f]!==x||!f&&m!==x)&&this.setState(g)}this.runAnimation($r($r({},this.props),{},{from:x,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,u=i.from,l=i.to,f=i.duration,d=i.easing,v=i.begin,p=i.onAnimationEnd,m=i.onAnimationStart,b=SH(u,l,fH(d),f,this.changeStyle),O=function(){o.stopJSAnimation=b()};this.manager.start([m,v,O,f,p])}},{key:"runStepAnimation",value:function(i){var o=this,u=i.steps,l=i.begin,f=i.onAnimationStart,d=u[0],v=d.style,p=d.duration,m=p===void 0?0:p,b=function(x,g,E){if(E===0)return x;var A=g.duration,T=g.easing,P=T===void 0?"ease":T,_=g.style,j=g.properties,N=g.onAnimationEnd,R=E>0?u[E-1]:g,D=j||Object.keys(_);if(typeof P=="function"||P==="spring")return[].concat(Hy(x),[o.runJSAnimation.bind(o,{from:R.style,to:_,duration:A,easing:P}),A]);var W=rA(D,A,P),B=$r($r($r({},R.style),_),{},{transition:W});return[].concat(Hy(x),[B,A,N]).filter(JW)};return this.manager.start([f].concat(Hy(u.reduce(b,[v,Math.max(m,l)])),[i.onAnimationEnd]))}},{key:"runAnimation",value:function(i){this.manager||(this.manager=XW());var o=i.begin,u=i.duration,l=i.attributeName,f=i.to,d=i.easing,v=i.onAnimationStart,p=i.onAnimationEnd,m=i.steps,b=i.children,O=this.manager;if(this.unSubscribe=O.subscribe(this.handleStyleChange),typeof d=="function"||typeof b=="function"||d==="spring"){this.runJSAnimation(i);return}if(m.length>1){this.runStepAnimation(i);return}var x=l?As({},l,f):f,g=rA(Object.keys(x),u,d);O.start([v,o,$r($r({},x),{},{transition:g}),u,p])}},{key:"render",value:function(){var i=this.props,o=i.children;i.begin;var u=i.duration;i.attributeName,i.easing;var l=i.isActive;i.steps,i.from,i.to,i.canBegin,i.onAnimationEnd,i.shouldReAnimate,i.onAnimationReStart;var f=_H(i,OH),d=C.Children.count(o),v=this.state.style;if(typeof o=="function")return o(v);if(!l||d===0||u<=0)return o;var p=function(b){var O=b.props,x=O.style,g=x===void 0?{}:x,E=O.className,A=C.cloneElement(b,$r($r({},f),{},{style:$r($r({},g),v),className:E}));return A};return d===1?p(C.Children.only(o)):I.createElement("div",null,C.Children.map(o,function(m){return p(m)}))}}]),r})(C.PureComponent);tn.displayName="Animate";tn.defaultProps={begin:0,duration:1e3,from:"",to:"",attributeName:"",easing:"ease",isActive:!0,canBegin:!0,steps:[],onAnimationEnd:function(){},onAnimationStart:function(){}};tn.propTypes={from:$e.oneOfType([$e.object,$e.string]),to:$e.oneOfType([$e.object,$e.string]),attributeName:$e.string,duration:$e.number,begin:$e.number,easing:$e.oneOfType([$e.string,$e.func]),steps:$e.arrayOf($e.shape({duration:$e.number.isRequired,style:$e.object.isRequired,easing:$e.oneOfType([$e.oneOf(["ease","ease-in","ease-out","ease-in-out","linear"]),$e.func]),properties:$e.arrayOf("string"),onAnimationEnd:$e.func})),children:$e.oneOfType([$e.node,$e.func]),isActive:$e.bool,canBegin:$e.bool,onAnimationEnd:$e.func,shouldReAnimate:$e.bool,onAnimationStart:$e.func,onAnimationReStart:$e.func};function du(e){"@babel/helpers - typeof";return du=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},du(e)}function Yc(){return Yc=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,f=n>=0?1:-1,d=i>=0&&n>=0||i<0&&n<0?1:0,v;if(u>0&&o instanceof Array){for(var p=[0,0,0,0],m=0,b=4;mu?u:o[m];v="M".concat(t,",").concat(r+l*p[0]),p[0]>0&&(v+="A ".concat(p[0],",").concat(p[0],",0,0,").concat(d,",").concat(t+f*p[0],",").concat(r)),v+="L ".concat(t+n-f*p[1],",").concat(r),p[1]>0&&(v+="A ".concat(p[1],",").concat(p[1],",0,0,").concat(d,`, `).concat(t+n,",").concat(r+l*p[1])),v+="L ".concat(t+n,",").concat(r+i-l*p[2]),p[2]>0&&(v+="A ".concat(p[2],",").concat(p[2],",0,0,").concat(d,`, `).concat(t+n-f*p[2],",").concat(r+i)),v+="L ".concat(t+f*p[3],",").concat(r+i),p[3]>0&&(v+="A ".concat(p[3],",").concat(p[3],",0,0,").concat(d,`, `).concat(t,",").concat(r+i-l*p[3])),v+="Z"}else if(u>0&&o===+o&&o>0){var O=Math.min(u,o);v="M ".concat(t,",").concat(r+l*O,` A `).concat(O,",").concat(O,",0,0,").concat(d,",").concat(t+f*O,",").concat(r,` L `).concat(t+n-f*O,",").concat(r,` A `).concat(O,",").concat(O,",0,0,").concat(d,",").concat(t+n,",").concat(r+l*O,` L `).concat(t+n,",").concat(r+i-l*O,` A `).concat(O,",").concat(O,",0,0,").concat(d,",").concat(t+n-f*O,",").concat(r+i,` L `).concat(t+f*O,",").concat(r+i,` A `).concat(O,",").concat(O,",0,0,").concat(d,",").concat(t,",").concat(r+i-l*O," Z")}else v="M ".concat(t,",").concat(r," h ").concat(n," v ").concat(i," h ").concat(-n," Z");return v},HH=function(t,r){if(!t||!r)return!1;var n=t.x,i=t.y,o=r.x,u=r.y,l=r.width,f=r.height;if(Math.abs(l)>0&&Math.abs(f)>0){var d=Math.min(o,o+l),v=Math.max(o,o+l),p=Math.min(u,u+f),m=Math.max(u,u+f);return n>=d&&n<=v&&i>=p&&i<=m}return!1},KH={x:0,y:0,width:0,height:0,radius:0,isAnimationActive:!1,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:"ease"},nx=function(t){var r=cA(cA({},KH),t),n=C.useRef(),i=C.useState(-1),o=DH(i,2),u=o[0],l=o[1];C.useEffect(function(){if(n.current&&n.current.getTotalLength)try{var P=n.current.getTotalLength();P&&l(P)}catch{}},[]);var f=r.x,d=r.y,v=r.width,p=r.height,m=r.radius,b=r.className,O=r.animationEasing,x=r.animationDuration,g=r.animationBegin,E=r.isAnimationActive,A=r.isUpdateAnimationActive;if(f!==+f||d!==+d||v!==+v||p!==+p||v===0||p===0)return null;var T=Me("recharts-rectangle",b);return A?I.createElement(tn,{canBegin:u>0,from:{width:v,height:p,x:f,y:d},to:{width:v,height:p,x:f,y:d},duration:x,animationEasing:O,isActive:A},function(P){var _=P.width,j=P.height,N=P.x,R=P.y;return I.createElement(tn,{canBegin:u>0,from:"0px ".concat(u===-1?1:u,"px"),to:"".concat(u,"px 0px"),attributeName:"strokeDasharray",begin:g,duration:x,isActive:E,easing:O},I.createElement("path",Yc({},Se(r,!0),{className:T,d:fA(N,R,_,j,m),ref:n})))}):I.createElement("path",Yc({},Se(r,!0),{className:T,d:fA(f,d,v,p,m)}))},VH=["points","className","baseLinePoints","connectNulls"];function Ia(){return Ia=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 XH(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function dA(e){return JH(e)||ZH(e)||QH(e)||YH()}function YH(){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 QH(e,t){if(e){if(typeof e=="string")return _0(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 _0(e,t)}}function ZH(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function JH(e){if(Array.isArray(e))return _0(e)}function _0(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]:[],r=[[]];return t.forEach(function(n){pA(n)?r[r.length-1].push(n):r[r.length-1].length>0&&r.push([])}),pA(t[0])&&r[r.length-1].push(t[0]),r[r.length-1].length<=0&&(r=r.slice(0,-1)),r},Rs=function(t,r){var n=eK(t);r&&(n=[n.reduce(function(o,u){return[].concat(dA(o),dA(u))},[])]);var i=n.map(function(o){return o.reduce(function(u,l,f){return"".concat(u).concat(f===0?"M":"L").concat(l.x,",").concat(l.y)},"")}).join("");return n.length===1?"".concat(i,"Z"):i},tK=function(t,r,n){var i=Rs(t,n);return"".concat(i.slice(-1)==="Z"?i.slice(0,-1):i,"L").concat(Rs(r.reverse(),n).slice(1))},rK=function(t){var r=t.points,n=t.className,i=t.baseLinePoints,o=t.connectNulls,u=GH(t,VH);if(!r||!r.length)return null;var l=Me("recharts-polygon",n);if(i&&i.length){var f=u.stroke&&u.stroke!=="none",d=tK(r,i,o);return I.createElement("g",{className:l},I.createElement("path",Ia({},Se(u,!0),{fill:d.slice(-1)==="Z"?u.fill:"none",stroke:"none",d})),f?I.createElement("path",Ia({},Se(u,!0),{fill:"none",d:Rs(r,o)})):null,f?I.createElement("path",Ia({},Se(u,!0),{fill:"none",d:Rs(i,o)})):null)}var v=Rs(r,o);return I.createElement("path",Ia({},Se(u,!0),{fill:v.slice(-1)==="Z"?u.fill:"none",className:l,d:v}))};function P0(){return P0=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 lK(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}var cK=function(t,r,n,i,o,u){return"M".concat(t,",").concat(o,"v").concat(i,"M").concat(u,",").concat(r,"h").concat(n)},fK=function(t){var r=t.x,n=r===void 0?0:r,i=t.y,o=i===void 0?0:i,u=t.top,l=u===void 0?0:u,f=t.left,d=f===void 0?0:f,v=t.width,p=v===void 0?0:v,m=t.height,b=m===void 0?0:m,O=t.className,x=uK(t,nK),g=iK({x:n,y:o,top:l,left:d,width:p,height:b},x);return!le(n)||!le(o)||!le(p)||!le(b)||!le(l)||!le(d)?null:I.createElement("path",E0({},Se(g,!0),{className:Me("recharts-cross",O),d:cK(n,o,p,b,l,d)}))},Ky,vA;function dK(){if(vA)return Ky;vA=1;var e=Gf(),t=PN(),r=an();function n(i,o){return i&&i.length?e(i,r(o,2),t):void 0}return Ky=n,Ky}var pK=dK();const hK=Ue(pK);var Vy,mA;function vK(){if(mA)return Vy;mA=1;var e=Gf(),t=an(),r=EN();function n(i,o){return i&&i.length?e(i,t(o,2),r):void 0}return Vy=n,Vy}var mK=vK();const yK=Ue(mK);var gK=["cx","cy","angle","ticks","axisLine"],bK=["ticks","tick","angle","tickFormatter","stroke"];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 Ms(){return Ms=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 xK(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function wK(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function bA(e,t){for(var r=0;rSA?u=i==="outer"?"start":"end":o<-SA?u=i==="outer"?"end":"start":u="middle",u}},{key:"renderAxisLine",value:function(){var n=this.props,i=n.cx,o=n.cy,u=n.radius,l=n.axisLine,f=n.axisLineType,d=Ti(Ti({},Se(this.props,!1)),{},{fill:"none"},Se(l,!1));if(f==="circle")return I.createElement(Jf,Mi({className:"recharts-polar-angle-axis-line"},d,{cx:i,cy:o,r:u}));var v=this.props.ticks,p=v.map(function(m){return Ze(i,o,u,m.coordinate)});return I.createElement(rK,Mi({className:"recharts-polar-angle-axis-line"},d,{points:p}))}},{key:"renderTicks",value:function(){var n=this,i=this.props,o=i.ticks,u=i.tick,l=i.tickLine,f=i.tickFormatter,d=i.stroke,v=Se(this.props,!1),p=Se(u,!1),m=Ti(Ti({},v),{},{fill:"none"},Se(l,!1)),b=o.map(function(O,x){var g=n.getTickLineCoord(O),E=n.getTickTextAnchor(O),A=Ti(Ti(Ti({textAnchor:E},v),{},{stroke:"none",fill:d},p),{},{index:x,payload:O,x:g.x2,y:g.y2});return I.createElement(qe,Mi({className:Me("recharts-polar-angle-axis-tick",eR(u)),key:"tick-".concat(O.coordinate)},zi(n.props,O,x)),l&&I.createElement("line",Mi({className:"recharts-polar-angle-axis-tick-line"},m,g)),u&&t.renderTickItem(u,A,f?f(O.value,x):O.value))});return I.createElement(qe,{className:"recharts-polar-angle-axis-ticks"},b)}},{key:"render",value:function(){var n=this.props,i=n.ticks,o=n.radius,u=n.axisLine;return o<=0||!i||!i.length?null:I.createElement(qe,{className:Me("recharts-polar-angle-axis",this.props.className)},u&&this.renderAxisLine(),this.renderTicks())}}],[{key:"renderTickItem",value:function(n,i,o){var u;return I.isValidElement(n)?u=I.cloneElement(n,i):je(n)?u=n(i):u=I.createElement(Ui,Mi({},i,{className:"recharts-polar-angle-axis-tick-value"}),o),u}}])})(C.PureComponent);rd(nd,"displayName","PolarAngleAxis");rd(nd,"axisType","angleAxis");rd(nd,"defaultProps",{type:"category",angleAxisId:0,scale:"auto",cx:0,cy:0,orientation:"outer",axisLine:!0,tickLine:!0,tickSize:8,tick:!0,hide:!1,allowDuplicatedCategory:!0});var Gy,OA;function IK(){if(OA)return Gy;OA=1;var e=Pk(),t=e(Object.getPrototypeOf,Object);return Gy=t,Gy}var Xy,_A;function DK(){if(_A)return Xy;_A=1;var e=Rn(),t=IK(),r=Mn(),n="[object Object]",i=Function.prototype,o=Object.prototype,u=i.toString,l=o.hasOwnProperty,f=u.call(Object);function d(v){if(!r(v)||e(v)!=n)return!1;var p=t(v);if(p===null)return!0;var m=l.call(p,"constructor")&&p.constructor;return typeof m=="function"&&m instanceof m&&u.call(m)==f}return Xy=d,Xy}var LK=DK();const BK=Ue(LK);var Yy,PA;function FK(){if(PA)return Yy;PA=1;var e=Rn(),t=Mn(),r="[object Boolean]";function n(i){return i===!0||i===!1||t(i)&&e(i)==r}return Yy=n,Yy}var qK=FK();const zK=Ue(qK);function hu(e){"@babel/helpers - typeof";return hu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},hu(e)}function Jc(){return Jc=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:m,x:f,y:d},to:{upperWidth:v,lowerWidth:p,height:m,x:f,y:d},duration:x,animationEasing:O,isActive:E},function(T){var P=T.upperWidth,_=T.lowerWidth,j=T.height,N=T.x,R=T.y;return I.createElement(tn,{canBegin:u>0,from:"0px ".concat(u===-1?1:u,"px"),to:"".concat(u,"px 0px"),attributeName:"strokeDasharray",begin:g,duration:x,easing:O},I.createElement("path",Jc({},Se(r,!0),{className:A,d:TA(N,R,P,_,j),ref:n})))}):I.createElement("g",null,I.createElement("path",Jc({},Se(r,!0),{className:A,d:TA(f,d,v,p,m)})))},JK=["option","shapeType","propTransformer","activeClassName","isActive"];function vu(e){"@babel/helpers - typeof";return vu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},vu(e)}function e9(e,t){if(e==null)return{};var r=t9(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 t9(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function CA(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 ef(e){for(var t=1;t0?lr(T,"paddingAngle",0):0;if(_){var N=sr(_.endAngle-_.startAngle,T.endAngle-T.startAngle),R=Ye(Ye({},T),{},{startAngle:A+j,endAngle:A+N(x)+j});g.push(R),A=R.endAngle}else{var D=T.endAngle,W=T.startAngle,B=sr(0,D-W),M=B(x),z=Ye(Ye({},T),{},{startAngle:A+j,endAngle:A+M+j});g.push(z),A=z.endAngle}}),I.createElement(qe,null,n.renderSectorsStatically(g))})}},{key:"attachKeyboardHandlers",value:function(n){var i=this;n.onkeydown=function(o){if(!o.altKey)switch(o.key){case"ArrowLeft":{var u=++i.state.sectorToFocus%i.sectorRefs.length;i.sectorRefs[u].focus(),i.setState({sectorToFocus:u});break}case"ArrowRight":{var l=--i.state.sectorToFocus<0?i.sectorRefs.length-1:i.state.sectorToFocus%i.sectorRefs.length;i.sectorRefs[l].focus(),i.setState({sectorToFocus:l});break}case"Escape":{i.sectorRefs[i.state.sectorToFocus].blur(),i.setState({sectorToFocus:0});break}}}}},{key:"renderSectors",value:function(){var n=this.props,i=n.sectors,o=n.isAnimationActive,u=this.state.prevSectors;return o&&i&&i.length&&(!u||!Mu(u,i))?this.renderSectorsWithAnimation():this.renderSectorsStatically(i)}},{key:"componentDidMount",value:function(){this.pieRef&&this.attachKeyboardHandlers(this.pieRef)}},{key:"render",value:function(){var n=this,i=this.props,o=i.hide,u=i.sectors,l=i.className,f=i.label,d=i.cx,v=i.cy,p=i.innerRadius,m=i.outerRadius,b=i.isAnimationActive,O=this.state.isAnimationFinished;if(o||!u||!u.length||!le(d)||!le(v)||!le(p)||!le(m))return null;var x=Me("recharts-pie",l);return I.createElement(qe,{tabIndex:this.props.rootTabIndex,className:x,ref:function(E){n.pieRef=E}},this.renderSectors(),f&&this.renderLabels(u),jt.renderCallByParent(this.props,null,!1),(!b||O)&&En.renderCallByParent(this.props,u,!1))}}],[{key:"getDerivedStateFromProps",value:function(n,i){return i.prevIsAnimationActive!==n.isAnimationActive?{prevIsAnimationActive:n.isAnimationActive,prevAnimationId:n.animationId,curSectors:n.sectors,prevSectors:[],isAnimationFinished:!0}:n.isAnimationActive&&n.animationId!==i.prevAnimationId?{prevAnimationId:n.animationId,curSectors:n.sectors,prevSectors:i.curSectors,isAnimationFinished:!0}:n.sectors!==i.curSectors?{curSectors:n.sectors,isAnimationFinished:!0}:null}},{key:"getTextAnchor",value:function(n,i){return n>i?"start":n=360?A:A-1)*f,P=g-A*b-T,_=i.reduce(function(R,D){var W=xt(D,E,0);return R+(le(W)?W:0)},0),j;if(_>0){var N;j=i.map(function(R,D){var W=xt(R,E,0),B=xt(R,v,D),M=(le(W)?W:0)/_,z;D?z=N.endAngle+qt(x)*f*(W!==0?1:0):z=u;var G=z+qt(x)*((W!==0?b:0)+M*P),V=(z+G)/2,Y=(O.innerRadius+O.outerRadius)/2,J=[{name:B,value:W,payload:R,dataKey:E,type:m}],H=Ze(O.cx,O.cy,Y,V);return N=Ye(Ye(Ye({percent:M,cornerRadius:o,name:B,tooltipPayload:J,midAngle:V,middleRadius:Y,tooltipPosition:H},R),O),{},{value:xt(R,E),startAngle:z,endAngle:G,payload:R,paddingAngle:qt(x)*f}),N})}return Ye(Ye({},O),{},{sectors:j,data:i})});var Qy,MA;function S9(){if(MA)return Qy;MA=1;var e=Math.ceil,t=Math.max;function r(n,i,o,u){for(var l=-1,f=t(e((i-n)/(o||1)),0),d=Array(f);f--;)d[u?f:++l]=n,n+=o;return d}return Qy=r,Qy}var Zy,$A;function gR(){if($A)return Zy;$A=1;var e=qk(),t=1/0,r=17976931348623157e292;function n(i){if(!i)return i===0?i:0;if(i=e(i),i===t||i===-t){var o=i<0?-1:1;return o*r}return i===i?i:0}return Zy=n,Zy}var Jy,IA;function O9(){if(IA)return Jy;IA=1;var e=S9(),t=qf(),r=gR();function n(i){return function(o,u,l){return l&&typeof l!="number"&&t(o,u,l)&&(u=l=void 0),o=r(o),u===void 0?(u=o,o=0):u=r(u),l=l===void 0?o0&&n.handleDrag(i.changedTouches[0])}),ar(n,"handleDragEnd",function(){n.setState({isTravellerMoving:!1,isSlideMoving:!1},function(){var i=n.props,o=i.endIndex,u=i.onDragEnd,l=i.startIndex;u==null||u({endIndex:o,startIndex:l})}),n.detachDragEndListener()}),ar(n,"handleLeaveWrapper",function(){(n.state.isTravellerMoving||n.state.isSlideMoving)&&(n.leaveTimer=window.setTimeout(n.handleDragEnd,n.props.leaveTimeOut))}),ar(n,"handleEnterSlideOrTraveller",function(){n.setState({isTextActive:!0})}),ar(n,"handleLeaveSlideOrTraveller",function(){n.setState({isTextActive:!1})}),ar(n,"handleSlideDragStart",function(i){var o=zA(i)?i.changedTouches[0]:i;n.setState({isTravellerMoving:!1,isSlideMoving:!0,slideMoveStartX:o.pageX}),n.attachDragEndListener()}),n.travellerDragStartHandlers={startX:n.handleTravellerDragStart.bind(n,"startX"),endX:n.handleTravellerDragStart.bind(n,"endX")},n.state={},n}return $9(t,e),k9(t,[{key:"componentWillUnmount",value:function(){this.leaveTimer&&(clearTimeout(this.leaveTimer),this.leaveTimer=null),this.detachDragEndListener()}},{key:"getIndex",value:function(n){var i=n.startX,o=n.endX,u=this.state.scaleValues,l=this.props,f=l.gap,d=l.data,v=d.length-1,p=Math.min(i,o),m=Math.max(i,o),b=t.getIndexInRange(u,p),O=t.getIndexInRange(u,m);return{startIndex:b-b%f,endIndex:O===v?v:O-O%f}}},{key:"getTextOfTick",value:function(n){var i=this.props,o=i.data,u=i.tickFormatter,l=i.dataKey,f=xt(o[n],l,n);return je(u)?u(f,n):f}},{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(n){var i=this.state,o=i.slideMoveStartX,u=i.startX,l=i.endX,f=this.props,d=f.x,v=f.width,p=f.travellerWidth,m=f.startIndex,b=f.endIndex,O=f.onChange,x=n.pageX-o;x>0?x=Math.min(x,d+v-p-l,d+v-p-u):x<0&&(x=Math.max(x,d-u,d-l));var g=this.getIndex({startX:u+x,endX:l+x});(g.startIndex!==m||g.endIndex!==b)&&O&&O(g),this.setState({startX:u+x,endX:l+x,slideMoveStartX:n.pageX})}},{key:"handleTravellerDragStart",value:function(n,i){var o=zA(i)?i.changedTouches[0]:i;this.setState({isSlideMoving:!1,isTravellerMoving:!0,movingTravellerId:n,brushMoveStartX:o.pageX}),this.attachDragEndListener()}},{key:"handleTravellerMove",value:function(n){var i=this.state,o=i.brushMoveStartX,u=i.movingTravellerId,l=i.endX,f=i.startX,d=this.state[u],v=this.props,p=v.x,m=v.width,b=v.travellerWidth,O=v.onChange,x=v.gap,g=v.data,E={startX:this.state.startX,endX:this.state.endX},A=n.pageX-o;A>0?A=Math.min(A,p+m-b-d):A<0&&(A=Math.max(A,p-d)),E[u]=d+A;var T=this.getIndex(E),P=T.startIndex,_=T.endIndex,j=function(){var R=g.length-1;return u==="startX"&&(l>f?P%x===0:_%x===0)||lf?_%x===0:P%x===0)||l>f&&_===R};this.setState(ar(ar({},u,d+A),"brushMoveStartX",n.pageX),function(){O&&j()&&O(T)})}},{key:"handleTravellerMoveKeyboard",value:function(n,i){var o=this,u=this.state,l=u.scaleValues,f=u.startX,d=u.endX,v=this.state[i],p=l.indexOf(v);if(p!==-1){var m=p+n;if(!(m===-1||m>=l.length)){var b=l[m];i==="startX"&&b>=d||i==="endX"&&b<=f||this.setState(ar({},i,b),function(){o.props.onChange(o.getIndex({startX:o.state.startX,endX:o.state.endX}))})}}}},{key:"renderBackground",value:function(){var n=this.props,i=n.x,o=n.y,u=n.width,l=n.height,f=n.fill,d=n.stroke;return I.createElement("rect",{stroke:d,fill:f,x:i,y:o,width:u,height:l})}},{key:"renderPanorama",value:function(){var n=this.props,i=n.x,o=n.y,u=n.width,l=n.height,f=n.data,d=n.children,v=n.padding,p=C.Children.only(d);return p?I.cloneElement(p,{x:i,y:o,width:u,height:l,margin:v,compact:!0,data:f}):null}},{key:"renderTravellerLayer",value:function(n,i){var o,u,l=this,f=this.props,d=f.y,v=f.travellerWidth,p=f.height,m=f.traveller,b=f.ariaLabel,O=f.data,x=f.startIndex,g=f.endIndex,E=Math.max(n,this.props.x),A=tg(tg({},Se(this.props,!1)),{},{x:E,y:d,width:v,height:p}),T=b||"Min value: ".concat((o=O[x])===null||o===void 0?void 0:o.name,", Max value: ").concat((u=O[g])===null||u===void 0?void 0:u.name);return I.createElement(qe,{tabIndex:0,role:"slider","aria-label":T,"aria-valuenow":n,className:"recharts-brush-traveller",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.travellerDragStartHandlers[i],onTouchStart:this.travellerDragStartHandlers[i],onKeyDown:function(_){["ArrowLeft","ArrowRight"].includes(_.key)&&(_.preventDefault(),_.stopPropagation(),l.handleTravellerMoveKeyboard(_.key==="ArrowRight"?1:-1,i))},onFocus:function(){l.setState({isTravellerFocused:!0})},onBlur:function(){l.setState({isTravellerFocused:!1})},style:{cursor:"col-resize"}},t.renderTraveller(m,A))}},{key:"renderSlide",value:function(n,i){var o=this.props,u=o.y,l=o.height,f=o.stroke,d=o.travellerWidth,v=Math.min(n,i)+d,p=Math.max(Math.abs(i-n)-d,0);return I.createElement("rect",{className:"recharts-brush-slide",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.handleSlideDragStart,onTouchStart:this.handleSlideDragStart,style:{cursor:"move"},stroke:"none",fill:f,fillOpacity:.2,x:v,y:u,width:p,height:l})}},{key:"renderText",value:function(){var n=this.props,i=n.startIndex,o=n.endIndex,u=n.y,l=n.height,f=n.travellerWidth,d=n.stroke,v=this.state,p=v.startX,m=v.endX,b=5,O={pointerEvents:"none",fill:d};return I.createElement(qe,{className:"recharts-brush-texts"},I.createElement(Ui,nf({textAnchor:"end",verticalAnchor:"middle",x:Math.min(p,m)-b,y:u+l/2},O),this.getTextOfTick(i)),I.createElement(Ui,nf({textAnchor:"start",verticalAnchor:"middle",x:Math.max(p,m)+f+b,y:u+l/2},O),this.getTextOfTick(o)))}},{key:"render",value:function(){var n=this.props,i=n.data,o=n.className,u=n.children,l=n.x,f=n.y,d=n.width,v=n.height,p=n.alwaysShowText,m=this.state,b=m.startX,O=m.endX,x=m.isTextActive,g=m.isSlideMoving,E=m.isTravellerMoving,A=m.isTravellerFocused;if(!i||!i.length||!le(l)||!le(f)||!le(d)||!le(v)||d<=0||v<=0)return null;var T=Me("recharts-brush",o),P=I.Children.count(u)===1,_=T9("userSelect","none");return I.createElement(qe,{className:T,onMouseLeave:this.handleLeaveWrapper,onTouchMove:this.handleTouchMove,style:_},this.renderBackground(),P&&this.renderPanorama(),this.renderSlide(b,O),this.renderTravellerLayer(b,"startX"),this.renderTravellerLayer(O,"endX"),(x||g||E||A||p)&&this.renderText())}}],[{key:"renderDefaultTraveller",value:function(n){var i=n.x,o=n.y,u=n.width,l=n.height,f=n.stroke,d=Math.floor(o+l/2)-1;return I.createElement(I.Fragment,null,I.createElement("rect",{x:i,y:o,width:u,height:l,fill:f,stroke:"none"}),I.createElement("line",{x1:i+1,y1:d,x2:i+u-1,y2:d,fill:"none",stroke:"#fff"}),I.createElement("line",{x1:i+1,y1:d+2,x2:i+u-1,y2:d+2,fill:"none",stroke:"#fff"}))}},{key:"renderTraveller",value:function(n,i){var o;return I.isValidElement(n)?o=I.cloneElement(n,i):je(n)?o=n(i):o=t.renderDefaultTraveller(i),o}},{key:"getDerivedStateFromProps",value:function(n,i){var o=n.data,u=n.width,l=n.x,f=n.travellerWidth,d=n.updateId,v=n.startIndex,p=n.endIndex;if(o!==i.prevData||d!==i.prevUpdateId)return tg({prevData:o,prevTravellerWidth:f,prevUpdateId:d,prevX:l,prevWidth:u},o&&o.length?D9({data:o,width:u,x:l,travellerWidth:f,startIndex:v,endIndex:p}):{scale:null,scaleValues:null});if(i.scale&&(u!==i.prevWidth||l!==i.prevX||f!==i.prevTravellerWidth)){i.scale.range([l,l+u-f]);var m=i.scale.domain().map(function(b){return i.scale(b)});return{prevData:o,prevTravellerWidth:f,prevUpdateId:d,prevX:l,prevWidth:u,startX:i.scale(n.startIndex),endX:i.scale(n.endIndex),scaleValues:m}}return null}},{key:"getIndexInRange",value:function(n,i){for(var o=n.length,u=0,l=o-1;l-u>1;){var f=Math.floor((u+l)/2);n[f]>i?l=f:u=f}return i>=n[l]?l:u}}])})(C.PureComponent);ar(ao,"displayName","Brush");ar(ao,"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 rg,UA;function L9(){if(UA)return rg;UA=1;var e=Tb();function t(r,n){var i;return e(r,function(o,u,l){return i=n(o,u,l),!i}),!!i}return rg=t,rg}var ng,WA;function B9(){if(WA)return ng;WA=1;var e=gk(),t=an(),r=L9(),n=Jt(),i=qf();function o(u,l,f){var d=n(u)?e:r;return f&&i(u,l,f)&&(l=void 0),d(u,t(l,3))}return ng=o,ng}var F9=B9();const q9=Ue(F9);var Jr=function(t,r){var n=t.alwaysShow,i=t.ifOverflow;return n&&(i="extendDomain"),i===r},ig,HA;function z9(){if(HA)return ig;HA=1;var e=Ik();function t(r,n,i){n=="__proto__"&&e?e(r,n,{configurable:!0,enumerable:!0,value:i,writable:!0}):r[n]=i}return ig=t,ig}var ag,KA;function U9(){if(KA)return ag;KA=1;var e=z9(),t=Mk(),r=an();function n(i,o){var u={};return o=r(o,3),t(i,function(l,f,d){e(u,f,o(l,f,d))}),u}return ag=n,ag}var W9=U9();const H9=Ue(W9);var og,VA;function K9(){if(VA)return og;VA=1;function e(t,r){for(var n=-1,i=t==null?0:t.length;++n=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function tV(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function rV(e,t){var r=e.x,n=e.y,i=eV(e,Y9),o="".concat(r),u=parseInt(o,10),l="".concat(n),f=parseInt(l,10),d="".concat(t.height||i.height),v=parseInt(d,10),p="".concat(t.width||i.width),m=parseInt(p,10);return _s(_s(_s(_s(_s({},t),i),u?{x:u}:{}),f?{y:f}:{}),{},{height:v,width:m,name:t.name,radius:t.radius})}function QA(e){return I.createElement(vR,k0({shapeType:"rectangle",propTransformer:rV,activeClassName:"recharts-active-bar"},e))}var nV=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return function(n,i){if(typeof t=="number")return t;var o=le(n)||jB(n);return o?t(n,i):(o||Hi(),r)}},iV=["value","background"],OR;function oo(e){"@babel/helpers - typeof";return oo=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},oo(e)}function aV(e,t){if(e==null)return{};var r=oV(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 oV(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function of(){return of=Object.assign?Object.assign.bind():function(e){for(var t=1;t0&&Math.abs(V)0&&Math.abs(G)0&&(z=Math.min((ce||0)-(G[me-1]||0),z))}),Number.isFinite(z)){var V=z/M,Y=x.layout==="vertical"?n.height:n.width;if(x.padding==="gap"&&(N=V*Y/2),x.padding==="no-gap"){var J=zt(t.barCategoryGap,V*Y),H=V*Y/2;N=H-J-(H-J)/Y*J}}}i==="xAxis"?R=[n.left+(T.left||0)+(N||0),n.left+n.width-(T.right||0)-(N||0)]:i==="yAxis"?R=f==="horizontal"?[n.top+n.height-(T.bottom||0),n.top+(T.top||0)]:[n.top+(T.top||0)+(N||0),n.top+n.height-(T.bottom||0)-(N||0)]:R=x.range,_&&(R=[R[1],R[0]]);var ee=VN(x,o,m),Z=ee.scale,L=ee.realScaleType;Z.domain(E).range(R),GN(Z);var U=XN(Z,Dr(Dr({},x),{},{realScaleType:L}));i==="xAxis"?(B=g==="top"&&!P||g==="bottom"&&P,D=n.left,W=p[j]-B*x.height):i==="yAxis"&&(B=g==="left"&&!P||g==="right"&&P,D=p[j]-B*x.width,W=n.top);var oe=Dr(Dr(Dr({},x),U),{},{realScaleType:L,x:D,y:W,scale:Z,width:i==="xAxis"?n.width:x.width,height:i==="yAxis"?n.height:x.height});return oe.bandSize=zc(oe,U),!x.hide&&i==="xAxis"?p[j]+=(B?-1:1)*oe.height:x.hide||(p[j]+=(B?-1:1)*oe.width),Dr(Dr({},b),{},od({},O,oe))},{})},AR=function(t,r){var n=t.x,i=t.y,o=r.x,u=r.y;return{x:Math.min(n,o),y:Math.min(i,u),width:Math.abs(o-n),height:Math.abs(u-i)}},yV=function(t){var r=t.x1,n=t.y1,i=t.x2,o=t.y2;return AR({x:r,y:n},{x:i,y:o})},TR=(function(){function e(t){hV(this,e),this.scale=t}return vV(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 u=this.bandwidth?this.bandwidth()/2:0;return this.scale(r)+u}case"end":{var l=this.bandwidth?this.bandwidth():0;return this.scale(r)+l}default:return this.scale(r)}if(i){var f=this.bandwidth?this.bandwidth()/2:0;return this.scale(r)+f}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)}}])})();od(TR,"EPS",1e-4);var ix=function(t){var r=Object.keys(t).reduce(function(n,i){return Dr(Dr({},n),{},od({},i,TR.create(t[i])))},{});return Dr(Dr({},r),{},{apply:function(i){var o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},u=o.bandAware,l=o.position;return H9(i,function(f,d){return r[d].apply(f,{bandAware:u,position:l})})},isInRange:function(i){return SR(i,function(o,u){return r[u].isInRange(o)})}})};function gV(e){return(e%180+180)%180}var bV=function(t){var r=t.width,n=t.height,i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,o=gV(i),u=o*Math.PI/180,l=Math.atan(n/r),f=u>l&&u-1?f[d?o[v]:v]:void 0}}return lg=n,lg}var cg,nT;function wV(){if(nT)return cg;nT=1;var e=gR();function t(r){var n=e(r),i=n%1;return n===n?i?n-i:n:0}return cg=t,cg}var fg,iT;function SV(){if(iT)return fg;iT=1;var e=Tk(),t=an(),r=wV(),n=Math.max;function i(o,u,l){var f=o==null?0:o.length;if(!f)return-1;var d=l==null?0:r(l);return d<0&&(d=n(f+d,0)),e(o,t(u,3),d)}return fg=i,fg}var dg,aT;function OV(){if(aT)return dg;aT=1;var e=xV(),t=SV(),r=e(t);return dg=r,dg}var _V=OV();const PV=Ue(_V);var EV=HC();const jV=Ue(EV);var AV=jV(function(e){return{x:e.left,y:e.top,width:e.width,height:e.height}},function(e){return["l",e.left,"t",e.top,"w",e.width,"h",e.height].join("")}),ax=C.createContext(void 0),ox=C.createContext(void 0),CR=C.createContext(void 0),kR=C.createContext({}),NR=C.createContext(void 0),RR=C.createContext(0),MR=C.createContext(0),oT=function(t){var r=t.state,n=r.xAxisMap,i=r.yAxisMap,o=r.offset,u=t.clipPathId,l=t.children,f=t.width,d=t.height,v=AV(o);return I.createElement(ax.Provider,{value:n},I.createElement(ox.Provider,{value:i},I.createElement(kR.Provider,{value:o},I.createElement(CR.Provider,{value:v},I.createElement(NR.Provider,{value:u},I.createElement(RR.Provider,{value:d},I.createElement(MR.Provider,{value:f},l)))))))},TV=function(){return C.useContext(NR)},$R=function(t){var r=C.useContext(ax);r==null&&Hi();var n=r[t];return n==null&&Hi(),n},CV=function(){var t=C.useContext(ax);return ni(t)},kV=function(){var t=C.useContext(ox),r=PV(t,function(n){return SR(n.domain,Number.isFinite)});return r||ni(t)},IR=function(t){var r=C.useContext(ox);r==null&&Hi();var n=r[t];return n==null&&Hi(),n},NV=function(){var t=C.useContext(CR);return t},RV=function(){return C.useContext(kR)},sx=function(){return C.useContext(MR)},ux=function(){return C.useContext(RR)};function so(e){"@babel/helpers - typeof";return so=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},so(e)}function MV(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function $V(e,t){for(var r=0;re.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 m7(e,t){return UR(e,t+1)}function y7(e,t,r,n,i){for(var o=(n||[]).slice(),u=t.start,l=t.end,f=0,d=1,v=u,p=function(){var O=n==null?void 0:n[f];if(O===void 0)return{v:UR(n,d)};var x=f,g,E=function(){return g===void 0&&(g=r(O,x)),g},A=O.coordinate,T=f===0||ff(e,A,E,v,l);T||(f=0,v=u,d+=1),T&&(v=A+e*(E()/2+i),f+=d)},m;d<=o.length;)if(m=p(),m)return m.v;return[]}function xu(e){"@babel/helpers - typeof";return xu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},xu(e)}function hT(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 It(e){for(var t=1;t0?b.coordinate-g*e:b.coordinate})}else o[m]=b=It(It({},b),{},{tickCoord:b.coordinate});var E=ff(e,b.tickCoord,x,l,f);E&&(f=b.tickCoord-e*(x()/2+i),o[m]=It(It({},b),{},{isShow:!0}))},v=u-1;v>=0;v--)d(v);return o}function S7(e,t,r,n,i,o){var u=(n||[]).slice(),l=u.length,f=t.start,d=t.end;if(o){var v=n[l-1],p=r(v,l-1),m=e*(v.coordinate+e*p/2-d);u[l-1]=v=It(It({},v),{},{tickCoord:m>0?v.coordinate-m*e:v.coordinate});var b=ff(e,v.tickCoord,function(){return p},f,d);b&&(d=v.tickCoord-e*(p/2+i),u[l-1]=It(It({},v),{},{isShow:!0}))}for(var O=o?l-1:l,x=function(A){var T=u[A],P,_=function(){return P===void 0&&(P=r(T,A)),P};if(A===0){var j=e*(T.coordinate-e*_()/2-f);u[A]=T=It(It({},T),{},{tickCoord:j<0?T.coordinate-j*e:T.coordinate})}else u[A]=T=It(It({},T),{},{tickCoord:T.coordinate});var N=ff(e,T.tickCoord,_,f,d);N&&(f=T.tickCoord+e*(_()/2+i),u[A]=It(It({},T),{},{isShow:!0}))},g=0;g=2?qt(i[1].coordinate-i[0].coordinate):1,E=v7(o,g,b);return f==="equidistantPreserveStart"?y7(g,E,x,i,u):(f==="preserveStart"||f==="preserveStartEnd"?m=S7(g,E,x,i,u,f==="preserveStartEnd"):m=w7(g,E,x,i,u),m.filter(function(A){return A.isShow}))}var O7=["viewBox"],_7=["viewBox"],P7=["ticks"];function co(e){"@babel/helpers - typeof";return co=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},co(e)}function La(){return La=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 E7(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function j7(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function mT(e,t){for(var r=0;r0?f(this.props):f(b)),u<=0||l<=0||!O||!O.length?null:I.createElement(qe,{className:Me("recharts-cartesian-axis",d),ref:function(g){n.layerReference=g}},o&&this.renderAxisLine(),this.renderTicks(O,this.state.fontSize,this.state.letterSpacing),jt.renderCallByParent(this.props))}}],[{key:"renderTickItem",value:function(n,i,o){var u,l=Me(i.className,"recharts-cartesian-axis-tick-value");return I.isValidElement(n)?u=I.cloneElement(n,gt(gt({},i),{},{className:l})):je(n)?u=n(gt(gt({},i),{},{className:l})):u=I.createElement(Ui,La({},i,{className:"recharts-cartesian-axis-tick-value"}),o),u}}])})(C.Component);dx(jo,"displayName","CartesianAxis");dx(jo,"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 M7=["x1","y1","x2","y2","key"],$7=["offset"];function Ki(e){"@babel/helpers - typeof";return Ki=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},Ki(e)}function yT(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 Lt(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function B7(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}var F7=function(t){var r=t.fill;if(!r||r==="none")return null;var n=t.fillOpacity,i=t.x,o=t.y,u=t.width,l=t.height,f=t.ry;return I.createElement("rect",{x:i,y:o,ry:f,width:u,height:l,stroke:"none",fill:r,fillOpacity:n,className:"recharts-cartesian-grid-bg"})};function KR(e,t){var r;if(I.isValidElement(e))r=I.cloneElement(e,t);else if(je(e))r=e(t);else{var n=t.x1,i=t.y1,o=t.x2,u=t.y2,l=t.key,f=gT(t,M7),d=Se(f,!1);d.offset;var v=gT(d,$7);r=I.createElement("line",Li({},v,{x1:n,y1:i,x2:o,y2:u,fill:"none",key:l}))}return r}function q7(e){var t=e.x,r=e.width,n=e.horizontal,i=n===void 0?!0:n,o=e.horizontalPoints;if(!i||!o||!o.length)return null;var u=o.map(function(l,f){var d=Lt(Lt({},e),{},{x1:t,y1:l,x2:t+r,y2:l,key:"line-".concat(f),index:f});return KR(i,d)});return I.createElement("g",{className:"recharts-cartesian-grid-horizontal"},u)}function z7(e){var t=e.y,r=e.height,n=e.vertical,i=n===void 0?!0:n,o=e.verticalPoints;if(!i||!o||!o.length)return null;var u=o.map(function(l,f){var d=Lt(Lt({},e),{},{x1:l,y1:t,x2:l,y2:t+r,key:"line-".concat(f),index:f});return KR(i,d)});return I.createElement("g",{className:"recharts-cartesian-grid-vertical"},u)}function U7(e){var t=e.horizontalFill,r=e.fillOpacity,n=e.x,i=e.y,o=e.width,u=e.height,l=e.horizontalPoints,f=e.horizontal,d=f===void 0?!0:f;if(!d||!t||!t.length)return null;var v=l.map(function(m){return Math.round(m+i-i)}).sort(function(m,b){return m-b});i!==v[0]&&v.unshift(0);var p=v.map(function(m,b){var O=!v[b+1],x=O?i+u-m:v[b+1]-m;if(x<=0)return null;var g=b%t.length;return I.createElement("rect",{key:"react-".concat(b),y:m,x:n,height:x,width:o,stroke:"none",fill:t[g],fillOpacity:r,className:"recharts-cartesian-grid-bg"})});return I.createElement("g",{className:"recharts-cartesian-gridstripes-horizontal"},p)}function W7(e){var t=e.vertical,r=t===void 0?!0:t,n=e.verticalFill,i=e.fillOpacity,o=e.x,u=e.y,l=e.width,f=e.height,d=e.verticalPoints;if(!r||!n||!n.length)return null;var v=d.map(function(m){return Math.round(m+o-o)}).sort(function(m,b){return m-b});o!==v[0]&&v.unshift(0);var p=v.map(function(m,b){var O=!v[b+1],x=O?o+l-m:v[b+1]-m;if(x<=0)return null;var g=b%n.length;return I.createElement("rect",{key:"react-".concat(b),x:m,y:u,width:x,height:f,stroke:"none",fill:n[g],fillOpacity:i,className:"recharts-cartesian-grid-bg"})});return I.createElement("g",{className:"recharts-cartesian-gridstripes-vertical"},p)}var H7=function(t,r){var n=t.xAxis,i=t.width,o=t.height,u=t.offset;return KN(fx(Lt(Lt(Lt({},jo.defaultProps),n),{},{ticks:wn(n,!0),viewBox:{x:0,y:0,width:i,height:o}})),u.left,u.left+u.width,r)},K7=function(t,r){var n=t.yAxis,i=t.width,o=t.height,u=t.offset;return KN(fx(Lt(Lt(Lt({},jo.defaultProps),n),{},{ticks:wn(n,!0),viewBox:{x:0,y:0,width:i,height:o}})),u.top,u.top+u.height,r)},ka={horizontal:!0,vertical:!0,stroke:"#ccc",fill:"none",verticalFill:[],horizontalFill:[]};function fd(e){var t,r,n,i,o,u,l=sx(),f=ux(),d=RV(),v=Lt(Lt({},e),{},{stroke:(t=e.stroke)!==null&&t!==void 0?t:ka.stroke,fill:(r=e.fill)!==null&&r!==void 0?r:ka.fill,horizontal:(n=e.horizontal)!==null&&n!==void 0?n:ka.horizontal,horizontalFill:(i=e.horizontalFill)!==null&&i!==void 0?i:ka.horizontalFill,vertical:(o=e.vertical)!==null&&o!==void 0?o:ka.vertical,verticalFill:(u=e.verticalFill)!==null&&u!==void 0?u:ka.verticalFill,x:le(e.x)?e.x:d.left,y:le(e.y)?e.y:d.top,width:le(e.width)?e.width:d.width,height:le(e.height)?e.height:d.height}),p=v.x,m=v.y,b=v.width,O=v.height,x=v.syncWithTicks,g=v.horizontalValues,E=v.verticalValues,A=CV(),T=kV();if(!le(b)||b<=0||!le(O)||O<=0||!le(p)||p!==+p||!le(m)||m!==+m)return null;var P=v.verticalCoordinatesGenerator||H7,_=v.horizontalCoordinatesGenerator||K7,j=v.horizontalPoints,N=v.verticalPoints;if((!j||!j.length)&&je(_)){var R=g&&g.length,D=_({yAxis:T?Lt(Lt({},T),{},{ticks:R?g:T.ticks}):void 0,width:l,height:f,offset:d},R?!0:x);qr(Array.isArray(D),"horizontalCoordinatesGenerator should return Array but instead it returned [".concat(Ki(D),"]")),Array.isArray(D)&&(j=D)}if((!N||!N.length)&&je(P)){var W=E&&E.length,B=P({xAxis:A?Lt(Lt({},A),{},{ticks:W?E:A.ticks}):void 0,width:l,height:f,offset:d},W?!0:x);qr(Array.isArray(B),"verticalCoordinatesGenerator should return Array but instead it returned [".concat(Ki(B),"]")),Array.isArray(B)&&(N=B)}return I.createElement("g",{className:"recharts-cartesian-grid"},I.createElement(F7,{fill:v.fill,fillOpacity:v.fillOpacity,x:v.x,y:v.y,width:v.width,height:v.height,ry:v.ry}),I.createElement(q7,Li({},v,{offset:d,horizontalPoints:j,xAxis:A,yAxis:T})),I.createElement(z7,Li({},v,{offset:d,verticalPoints:N,xAxis:A,yAxis:T})),I.createElement(U7,Li({},v,{horizontalPoints:j})),I.createElement(W7,Li({},v,{verticalPoints:N})))}fd.displayName="CartesianGrid";var V7=["type","layout","connectNulls","ref"],G7=["key"];function fo(e){"@babel/helpers - typeof";return fo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},fo(e)}function bT(e,t){if(e==null)return{};var r=X7(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 X7(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function $s(){return $s=Object.assign?Object.assign.bind():function(e){for(var t=1;te.length)&&(t=e.length);for(var r=0,n=new Array(t);rp){b=[].concat(Na(f.slice(0,O)),[p-x]);break}var g=b.length%2===0?[0,m]:[m];return[].concat(Na(t.repeat(f,v)),Na(b),g).map(function(E){return"".concat(E,"px")}).join(", ")}),Lr(r,"id",So("recharts-line-")),Lr(r,"pathRef",function(u){r.mainCurve=u}),Lr(r,"handleAnimationEnd",function(){r.setState({isAnimationFinished:!0}),r.props.onAnimationEnd&&r.props.onAnimationEnd()}),Lr(r,"handleAnimationStart",function(){r.setState({isAnimationFinished:!1}),r.props.onAnimationStart&&r.props.onAnimationStart()}),r}return aG(t,e),tG(t,[{key:"componentDidMount",value:function(){if(this.props.isAnimationActive){var n=this.getTotalLength();this.setState({totalLength:n})}}},{key:"componentDidUpdate",value:function(){if(this.props.isAnimationActive){var n=this.getTotalLength();n!==this.state.totalLength&&this.setState({totalLength:n})}}},{key:"getTotalLength",value:function(){var n=this.mainCurve;try{return n&&n.getTotalLength&&n.getTotalLength()||0}catch{return 0}}},{key:"renderErrorBar",value:function(n,i){if(this.props.isAnimationActive&&!this.state.isAnimationFinished)return null;var o=this.props,u=o.points,l=o.xAxis,f=o.yAxis,d=o.layout,v=o.children,p=cr(v,$u);if(!p)return null;var m=function(x,g){return{x:x.x,y:x.y,value:x.value,errorVal:xt(x.payload,g)}},b={clipPath:n?"url(#clipPath-".concat(i,")"):null};return I.createElement(qe,b,p.map(function(O){return I.cloneElement(O,{key:"bar-".concat(O.props.dataKey),data:u,xAxis:l,yAxis:f,layout:d,dataPointFormatter:m})}))}},{key:"renderDots",value:function(n,i,o){var u=this.props.isAnimationActive;if(u&&!this.state.isAnimationFinished)return null;var l=this.props,f=l.dot,d=l.points,v=l.dataKey,p=Se(this.props,!1),m=Se(f,!0),b=d.map(function(x,g){var E=ir(ir(ir({key:"dot-".concat(g),r:3},p),m),{},{index:g,cx:x.x,cy:x.y,value:x.value,dataKey:v,payload:x.payload,points:d});return t.renderDotItem(f,E)}),O={clipPath:n?"url(#clipPath-".concat(i?"":"dots-").concat(o,")"):null};return I.createElement(qe,$s({className:"recharts-line-dots",key:"dots"},O),b)}},{key:"renderCurveStatically",value:function(n,i,o,u){var l=this.props,f=l.type,d=l.layout,v=l.connectNulls;l.ref;var p=bT(l,V7),m=ir(ir(ir({},Se(p,!0)),{},{fill:"none",className:"recharts-line-curve",clipPath:i?"url(#clipPath-".concat(o,")"):null,points:n},u),{},{type:f,layout:d,connectNulls:v});return I.createElement(Hc,$s({},m,{pathRef:this.pathRef}))}},{key:"renderCurveWithAnimation",value:function(n,i){var o=this,u=this.props,l=u.points,f=u.strokeDasharray,d=u.isAnimationActive,v=u.animationBegin,p=u.animationDuration,m=u.animationEasing,b=u.animationId,O=u.animateNewValues,x=u.width,g=u.height,E=this.state,A=E.prevPoints,T=E.totalLength;return I.createElement(tn,{begin:v,duration:p,isActive:d,easing:m,from:{t:0},to:{t:1},key:"line-".concat(b),onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},function(P){var _=P.t;if(A){var j=A.length/l.length,N=l.map(function(M,z){var G=Math.floor(z*j);if(A[G]){var V=A[G],Y=sr(V.x,M.x),J=sr(V.y,M.y);return ir(ir({},M),{},{x:Y(_),y:J(_)})}if(O){var H=sr(x*2,M.x),ee=sr(g/2,M.y);return ir(ir({},M),{},{x:H(_),y:ee(_)})}return ir(ir({},M),{},{x:M.x,y:M.y})});return o.renderCurveStatically(N,n,i)}var R=sr(0,T),D=R(_),W;if(f){var B="".concat(f).split(/[,\s]+/gim).map(function(M){return parseFloat(M)});W=o.getStrokeDasharray(D,T,B)}else W=o.generateSimpleStrokeDasharray(T,D);return o.renderCurveStatically(l,n,i,{strokeDasharray:W})})}},{key:"renderCurve",value:function(n,i){var o=this.props,u=o.points,l=o.isAnimationActive,f=this.state,d=f.prevPoints,v=f.totalLength;return l&&u&&u.length&&(!d&&v>0||!Mu(d,u))?this.renderCurveWithAnimation(n,i):this.renderCurveStatically(u,n,i)}},{key:"render",value:function(){var n,i=this.props,o=i.hide,u=i.dot,l=i.points,f=i.className,d=i.xAxis,v=i.yAxis,p=i.top,m=i.left,b=i.width,O=i.height,x=i.isAnimationActive,g=i.id;if(o||!l||!l.length)return null;var E=this.state.isAnimationFinished,A=l.length===1,T=Me("recharts-line",f),P=d&&d.allowDataOverflow,_=v&&v.allowDataOverflow,j=P||_,N=ke(g)?this.id:g,R=(n=Se(u,!1))!==null&&n!==void 0?n:{r:3,strokeWidth:2},D=R.r,W=D===void 0?3:D,B=R.strokeWidth,M=B===void 0?2:B,z=BB(u)?u:{},G=z.clipDot,V=G===void 0?!0:G,Y=W*2+M;return I.createElement(qe,{className:T},P||_?I.createElement("defs",null,I.createElement("clipPath",{id:"clipPath-".concat(N)},I.createElement("rect",{x:P?m:m-b/2,y:_?p:p-O/2,width:P?b:b*2,height:_?O:O*2})),!V&&I.createElement("clipPath",{id:"clipPath-dots-".concat(N)},I.createElement("rect",{x:m-Y/2,y:p-Y/2,width:b+Y,height:O+Y}))):null,!A&&this.renderCurve(j,N),this.renderErrorBar(j,N),(A||u)&&this.renderDots(j,V,N),(!x||E)&&En.renderCallByParent(this.props,l))}}],[{key:"getDerivedStateFromProps",value:function(n,i){return n.animationId!==i.prevAnimationId?{prevAnimationId:n.animationId,curPoints:n.points,prevPoints:i.curPoints}:n.points!==i.curPoints?{curPoints:n.points}:null}},{key:"repeat",value:function(n,i){for(var o=n.length%2!==0?[].concat(Na(n),[0]):n,u=[],l=0;le.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 XG(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function YG(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function QG(e,t){for(var r=0;re.length)&&(t=e.length);for(var r=0,n=new Array(t);r0?u:t&&t.length&&le(i)&&le(o)?t.slice(i,o+1):[]};function sM(e){return e==="number"?[0,"auto"]:void 0}var Y0=function(t,r,n,i){var o=t.graphicalItems,u=t.tooltipAxis,l=dd(r,t);return n<0||!o||!o.length||n>=l.length?null:o.reduce(function(f,d){var v,p=(v=d.props.data)!==null&&v!==void 0?v:r;p&&t.dataStartIndex+t.dataEndIndex!==0&&t.dataEndIndex-t.dataStartIndex>=n&&(p=p.slice(t.dataStartIndex,t.dataEndIndex+1));var m;if(u.dataKey&&!u.allowDuplicatedCategory){var b=p===void 0?l:p;m=mc(b,u.dataKey,i)}else m=p&&p[n]||l[n];return m?[].concat(mo(f),[QN(d,m)]):f},[])},AT=function(t,r,n,i){var o=i||{x:t.chartX,y:t.chartY},u=lX(o,n),l=t.orderedTooltipTicks,f=t.tooltipAxis,d=t.tooltipTicks,v=I6(u,l,d,f);if(v>=0&&d){var p=d[v]&&d[v].value,m=Y0(t,r,v,p),b=cX(n,l,v,o);return{activeTooltipIndex:v,activeLabel:p,activePayload:m,activeCoordinate:b}}return null},fX=function(t,r){var n=r.axes,i=r.graphicalItems,o=r.axisType,u=r.axisIdKey,l=r.stackGroups,f=r.dataStartIndex,d=r.dataEndIndex,v=t.layout,p=t.children,m=t.stackOffset,b=HN(v,o);return n.reduce(function(O,x){var g,E=x.type.defaultProps!==void 0?te(te({},x.type.defaultProps),x.props):x.props,A=E.type,T=E.dataKey,P=E.allowDataOverflow,_=E.allowDuplicatedCategory,j=E.scale,N=E.ticks,R=E.includeHidden,D=E[u];if(O[D])return O;var W=dd(t.data,{graphicalItems:i.filter(function(U){var oe,ce=u in U.props?U.props[u]:(oe=U.type.defaultProps)===null||oe===void 0?void 0:oe[u];return ce===D}),dataStartIndex:f,dataEndIndex:d}),B=W.length,M,z,G;DG(E.domain,P,A)&&(M=c0(E.domain,null,P),b&&(A==="number"||j!=="auto")&&(G=ks(W,T,"category")));var V=sM(A);if(!M||M.length===0){var Y,J=(Y=E.domain)!==null&&Y!==void 0?Y:V;if(T){if(M=ks(W,T,A),A==="category"&&b){var H=TB(M);_&&H?(z=M,M=rf(0,B)):_||(M=Rj(J,M,x).reduce(function(U,oe){return U.indexOf(oe)>=0?U:[].concat(mo(U),[oe])},[]))}else if(A==="category")_?M=M.filter(function(U){return U!==""&&!ke(U)}):M=Rj(J,M,x).reduce(function(U,oe){return U.indexOf(oe)>=0||oe===""||ke(oe)?U:[].concat(mo(U),[oe])},[]);else if(A==="number"){var ee=q6(W,i.filter(function(U){var oe,ce,me=u in U.props?U.props[u]:(oe=U.type.defaultProps)===null||oe===void 0?void 0:oe[u],Pe="hide"in U.props?U.props.hide:(ce=U.type.defaultProps)===null||ce===void 0?void 0:ce.hide;return me===D&&(R||!Pe)}),T,o,v);ee&&(M=ee)}b&&(A==="number"||j!=="auto")&&(G=ks(W,T,"category"))}else b?M=rf(0,B):l&&l[D]&&l[D].hasStack&&A==="number"?M=m==="expand"?[0,1]:YN(l[D].stackGroups,f,d):M=WN(W,i.filter(function(U){var oe=u in U.props?U.props[u]:U.type.defaultProps[u],ce="hide"in U.props?U.props.hide:U.type.defaultProps.hide;return oe===D&&(R||!ce)}),A,v,!0);if(A==="number")M=V0(p,M,D,o,N),J&&(M=c0(J,M,P));else if(A==="category"&&J){var Z=J,L=M.every(function(U){return Z.indexOf(U)>=0});L&&(M=Z)}}return te(te({},O),{},_e({},D,te(te({},E),{},{axisType:o,domain:M,categoricalDomain:G,duplicateDomain:z,originalDomain:(g=E.domain)!==null&&g!==void 0?g:V,isCategorical:b,layout:v})))},{})},dX=function(t,r){var n=r.graphicalItems,i=r.Axis,o=r.axisType,u=r.axisIdKey,l=r.stackGroups,f=r.dataStartIndex,d=r.dataEndIndex,v=t.layout,p=t.children,m=dd(t.data,{graphicalItems:n,dataStartIndex:f,dataEndIndex:d}),b=m.length,O=HN(v,o),x=-1;return n.reduce(function(g,E){var A=E.type.defaultProps!==void 0?te(te({},E.type.defaultProps),E.props):E.props,T=A[u],P=sM("number");if(!g[T]){x++;var _;return O?_=rf(0,b):l&&l[T]&&l[T].hasStack?(_=YN(l[T].stackGroups,f,d),_=V0(p,_,T,o)):(_=c0(P,WN(m,n.filter(function(j){var N,R,D=u in j.props?j.props[u]:(N=j.type.defaultProps)===null||N===void 0?void 0:N[u],W="hide"in j.props?j.props.hide:(R=j.type.defaultProps)===null||R===void 0?void 0:R.hide;return D===T&&!W}),"number",v),i.defaultProps.allowDataOverflow),_=V0(p,_,T,o)),te(te({},g),{},_e({},T,te(te({axisType:o},i.defaultProps),{},{hide:!0,orientation:lr(sX,"".concat(o,".").concat(x%2),null),domain:_,originalDomain:P,isCategorical:O,layout:v})))}return g},{})},pX=function(t,r){var n=r.axisType,i=n===void 0?"xAxis":n,o=r.AxisComp,u=r.graphicalItems,l=r.stackGroups,f=r.dataStartIndex,d=r.dataEndIndex,v=t.children,p="".concat(i,"Id"),m=cr(v,o),b={};return m&&m.length?b=fX(t,{axes:m,graphicalItems:u,axisType:i,axisIdKey:p,stackGroups:l,dataStartIndex:f,dataEndIndex:d}):u&&u.length&&(b=dX(t,{Axis:o,graphicalItems:u,axisType:i,axisIdKey:p,stackGroups:l,dataStartIndex:f,dataEndIndex:d})),b},hX=function(t){var r=ni(t),n=wn(r,!1,!0);return{tooltipTicks:n,orderedTooltipTicks:Cb(n,function(i){return i.coordinate}),tooltipAxis:r,tooltipAxisBandSize:zc(r,n)}},TT=function(t){var r=t.children,n=t.defaultShowTooltip,i=or(r,ao),o=0,u=0;return t.data&&t.data.length!==0&&(u=t.data.length-1),i&&i.props&&(i.props.startIndex>=0&&(o=i.props.startIndex),i.props.endIndex>=0&&(u=i.props.endIndex)),{chartX:0,chartY:0,dataStartIndex:o,dataEndIndex:u,activeTooltipIndex:-1,isTooltipActive:!!n}},vX=function(t){return!t||!t.length?!1:t.some(function(r){var n=On(r&&r.type);return n&&n.indexOf("Bar")>=0})},CT=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"}},mX=function(t,r){var n=t.props,i=t.graphicalItems,o=t.xAxisMap,u=o===void 0?{}:o,l=t.yAxisMap,f=l===void 0?{}:l,d=n.width,v=n.height,p=n.children,m=n.margin||{},b=or(p,ao),O=or(p,_n),x=Object.keys(f).reduce(function(_,j){var N=f[j],R=N.orientation;return!N.mirror&&!N.hide?te(te({},_),{},_e({},R,_[R]+N.width)):_},{left:m.left||0,right:m.right||0}),g=Object.keys(u).reduce(function(_,j){var N=u[j],R=N.orientation;return!N.mirror&&!N.hide?te(te({},_),{},_e({},R,lr(_,"".concat(R))+N.height)):_},{top:m.top||0,bottom:m.bottom||0}),E=te(te({},g),x),A=E.bottom;b&&(E.bottom+=b.props.height||ao.defaultProps.height),O&&r&&(E=B6(E,i,n,r));var T=d-E.left-E.right,P=v-E.top-E.bottom;return te(te({brushBottom:A},E),{},{width:Math.max(T,0),height:Math.max(P,0)})},yX=function(t,r){if(r==="xAxis")return t[r].width;if(r==="yAxis")return t[r].height},px=function(t){var r=t.chartName,n=t.GraphicalChild,i=t.defaultTooltipEventType,o=i===void 0?"axis":i,u=t.validateTooltipEventTypes,l=u===void 0?["axis"]:u,f=t.axisComponents,d=t.legendContent,v=t.formatAxisMap,p=t.defaultProps,m=function(E,A){var T=A.graphicalItems,P=A.stackGroups,_=A.offset,j=A.updateId,N=A.dataStartIndex,R=A.dataEndIndex,D=E.barSize,W=E.layout,B=E.barGap,M=E.barCategoryGap,z=E.maxBarSize,G=CT(W),V=G.numericAxisName,Y=G.cateAxisName,J=vX(T),H=[];return T.forEach(function(ee,Z){var L=dd(E.data,{graphicalItems:[ee],dataStartIndex:N,dataEndIndex:R}),U=ee.type.defaultProps!==void 0?te(te({},ee.type.defaultProps),ee.props):ee.props,oe=U.dataKey,ce=U.maxBarSize,me=U["".concat(V,"Id")],Pe=U["".concat(Y,"Id")],De={},Ae=f.reduce(function(Wt,jr){var ra=A["".concat(jr.axisType,"Map")],Ao=U["".concat(jr.axisType,"Id")];ra&&ra[Ao]||jr.axisType==="zAxis"||Hi();var To=ra[Ao];return te(te({},Wt),{},_e(_e({},jr.axisType,To),"".concat(jr.axisType,"Ticks"),wn(To)))},De),ae=Ae[Y],ge=Ae["".concat(Y,"Ticks")],Te=P&&P[me]&&P[me].hasStack&&Y6(ee,P[me].stackGroups),ne=On(ee.type).indexOf("Bar")>=0,We=zc(ae,ge),Ne=[],Ce=J&&D6({barSize:D,stackGroups:P,totalSize:yX(Ae,Y)});if(ne){var Je,st,Er=ke(ce)?z:ce,Wr=(Je=(st=zc(ae,ge,!0))!==null&&st!==void 0?st:Er)!==null&&Je!==void 0?Je:0;Ne=L6({barGap:B,barCategoryGap:M,bandSize:Wr!==We?Wr:We,sizeList:Ce[Pe],maxBarSize:Er}),Wr!==We&&(Ne=Ne.map(function(Wt){return te(te({},Wt),{},{position:te(te({},Wt.position),{},{offset:Wt.position.offset-Wr/2})})}))}var Hr=ee&&ee.type&&ee.type.getComposedData;Hr&&H.push({props:te(te({},Hr(te(te({},Ae),{},{displayedData:L,props:E,dataKey:oe,item:ee,bandSize:We,barPosition:Ne,offset:_,stackedData:Te,layout:W,dataStartIndex:N,dataEndIndex:R}))),{},_e(_e(_e({key:ee.key||"item-".concat(Z)},V,Ae[V]),Y,Ae[Y]),"animationId",j)),childIndex:zB(ee,E.children),item:ee})}),H},b=function(E,A){var T=E.props,P=E.dataStartIndex,_=E.dataEndIndex,j=E.updateId;if(!VO({props:T}))return null;var N=T.children,R=T.layout,D=T.stackOffset,W=T.data,B=T.reverseStackOrder,M=CT(R),z=M.numericAxisName,G=M.cateAxisName,V=cr(N,n),Y=G6(W,V,"".concat(z,"Id"),"".concat(G,"Id"),D,B),J=f.reduce(function(U,oe){var ce="".concat(oe.axisType,"Map");return te(te({},U),{},_e({},ce,pX(T,te(te({},oe),{},{graphicalItems:V,stackGroups:oe.axisType===z&&Y,dataStartIndex:P,dataEndIndex:_}))))},{}),H=mX(te(te({},J),{},{props:T,graphicalItems:V}),A==null?void 0:A.legendBBox);Object.keys(J).forEach(function(U){J[U]=v(T,J[U],H,U.replace("Map",""),r)});var ee=J["".concat(G,"Map")],Z=hX(ee),L=m(T,te(te({},J),{},{dataStartIndex:P,dataEndIndex:_,updateId:j,graphicalItems:V,stackGroups:Y,offset:H}));return te(te({formattedGraphicalItems:L,graphicalItems:V,offset:H,stackGroups:Y},Z),J)},O=(function(g){function E(A){var T,P,_;return YG(this,E),_=JG(this,E,[A]),_e(_,"eventEmitterSymbol",Symbol("rechartsEventEmitter")),_e(_,"accessibilityManager",new IG),_e(_,"handleLegendBBoxUpdate",function(j){if(j){var N=_.state,R=N.dataStartIndex,D=N.dataEndIndex,W=N.updateId;_.setState(te({legendBBox:j},b({props:_.props,dataStartIndex:R,dataEndIndex:D,updateId:W},te(te({},_.state),{},{legendBBox:j}))))}}),_e(_,"handleReceiveSyncEvent",function(j,N,R){if(_.props.syncId===j){if(R===_.eventEmitterSymbol&&typeof _.props.syncMethod!="function")return;_.applySyncEvent(N)}}),_e(_,"handleBrushChange",function(j){var N=j.startIndex,R=j.endIndex;if(N!==_.state.dataStartIndex||R!==_.state.dataEndIndex){var D=_.state.updateId;_.setState(function(){return te({dataStartIndex:N,dataEndIndex:R},b({props:_.props,dataStartIndex:N,dataEndIndex:R,updateId:D},_.state))}),_.triggerSyncEvent({dataStartIndex:N,dataEndIndex:R})}}),_e(_,"handleMouseEnter",function(j){var N=_.getMouseInfo(j);if(N){var R=te(te({},N),{},{isTooltipActive:!0});_.setState(R),_.triggerSyncEvent(R);var D=_.props.onMouseEnter;je(D)&&D(R,j)}}),_e(_,"triggeredAfterMouseMove",function(j){var N=_.getMouseInfo(j),R=N?te(te({},N),{},{isTooltipActive:!0}):{isTooltipActive:!1};_.setState(R),_.triggerSyncEvent(R);var D=_.props.onMouseMove;je(D)&&D(R,j)}),_e(_,"handleItemMouseEnter",function(j){_.setState(function(){return{isTooltipActive:!0,activeItem:j,activePayload:j.tooltipPayload,activeCoordinate:j.tooltipPosition||{x:j.cx,y:j.cy}}})}),_e(_,"handleItemMouseLeave",function(){_.setState(function(){return{isTooltipActive:!1}})}),_e(_,"handleMouseMove",function(j){j.persist(),_.throttleTriggeredAfterMouseMove(j)}),_e(_,"handleMouseLeave",function(j){_.throttleTriggeredAfterMouseMove.cancel();var N={isTooltipActive:!1};_.setState(N),_.triggerSyncEvent(N);var R=_.props.onMouseLeave;je(R)&&R(N,j)}),_e(_,"handleOuterEvent",function(j){var N=qB(j),R=lr(_.props,"".concat(N));if(N&&je(R)){var D,W;/.*touch.*/i.test(N)?W=_.getMouseInfo(j.changedTouches[0]):W=_.getMouseInfo(j),R((D=W)!==null&&D!==void 0?D:{},j)}}),_e(_,"handleClick",function(j){var N=_.getMouseInfo(j);if(N){var R=te(te({},N),{},{isTooltipActive:!0});_.setState(R),_.triggerSyncEvent(R);var D=_.props.onClick;je(D)&&D(R,j)}}),_e(_,"handleMouseDown",function(j){var N=_.props.onMouseDown;if(je(N)){var R=_.getMouseInfo(j);N(R,j)}}),_e(_,"handleMouseUp",function(j){var N=_.props.onMouseUp;if(je(N)){var R=_.getMouseInfo(j);N(R,j)}}),_e(_,"handleTouchMove",function(j){j.changedTouches!=null&&j.changedTouches.length>0&&_.throttleTriggeredAfterMouseMove(j.changedTouches[0])}),_e(_,"handleTouchStart",function(j){j.changedTouches!=null&&j.changedTouches.length>0&&_.handleMouseDown(j.changedTouches[0])}),_e(_,"handleTouchEnd",function(j){j.changedTouches!=null&&j.changedTouches.length>0&&_.handleMouseUp(j.changedTouches[0])}),_e(_,"handleDoubleClick",function(j){var N=_.props.onDoubleClick;if(je(N)){var R=_.getMouseInfo(j);N(R,j)}}),_e(_,"handleContextMenu",function(j){var N=_.props.onContextMenu;if(je(N)){var R=_.getMouseInfo(j);N(R,j)}}),_e(_,"triggerSyncEvent",function(j){_.props.syncId!==void 0&&vg.emit(mg,_.props.syncId,j,_.eventEmitterSymbol)}),_e(_,"applySyncEvent",function(j){var N=_.props,R=N.layout,D=N.syncMethod,W=_.state.updateId,B=j.dataStartIndex,M=j.dataEndIndex;if(j.dataStartIndex!==void 0||j.dataEndIndex!==void 0)_.setState(te({dataStartIndex:B,dataEndIndex:M},b({props:_.props,dataStartIndex:B,dataEndIndex:M,updateId:W},_.state)));else if(j.activeTooltipIndex!==void 0){var z=j.chartX,G=j.chartY,V=j.activeTooltipIndex,Y=_.state,J=Y.offset,H=Y.tooltipTicks;if(!J)return;if(typeof D=="function")V=D(H,j);else if(D==="value"){V=-1;for(var ee=0;ee=0){var Te,ne;if(z.dataKey&&!z.allowDuplicatedCategory){var We=typeof z.dataKey=="function"?ge:"payload.".concat(z.dataKey.toString());Te=mc(ee,We,V),ne=Z&&L&&mc(L,We,V)}else Te=ee==null?void 0:ee[G],ne=Z&&L&&L[G];if(Pe||me){var Ne=j.props.activeIndex!==void 0?j.props.activeIndex:G;return[C.cloneElement(j,te(te(te({},D.props),Ae),{},{activeIndex:Ne})),null,null]}if(!ke(Te))return[ae].concat(mo(_.renderActivePoints({item:D,activePoint:Te,basePoint:ne,childIndex:G,isRange:Z})))}else{var Ce,Je=(Ce=_.getItemByXY(_.state.activeCoordinate))!==null&&Ce!==void 0?Ce:{graphicalItem:ae},st=Je.graphicalItem,Er=st.item,Wr=Er===void 0?j:Er,Hr=st.childIndex,Wt=te(te(te({},D.props),Ae),{},{activeIndex:Hr});return[C.cloneElement(Wr,Wt),null,null]}return Z?[ae,null,null]:[ae,null]}),_e(_,"renderCustomized",function(j,N,R){return C.cloneElement(j,te(te({key:"recharts-customized-".concat(R)},_.props),_.state))}),_e(_,"renderMap",{CartesianGrid:{handler:lc,once:!0},ReferenceArea:{handler:_.renderReferenceElement},ReferenceLine:{handler:lc},ReferenceDot:{handler:_.renderReferenceElement},XAxis:{handler:lc},YAxis:{handler:lc},Brush:{handler:_.renderBrush,once:!0},Bar:{handler:_.renderGraphicChild},Line:{handler:_.renderGraphicChild},Area:{handler:_.renderGraphicChild},Radar:{handler:_.renderGraphicChild},RadialBar:{handler:_.renderGraphicChild},Scatter:{handler:_.renderGraphicChild},Pie:{handler:_.renderGraphicChild},Funnel:{handler:_.renderGraphicChild},Tooltip:{handler:_.renderCursor,once:!0},PolarGrid:{handler:_.renderPolarGrid,once:!0},PolarAngleAxis:{handler:_.renderPolarAxis},PolarRadiusAxis:{handler:_.renderPolarAxis},Customized:{handler:_.renderCustomized}}),_.clipPathId="".concat((T=A.id)!==null&&T!==void 0?T:So("recharts"),"-clip"),_.throttleTriggeredAfterMouseMove=zk(_.triggeredAfterMouseMove,(P=A.throttleDelay)!==null&&P!==void 0?P:1e3/60),_.state={},_}return rX(E,g),ZG(E,[{key:"componentDidMount",value:function(){var T,P;this.addListener(),this.accessibilityManager.setDetails({container:this.container,offset:{left:(T=this.props.margin.left)!==null&&T!==void 0?T:0,top:(P=this.props.margin.top)!==null&&P!==void 0?P:0},coordinateList:this.state.tooltipTicks,mouseHandlerCallback:this.triggeredAfterMouseMove,layout:this.props.layout}),this.displayDefaultTooltip()}},{key:"displayDefaultTooltip",value:function(){var T=this.props,P=T.children,_=T.data,j=T.height,N=T.layout,R=or(P,Qt);if(R){var D=R.props.defaultIndex;if(!(typeof D!="number"||D<0||D>this.state.tooltipTicks.length-1)){var W=this.state.tooltipTicks[D]&&this.state.tooltipTicks[D].value,B=Y0(this.state,_,D,W),M=this.state.tooltipTicks[D].coordinate,z=(this.state.offset.top+j)/2,G=N==="horizontal",V=G?{x:M,y:z}:{y:M,x:z},Y=this.state.formattedGraphicalItems.find(function(H){var ee=H.item;return ee.type.name==="Scatter"});Y&&(V=te(te({},V),Y.props.points[D].tooltipPosition),B=Y.props.points[D].tooltipPayload);var J={activeTooltipIndex:D,isTooltipActive:!0,activeLabel:W,activePayload:B,activeCoordinate:V};this.setState(J),this.renderCursor(R),this.accessibilityManager.setIndex(D)}}}},{key:"getSnapshotBeforeUpdate",value:function(T,P){if(!this.props.accessibilityLayer)return null;if(this.state.tooltipTicks!==P.tooltipTicks&&this.accessibilityManager.setDetails({coordinateList:this.state.tooltipTicks}),this.props.layout!==T.layout&&this.accessibilityManager.setDetails({layout:this.props.layout}),this.props.margin!==T.margin){var _,j;this.accessibilityManager.setDetails({offset:{left:(_=this.props.margin.left)!==null&&_!==void 0?_:0,top:(j=this.props.margin.top)!==null&&j!==void 0?j:0}})}return null}},{key:"componentDidUpdate",value:function(T){Ng([or(T.children,Qt)],[or(this.props.children,Qt)])||this.displayDefaultTooltip()}},{key:"componentWillUnmount",value:function(){this.removeListener(),this.throttleTriggeredAfterMouseMove.cancel()}},{key:"getTooltipEventType",value:function(){var T=or(this.props.children,Qt);if(T&&typeof T.props.shared=="boolean"){var P=T.props.shared?"axis":"item";return l.indexOf(P)>=0?P:o}return o}},{key:"getMouseInfo",value:function(T){if(!this.container)return null;var P=this.container,_=P.getBoundingClientRect(),j=Az(_),N={chartX:Math.round(T.pageX-j.left),chartY:Math.round(T.pageY-j.top)},R=_.width/P.offsetWidth||1,D=this.inRange(N.chartX,N.chartY,R);if(!D)return null;var W=this.state,B=W.xAxisMap,M=W.yAxisMap,z=this.getTooltipEventType(),G=AT(this.state,this.props.data,this.props.layout,D);if(z!=="axis"&&B&&M){var V=ni(B).scale,Y=ni(M).scale,J=V&&V.invert?V.invert(N.chartX):null,H=Y&&Y.invert?Y.invert(N.chartY):null;return te(te({},N),{},{xValue:J,yValue:H},G)}return G?te(te({},N),G):null}},{key:"inRange",value:function(T,P){var _=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,j=this.props.layout,N=T/_,R=P/_;if(j==="horizontal"||j==="vertical"){var D=this.state.offset,W=N>=D.left&&N<=D.left+D.width&&R>=D.top&&R<=D.top+D.height;return W?{x:N,y:R}:null}var B=this.state,M=B.angleAxisMap,z=B.radiusAxisMap;if(M&&z){var G=ni(M);return Ij({x:N,y:R},G)}return null}},{key:"parseEventsOfWrapper",value:function(){var T=this.props.children,P=this.getTooltipEventType(),_=or(T,Qt),j={};_&&P==="axis"&&(_.props.trigger==="click"?j={onClick:this.handleClick}:j={onMouseEnter:this.handleMouseEnter,onDoubleClick:this.handleDoubleClick,onMouseMove:this.handleMouseMove,onMouseLeave:this.handleMouseLeave,onTouchMove:this.handleTouchMove,onTouchStart:this.handleTouchStart,onTouchEnd:this.handleTouchEnd,onContextMenu:this.handleContextMenu});var N=yc(this.props,this.handleOuterEvent);return te(te({},N),j)}},{key:"addListener",value:function(){vg.on(mg,this.handleReceiveSyncEvent)}},{key:"removeListener",value:function(){vg.removeListener(mg,this.handleReceiveSyncEvent)}},{key:"filterFormatItem",value:function(T,P,_){for(var j=this.state.formattedGraphicalItems,N=0,R=j.length;N{r[i.sessionTypeAsInt]=(r[i.sessionTypeAsInt]||0)+1});const n=Object.entries(r).map(([i,o])=>({name:BL[Number(i)]||`Type ${i}`,value:o,color:FC[Number(i)]||"#6c757d",typeId:Number(i)}));return n.length===0?w.jsx("p",{className:"text-muted-custom text-center",children:"Aucune donnée"}):w.jsx(Ks,{width:"100%",height:300,children:w.jsxs(lM,{children:[w.jsx(on,{data:n,dataKey:"value",nameKey:"name",cx:"50%",cy:"50%",outerRadius:100,label:!0,style:t?{cursor:"pointer"}:void 0,onClick:t?(i,o)=>t(n[o].typeId):void 0,children:n.map((i,o)=>w.jsx(Tu,{fill:i.color},o))}),w.jsx(Qt,{contentStyle:{backgroundColor:"#1a1a2e",border:"1px solid #333"}}),w.jsx(_n,{})]})})}function xX({sessions:e}){const t={};e.forEach(n=>{if(n.sessionDateAsString){const i=new Date(n.sessionDateAsString),o=`${i.getFullYear()}-${String(i.getMonth()+1).padStart(2,"0")}`;t[o]=(t[o]||0)+1}});const r=Object.entries(t).sort(([n],[i])=>n.localeCompare(i)).slice(-12).map(([n,i])=>({month:n,sessions:i}));return r.length===0?w.jsx("p",{className:"text-muted-custom text-center",children:"Aucune donnée"}):w.jsx(Ks,{width:"100%",height:300,children:w.jsxs(gX,{data:r,children:[w.jsx(fd,{strokeDasharray:"3 3",stroke:"#333"}),w.jsx(ta,{dataKey:"month",stroke:"#888"}),w.jsx(ui,{stroke:"#888",allowDecimals:!1}),w.jsx(Qt,{contentStyle:{backgroundColor:"#1a1a2e",border:"1px solid #333"}}),w.jsx(ea,{dataKey:"sessions",fill:"#4a90d9",name:"Sessions"})]})})}function wX(e){const t=Math.floor(e/60),r=Math.floor(e%60);return`${t}m ${r}s`}function SX(e,t){return e?new Date(e).toLocaleDateString(t==="fr"?"fr-FR":"en-US",{day:"2-digit",month:"2-digit",year:"numeric",hour:"2-digit",minute:"2-digit"}):"-"}function OX(){const{t:e,lang:t}=zr(),r=_u(),[n,i]=C.useState([]),[o,u]=C.useState([]),[l,f]=C.useState(!0);if(C.useEffect(()=>{Promise.all([LC(),BC()]).then(([x,g])=>{i(x),u(g)}).finally(()=>f(!1))},[]),l)return w.jsx(Pu,{});const d=n.length,v=o.length,p=d>0?Math.round(n.filter(x=>x.success).length/d*100):0,m=o.length>0?Math.round(o.reduce((x,g)=>x+g.avgPrecision,0)/o.length*100)/100:0,b=n.slice(0,10),O=[...o].sort((x,g)=>g.avgPrecision-x.avgPrecision).slice(0,5);return w.jsxs(w.Fragment,{children:[w.jsx("h2",{className:"mb-4",children:e("dashboard.title")}),w.jsxs(wr,{className:"mb-4 g-3",children:[w.jsx(Le,{xs:6,md:3,children:w.jsx(Dt,{title:e("dashboard.totalSessions"),value:d,color:"#4a90d9",onClick:()=>r("/sessions")})}),w.jsx(Le,{xs:6,md:3,children:w.jsx(Dt,{title:e("dashboard.totalUsers"),value:v,color:"#9b59b6",onClick:()=>r("/users")})}),w.jsx(Le,{xs:6,md:3,children:w.jsx(Dt,{title:e("dashboard.successRate"),value:`${p}%`,color:"#27ae60"})}),w.jsx(Le,{xs:6,md:3,children:w.jsx(Dt,{title:e("dashboard.avgPrecision"),value:m.toFixed(1),color:"#f39c12"})})]}),w.jsxs(wr,{className:"mb-4 g-3",children:[w.jsx(Le,{md:6,children:w.jsx(be,{className:"chart-card",children:w.jsxs(be.Body,{children:[w.jsx(be.Title,{children:e("dashboard.sessionsByType")}),w.jsx(bX,{sessions:n,onSliceClick:x=>r(`/sessions?type=${x}`)})]})})}),w.jsx(Le,{md:6,children:w.jsx(be,{className:"chart-card",children:w.jsxs(be.Body,{children:[w.jsx(be.Title,{children:e("dashboard.monthlyActivity")}),w.jsx(xX,{sessions:n})]})})})]}),w.jsxs(wr,{className:"g-3",children:[w.jsx(Le,{md:8,children:w.jsx(be,{className:"data-card",children:w.jsxs(be.Body,{children:[w.jsx(be.Title,{children:e("dashboard.recentSessions")}),w.jsxs(Sr,{hover:!0,responsive:!0,className:"data-table mb-0",children:[w.jsx("thead",{children:w.jsxs("tr",{children:[w.jsx("th",{children:e("table.date")}),w.jsx("th",{children:e("table.type")}),w.jsx("th",{children:e("table.scenario")}),w.jsx("th",{children:e("table.score")}),w.jsx("th",{children:e("table.duration")}),w.jsx("th",{children:e("table.result")})]})}),w.jsx("tbody",{children:b.map(x=>w.jsxs("tr",{className:"clickable-row",onClick:()=>r(`/sessions/${x.id}`),children:[w.jsx("td",{children:SX(x.sessionDateAsString,t)}),w.jsx("td",{children:w.jsx(Fs,{typeId:x.sessionTypeAsInt})}),w.jsx("td",{children:x.scenarioName||"-"}),w.jsx("td",{children:x.score}),w.jsx("td",{children:wX(x.timeToFinish)}),w.jsx("td",{children:w.jsx(Tf,{success:x.success})})]},x.id))})]})]})})}),w.jsx(Le,{md:4,children:w.jsx(be,{className:"data-card",children:w.jsxs(be.Body,{children:[w.jsx(be.Title,{children:e("dashboard.topPrecision")}),w.jsxs(Sr,{hover:!0,className:"data-table mb-0",children:[w.jsx("thead",{children:w.jsxs("tr",{children:[w.jsx("th",{children:"#"}),w.jsx("th",{children:e("table.user")}),w.jsx("th",{children:e("chart.precision")})]})}),w.jsx("tbody",{children:O.map((x,g)=>w.jsxs("tr",{className:"clickable-row",onClick:()=>r(`/users/${x.id}`),children:[w.jsx("td",{children:g+1}),w.jsx("td",{children:x.firstName&&x.lastName?`${x.firstName} ${x.lastName}`:x.username}),w.jsx("td",{children:x.avgPrecision.toFixed(1)})]},x.id))})]})]})})})]})]})}const _X={type:$e.string,tooltip:$e.bool,as:$e.elementType},pd=C.forwardRef(({as:e="div",className:t,type:r="valid",tooltip:n=!1,...i},o)=>w.jsx(e,{...i,ref:o,className:Oe(t,`${r}-${n?"tooltip":"feedback"}`)}));pd.displayName="Feedback";pd.propTypes=_X;const Cn=C.createContext({}),hx=C.forwardRef(({id:e,bsPrefix:t,className:r,type:n="checkbox",isValid:i=!1,isInvalid:o=!1,as:u="input",...l},f)=>{const{controlId:d}=C.useContext(Cn);return t=Re(t,"form-check-input"),w.jsx(u,{...l,ref:f,type:n,id:e||d,className:Oe(r,t,i&&"is-valid",o&&"is-invalid")})});hx.displayName="FormCheckInput";const yf=C.forwardRef(({bsPrefix:e,className:t,htmlFor:r,...n},i)=>{const{controlId:o}=C.useContext(Cn);return e=Re(e,"form-check-label"),w.jsx("label",{...n,ref:i,htmlFor:r||o,className:Oe(t,e)})});yf.displayName="FormCheckLabel";function PX(e,t){let r=0;return C.Children.map(e,n=>C.isValidElement(n)?t(n,r++):n)}function EX(e,t){return C.Children.toArray(e).some(r=>C.isValidElement(r)&&r.type===t)}const cM=C.forwardRef(({id:e,bsPrefix:t,bsSwitchPrefix:r,inline:n=!1,reverse:i=!1,disabled:o=!1,isValid:u=!1,isInvalid:l=!1,feedbackTooltip:f=!1,feedback:d,feedbackType:v,className:p,style:m,title:b="",type:O="checkbox",label:x,children:g,as:E="input",...A},T)=>{t=Re(t,"form-check"),r=Re(r,"form-switch");const{controlId:P}=C.useContext(Cn),_=C.useMemo(()=>({controlId:e||P}),[P,e]),j=!g&&x!=null&&x!==!1||EX(g,yf),N=w.jsx(hx,{...A,type:O==="switch"?"checkbox":O,ref:T,isValid:u,isInvalid:l,disabled:o,as:E});return w.jsx(Cn.Provider,{value:_,children:w.jsx("div",{style:m,className:Oe(p,j&&t,n&&`${t}-inline`,i&&`${t}-reverse`,O==="switch"&&r),children:g||w.jsxs(w.Fragment,{children:[N,j&&w.jsx(yf,{title:b,children:x}),d&&w.jsx(pd,{type:v,tooltip:f,children:d})]})})})});cM.displayName="FormCheck";const gf=Object.assign(cM,{Input:hx,Label:yf}),fM=C.forwardRef(({bsPrefix:e,type:t,size:r,htmlSize:n,id:i,className:o,isValid:u=!1,isInvalid:l=!1,plaintext:f,readOnly:d,as:v="input",...p},m)=>{const{controlId:b}=C.useContext(Cn);return e=Re(e,"form-control"),w.jsx(v,{...p,type:t,size:n,ref:m,readOnly:d,id:i||b,className:Oe(o,f?`${e}-plaintext`:e,r&&`${e}-${r}`,t==="color"&&`${e}-color`,u&&"is-valid",l&&"is-invalid")})});fM.displayName="FormControl";const jX=Object.assign(fM,{Feedback:pd}),dM=C.forwardRef(({className:e,bsPrefix:t,as:r="div",...n},i)=>(t=Re(t,"form-floating"),w.jsx(r,{ref:i,className:Oe(e,t),...n})));dM.displayName="FormFloating";const vx=C.forwardRef(({controlId:e,as:t="div",...r},n)=>{const i=C.useMemo(()=>({controlId:e}),[e]);return w.jsx(Cn.Provider,{value:i,children:w.jsx(t,{...r,ref:n})})});vx.displayName="FormGroup";const pM=C.forwardRef(({as:e="label",bsPrefix:t,column:r=!1,visuallyHidden:n=!1,className:i,htmlFor:o,...u},l)=>{const{controlId:f}=C.useContext(Cn);t=Re(t,"form-label");let d="col-form-label";typeof r=="string"&&(d=`${d} ${d}-${r}`);const v=Oe(i,t,n&&"visually-hidden",r&&d);return o=o||f,r?w.jsx(Le,{ref:l,as:"label",className:v,htmlFor:o,...u}):w.jsx(e,{ref:l,className:v,htmlFor:o,...u})});pM.displayName="FormLabel";const hM=C.forwardRef(({bsPrefix:e,className:t,id:r,...n},i)=>{const{controlId:o}=C.useContext(Cn);return e=Re(e,"form-range"),w.jsx("input",{...n,type:"range",ref:i,className:Oe(t,e),id:r||o})});hM.displayName="FormRange";const vM=C.forwardRef(({bsPrefix:e,size:t,htmlSize:r,className:n,isValid:i=!1,isInvalid:o=!1,id:u,...l},f)=>{const{controlId:d}=C.useContext(Cn);return e=Re(e,"form-select"),w.jsx("select",{...l,size:r,ref:f,className:Oe(n,e,t&&`${e}-${t}`,i&&"is-valid",o&&"is-invalid"),id:u||d})});vM.displayName="FormSelect";const mM=C.forwardRef(({bsPrefix:e,className:t,as:r="small",muted:n,...i},o)=>(e=Re(e,"form-text"),w.jsx(r,{...i,ref:o,className:Oe(t,e,n&&"text-muted")})));mM.displayName="FormText";const yM=C.forwardRef((e,t)=>w.jsx(gf,{...e,ref:t,type:"switch"}));yM.displayName="Switch";const AX=Object.assign(yM,{Input:gf.Input,Label:gf.Label}),gM=C.forwardRef(({bsPrefix:e,className:t,children:r,controlId:n,label:i,...o},u)=>(e=Re(e,"form-floating"),w.jsxs(vx,{ref:u,className:Oe(t,e),controlId:n,...o,children:[r,w.jsx("label",{htmlFor:n,children:i})]})));gM.displayName="FloatingLabel";const TX={_ref:$e.any,validated:$e.bool,as:$e.elementType},mx=C.forwardRef(({className:e,validated:t,as:r="form",...n},i)=>w.jsx(r,{...n,ref:i,className:Oe(e,t&&"was-validated")}));mx.displayName="Form";mx.propTypes=TX;const Ir=Object.assign(mx,{Group:vx,Control:jX,Floating:dM,Check:gf,Switch:AX,Label:pM,Text:mM,Range:hM,Select:vM,FloatingLabel:gM}),yx=C.forwardRef(({active:e=!1,disabled:t=!1,className:r,style:n,activeLabel:i="(current)",children:o,linkStyle:u,linkClassName:l,as:f=sb,...d},v)=>{const p=e||t?"span":f;return w.jsx("li",{ref:v,style:n,className:Oe(r,"page-item",{active:e,disabled:t}),children:w.jsxs(p,{className:Oe("page-link",l),style:u,...d,children:[o,e&&i&&w.jsx("span",{className:"visually-hidden",children:i})]})})});yx.displayName="PageItem";function Iu(e,t,r=e){const n=C.forwardRef(({children:i,...o},u)=>w.jsxs(yx,{...o,ref:u,children:[w.jsx("span",{"aria-hidden":"true",children:i||t}),w.jsx("span",{className:"visually-hidden",children:r})]}));return n.displayName=e,n}const CX=Iu("First","«"),kX=Iu("Prev","‹","Previous"),NX=Iu("Ellipsis","…","More"),RX=Iu("Next","›"),MX=Iu("Last","»"),bM=C.forwardRef(({bsPrefix:e,className:t,size:r,...n},i)=>{const o=Re(e,"pagination");return w.jsx("ul",{ref:i,...n,className:Oe(t,o,r&&`${o}-${r}`)})});bM.displayName="Pagination";const Ra=Object.assign(bM,{First:CX,Prev:kX,Ellipsis:NX,Item:yx,Next:RX,Last:MX}),$X="/ProserveReport/",IX=`${$X}logo.png`;function hd({subtitle:e}){const{t}=zr(),n=new Date().toLocaleDateString("fr-FR",{day:"2-digit",month:"2-digit",year:"numeric",hour:"2-digit",minute:"2-digit"});return w.jsxs("div",{className:"print-header",children:[w.jsx("img",{src:IX,alt:"Logo"}),w.jsx("span",{className:"print-title",children:"PROSERVE Report"}),e&&w.jsxs("span",{style:{color:"#333",fontSize:"0.9rem"},children:["— ",e]}),w.jsxs("span",{className:"print-subtitle",children:[t("print.generatedOn")," ",n]})]})}const gg=20;function DX(e){const t=Math.floor(e/60),r=Math.floor(e%60);return`${t}m ${r}s`}function LX(e,t){return e?new Date(e).toLocaleDateString(t==="fr"?"fr-FR":"en-US",{day:"2-digit",month:"2-digit",year:"numeric",hour:"2-digit",minute:"2-digit"}):"-"}function BX(){const{t:e,lang:t}=zr(),r=_u(),[n,i]=$2(),[o,u]=C.useState([]),[l,f]=C.useState(!0),d=n.get("type"),[v,p]=C.useState(d!==null?Number(d):-1),[m,b]=C.useState("all"),[O,x]=C.useState(""),[g,E]=C.useState("sessionDateAsString"),[A,T]=C.useState("desc"),[P,_]=C.useState(1);C.useEffect(()=>{LC().then(u).finally(()=>f(!1))},[]);const j=C.useMemo(()=>{let M=o;if(v>=0&&(M=M.filter(z=>z.sessionTypeAsInt===v)),m==="success"?M=M.filter(z=>z.success):m==="failed"&&(M=M.filter(z=>!z.success)),O.trim()){const z=O.toLowerCase();M=M.filter(G=>G.scenarioName.toLowerCase().includes(z)||G.mapName.toLowerCase().includes(z)||G.sessionName.toLowerCase().includes(z))}return[...M].sort((z,G)=>{const V=z[g],Y=G[g];return typeof V=="string"&&typeof Y=="string"?A==="asc"?V.localeCompare(Y):Y.localeCompare(V):A==="asc"?Number(V)-Number(Y):Number(Y)-Number(V)})},[o,v,m,O,g,A]),N=Math.ceil(j.length/gg),R=j.slice((P-1)*gg,P*gg);function D(M){g===M?T(A==="asc"?"desc":"asc"):(E(M),T("desc"))}function W(M){return g!==M?"":A==="asc"?" ▲":" ▼"}if(l)return w.jsx(Pu,{});const B=[...new Set(o.map(M=>M.sessionTypeAsInt))].sort();return w.jsxs(w.Fragment,{children:[w.jsx(hd,{subtitle:e("sessions.title")}),w.jsxs("div",{className:"d-flex justify-content-between align-items-center mb-4",children:[w.jsxs("h2",{className:"mb-0",children:[e("sessions.title")," (",j.length,")"]}),w.jsx("button",{className:"print-btn no-print",onClick:()=>window.print(),children:e("print.btn")})]}),w.jsx(be,{className:"data-card mb-4 no-print",children:w.jsx(be.Body,{children:w.jsxs(wr,{className:"g-3",children:[w.jsx(Le,{md:3,children:w.jsxs(Ir.Group,{children:[w.jsx(Ir.Label,{className:"text-muted-custom",children:e("sessions.sessionType")}),w.jsxs(Ir.Select,{value:v,onChange:M=>{const z=Number(M.target.value);p(z),_(1),z>=0?i({type:String(z)}):i({})},className:"filter-select",children:[w.jsx("option",{value:-1,children:e("sessions.allTypes")}),B.map(M=>w.jsx("option",{value:M,children:e(`sessionType.${M}`)},M))]})]})}),w.jsx(Le,{md:3,children:w.jsxs(Ir.Group,{children:[w.jsx(Ir.Label,{className:"text-muted-custom",children:e("sessions.result")}),w.jsxs(Ir.Select,{value:m,onChange:M=>{b(M.target.value),_(1)},className:"filter-select",children:[w.jsx("option",{value:"all",children:e("sessions.all")}),w.jsx("option",{value:"success",children:e("sessions.success")}),w.jsx("option",{value:"failed",children:e("sessions.failed")})]})]})}),w.jsx(Le,{md:6,children:w.jsxs(Ir.Group,{children:[w.jsx(Ir.Label,{className:"text-muted-custom",children:e("sessions.search")}),w.jsx(Ir.Control,{type:"text",placeholder:e("sessions.search"),value:O,onChange:M=>{x(M.target.value),_(1)},className:"filter-input"})]})})]})})}),w.jsx(be,{className:"data-card",children:w.jsx(be.Body,{className:"p-0",children:w.jsxs(Sr,{hover:!0,responsive:!0,className:"data-table mb-0",children:[w.jsx("thead",{children:w.jsxs("tr",{children:[w.jsxs("th",{className:"sortable",onClick:()=>D("sessionDateAsString"),children:[e("table.date"),W("sessionDateAsString")]}),w.jsxs("th",{className:"sortable",onClick:()=>D("sessionTypeAsInt"),children:[e("table.type"),W("sessionTypeAsInt")]}),w.jsxs("th",{className:"sortable",onClick:()=>D("scenarioName"),children:[e("table.scenario"),W("scenarioName")]}),w.jsx("th",{children:e("table.map")}),w.jsxs("th",{className:"sortable",onClick:()=>D("score"),children:[e("table.score"),W("score")]}),w.jsx("th",{children:e("table.enemies")}),w.jsx("th",{children:e("table.civilians")}),w.jsxs("th",{className:"sortable",onClick:()=>D("timeToFinish"),children:[e("table.duration"),W("timeToFinish")]}),w.jsx("th",{children:e("table.result")})]})}),w.jsxs("tbody",{children:[R.map(M=>w.jsxs("tr",{className:"clickable-row",onClick:()=>r(`/sessions/${M.id}`),children:[w.jsx("td",{children:LX(M.sessionDateAsString,t)}),w.jsx("td",{children:w.jsx(Fs,{typeId:M.sessionTypeAsInt})}),w.jsx("td",{children:M.scenarioName||"-"}),w.jsx("td",{children:M.mapName||"-"}),w.jsx("td",{className:"fw-bold",children:M.score}),w.jsx("td",{children:M.nbEnemyHit}),w.jsx("td",{className:M.nbCivilsHit>0?"text-danger":"",children:M.nbCivilsHit}),w.jsx("td",{children:DX(M.timeToFinish)}),w.jsx("td",{children:w.jsx(Tf,{success:M.success})})]},M.id)),R.length===0&&w.jsx("tr",{children:w.jsx("td",{colSpan:9,className:"text-center text-muted-custom py-4",children:e("sessions.noSession")})})]})]})})}),N>1&&w.jsx("div",{className:"d-flex justify-content-center mt-3",children:w.jsxs(Ra,{className:"custom-pagination",children:[w.jsx(Ra.First,{onClick:()=>_(1),disabled:P===1}),w.jsx(Ra.Prev,{onClick:()=>_(P-1),disabled:P===1}),Array.from({length:Math.min(N,5)},(M,z)=>{const V=Math.max(1,Math.min(P-2,N-4))+z;return V>N?null:w.jsx(Ra.Item,{active:V===P,onClick:()=>_(V),children:V},V)}),w.jsx(Ra.Next,{onClick:()=>_(P+1),disabled:P===N}),w.jsx(Ra.Last,{onClick:()=>_(N),disabled:P===N})]})})]})}const kT=1e3;function FX(e,t,r){const n=(e-t)/(r-t)*100;return Math.round(n*kT)/kT}function NT({min:e,now:t,max:r,label:n,visuallyHidden:i,striped:o,animated:u,className:l,style:f,variant:d,bsPrefix:v,...p},m){return w.jsx("div",{ref:m,...p,role:"progressbar",className:Oe(l,`${v}-bar`,{[`bg-${d}`]:d,[`${v}-bar-animated`]:u,[`${v}-bar-striped`]:u||o}),style:{width:`${FX(t,e,r)}%`,...f},"aria-valuenow":t,"aria-valuemin":e,"aria-valuemax":r,children:i?w.jsx("span",{className:"visually-hidden",children:n}):n})}const xM=C.forwardRef(({isChild:e=!1,...t},r)=>{const n={min:0,max:100,animated:!1,visuallyHidden:!1,striped:!1,...t};if(n.bsPrefix=Re(n.bsPrefix,"progress"),e)return NT(n,r);const{min:i,now:o,max:u,label:l,visuallyHidden:f,striped:d,animated:v,bsPrefix:p,variant:m,className:b,children:O,...x}=n;return w.jsx("div",{ref:r,...x,className:Oe(b,p),children:O?PX(O,g=>C.cloneElement(g,{isChild:!0})):NT({min:i,now:o,max:u,label:l,visuallyHidden:f,striped:d,animated:v,bsPrefix:p,variant:m},r)})});xM.displayName="ProgressBar";function qX({shots:e}){return w.jsxs("div",{style:{position:"relative",width:400,height:500,margin:"0 auto"},children:[w.jsx("img",{src:"/ProserveReport/HumanTarget.png",alt:"Target",style:{width:"100%",height:"100%",objectFit:"contain",display:"block"}}),w.jsx("svg",{viewBox:"0 0 400 500",style:{position:"absolute",top:0,left:0,width:"100%",height:"100%",pointerEvents:"none"},children:e.map(n=>{const i=n.x*400,o=n.y*500;return w.jsxs("g",{children:[w.jsx("circle",{cx:i,cy:o,r:6,fill:"#00e5ff",stroke:"#000",strokeWidth:1.5,opacity:.9}),w.jsx("text",{x:i+10,y:o+4,fill:"#00e5ff",fontSize:12,fontWeight:"bold",stroke:"#000",strokeWidth:.5,paintOrder:"stroke",children:n.index})]},n.index)})})]})}function zX(e){const t=Math.floor(e/60),r=Math.floor(e%60);return`${t}m ${r}s`}function UX(e,t){return e?new Date(e).toLocaleDateString(t==="fr"?"fr-FR":"en-US",{day:"2-digit",month:"2-digit",year:"numeric",hour:"2-digit",minute:"2-digit"}):"-"}const RT={enemy:"#27ae60",civilian:"#e74c3c",police:"#f39c12",object:"#6c757d",target:"#4a90d9",paperTarget:"#2980b9",deadBody:"#95a5a6"},WX={Ennemi:"enemy",Civil:"civilian",Police:"police",Objet:"object",Cible:"target","Cible Papier":"paperTarget",Corps:"deadBody"},bg={enemy:"hitType.enemy",civilian:"hitType.civilian",police:"hitType.police",object:"hitType.object",target:"hitType.target",paperTarget:"hitType.paperTarget",deadBody:"hitType.deadBody"};function HX(){const{id:e}=WT(),t=Number(e),{t:r,lang:n}=zr(),[i,o]=C.useState(null),[u,l]=C.useState([]),[f,d]=C.useState([]),[v,p]=C.useState(null),[m,b]=C.useState([]),[O,x]=C.useState(!0);if(C.useEffect(()=>{t&&Promise.all([NL(t).catch(()=>null),ML(t).catch(()=>[]),$L(t).catch(()=>[]),DL(t).catch(()=>null)]).then(([P,_,j,N])=>{if(o(P),l(_),d(j),p(N),P){const R=P.sessionTypeAsInt;(R===cc.FireRange||R===cc.Challenge||R===cc.LongRange)&&IL(t,-1,R).then(b)}}).finally(()=>x(!1))},[t]),O)return w.jsx(Pu,{});if(!i)return w.jsx("p",{className:"text-center text-muted-custom py-5",children:r("session.notFound")});let g=null;if(v!=null&&v.resultsAsString)try{g=JSON.parse(v.resultsAsString)}catch{}const E={};f.forEach(P=>{P.nbEnemyHitsByUser>0&&(E.enemy=(E.enemy||0)+P.nbEnemyHitsByUser),P.nbCivilHitsByUser>0&&(E.civilian=(E.civilian||0)+P.nbCivilHitsByUser),P.nbPoliceHitsByUser>0&&(E.police=(E.police||0)+P.nbPoliceHitsByUser),P.nbObjectHitsByUser>0&&(E.object=(E.object||0)+P.nbObjectHitsByUser)});const A=Object.entries(E).map(([P,_])=>({name:r(bg[P]),value:_,color:RT[P]||"#6c757d"})),T=new Map(u.map(P=>[P.id,P]));return w.jsxs(w.Fragment,{children:[w.jsx(hd,{subtitle:i.sessionName||i.scenarioName||`Session #${i.id}`}),w.jsxs("div",{className:"d-flex justify-content-between align-items-center mb-3",children:[w.jsxs(Ls,{to:"/sessions",className:"text-muted-custom no-print",children:["← ",r("session.backToSessions")]}),w.jsx("button",{className:"print-btn no-print",onClick:()=>window.print(),children:r("print.btn")})]}),w.jsx(be,{className:"data-card mb-4",children:w.jsx(be.Body,{children:w.jsxs(wr,{className:"align-items-center",children:[w.jsxs(Le,{children:[w.jsx("h3",{className:"mb-1",children:i.sessionName||i.scenarioName||`Session #${i.id}`}),w.jsxs("div",{className:"d-flex gap-3 align-items-center flex-wrap",children:[w.jsx(Fs,{typeId:i.sessionTypeAsInt}),w.jsx("span",{className:"text-muted-custom",children:UX(i.sessionDateAsString,n)}),w.jsxs("span",{className:"text-muted-custom",children:["Map: ",i.mapName||"-"]}),w.jsxs("span",{className:"text-muted-custom",children:["Scenario: ",i.scenarioName||"-"]})]})]}),w.jsx(Le,{xs:"auto",children:w.jsx(Tf,{success:i.success,score:i.score})})]})})}),w.jsxs(wr,{className:"mb-4 g-3",children:[w.jsx(Le,{xs:6,md:2,children:w.jsx(Dt,{title:r("session.score"),value:i.score,color:"#4a90d9"})}),w.jsx(Le,{xs:6,md:2,children:w.jsx(Dt,{title:r("session.duration"),value:zX(i.timeToFinish),color:"#9b59b6"})}),w.jsx(Le,{xs:6,md:2,children:w.jsx(Dt,{title:r("session.enemiesHit"),value:i.nbEnemyHit,color:"#27ae60"})}),w.jsx(Le,{xs:6,md:2,children:w.jsx(Dt,{title:r("session.civiliansHit"),value:i.nbCivilsHit,color:i.nbCivilsHit>0?"#e74c3c":"#27ae60"})}),w.jsx(Le,{xs:6,md:2,children:w.jsx(Dt,{title:r("session.damageTaken"),value:Math.round(i.damageTaken),color:"#f39c12"})}),w.jsx(Le,{xs:6,md:2,children:w.jsx(Dt,{title:r("session.participants"),value:u.length,color:"#1abc9c"})})]}),m.length>0&&(()=>{const P=(B,...M)=>{for(const z of M)if(B[z]!=null)return B[z];return 0},_=m.length,j=m.filter(B=>P(B,"ReactId","reactId")<0).length,N=m.filter(B=>P(B,"ReactId","reactId")>=0),R=N.length>0?N.reduce((B,M)=>B+P(M,"HitPrecision","hitPrecision"),0)/N.length:0,D=m.map(B=>({shot:P(B,"ShotIndex","shotIndex"),precision:P(B,"ReactId","reactId")>=0?Math.round(P(B,"HitPrecision","hitPrecision")*100):0})),W=N.map(B=>({index:P(B,"ShotIndex","shotIndex"),x:P(B,"HitLocationX","hitLocationX"),y:P(B,"HitLocationY","hitLocationY"),precision:P(B,"HitPrecision","hitPrecision")}));return w.jsxs(wr,{className:"mb-4 g-3",children:[w.jsx(Le,{lg:7,children:w.jsx(be,{className:"data-card h-100",children:w.jsxs(be.Body,{children:[w.jsx(be.Title,{children:r("firerange.personalStats")}),w.jsx(Sr,{className:"data-table mb-4",size:"sm",children:w.jsxs("tbody",{children:[w.jsxs("tr",{children:[w.jsx("td",{className:"text-muted-custom",children:r("firerange.shotsFired")}),w.jsx("td",{className:"text-end fw-bold",children:_})]}),w.jsxs("tr",{children:[w.jsx("td",{className:"text-muted-custom",children:r("firerange.shotsMissed")}),w.jsx("td",{className:"text-end fw-bold",children:j})]}),w.jsxs("tr",{children:[w.jsx("td",{className:"text-muted-custom",children:r("firerange.avgPrecision")}),w.jsxs("td",{className:"text-end fw-bold",children:[(R*100).toFixed(2),"%"]})]})]})}),w.jsx("h6",{className:"text-muted-custom mb-2",children:r("firerange.precisionChart")}),w.jsx(Ks,{width:"100%",height:250,children:w.jsxs(uM,{data:D,children:[w.jsx(fd,{strokeDasharray:"3 3",stroke:"#333"}),w.jsx(ta,{dataKey:"shot",stroke:"#999"}),w.jsx(ui,{domain:[0,100],stroke:"#999",tickFormatter:B=>`${B}`}),w.jsx(Qt,{contentStyle:{backgroundColor:"#1a1a2e",border:"1px solid #333"},formatter:B=>[`${B}%`,r("chart.precision")]}),w.jsx(Vi,{type:"linear",dataKey:"precision",stroke:"#ff6b8a",strokeWidth:2,dot:{fill:"#ff6b8a",r:4},activeDot:{r:6}})]})})]})})}),w.jsx(Le,{lg:5,children:w.jsx(be,{className:"data-card h-100",children:w.jsxs(be.Body,{children:[w.jsx(be.Title,{children:r("firerange.targetView")}),w.jsx(qX,{shots:W})]})})})]})})(),w.jsx(be,{className:"data-card mb-4",children:w.jsxs(be.Body,{children:[w.jsx(be.Title,{children:r("session.participants")}),w.jsxs(Sr,{hover:!0,responsive:!0,className:"data-table mb-0",children:[w.jsx("thead",{children:w.jsxs("tr",{children:[w.jsx("th",{children:r("table.user")}),w.jsx("th",{children:r("table.shotsFired")}),w.jsx("th",{children:r("table.shotsMissed")}),w.jsx("th",{children:r("table.enemiesHit")}),w.jsx("th",{children:r("table.civiliansHit")}),w.jsx("th",{children:r("table.avgPrecision")}),w.jsx("th",{children:r("table.reactionTime")}),w.jsx("th",{children:r("table.hitsReceivedIA")}),w.jsx("th",{children:r("table.enemiesKilled")}),w.jsx("th",{children:r("table.civiliansKilled")})]})}),w.jsxs("tbody",{children:[f.map((P,_)=>{const j=T.get(P.userId);return w.jsxs("tr",{children:[w.jsx("td",{children:w.jsx(Ls,{to:`/users/${P.userId}`,className:"table-link",children:j?j.firstName&&j.lastName?`${j.firstName} ${j.lastName}`:j.username:`User #${P.userId}`})}),w.jsx("td",{children:P.nbFiredShotsByUser}),w.jsx("td",{children:P.nbMissedShotsByUser}),w.jsx("td",{children:P.nbEnemyHitsByUser}),w.jsx("td",{className:P.nbCivilHitsByUser>0?"text-danger":"",children:P.nbCivilHitsByUser}),w.jsx("td",{children:P.averagePrecision!=null?`${(P.averagePrecision*100).toFixed(1)}%`:"-"}),w.jsx("td",{children:P.averageReactionTime!=null&&P.averageReactionTime>0?`${P.averageReactionTime.toFixed(0)} ms`:"-"}),w.jsx("td",{children:P.nbReceivedHitsFromEnemyIA??0}),w.jsx("td",{children:P.totalEnemyKilled??0}),w.jsx("td",{className:(P.totalCivilKilled??0)>0?"text-danger":"",children:P.totalCivilKilled??0})]},_)}),f.length===0&&w.jsx("tr",{children:w.jsx("td",{colSpan:10,className:"text-center text-muted-custom",children:r("noData")})})]})]})]})}),w.jsxs(wr,{className:"mb-4 g-3",children:[g&&w.jsx(Le,{md:6,children:w.jsx(be,{className:"data-card h-100",children:w.jsxs(be.Body,{children:[w.jsx(be.Title,{children:r("session.objectives")}),Object.entries(g).map(([P,_])=>{if(!_||typeof _!="object")return null;const j=_.maxScore>0?_.score/_.maxScore*100:0;return w.jsxs("div",{className:"mb-3",children:[w.jsxs("div",{className:"d-flex justify-content-between mb-1",children:[w.jsx("span",{children:r(`obj.${P}`)}),w.jsxs("span",{children:[_.score,"/",_.maxScore,_.success!==void 0&&w.jsx(Fa,{bg:_.success?"success":"danger",className:"ms-2",children:_.success?"OK":"X"})]})]}),w.jsx(xM,{now:j,variant:_.success?"success":"danger",className:"objective-bar"})]},P)})]})})}),A.length>0&&w.jsx(Le,{md:g?6:12,children:w.jsx(be,{className:"chart-card h-100",children:w.jsxs(be.Body,{children:[w.jsx(be.Title,{children:r("session.hitDistribution")}),w.jsx(Ks,{width:"100%",height:250,children:w.jsxs(lM,{children:[w.jsx(on,{data:A,dataKey:"value",nameKey:"name",cx:"50%",cy:"50%",outerRadius:80,label:!0,children:A.map((P,_)=>w.jsx(Tu,{fill:P.color},_))}),w.jsx(Qt,{contentStyle:{backgroundColor:"#1a1a2e",border:"1px solid #333"}}),w.jsx(_n,{})]})})]})})})]}),m.length>0&&w.jsx(be,{className:"data-card mb-4",children:w.jsxs(be.Body,{children:[w.jsx(be.Title,{children:r("session.shotDetails")}),w.jsxs(Sr,{hover:!0,responsive:!0,className:"data-table mb-0",size:"sm",children:[w.jsx("thead",{children:w.jsxs("tr",{children:[w.jsx("th",{children:r("shot.index")}),w.jsx("th",{children:r("shot.shooter")}),w.jsx("th",{children:r("shot.impactType")}),w.jsx("th",{children:r("shot.target")}),w.jsx("th",{children:r("shot.boneZone")}),w.jsx("th",{children:r("shot.precision")}),w.jsx("th",{children:r("shot.distance")}),w.jsx("th",{children:r("shot.reaction")}),w.jsx("th",{children:r("shot.killed")}),w.jsx("th",{children:r("shot.time")})]})}),w.jsx("tbody",{children:m.map((P,_)=>{const j=FL[P.reactTypeId]||"",N=WX[j]||"",R=N&&bg[N]?r(bg[N]):P.reactType||"-",D=RT[N]||"#6c757d";return w.jsxs("tr",{children:[w.jsx("td",{children:P.shotIndex}),w.jsx("td",{children:P.shooterName||`#${P.shooterId}`}),w.jsx("td",{children:w.jsx(Fa,{bg:"secondary",style:{backgroundColor:D},children:R})}),w.jsx("td",{children:P.targetName||P.targetUserName||"-"}),w.jsx("td",{children:P.targetBoneName||P.hitLocationTag||"-"}),w.jsx("td",{children:P.hitPrecision!=null?`${(P.hitPrecision*100).toFixed(1)}%`:"-"}),w.jsx("td",{children:P.hitTargetDistance!=null&&P.hitTargetDistance>0?`${P.hitTargetDistance.toFixed(1)}m`:"-"}),w.jsx("td",{children:P.reactionTime!=null&&P.reactionTime>0?`${P.reactionTime.toFixed(0)}ms`:"-"}),w.jsx("td",{children:P.targetKilled?w.jsx(Fa,{bg:"danger",children:r("badge.killed")}):"-"}),w.jsx("td",{children:P.timeStamp!=null?`${P.timeStamp.toFixed(1)}s`:"-"})]},_)})})]})]})})]})}function KX(e,t){if(!e)return"-";const r=new Date(e),n=t==="fr"?"fr-FR":"en-US";return r.toLocaleDateString(n,{day:"2-digit",month:"2-digit",year:"numeric",hour:"2-digit",minute:"2-digit"})}function VX(){const{t:e,lang:t}=zr(),r=_u(),[n,i]=C.useState([]),[o,u]=C.useState(!0),[l,f]=C.useState(""),[d,v]=C.useState("avgPrecision"),[p,m]=C.useState("desc");C.useEffect(()=>{BC().then(i).finally(()=>u(!1))},[]);const b=C.useMemo(()=>{let g=n;if(l.trim()){const E=l.toLowerCase();g=g.filter(A=>A.username.toLowerCase().includes(E)||A.firstName.toLowerCase().includes(E)||A.lastName.toLowerCase().includes(E))}return[...g].sort((E,A)=>{const T=E[d],P=A[d];return typeof T=="string"&&typeof P=="string"?p==="asc"?T.localeCompare(P):P.localeCompare(T):p==="asc"?Number(T)-Number(P):Number(P)-Number(T)})},[n,l,d,p]);function O(g){d===g?m(p==="asc"?"desc":"asc"):(v(g),m("desc"))}function x(g){return d!==g?"":p==="asc"?" ▲":" ▼"}return o?w.jsx(Pu,{}):w.jsxs(w.Fragment,{children:[w.jsx(hd,{subtitle:e("users.title")}),w.jsxs("div",{className:"d-flex justify-content-between align-items-center mb-4",children:[w.jsxs("h2",{className:"mb-0",children:[e("users.title")," (",b.length,")"]}),w.jsx("button",{className:"print-btn no-print",onClick:()=>window.print(),children:e("print.btn")})]}),w.jsx(be,{className:"data-card mb-4 no-print",children:w.jsx(be.Body,{children:w.jsx(Ir.Group,{children:w.jsx(Ir.Control,{type:"text",placeholder:e("users.search"),value:l,onChange:g=>f(g.target.value),className:"filter-input"})})})}),w.jsx(be,{className:"data-card",children:w.jsx(be.Body,{className:"p-0",children:w.jsxs(Sr,{hover:!0,responsive:!0,className:"data-table mb-0",children:[w.jsx("thead",{children:w.jsxs("tr",{children:[w.jsxs("th",{className:"sortable",onClick:()=>O("username"),children:[e("table.username"),x("username")]}),w.jsxs("th",{className:"sortable",onClick:()=>O("firstName"),children:[e("table.name"),x("firstName")]}),w.jsxs("th",{className:"sortable",onClick:()=>O("avgPrecision"),children:[e("table.avgPrecision"),x("avgPrecision")]}),w.jsxs("th",{className:"sortable",onClick:()=>O("avgReaction"),children:[e("table.avgReaction"),x("avgReaction")]}),w.jsxs("th",{className:"sortable",onClick:()=>O("lastConnection"),children:[e("table.lastConnection"),x("lastConnection")]})]})}),w.jsxs("tbody",{children:[b.map(g=>w.jsxs("tr",{className:"clickable-row",onClick:()=>r(`/users/${g.id}`),children:[w.jsx("td",{children:g.username}),w.jsx("td",{children:g.firstName||g.lastName?`${g.firstName} ${g.lastName}`.trim():"-"}),w.jsx("td",{className:"fw-bold",children:g.avgPrecision.toFixed(1)}),w.jsx("td",{children:g.avgReaction>0?`${g.avgReaction.toFixed(0)} ms`:"-"}),w.jsx("td",{children:KX(g.lastConnection,t)})]},g.id)),b.length===0&&w.jsx("tr",{children:w.jsx("td",{colSpan:5,className:"text-center text-muted-custom py-4",children:e("users.noUser")})})]})]})})})]})}function GX({debriefRows:e}){const{t,lang:r}=zr(),n=new Map;e.forEach(o=>{n.has(o.sessionId)||n.set(o.sessionId,{date:o.sessionDate,precisions:[],reactions:[]});const u=n.get(o.sessionId);o.hitPrecision>0&&u.precisions.push(o.hitPrecision),o.reactionTime>0&&u.reactions.push(o.reactionTime)});const i=Array.from(n.entries()).map(([,o])=>{const u=o.precisions.length>0?Math.round(o.precisions.reduce((f,d)=>f+d,0)/o.precisions.length*100)/100:0,l=o.reactions.length>0?Math.round(o.reactions.reduce((f,d)=>f+d,0)/o.reactions.length):0;return{date:o.date,dateLabel:new Date(o.date).toLocaleDateString(r==="fr"?"fr-FR":"en-US",{day:"2-digit",month:"2-digit"}),precision:u,reactionTime:l}}).sort((o,u)=>new Date(o.date).getTime()-new Date(u.date).getTime());return i.length===0?w.jsx("p",{className:"text-muted-custom text-center",children:"Aucune donnée"}):w.jsx(Ks,{width:"100%",height:300,children:w.jsxs(uM,{data:i,children:[w.jsx(fd,{strokeDasharray:"3 3",stroke:"#333"}),w.jsx(ta,{dataKey:"dateLabel",stroke:"#888"}),w.jsx(ui,{yAxisId:"left",stroke:"#4a90d9"}),w.jsx(ui,{yAxisId:"right",orientation:"right",stroke:"#f39c12"}),w.jsx(Qt,{contentStyle:{backgroundColor:"#1a1a2e",border:"1px solid #333"},labelFormatter:o=>o}),w.jsx(_n,{}),w.jsx(Vi,{yAxisId:"left",type:"monotone",dataKey:"precision",stroke:"#4a90d9",name:t("chart.precision"),strokeWidth:2,dot:{r:3}}),w.jsx(Vi,{yAxisId:"right",type:"monotone",dataKey:"reactionTime",stroke:"#f39c12",name:t("chart.reactionTime"),strokeWidth:2,dot:{r:3}})]})})}function MT(e){if(e<60)return`${Math.floor(e)}s`;if(e<3600)return`${Math.floor(e/60)}m ${Math.floor(e%60)}s`;const t=Math.floor(e/3600),r=Math.floor(e%3600/60);return`${t}h ${r}m`}function XX(e,t){if(!e)return"-";const r=new Date(e),n=t==="fr"?"fr-FR":"en-US";return r.toLocaleDateString(n,{day:"2-digit",month:"2-digit",year:"numeric",hour:"2-digit",minute:"2-digit"})}function YX(){const{id:e}=WT(),t=Number(e),{t:r,lang:n}=zr(),[i,o]=C.useState(null),[u,l]=C.useState([]),[f,d]=C.useState(null),[v,p]=C.useState(!0);if(C.useEffect(()=>{t&&Promise.all([RL(t).catch(()=>null),kL(t).catch(()=>[]),LL(t,!0).catch(()=>null)]).then(([x,g,E])=>{o(x),l(g),d(E)}).finally(()=>p(!1))},[t]),v)return w.jsx(Pu,{});if(!i)return w.jsx("p",{className:"text-center text-muted-custom py-5",children:r("user.notFound")});const m=i.firstName&&i.lastName?`${i.firstName} ${i.lastName}`:i.username,b=f==null?void 0:f.totals,O={};return u.forEach(x=>{O[x.sessionTypeAsInt]=(O[x.sessionTypeAsInt]||0)+1}),w.jsxs(w.Fragment,{children:[w.jsx(hd,{subtitle:m}),w.jsxs("div",{className:"d-flex justify-content-between align-items-center mb-3",children:[w.jsxs(Ls,{to:"/users",className:"text-muted-custom no-print",children:["← ",r("user.backToUsers")]}),w.jsx("button",{className:"print-btn no-print",onClick:()=>window.print(),children:r("print.btn")})]}),w.jsx(be,{className:"data-card mb-4",children:w.jsx(be.Body,{children:w.jsx(wr,{children:w.jsxs(Le,{children:[w.jsx("h3",{className:"mb-1",children:m}),w.jsxs("div",{className:"d-flex gap-3 flex-wrap text-muted-custom",children:[w.jsxs("span",{children:["@",i.username]}),w.jsx("span",{children:i.maleGender?r("user.male"):r("user.female")}),w.jsx("span",{children:i.leftHanded?r("user.leftHanded"):r("user.rightHanded")}),i.size>0&&w.jsxs("span",{children:[r("user.height"),": ",i.size," cm"]}),i.charSkinAssetName&&w.jsxs("span",{children:[r("user.avatar"),": ",i.charSkinAssetName]}),i.weaponAssetName&&w.jsxs("span",{children:[r("user.weapon"),": ",i.weaponAssetName]})]})]})})})}),w.jsxs(wr,{className:"mb-4 g-3",children:[w.jsx(Le,{xs:6,md:2,children:w.jsx(Dt,{title:r("user.sessions"),value:(f==null?void 0:f.nbSessions)||u.length,color:"#4a90d9"})}),w.jsx(Le,{xs:6,md:2,children:w.jsx(Dt,{title:r("user.totalTime"),value:MT((f==null?void 0:f.totalDuration)||0),color:"#9b59b6"})}),w.jsx(Le,{xs:6,md:2,children:w.jsx(Dt,{title:r("user.avgPrecision"),value:i.avgPrecision!=null?i.avgPrecision.toFixed(1):"-",color:"#27ae60"})}),w.jsx(Le,{xs:6,md:2,children:w.jsx(Dt,{title:r("user.avgReaction"),value:i.avgReaction!=null&&i.avgReaction>0?`${i.avgReaction.toFixed(0)}ms`:"-",color:"#f39c12"})}),w.jsx(Le,{xs:6,md:2,children:w.jsx(Dt,{title:r("user.shotsFired"),value:(b==null?void 0:b.nbFiredShotsByUser)||0,color:"#1abc9c"})}),w.jsx(Le,{xs:6,md:2,children:w.jsx(Dt,{title:r("user.enemiesKilled"),value:(b==null?void 0:b.totalEnemyKilled)||0,color:"#e74c3c"})})]}),b&&w.jsx(be,{className:"data-card mb-4",children:w.jsxs(be.Body,{children:[w.jsx(be.Title,{children:r("user.detailedStats")}),w.jsxs(wr,{className:"g-3",children:[w.jsxs(Le,{md:4,children:[w.jsx("h6",{className:"text-muted-custom",children:r("user.shots")}),w.jsx(Sr,{size:"sm",className:"data-table mb-0",children:w.jsxs("tbody",{children:[w.jsxs("tr",{children:[w.jsx("td",{children:r("stats.shotsFired")}),w.jsx("td",{className:"fw-bold",children:b.nbFiredShotsByUser})]}),w.jsxs("tr",{children:[w.jsx("td",{children:r("stats.shotsMissed")}),w.jsx("td",{children:b.nbMissedShotsByUser})]}),w.jsxs("tr",{children:[w.jsx("td",{children:r("stats.enemiesHit")}),w.jsx("td",{className:"text-success",children:b.nbEnemyHitsByUser})]}),w.jsxs("tr",{children:[w.jsx("td",{children:r("stats.civiliansHit")}),w.jsx("td",{className:b.nbCivilHitsByUser>0?"text-danger":"",children:b.nbCivilHitsByUser})]}),w.jsxs("tr",{children:[w.jsx("td",{children:r("stats.policeHit")}),w.jsx("td",{className:b.nbPoliceHitsByUser>0?"text-warning":"",children:b.nbPoliceHitsByUser})]})]})})]}),w.jsxs(Le,{md:4,children:[w.jsx("h6",{className:"text-muted-custom",children:r("user.hitsReceived")}),w.jsx(Sr,{size:"sm",className:"data-table mb-0",children:w.jsxs("tbody",{children:[w.jsxs("tr",{children:[w.jsx("td",{children:r("stats.fromEnemyIA")}),w.jsx("td",{children:b.nbReceivedHitsFromEnemyIA})]}),w.jsxs("tr",{children:[w.jsx("td",{children:r("stats.fromEnemyUsers")}),w.jsx("td",{children:b.nbReceivedHitsFromEnemyUser})]}),w.jsxs("tr",{children:[w.jsx("td",{children:r("stats.fromPolice")}),w.jsx("td",{className:b.nbReceivedHitsFromPoliceUser>0?"text-warning":"",children:b.nbReceivedHitsFromPoliceUser})]})]})})]}),w.jsxs(Le,{md:4,children:[w.jsx("h6",{className:"text-muted-custom",children:r("user.eliminations")}),w.jsx(Sr,{size:"sm",className:"data-table mb-0",children:w.jsxs("tbody",{children:[w.jsxs("tr",{children:[w.jsx("td",{children:r("stats.enemiesKilled")}),w.jsx("td",{className:"text-success",children:b.totalEnemyKilled})]}),w.jsxs("tr",{children:[w.jsx("td",{children:r("stats.civiliansKilled")}),w.jsx("td",{className:b.totalCivilKilled>0?"text-danger fw-bold":"",children:b.totalCivilKilled})]}),w.jsxs("tr",{children:[w.jsx("td",{children:r("stats.policeKilled")}),w.jsx("td",{className:b.totalPoliceKilled>0?"text-warning":"",children:b.totalPoliceKilled})]})]})})]})]})]})}),(f==null?void 0:f.sessionDebriefRows)&&f.sessionDebriefRows.length>1&&w.jsx(be,{className:"chart-card mb-4",children:w.jsxs(be.Body,{children:[w.jsx(be.Title,{children:r("user.precisionEvolution")}),w.jsx(GX,{debriefRows:f.sessionDebriefRows})]})}),Object.keys(O).length>0&&w.jsx(be,{className:"data-card mb-4",children:w.jsxs(be.Body,{children:[w.jsx(be.Title,{children:r("user.sessionTypeDistrib")}),w.jsx("div",{className:"d-flex gap-3 flex-wrap",children:Object.entries(O).map(([x,g])=>w.jsxs("div",{className:"text-center",children:[w.jsx(Fs,{typeId:Number(x)}),w.jsx("div",{className:"fw-bold mt-1",children:g})]},x))})]})}),w.jsx(be,{className:"data-card",children:w.jsxs(be.Body,{children:[w.jsxs(be.Title,{children:[r("user.sessionHistory")," (",u.length,")"]}),w.jsxs(Sr,{hover:!0,responsive:!0,className:"data-table mb-0",children:[w.jsx("thead",{children:w.jsxs("tr",{children:[w.jsx("th",{children:r("table.date")}),w.jsx("th",{children:r("table.type")}),w.jsx("th",{children:r("table.scenario")}),w.jsx("th",{children:r("table.score")}),w.jsx("th",{children:r("table.duration")}),w.jsx("th",{children:r("table.result")})]})}),w.jsxs("tbody",{children:[u.map(x=>w.jsxs("tr",{children:[w.jsx("td",{children:w.jsx(Ls,{to:`/sessions/${x.id}`,className:"table-link",children:XX(x.sessionDateAsString,n)})}),w.jsx("td",{children:w.jsx(Fs,{typeId:x.sessionTypeAsInt})}),w.jsx("td",{children:x.scenarioName||"-"}),w.jsx("td",{className:"fw-bold",children:x.score}),w.jsx("td",{children:MT(x.timeToFinish)}),w.jsx("td",{children:w.jsx(Tf,{success:x.success})})]},x.id)),u.length===0&&w.jsx("tr",{children:w.jsx("td",{colSpan:6,className:"text-center text-muted-custom",children:r("user.noSession")})})]})]})]})})]})}function QX(){return w.jsx(w2,{children:w.jsxs(Ci,{element:w.jsx(EL,{}),children:[w.jsx(Ci,{path:"/",element:w.jsx(OX,{})}),w.jsx(Ci,{path:"/sessions",element:w.jsx(BX,{})}),w.jsx(Ci,{path:"/sessions/:id",element:w.jsx(HX,{})}),w.jsx(Ci,{path:"/users",element:w.jsx(VX,{})}),w.jsx(Ci,{path:"/users/:id",element:w.jsx(YX,{})})]})})}jI.createRoot(document.getElementById("root")).render(w.jsx(I.StrictMode,{children:w.jsx(L2,{children:w.jsx(C2,{children:w.jsx(QX,{})})})}));