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 Vl=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:{}},ms={},ah={exports:{}},De={};/** * @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 oS;function gI(){if(oS)return De;oS=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,W,oe){this.props=L,this.context=W,this.refs=x,this.updater=oe||b}g.prototype.isReactComponent={},g.prototype.setState=function(L,W){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,W,"setState")},g.prototype.forceUpdate=function(L){this.updater.enqueueForceUpdate(this,L,"forceUpdate")};function E(){}E.prototype=g.prototype;function j(L,W,oe){this.props=L,this.context=W,this.refs=x,this.updater=oe||b}var A=j.prototype=new E;A.constructor=j,O(A,g.prototype),A.isPureReactComponent=!0;var T=Array.isArray,P=Object.prototype.hasOwnProperty,_={current:null},N={key:!0,ref:!0,__self:!0,__source:!0};function R(L,W,oe){var ce,me={},Pe=null,Le=null;if(W!=null)for(ce in W.ref!==void 0&&(Le=W.ref),W.key!==void 0&&(Pe=""+W.key),W)P.call(W,ce)&&!N.hasOwnProperty(ce)&&(me[ce]=W[ce]);var Ae=arguments.length-2;if(Ae===1)me.children=oe;else if(1>>1,W=H[L];if(0>>1;Li(me,Z))Pei(Le,me)?(H[L]=Le,H[Pe]=Z,L=Pe):(H[L]=me,H[ce]=Z,L=ce);else if(Pei(Le,Z))H[L]=Le,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,j=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function A(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 T(H){if(x=!1,A(H),!O)if(r(f)!==null)O=!0,Y(P);else{var ee=r(d);ee!==null&&J(T,ee.startTime-H)}}function P(H,ee){O=!1,x&&(x=!1,E(R),R=-1),b=!0;var Z=m;try{for(A(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 W=L(p.expirationTime<=ee);ee=e.unstable_now(),typeof W=="function"?p.callback=W:p===r(f)&&n(f),A(ee)}else n(f);p=r(f)}if(p!==null)var oe=!0;else{var ce=r(d);ce!==null&&J(T,ce.startTime-ee),oe=!1}return oe}finally{p=null,m=Z,b=!1}}var _=!1,N=null,R=-1,I=5,U=-1;function B(){return!(e.unstable_now()-UH||125L?(H.sortIndex=Z,t(d,H),r(f)===null&&H===r(d)&&(x?(E(R),R=-1):x=!0,J(T,Z-L))):(H.sortIndex=W,t(f,H),O||b||(O=!0,Y(P))),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 fS;function OI(){return fS||(fS=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 dS;function _I(){if(dS)return Qt;dS=1;var e=Z0(),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 j(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,j);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,j);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,j);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 A(a,s,c,h){var y=g.hasOwnProperty(s)?g[s]:null;(y!==null?y.type!==0:h||!(2M||y[k]!==S[M]){var F=` `+y[k].replace(" at new "," at ");return a.displayName&&F.includes("")&&(F=F.replace("",a.displayName)),F}while(1<=k&&0<=M);break}}}finally{oe=!1,Error.prepareStackTrace=c}return(a=a?a.displayName||a.name:"")?W(a):""}function me(a){switch(a.tag){case 5:return W(a.type);case 16:return W("Lazy");case 13:return W("Suspense");case 19:return W("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 _:return"Portal";case I: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 U:return(a._context.displayName||"Context")+".Provider";case $: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 Le(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&&A(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")?Hr(a,s.type,c):s.hasOwnProperty("defaultValue")&&Hr(a,s.type,Ae(s.defaultValue)),s.checked==null&&s.defaultChecked!=null&&(a.defaultChecked=!!s.defaultChecked)}function Pr(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 Hr(a,s,c){(s!=="number"||We(a.ownerDocument)!==a)&&(c==null?a.defaultValue=""+a._wrapperState.initialValue:a.defaultValue!==""+c&&(a.defaultValue=""+c))}var Kr=Array.isArray;function Ht(a,s,c,h){if(a=a.options,s){s={};for(var y=0;y"+s.valueOf().toString()+"",s=Bu.firstChild;a.firstChild;)a.removeChild(a.firstChild);for(;s.firstChild;)a.appendChild(s.firstChild)}});function No(a,s){if(s){var c=a.firstChild;if(c&&c===a.lastChild&&c.nodeType===3){c.nodeValue=s;return}}a.textContent=s}var Ro={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},w$=["Webkit","ms","Moz","O"];Object.keys(Ro).forEach(function(a){w$.forEach(function(s){s=s+a.charAt(0).toUpperCase()+a.substring(1),Ro[s]=Ro[a]})});function wx(a,s,c){return s==null||typeof s=="boolean"||s===""?"":c||typeof s!="number"||s===0||Ro.hasOwnProperty(a)&&Ro[a]?(""+s).trim():s+"px"}function Sx(a,s){a=a.style;for(var c in s)if(s.hasOwnProperty(c)){var h=c.indexOf("--")===0,y=wx(c,s[c],h);c==="float"&&(c="cssFloat"),h?a.setProperty(c,y):a[c]=y}}var S$=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(S$[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,ia=null,aa=null;function Ox(a){if(a=ts(a)){if(typeof xd!="function")throw Error(r(280));var s=a.stateNode;s&&(s=ul(s),xd(a.stateNode,a.type,s))}}function _x(a){ia?aa?aa.push(a):aa=[a]:ia=a}function Px(){if(ia){var a=ia,s=aa;if(aa=ia=null,Ox(a),s)for(a=0;a>>=0,a===0?32:31-(R$(a)/$$|0)|0}var Wu=64,Hu=4194304;function Do(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 Ku(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 M=k&~y;M!==0?h=Do(M):(S&=k,S!==0&&(h=Do(S)))}else k=c&~y,k!==0?h=Do(k):S!==0&&(h=Do(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 Lo(a,s,c){a.pendingLanes|=s,s!==536870912&&(a.suspendedLanes=0,a.pingedLanes=0),a=a.eventTimes,s=31-jr(s),a[s]=c}function L$(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=Ko),Jx=" ",ew=!1;function tw(a,s){switch(a){case"keyup":return dM.indexOf(s.keyCode)!==-1;case"keydown":return s.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function rw(a){return a=a.detail,typeof a=="object"&&"data"in a?a.data:null}var ua=!1;function hM(a,s){switch(a){case"compositionend":return rw(s);case"keypress":return s.which!==32?null:(ew=!0,Jx);case"textInput":return a=s.data,a===Jx&&ew?null:a;default:return null}}function vM(a,s){if(ua)return a==="compositionend"||!Ld&&tw(a,s)?(a=Vx(),Qu=Nd=zn=null,ua=!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=lw(c)}}function fw(a,s){return a&&s?a===s?!0:a&&a.nodeType===3?!1:s&&s.nodeType===3?fw(a,s.parentNode):"contains"in a?a.contains(s):a.compareDocumentPosition?!!(a.compareDocumentPosition(s)&16):!1:!1}function dw(){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 _M(a){var s=dw(),c=a.focusedElem,h=a.selectionRange;if(s!==c&&c&&c.ownerDocument&&fw(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=cw(c,S);var k=cw(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,la=null,zd=null,Yo=null,Ud=!1;function pw(a,s,c){var h=c.window===c?c.document:c.nodeType===9?c:c.ownerDocument;Ud||la==null||la!==We(h)||(h=la,"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}),Yo&&Xo(Yo,h)||(Yo=h,h=al(zd,"onSelect"),0ha||(a.current=tp[ha],tp[ha]=null,ha--)}function Xe(a,s){ha++,tp[ha]=a.current,a.current=s}var Kn={},Rt=Hn(Kn),Kt=Hn(!1),bi=Kn;function va(a,s){var c=a.type.contextTypes;if(!c)return Kn;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 Vt(a){return a=a.childContextTypes,a!=null}function ll(){tt(Kt),tt(Rt)}function Aw(a,s,c){if(Rt.current!==Kn)throw Error(r(168));Xe(Rt,s),Xe(Kt,c)}function Tw(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,Le(a)||"Unknown",y));return Z({},c,h)}function cl(a){return a=(a=a.stateNode)&&a.__reactInternalMemoizedMergedChildContext||Kn,bi=Rt.current,Xe(Rt,a),Xe(Kt,Kt.current),!0}function Cw(a,s,c){var h=a.stateNode;if(!h)throw Error(r(169));c?(a=Tw(a,s,bi),h.__reactInternalMemoizedMergedChildContext=a,tt(Kt),tt(Rt),Xe(Rt,a)):tt(Kt),Xe(Kt,c)}var ln=null,fl=!1,rp=!1;function kw(a){ln===null?ln=[a]:ln.push(a)}function IM(a){fl=!0,kw(a)}function Vn(){if(!rp&&ln!==null){rp=!0;var a=0,s=Ke;try{var c=ln;for(Ke=1;a>=k,y-=k,cn=1<<32-jr(s)+y|c<Ee?(Et=we,we=null):Et=we.sibling;var Fe=re(K,we,X[Ee],ue);if(Fe===null){we===null&&(we=Et);break}a&&we&&Fe.alternate===null&&s(K,we),q=S(Fe,q,Ee),xe===null?ye=Fe:xe.sibling=Fe,xe=Fe,we=Et}if(Ee===X.length)return c(K,we),nt&&wi(K,Ee),ye;if(we===null){for(;EeEe?(Et=we,we=null):Et=we.sibling;var ri=re(K,we,Fe.value,ue);if(ri===null){we===null&&(we=Et);break}a&&we&&ri.alternate===null&&s(K,we),q=S(ri,q,Ee),xe===null?ye=ri:xe.sibling=ri,xe=ri,we=Et}if(Fe.done)return c(K,we),nt&&wi(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&&wi(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&&wi(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 P: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&&Dw(ye)===xe.type){c(K,xe.sibling),q=y(xe,X.props),q.ref=rs(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=Ti(X.props.children,K.mode,ue,X.key),q.return=K,K=q):(ue=Bl(X.type,X.key,X.props,null,K.mode,ue),ue.ref=rs(K,q,X),ue.return=K,K=ue)}return k(K);case _: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(Kr(X))return he(K,q,X,ue);if(ee(X))return ve(K,q,X,ue);vl(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 ba=Lw(!0),Bw=Lw(!1),ml=Hn(null),yl=null,xa=null,up=null;function lp(){up=xa=yl=null}function cp(a){var s=ml.current;tt(ml),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 wa(a,s){yl=a,up=xa=null,a=a.dependencies,a!==null&&a.firstContext!==null&&((a.lanes&s)!==0&&(Gt=!0),a.firstContext=null)}function pr(a){var s=a._currentValue;if(up!==a)if(a={context:a,memoizedValue:s,next:null},xa===null){if(yl===null)throw Error(r(308));xa=a,yl.dependencies={lanes:0,firstContext:a}}else xa=xa.next=a;return s}var Si=null;function dp(a){Si===null?Si=[a]:Si.push(a)}function Fw(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,dn(a,h)}function dn(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 Gn=!1;function pp(a){a.updateQueue={baseState:a.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function qw(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 pn(a,s){return{eventTime:a,lane:s,tag:0,payload:null,callback:null,next:null}}function Xn(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,dn(a,c)}return y=h.interleaved,y===null?(s.next=s,dp(h)):(s.next=y.next,y.next=s),h.interleaved=s,dn(a,c)}function gl(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 zw(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 bl(a,s,c,h){var y=a.updateQueue;Gn=!1;var S=y.firstBaseUpdate,k=y.lastBaseUpdate,M=y.shared.pending;if(M!==null){y.shared.pending=null;var F=M,Q=F.next;F.next=null,k===null?S=Q:k.next=Q,k=F;var ie=a.alternate;ie!==null&&(ie=ie.updateQueue,M=ie.lastBaseUpdate,M!==k&&(M===null?ie.firstBaseUpdate=Q:M.next=Q,ie.lastBaseUpdate=F))}if(S!==null){var se=y.baseState;k=0,ie=Q=F=null,M=S;do{var re=M.lane,fe=M.eventTime;if((h&re)===re){ie!==null&&(ie=ie.next={eventTime:fe,lane:0,tag:M.tag,payload:M.payload,callback:M.callback,next:null});e:{var he=a,ve=M;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:Gn=!0}}M.callback!==null&&M.lane!==0&&(a.flags|=64,re=y.effects,re===null?y.effects=[M]:re.push(M))}else fe={eventTime:fe,lane:re,tag:M.tag,payload:M.payload,callback:M.callback,next:null},ie===null?(Q=ie=fe,F=se):ie=ie.next=fe,k|=re;if(M=M.next,M===null){if(M=y.shared.pending,M===null)break;re=M,M=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);Pi|=k,a.lanes=k,a.memoizedState=se}}function Uw(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 u1(){return hr().memoizedState}function FM(a,s,c){var h=Jn(a);if(c={lane:h,action:c,hasEagerState:!1,eagerState:null,next:null},l1(a))c1(s,c);else if(c=Fw(a,s,c,h),c!==null){var y=Ft();Rr(c,a,h,y),f1(c,s,h)}}function qM(a,s,c){var h=Jn(a),y={lane:h,action:c,hasEagerState:!1,eagerState:null,next:null};if(l1(a))c1(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,M=S(k,c);if(y.hasEagerState=!0,y.eagerState=M,Ar(M,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=Fw(a,s,y,h),c!==null&&(y=Ft(),Rr(c,a,h,y),f1(c,s,h))}}function l1(a){var s=a.alternate;return a===ot||s!==null&&s===ot}function c1(a,s){os=Sl=!0;var c=a.pending;c===null?s.next=s:(s.next=c.next,c.next=s),a.pending=s}function f1(a,s,c){if((c&4194240)!==0){var h=s.lanes;h&=a.pendingLanes,c|=h,s.lanes=c,jd(a,c)}}var Pl={readContext:pr,useCallback:$t,useContext:$t,useEffect:$t,useImperativeHandle:$t,useInsertionEffect:$t,useLayoutEffect:$t,useMemo:$t,useReducer:$t,useRef:$t,useState:$t,useDebugValue:$t,useDeferredValue:$t,useTransition:$t,useMutableSource:$t,useSyncExternalStore:$t,useId:$t,unstable_isNewReconciler:!1},zM={readContext:pr,useCallback:function(a,s){return Yr().memoizedState=[a,s===void 0?null:s],a},useContext:pr,useEffect:e1,useImperativeHandle:function(a,s,c){return c=c!=null?c.concat([a]):null,Ol(4194308,4,n1.bind(null,s,a),c)},useLayoutEffect:function(a,s){return Ol(4194308,4,a,s)},useInsertionEffect:function(a,s){return Ol(4,2,a,s)},useMemo:function(a,s){var c=Yr();return s=s===void 0?null:s,a=a(),c.memoizedState=[a,s],a},useReducer:function(a,s,c){var h=Yr();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=FM.bind(null,ot,a),[h.memoizedState,a]},useRef:function(a){var s=Yr();return a={current:a},s.memoizedState=a},useState:Zw,useDebugValue:Pp,useDeferredValue:function(a){return Yr().memoizedState=a},useTransition:function(){var a=Zw(!1),s=a[0];return a=BM.bind(null,a[1]),Yr().memoizedState=a,[s,a]},useMutableSource:function(){},useSyncExternalStore:function(a,s,c){var h=ot,y=Yr();if(nt){if(c===void 0)throw Error(r(407));c=c()}else{if(c=s(),Pt===null)throw Error(r(349));(_i&30)!==0||Vw(h,s,c)}y.memoizedState=c;var S={value:c,getSnapshot:s};return y.queue=S,e1(Xw.bind(null,h,S,a),[a]),h.flags|=2048,ls(9,Gw.bind(null,h,S,c,s),void 0,null),c},useId:function(){var a=Yr(),s=Pt.identifierPrefix;if(nt){var c=fn,h=cn;c=(h&~(1<<32-jr(h)-1)).toString(32)+c,s=":"+s+"R"+c,c=ss++,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[Gr]=s,a[es]=h,k1(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;yEa&&(s.flags|=128,h=!0,cs(S,!1),s.lanes=4194304)}else{if(!h)if(a=xl(k),a!==null){if(s.flags|=128,h=!0,c=a.updateQueue,c!==null&&(s.updateQueue=c,s.flags|=4),cs(S,!0),S.tail===null&&S.tailMode==="hidden"&&!k.alternate&&!nt)return Mt(s),null}else 2*ft()-S.renderingStartTime>Ea&&c!==1073741824&&(s.flags|=128,h=!0,cs(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 YM(a,s){switch(ip(s),s.tag){case 1:return Vt(s.type)&&ll(),a=s.flags,a&65536?(s.flags=a&-65537|128,s):null;case 3:return Sa(),tt(Kt),tt(Rt),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));ga()}return a=s.flags,a&65536?(s.flags=a&-65537|128,s):null;case 19:return tt(at),null;case 4:return Sa(),null;case 10:return cp(s.type._context),null;case 22:case 23:return Xp(),null;case 24:return null;default:return null}}var Tl=!1,It=!1,QM=typeof WeakSet=="function"?WeakSet:Set,de=null;function _a(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 $1=!1;function ZM(a,s){if(Xd=Xu,a=dw(),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,M=-1,F=-1,Q=0,ie=0,se=a,re=null;t:for(;;){for(var fe;se!==c||y!==0&&se.nodeType!==3||(M=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&&(M=k),re===S&&++ie===h&&(F=k),(fe=se.nextSibling)!==null)break;se=re,re=se.parentNode}se=fe}c=M===-1||F===-1?null:{start:M,end:F}}else c=null}c=c||{start:0,end:0}}else c=null;for(Yd={focusedElem:a,selectionRange:c},Xu=!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:Cr(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=$1,$1=!1,he}function fs(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 Cl(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[Gr],delete s[es],delete s[ep],delete s[$M],delete s[MM])),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 I1(a){return a.tag===5||a.tag===3||a.tag===4}function D1(a){e:for(;;){for(;a.sibling===null;){if(a.return===null||I1(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=sl));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 Ct=null,kr=!1;function Yn(a,s,c){for(c=c.child;c!==null;)L1(a,s,c),c=c.sibling}function L1(a,s,c){if(Vr&&typeof Vr.onCommitFiberUnmount=="function")try{Vr.onCommitFiberUnmount(Uu,c)}catch{}switch(c.tag){case 5:It||_a(c,s);case 6:var h=Ct,y=kr;Ct=null,Yn(a,s,c),Ct=h,kr=y,Ct!==null&&(kr?(a=Ct,c=c.stateNode,a.nodeType===8?a.parentNode.removeChild(c):a.removeChild(c)):Ct.removeChild(c.stateNode));break;case 18:Ct!==null&&(kr?(a=Ct,c=c.stateNode,a.nodeType===8?Jd(a.parentNode,c):a.nodeType===1&&Jd(a,c),Uo(a)):Jd(Ct,c.stateNode));break;case 4:h=Ct,y=kr,Ct=c.stateNode.containerInfo,kr=!0,Yn(a,s,c),Ct=h,kr=y;break;case 0:case 11:case 14:case 15:if(!It&&(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)}Yn(a,s,c);break;case 1:if(!It&&(_a(c,s),h=c.stateNode,typeof h.componentWillUnmount=="function"))try{h.props=c.memoizedProps,h.state=c.memoizedState,h.componentWillUnmount()}catch(M){ut(c,s,M)}Yn(a,s,c);break;case 21:Yn(a,s,c);break;case 22:c.mode&1?(It=(h=It)||c.memoizedState!==null,Yn(a,s,c),It=h):Yn(a,s,c);break;default:Yn(a,s,c)}}function B1(a){var s=a.updateQueue;if(s!==null){a.updateQueue=null;var c=a.stateNode;c===null&&(c=a.stateNode=new QM),s.forEach(function(h){var y=sI.bind(null,a,h);c.has(h)||(c.add(h),h.then(y,y))})}}function Nr(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,Zn===null)var h=!1;else{if(a=Zn,Zn=null,Ml=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 M=S.deletions;if(M!==null){for(var F=0;Fft()-Up?ji(a,0):zp|=c),Yt(a,s)}function Z1(a,s){s===0&&((a.mode&1)===0?s=1:(s=Hu,Hu<<=1,(Hu&130023424)===0&&(Hu=4194304)));var c=Ft();a=dn(a,s),a!==null&&(Lo(a,s,c),Yt(a,c))}function oI(a){var s=a.memoizedState,c=0;s!==null&&(c=s.retryLane),Z1(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),Z1(a,c)}var J1;J1=function(a,s,c){if(a!==null)if(a.memoizedProps!==s.pendingProps||Kt.current)Gt=!0;else{if((a.lanes&c)===0&&(s.flags&128)===0)return Gt=!1,GM(a,s,c);Gt=(a.flags&131072)!==0}else Gt=!1,nt&&(s.flags&1048576)!==0&&Nw(s,pl,s.index);switch(s.lanes=0,s.tag){case 2:var h=s.type;Al(a,s),a=s.pendingProps;var y=va(s,Rt.current);wa(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,Vt(h)?(S=!0,cl(s)):S=!1,s.memoizedState=y.state!==null&&y.state!==void 0?y.state:null,pp(s),y.updater=El,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(Al(a,s),a=s.pendingProps,y=h._init,h=y(h._payload),s.type=h,y=s.tag=lI(h),a=Cr(h,a),y){case 0:s=Cp(null,s,h,a,c);break e;case 1:s=P1(null,s,h,a,c);break e;case 11:s=x1(null,s,h,a,c);break e;case 14:s=w1(null,s,h,Cr(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:Cr(h,y),Cp(a,s,h,y,c);case 1:return h=s.type,y=s.pendingProps,y=s.elementType===h?y:Cr(h,y),P1(a,s,h,y,c);case 3:e:{if(E1(s),a===null)throw Error(r(387));h=s.pendingProps,S=s.memoizedState,y=S.element,qw(a,s),bl(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=Oa(Error(r(423)),s),s=j1(a,s,h,c,y);break e}else if(h!==y){y=Oa(Error(r(424)),s),s=j1(a,s,h,c,y);break e}else for(rr=Wn(s.stateNode.containerInfo.firstChild),tr=s,nt=!0,Tr=null,c=Bw(s,null,h,c),s.child=c;c;)c.flags=c.flags&-3|4096,c=c.sibling;else{if(ga(),h===y){s=hn(a,s,c);break e}Bt(a,s,h,c)}s=s.child}return s;case 5:return Ww(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),_1(a,s),Bt(a,s,k,c),s.child;case 6:return a===null&&op(s),null;case 13:return A1(a,s,c);case 4:return hp(s,s.stateNode.containerInfo),h=s.pendingProps,a===null?s.child=ba(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:Cr(h,y),x1(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(ml,h._currentValue),h._currentValue=k,S!==null)if(Ar(S.value,k)){if(S.children===y.children&&!Kt.current){s=hn(a,s,c);break e}}else for(S=s.child,S!==null&&(S.return=s);S!==null;){var M=S.dependencies;if(M!==null){k=S.child;for(var F=M.firstContext;F!==null;){if(F.context===h){if(S.tag===1){F=pn(-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),M.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,M=k.alternate,M!==null&&(M.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,wa(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=Cr(h,s.pendingProps),y=Cr(h.type,y),w1(a,s,h,y,c);case 15:return S1(a,s,s.type,s.pendingProps,c);case 17:return h=s.type,y=s.pendingProps,y=s.elementType===h?y:Cr(h,y),Al(a,s),s.tag=1,Vt(h)?(a=!0,cl(s)):a=!1,wa(s,c),p1(s,h,y),jp(s,h,y,c),kp(null,s,h,!0,a,c);case 19:return C1(a,s,c);case 22:return O1(a,s,c)}throw Error(r(156,s.tag))};function eS(a,s){return Rx(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===$)return 11;if(a===V)return 14}return 2}function ti(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 Bl(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 Ti(c.children,y,S,s);case R:k=8,y|=8;break;case I:return a=mr(12,c,s,y|2),a.elementType=I,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 Fl(c,y,S,s);default:if(typeof a=="object"&&a!==null)switch(a.$$typeof){case U:k=10;break e;case B:k=9;break e;case $: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 Ti(a,s,c,h){return a=mr(7,a,h,s),a.lanes=c,a}function Fl(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,M,F){return a=new cI(a,s,c,M,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 hS;function PI(){if(hS)return Gl;hS=1;var e=IT();return Gl.createRoot=e.createRoot,Gl.hydrateRoot=e.hydrateRoot,Gl}var EI=PI();const jI=Ue(EI);var AI=IT();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 Ls(){return Ls=Object.assign?Object.assign.bind():function(e){for(var t=1;t"u")throw new Error(t)}function xf(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 mS(e,t){return{usr:e.state,key:e.key,idx:t}}function xg(e,t,r,n){return r===void 0&&(r=null),Ls({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof t=="string"?Yi(t):t,{state:r,key:t&&t.key||n||CI()})}function pc(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 Yi(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=oi.Pop,f=null,d=v();d==null&&(d=0,u.replaceState(Ls({},u.state,{idx:d}),""));function v(){return(u.state||{idx:null}).idx}function p(){l=oi.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=oi.Push;let j=xg(x.location,g,E);r&&r(j,g),d=v()+1;let A=mS(j,d),T=x.createHref(j);try{u.pushState(A,"",T)}catch(P){if(P instanceof DOMException&&P.name==="DataCloneError")throw P;i.location.assign(T)}o&&f&&f({action:l,location:x.location,delta:1})}function b(g,E){l=oi.Replace;let j=xg(x.location,g,E);r&&r(j,g),d=v();let A=mS(j,d),T=x.createHref(j);u.replaceState(A,"",T),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,j=typeof g=="string"?g:pc(g);return j=j.replace(/ $/,"%20"),ct(E,"No window.location.(origin|href) available to create URL for href: "+j),new URL(j,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(vS,p),f=g,()=>{i.removeEventListener(vS,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 yS;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(yS||(yS={}));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"?Yi(t):t,o=Ka(i.pathname||"/",r);if(o==null)return null;let u=DT(e);$I(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=ui([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+'".')),DT(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 LT(o.path))i(o,u,f)}),t}function LT(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=LT(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 $I(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 MI=/^:[\w-]+$/,II=3,DI=2,LI=1,BI=10,FI=-2,gS=e=>e==="*";function qI(e,t){let r=e.split("/"),n=r.length;return r.some(gS)&&(n+=FI),t&&(n+=DI),r.filter(i=>!gS(i)).reduce((i,o)=>i+(MI.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),xf(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 xf(!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 Ka(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"?Yi(e):e,o;if(r)if(VI(r))o=r;else{if(r.includes("//")){let u=r;r=r.replace(/\/\/+/g,"/"),xf(!1,"Pathnames cannot have embedded double slashes - normalizing "+(u+" -> "+r))}r.startsWith("/")?o=bS(r.substring(1),"/"):o=bS(r,t)}else o=t;return{pathname:o,search:QI(n),hash:ZI(i)}}function bS(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 BT(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 FT(e,t,r,n){n===void 0&&(n=!1);let i;typeof e=="string"?i=Yi(e):(i=Ls({},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 ui=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 qT=["post","put","patch","delete"];new Set(qT);const e2=["get",...qT];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 Bs(){return Bs=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=FT(d,JSON.parse(u),o,v.relative==="path");e==null&&t!=="/"&&(p.pathname=p.pathname==="/"?t:ui([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(Rn).outlet;return t&&C.createElement(n2.Provider,{value:e},t)}function HT(){let{matches:e}=C.useContext(Rn),t=e[e.length-1];return t?t.params:{}}function Of(e,t){let{relative:r}=t===void 0?{}:t,{future:n}=C.useContext(di),{matches:i}=C.useContext(Rn),{pathname:o}=bo(),u=JSON.stringify(BT(i,n.v7_relativeSplatPath));return C.useMemo(()=>FT(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){Pu()||ct(!1);let{navigator:i}=C.useContext(di),{matches:o}=C.useContext(Rn),u=o[o.length-1],l=u?u.params:{};u&&u.pathname;let f=u?u.pathnameBase:"/";u&&u.route;let d=bo(),v;if(t){var p;let g=typeof t=="string"?Yi(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:ui([f,i.encodeLocation?i.encodeLocation(g.pathname).pathname:g.pathname]),pathnameBase:g.pathnameBase==="/"?f:ui([f,i.encodeLocation?i.encodeLocation(g.pathnameBase).pathname:g.pathnameBase])})),o,r,n);return t&&x?C.createElement(Sf.Provider,{value:{location:Bs({pathname:"/",search:"",hash:"",state:null,key:"default"},v),navigationType:oi.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(Rn.Provider,{value:this.props.routeContext},C.createElement(UT.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(wf);return i&&i.static&&i.staticContext&&(r.route.errorElement||r.route.ErrorBoundary)&&(i.staticContext._deepestRenderedBoundaryId=r.route.id),C.createElement(Rn.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)),j=()=>{let A;return b?A=x:O?A=g:p.route.Component?A=C.createElement(p.route.Component,null):p.route.element?A=p.route.element:A=v,C.createElement(c2,{match:p,routeContext:{outlet:v,matches:E,isDataRoute:r!=null},children:A})};return r&&(p.route.ErrorBoundary||p.route.errorElement||m===0)?C.createElement(l2,{location:r.location,revalidation:r.revalidation,component:x,error:b,children:j(),routeContext:{outlet:null,matches:E,isDataRoute:!0}}):j()},null)}var KT=(function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e})(KT||{}),VT=(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})(VT||{});function d2(e){let t=C.useContext(wf);return t||ct(!1),t}function p2(e){let t=C.useContext(zT);return t||ct(!1),t}function h2(e){let t=C.useContext(Rn);return t||ct(!1),t}function GT(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(UT),r=p2(),n=GT();return t!==void 0?t:(e=r.errors)==null?void 0:e[n]}function m2(){let{router:e}=d2(KT.UseNavigateStable),t=GT(VT.UseNavigateStable),r=C.useRef(!1);return WT(()=>{r.current=!0}),C.useCallback(function(i,o){o===void 0&&(o={}),r.current&&(typeof i=="number"?e.navigate(i):e.navigate(i,Bs({fromRouteId:t},o)))},[e,t])}const xS={};function y2(e,t,r){xS[e]||(xS[e]=!0)}function g2(e,t){e==null||e.v7_startTransition,e==null||e.v7_relativeSplatPath}function b2(e){return i2(e.context)}function Ri(e){ct(!1)}function x2(e){let{basename:t="/",children:r=null,location:n,navigationType:i=oi.Pop,navigator:o,static:u=!1,future:l}=e;Pu()&&ct(!1);let f=t.replace(/^\/*/,"/"),d=C.useMemo(()=>({basename:f,navigator:o,static:u,future:Bs({v7_relativeSplatPath:!1},l)}),[f,l,o,u]);typeof n=="string"&&(n=Yi(n));let{pathname:v="/",search:p="",hash:m="",state:b=null,key:O="default"}=n,x=C.useMemo(()=>{let g=Ka(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(di.Provider,{value:d},C.createElement(Sf.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!==Ri&&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 hc(){return hc=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",wS=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&&wS?wS(()=>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,Fs=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=XT(t,P2),{basename:b}=C.useContext(di),O,x=!1;if(typeof d=="string"&&N2.test(d)&&(O=d,k2))try{let A=new URL(window.location.href),T=d.startsWith("//")?new URL(A.protocol+d):new URL(d),P=Ka(T.pathname,b);T.origin===A.origin&&P!=null?d=P+T.search+T.hash:x=!0}catch{}let g=t2(d,{relative:i}),E=$2(d,{replace:u,state:l,target:f,preventScrollReset:v,relative:i,viewTransition:p});function j(A){n&&n(A),A.defaultPrevented||E(A)}return C.createElement("a",hc({},m,{href:O||g,onClick:x||o?n:j,ref:r,target:f}))}),Xl=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=XT(t,E2),m=Of(f,{relative:p.relative}),b=bo(),O=C.useContext(zT),{navigator:x,basename:g}=C.useContext(di),E=O!=null&&I2(m)&&d===!0,j=x.encodeLocation?x.encodeLocation(m).pathname:m.pathname,A=b.pathname,T=O&&O.navigation&&O.navigation.location?O.navigation.location.pathname:null;i||(A=A.toLowerCase(),T=T?T.toLowerCase():null,j=j.toLowerCase()),T&&g&&(T=Ka(T,g)||T);const P=j!=="/"&&j.endsWith("/")?j.length-1:j.length;let _=A===j||!u&&A.startsWith(j)&&A.charAt(P)==="/",N=T!=null&&(T===j||!u&&T.startsWith(j)&&T.charAt(j.length)==="/"),R={isActive:_,isPending:N,isTransitioning:E},I=_?n:void 0,U;typeof o=="function"?U=o(R):U=[o,_?"active":null,N?"pending":null,E?"transitioning":null].filter(Boolean).join(" ");let B=typeof l=="function"?l(R):l;return C.createElement(Fs,hc({},p,{"aria-current":I,className:U,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 SS;(function(e){e.UseFetcher="useFetcher",e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"})(SS||(SS={}));function R2(e){let t=C.useContext(wf);return t||ct(!1),t}function $2(e,t){let{target:r,replace:n,state:i,preventScrollReset:o,relative:u,viewTransition:l}=t===void 0?{}:t,f=Eu(),d=bo(),v=Of(e,{relative:u});return C.useCallback(p=>{if(O2(p,r)){p.preventDefault();let m=n!==void 0?n:pc(d)===pc(v);f(e,{replace:m,state:i,preventScrollReset:o,relative:u,viewTransition:l})}},[d,f,v,n,i,r,e,o,u,l])}function M2(e){let t=C.useRef(Og(e)),r=C.useRef(!1),n=bo(),i=C.useMemo(()=>_2(n.search,r.current?null:t.current),[n.search]),o=Eu(),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=Of(e,{relative:t.relative});if(!r.isTransitioning)return!1;let o=Ka(r.currentLocation.pathname,n)||r.currentLocation.pathname,u=Ka(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"},"firerange.targetsHit":{fr:"Cibles touchées",en:"Targets Hit"},"firerange.avgReaction":{fr:"Réaction moyenne",en:"Avg. Reaction Time"},"firerange.reactionChart":{fr:"Temps de réaction durant la session",en:"Reaction Time During Session"},"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"}},YT=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(YT.Provider,{value:{lang:t,setLang:n,t:i},children:e})}function Ur(){const e=C.useContext(YT);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 OS;function B2(){return OS||(OS=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)})});tC.displayName="NavbarBrand";function eb(e){return e&&e.ownerDocument||document}function V2(e){var t=eb(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 Yl(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 On(e,t){var r="",n="";if(typeof t=="string")return e.style.getPropertyValue(Yl(t))||G2(e).getPropertyValue(Yl(t));Object.keys(t).forEach(function(i){var o=t[i];!o&&o!==0?e.style.removeProperty(Yl(i)):J2(i)?n+=i+"("+o+") ":r+=Yl(i)+": "+o+";"}),n&&(r+="transform: "+n+";"),e.style.cssText+=";"+r}var fh={exports:{}},dh,PS;function eD(){if(PS)return dh;PS=1;var e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return dh=e,dh}var ph,ES;function tD(){if(ES)return ph;ES=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 jS;function rD(){return jS||(jS=1,fh.exports=tD()()),fh.exports}var nD=rD();const Me=Ue(nD),AS={disabled:!1},rC=D.createContext(null);var iD=function(t){return t.scrollTop},js="unmounted",ni="exited",Br="entering",gn="entered",qs="exiting",$n=(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=ni,o.appearStatus=Br):f=gn:n.unmountOnExit||n.mountOnEnter?f=js:f=ni,o.state={status:f},o.nextCallback=null,o}t.getDerivedStateFromProps=function(i,o){var u=i.in;return u&&o.status===js?{status:ni}: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!==gn&&(o=Br):(u===Br||u===gn)&&(o=qs)}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===ni&&this.setState({status:js})},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||AS.disabled){this.safeSetState({status:gn},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:gn},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||AS.disabled){this.safeSetState({status:ni},function(){i.props.onExited(l)});return}this.props.onExit(l),this.safeSetState({status:qs},function(){i.props.onExiting(l),i.onTransitionEnd(u.exit,function(){i.safeSetState({status:ni},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===js)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=QT(o,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return D.createElement(rC.Provider,{value:null},typeof u=="function"?u(i,l):D.cloneElement(D.Children.only(u),l))},t})(D.Component);$n.contextType=rC;$n.propTypes={};function Aa(){}$n.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:Aa,onEntering:Aa,onEntered:Aa,onExit:Aa,onExiting:Aa,onExited:Aa};$n.UNMOUNTED=js;$n.EXITED=ni;$n.ENTERING=Br;$n.ENTERED=gn;$n.EXITING=qs;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 xo(e){if(!e||typeof e=="function")return null;const{major:t}=oD();return t>=19?e.props.ref:e.ref}const Pf=!!(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}};Pf&&(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 mc(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=On(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=mc(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=mc(e,"transitionend",t);return function(){i(),o()}}function TS(e,t){const r=On(e,t)||"",n=r.indexOf("ms")===-1?1e3:1;return parseFloat(r)*n}function tb(e,t){const r=TS(e,"transitionDuration"),n=TS(e,"transitionDelay"),i=dD(e,o=>{o.target===e&&(i(),t(o))},r+n)}function ys(...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 nC(e){e.offsetHeight}const CS=e=>!e||typeof e=="function"?e:t=>{e.current=t};function pD(e,t){const r=CS(e),n=CS(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 Ef=D.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=_=>{m(vD(_))},O=_=>N=>{_&&p.current&&_(p.current,N)},x=C.useCallback(O(e),[e]),g=C.useCallback(O(t),[t]),E=C.useCallback(O(r),[r]),j=C.useCallback(O(n),[n]),A=C.useCallback(O(i),[i]),T=C.useCallback(O(o),[o]),P=C.useCallback(O(u),[u]);return w.jsx($n,{ref:v,...d,onEnter:x,onEntered:E,onEntering:g,onExit:j,onExited:T,onExiting:A,addEndListener:P,nodeRef:p,children:typeof l=="function"?(_,N)=>l(_,{...N,ref:b}):D.cloneElement(l,{ref:b})})});Ef.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(On(t,i[0]),10)+parseInt(On(t,i[1]),10)}const gD={[ni]:"collapse",[qs]:"collapsing",[Br]:"collapsing",[gn]:"collapse show"},iC=D.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(()=>ys(_=>{_.style[g]="0"},e),[g,e]),j=C.useMemo(()=>ys(_=>{const N=`scroll${g[0].toUpperCase()}${g.slice(1)}`;_.style[g]=`${_[N]}px`},t),[g,t]),A=C.useMemo(()=>ys(_=>{_.style[g]=null},r),[g,r]),T=C.useMemo(()=>ys(_=>{_.style[g]=`${b(g,_)}px`,nC(_)},n),[n,b,g]),P=C.useMemo(()=>ys(_=>{_.style[g]=null},i),[g,i]);return w.jsx(Ef,{ref:x,addEndListener:tb,...O,"aria-expanded":O.role?f:null,onEnter:E,onEntering:j,onEntered:A,onExit:T,onExiting:P,childRef:xo(u),in:f,timeout:d,mountOnEnter:v,unmountOnExit:p,appear:m,children:(_,N)=>D.cloneElement(u,{...N,className:Oe(o,u.props.className,gD[_],g==="width"&&"collapse-horizontal")})})});iC.displayName="Collapse";const wo=C.createContext(null);wo.displayName="NavbarContext";const aC=C.forwardRef(({children:e,bsPrefix:t,...r},n)=>{t=Re(t,"navbar-collapse");const i=C.useContext(wo);return w.jsx(iC,{in:!!(i&&i.expanded),...r,children:w.jsx("div",{ref:n,className:t,children:e})})});aC.displayName="NavbarCollapse";function bD(e){const t=C.useRef(e);return C.useEffect(()=>{t.current=e},[e]),t}function jf(e){const t=bD(e);return C.useCallback(function(...r){return t.current&&t.current(...r)},[t])}const oC=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(wo)||{},v=jf(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`})})});oC.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,kS=(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=kS(e,t),[n,i]=C.useState(()=>r?r.matches:!1);return SD(()=>{let o=kS(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=eb());try{var t=e.activeElement;return!t||!t.nodeName?null:t}catch{return e.body}}function NS(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 bn(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 Af(e){return`${kD}${e}`}function RD(e){return`${ND}${e}`}function $D(e=document){const t=e.defaultView;return Math.abs(t.innerWidth-e.documentElement.clientWidth)}const RS=Af("modal-open");class rb{constructor({ownerDocument:t,handleContainerOverflow:r=!0,isRTL:n=!1}={}){this.handleContainerOverflow=r,this.isRTL=n,this.modals=[],this.ownerDocument=t}getScrollbarWidth(){return $D(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(On(i,n)||"0",10)+t.scrollBarWidth}px`),i.setAttribute(RS,""),On(i,r)}reset(){[...this.modals].forEach(t=>this.remove(t))}removeContainerStyle(t){const r=this.getElement();r.removeAttribute(RS),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 sC=C.createContext(Pf?window:void 0);sC.Provider;function nb(){return C.useContext(sC)}const mh=(e,t)=>Pf?e==null?(t||eb()).body:(typeof e=="function"&&(e=e()),e&&"current"in e&&(e=e.current),e&&("nodeType"in e||e.getBoundingClientRect)?e:null):null;function MD(e,t){const r=nb(),[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 $S=e=>!e||typeof e=="function"?e:t=>{e.current=t};function ID(e,t){const r=$S(e),n=$S(t);return i=>{r&&r(i),n&&n(i)}}function Tf(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=bn(r);C.useEffect(()=>{t?u.current=!0:l(o.current)},[t,l]);const f=Tf(o,xo(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=Tf(v,xo(f)),m=T=>P=>{T&&v.current&&T(v.current,P)},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]),j=C.useCallback(m(u),[u]),A=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:j},l&&{addEndListener:A},{children:typeof f=="function"?(T,P)=>f(T,Object.assign({},P,{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=bn(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=Tf(l,xo(e));return o&&!t?null:C.cloneElement(e,{ref:f})}function IS(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 rb({ownerDocument:e==null?void 0:e.document})),yh}function QD(e){const t=nb(),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 uC=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:j,renderDialog:A,renderBackdrop:T=Ce=>w.jsx("div",Object.assign({},Ce)),manager:P,container:_,onShow:N,onHide:R=()=>{},onExit:I,onExited:U,onExiting:B,onEnter:$,onEntering:z,onEntered:G}=e,V=XD(e,GD);const Y=nb(),J=MD(_),H=QD(P),ee=ED(),Z=TD(r),[L,W]=C.useState(!r),oe=C.useRef(null);C.useImperativeHandle(t,()=>H,[H]),Pf&&!Z&&r&&(oe.current=vh(Y==null?void 0:Y.document)),r&&L&&W(!1);const ce=bn(()=>{if(H.add(),ge.current=mc(document,"keydown",Ae),ae.current=mc(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&&!NS(H.dialog,st)&&(oe.current=st,H.dialog.focus())}}),me=bn(()=>{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(j),oe.current=null}});C.useEffect(()=>{!r||!J||ce()},[r,J,ce]),C.useEffect(()=>{L&&me()},[L,me]),AD(()=>{me()});const Pe=bn(()=>{if(!g||!ee()||!H.isTopModal())return;const Ce=vh(Y==null?void 0:Y.document);H.dialog&&Ce&&!NS(H.dialog,Ce)&&H.dialog.focus()}),Le=bn(Ce=>{Ce.target===Ce.currentTarget&&(d==null||d(Ce),l===!0&&R())}),Ae=bn(Ce=>{f&&aD(Ce)&&H.isTopModal()&&(v==null||v(Ce),Ce.defaultPrevented||R())}),ae=C.useRef(),ge=C.useRef(),Te=(...Ce)=>{W(!0),U==null||U(...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=A?A(ne):w.jsx("div",Object.assign({},ne,{children:C.cloneElement(u,{role:"document"})}));We=IS(p,m,{unmountOnExit:!0,mountOnEnter:!0,appear:!0,in:!!r,onExit:I,onExiting:B,onExited:Te,onEnter:$,onEntering:z,onEntered:G,children:We});let Ne=null;return l&&(Ne=T({ref:H.setBackdropRef,onClick:Le}),Ne=IS(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)})});uC.displayName="Modal";const ZD=Object.assign(uC,{Manager:rb}),JD={[Br]:"show",[gn]:"show"},lC=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)=>{nC(f),n==null||n(f,d)},[n]);return w.jsx(Ef,{ref:o,addEndListener:tb,...u,onEnter:l,childRef:xo(t),children:(f,d)=>C.cloneElement(t,{...d,className:Oe("fade",e,t.props.className,JD[f],r[f])})})});lC.displayName="Fade";const cC=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})));cC.displayName="OffcanvasBody";const eL={[Br]:"show",[gn]:"show"},fC=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(Ef,{ref:f,addEndListener:tb,in:n,mountOnEnter:i,unmountOnExit:o,appear:u,...l,childRef:xo(r),children:(d,v)=>C.cloneElement(r,{...v,className:Oe(t,r.props.className,(d===Br||d===qs)&&`${e}-toggling`,eL[d])})})));fC.displayName="OffcanvasToggling";const dC=C.createContext({onHide(){}}),tL={"aria-label":Me.string,onClick:Me.func,variant:Me.oneOf(["white"])},ib=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}));ib.displayName="CloseButton";ib.propTypes=tL;const pC=C.forwardRef(({closeLabel:e="Close",closeVariant:t,closeButton:r=!1,onHide:n,children:i,...o},u)=>{const l=C.useContext(dC),f=jf(()=>{l==null||l.onHide(),n==null||n()});return w.jsxs("div",{ref:u,...o,children:[i,r&&w.jsx(ib,{"aria-label":e,variant:t,onClick:f})]})});pC.displayName="AbstractModalHeader";const hC=C.forwardRef(({bsPrefix:e,className:t,closeLabel:r="Close",closeButton:n=!1,...i},o)=>(e=Re(e,"offcanvas-header"),w.jsx(pC,{ref:o,...i,className:Oe(t,e),closeLabel:r,closeButton:n})));hC.displayName="OffcanvasHeader";const ab=(e=>C.forwardRef((t,r)=>w.jsx("div",{...t,ref:r,className:Oe(t.className,e)}))),rL=ab("h5"),vC=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})));vC.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 $i(e,t){return aL(e.querySelectorAll(t))}function DS(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=DS(e.className,t):e.setAttribute("class",DS(e.className&&e.className.baseVal||"",t))}const Ta={FIXED_CONTENT:".fixed-top, .fixed-bottom, .is-fixed, .sticky-top",STICKY_CONTENT:".sticky-top",NAVBAR_TOGGLER:".navbar-toggler"};class mC extends rb{adjustAndStore(t,r,n){const i=r.style[t];r.dataset[t]=i,On(r,{[t]:`${parseFloat(On(r,t))+n}px`})}restore(t,r){const n=r.dataset[t];n!==void 0&&(delete r.dataset[t],On(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";$i(r,Ta.FIXED_CONTENT).forEach(o=>this.adjustAndStore(n,o,t.scrollBarWidth)),$i(r,Ta.STICKY_CONTENT).forEach(o=>this.adjustAndStore(i,o,-t.scrollBarWidth)),$i(r,Ta.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";$i(r,Ta.FIXED_CONTENT).forEach(o=>this.restore(n,o)),$i(r,Ta.STICKY_CONTENT).forEach(o=>this.restore(i,o)),$i(r,Ta.NAVBAR_TOGGLER).forEach(o=>this.restore(i,o))}}let gh;function sL(e){return gh||(gh=new mC(e)),gh}function uL(e){return w.jsx(fC,{...e})}function lL(e){return w.jsx(lC,{...e})}const yC=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:j,onExit:A,onExiting:T,onEnter:P,onEntering:_,onExited:N,backdropClassName:R,manager:I,renderStaticNode:U=!1,...B},$)=>{const z=C.useRef();e=Re(e,"offcanvas");const[G,V]=C.useState(!1),Y=jf(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 I||(d?(z.current||(z.current=new mC({handleContainerOverflow:!1})),z.current):sL())}const Z=(ce,...me)=>{ce&&(ce.style.visibility="visible"),P==null||P(ce,...me)},L=(ce,...me)=>{ce&&(ce.style.visibility=""),N==null||N(...me)},W=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||U)&&oe({}),w.jsx(dC.Provider,{value:H,children:w.jsx(ZD,{show:G,ref:$,backdrop:l,container:b,keyboard:f,autoFocus:O,enforceFocus:x&&!d,restoreFocus:g,restoreFocusOptions:E,onEscapeKeyDown:v,onShow:p,onHide:Y,onEnter:Z,onEntering:_,onEntered:j,onExit:A,onExiting:T,onExited:L,manager:ee(),transition:uL,backdropTransition:lL,renderBackdrop:W,renderDialog:oe})})]})});yC.displayName="Offcanvas";const cL=Object.assign(yC,{Body:cC,Header:hC,Title:vC}),gC=C.forwardRef(({onHide:e,...t},r)=>{const n=C.useContext(wo),i=jf(()=>{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})});gC.displayName="NavbarOffcanvas";const bC=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})));bC.displayName="NavbarText";const xC=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}=ZT(e,{expanded:"onToggle"}),x=Re(r,"navbar"),g=C.useCallback((...A)=>{m==null||m(...A),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 j=C.useMemo(()=>({onToggle:()=>p==null?void 0:p(!v),bsPrefix:x,expanded:!!v,expand:n}),[x,v,n,p]);return w.jsx(wo.Provider,{value:j,children:w.jsx(vc.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}`)})})})});xC.displayName="Navbar";const Ql=Object.assign(xC,{Brand:tC,Collapse:aC,Offcanvas:gC,Text:bC,Toggle:oC});function fL(){const[,e]=C.useReducer(t=>t+1,0);return e}const ob=C.createContext(null);ob.displayName="NavContext";const wC=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 SC({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 OC=C.forwardRef((e,t)=>{let{as:r,disabled:n}=e,i=pL(e,dL);const[o,{tagName:u}]=SC(Object.assign({tagName:r,disabled:n},i));return w.jsx(u,Object.assign({},i,o,{ref:t}))});OC.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 _C({key:e,onClick:t,active:r,id:n,role:i,disabled:o}){const u=C.useContext(vc),l=C.useContext(ob),f=C.useContext(wC);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[Af("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=bn(p=>{o||(t==null||t(p),e!=null&&u&&!p.isPropagationStopped()&&u(e,p))}),[v,{isActive:d}]}const PC=C.forwardRef((e,t)=>{let{as:r=OC,active:n,eventKey:i}=e,o=mL(e,vL);const[u,l]=_C(Object.assign({key:J0(i,o.href),active:n},o));return u[Af("active")]=l.isActive,w.jsx(r,Object.assign({},o,u,{ref:t}))});PC.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 LS=()=>{},BS=Af("event-key"),EC=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(vc),p=C.useContext(wC);let m,b;p&&(o=o||"tablist",i=p.activeKey,m=p.getControlledId,b=p.getControllerId);const O=C.useRef(null),x=A=>{const T=O.current;if(!T)return null;const P=$i(T,`[${BS}]:not([aria-disabled=true])`),_=T.querySelector("[aria-selected=true]");if(!_||_!==document.activeElement)return null;const N=P.indexOf(_);if(N===-1)return null;let R=N+A;return R>=P.length&&(R=0),R<0&&(R=P.length-1),P[R]},g=(A,T)=>{A!=null&&(n==null||n(A,T),v==null||v(A,T))},E=A=>{if(u==null||u(A),!p)return;let T;switch(A.key){case"ArrowLeft":case"ArrowUp":T=x(-1);break;case"ArrowRight":case"ArrowDown":T=x(1);break;default:return}T&&(A.preventDefault(),g(T.dataset[RD("EventKey")]||null,A),d.current=!0,f())};C.useEffect(()=>{if(O.current&&d.current){const A=O.current.querySelector(`[${BS}][aria-selected=true]`);A==null||A.focus()}d.current=!1});const j=Tf(t,O);return w.jsx(vc.Provider,{value:g,children:w.jsx(ob.Provider,{value:{role:o,activeKey:J0(i),getControlledId:m||LS,getControllerId:b||LS},children:w.jsx(r,Object.assign({},l,{onKeyDown:E,ref:j,role:o}))})})});EC.displayName="Nav";const bL=Object.assign(EC,{Item:PC}),sb=C.createContext(null);sb.displayName="CardHeaderContext";const jC=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})));jC.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 ub=C.forwardRef((e,t)=>{let{onKeyDown:r}=e,n=wL(e,xL);const[i]=SC(Object.assign({tagName:"a"},n)),o=bn(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}))});ub.displayName="Anchor";const AC=C.forwardRef(({bsPrefix:e,className:t,as:r=ub,active:n,eventKey:i,disabled:o=!1,...u},l)=>{e=Re(e,"nav-link");const[f,d]=_C({key:J0(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")})});AC.displayName="NavLink";const TC=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}=ZT(e,{activeKey:"onSelect"}),m=Re(n,"nav");let b,O,x=!1;const g=C.useContext(wo),E=C.useContext(sb);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})});TC.displayName="Nav";const Zl=Object.assign(TC,{Item:jC,Link:AC}),lb=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)})});lb.displayName="Container";const OL="/ProserveReport/",_L=`${OL}logo.png`;function PL(){const{lang:e,setLang:t,t:r}=Ur();return w.jsx(Ql,{bg:"dark",variant:"dark",expand:"lg",className:"app-navbar",children:w.jsxs(lb,{fluid:!0,children:[w.jsxs(Ql.Brand,{as:Xl,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(Ql.Toggle,{"aria-controls":"main-nav"}),w.jsxs(Ql.Collapse,{id:"main-nav",children:[w.jsxs(Zl,{className:"me-auto",children:[w.jsx(Zl.Link,{as:Xl,to:"/",end:!0,children:r("nav.dashboard")}),w.jsx(Zl.Link,{as:Xl,to:"/sessions",children:r("nav.sessions")}),w.jsx(Zl.Link,{as:Xl,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(lb,{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=JT(),l=eC(),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=JT(),o=eC(),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 Ie=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)})});Ie.displayName="Col";const cb=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})));cb.displayName="CardBody";const CC=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})));CC.displayName="CardFooter";const kC=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(sb.Provider,{value:u,children:w.jsx(r,{ref:i,...n,className:Oe(t,o)})})});kC.displayName="CardHeader";const NC=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})});NC.displayName="CardImg";const RC=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})));RC.displayName="CardImgOverlay";const $C=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})));$C.displayName="CardLink";const AL=ab("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 IC=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})));IC.displayName="CardText";const TL=ab("h5"),DC=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})));DC.displayName="CardTitle";const LC=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(cb,{children:u}):u})});LC.displayName="Card";const be=Object.assign(LC,{Img:NC,Title:DC,Subtitle:MC,Body:cb,Link:$C,Text:IC,Header:kC,Footer:CC,ImgOverlay:RC}),qr=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});qr.displayName="Table";const CL="/proserve";async function nn(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 BC(e=-1){return(await nn("lists/all_sessions.php",{typeId:e})).stats||[]}async function kL(e,t=-1){return(await nn("lists/sessions_for_user.php",{userId:e,typeId:t})).stats||[]}async function NL(e){return(await nn("session/get.php",{sessionId:e})).session||null}async function FC(){return(await nn("lists/all_users.php")).stats||[]}async function RL(e){return(await nn("user/get.php",{userId:e})).user||null}async function $L(e){return(await nn("lists/users_in_session.php",{sessionId:e})).stats||[]}async function ML(e,t=-1){return(await nn("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 nn("stats/get.php",n)).stats||[]}async function DL(e,t=-1){const r={sessionId:e};return t>0&&(r.userId=t),(await nn("session/getobjectives.php",r)).participation||null}async function LL(e,t=!0){var n;return((n=(await nn("stats/userhistory.php",{userId:e,sessionId:-1,quickMode:t?"true":"false"})).stats)==null?void 0:n[0])||null}function vt({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 qa=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}`)})});qa.displayName="Badge";function Cf({success:e,score:t}){const{t:r}=Ur();return w.jsxs(qa,{bg:e?"success":"danger",children:[t!==void 0&&w.jsx("span",{className:"me-1",children:t}),r(e?"badge.success":"badge.failed")]})}var Mr=(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))(Mr||{});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"},qC={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 zs({typeId:e}){const{t}=Ur(),r=t(`sessionType.${e}`),n=qC[e]||"#6c757d";return w.jsx(qa,{style:{backgroundColor:n},className:"session-type-badge",children:r})}const zC=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}`)})});zC.displayName="Spinner";function ju(){const{t:e}=Ur();return w.jsxs("div",{className:"d-flex justify-content-center align-items-center py-5",children:[w.jsx(zC,{animation:"border",variant:"primary"}),w.jsx("span",{className:"ms-3 text-muted-custom",children:e("loading")})]})}function UC(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,yO;function nB(){if(yO)return Yh;yO=1;var e=Nf();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,gO;function Rf(){if(gO)return Qh;gO=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},Li=function(t){return Wi(t)&&t.indexOf("%")===t.length-1},le=function(t){return EB(t)&&!Tu(t)},jB=function(t){return ke(t)},St=function(t){return le(t)||Wi(t)},AB=0,_o=function(t){var r=++AB;return"".concat(t||"").concat(r)},Ut=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)&&!Wi(t))return n;var o;if(Li(t)){var u=t.indexOf("%");o=r*parseFloat(t.slice(0,u))/100}else o=+t;return Tu(o)&&(o=n),i&&o>r&&(o=r),o},ai=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 KO={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"},_n=function(t){return typeof t=="string"?t:t?t.displayName||t.name||"Component":""},VO=null,Ov=null,bb=function e(t){if(t===VO&&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,VO=t,r};function cr(e,t){var r=[],n=[];return Array.isArray(t)?n=t.map(function(i){return _n(i)}):n=[_n(t)],bb(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 GO=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&&Wi(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&&gb.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),!Oo(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 XO(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 $g(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=$e("recharts-surface",o);return D.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)}),D.createElement("title",null,l),D.createElement("desc",null,f),t)}var KB=["children","className"];function Mg(){return Mg=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=D.forwardRef(function(e,t){var r=e.children,n=e.className,i=VB(e,KB),o=$e("recharts-layer",n);return D.createElement("g",Mg({className:o},Se(i,!0),{ref:t}),r)}),zr=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,JO;function QC(){if(JO)return Ev;JO=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,e_;function QB(){if(e_)return jv;e_=1;function e(t){return t.split("")}return jv=e,jv}var Av,t_;function ZB(){if(t_)return Av;t_=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,j="(?:"+[v+l+"?",l,p,m,u].join("|")+")",A=RegExp(f+"(?="+f+")|"+j+E,"g");function T(P){return P.match(A)||[]}return Av=T,Av}var Tv,r_;function JB(){if(r_)return Tv;r_=1;var e=QB(),t=QC(),r=ZB();function n(i){return t(i)?r(i):e(i)}return Tv=n,Tv}var Cv,n_;function e3(){if(n_)return Cv;n_=1;var e=YB(),t=QC(),r=JB(),n=VC();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,i_;function t3(){if(i_)return kv;i_=1;var e=e3(),t=e("toUpperCase");return kv=t,kv}var r3=t3();const If=Ue(r3);function Qe(e){return function(){return e}}const ZC=Math.cos,bc=Math.sin,Wr=Math.sqrt,xc=Math.PI,Df=2*xc,Ig=Math.PI,Dg=2*Ig,Mi=1e-6,n3=Dg-Mi;function JC(e){this._+=e[0];for(let t=1,r=e.length;t=0))throw new Error(`invalid digits: ${e}`);if(t>15)return JC;const r=10**t;return function(n){this._+=n[0];for(let i=1,o=n.length;iMi)if(!(Math.abs(p*f-d*v)>Mi)||!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),j=Math.sqrt(m),A=o*Math.tan((Ig-Math.acos((x+m-g)/(2*E*j)))/2),T=A/j,P=A/E;Math.abs(T-1)>Mi&&this._append`L${t+T*v},${r+T*p}`,this._append`A${o},${o},0,0,${+(p*b>v*O)},${this._x1=t+P*f},${this._y1=r+P*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)>Mi||Math.abs(this._y1-v)>Mi)&&this._append`L${d},${v}`,n&&(m<0&&(m=m%Dg+Dg),m>n3?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>Mi&&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 xb(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 a3(t)}function wb(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function ek(e){this._context=e}ek.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 Lf(e){return new ek(e)}function tk(e){return e[0]}function rk(e){return e[1]}function nk(e,t){var r=Qe(!0),n=null,i=Lf,o=null,u=xb(l);e=typeof e=="function"?e:e===void 0?tk:Qe(e),t=typeof t=="function"?t:t===void 0?rk:Qe(t);function l(f){var d,v=(f=wb(f)).length,p,m=!1,b;for(n==null&&(o=i(b=u())),d=0;d<=v;++d)!(d=b;--O)l.point(A[O],T[O]);l.lineEnd(),l.areaEnd()}E&&(A[m]=+e(g,m,p),T[m]=+t(g,m,p),l.point(n?+n(g,m,p):A[m],r?+r(g,m,p):T[m]))}if(j)return l=null,j+""||null}function v(){return nk().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 ik{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 o3(e){return new ik(e,!0)}function s3(e){return new ik(e,!1)}const Sb={draw(e,t){const r=Wr(t/xc);e.moveTo(r,0),e.arc(0,0,r,0,Df)}},u3={draw(e,t){const r=Wr(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()}},ak=Wr(1/3),l3=ak*2,c3={draw(e,t){const r=Wr(t/l3),n=r*ak;e.moveTo(0,-r),e.lineTo(n,0),e.lineTo(0,r),e.lineTo(-n,0),e.closePath()}},f3={draw(e,t){const r=Wr(t),n=-r/2;e.rect(n,n,r,r)}},d3=.8908130915292852,ok=bc(xc/10)/bc(7*xc/10),p3=bc(Df/10)*ok,h3=-ZC(Df/10)*ok,v3={draw(e,t){const r=Wr(t*d3),n=p3*r,i=h3*r;e.moveTo(0,-r),e.lineTo(n,i);for(let o=1;o<5;++o){const u=Df*o/5,l=ZC(u),f=bc(u);e.lineTo(f*r,-l*r),e.lineTo(l*n-f*i,f*n+l*i)}e.closePath()}},Nv=Wr(3),m3={draw(e,t){const r=-Wr(t/(Nv*3));e.moveTo(0,r*2),e.lineTo(-Nv*r,-r),e.lineTo(Nv*r,-r),e.closePath()}},yr=-.5,gr=Wr(3)/2,Lg=1/Wr(12),y3=(Lg/2+1)*3,g3={draw(e,t){const r=Wr(t/y3),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 b3(e,t){let r=null,n=xb(i);e=typeof e=="function"?e:Qe(e||Sb),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 wc(){}function Sc(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 sk(e){this._context=e}sk.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:Sc(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:Sc(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function x3(e){return new sk(e)}function uk(e){this._context=e}uk.prototype={areaStart:wc,areaEnd:wc,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:Sc(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function w3(e){return new uk(e)}function lk(e){this._context=e}lk.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:Sc(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function S3(e){return new lk(e)}function ck(e){this._context=e}ck.prototype={areaStart:wc,areaEnd:wc,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 O3(e){return new ck(e)}function a_(e){return e<0?-1:1}function o_(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(a_(o)+a_(u))*Math.min(Math.abs(o),Math.abs(u),.5*Math.abs(l))||0}function s_(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 Oc(e){this._context=e}Oc.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,s_(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,s_(this,r=o_(this,e,t)),r);break;default:Rv(this,this._t0,r=o_(this,e,t));break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=r}}};function fk(e){this._context=new dk(e)}(fk.prototype=Object.create(Oc.prototype)).point=function(e,t){Oc.prototype.point.call(this,t,e)};function dk(e){this._context=e}dk.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 _3(e){return new Oc(e)}function P3(e){return new fk(e)}function pk(e){this._context=e}pk.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=u_(e),i=u_(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 j3(e){return new Bf(e,.5)}function A3(e){return new Bf(e,0)}function T3(e){return new Bf(e,1)}function Va(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 C3(e,t){return e[t]}function k3(e){const t=[];return t.key=e,t}function N3(){var e=Qe([]),t=Bg,r=Va,n=C3;function i(o){var u=Array.from(e.apply(this,arguments),k3),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 q3(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 hk={symbolCircle:Sb,symbolCross:u3,symbolDiamond:c3,symbolSquare:f3,symbolStar:v3,symbolTriangle:m3,symbolWye:g3},z3=Math.PI/180,U3=function(t){var r="symbol".concat(If(t));return hk[r]||Sb},W3=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*z3;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}},H3=function(t,r){hk["symbol".concat(If(t))]=r},Ob=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=F3(t,I3),d=c_(c_({},f),{},{type:n,size:o,sizeType:l}),v=function(){var g=U3(n),E=b3().type(g).size(W3(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?D.createElement("path",Fg({},O,{className:$e("recharts-symbols",p),transform:"translate(".concat(m,", ").concat(b,")"),d:v()})):null};Ob.registerSymbol=H3;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 qg(){return qg=Object.assign?Object.assign.bind():function(e){for(var t=1;t`);var j=b.inactive?d:b.color;return D.createElement("li",qg({className:g,style:p,key:"legend-item-".concat(O)},Hi(n.props,b,O)),D.createElement($g,{width:u,height:u,viewBox:v,style:m},n.renderIcon(b)),D.createElement("span",{className:"recharts-legend-item-text",style:{color:j}},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 D.createElement("ul",{className:"recharts-default-legend",style:l},this.renderItems())}}])})(C.PureComponent);Ws(_b,"displayName","Legend");Ws(_b,"defaultProps",{iconSize:14,layout:"horizontal",align:"center",verticalAlign:"middle",inactiveColor:"#ccc"});var $v,d_;function tF(){if(d_)return $v;d_=1;var e=Rf();function t(){this.__data__=new e,this.size=0}return $v=t,$v}var Mv,p_;function rF(){if(p_)return Mv;p_=1;function e(t){var r=this.__data__,n=r.delete(t);return this.size=r.size,n}return Mv=e,Mv}var Iv,h_;function nF(){if(h_)return Iv;h_=1;function e(t){return this.__data__.get(t)}return Iv=e,Iv}var Dv,v_;function iF(){if(v_)return Dv;v_=1;function e(t){return this.__data__.has(t)}return Dv=e,Dv}var Lv,m_;function aF(){if(m_)return Lv;m_=1;var e=Rf(),t=hb(),r=vb(),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,j=!0,A=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,F_;function gF(){if(F_)return sm;F_=1;var e=Mn(),t=Ab(),r=In(),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]",j="[object Float32Array]",A="[object Float64Array]",T="[object Int8Array]",P="[object Int16Array]",_="[object Int32Array]",N="[object Uint8Array]",R="[object Uint8ClampedArray]",I="[object Uint16Array]",U="[object Uint32Array]",B={};B[j]=B[A]=B[T]=B[P]=B[_]=B[N]=B[R]=B[I]=B[U]=!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 $(z){return r(z)&&t(z.length)&&!!B[e(z)]}return sm=$,sm}var um,q_;function _k(){if(q_)return um;q_=1;function e(t){return function(r){return t(r)}}return um=e,um}var Ts={exports:{}};Ts.exports;var z_;function bF(){return z_||(z_=1,(function(e,t){var r=WC(),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})(Ts,Ts.exports)),Ts.exports}var lm,U_;function Pk(){if(U_)return lm;U_=1;var e=gF(),t=_k(),r=bF(),n=r&&r.isTypedArray,i=n?t(n):e;return lm=i,lm}var cm,W_;function xF(){if(W_)return cm;W_=1;var e=vF(),t=Eb(),r=Jt(),n=Ok(),i=jb(),o=Pk(),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 j in d)(v||l.call(d,j))&&!(x&&(j=="length"||b&&(j=="offset"||j=="parent")||O&&(j=="buffer"||j=="byteLength"||j=="byteOffset")||i(j,E)))&&g.push(j);return g}return cm=f,cm}var fm,H_;function wF(){if(H_)return fm;H_=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,K_;function Ek(){if(K_)return dm;K_=1;function e(t,r){return function(n){return t(r(n))}}return dm=e,dm}var pm,V_;function SF(){if(V_)return pm;V_=1;var e=Ek(),t=e(Object.keys,Object);return pm=t,pm}var hm,G_;function OF(){if(G_)return hm;G_=1;var e=wF(),t=SF(),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,X_;function Cu(){if(X_)return vm;X_=1;var e=db(),t=Ab();function r(n){return n!=null&&t(n.length)&&!e(n)}return vm=r,vm}var mm,Y_;function Ff(){if(Y_)return mm;Y_=1;var e=xF(),t=OF(),r=Cu();function n(i){return r(i)?e(i):t(i)}return mm=n,mm}var ym,Q_;function _F(){if(Q_)return ym;Q_=1;var e=fF(),t=hF(),r=Ff();function n(i){return e(i,r,t)}return ym=n,ym}var gm,Z_;function PF(){if(Z_)return gm;Z_=1;var e=_F(),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 j=v.get(o),A=v.get(u);if(j&&A)return j==u&&A==o;var T=!0;v.set(o,u),v.set(u,o);for(var P=p;++g-1}return Wm=t,Wm}var Hm,PP;function HF(){if(PP)return Hm;PP=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(D.isValidElement(e))return D.cloneElement(e,t);if(typeof e=="function")return D.createElement(e,t);t.ref;var r=aq(t,QF);return D.createElement(_b,r)}var RP=1,Pn=(function(e){function t(){var r;ZF(this,t);for(var n=arguments.length,i=new Array(n),o=0;oRP||Math.abs(i.height-this.lastBoundingBox.height)>RP)&&(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?mn({},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 mn(mn({},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=mn(mn({position:"absolute",width:u||"auto",height:l||"auto"},this.getDefaultPosition(f)),f);return D.createElement("div",{className:"recharts-legend-wrapper",style:p,ref:function(b){n.wrapperNode=b}},uq(o,mn(mn({},this.props),{},{payload:kk(v,d,sq)})))}}],[{key:"getWithHeight",value:function(n,i){var o=mn(mn({},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);qf(Pn,"displayName","Legend");qf(Pn,"defaultProps",{iconSize:14,layout:"horizontal",align:"center",verticalAlign:"bottom"});var Ym,$P;function lq(){if($P)return Ym;$P=1;var e=Au(),t=Eb(),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 $k(){if(MP)return Qm;MP=1;var e=Sk(),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,IP;function cq(){if(IP)return Zm;IP=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,DP;function fq(){if(DP)return Jm;DP=1;var e=cq(),t=e();return Jm=t,Jm}var ey,LP;function Mk(){if(LP)return ey;LP=1;var e=fq(),t=Ff();function r(n,i){return n&&e(n,i,t)}return ey=r,ey}var ty,BP;function dq(){if(BP)return ty;BP=1;var e=Cu();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,HP;function mq(){if(HP)return sy;HP=1;var e=mb(),t=yb(),r=on(),n=Ik(),i=pq(),o=_k(),u=vq(),l=Po(),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 j=e(p,function(A){return A(x)});return{criteria:j,index:++b,value:x}});return i(O,function(x,g){return u(x,g,m)})}return sy=d,sy}var uy,KP;function yq(){if(KP)return uy;KP=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,VP;function gq(){if(VP)return ly;VP=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,ZP;function Sq(){if(ZP)return hy;ZP=1;var e=xq(),t=wq(),r=t(e);return hy=r,hy}var vy,JP;function Oq(){if(JP)return vy;JP=1;var e=Po(),t=gq(),r=Sq();function n(i,o){return r(t(i,o,e),i+"")}return vy=n,vy}var my,eE;function zf(){if(eE)return my;eE=1;var e=pb(),t=Cu(),r=jb(),n=pi();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,tE;function _q(){if(tE)return yy;tE=1;var e=$k(),t=mq(),r=Oq(),n=zf(),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 kb=Ue(Pq);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 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(gs,"-left"),le(r)&&t&&le(t.x)&&r=t.y),"".concat(gs,"-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=iE({allowEscapeViewBox:t,coordinate:r,key:"x",offsetTopLeft:n,position:i,reverseDirection:o,tooltipDimension:u.width,viewBox:f,viewBoxDimension:f.width}),p=iE({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 Ya(e){"@babel/helpers - typeof";return Ya=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},Ya(e)}function aE(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 oE(e){for(var t=1;tsE||Math.abs(n.height-this.state.lastBoundingBox.height)>sE)&&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,j=i.wrapperStyle,A=qq({allowEscapeViewBox:u,coordinate:v,offsetTopLeft:b,position:O,reverseDirection:x,tooltipBox:this.state.lastBoundingBox,useTranslate3d:g,viewBox:E}),T=A.cssClasses,P=A.cssProperties,_=oE(oE({transition:m&&o?"transform ".concat(l,"ms ").concat(f):void 0},P),{},{pointerEvents:"none",visibility:!this.state.dismissed&&o&&p?"visible":"hidden",position:"absolute",top:0,left:0},j);return D.createElement("div",{tabIndex:-1,className:T,style:_,ref:function(R){n.wrapperNode=R}},d)}}])})(C.PureComponent),Qq=function(){return!(typeof window<"u"&&window.document&&window.document.createElement&&window.setTimeout)},Zi={isSsr:Qq()};function Qa(e){"@babel/helpers - typeof";return Qa=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Qa(e)}function uE(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 lE(e){for(var t=1;t0;return D.createElement(Yq,{allowEscapeViewBox:u,animationDuration:l,animationEasing:f,isAnimationActive:m,active:o,coordinate:v,hasPayload:_,offset:b,position:g,reverseDirection:E,useTranslate3d:j,viewBox:A,wrapperStyle:T},sz(d,lE(lE({},this.props),{},{payload:P})))}}])})(C.PureComponent);Nb(qt,"displayName","Tooltip");Nb(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:!Zi.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,cE;function uz(){if(cE)return by;cE=1;var e=an(),t=function(){return e.Date.now()};return by=t,by}var xy,fE;function lz(){if(fE)return xy;fE=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,dE;function cz(){if(dE)return wy;dE=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,pE;function zk(){if(pE)return Sy;pE=1;var e=cz(),t=pi(),r=So(),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,hE;function fz(){if(hE)return Oy;hE=1;var e=pi(),t=uz(),r=zk(),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,j=!1,A=!0;if(typeof l!="function")throw new TypeError(n);f=r(f)||0,e(d)&&(E=!!d.leading,j="maxWait"in d,m=j?i(r(d.maxWait)||0,f):m,A="trailing"in d?!!d.trailing:A);function T(z){var G=v,V=p;return v=p=void 0,g=z,b=l.apply(V,G),b}function P(z){return g=z,O=setTimeout(R,f),E?T(z):b}function _(z){var G=z-x,V=z-g,Y=f-G;return j?o(Y,m-V):Y}function N(z){var G=z-x,V=z-g;return x===void 0||G>=f||G<0||j&&V>=m}function R(){var z=t();if(N(z))return I(z);O=setTimeout(R,_(z))}function I(z){return O=void 0,A&&v?T(z):(v=p=void 0,b)}function U(){O!==void 0&&clearTimeout(O),g=0,v=x=p=O=void 0}function B(){return O===void 0?b:I(t())}function $(){var z=t(),G=N(z);if(v=arguments,p=this,x=z,G){if(O===void 0)return P(x);if(j)return clearTimeout(O),O=setTimeout(R,f),T(x)}return O===void 0&&(O=setTimeout(R,f)),b}return $.cancel=U,$.flush=B,$}return Oy=u,Oy}var _y,vE;function dz(){if(vE)return _y;vE=1;var e=fz(),t=pi(),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 Uk=Ue(pz);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 mE(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 tc(e){for(var t=1;te.length)&&(t=e.length);for(var r=0,n=new Array(t);r0&&(z=Uk(z,x,{trailing:!0,leading:!1}));var G=new ResizeObserver(z),V=P.current.getBoundingClientRect(),Y=V.width,J=V.height;return B(Y,J),G.observe(P.current),function(){G.disconnect()}},[B,x]);var $=C.useMemo(function(){var z=I.containerWidth,G=I.containerHeight;if(z<0||G<0)return null;zr(Li(u)||Li(f),`The width(%s) and height(%s) are both fixed numbers, maybe you don't need to use a ResponsiveContainer.`,u,f),zr(!r||r>0,"The aspect(%s) must be greater than zero.",r);var V=Li(u)?z:u,Y=Li(f)?G:f;r&&r>0&&(V?Y=V/r:Y&&(V=Y*r),m&&Y>m&&(Y=m)),zr(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)&&_n(b.type).endsWith("Chart");return D.Children.map(b,function(H){return D.isValidElement(H)?C.cloneElement(H,tc({width:V,height:Y},J?{style:tc({height:"100%",width:"100%",maxHeight:Y,maxWidth:V},H.props.style)}:{})):H})},[r,b,f,m,p,v,I,u]);return D.createElement("div",{id:g?"".concat(g):void 0,className:$e("recharts-responsive-container",E),style:tc(tc({},T),{},{width:u,height:f,minWidth:v,minHeight:p,maxHeight:m}),ref:P},$)}),ku=function(t){return null};ku.displayName="Cell";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 gE(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||Zi.isSsr)return{width:0,height:0};var n=jz(r),i=JSON.stringify({text:t,copyStyle:n});if(Ca.widthCache[i])return Ca.widthCache[i];try{var o=document.getElementById(bE);o||(o=document.createElement("span"),o.setAttribute("id",bE),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 Ca.widthCache[i]=f,++Ca.cacheCount>Pz&&(Ca.cacheCount=0,Ca.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 Xs(e){"@babel/helpers - typeof";return Xs=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},Xs(e)}function Ac(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 xE(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 xE(e,t)}}function xE(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 EE(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 jE(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 jE(e,t)}}function jE(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=Vk({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,j=p.length-1,A=0,T;E<=j&&A<=p.length-1;){var P=Math.floor((E+j)/2),_=P-1,N=g(_),R=EE(N,2),I=R[0],U=R[1],B=g(P),$=EE(B,1),z=$[0];if(!I&&!z&&(E=P+1),I&&z&&(j=P-1),!I&&z){T=U;break}A++}return T||b},AE=function(t){var r=ke(t)?[]:t.toString().split(Kk);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)&&!Zi.isSsr){var f,d,v=Vk({breakAll:u,children:i,style:o});if(v){var p=v.wordsWithComputedWidth,m=v.spaceWidth;f=p,d=m}else return AE(i);return Qz({breakAll:u,children:i,maxLines:l,style:o},f,d,r,n)}return AE(i)},TE="#808080",Ki=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?TE:g,j=PE(t,Wz),A=C.useMemo(function(){return Zz({breakAll:j.breakAll,children:j.children,maxLines:j.maxLines,scaleToFit:p,style:j.style,width:j.width})},[j.breakAll,j.children,j.maxLines,p,j.style,j.width]),T=j.dx,P=j.dy,_=j.angle,N=j.className,R=j.breakAll,I=PE(j,Hz);if(!St(n)||!St(o))return null;var U=n+(le(T)?T:0),B=o+(le(P)?P:0),$;switch(x){case"start":$=Py("calc(".concat(d,")"));break;case"middle":$=Py("calc(".concat((A.length-1)/2," * -").concat(l," + (").concat(d," / 2))"));break;default:$=Py("calc(".concat(A.length-1," * -").concat(l,")"));break}var z=[];if(p){var G=A[0].width,V=j.width;z.push("scale(".concat((le(V)?V/G:1)/G,")"))}return _&&z.push("rotate(".concat(_,", ").concat(U,", ").concat(B,")")),z.length&&(I.transform=z.join(" ")),D.createElement("text",Xg({},Se(I,!0),{x:U,y:B,className:$e("recharts-text",N),textAnchor:b,fill:E.includes("url")?TE:E}),A.map(function(Y,J){var H=Y.words.join(R?"":" ");return D.createElement("tspan",{x:U,dy:J===0?$:l,key:"".concat(H,"-").concat(J)},H)}))};function li(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 Rb(e){let t,r,n;e.length!==2?(t=li,r=(l,f)=>li(e(l),f),n=(l,f)=>e(l)-f):(t=e===li||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 Gk(e){return e===null?NaN:+e}function*tU(e,t){for(let r of e)r!=null&&(r=+r)>=r&&(yield r)}const rU=Rb(li),Nu=rU.right;Rb(Gk).center;class CE 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(kE(this,t))}has(t){return super.has(kE(this,t))}set(t,r){return super.set(nU(this,t),r)}delete(t){return super.delete(iU(this,t))}}function kE({_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=li){if(e===li)return Xk;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 Xk(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 Tc(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 RE(e,t){let r;for(const n of e)n!=null&&(r>n||r===void 0&&n>=n)&&(r=n);return r}function Yk(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?Xk: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));Yk(e,t,b,O,i)}const o=e[t];let u=r,l=n;for(bs(e,r,t),i(e[n],o)>0&&bs(e,r,n);u0;)--l}i(e[r],o)===0?bs(e,r,l):(++l,bs(e,l,n)),l<=t&&(r=l+1),t<=l&&(n=l-1)}return e}function bs(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 RE(e);if(t>=1)return NE(e);var n,i=(n-1)*t,o=Math.floor(i),u=NE(Yk(e,o).subarray(0,o+1)),l=RE(e.subarray(o+1));return u+(l-u)*(i-o)}}function fU(e,t,r=Gk){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?nc(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):r===4?nc(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))?nc(t[1],t[2],t[3],t[4]):(t=yU.exec(e))?nc(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=gU.exec(e))?FE(t[1],t[2]/100,t[3]/100,1):(t=bU.exec(e))?FE(t[1],t[2]/100,t[3]/100,t[4]):$E.hasOwnProperty(e)?DE($E[e]):e==="transparent"?new Zt(NaN,NaN,NaN,0):null}function DE(e){return new Zt(e>>16&255,e>>8&255,e&255,1)}function nc(e,t,r,n){return n<=0&&(e=t=r=NaN),new Zt(e,t,r,n)}function SU(e){return e instanceof Ru||(e=Js(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,Zk(Ru,{brighter(e){return e=e==null?Cc:Math.pow(Cc,e),new Zt(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?Qs:Math.pow(Qs,e),new Zt(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new Zt(zi(this.r),zi(this.g),zi(this.b),kc(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:LE,formatHex:LE,formatHex8:OU,formatRgb:BE,toString:BE}));function LE(){return`#${Bi(this.r)}${Bi(this.g)}${Bi(this.b)}`}function OU(){return`#${Bi(this.r)}${Bi(this.g)}${Bi(this.b)}${Bi((isNaN(this.opacity)?1:this.opacity)*255)}`}function BE(){const e=kc(this.opacity);return`${e===1?"rgb(":"rgba("}${zi(this.r)}, ${zi(this.g)}, ${zi(this.b)}${e===1?")":`, ${e})`}`}function kc(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function zi(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function Bi(e){return e=zi(e),(e<16?"0":"")+e.toString(16)}function FE(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 Jk(e){if(e instanceof Fr)return new Fr(e.h,e.s,e.l,e.opacity);if(e instanceof Ru||(e=Js(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?Jk(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,Zk(Ru,{brighter(e){return e=e==null?Cc:Math.pow(Cc,e),new Fr(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?Qs:Math.pow(Qs,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(qE(this.h),ic(this.s),ic(this.l),kc(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=kc(this.opacity);return`${e===1?"hsl(":"hsla("}${qE(this.h)}, ${ic(this.s)*100}%, ${ic(this.l)*100}%${e===1?")":`, ${e})`}`}}));function qE(e){return e=(e||0)%360,e<0?e+360:e}function ic(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 Ib=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?eN:function(t,r){return r-t?EU(t,r,e):Ib(isNaN(t)?r:t)}}function eN(e,t){var r=t-e;return r?PU(e,r):Ib(isNaN(e)?t:e)}const zE=(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=eN(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:Nc(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),Nc)))(m)))},p.domain=function(m){return arguments.length?(e=Array.from(m,Rc),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=Db,v()},p.clamp=function(m){return arguments.length?(u=m?!0:Wt,v()):u!==Wt},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 Lb(){return Uf()(Wt,Wt)}function qU(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function $c(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 Za(e){return e=$c(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 eu(e){if(!(t=WU.exec(e)))throw new Error("invalid format: "+e);var t;return new Bb({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]})}eu.prototype=Bb.prototype;function Bb(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+""}Bb.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=$c(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")+$c(e,Math.max(0,t+o-1))[0]}function WE(e,t){var r=$c(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 HE={"%":(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)=>WE(e*100,t),r:WE,s:KU,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function KE(e){return e}var VE=Array.prototype.map,GE=["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?KE:zU(VE.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?KE:UU(VE.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=eu(p);var b=p.fill,O=p.align,x=p.sign,g=p.symbol,E=p.zero,j=p.width,A=p.comma,T=p.precision,P=p.trim,_=p.type;_==="n"?(A=!0,_="g"):HE[_]||(T===void 0&&(T=12),P=!0,_="g"),(E||b==="0"&&O==="=")&&(E=!0,b="0",O="=");var N=(m&&m.prefix!==void 0?m.prefix:"")+(g==="$"?r:g==="#"&&/[boxX]/.test(_)?"0"+_.toLowerCase():""),R=(g==="$"?n:/[%p]/.test(_)?u:"")+(m&&m.suffix!==void 0?m.suffix:""),I=HE[_],U=/[defgprs%]/.test(_);T=T===void 0?6:/[gprs]/.test(_)?Math.max(1,Math.min(21,T)):Math.max(0,Math.min(20,T));function B($){var z=N,G=R,V,Y,J;if(_==="c")G=I($)+G,$="";else{$=+$;var H=$<0||1/$<0;if($=isNaN($)?f:I(Math.abs($),T),P&&($=HU($)),H&&+$==0&&x!=="+"&&(H=!1),z=(H?x==="("?x:l:x==="-"||x==="("?"":x)+z,G=(_==="s"&&!isNaN($)&&Mc!==void 0?GE[8+Mc/3]:"")+G+(H&&x==="("?")":""),U){for(V=-1,Y=$.length;++VJ||J>57){G=(J===46?i+$.slice(V+1):$.slice(V))+G,$=$.slice(0,V);break}}}A&&!E&&($=t($,1/0));var ee=z.length+$.length+G.length,Z=ee>1)+z+$+G+Z.slice(ee);break;default:$=Z+z+$+G;break}return o($)}return B.toString=function(){return p+""},B}function v(p,m){var b=Math.max(-8,Math.min(8,Math.floor(Za(m)/3)))*3,O=Math.pow(10,-b),x=d((p=eu(p),p.type="f",p),{suffix:GE[8+b/3]});return function(g){return x(O*g)}}return{format:d,formatPrefix:v}}var ac,Fb,tN;GU({thousands:",",grouping:[3],currency:["$",""]});function GU(e){return ac=VU(e),Fb=ac.format,tN=ac.formatPrefix,ac}function XU(e){return Math.max(0,-Za(Math.abs(e)))}function YU(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(Za(t)/3)))*3-Za(Math.abs(e)))}function QU(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,Za(t)-Za(e))+1}function rN(e,t,r,n){var i=Zg(e,t,r),o;switch(n=eu(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),tN(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 Fb(n)}function hi(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 rN(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 Ic(){var e=Lb();return e.copy=function(){return $u(e,Ic())},_r.apply(e,arguments),hi(e)}function nN(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,Rc),r):e.slice()},r.unknown=function(n){return arguments.length?(t=n,r):t},r.copy=function(){return nN(e).unknown(t)},e=arguments.length?Array.from(e,Rc):[0,1],hi(r)}function iN(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 QE(e){return(t,r)=>-e(-t,r)}function qb(e){const t=e(XE,YE),r=t.domain;let n=10,i,o;function u(){return i=r4(n),o=t4(n),r()[0]<0?(i=QE(i),o=QE(o),e(ZU,JU)):e(XE,YE),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=eu(f)).precision==null&&(f.trim=!0),f=Fb(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(iN(r(),{floor:l=>o(Math.floor(i(l))),ceil:l=>o(Math.ceil(i(l)))})),t}function aN(){const e=qb(Uf()).domain([1,10]);return e.copy=()=>$u(e,aN()).base(e.base()),_r.apply(e,arguments),e}function ZE(e){return function(t){return Math.sign(t)*Math.log1p(Math.abs(t/e))}}function JE(e){return function(t){return Math.sign(t)*Math.expm1(Math.abs(t))*e}}function zb(e){var t=1,r=e(ZE(t),JE(t));return r.constant=function(n){return arguments.length?e(ZE(t=+n),JE(t)):t},hi(r)}function oN(){var e=zb(Uf());return e.copy=function(){return $u(e,oN()).constant(e.constant())},_r.apply(e,arguments)}function ej(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 Ub(e){var t=e(Wt,Wt),r=1;function n(){return r===1?e(Wt,Wt):r===.5?e(n4,i4):e(ej(r),ej(1/r))}return t.exponent=function(i){return arguments.length?(r=+i,n()):r},hi(t)}function Wb(){var e=Ub(Uf());return e.copy=function(){return $u(e,Wb()).exponent(e.exponent())},_r.apply(e,arguments),e}function a4(){return Wb.apply(null,arguments).exponent(.5)}function tj(e){return Math.sign(e)*e*e}function o4(e){return Math.sign(e)*Math.sqrt(Math.abs(e))}function sN(){var e=Lb(),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(tj(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,Rc)).map(tj)),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 sN(e.domain(),t).round(r).clamp(e.clamp()).unknown(n)},_r.apply(i,arguments),hi(i)}function uN(){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 lN().domain([e,t]).range(i).unknown(o)},_r.apply(hi(u),arguments)}function cN(){var e=[.5],t=[0,1],r,n=1;function i(o){return o!=null&&o<=o?t[Nu(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 cN().domain(e).range(t).unknown(r)},_r.apply(i,arguments)}const Ay=new Date,Ty=new Date;function Ot(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(dOt(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 Dc=Ot(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);Dc.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?Ot(t=>{t.setTime(Math.floor(t/e)*e)},(t,r)=>{t.setTime(+t+r*e)},(t,r)=>(r-t)/e):Dc);Dc.range;const xn=1e3,Sr=xn*60,wn=Sr*60,An=wn*24,Hb=An*7,rj=An*30,Cy=An*365,Fi=Ot(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*xn)},(e,t)=>(t-e)/xn,e=>e.getUTCSeconds());Fi.range;const Kb=Ot(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*xn)},(e,t)=>{e.setTime(+e+t*Sr)},(e,t)=>(t-e)/Sr,e=>e.getMinutes());Kb.range;const Vb=Ot(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*Sr)},(e,t)=>(t-e)/Sr,e=>e.getUTCMinutes());Vb.range;const Gb=Ot(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*xn-e.getMinutes()*Sr)},(e,t)=>{e.setTime(+e+t*wn)},(e,t)=>(t-e)/wn,e=>e.getHours());Gb.range;const Xb=Ot(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*wn)},(e,t)=>(t-e)/wn,e=>e.getUTCHours());Xb.range;const Mu=Ot(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*Sr)/An,e=>e.getDate()-1);Mu.range;const Wf=Ot(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/An,e=>e.getUTCDate()-1);Wf.range;const fN=Ot(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/An,e=>Math.floor(e/An));fN.range;function Ji(e){return Ot(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())*Sr)/Hb)}const Hf=Ji(0),Lc=Ji(1),s4=Ji(2),u4=Ji(3),Ja=Ji(4),l4=Ji(5),c4=Ji(6);Hf.range;Lc.range;s4.range;u4.range;Ja.range;l4.range;c4.range;function ea(e){return Ot(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)/Hb)}const Kf=ea(0),Bc=ea(1),f4=ea(2),d4=ea(3),eo=ea(4),p4=ea(5),h4=ea(6);Kf.range;Bc.range;f4.range;d4.range;eo.range;p4.range;h4.range;const Yb=Ot(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());Yb.range;const Qb=Ot(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());Qb.range;const Tn=Ot(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());Tn.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:Ot(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)});Tn.range;const Cn=Ot(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());Cn.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:Ot(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)});Cn.range;function dN(e,t,r,n,i,o){const u=[[Fi,1,xn],[Fi,5,5*xn],[Fi,15,15*xn],[Fi,30,30*xn],[o,1,Sr],[o,5,5*Sr],[o,15,15*Sr],[o,30,30*Sr],[i,1,wn],[i,3,3*wn],[i,6,6*wn],[i,12,12*wn],[n,1,An],[n,2,2*An],[r,1,Hb],[t,1,rj],[t,3,3*rj],[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 Dc.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(xs(ne.y,0,1)),Ce=Ne.getUTCDay(),Ne=Ce>4||Ce===0?Bc.ceil(Ne):Bc(Ne),Ne=Wf.offset(Ne,(ne.V-1)*7),ne.y=Ne.getUTCFullYear(),ne.m=Ne.getUTCMonth(),ne.d=Ne.getUTCDate()+(ne.w+6)%7):(Ne=ky(xs(ne.y,0,1)),Ce=Ne.getDay(),Ne=Ce>4||Ce===0?Lc.ceil(Ne):Lc(Ne),Ne=Mu.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(xs(ne.y,0,1)).getUTCDay():ky(xs(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=P[Je in nj?ge.charAt(We++):Je],!st||(ne=st(ae,Te,ne))<0)return-1}else if(Je!=Te.charCodeAt(ne++))return-1}return ne}function I(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 U(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 $(ae,ge,Te){var ne=E.exec(ge.slice(Te));return ne?(ae.m=j.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 W(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 Le(ae){return i[+(ae.getUTCHours()>=12)]}function Ae(ae){return 1+~~(ae.getUTCMonth()/3)}return{format:function(ae){var ge=_(ae+="",A);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=_(ae+="",T);return ge.toString=function(){return ae},ge},utcParse:function(ae){var ge=N(ae+="",!0);return ge.toString=function(){return ae},ge}}}var nj={"-":"",_:" ",0:"0"},Tt=/^\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=Tt.exec(t.slice(r,r+1));return n?(e.w=+n[0],r+n[0].length):-1}function _4(e,t,r){var n=Tt.exec(t.slice(r,r+1));return n?(e.u=+n[0],r+n[0].length):-1}function P4(e,t,r){var n=Tt.exec(t.slice(r,r+2));return n?(e.U=+n[0],r+n[0].length):-1}function E4(e,t,r){var n=Tt.exec(t.slice(r,r+2));return n?(e.V=+n[0],r+n[0].length):-1}function j4(e,t,r){var n=Tt.exec(t.slice(r,r+2));return n?(e.W=+n[0],r+n[0].length):-1}function ij(e,t,r){var n=Tt.exec(t.slice(r,r+4));return n?(e.y=+n[0],r+n[0].length):-1}function aj(e,t,r){var n=Tt.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=Tt.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=Tt.exec(t.slice(r,r+2));return n?(e.m=n[0]-1,r+n[0].length):-1}function oj(e,t,r){var n=Tt.exec(t.slice(r,r+2));return n?(e.d=+n[0],r+n[0].length):-1}function k4(e,t,r){var n=Tt.exec(t.slice(r,r+3));return n?(e.m=0,e.d=+n[0],r+n[0].length):-1}function sj(e,t,r){var n=Tt.exec(t.slice(r,r+2));return n?(e.H=+n[0],r+n[0].length):-1}function N4(e,t,r){var n=Tt.exec(t.slice(r,r+2));return n?(e.M=+n[0],r+n[0].length):-1}function R4(e,t,r){var n=Tt.exec(t.slice(r,r+2));return n?(e.S=+n[0],r+n[0].length):-1}function $4(e,t,r){var n=Tt.exec(t.slice(r,r+3));return n?(e.L=+n[0],r+n[0].length):-1}function M4(e,t,r){var n=Tt.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=Tt.exec(t.slice(r));return n?(e.Q=+n[0],r+n[0].length):-1}function L4(e,t,r){var n=Tt.exec(t.slice(r));return n?(e.s=+n[0],r+n[0].length):-1}function uj(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+Mu.count(Tn(e),e),t,3)}function pN(e,t){return ze(e.getMilliseconds(),t,3)}function z4(e,t){return pN(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(Hf.count(Tn(e)-1,e),t,2)}function hN(e){var t=e.getDay();return t>=4||t===0?Ja(e):Ja.ceil(e)}function G4(e,t){return e=hN(e),ze(Ja.count(Tn(e),e)+(Tn(e).getDay()===4),t,2)}function X4(e){return e.getDay()}function Y4(e,t){return ze(Lc.count(Tn(e)-1,e),t,2)}function Q4(e,t){return ze(e.getFullYear()%100,t,2)}function Z4(e,t){return e=hN(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?Ja(e):Ja.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 lj(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+Wf.count(Cn(e),e),t,3)}function vN(e,t){return ze(e.getUTCMilliseconds(),t,3)}function a8(e,t){return vN(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(Kf.count(Cn(e)-1,e),t,2)}function mN(e){var t=e.getUTCDay();return t>=4||t===0?eo(e):eo.ceil(e)}function f8(e,t){return e=mN(e),ze(eo.count(Cn(e),e)+(Cn(e).getUTCDay()===4),t,2)}function d8(e){return e.getUTCDay()}function p8(e,t){return ze(Bc.count(Cn(e)-1,e),t,2)}function h8(e,t){return ze(e.getUTCFullYear()%100,t,2)}function v8(e,t){return e=mN(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?eo(e):eo.ceil(e),ze(e.getUTCFullYear()%1e4,t,4)}function g8(){return"+0000"}function cj(){return"%"}function fj(e){return+e}function dj(e){return Math.floor(+e/1e3)}var ka,yN,gN;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 ka=b4(e),yN=ka.format,ka.parse,gN=ka.utcFormat,ka.utcParse,ka}function x8(e){return new Date(e)}function w8(e){return e instanceof Date?+e:+new Date(+e)}function Zb(e,t,r,n,i,o,u,l,f,d){var v=Lb(),p=v.invert,m=v.domain,b=d(".%L"),O=d(":%S"),x=d("%I:%M"),g=d("%I %p"),E=d("%a %d"),j=d("%b %d"),A=d("%B"),T=d("%Y");function P(_){return(f(_)<_?b:l(_)<_?O:u(_)<_?x:o(_)<_?g:n(_)<_?i(_)<_?E:j:r(_)<_?A:T)(_)}return v.invert=function(_){return new Date(p(_))},v.domain=function(_){return arguments.length?m(Array.from(_,w8)):m().map(x8)},v.ticks=function(_){var N=m();return e(N[0],N[N.length-1],_??10)},v.tickFormat=function(_,N){return N==null?P:d(N)},v.nice=function(_){var N=m();return(!_||typeof _.range!="function")&&(_=t(N[0],N[N.length-1],_??10)),_?m(iN(N,_)):v},v.copy=function(){return $u(v,Zb(e,t,r,n,i,o,u,l,f,d))},v}function S8(){return _r.apply(Zb(y4,g4,Tn,Yb,Hf,Mu,Gb,Kb,Fi,yN).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}function O8(){return _r.apply(Zb(v4,m4,Cn,Qb,Kf,Wf,Xb,Vb,Fi,gN).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)]),arguments)}function Vf(){var e=0,t=1,r,n,i,o,u=Wt,l=!1,f;function d(p){return p==null||isNaN(p=+p)?f:u(i===0?.5:(p=(o(p)-r)*i,l?Math.max(0,Math.min(1,p)):p))}d.domain=function(p){return arguments.length?([e,t]=p,r=o(e=+e),n=o(t=+t),i=r===n?0:1/(n-r),d):[e,t]},d.clamp=function(p){return arguments.length?(l=!!p,d):l},d.interpolator=function(p){return arguments.length?(u=p,d):u};function v(p){return function(m){var b,O;return arguments.length?([b,O]=m,u=p(b,O),d):[u(0),u(1)]}}return d.range=v(Eo),d.rangeRound=v(Db),d.unknown=function(p){return arguments.length?(f=p,d):f},function(p){return o=p,r=p(e),n=p(t),i=r===n?0:1/(n-r),d}}function vi(e,t){return t.domain(e.domain()).interpolator(e.interpolator()).clamp(e.clamp()).unknown(e.unknown())}function bN(){var e=hi(Vf()(Wt));return e.copy=function(){return vi(e,bN())},Dn.apply(e,arguments)}function xN(){var e=qb(Vf()).domain([1,10]);return e.copy=function(){return vi(e,xN()).base(e.base())},Dn.apply(e,arguments)}function wN(){var e=zb(Vf());return e.copy=function(){return vi(e,wN()).constant(e.constant())},Dn.apply(e,arguments)}function Jb(){var e=Ub(Vf());return e.copy=function(){return vi(e,Jb()).exponent(e.exponent())},Dn.apply(e,arguments)}function _8(){return Jb.apply(null,arguments).exponent(.5)}function SN(){var e=[],t=Wt;function r(n){if(n!=null&&!isNaN(n=+n))return t((Nu(e,n,1)-1)/(e.length-1))}return r.domain=function(n){if(!arguments.length)return e.slice();e=[];for(let i of n)i!=null&&!isNaN(i=+i)&&e.push(i);return e.sort(li),r},r.interpolator=function(n){return arguments.length?(t=n,r):t},r.range=function(){return e.map((n,i)=>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 SN(t).domain(e)},Dn.apply(r,arguments)}function Gf(){var e=0,t=.5,r=1,n=1,i,o,u,l,f,d=Wt,v,p=!1,m;function b(x){return isNaN(x=+x)?m:(x=.5+((x=+v(x))-o)*(n*xr}return $y=e,$y}var My,mj;function E8(){if(mj)return My;mj=1;var e=Xf(),t=EN(),r=Po();function n(i){return i&&i.length?e(i,r,t):void 0}return My=n,My}var j8=E8();const Yf=Ue(j8);var Iy,yj;function jN(){if(yj)return Iy;yj=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 En(this,new this.constructor(e))};pe.dividedToIntegerBy=pe.idiv=function(e){var t=this,r=t.constructor;return Ge(En(t,new r(e),0,1),r.precision)};pe.equals=pe.eq=function(e){return!this.cmp(e)};pe.exponent=function(){return mt(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(Or+"NaN");if(r.s<1)throw Error(Or+(r.s?"NaN":"-Infinity"));return r.eq(ur)?new n(0):(it=!1,t=En(tu(r,o),tu(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?kN(t,e):TN(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(Or+"NaN");return r.s?(it=!1,t=En(r,e,0,1).times(e),it=!0,r.minus(t)):Ge(new n(r),i)};pe.naturalExponential=pe.exp=function(){return CN(this)};pe.naturalLogarithm=pe.ln=function(){return tu(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?TN(t,e):kN(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(Ui+e);if(t=mt(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(Or+"NaN")}for(e=mt(l),it=!1,i=Math.sqrt(+l),i==0||i==1/0?(t=Zr(l.d),(t.length+e)%2==0&&(t+="0"),i=Math.sqrt(t),e=Ao((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(En(l,o,u+2)).times(.5),Zr(o.d).slice(0,u)===(t=Zr(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%jt|0,t=l/jt|0;o[i]=(o[i]+t)%jt|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:(tn(e,0,jo),t===void 0?t=n.rounding:tn(t,0,8),Ge(r,e+mt(r)+1,t))};pe.toExponential=function(e,t){var r,n=this,i=n.constructor;return e===void 0?r=Vi(n,!0):(tn(e,0,jo),t===void 0?t=i.rounding:tn(t,0,8),n=Ge(new i(n),e+1,t),r=Vi(n,!0,e+1)),r};pe.toFixed=function(e,t){var r,n,i=this,o=i.constructor;return e===void 0?Vi(i):(tn(e,0,jo),t===void 0?t=o.rounding:tn(t,0,8),n=Ge(new o(i),e+mt(i)+1,t),r=Vi(n.abs(),!1,e+mt(n)+1),i.isneg()&&!i.isZero()?"-"+r:r)};pe.toInteger=pe.toint=function(){var e=this,t=e.constructor;return Ge(new t(e),mt(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(Or+"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)<=AN){for(i=new f(ur),t=Math.ceil(n/rt+4),it=!1;r%2&&(i=i.times(l),Oj(i.d,t)),r=Ao(r/2),r!==0;)l=l.times(l),Oj(l.d,t);return it=!0,e.s<0?new f(ur).div(i):Ge(i,n)}}else if(o<0)throw Error(Or+"NaN");return o=o<0&&e.d[Math.max(t,r)]&1?-1:1,l.s=1,it=!1,i=e.times(tu(l,n+d)),it=!0,i=CN(i),i.s=o,i};pe.toPrecision=function(e,t){var r,n,i=this,o=i.constructor;return e===void 0?(r=mt(i),n=Vi(i,r<=o.toExpNeg||r>=o.toExpPos)):(tn(e,1,jo),t===void 0?t=o.rounding:tn(t,0,8),i=Ge(new o(i),e,t),r=mt(i),n=Vi(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):(tn(e,1,jo),t===void 0?t=n.rounding:tn(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=mt(e),r=e.constructor;return Vi(e,t<=r.toExpNeg||t>=r.toExpPos)};function TN(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)/jt|0,f[o]%=jt;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 tn(e,t,r){if(e!==~~e||er)throw Error(Ui+e)}function Zr(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,j,A,T,P,_,N,R,I=n.constructor,U=n.s==i.s?1:-1,B=n.d,$=i.d;if(!n.s)return new I(n);if(!i.s)throw Error(Or+"Division by zero");for(f=n.e-i.e,N=$.length,P=B.length,b=new I(U),O=b.d=[],d=0;$[d]==(B[d]||0);)++d;if($[d]>(B[d]||0)&&--f,o==null?j=o=I.precision:u?j=o+(mt(n)-mt(i))+1:j=o,j<0)return new I(0);if(j=j/rt+2|0,d=0,N==1)for(v=0,$=$[0],j++;(d1&&($=e($,v),B=e(B,v),N=$.length,P=B.length),T=N,x=B.slice(0,N),g=x.length;g=jt/2&&++_;do v=0,l=t($,x,N,g),l<0?(E=x[0],N!=g&&(E=E*jt+(x[1]||0)),v=E/_|0,v>1?(v>=jt&&(v=jt-1),p=e($,v),m=p.length,g=x.length,l=t(p,x,m,g),l==1&&(v--,r(p,N16)throw Error(tx+mt(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(Ii(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(En(i,r,l)),Zr(u.d).slice(0,l)===Zr(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 mt(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(Or+"LN10 precision limit exceeded");return Ge(new e(e.LN10),t)}function ii(e){for(var t="";e--;)t+="0";return t}function tu(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(Or+(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=Zr(O),n=r.charAt(0),o=mt(b),Math.abs(o)<15e14){for(;n<7&&n!=1||n==1&&r.charAt(1)>3;)b=b.times(e),r=Zr(b.d),n=r.charAt(0),p++;o=mt(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=tu(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=En(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(En(u,new x(i),d)),Zr(f.d).slice(0,d)===Zr(l.d).slice(0,d))return l=l.times(2),o!==0&&(l=l.plus(qy(x,d+2,g).times(o+""))),l=En(l,new x(p),d),x.precision=g,t==null?(it=!0,Ge(l,g)):l;l=f,i+=2}}function Sj(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=Ao(r/rt),e.d=[],n=(r+1)%rt,r<0&&(n+=rt),nFc||e.e<-Fc))throw Error(tx+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=Ii(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/Ii(10,u-i):0:p[v-1])%10&1||r==(e.s<0?8:7))),t<1||!p[0])return f?(o=mt(e),p.length=1,t=t-o-1,p[0]=Ii(10,(rt-t%rt)%rt),e.e=Ao(-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=Ii(10,rt-n),p[v]=i>0?(d/Ii(10,u-i)%Ii(10,i)|0)*o:0),f)for(;;)if(v==0){(p[0]+=o)==jt&&(p[0]=1,++e.e);break}else{if(p[v]+=o,p[v]!=jt)break;p[v--]=0,o=1}for(n=p.length;p[--n]===0;)p.pop();if(it&&(e.e>Fc||e.e<-Fc))throw Error(tx+mt(e));return e}function kN(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)+ii(n):u>1&&(o=o.charAt(0)+"."+o.slice(1)),o=o+(i<0?"e":"e+")+i):i<0?(o="0."+ii(-i-1)+o,r&&(n=r-u)>0&&(o+=ii(n))):i>=u?(o+=ii(i+1-u),r&&(n=r-i-1)>0&&(o=o+"."+ii(n))):((n=i+1)0&&(i+1===u&&(o+="."),o+=ii(n))),e.s<0?"-"+o:o}function Oj(e,t){if(e.length>t)return e.length=t,!0}function NN(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(Ui+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 Sj(u,o.toString())}else if(typeof o!="string")throw Error(Ui+o);if(o.charCodeAt(0)===45?(o=o.slice(1),u.s=-1):u.s=1,D8.test(o))Sj(u,o);else throw Error(Ui+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=NN,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(Ui+r+": "+n);if((n=e[r="LN10"])!==void 0)if(n==Math.LN10)this[r]=new this(n);else throw Error(Ui+r+": "+n);return this}var rx=NN(I8);ur=new rx(1);const Ve=rx;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,_j(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 DN(e){var t=ru(e,2),r=t[0],n=t[1],i=r,o=n;return r>n&&(i=n,o=r),[i,o]}function LN(e,t,r){if(e.lte(0))return new Ve(0);var n=Jf.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(Jf.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 BN(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=LN(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?BN(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=ru(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=DN([r,n]),f=ru(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=BN(d,v,u,o),b=m.step,O=m.tickMin,x=m.tickMax,g=Jf.rangeStep(O,x.add(new Ve(.1).mul(b)),b);return r>n?a0(g):g}function s6(e,t){var r=ru(e,2),n=r[0],i=r[1],o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,u=DN([n,i]),l=ru(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=LN(new Ve(d).sub(f).div(v-1),o,0),m=[].concat(o0(Jf.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 Gi(e,t){throw new Error(c6)}var f6=["offset","layout","width","dataKey","data","dataPointFormatter","xAxis","yAxis"];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 qc(){return qc=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(zt(p-v)!==zt(m-p)){var O=[];if(zt(m-p)===zt(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 j=Math.min(v,m),A=Math.max(v,m);if(t>(j+p)/2&&t<=(A+p)/2){u=i[d].index;break}}}else for(var T=0;T0&&T(n[T].coordinate+n[T-1].coordinate)/2&&t<=(n[T].coordinate+n[T+1].coordinate)/2||T===l-1&&t>(n[T].coordinate+n[T-1].coordinate)/2){u=n[T].index;break}return u},nx=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 j=E[0].type.defaultProps,A=j!==void 0?lt(lt({},j),E[0].props):E[0].props,T=A.barSize,P=A[g];u[P]||(u[P]=[]);var _=ke(T)?r:T;u[P].push({item:E[0],stackList:E.slice(1),barSize:ke(_)?void 0:Ut(_,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=Ut(r,i,0,!0),v,p=[];if(u[0].barSize===+u[0].barSize){var m=!1,b=i/f,O=u.reduce(function(T,P){return T+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(T,P){var _={item:P.item,position:{offset:g.offset+g.size+d,size:m?b:P.barSize}},N=[].concat(jj(T),[_]);return g=N[N.length-1].position,P.stackList&&P.stackList.length&&P.stackList.forEach(function(R){N.push({item:R,position:g})}),N},p)}else{var E=Ut(n,i,0,!0);i-2*E-(f-1)*d<=0&&(d=0);var j=(i-2*E-(f-1)*d)/f;j>1&&(j>>=0);var A=l===+l?Math.min(j,l):j;v=u.reduce(function(T,P,_){var N=[].concat(jj(T),[{item:P.item,position:{offset:E+(j+d)*_+(j-A)/2,size:A}}]);return P.stackList&&P.stackList.length&&P.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=UN({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),{},Ha({},b,t[b]+(p||0)));if((x==="horizontal"||x==="vertical"&&b==="center")&&O!=="middle"&&le(t[O]))return lt(lt({},t),{},Ha({},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},WN=function(t,r,n,i,o){var u=r.props.children,l=cr(u,Du).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=wt(v,n);if(ke(p))return d;var m=Array.isArray(p)?[Qf(p),Yf(p)]:[p,p],b=f.reduce(function(O,x){var g=wt(v,x,0),E=m[0]-Math.abs(Array.isArray(g)?g[0]:g),j=m[1]+Math.abs(Array.isArray(g)?g[1]:g);return[Math.min(E,O[0]),Math.max(j,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 WN(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},HN=function(t,r,n,i,o){var u=r.map(function(f){var d=f.props.dataKey;return n==="number"&&d&&WN(t,f,d,i)||Rs(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?zt(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!Tu(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,oc=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},GN=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:Ys(),realScaleType:"band"}:u==="radial"&&l==="angleAxis"?{scale:Ic(),realScaleType:"linear"}:o==="category"&&r&&(r.indexOf("LineChart")>=0||r.indexOf("AreaChart")>=0||r.indexOf("ComposedChart")>=0&&!n)?{scale:Ns(),realScaleType:"point"}:o==="category"?{scale:Ys(),realScaleType:"band"}:{scale:Ic(),realScaleType:"linear"};if(Wi(i)){var f="scale".concat(If(i));return{scale:(pj[f]||Ns)(),realScaleType:pj[f]?f:"point"}}return je(i)?{scale:i}:{scale:Ns(),realScaleType:"point"}},Tj=1e-4,XN=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])-Tj,u=Math.max(i[0],i[1])+Tj,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:R3,none:Va,silhouette:$3,wiggle:M3,positive:H6},V6=function(t,r,n){var i=r.map(function(l){return l.props.dataKey}),o=K6[n],u=N3().keys(i).value(function(l,f){return+wt(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],j=p[E]||{hasStack:!1,stackGroups:{}};if(St(x)){var A=j.stackGroups[x]||{numericAxisId:n,cateAxisId:i,items:[]};A.items.push(m),j.hasStack=!0,j.stackGroups[x]=A}else j.stackGroups[_o("_stackId_")]={numericAxisId:n,cateAxisId:i,items:[m]};return lt(lt({},p),{},Ha({},E,j))},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),{},Ha({},g,{numericAxisId:n,cateAxisId:i,items:E.items,stackedData:V6(t,E.items,o)}))},O)}return lt(lt({},p),{},Ha({},m,b))},v)},YN=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([Qf(v),Yf(v)]),{niceTicks:v}}if(o&&i==="number"){var p=t.domain(),m=l6(p,o,l);return{niceTicks:m}}return null};function Cj(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=yc(r,"value",i[t.dataKey]);if(l)return l.coordinate+n/2}return r[o]?r[o].coordinate+n/2:null}var f=wt(i,ke(u)?t.dataKey:u);return ke(f)?null:t.scale(f)}var kj=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=wt(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(St(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[Qf(n.concat([r[0]]).filter(le)),Yf(n.concat([r[1]]).filter(le))]},[1/0,-1/0])},QN=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})},Nj=/^dataMin[\s]*-[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,Rj=/^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(Nj.test(t[0])){var o=+Nj.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(Rj.test(t[1])){var u=+Rj.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},Uc=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=kb(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=Ut(t.cx,u,u/2),p=Ut(t.cy,l,l/2),m=eR(u,l,n),b=Ut(t.innerRadius,m,0),O=Ut(t.outerRadius,m,m*.8),x=Object.keys(r);return x.reduce(function(g,E){var j=r[E],A=j.domain,T=j.reversed,P;if(ke(j.range))i==="angleAxis"?P=[f,d]:i==="radiusAxis"&&(P=[b,O]),T&&(P=[P[1],P[0]]);else{P=j.range;var _=P,N=e5(_,2);f=N[0],d=N[1]}var R=GN(j,o),I=R.realScaleType,U=R.scale;U.domain(A).range(P),XN(U);var B=YN(U,yn(yn({},j),{},{realScaleType:I})),$=yn(yn(yn({},j),B),{},{range:P,radius:O,realScaleType:I,scale:U,cx:v,cy:p,innerRadius:b,outerRadius:O,startAngle:f,endAngle:d});return yn(yn({},g),{},JN({},E,$))},{})},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},Dj=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?yn(yn({},r),{},{radius:u,angle:c5(b,r)}):null},tR=function(t){return!C.isValidElement(t)&&!je(t)&&typeof t!="boolean"?t.className:""};function ou(e){"@babel/helpers - typeof";return ou=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},ou(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 Lj(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 xt(e){for(var t=1;t=0?1:-1,A,T;i==="insideStart"?(A=b+j*u,T=x):i==="insideEnd"?(A=O-j*u,T=!x):i==="end"&&(A=O+j*u,T=x),T=E<=0?T:!T;var P=Ze(d,v,g,A),_=Ze(d,v,g,A+(T?1:-1)*359),N="M".concat(P.x,",").concat(P.y,` A`).concat(g,",").concat(g,",0,1,").concat(T?0:1,`, `).concat(_.x,",").concat(_.y),R=ke(t.id)?_o("recharts-radial-line-"):t.id;return D.createElement("text",su({},n,{dominantBaseline:"central",className:$e("recharts-radial-bar-label",l)}),D.createElement("defs",null,D.createElement("path",{id:R,d:N})),D.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),j=E.x,A=E.y;return{x:j,y:A,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",j=x>0?"start":"end";if(o==="top"){var A={x:l+d/2,y:f-p*i,textAnchor:"middle",verticalAnchor:b};return xt(xt({},A),n?{height:Math.max(f-n.y,0),width:d}:{})}if(o==="bottom"){var T={x:l+d/2,y:f+v+m,textAnchor:"middle",verticalAnchor:O};return xt(xt({},T),n?{height:Math.max(n.y+n.height-(f+v),0),width:d}:{})}if(o==="left"){var P={x:l-g,y:f+v/2,textAnchor:E,verticalAnchor:"middle"};return xt(xt({},P),n?{width:Math.max(P.x-n.x,0),height:v}:{})}if(o==="right"){var _={x:l+d+g,y:f+v/2,textAnchor:j,verticalAnchor:"middle"};return xt(xt({},_),n?{width:Math.max(n.x+n.width-_.x,0),height:v}:{})}var N=n?{width:d,height:v}:{};return o==="insideLeft"?xt({x:l+g,y:f+v/2,textAnchor:j,verticalAnchor:"middle"},N):o==="insideRight"?xt({x:l+d-g,y:f+v/2,textAnchor:E,verticalAnchor:"middle"},N):o==="insideTop"?xt({x:l+d/2,y:f+m,textAnchor:"middle",verticalAnchor:O},N):o==="insideBottom"?xt({x:l+d/2,y:f+v-m,textAnchor:"middle",verticalAnchor:b},N):o==="insideTopLeft"?xt({x:l+g,y:f+m,textAnchor:j,verticalAnchor:O},N):o==="insideTopRight"?xt({x:l+d-g,y:f+m,textAnchor:E,verticalAnchor:O},N):o==="insideBottomLeft"?xt({x:l+g,y:f+v-m,textAnchor:j,verticalAnchor:b},N):o==="insideBottomRight"?xt({x:l+d-g,y:f+v-m,textAnchor:E,verticalAnchor:b},N):Oo(o)&&(le(o.x)||Li(o.x))&&(le(o.y)||Li(o.y))?xt({x:l+Ut(o.x,d),y:f+Ut(o.y,v),textAnchor:"end",verticalAnchor:"end"},N):xt({x:l+d/2,y:f+v/2,textAnchor:"middle",verticalAnchor:"middle"},N)},j5=function(t){return"cx"in t&&le(t.cx)};function At(e){var t=e.offset,r=t===void 0?5:t,n=y5(e,f5),i=xt({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 D.createElement(Ki,su({className:$e("recharts-label",p)},x,g,{breakAll:m}),b)}At.displayName="Label";var rR=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,j=t.labelViewBox;if(j)return j;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?D.createElement(At,{key:"label-implicit",viewBox:r}):St(t)?D.createElement(At,{key:"label-implicit",viewBox:r,value:t}):C.isValidElement(t)?t.type===At?C.cloneElement(t,{key:"label-implicit",viewBox:r}):D.createElement(At,{key:"label-implicit",content:t,viewBox:r}):je(t)?D.createElement(At,{key:"label-implicit",content:t,viewBox:r}):Oo(t)?D.createElement(At,su({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=rR(t),u=cr(i,At).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))};At.parseViewBox=rR;At.renderCallByParent=T5;var Uy,Bj;function C5(){if(Bj)return Uy;Bj=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 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)}var R5=["valueAccessor"],$5=["data","dataKey","clockWise","id","textBreakAll"];function M5(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 jn(e){var t=e.valueAccessor,r=t===void 0?W5:t,n=zj(e,R5),i=n.data,o=n.dataKey,u=n.clockWise,l=n.id,f=n.textBreakAll,d=zj(n,$5);return!i||!i.length?null:D.createElement(qe,{className:"recharts-label-list"},i.map(function(v,p){var m=ke(o)?r(v,p):wt(v&&v.payload,o),b=ke(l)?{}:{id:"".concat(l,"-").concat(p)};return D.createElement(At,Hc({},Se(v,!0),d,b,{parentViewBox:v.parentViewBox,value:m,textBreakAll:f,viewBox:At.parseViewBox(ke(u)?v:qj(qj({},v),{},{clockWise:u})),key:"label-".concat(p),index:p}))}))}jn.displayName="LabelList";function H5(e,t){return e?e===!0?D.createElement(jn,{key:"labelList-implicit",data:t}):D.isValidElement(e)||je(e)?D.createElement(jn,{key:"labelList-implicit",data:t,content:e}):Oo(e)?D.createElement(jn,Hc({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,jn).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(M5(i))}jn.renderCallByParent=K5;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 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=zt(v-d),m=sc({cx:r,cy:n,radius:o,angle:d,sign:p,cornerRadius:u,cornerIsExternal:f}),b=m.circleTangency,O=m.lineTangency,x=m.theta,g=sc({cx:r,cy:n,radius:o,angle:v,sign:-p,cornerRadius:u,cornerIsExternal:f}),E=g.circleTangency,j=g.lineTangency,A=g.theta,T=f?Math.abs(d-v):Math.abs(d-v)-x-A;if(T<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 `):nR({cx:r,cy:n,innerRadius:i,outerRadius:o,startAngle:d,endAngle:v});var P="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(+(T>180),",").concat(+(p<0),",").concat(E.x,",").concat(E.y,` A`).concat(u,",").concat(u,",0,0,").concat(+(p<0),",").concat(j.x,",").concat(j.y,` `);if(i>0){var _=sc({cx:r,cy:n,radius:i,angle:d,sign:p,isExternal:!0,cornerRadius:u,cornerIsExternal:f}),N=_.circleTangency,R=_.lineTangency,I=_.theta,U=sc({cx:r,cy:n,radius:i,angle:v,sign:-p,isExternal:!0,cornerRadius:u,cornerIsExternal:f}),B=U.circleTangency,$=U.lineTangency,z=U.theta,G=f?Math.abs(d-v):Math.abs(d-v)-I-z;if(G<0&&u===0)return"".concat(P,"L").concat(r,",").concat(n,"Z");P+="L".concat($.x,",").concat($.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 P+="L".concat(r,",").concat(n,"Z");return P},Z5={cx:0,cy:0,innerRadius:0,outerRadius:0,startAngle:0,endAngle:0,cornerRadius:0,forceCornerRadius:!1,cornerIsExternal:!1},iR=function(t){var r=Wj(Wj({},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=nR({cx:n,cy:i,innerRadius:o,outerRadius:u,startAngle:v,endAngle:p}),D.createElement("path",p0({},Se(r,!0),{className:b,d:g,role:"img"}))};function cu(e){"@babel/helpers - typeof";return cu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},cu(e)}function h0(){return h0=Object.assign?Object.assign.bind():function(e){for(var t=1;toW.call(e,t));function ta(e,t){return e===t||!e&&!t&&e!==e&&t!==t}const lW="__v",cW="__o",fW="_owner",{getOwnPropertyDescriptor:Xj,keys:Yj}=Object;function dW(e,t){return e.byteLength===t.byteLength&&Vc(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&&Vc(new Uint8Array(e.buffer,e.byteOffset,e.byteLength),new Uint8Array(t.buffer,t.byteOffset,t.byteLength))}function vW(e,t){return ta(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 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.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=ta;function bW(e,t,r){const n=Yj(e);let i=n.length;if(Yj(t).length!==i)return!1;for(;i-- >0;)if(!aR(e,t,r,n[i]))return!1;return!0}function Ps(e,t,r){const n=Gj(e);let i=n.length;if(Gj(t).length!==i)return!1;let o,u,l;for(;i-- >0;)if(o=n[i],!aR(e,t,r,o)||(u=Xj(e,o),l=Xj(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 ta(e.valueOf(),t.valueOf())}function wW(e,t){return e.source===t.source&&e.flags===t.flags}function Zj(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 Vc(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 aR(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]",$W="[object String]",MW={"[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,j){if(g===E)return!0;if(g==null||E==null)return!1;const A=typeof g;if(A!==typeof E)return!1;if(A!=="object")return A==="number"?l(g,E,j):A==="function"?o(g,E,j):!1;const T=g.constructor;if(T!==E.constructor)return!1;if(T===Object)return f(g,E,j);if(Array.isArray(g))return t(g,E,j);if(T===Date)return n(g,E,j);if(T===RegExp)return v(g,E,j);if(T===Map)return u(g,E,j);if(T===Set)return p(g,E,j);const P=DW.call(g);if(P===jW)return n(g,E,j);if(P===NW)return v(g,E,j);if(P===TW)return u(g,E,j);if(P===RW)return p(g,E,j);if(P===kW)return typeof g.then!="function"&&typeof E.then!="function"&&f(g,E,j);if(P===IW)return b(g,E,j);if(P===AW)return i(g,E,j);if(P===_W)return f(g,E,j);if(MW[P])return m(g,E,j);if(P===OW)return e(g,E,j);if(P===EW)return r(g,E,j);if(P===PW||P===CW||P===$W)return d(g,E,j);if(O){let _=O[P];if(!_){const N=sW(g);N&&(_=O[N])}if(_)return _(g,E,j)}return!1}}function BW({circular:e,createCustomConfig:t,strict:r}){let n={areArrayBuffersEqual:dW,areArraysEqual:r?Ps:pW,areDataViewsEqual:hW,areDatesEqual:vW,areErrorsEqual:mW,areFunctionsEqual:yW,areMapsEqual:r?Wy(Qj,Ps):Qj,areNumbersEqual:gW,areObjectsEqual:r?Ps:bW,arePrimitiveWrappersEqual:xW,areRegExpsEqual:wW,areSetsEqual:r?Wy(Zj,Ps):Zj,areTypedArraysEqual:r?Wy(Vc,Ps):Vc,areUrlsEqual:SW,unknownTagComparators:void 0};if(t&&(n=Object.assign({},n,t(n))),e){const i=lc(n.areArraysEqual),o=lc(n.areMapsEqual),u=lc(n.areObjectsEqual),l=lc(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=mi();mi({strict:!0});mi({circular:!0});mi({circular:!0,strict:!0});mi({createInternalComparator:()=>ta});mi({strict:!0,createInternalComparator:()=>ta});mi({circular:!0,createInternalComparator:()=>ta});mi({circular:!0,createInternalComparator:()=>ta,strict:!0});function mi(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 Jj(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 eA(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 eA(e,t)}}function eA(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 j=E>1?1:E,A=j,T=0;T<8;++T){var P=p(A)-j,_=b(A);if(Math.abs(P-j)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 Yc(e){return Yc=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Yc(e)}var rn=(function(e){$H(r,e);var t=MH(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?Cs({},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?Cs({},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?Cs({},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 j=g.duration,A=g.easing,T=A===void 0?"ease":A,P=g.style,_=g.properties,N=g.onAnimationEnd,R=E>0?u[E-1]:g,I=_||Object.keys(P);if(typeof T=="function"||T==="spring")return[].concat(Hy(x),[o.runJSAnimation.bind(o,{from:R.style,to:P,duration:j,easing:T}),j]);var U=nA(I,j,T),B=$r($r($r({},R.style),P),{},{transition:U});return[].concat(Hy(x),[B,j,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?Cs({},l,f):f,g=nA(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,j=C.cloneElement(b,$r($r({},f),{},{style:$r($r({},g),v),className:E}));return j};return d===1?p(C.Children.only(o)):D.createElement("div",null,C.Children.map(o,function(m){return p(m)}))}}]),r})(C.PureComponent);rn.displayName="Animate";rn.defaultProps={begin:0,duration:1e3,from:"",to:"",attributeName:"",easing:"ease",isActive:!0,canBegin:!0,steps:[],onAnimationEnd:function(){},onAnimationStart:function(){}};rn.propTypes={from:Me.oneOfType([Me.object,Me.string]),to:Me.oneOfType([Me.object,Me.string]),attributeName:Me.string,duration:Me.number,begin:Me.number,easing:Me.oneOfType([Me.string,Me.func]),steps:Me.arrayOf(Me.shape({duration:Me.number.isRequired,style:Me.object.isRequired,easing:Me.oneOfType([Me.oneOf(["ease","ease-in","ease-out","ease-in-out","linear"]),Me.func]),properties:Me.arrayOf("string"),onAnimationEnd:Me.func})),children:Me.oneOfType([Me.node,Me.func]),isActive:Me.bool,canBegin:Me.bool,onAnimationEnd:Me.func,shouldReAnimate:Me.bool,onAnimationStart:Me.func,onAnimationReStart:Me.func};function pu(e){"@babel/helpers - typeof";return pu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},pu(e)}function Qc(){return Qc=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"},ix=function(t){var r=fA(fA({},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 T=n.current.getTotalLength();T&&l(T)}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,j=r.isUpdateAnimationActive;if(f!==+f||d!==+d||v!==+v||p!==+p||v===0||p===0)return null;var A=$e("recharts-rectangle",b);return j?D.createElement(rn,{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:j},function(T){var P=T.width,_=T.height,N=T.x,R=T.y;return D.createElement(rn,{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},D.createElement("path",Qc({},Se(r,!0),{className:A,d:dA(N,R,P,_,m),ref:n})))}):D.createElement("path",Qc({},Se(r,!0),{className:A,d:dA(f,d,v,p,m)}))},VH=["points","className","baseLinePoints","connectNulls"];function Da(){return Da=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 pA(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){hA(n)?r[r.length-1].push(n):r[r.length-1].length>0&&r.push([])}),hA(t[0])&&r[r.length-1].push(t[0]),r[r.length-1].length<=0&&(r=r.slice(0,-1)),r},Ms=function(t,r){var n=eK(t);r&&(n=[n.reduce(function(o,u){return[].concat(pA(o),pA(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=Ms(t,n);return"".concat(i.slice(-1)==="Z"?i.slice(0,-1):i,"L").concat(Ms(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=$e("recharts-polygon",n);if(i&&i.length){var f=u.stroke&&u.stroke!=="none",d=tK(r,i,o);return D.createElement("g",{className:l},D.createElement("path",Da({},Se(u,!0),{fill:d.slice(-1)==="Z"?u.fill:"none",stroke:"none",d})),f?D.createElement("path",Da({},Se(u,!0),{fill:"none",d:Ms(r,o)})):null,f?D.createElement("path",Da({},Se(u,!0),{fill:"none",d:Ms(i,o)})):null)}var v=Ms(r,o);return D.createElement("path",Da({},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:D.createElement("path",E0({},Se(g,!0),{className:$e("recharts-cross",O),d:cK(n,o,p,b,l,d)}))},Ky,mA;function dK(){if(mA)return Ky;mA=1;var e=Xf(),t=EN(),r=on();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,yA;function vK(){if(yA)return Vy;yA=1;var e=Xf(),t=on(),r=jN();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 no(e){"@babel/helpers - typeof";return no=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},no(e)}function Is(){return Is=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 xA(e,t){for(var r=0;rOA?u=i==="outer"?"start":"end":o<-OA?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=Ni(Ni({},Se(this.props,!1)),{},{fill:"none"},Se(l,!1));if(f==="circle")return D.createElement(ed,Di({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 D.createElement(rK,Di({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=Ni(Ni({},v),{},{fill:"none"},Se(l,!1)),b=o.map(function(O,x){var g=n.getTickLineCoord(O),E=n.getTickTextAnchor(O),j=Ni(Ni(Ni({textAnchor:E},v),{},{stroke:"none",fill:d},p),{},{index:x,payload:O,x:g.x2,y:g.y2});return D.createElement(qe,Di({className:$e("recharts-polar-angle-axis-tick",tR(u)),key:"tick-".concat(O.coordinate)},Hi(n.props,O,x)),l&&D.createElement("line",Di({className:"recharts-polar-angle-axis-tick-line"},m,g)),u&&t.renderTickItem(u,j,f?f(O.value,x):O.value))});return D.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:D.createElement(qe,{className:$e("recharts-polar-angle-axis",this.props.className)},u&&this.renderAxisLine(),this.renderTicks())}}],[{key:"renderTickItem",value:function(n,i,o){var u;return D.isValidElement(n)?u=D.cloneElement(n,i):je(n)?u=n(i):u=D.createElement(Ki,Di({},i,{className:"recharts-polar-angle-axis-tick-value"}),o),u}}])})(C.PureComponent);nd(id,"displayName","PolarAngleAxis");nd(id,"axisType","angleAxis");nd(id,"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,_A;function IK(){if(_A)return Gy;_A=1;var e=Ek(),t=e(Object.getPrototypeOf,Object);return Gy=t,Gy}var Xy,PA;function DK(){if(PA)return Xy;PA=1;var e=Mn(),t=IK(),r=In(),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,EA;function FK(){if(EA)return Yy;EA=1;var e=Mn(),t=In(),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 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 ef(){return ef=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(A){var T=A.upperWidth,P=A.lowerWidth,_=A.height,N=A.x,R=A.y;return D.createElement(rn,{canBegin:u>0,from:"0px ".concat(u===-1?1:u,"px"),to:"".concat(u,"px 0px"),attributeName:"strokeDasharray",begin:g,duration:x,easing:O},D.createElement("path",ef({},Se(r,!0),{className:j,d:CA(N,R,T,P,_),ref:n})))}):D.createElement("g",null,D.createElement("path",ef({},Se(r,!0),{className:j,d:CA(f,d,v,p,m)})))},JK=["option","shapeType","propTransformer","activeClassName","isActive"];function mu(e){"@babel/helpers - typeof";return mu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},mu(e)}function 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 kA(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 tf(e){for(var t=1;t0?lr(A,"paddingAngle",0):0;if(P){var N=sr(P.endAngle-P.startAngle,A.endAngle-A.startAngle),R=Ye(Ye({},A),{},{startAngle:j+_,endAngle:j+N(x)+_});g.push(R),j=R.endAngle}else{var I=A.endAngle,U=A.startAngle,B=sr(0,I-U),$=B(x),z=Ye(Ye({},A),{},{startAngle:j+_,endAngle:j+$+_});g.push(z),j=z.endAngle}}),D.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||!Iu(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=$e("recharts-pie",l);return D.createElement(qe,{tabIndex:this.props.rootTabIndex,className:x,ref:function(E){n.pieRef=E}},this.renderSectors(),f&&this.renderLabels(u),At.renderCallByParent(this.props,null,!1),(!b||O)&&jn.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?j:j-1)*f,T=g-j*b-A,P=i.reduce(function(R,I){var U=wt(I,E,0);return R+(le(U)?U:0)},0),_;if(P>0){var N;_=i.map(function(R,I){var U=wt(R,E,0),B=wt(R,v,I),$=(le(U)?U:0)/P,z;I?z=N.endAngle+zt(x)*f*(U!==0?1:0):z=u;var G=z+zt(x)*((U!==0?b:0)+$*T),V=(z+G)/2,Y=(O.innerRadius+O.outerRadius)/2,J=[{name:B,value:U,payload:R,dataKey:E,type:m}],H=Ze(O.cx,O.cy,Y,V);return N=Ye(Ye(Ye({percent:$,cornerRadius:o,name:B,tooltipPayload:J,midAngle:V,middleRadius:Y,tooltipPosition:H},R),O),{},{value:wt(R,E),startAngle:z,endAngle:G,payload:R,paddingAngle:zt(x)*f}),N})}return Ye(Ye({},O),{},{sectors:_,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,IA;function bR(){if(IA)return Zy;IA=1;var e=zk(),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,DA;function O9(){if(DA)return Jy;DA=1;var e=S9(),t=zf(),r=bR();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=UA(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 M9(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=wt(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=UA(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},j=n.pageX-o;j>0?j=Math.min(j,p+m-b-d):j<0&&(j=Math.max(j,p-d)),E[u]=d+j;var A=this.getIndex(E),T=A.startIndex,P=A.endIndex,_=function(){var R=g.length-1;return u==="startX"&&(l>f?T%x===0:P%x===0)||lf?P%x===0:T%x===0)||l>f&&P===R};this.setState(ar(ar({},u,d+j),"brushMoveStartX",n.pageX),function(){O&&_()&&O(A)})}},{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 D.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?D.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),j=tg(tg({},Se(this.props,!1)),{},{x:E,y:d,width:v,height:p}),A=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 D.createElement(qe,{tabIndex:0,role:"slider","aria-label":A,"aria-valuenow":n,className:"recharts-brush-traveller",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.travellerDragStartHandlers[i],onTouchStart:this.travellerDragStartHandlers[i],onKeyDown:function(P){["ArrowLeft","ArrowRight"].includes(P.key)&&(P.preventDefault(),P.stopPropagation(),l.handleTravellerMoveKeyboard(P.key==="ArrowRight"?1:-1,i))},onFocus:function(){l.setState({isTravellerFocused:!0})},onBlur:function(){l.setState({isTravellerFocused:!1})},style:{cursor:"col-resize"}},t.renderTraveller(m,j))}},{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 D.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 D.createElement(qe,{className:"recharts-brush-texts"},D.createElement(Ki,af({textAnchor:"end",verticalAnchor:"middle",x:Math.min(p,m)-b,y:u+l/2},O),this.getTextOfTick(i)),D.createElement(Ki,af({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,j=m.isTravellerFocused;if(!i||!i.length||!le(l)||!le(f)||!le(d)||!le(v)||d<=0||v<=0)return null;var A=$e("recharts-brush",o),T=D.Children.count(u)===1,P=T9("userSelect","none");return D.createElement(qe,{className:A,onMouseLeave:this.handleLeaveWrapper,onTouchMove:this.handleTouchMove,style:P},this.renderBackground(),T&&this.renderPanorama(),this.renderSlide(b,O),this.renderTravellerLayer(b,"startX"),this.renderTravellerLayer(O,"endX"),(x||g||E||j||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 D.createElement(D.Fragment,null,D.createElement("rect",{x:i,y:o,width:u,height:l,fill:f,stroke:"none"}),D.createElement("line",{x1:i+1,y1:d,x2:i+u-1,y2:d,fill:"none",stroke:"#fff"}),D.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 D.isValidElement(n)?o=D.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(so,"displayName","Brush");ar(so,"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,WA;function L9(){if(WA)return rg;WA=1;var e=Cb();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,HA;function B9(){if(HA)return ng;HA=1;var e=bk(),t=on(),r=L9(),n=Jt(),i=zf();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 en=function(t,r){var n=t.alwaysShow,i=t.ifOverflow;return n&&(i="extendDomain"),i===r},ig,KA;function z9(){if(KA)return ig;KA=1;var e=Dk();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,VA;function U9(){if(VA)return ag;VA=1;var e=z9(),t=Mk(),r=on();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,GA;function K9(){if(GA)return og;GA=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 Es(Es(Es(Es(Es({},t),i),u?{x:u}:{}),f?{y:f}:{}),{},{height:v,width:m,name:t.name,radius:t.radius})}function ZA(e){return D.createElement(mR,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||Gi(),r)}},iV=["value","background"],_R;function uo(e){"@babel/helpers - typeof";return uo=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},uo(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 sf(){return sf=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/$,Y=x.layout==="vertical"?n.height:n.width;if(x.padding==="gap"&&(N=V*Y/2),x.padding==="no-gap"){var J=Ut(t.barCategoryGap,V*Y),H=V*Y/2;N=H-J-(H-J)/Y*J}}}i==="xAxis"?R=[n.left+(A.left||0)+(N||0),n.left+n.width-(A.right||0)-(N||0)]:i==="yAxis"?R=f==="horizontal"?[n.top+n.height-(A.bottom||0),n.top+(A.top||0)]:[n.top+(A.top||0)+(N||0),n.top+n.height-(A.bottom||0)-(N||0)]:R=x.range,P&&(R=[R[1],R[0]]);var ee=GN(x,o,m),Z=ee.scale,L=ee.realScaleType;Z.domain(E).range(R),XN(Z);var W=YN(Z,Dr(Dr({},x),{},{realScaleType:L}));i==="xAxis"?(B=g==="top"&&!T||g==="bottom"&&T,I=n.left,U=p[_]-B*x.height):i==="yAxis"&&(B=g==="left"&&!T||g==="right"&&T,I=p[_]-B*x.width,U=n.top);var oe=Dr(Dr(Dr({},x),W),{},{realScaleType:L,x:I,y:U,scale:Z,width:i==="xAxis"?n.width:x.width,height:i==="yAxis"?n.height:x.height});return oe.bandSize=Uc(oe,W),!x.hide&&i==="xAxis"?p[_]+=(B?-1:1)*oe.height:x.hide||(p[_]+=(B?-1:1)*oe.width),Dr(Dr({},b),{},sd({},O,oe))},{})},TR=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 TR({x:r,y:n},{x:i,y:o})},CR=(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)}}])})();sd(CR,"EPS",1e-4);var ax=function(t){var r=Object.keys(t).reduce(function(n,i){return Dr(Dr({},n),{},sd({},i,CR.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 OR(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,iT;function wV(){if(iT)return cg;iT=1;var e=bR();function t(r){var n=e(r),i=n%1;return n===n?i?n-i:n:0}return cg=t,cg}var fg,aT;function SV(){if(aT)return fg;aT=1;var e=Ck(),t=on(),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,oT;function OV(){if(oT)return dg;oT=1;var e=xV(),t=SV(),r=e(t);return dg=r,dg}var _V=OV();const PV=Ue(_V);var EV=KC();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("")}),ox=C.createContext(void 0),sx=C.createContext(void 0),kR=C.createContext(void 0),NR=C.createContext({}),RR=C.createContext(void 0),$R=C.createContext(0),MR=C.createContext(0),sT=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 D.createElement(ox.Provider,{value:n},D.createElement(sx.Provider,{value:i},D.createElement(NR.Provider,{value:o},D.createElement(kR.Provider,{value:v},D.createElement(RR.Provider,{value:u},D.createElement($R.Provider,{value:d},D.createElement(MR.Provider,{value:f},l)))))))},TV=function(){return C.useContext(RR)},IR=function(t){var r=C.useContext(ox);r==null&&Gi();var n=r[t];return n==null&&Gi(),n},CV=function(){var t=C.useContext(ox);return ai(t)},kV=function(){var t=C.useContext(sx),r=PV(t,function(n){return OR(n.domain,Number.isFinite)});return r||ai(t)},DR=function(t){var r=C.useContext(sx);r==null&&Gi();var n=r[t];return n==null&&Gi(),n},NV=function(){var t=C.useContext(kR);return t},RV=function(){return C.useContext(NR)},ux=function(){return C.useContext(MR)},lx=function(){return C.useContext($R)};function lo(e){"@babel/helpers - typeof";return lo=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},lo(e)}function $V(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function MV(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 WR(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:WR(n,d)};var x=f,g,E=function(){return g===void 0&&(g=r(O,x)),g},j=O.coordinate,A=f===0||df(e,j,E,v,l);A||(f=0,v=u,d+=1),A&&(v=j+e*(E()/2+i),f+=d)},m;d<=o.length;)if(m=p(),m)return m.v;return[]}function wu(e){"@babel/helpers - typeof";return wu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},wu(e)}function vT(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 Dt(e){for(var t=1;t0?b.coordinate-g*e:b.coordinate})}else o[m]=b=Dt(Dt({},b),{},{tickCoord:b.coordinate});var E=df(e,b.tickCoord,x,l,f);E&&(f=b.tickCoord-e*(x()/2+i),o[m]=Dt(Dt({},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=Dt(Dt({},v),{},{tickCoord:m>0?v.coordinate-m*e:v.coordinate});var b=df(e,v.tickCoord,function(){return p},f,d);b&&(d=v.tickCoord-e*(p/2+i),u[l-1]=Dt(Dt({},v),{},{isShow:!0}))}for(var O=o?l-1:l,x=function(j){var A=u[j],T,P=function(){return T===void 0&&(T=r(A,j)),T};if(j===0){var _=e*(A.coordinate-e*P()/2-f);u[j]=A=Dt(Dt({},A),{},{tickCoord:_<0?A.coordinate-_*e:A.coordinate})}else u[j]=A=Dt(Dt({},A),{},{tickCoord:A.coordinate});var N=df(e,A.tickCoord,P,f,d);N&&(f=A.tickCoord+e*(P()/2+i),u[j]=Dt(Dt({},A),{},{isShow:!0}))},g=0;g=2?zt(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(j){return j.isShow}))}var O7=["viewBox"],_7=["viewBox"],P7=["ticks"];function po(e){"@babel/helpers - typeof";return po=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},po(e)}function Ba(){return Ba=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 yT(e,t){for(var r=0;r0?f(this.props):f(b)),u<=0||l<=0||!O||!O.length?null:D.createElement(qe,{className:$e("recharts-cartesian-axis",d),ref:function(g){n.layerReference=g}},o&&this.renderAxisLine(),this.renderTicks(O,this.state.fontSize,this.state.letterSpacing),At.renderCallByParent(this.props))}}],[{key:"renderTickItem",value:function(n,i,o){var u,l=$e(i.className,"recharts-cartesian-axis-tick-value");return D.isValidElement(n)?u=D.cloneElement(n,bt(bt({},i),{},{className:l})):je(n)?u=n(bt(bt({},i),{},{className:l})):u=D.createElement(Ki,Ba({},i,{className:"recharts-cartesian-axis-tick-value"}),o),u}}])})(C.Component);px(To,"displayName","CartesianAxis");px(To,"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 $7=["x1","y1","x2","y2","key"],M7=["offset"];function Xi(e){"@babel/helpers - typeof";return Xi=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},Xi(e)}function gT(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 D.createElement("rect",{x:i,y:o,ry:f,width:u,height:l,stroke:"none",fill:r,fillOpacity:n,className:"recharts-cartesian-grid-bg"})};function VR(e,t){var r;if(D.isValidElement(e))r=D.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=bT(t,$7),d=Se(f,!1);d.offset;var v=bT(d,M7);r=D.createElement("line",qi({},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 VR(i,d)});return D.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 VR(i,d)});return D.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 D.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 D.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 D.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 D.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 VN(dx(Lt(Lt(Lt({},To.defaultProps),n),{},{ticks:Sn(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 VN(dx(Lt(Lt(Lt({},To.defaultProps),n),{},{ticks:Sn(n,!0),viewBox:{x:0,y:0,width:i,height:o}})),u.top,u.top+u.height,r)},Na={horizontal:!0,vertical:!0,stroke:"#ccc",fill:"none",verticalFill:[],horizontalFill:[]};function Su(e){var t,r,n,i,o,u,l=ux(),f=lx(),d=RV(),v=Lt(Lt({},e),{},{stroke:(t=e.stroke)!==null&&t!==void 0?t:Na.stroke,fill:(r=e.fill)!==null&&r!==void 0?r:Na.fill,horizontal:(n=e.horizontal)!==null&&n!==void 0?n:Na.horizontal,horizontalFill:(i=e.horizontalFill)!==null&&i!==void 0?i:Na.horizontalFill,vertical:(o=e.vertical)!==null&&o!==void 0?o:Na.vertical,verticalFill:(u=e.verticalFill)!==null&&u!==void 0?u:Na.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,j=CV(),A=kV();if(!le(b)||b<=0||!le(O)||O<=0||!le(p)||p!==+p||!le(m)||m!==+m)return null;var T=v.verticalCoordinatesGenerator||H7,P=v.horizontalCoordinatesGenerator||K7,_=v.horizontalPoints,N=v.verticalPoints;if((!_||!_.length)&&je(P)){var R=g&&g.length,I=P({yAxis:A?Lt(Lt({},A),{},{ticks:R?g:A.ticks}):void 0,width:l,height:f,offset:d},R?!0:x);zr(Array.isArray(I),"horizontalCoordinatesGenerator should return Array but instead it returned [".concat(Xi(I),"]")),Array.isArray(I)&&(_=I)}if((!N||!N.length)&&je(T)){var U=E&&E.length,B=T({xAxis:j?Lt(Lt({},j),{},{ticks:U?E:j.ticks}):void 0,width:l,height:f,offset:d},U?!0:x);zr(Array.isArray(B),"verticalCoordinatesGenerator should return Array but instead it returned [".concat(Xi(B),"]")),Array.isArray(B)&&(N=B)}return D.createElement("g",{className:"recharts-cartesian-grid"},D.createElement(F7,{fill:v.fill,fillOpacity:v.fillOpacity,x:v.x,y:v.y,width:v.width,height:v.height,ry:v.ry}),D.createElement(q7,qi({},v,{offset:d,horizontalPoints:_,xAxis:j,yAxis:A})),D.createElement(z7,qi({},v,{offset:d,verticalPoints:N,xAxis:j,yAxis:A})),D.createElement(U7,qi({},v,{horizontalPoints:_})),D.createElement(W7,qi({},v,{verticalPoints:N})))}Su.displayName="CartesianGrid";var V7=["type","layout","connectNulls","ref"],G7=["key"];function ho(e){"@babel/helpers - typeof";return ho=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ho(e)}function xT(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 Ds(){return Ds=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(Ra(f.slice(0,O)),[p-x]);break}var g=b.length%2===0?[0,m]:[m];return[].concat(Ra(t.repeat(f,v)),Ra(b),g).map(function(E){return"".concat(E,"px")}).join(", ")}),Lr(r,"id",_o("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,Du);if(!p)return null;var m=function(x,g){return{x:x.x,y:x.y,value:x.value,errorVal:wt(x.payload,g)}},b={clipPath:n?"url(#clipPath-".concat(i,")"):null};return D.createElement(qe,b,p.map(function(O){return D.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 D.createElement(qe,Ds({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=xT(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 D.createElement(Kc,Ds({},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,j=E.prevPoints,A=E.totalLength;return D.createElement(rn,{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(T){var P=T.t;if(j){var _=j.length/l.length,N=l.map(function($,z){var G=Math.floor(z*_);if(j[G]){var V=j[G],Y=sr(V.x,$.x),J=sr(V.y,$.y);return ir(ir({},$),{},{x:Y(P),y:J(P)})}if(O){var H=sr(x*2,$.x),ee=sr(g/2,$.y);return ir(ir({},$),{},{x:H(P),y:ee(P)})}return ir(ir({},$),{},{x:$.x,y:$.y})});return o.renderCurveStatically(N,n,i)}var R=sr(0,A),I=R(P),U;if(f){var B="".concat(f).split(/[,\s]+/gim).map(function($){return parseFloat($)});U=o.getStrokeDasharray(I,A,B)}else U=o.generateSimpleStrokeDasharray(A,I);return o.renderCurveStatically(l,n,i,{strokeDasharray:U})})}},{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||!Iu(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,j=l.length===1,A=$e("recharts-line",f),T=d&&d.allowDataOverflow,P=v&&v.allowDataOverflow,_=T||P,N=ke(g)?this.id:g,R=(n=Se(u,!1))!==null&&n!==void 0?n:{r:3,strokeWidth:2},I=R.r,U=I===void 0?3:I,B=R.strokeWidth,$=B===void 0?2:B,z=BB(u)?u:{},G=z.clipDot,V=G===void 0?!0:G,Y=U*2+$;return D.createElement(qe,{className:A},T||P?D.createElement("defs",null,D.createElement("clipPath",{id:"clipPath-".concat(N)},D.createElement("rect",{x:T?m:m-b/2,y:P?p:p-O/2,width:T?b:b*2,height:P?O:O*2})),!V&&D.createElement("clipPath",{id:"clipPath-dots-".concat(N)},D.createElement("rect",{x:m-Y/2,y:p-Y/2,width:b+Y,height:O+Y}))):null,!j&&this.renderCurve(_,N),this.renderErrorBar(_,N),(j||u)&&this.renderDots(_,V,N),(!x||E)&&jn.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(Ra(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 u$(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=yc(b,u.dataKey,i)}else m=p&&p[n]||l[n];return m?[].concat(go(f),[ZN(d,m)]):f},[])},TT=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=KN(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,j=E.type,A=E.dataKey,T=E.allowDataOverflow,P=E.allowDuplicatedCategory,_=E.scale,N=E.ticks,R=E.includeHidden,I=E[u];if(O[I])return O;var U=dd(t.data,{graphicalItems:i.filter(function(W){var oe,ce=u in W.props?W.props[u]:(oe=W.type.defaultProps)===null||oe===void 0?void 0:oe[u];return ce===I}),dataStartIndex:f,dataEndIndex:d}),B=U.length,$,z,G;DG(E.domain,T,j)&&($=c0(E.domain,null,T),b&&(j==="number"||_!=="auto")&&(G=Rs(U,A,"category")));var V=u$(j);if(!$||$.length===0){var Y,J=(Y=E.domain)!==null&&Y!==void 0?Y:V;if(A){if($=Rs(U,A,j),j==="category"&&b){var H=TB($);P&&H?(z=$,$=nf(0,B)):P||($=$j(J,$,x).reduce(function(W,oe){return W.indexOf(oe)>=0?W:[].concat(go(W),[oe])},[]))}else if(j==="category")P?$=$.filter(function(W){return W!==""&&!ke(W)}):$=$j(J,$,x).reduce(function(W,oe){return W.indexOf(oe)>=0||oe===""||ke(oe)?W:[].concat(go(W),[oe])},[]);else if(j==="number"){var ee=q6(U,i.filter(function(W){var oe,ce,me=u in W.props?W.props[u]:(oe=W.type.defaultProps)===null||oe===void 0?void 0:oe[u],Pe="hide"in W.props?W.props.hide:(ce=W.type.defaultProps)===null||ce===void 0?void 0:ce.hide;return me===I&&(R||!Pe)}),A,o,v);ee&&($=ee)}b&&(j==="number"||_!=="auto")&&(G=Rs(U,A,"category"))}else b?$=nf(0,B):l&&l[I]&&l[I].hasStack&&j==="number"?$=m==="expand"?[0,1]:QN(l[I].stackGroups,f,d):$=HN(U,i.filter(function(W){var oe=u in W.props?W.props[u]:W.type.defaultProps[u],ce="hide"in W.props?W.props.hide:W.type.defaultProps.hide;return oe===I&&(R||!ce)}),j,v,!0);if(j==="number")$=V0(p,$,I,o,N),J&&($=c0(J,$,T));else if(j==="category"&&J){var Z=J,L=$.every(function(W){return Z.indexOf(W)>=0});L&&($=Z)}}return te(te({},O),{},_e({},I,te(te({},E),{},{axisType:o,domain:$,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=KN(v,o),x=-1;return n.reduce(function(g,E){var j=E.type.defaultProps!==void 0?te(te({},E.type.defaultProps),E.props):E.props,A=j[u],T=u$("number");if(!g[A]){x++;var P;return O?P=nf(0,b):l&&l[A]&&l[A].hasStack?(P=QN(l[A].stackGroups,f,d),P=V0(p,P,A,o)):(P=c0(T,HN(m,n.filter(function(_){var N,R,I=u in _.props?_.props[u]:(N=_.type.defaultProps)===null||N===void 0?void 0:N[u],U="hide"in _.props?_.props.hide:(R=_.type.defaultProps)===null||R===void 0?void 0:R.hide;return I===A&&!U}),"number",v),i.defaultProps.allowDataOverflow),P=V0(p,P,A,o)),te(te({},g),{},_e({},A,te(te({axisType:o},i.defaultProps),{},{hide:!0,orientation:lr(sX,"".concat(o,".").concat(x%2),null),domain:P,originalDomain:T,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=ai(t),n=Sn(r,!1,!0);return{tooltipTicks:n,orderedTooltipTicks:kb(n,function(i){return i.coordinate}),tooltipAxis:r,tooltipAxisBandSize:Uc(r,n)}},CT=function(t){var r=t.children,n=t.defaultShowTooltip,i=or(r,so),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=_n(r&&r.type);return n&&n.indexOf("Bar")>=0})},kT=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,so),O=or(p,Pn),x=Object.keys(f).reduce(function(P,_){var N=f[_],R=N.orientation;return!N.mirror&&!N.hide?te(te({},P),{},_e({},R,P[R]+N.width)):P},{left:m.left||0,right:m.right||0}),g=Object.keys(u).reduce(function(P,_){var N=u[_],R=N.orientation;return!N.mirror&&!N.hide?te(te({},P),{},_e({},R,lr(P,"".concat(R))+N.height)):P},{top:m.top||0,bottom:m.bottom||0}),E=te(te({},g),x),j=E.bottom;b&&(E.bottom+=b.props.height||so.defaultProps.height),O&&r&&(E=B6(E,i,n,r));var A=d-E.left-E.right,T=v-E.top-E.bottom;return te(te({brushBottom:j},E),{},{width:Math.max(A,0),height:Math.max(T,0)})},yX=function(t,r){if(r==="xAxis")return t[r].width;if(r==="yAxis")return t[r].height},hx=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,j){var A=j.graphicalItems,T=j.stackGroups,P=j.offset,_=j.updateId,N=j.dataStartIndex,R=j.dataEndIndex,I=E.barSize,U=E.layout,B=E.barGap,$=E.barCategoryGap,z=E.maxBarSize,G=kT(U),V=G.numericAxisName,Y=G.cateAxisName,J=vX(A),H=[];return A.forEach(function(ee,Z){var L=dd(E.data,{graphicalItems:[ee],dataStartIndex:N,dataEndIndex:R}),W=ee.type.defaultProps!==void 0?te(te({},ee.type.defaultProps),ee.props):ee.props,oe=W.dataKey,ce=W.maxBarSize,me=W["".concat(V,"Id")],Pe=W["".concat(Y,"Id")],Le={},Ae=f.reduce(function(Ht,Er){var na=j["".concat(Er.axisType,"Map")],Co=W["".concat(Er.axisType,"Id")];na&&na[Co]||Er.axisType==="zAxis"||Gi();var ko=na[Co];return te(te({},Ht),{},_e(_e({},Er.axisType,ko),"".concat(Er.axisType,"Ticks"),Sn(ko)))},Le),ae=Ae[Y],ge=Ae["".concat(Y,"Ticks")],Te=T&&T[me]&&T[me].hasStack&&Y6(ee,T[me].stackGroups),ne=_n(ee.type).indexOf("Bar")>=0,We=Uc(ae,ge),Ne=[],Ce=J&&D6({barSize:I,stackGroups:T,totalSize:yX(Ae,Y)});if(ne){var Je,st,Pr=ke(ce)?z:ce,Hr=(Je=(st=Uc(ae,ge,!0))!==null&&st!==void 0?st:Pr)!==null&&Je!==void 0?Je:0;Ne=L6({barGap:B,barCategoryGap:$,bandSize:Hr!==We?Hr:We,sizeList:Ce[Pe],maxBarSize:Pr}),Hr!==We&&(Ne=Ne.map(function(Ht){return te(te({},Ht),{},{position:te(te({},Ht.position),{},{offset:Ht.position.offset-Hr/2})})}))}var Kr=ee&&ee.type&&ee.type.getComposedData;Kr&&H.push({props:te(te({},Kr(te(te({},Ae),{},{displayedData:L,props:E,dataKey:oe,item:ee,bandSize:We,barPosition:Ne,offset:P,stackedData:Te,layout:U,dataStartIndex:N,dataEndIndex:R}))),{},_e(_e(_e({key:ee.key||"item-".concat(Z)},V,Ae[V]),Y,Ae[Y]),"animationId",_)),childIndex:zB(ee,E.children),item:ee})}),H},b=function(E,j){var A=E.props,T=E.dataStartIndex,P=E.dataEndIndex,_=E.updateId;if(!GO({props:A}))return null;var N=A.children,R=A.layout,I=A.stackOffset,U=A.data,B=A.reverseStackOrder,$=kT(R),z=$.numericAxisName,G=$.cateAxisName,V=cr(N,n),Y=G6(U,V,"".concat(z,"Id"),"".concat(G,"Id"),I,B),J=f.reduce(function(W,oe){var ce="".concat(oe.axisType,"Map");return te(te({},W),{},_e({},ce,pX(A,te(te({},oe),{},{graphicalItems:V,stackGroups:oe.axisType===z&&Y,dataStartIndex:T,dataEndIndex:P}))))},{}),H=mX(te(te({},J),{},{props:A,graphicalItems:V}),j==null?void 0:j.legendBBox);Object.keys(J).forEach(function(W){J[W]=v(A,J[W],H,W.replace("Map",""),r)});var ee=J["".concat(G,"Map")],Z=hX(ee),L=m(A,te(te({},J),{},{dataStartIndex:T,dataEndIndex:P,updateId:_,graphicalItems:V,stackGroups:Y,offset:H}));return te(te({formattedGraphicalItems:L,graphicalItems:V,offset:H,stackGroups:Y},Z),J)},O=(function(g){function E(j){var A,T,P;return YG(this,E),P=JG(this,E,[j]),_e(P,"eventEmitterSymbol",Symbol("rechartsEventEmitter")),_e(P,"accessibilityManager",new IG),_e(P,"handleLegendBBoxUpdate",function(_){if(_){var N=P.state,R=N.dataStartIndex,I=N.dataEndIndex,U=N.updateId;P.setState(te({legendBBox:_},b({props:P.props,dataStartIndex:R,dataEndIndex:I,updateId:U},te(te({},P.state),{},{legendBBox:_}))))}}),_e(P,"handleReceiveSyncEvent",function(_,N,R){if(P.props.syncId===_){if(R===P.eventEmitterSymbol&&typeof P.props.syncMethod!="function")return;P.applySyncEvent(N)}}),_e(P,"handleBrushChange",function(_){var N=_.startIndex,R=_.endIndex;if(N!==P.state.dataStartIndex||R!==P.state.dataEndIndex){var I=P.state.updateId;P.setState(function(){return te({dataStartIndex:N,dataEndIndex:R},b({props:P.props,dataStartIndex:N,dataEndIndex:R,updateId:I},P.state))}),P.triggerSyncEvent({dataStartIndex:N,dataEndIndex:R})}}),_e(P,"handleMouseEnter",function(_){var N=P.getMouseInfo(_);if(N){var R=te(te({},N),{},{isTooltipActive:!0});P.setState(R),P.triggerSyncEvent(R);var I=P.props.onMouseEnter;je(I)&&I(R,_)}}),_e(P,"triggeredAfterMouseMove",function(_){var N=P.getMouseInfo(_),R=N?te(te({},N),{},{isTooltipActive:!0}):{isTooltipActive:!1};P.setState(R),P.triggerSyncEvent(R);var I=P.props.onMouseMove;je(I)&&I(R,_)}),_e(P,"handleItemMouseEnter",function(_){P.setState(function(){return{isTooltipActive:!0,activeItem:_,activePayload:_.tooltipPayload,activeCoordinate:_.tooltipPosition||{x:_.cx,y:_.cy}}})}),_e(P,"handleItemMouseLeave",function(){P.setState(function(){return{isTooltipActive:!1}})}),_e(P,"handleMouseMove",function(_){_.persist(),P.throttleTriggeredAfterMouseMove(_)}),_e(P,"handleMouseLeave",function(_){P.throttleTriggeredAfterMouseMove.cancel();var N={isTooltipActive:!1};P.setState(N),P.triggerSyncEvent(N);var R=P.props.onMouseLeave;je(R)&&R(N,_)}),_e(P,"handleOuterEvent",function(_){var N=qB(_),R=lr(P.props,"".concat(N));if(N&&je(R)){var I,U;/.*touch.*/i.test(N)?U=P.getMouseInfo(_.changedTouches[0]):U=P.getMouseInfo(_),R((I=U)!==null&&I!==void 0?I:{},_)}}),_e(P,"handleClick",function(_){var N=P.getMouseInfo(_);if(N){var R=te(te({},N),{},{isTooltipActive:!0});P.setState(R),P.triggerSyncEvent(R);var I=P.props.onClick;je(I)&&I(R,_)}}),_e(P,"handleMouseDown",function(_){var N=P.props.onMouseDown;if(je(N)){var R=P.getMouseInfo(_);N(R,_)}}),_e(P,"handleMouseUp",function(_){var N=P.props.onMouseUp;if(je(N)){var R=P.getMouseInfo(_);N(R,_)}}),_e(P,"handleTouchMove",function(_){_.changedTouches!=null&&_.changedTouches.length>0&&P.throttleTriggeredAfterMouseMove(_.changedTouches[0])}),_e(P,"handleTouchStart",function(_){_.changedTouches!=null&&_.changedTouches.length>0&&P.handleMouseDown(_.changedTouches[0])}),_e(P,"handleTouchEnd",function(_){_.changedTouches!=null&&_.changedTouches.length>0&&P.handleMouseUp(_.changedTouches[0])}),_e(P,"handleDoubleClick",function(_){var N=P.props.onDoubleClick;if(je(N)){var R=P.getMouseInfo(_);N(R,_)}}),_e(P,"handleContextMenu",function(_){var N=P.props.onContextMenu;if(je(N)){var R=P.getMouseInfo(_);N(R,_)}}),_e(P,"triggerSyncEvent",function(_){P.props.syncId!==void 0&&vg.emit(mg,P.props.syncId,_,P.eventEmitterSymbol)}),_e(P,"applySyncEvent",function(_){var N=P.props,R=N.layout,I=N.syncMethod,U=P.state.updateId,B=_.dataStartIndex,$=_.dataEndIndex;if(_.dataStartIndex!==void 0||_.dataEndIndex!==void 0)P.setState(te({dataStartIndex:B,dataEndIndex:$},b({props:P.props,dataStartIndex:B,dataEndIndex:$,updateId:U},P.state)));else if(_.activeTooltipIndex!==void 0){var z=_.chartX,G=_.chartY,V=_.activeTooltipIndex,Y=P.state,J=Y.offset,H=Y.tooltipTicks;if(!J)return;if(typeof I=="function")V=I(H,_);else if(I==="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=yc(ee,We,V),ne=Z&&L&&yc(L,We,V)}else Te=ee==null?void 0:ee[G],ne=Z&&L&&L[G];if(Pe||me){var Ne=_.props.activeIndex!==void 0?_.props.activeIndex:G;return[C.cloneElement(_,te(te(te({},I.props),Ae),{},{activeIndex:Ne})),null,null]}if(!ke(Te))return[ae].concat(go(P.renderActivePoints({item:I,activePoint:Te,basePoint:ne,childIndex:G,isRange:Z})))}else{var Ce,Je=(Ce=P.getItemByXY(P.state.activeCoordinate))!==null&&Ce!==void 0?Ce:{graphicalItem:ae},st=Je.graphicalItem,Pr=st.item,Hr=Pr===void 0?_:Pr,Kr=st.childIndex,Ht=te(te(te({},I.props),Ae),{},{activeIndex:Kr});return[C.cloneElement(Hr,Ht),null,null]}return Z?[ae,null,null]:[ae,null]}),_e(P,"renderCustomized",function(_,N,R){return C.cloneElement(_,te(te({key:"recharts-customized-".concat(R)},P.props),P.state))}),_e(P,"renderMap",{CartesianGrid:{handler:fc,once:!0},ReferenceArea:{handler:P.renderReferenceElement},ReferenceLine:{handler:fc},ReferenceDot:{handler:P.renderReferenceElement},XAxis:{handler:fc},YAxis:{handler:fc},Brush:{handler:P.renderBrush,once:!0},Bar:{handler:P.renderGraphicChild},Line:{handler:P.renderGraphicChild},Area:{handler:P.renderGraphicChild},Radar:{handler:P.renderGraphicChild},RadialBar:{handler:P.renderGraphicChild},Scatter:{handler:P.renderGraphicChild},Pie:{handler:P.renderGraphicChild},Funnel:{handler:P.renderGraphicChild},Tooltip:{handler:P.renderCursor,once:!0},PolarGrid:{handler:P.renderPolarGrid,once:!0},PolarAngleAxis:{handler:P.renderPolarAxis},PolarRadiusAxis:{handler:P.renderPolarAxis},Customized:{handler:P.renderCustomized}}),P.clipPathId="".concat((A=j.id)!==null&&A!==void 0?A:_o("recharts"),"-clip"),P.throttleTriggeredAfterMouseMove=Uk(P.triggeredAfterMouseMove,(T=j.throttleDelay)!==null&&T!==void 0?T:1e3/60),P.state={},P}return rX(E,g),ZG(E,[{key:"componentDidMount",value:function(){var A,T;this.addListener(),this.accessibilityManager.setDetails({container:this.container,offset:{left:(A=this.props.margin.left)!==null&&A!==void 0?A:0,top:(T=this.props.margin.top)!==null&&T!==void 0?T:0},coordinateList:this.state.tooltipTicks,mouseHandlerCallback:this.triggeredAfterMouseMove,layout:this.props.layout}),this.displayDefaultTooltip()}},{key:"displayDefaultTooltip",value:function(){var A=this.props,T=A.children,P=A.data,_=A.height,N=A.layout,R=or(T,qt);if(R){var I=R.props.defaultIndex;if(!(typeof I!="number"||I<0||I>this.state.tooltipTicks.length-1)){var U=this.state.tooltipTicks[I]&&this.state.tooltipTicks[I].value,B=Y0(this.state,P,I,U),$=this.state.tooltipTicks[I].coordinate,z=(this.state.offset.top+_)/2,G=N==="horizontal",V=G?{x:$,y:z}:{y:$,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[I].tooltipPosition),B=Y.props.points[I].tooltipPayload);var J={activeTooltipIndex:I,isTooltipActive:!0,activeLabel:U,activePayload:B,activeCoordinate:V};this.setState(J),this.renderCursor(R),this.accessibilityManager.setIndex(I)}}}},{key:"getSnapshotBeforeUpdate",value:function(A,T){if(!this.props.accessibilityLayer)return null;if(this.state.tooltipTicks!==T.tooltipTicks&&this.accessibilityManager.setDetails({coordinateList:this.state.tooltipTicks}),this.props.layout!==A.layout&&this.accessibilityManager.setDetails({layout:this.props.layout}),this.props.margin!==A.margin){var P,_;this.accessibilityManager.setDetails({offset:{left:(P=this.props.margin.left)!==null&&P!==void 0?P:0,top:(_=this.props.margin.top)!==null&&_!==void 0?_:0}})}return null}},{key:"componentDidUpdate",value:function(A){Ng([or(A.children,qt)],[or(this.props.children,qt)])||this.displayDefaultTooltip()}},{key:"componentWillUnmount",value:function(){this.removeListener(),this.throttleTriggeredAfterMouseMove.cancel()}},{key:"getTooltipEventType",value:function(){var A=or(this.props.children,qt);if(A&&typeof A.props.shared=="boolean"){var T=A.props.shared?"axis":"item";return l.indexOf(T)>=0?T:o}return o}},{key:"getMouseInfo",value:function(A){if(!this.container)return null;var T=this.container,P=T.getBoundingClientRect(),_=Az(P),N={chartX:Math.round(A.pageX-_.left),chartY:Math.round(A.pageY-_.top)},R=P.width/T.offsetWidth||1,I=this.inRange(N.chartX,N.chartY,R);if(!I)return null;var U=this.state,B=U.xAxisMap,$=U.yAxisMap,z=this.getTooltipEventType(),G=TT(this.state,this.props.data,this.props.layout,I);if(z!=="axis"&&B&&$){var V=ai(B).scale,Y=ai($).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(A,T){var P=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,_=this.props.layout,N=A/P,R=T/P;if(_==="horizontal"||_==="vertical"){var I=this.state.offset,U=N>=I.left&&N<=I.left+I.width&&R>=I.top&&R<=I.top+I.height;return U?{x:N,y:R}:null}var B=this.state,$=B.angleAxisMap,z=B.radiusAxisMap;if($&&z){var G=ai($);return Dj({x:N,y:R},G)}return null}},{key:"parseEventsOfWrapper",value:function(){var A=this.props.children,T=this.getTooltipEventType(),P=or(A,qt),_={};P&&T==="axis"&&(P.props.trigger==="click"?_={onClick:this.handleClick}:_={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=gc(this.props,this.handleOuterEvent);return te(te({},N),_)}},{key:"addListener",value:function(){vg.on(mg,this.handleReceiveSyncEvent)}},{key:"removeListener",value:function(){vg.removeListener(mg,this.handleReceiveSyncEvent)}},{key:"filterFormatItem",value:function(A,T,P){for(var _=this.state.formattedGraphicalItems,N=0,R=_.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:qC[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(Ua,{width:"100%",height:300,children:w.jsxs(l$,{children:[w.jsx(sn,{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(ku,{fill:i.color},o))}),w.jsx(qt,{contentStyle:{backgroundColor:"#1a1a2e",border:"1px solid #333"}}),w.jsx(Pn,{})]})})}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(Ua,{width:"100%",height:300,children:w.jsxs(gX,{data:r,children:[w.jsx(Su,{strokeDasharray:"3 3",stroke:"#333"}),w.jsx(fi,{dataKey:"month",stroke:"#888"}),w.jsx(kn,{stroke:"#888",allowDecimals:!1}),w.jsx(qt,{contentStyle:{backgroundColor:"#1a1a2e",border:"1px solid #333"}}),w.jsx(ra,{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}=Ur(),r=Eu(),[n,i]=C.useState([]),[o,u]=C.useState([]),[l,f]=C.useState(!0);if(C.useEffect(()=>{Promise.all([BC(),FC()]).then(([x,g])=>{i(x),u(g)}).finally(()=>f(!1))},[]),l)return w.jsx(ju,{});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(Ie,{xs:6,md:3,children:w.jsx(vt,{title:e("dashboard.totalSessions"),value:d,color:"#4a90d9",onClick:()=>r("/sessions")})}),w.jsx(Ie,{xs:6,md:3,children:w.jsx(vt,{title:e("dashboard.totalUsers"),value:v,color:"#9b59b6",onClick:()=>r("/users")})}),w.jsx(Ie,{xs:6,md:3,children:w.jsx(vt,{title:e("dashboard.successRate"),value:`${p}%`,color:"#27ae60"})}),w.jsx(Ie,{xs:6,md:3,children:w.jsx(vt,{title:e("dashboard.avgPrecision"),value:m.toFixed(1),color:"#f39c12"})})]}),w.jsxs(wr,{className:"mb-4 g-3",children:[w.jsx(Ie,{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(Ie,{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(Ie,{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(qr,{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(zs,{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(Cf,{success:x.success})})]},x.id))})]})]})})}),w.jsx(Ie,{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(qr,{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:Me.string,tooltip:Me.bool,as:Me.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 Nn=C.createContext({}),vx=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(Nn);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")})});vx.displayName="FormCheckInput";const gf=C.forwardRef(({bsPrefix:e,className:t,htmlFor:r,...n},i)=>{const{controlId:o}=C.useContext(Nn);return e=Re(e,"form-check-label"),w.jsx("label",{...n,ref:i,htmlFor:r||o,className:Oe(t,e)})});gf.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 c$=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",...j},A)=>{t=Re(t,"form-check"),r=Re(r,"form-switch");const{controlId:T}=C.useContext(Nn),P=C.useMemo(()=>({controlId:e||T}),[T,e]),_=!g&&x!=null&&x!==!1||EX(g,gf),N=w.jsx(vx,{...j,type:O==="switch"?"checkbox":O,ref:A,isValid:u,isInvalid:l,disabled:o,as:E});return w.jsx(Nn.Provider,{value:P,children:w.jsx("div",{style:m,className:Oe(p,_&&t,n&&`${t}-inline`,i&&`${t}-reverse`,O==="switch"&&r),children:g||w.jsxs(w.Fragment,{children:[N,_&&w.jsx(gf,{title:b,children:x}),d&&w.jsx(pd,{type:v,tooltip:f,children:d})]})})})});c$.displayName="FormCheck";const bf=Object.assign(c$,{Input:vx,Label:gf}),f$=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(Nn);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")})});f$.displayName="FormControl";const jX=Object.assign(f$,{Feedback:pd}),d$=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})));d$.displayName="FormFloating";const mx=C.forwardRef(({controlId:e,as:t="div",...r},n)=>{const i=C.useMemo(()=>({controlId:e}),[e]);return w.jsx(Nn.Provider,{value:i,children:w.jsx(t,{...r,ref:n})})});mx.displayName="FormGroup";const p$=C.forwardRef(({as:e="label",bsPrefix:t,column:r=!1,visuallyHidden:n=!1,className:i,htmlFor:o,...u},l)=>{const{controlId:f}=C.useContext(Nn);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(Ie,{ref:l,as:"label",className:v,htmlFor:o,...u}):w.jsx(e,{ref:l,className:v,htmlFor:o,...u})});p$.displayName="FormLabel";const h$=C.forwardRef(({bsPrefix:e,className:t,id:r,...n},i)=>{const{controlId:o}=C.useContext(Nn);return e=Re(e,"form-range"),w.jsx("input",{...n,type:"range",ref:i,className:Oe(t,e),id:r||o})});h$.displayName="FormRange";const v$=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(Nn);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})});v$.displayName="FormSelect";const m$=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")})));m$.displayName="FormText";const y$=C.forwardRef((e,t)=>w.jsx(bf,{...e,ref:t,type:"switch"}));y$.displayName="Switch";const AX=Object.assign(y$,{Input:bf.Input,Label:bf.Label}),g$=C.forwardRef(({bsPrefix:e,className:t,children:r,controlId:n,label:i,...o},u)=>(e=Re(e,"form-floating"),w.jsxs(mx,{ref:u,className:Oe(t,e),controlId:n,...o,children:[r,w.jsx("label",{htmlFor:n,children:i})]})));g$.displayName="FloatingLabel";const TX={_ref:Me.any,validated:Me.bool,as:Me.elementType},yx=C.forwardRef(({className:e,validated:t,as:r="form",...n},i)=>w.jsx(r,{...n,ref:i,className:Oe(e,t&&"was-validated")}));yx.displayName="Form";yx.propTypes=TX;const Ir=Object.assign(yx,{Group:mx,Control:jX,Floating:d$,Check:bf,Switch:AX,Label:p$,Text:m$,Range:h$,Select:v$,FloatingLabel:g$}),gx=C.forwardRef(({active:e=!1,disabled:t=!1,className:r,style:n,activeLabel:i="(current)",children:o,linkStyle:u,linkClassName:l,as:f=ub,...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})]})})});gx.displayName="PageItem";function Lu(e,t,r=e){const n=C.forwardRef(({children:i,...o},u)=>w.jsxs(gx,{...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=Lu("First","«"),kX=Lu("Prev","‹","Previous"),NX=Lu("Ellipsis","…","More"),RX=Lu("Next","›"),$X=Lu("Last","»"),b$=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}`)})});b$.displayName="Pagination";const $a=Object.assign(b$,{First:CX,Prev:kX,Ellipsis:NX,Item:gx,Next:RX,Last:$X}),MX="/ProserveReport/",IX=`${MX}logo.png`;function hd({subtitle:e}){const{t}=Ur(),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}=Ur(),r=Eu(),[n,i]=M2(),[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"),[j,A]=C.useState("desc"),[T,P]=C.useState(1);C.useEffect(()=>{BC().then(u).finally(()=>f(!1))},[]);const _=C.useMemo(()=>{let $=o;if(v>=0&&($=$.filter(z=>z.sessionTypeAsInt===v)),m==="success"?$=$.filter(z=>z.success):m==="failed"&&($=$.filter(z=>!z.success)),O.trim()){const z=O.toLowerCase();$=$.filter(G=>G.scenarioName.toLowerCase().includes(z)||G.mapName.toLowerCase().includes(z)||G.sessionName.toLowerCase().includes(z))}return[...$].sort((z,G)=>{const V=z[g],Y=G[g];return typeof V=="string"&&typeof Y=="string"?j==="asc"?V.localeCompare(Y):Y.localeCompare(V):j==="asc"?Number(V)-Number(Y):Number(Y)-Number(V)})},[o,v,m,O,g,j]),N=Math.ceil(_.length/gg),R=_.slice((T-1)*gg,T*gg);function I($){g===$?A(j==="asc"?"desc":"asc"):(E($),A("desc"))}function U($){return g!==$?"":j==="asc"?" ▲":" ▼"}if(l)return w.jsx(ju,{});const B=[...new Set(o.map($=>$.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")," (",_.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(Ie,{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:$=>{const z=Number($.target.value);p(z),P(1),z>=0?i({type:String(z)}):i({})},className:"filter-select",children:[w.jsx("option",{value:-1,children:e("sessions.allTypes")}),B.map($=>w.jsx("option",{value:$,children:e(`sessionType.${$}`)},$))]})]})}),w.jsx(Ie,{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:$=>{b($.target.value),P(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(Ie,{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:$=>{x($.target.value),P(1)},className:"filter-input"})]})})]})})}),w.jsx(be,{className:"data-card",children:w.jsx(be.Body,{className:"p-0",children:w.jsxs(qr,{hover:!0,responsive:!0,className:"data-table mb-0",children:[w.jsx("thead",{children:w.jsxs("tr",{children:[w.jsxs("th",{className:"sortable",onClick:()=>I("sessionDateAsString"),children:[e("table.date"),U("sessionDateAsString")]}),w.jsxs("th",{className:"sortable",onClick:()=>I("sessionTypeAsInt"),children:[e("table.type"),U("sessionTypeAsInt")]}),w.jsxs("th",{className:"sortable",onClick:()=>I("scenarioName"),children:[e("table.scenario"),U("scenarioName")]}),w.jsx("th",{children:e("table.map")}),w.jsxs("th",{className:"sortable",onClick:()=>I("score"),children:[e("table.score"),U("score")]}),w.jsx("th",{children:e("table.enemies")}),w.jsx("th",{children:e("table.civilians")}),w.jsxs("th",{className:"sortable",onClick:()=>I("timeToFinish"),children:[e("table.duration"),U("timeToFinish")]}),w.jsx("th",{children:e("table.result")})]})}),w.jsxs("tbody",{children:[R.map($=>w.jsxs("tr",{className:"clickable-row",onClick:()=>r(`/sessions/${$.id}`),children:[w.jsx("td",{children:LX($.sessionDateAsString,t)}),w.jsx("td",{children:w.jsx(zs,{typeId:$.sessionTypeAsInt})}),w.jsx("td",{children:$.scenarioName||"-"}),w.jsx("td",{children:$.mapName||"-"}),w.jsx("td",{className:"fw-bold",children:$.score}),w.jsx("td",{children:$.nbEnemyHit}),w.jsx("td",{className:$.nbCivilsHit>0?"text-danger":"",children:$.nbCivilsHit}),w.jsx("td",{children:DX($.timeToFinish)}),w.jsx("td",{children:w.jsx(Cf,{success:$.success})})]},$.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($a,{className:"custom-pagination",children:[w.jsx($a.First,{onClick:()=>P(1),disabled:T===1}),w.jsx($a.Prev,{onClick:()=>P(T-1),disabled:T===1}),Array.from({length:Math.min(N,5)},($,z)=>{const V=Math.max(1,Math.min(T-2,N-4))+z;return V>N?null:w.jsx($a.Item,{active:V===T,onClick:()=>P(V),children:V},V)}),w.jsx($a.Next,{onClick:()=>P(T+1),disabled:T===N}),w.jsx($a.Last,{onClick:()=>P(N),disabled:T===N})]})})]})}const NT=1e3;function FX(e,t,r){const n=(e-t)/(r-t)*100;return Math.round(n*NT)/NT}function RT({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 x$=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 RT(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})):RT({min:i,now:o,max:u,label:l,visuallyHidden:f,striped:d,animated:v,bsPrefix:p,variant:m},r)})});x$.displayName="ProgressBar";const qX={human:{image:"HumanTarget.png",ratio:.7183098591549296,maxW:320},longRange:{image:"longRangeTarget.PNG",ratio:1,maxW:480}};function zX({shots:e,variant:t="human"}){const{image:r,ratio:n,maxW:i}=qX[t],o=100,u=o*n;return w.jsx("div",{style:{width:"100%",maxWidth:i,margin:"0 auto",aspectRatio:`${n}`},children:w.jsxs("svg",{viewBox:`0 0 ${u} ${o}`,width:"100%",height:"100%",style:{display:"block"},children:[w.jsx("image",{href:`/ProserveReport/${r}`,x:"0",y:"0",width:u,height:o,preserveAspectRatio:"none"}),e.map(l=>{const f=l.x*u,d=l.y*o;return w.jsxs("g",{children:[w.jsx("circle",{cx:f,cy:d,r:1.2,fill:"#00e5ff",stroke:"#000",strokeWidth:.3,opacity:.9}),w.jsx("text",{x:f+2,y:d+1,fill:"#00e5ff",fontSize:2.8,fontWeight:"bold",stroke:"#000",strokeWidth:.15,paintOrder:"stroke",children:l.index})]},l.index)})]})})}function UX(e){const t=Math.floor(e/60),r=Math.floor(e%60);return`${t}m ${r}s`}function WX(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 $T={enemy:"#27ae60",civilian:"#e74c3c",police:"#f39c12",object:"#6c757d",target:"#4a90d9",paperTarget:"#2980b9",deadBody:"#95a5a6"},HX={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 KX(){const{id:e}=HT(),t=Number(e),{t:r,lang:n}=Ur(),[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),$L(t).catch(()=>[]),ML(t).catch(()=>[]),DL(t).catch(()=>null)]).then(([_,N,R,I])=>{if(o(_),l(N),d(R),p(I),_){const U=_.sessionTypeAsInt;(U===Mr.FireRange||U===Mr.Challenge||U===Mr.LongRange)&&IL(t,-1,U).then(b)}}).finally(()=>x(!1))},[t]),O)return w.jsx(ju,{});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(_=>{_.nbEnemyHitsByUser>0&&(E.enemy=(E.enemy||0)+_.nbEnemyHitsByUser),_.nbCivilHitsByUser>0&&(E.civilian=(E.civilian||0)+_.nbCivilHitsByUser),_.nbPoliceHitsByUser>0&&(E.police=(E.police||0)+_.nbPoliceHitsByUser),_.nbObjectHitsByUser>0&&(E.object=(E.object||0)+_.nbObjectHitsByUser)});const j=Object.entries(E).map(([_,N])=>({name:r(bg[_]),value:N,color:$T[_]||"#6c757d"})),A=new Map(u.map(_=>[_.id,_])),T=i.sessionTypeAsInt===Mr.FireRange||i.sessionTypeAsInt===Mr.Challenge||i.sessionTypeAsInt===Mr.LongRange,P=i.sessionTypeAsInt===Mr.Challenge;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(Fs,{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(Ie,{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(zs,{typeId:i.sessionTypeAsInt}),w.jsx("span",{className:"text-muted-custom",children:WX(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(Ie,{xs:"auto",children:w.jsx(Cf,{success:i.success})})]})})}),w.jsxs(wr,{className:"mb-4 g-3",children:[w.jsx(Ie,{xs:6,md:2,children:w.jsx(vt,{title:r("session.duration"),value:UX(i.timeToFinish),color:"#9b59b6"})}),T?w.jsxs(w.Fragment,{children:[w.jsx(Ie,{xs:6,md:2,children:w.jsx(vt,{title:r("firerange.shotsFired"),value:m.length,color:"#1abc9c"})}),P&&w.jsx(Ie,{xs:6,md:2,children:w.jsx(vt,{title:r("firerange.targetsHit"),value:m.filter(_=>(_.ReactId??_.reactId??-1)>=0).length,color:"#4a90d9"})}),w.jsx(Ie,{xs:6,md:2,children:w.jsx(vt,{title:r("firerange.shotsMissed"),value:m.filter(_=>_.ReactId<0||_.reactId<0).length,color:"#e74c3c"})}),w.jsx(Ie,{xs:6,md:2,children:w.jsx(vt,{title:r("firerange.avgPrecision"),value:(()=>{const _=m.filter(R=>(R.ReactId??R.reactId??-1)>=0);return _.length===0?"-":`${(_.reduce((R,I)=>R+(I.HitPrecision??I.hitPrecision??0),0)/_.length*100).toFixed(1)}%`})(),color:"#27ae60"})}),P&&w.jsx(Ie,{xs:6,md:2,children:w.jsx(vt,{title:r("firerange.avgReaction"),value:(()=>{const _=m.filter(R=>(R.ReactionTime??R.reactionTime??0)>0);return _.length===0?"-":`${(_.reduce((R,I)=>R+(I.ReactionTime??I.reactionTime??0),0)/_.length/1e3).toFixed(3)} s`})(),color:"#f39c12"})})]}):w.jsxs(w.Fragment,{children:[w.jsx(Ie,{xs:6,md:2,children:w.jsx(vt,{title:r("session.enemiesHit"),value:i.nbEnemyHit,color:"#27ae60"})}),w.jsx(Ie,{xs:6,md:2,children:w.jsx(vt,{title:r("session.civiliansHit"),value:i.nbCivilsHit,color:i.nbCivilsHit>0?"#e74c3c":"#27ae60"})}),w.jsx(Ie,{xs:6,md:2,children:w.jsx(vt,{title:r("session.damageTaken"),value:Math.round(i.damageTaken),color:"#f39c12"})}),w.jsx(Ie,{xs:6,md:2,children:w.jsx(vt,{title:r("session.participants"),value:u.length,color:"#1abc9c"})})]})]}),m.length>0&&(()=>{const _=(B,...$)=>{for(const z of $)if(B[z]!=null)return B[z];return 0},N=m.filter(B=>_(B,"ReactId","reactId")>=0),R=m.map(B=>({shot:_(B,"ShotIndex","shotIndex"),precision:_(B,"ReactId","reactId")>=0?Math.round(_(B,"HitPrecision","hitPrecision")*100):0})),I=N.filter(B=>_(B,"ReactionTime","reactionTime")>0).map(B=>({shot:_(B,"ShotIndex","shotIndex"),reaction:Math.round(_(B,"ReactionTime","reactionTime"))})),U=N.map(B=>({index:_(B,"ShotIndex","shotIndex"),x:_(B,"HitLocationX","hitLocationX"),y:_(B,"HitLocationY","hitLocationY"),precision:_(B,"HitPrecision","hitPrecision")}));return w.jsxs(wr,{className:"mb-4 g-3",children:[!P&&w.jsx(Ie,{lg:5,children:w.jsx(be,{className:"data-card h-100",children:w.jsxs(be.Body,{className:"d-flex flex-column",children:[w.jsx(be.Title,{className:"text-center",children:r("firerange.targetView")}),w.jsx("div",{className:"d-flex flex-grow-1 align-items-center justify-content-center",children:w.jsx(zX,{shots:U,variant:i.sessionTypeAsInt===Mr.LongRange?"longRange":"human"})})]})})}),w.jsx(Ie,{lg:P?12:7,children:w.jsx(be,{className:"data-card h-100",children:w.jsxs(be.Body,{className:"d-flex flex-column",children:[w.jsx(be.Title,{className:"text-center",children:i.sessionTypeAsInt===Mr.Challenge?r("firerange.reactionChart"):r("firerange.precisionChart")}),w.jsx("div",{className:"d-flex flex-grow-1 align-items-center",children:i.sessionTypeAsInt===Mr.Challenge?w.jsx(Ua,{width:"100%",height:250,children:w.jsxs(Q0,{data:I,margin:{top:10,right:20,left:10,bottom:5},children:[w.jsx(Su,{strokeDasharray:"3 3",stroke:"#333"}),w.jsx(fi,{dataKey:"shot",stroke:"#999"}),w.jsx(kn,{stroke:"#999",width:50,tickFormatter:B=>`${B}`}),w.jsx(qt,{contentStyle:{backgroundColor:"#1a1a2e",border:"1px solid #333"},formatter:B=>[`${B} ms`,r("chart.reactionTime")]}),w.jsx(ci,{type:"linear",dataKey:"reaction",stroke:"#f39c12",strokeWidth:2,dot:{fill:"#f39c12",r:4},activeDot:{r:6}})]})}):w.jsx(Ua,{width:"100%",height:250,children:w.jsxs(Q0,{data:R,margin:{top:10,right:20,left:10,bottom:5},children:[w.jsx(Su,{strokeDasharray:"3 3",stroke:"#333"}),w.jsx(fi,{dataKey:"shot",stroke:"#999"}),w.jsx(kn,{domain:[0,100],stroke:"#999",width:50,tickFormatter:B=>`${B}`}),w.jsx(qt,{contentStyle:{backgroundColor:"#1a1a2e",border:"1px solid #333"},formatter:B=>[`${B}%`,r("chart.precision")]}),w.jsx(ci,{type:"linear",dataKey:"precision",stroke:"#ff6b8a",strokeWidth:2,dot:{fill:"#ff6b8a",r:4},activeDot:{r:6}})]})})})]})})})]})})(),!T&&w.jsx(be,{className:"data-card mb-4",children:w.jsxs(be.Body,{children:[w.jsx(be.Title,{children:r("session.participants")}),w.jsxs(qr,{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((_,N)=>{const R=A.get(_.userId);return w.jsxs("tr",{children:[w.jsx("td",{children:w.jsx(Fs,{to:`/users/${_.userId}`,className:"table-link",children:R?R.firstName&&R.lastName?`${R.firstName} ${R.lastName}`:R.username:`User #${_.userId}`})}),w.jsx("td",{children:_.nbFiredShotsByUser}),w.jsx("td",{children:_.nbMissedShotsByUser}),w.jsx("td",{children:_.nbEnemyHitsByUser}),w.jsx("td",{className:_.nbCivilHitsByUser>0?"text-danger":"",children:_.nbCivilHitsByUser}),w.jsx("td",{children:_.averagePrecision!=null?`${(_.averagePrecision*100).toFixed(1)}%`:"-"}),w.jsx("td",{children:_.averageReactionTime!=null&&_.averageReactionTime>0?`${_.averageReactionTime.toFixed(0)} ms`:"-"}),w.jsx("td",{children:_.nbReceivedHitsFromEnemyIA??0}),w.jsx("td",{children:_.totalEnemyKilled??0}),w.jsx("td",{className:(_.totalCivilKilled??0)>0?"text-danger":"",children:_.totalCivilKilled??0})]},N)}),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&&!P&&w.jsx(Ie,{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(([_,N])=>{if(!N||typeof N!="object")return null;const R=N.maxScore>0?N.score/N.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.${_}`)}),w.jsxs("span",{children:[N.score,"/",N.maxScore,N.success!==void 0&&w.jsx(qa,{bg:N.success?"success":"danger",className:"ms-2",children:N.success?"OK":"X"})]})]}),w.jsx(x$,{now:R,variant:N.success?"success":"danger",className:"objective-bar"})]},_)})]})})}),j.length>0&&w.jsx(Ie,{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(Ua,{width:"100%",height:250,children:w.jsxs(l$,{children:[w.jsx(sn,{data:j,dataKey:"value",nameKey:"name",cx:"50%",cy:"50%",outerRadius:80,label:!0,children:j.map((_,N)=>w.jsx(ku,{fill:_.color},N))}),w.jsx(qt,{contentStyle:{backgroundColor:"#1a1a2e",border:"1px solid #333"}}),w.jsx(Pn,{})]})})]})})})]}),!T&&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(qr,{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((_,N)=>{const R=FL[_.reactTypeId]||"",I=HX[R]||"",U=I&&bg[I]?r(bg[I]):_.reactType||"-",B=$T[I]||"#6c757d";return w.jsxs("tr",{children:[w.jsx("td",{children:_.shotIndex}),w.jsx("td",{children:_.shooterName||`#${_.shooterId}`}),w.jsx("td",{children:w.jsx(qa,{bg:"secondary",style:{backgroundColor:B},children:U})}),w.jsx("td",{children:_.targetName||_.targetUserName||"-"}),w.jsx("td",{children:_.targetBoneName||_.hitLocationTag||"-"}),w.jsx("td",{children:_.hitPrecision!=null?`${(_.hitPrecision*100).toFixed(1)}%`:"-"}),w.jsx("td",{children:_.hitTargetDistance!=null&&_.hitTargetDistance>0?`${_.hitTargetDistance.toFixed(1)}m`:"-"}),w.jsx("td",{children:_.reactionTime!=null&&_.reactionTime>0?`${_.reactionTime.toFixed(0)}ms`:"-"}),w.jsx("td",{children:_.targetKilled?w.jsx(qa,{bg:"danger",children:r("badge.killed")}):"-"}),w.jsx("td",{children:_.timeStamp!=null?`${_.timeStamp.toFixed(1)}s`:"-"})]},N)})})]})]})})]})}function VX(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 GX(){const{t:e,lang:t}=Ur(),r=Eu(),[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(()=>{FC().then(i).finally(()=>u(!1))},[]);const b=C.useMemo(()=>{let g=n;if(l.trim()){const E=l.toLowerCase();g=g.filter(j=>j.username.toLowerCase().includes(E)||j.firstName.toLowerCase().includes(E)||j.lastName.toLowerCase().includes(E))}return[...g].sort((E,j)=>{const A=E[d],T=j[d];return typeof A=="string"&&typeof T=="string"?p==="asc"?A.localeCompare(T):T.localeCompare(A):p==="asc"?Number(A)-Number(T):Number(T)-Number(A)})},[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(ju,{}):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(qr,{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:VX(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 XX({debriefRows:e}){const{t,lang:r}=Ur(),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(Ua,{width:"100%",height:300,children:w.jsxs(Q0,{data:i,children:[w.jsx(Su,{strokeDasharray:"3 3",stroke:"#333"}),w.jsx(fi,{dataKey:"dateLabel",stroke:"#888"}),w.jsx(kn,{yAxisId:"left",stroke:"#4a90d9"}),w.jsx(kn,{yAxisId:"right",orientation:"right",stroke:"#f39c12"}),w.jsx(qt,{contentStyle:{backgroundColor:"#1a1a2e",border:"1px solid #333"},labelFormatter:o=>o}),w.jsx(Pn,{}),w.jsx(ci,{yAxisId:"left",type:"monotone",dataKey:"precision",stroke:"#4a90d9",name:t("chart.precision"),strokeWidth:2,dot:{r:3}}),w.jsx(ci,{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 YX(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 QX(){const{id:e}=HT(),t=Number(e),{t:r,lang:n}=Ur(),[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(ju,{});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(Fs,{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(Ie,{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(Ie,{xs:6,md:2,children:w.jsx(vt,{title:r("user.sessions"),value:(f==null?void 0:f.nbSessions)||u.length,color:"#4a90d9"})}),w.jsx(Ie,{xs:6,md:2,children:w.jsx(vt,{title:r("user.totalTime"),value:MT((f==null?void 0:f.totalDuration)||0),color:"#9b59b6"})}),w.jsx(Ie,{xs:6,md:2,children:w.jsx(vt,{title:r("user.avgPrecision"),value:i.avgPrecision!=null?i.avgPrecision.toFixed(1):"-",color:"#27ae60"})}),w.jsx(Ie,{xs:6,md:2,children:w.jsx(vt,{title:r("user.avgReaction"),value:i.avgReaction!=null&&i.avgReaction>0?`${i.avgReaction.toFixed(0)}ms`:"-",color:"#f39c12"})}),w.jsx(Ie,{xs:6,md:2,children:w.jsx(vt,{title:r("user.shotsFired"),value:(b==null?void 0:b.nbFiredShotsByUser)||0,color:"#1abc9c"})}),w.jsx(Ie,{xs:6,md:2,children:w.jsx(vt,{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(Ie,{md:4,children:[w.jsx("h6",{className:"text-muted-custom",children:r("user.shots")}),w.jsx(qr,{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(Ie,{md:4,children:[w.jsx("h6",{className:"text-muted-custom",children:r("user.hitsReceived")}),w.jsx(qr,{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(Ie,{md:4,children:[w.jsx("h6",{className:"text-muted-custom",children:r("user.eliminations")}),w.jsx(qr,{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(XX,{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(zs,{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(qr,{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(Fs,{to:`/sessions/${x.id}`,className:"table-link",children:YX(x.sessionDateAsString,n)})}),w.jsx("td",{children:w.jsx(zs,{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(Cf,{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 ZX(){return w.jsx(w2,{children:w.jsxs(Ri,{element:w.jsx(EL,{}),children:[w.jsx(Ri,{path:"/",element:w.jsx(OX,{})}),w.jsx(Ri,{path:"/sessions",element:w.jsx(BX,{})}),w.jsx(Ri,{path:"/sessions/:id",element:w.jsx(KX,{})}),w.jsx(Ri,{path:"/users",element:w.jsx(GX,{})}),w.jsx(Ri,{path:"/users/:id",element:w.jsx(QX,{})})]})})}jI.createRoot(document.getElementById("root")).render(w.jsx(D.StrictMode,{children:w.jsx(L2,{children:w.jsx(C2,{children:w.jsx(ZX,{})})})}));