16)throw Error(AS+kt(e));if(!e.s)return new d(qr);for(wt=!1,u=p,s=new d(.03125);e.abs().gte(.1);)e=e.times(s),l+=5;for(n=Math.log(Do(2,l))/Math.LN10*2+5|0,u+=n,r=i=o=new d(qr),d.precision=u;;){if(i=ft(i.times(e),u),r=r.times(++f),s=o.plus(bi(i,r,u)),Hn(s.d).slice(0,u)===Hn(o.d).slice(0,u)){for(;l--;)o=ft(o.times(o),u);return d.precision=p,t==null?(wt=!0,ft(o,p)):o}o=s}}function kt(e){for(var t=e.e*xt,r=e.d[0];r>=10;r/=10)t++;return t}function Ux(e,t,r){if(t>e.LN10.sd())throw wt=!0,r&&(e.precision=r),Error(sn+"LN10 precision limit exceeded");return ft(new e(e.LN10),t)}function eo(e){for(var t="";e--;)t+="0";return t}function Mc(e,t){var r,n,i,o,s,u,f,l,d,p=1,m=10,g=e,b=g.d,y=g.constructor,w=y.precision;if(g.s<1)throw Error(sn+(g.s?"NaN":"-Infinity"));if(g.eq(qr))return new y(0);if(t==null?(wt=!1,l=w):l=t,g.eq(10))return t==null&&(wt=!0),Ux(y,l);if(l+=m,y.precision=l,r=Hn(b),n=r.charAt(0),o=kt(g),Math.abs(o)<15e14){for(;n<7&&n!=1||n==1&&r.charAt(1)>3;)g=g.times(e),r=Hn(g.d),n=r.charAt(0),p++;o=kt(g),n>1?(g=new y("0."+r),o++):g=new y(n+"."+r.slice(1))}else return f=Ux(y,l+2,w).times(o+""),g=Mc(new y(n+"."+r.slice(1)),l-m).plus(f),y.precision=w,t==null?(wt=!0,ft(g,w)):g;for(u=s=g=bi(g.minus(qr),g.plus(qr),l),d=ft(g.times(g),l),i=3;;){if(s=ft(s.times(d),l),f=u.plus(bi(s,new y(i),l)),Hn(f.d).slice(0,l)===Hn(u.d).slice(0,l))return u=u.times(2),o!==0&&(u=u.plus(Ux(y,l+2,w).times(o+""))),u=bi(u,new y(p),l),y.precision=w,t==null?(wt=!0,ft(u,w)):u;u=f,i+=2}}function nN(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=Xs(r/xt),e.d=[],n=(r+1)%xt,r<0&&(n+=xt),n_h||e.e<-_h))throw Error(AS+r)}else e.s=0,e.e=0,e.d=[0];return e}function ft(e,t,r){var n,i,o,s,u,f,l,d,p=e.d;for(s=1,o=p[0];o>=10;o/=10)s++;if(n=t-s,n<0)n+=xt,i=t,l=p[d=0];else{if(d=Math.ceil((n+1)/xt),o=p.length,d>=o)return e;for(l=o=p[d],s=1;o>=10;o/=10)s++;n%=xt,i=n-xt+s}if(r!==void 0&&(o=Do(10,s-i-1),u=l/o%10|0,f=t<0||p[d+1]!==void 0||l%o,f=r<4?(u||f)&&(r==0||r==(e.s<0?3:2)):u>5||u==5&&(r==4||f||r==6&&(n>0?i>0?l/Do(10,s-i):0:p[d-1])%10&1||r==(e.s<0?8:7))),t<1||!p[0])return f?(o=kt(e),p.length=1,t=t-o-1,p[0]=Do(10,(xt-t%xt)%xt),e.e=Xs(-t/xt)||0):(p.length=1,p[0]=e.e=e.s=0),e;if(n==0?(p.length=d,o=1,d--):(p.length=d+1,o=Do(10,xt-n),p[d]=i>0?(l/Do(10,s-i)%Do(10,i)|0)*o:0),f)for(;;)if(d==0){(p[0]+=o)==Ht&&(p[0]=1,++e.e);break}else{if(p[d]+=o,p[d]!=Ht)break;p[d--]=0,o=1}for(n=p.length;p[--n]===0;)p.pop();if(wt&&(e.e>_h||e.e<-_h))throw Error(AS+kt(e));return e}function ED(e,t){var r,n,i,o,s,u,f,l,d,p,m=e.constructor,g=m.precision;if(!e.s||!t.s)return t.s?t.s=-t.s:t=new m(e),wt?ft(t,g):t;if(f=e.d,p=t.d,n=t.e,l=e.e,f=f.slice(),s=l-n,s){for(d=s<0,d?(r=f,s=-s,u=p.length):(r=p,n=l,u=f.length),i=Math.max(Math.ceil(g/xt),u)+2,s>i&&(s=i,r.length=1),r.reverse(),i=s;i--;)r.push(0);r.reverse()}else{for(i=f.length,u=p.length,d=i0;--i)f[u++]=0;for(i=p.length;i>s;){if(f[--i]0?o=o.charAt(0)+"."+o.slice(1)+eo(n):s>1&&(o=o.charAt(0)+"."+o.slice(1)),o=o+(i<0?"e":"e+")+i):i<0?(o="0."+eo(-i-1)+o,r&&(n=r-s)>0&&(o+=eo(n))):i>=s?(o+=eo(i+1-s),r&&(n=r-i-1)>0&&(o=o+"."+eo(n))):((n=i+1)0&&(i+1===s&&(o+="."),o+=eo(n))),e.s<0?"-"+o:o}function iN(e,t){if(e.length>t)return e.length=t,!0}function PD(e){var t,r,n;function i(o){var s=this;if(!(s instanceof i))return new i(o);if(s.constructor=i,o instanceof i){s.s=o.s,s.e=o.e,s.d=(o=o.d)?o.slice():o;return}if(typeof o=="number"){if(o*0!==0)throw Error(Uo+o);if(o>0)s.s=1;else if(o<0)o=-o,s.s=-1;else{s.s=0,s.e=0,s.d=[0];return}if(o===~~o&&o<1e7){s.e=0,s.d=[o];return}return nN(s,o.toString())}else if(typeof o!="string")throw Error(Uo+o);if(o.charCodeAt(0)===45?(o=o.slice(1),s.s=-1):s.s=1,AG.test(o))nN(s,o);else throw Error(Uo+o)}if(i.prototype=je,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=PD,i.config=i.set=CG,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(Uo+r+": "+n);if((n=e[r="LN10"])!==void 0)if(n==Math.LN10)this[r]=new this(n);else throw Error(Uo+r+": "+n);return this}var CS=PD(PG);qr=new CS(1);const ut=CS;function NG(e){return MG(e)||RG(e)||kG(e)||TG()}function TG(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
-In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function kG(e,t){if(e){if(typeof e=="string")return v1(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 v1(e,t)}}function RG(e){if(typeof Symbol<"u"&&Symbol.iterator in Object(e))return Array.from(e)}function MG(e){if(Array.isArray(e))return v1(e)}function v1(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-s,oN(function(){for(var u=arguments.length,f=new Array(u),l=0;le.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 s=e[Symbol.iterator](),u;!(n=(u=s.next()).done)&&(r.push(u.value),!(t&&r.length===t));n=!0);}catch(f){i=!0,o=f}finally{try{!n&&s.return!=null&&s.return()}finally{if(i)throw o}}return r}}function XG(e){if(Array.isArray(e))return e}function kD(e){var t=Ic(e,2),r=t[0],n=t[1],i=r,o=n;return r>n&&(i=n,o=r),[i,o]}function RD(e,t,r){if(e.lte(0))return new ut(0);var n=Lp.getDigitCount(e.toNumber()),i=new ut(10).pow(n),o=e.div(i),s=n!==1?.05:.1,u=new ut(Math.ceil(o.div(s).toNumber())).add(r).mul(s),f=u.mul(i);return t?f:new ut(Math.ceil(f))}function YG(e,t,r){var n=1,i=new ut(e);if(!i.isint()&&r){var o=Math.abs(e);o<1?(n=new ut(10).pow(Lp.getDigitCount(e)-1),i=new ut(Math.floor(i.div(n).toNumber())).mul(n)):o>1&&(i=new ut(Math.floor(e)))}else e===0?i=new ut(Math.floor((t-1)/2)):r||(i=new ut(Math.floor(e)));var s=Math.floor((t-1)/2),u=$G(LG(function(f){return i.add(new ut(f-s).mul(n)).toNumber()}),g1);return u(0,t)}function MD(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 ut(0),tickMin:new ut(0),tickMax:new ut(0)};var o=RD(new ut(t).sub(e).div(r-1),n,i),s;e<=0&&t>=0?s=new ut(0):(s=new ut(e).add(t).div(2),s=s.sub(new ut(s).mod(o)));var u=Math.ceil(s.sub(e).div(o).toNumber()),f=Math.ceil(new ut(t).sub(s).div(o).toNumber()),l=u+f+1;return l>r?MD(e,t,r,n,i+1):(l0?f+(r-l):f,u=t>0?u:u+(r-l)),{step:o,tickMin:s.sub(new ut(u).mul(o)),tickMax:s.add(new ut(f).mul(o))})}function QG(e){var t=Ic(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,s=Math.max(i,2),u=kD([r,n]),f=Ic(u,2),l=f[0],d=f[1];if(l===-1/0||d===1/0){var p=d===1/0?[l].concat(x1(g1(0,i-1).map(function(){return 1/0}))):[].concat(x1(g1(0,i-1).map(function(){return-1/0})),[d]);return r>n?y1(p):p}if(l===d)return YG(l,i,o);var m=MD(l,d,s,o),g=m.step,b=m.tickMin,y=m.tickMax,w=Lp.rangeStep(b,y.add(new ut(.1).mul(g)),g);return r>n?y1(w):w}function ZG(e,t){var r=Ic(e,2),n=r[0],i=r[1],o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,s=kD([n,i]),u=Ic(s,2),f=u[0],l=u[1];if(f===-1/0||l===1/0)return[n,i];if(f===l)return[f];var d=Math.max(t,2),p=RD(new ut(l).sub(f).div(d-1),o,0),m=[].concat(x1(Lp.rangeStep(new ut(f),new ut(l).sub(new ut(.99).mul(p)),p)),[l]);return n>i?y1(m):m}var JG=ND(QG),eK=ND(ZG),tK="Invariant failed";function Xo(e,t){throw new Error(tK)}var rK=["offset","layout","width","dataKey","data","dataPointFormatter","xAxis","yAxis"];function bs(e){"@babel/helpers - typeof";return bs=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},bs(e)}function jh(){return jh=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 cK(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 uK(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function fK(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,s=-1,u=(r=n?.length)!==null&&r!==void 0?r:0;if(u<=1)return 0;if(o&&o.axisType==="angleAxis"&&Math.abs(Math.abs(o.range[1]-o.range[0])-360)<=1e-6)for(var f=o.range,l=0;l0?i[l-1].coordinate:i[u-1].coordinate,p=i[l].coordinate,m=l>=u-1?i[0].coordinate:i[l+1].coordinate,g=void 0;if(ur(p-d)!==ur(m-p)){var b=[];if(ur(m-p)===ur(f[1]-f[0])){g=m;var y=p+f[1]-f[0];b[0]=Math.min(y,(y+d)/2),b[1]=Math.max(y,(y+d)/2)}else{g=d;var w=m+f[1]-f[0];b[0]=Math.min(p,(w+p)/2),b[1]=Math.max(p,(w+p)/2)}var j=[Math.min(p,(g+p)/2),Math.max(p,(g+p)/2)];if(t>j[0]&&t<=j[1]||t>=b[0]&&t<=b[1]){s=i[l].index;break}}else{var O=Math.min(d,m),E=Math.max(d,m);if(t>(O+p)/2&&t<=(E+p)/2){s=i[l].index;break}}}else for(var N=0;N0&&N(n[N].coordinate+n[N-1].coordinate)/2&&t<=(n[N].coordinate+n[N+1].coordinate)/2||N===u-1&&t>(n[N].coordinate+n[N-1].coordinate)/2){s=n[N].index;break}return s},NS=function(t){var r,n=t,i=n.type.displayName,o=(r=t.type)!==null&&r!==void 0&&r.defaultProps?Pt(Pt({},t.type.defaultProps),t.props):t.props,s=o.stroke,u=o.fill,f;switch(i){case"Line":f=s;break;case"Area":case"Radar":f=s&&s!=="none"?s:u;break;default:f=u;break}return f},AK=function(t){var r=t.barSize,n=t.totalSize,i=t.stackGroups,o=i===void 0?{}:i;if(!o)return{};for(var s={},u=Object.keys(o),f=0,l=u.length;f=0});if(j&&j.length){var O=j[0].type.defaultProps,E=O!==void 0?Pt(Pt({},O),j[0].props):j[0].props,N=E.barSize,A=E[w];s[A]||(s[A]=[]);var C=Ue(N)?r:N;s[A].push({item:j[0],stackList:j.slice(1),barSize:Ue(C)?void 0:fr(C,n,0)})}}return s},CK=function(t){var r=t.barGap,n=t.barCategoryGap,i=t.bandSize,o=t.sizeList,s=o===void 0?[]:o,u=t.maxBarSize,f=s.length;if(f<1)return null;var l=fr(r,i,0,!0),d,p=[];if(s[0].barSize===+s[0].barSize){var m=!1,g=i/f,b=s.reduce(function(N,A){return N+A.barSize||0},0);b+=(f-1)*l,b>=i&&(b-=(f-1)*l,l=0),b>=i&&g>0&&(m=!0,g*=.9,b=f*g);var y=(i-b)/2>>0,w={offset:y-l,size:0};d=s.reduce(function(N,A){var C={item:A.item,position:{offset:w.offset+w.size+l,size:m?g:A.barSize}},T=[].concat(lN(N),[C]);return w=T[T.length-1].position,A.stackList&&A.stackList.length&&A.stackList.forEach(function(R){T.push({item:R,position:w})}),T},p)}else{var j=fr(n,i,0,!0);i-2*j-(f-1)*l<=0&&(l=0);var O=(i-2*j-(f-1)*l)/f;O>1&&(O>>=0);var E=u===+u?Math.min(O,u):O;d=s.reduce(function(N,A,C){var T=[].concat(lN(N),[{item:A.item,position:{offset:j+(O+l)*C+(O-E)/2,size:E}}]);return A.stackList&&A.stackList.length&&A.stackList.forEach(function(R){T.push({item:R,position:T[T.length-1].position})}),T},p)}return d},NK=function(t,r,n,i){var o=n.children,s=n.width,u=n.margin,f=s-(u.left||0)-(u.right||0),l=$D({children:o,legendWidth:f});if(l){var d=i||{},p=d.width,m=d.height,g=l.align,b=l.verticalAlign,y=l.layout;if((y==="vertical"||y==="horizontal"&&b==="middle")&&g!=="center"&&ge(t[g]))return Pt(Pt({},t),{},is({},g,t[g]+(p||0)));if((y==="horizontal"||y==="vertical"&&g==="center")&&b!=="middle"&&ge(t[b]))return Pt(Pt({},t),{},is({},b,t[b]+(m||0)))}return t},TK=function(t,r,n){return Ue(r)?!0:t==="horizontal"?r==="yAxis":t==="vertical"||n==="x"?r==="xAxis":n==="y"?r==="yAxis":!0},BD=function(t,r,n,i,o){var s=r.props.children,u=Wr(s,pu).filter(function(l){return TK(i,o,l.props.direction)});if(u&&u.length){var f=u.map(function(l){return l.props.dataKey});return t.reduce(function(l,d){var p=Bt(d,n);if(Ue(p))return l;var m=Array.isArray(p)?[Ip(p),Mp(p)]:[p,p],g=f.reduce(function(b,y){var w=Bt(d,y,0),j=m[0]-Math.abs(Array.isArray(w)?w[0]:w),O=m[1]+Math.abs(Array.isArray(w)?w[1]:w);return[Math.min(j,b[0]),Math.max(O,b[1])]},[1/0,-1/0]);return[Math.min(g[0],l[0]),Math.max(g[1],l[1])]},[1/0,-1/0])}return null},kK=function(t,r,n,i,o){var s=r.map(function(u){return BD(t,u,n,o,i)}).filter(function(u){return!Ue(u)});return s&&s.length?s.reduce(function(u,f){return[Math.min(u[0],f[0]),Math.max(u[1],f[1])]},[1/0,-1/0]):null},FD=function(t,r,n,i,o){var s=r.map(function(f){var l=f.props.dataKey;return n==="number"&&l&&BD(t,f,l,i)||hc(t,l,n,o)});if(n==="number")return s.reduce(function(f,l){return[Math.min(f[0],l[0]),Math.max(f[1],l[1])]},[1/0,-1/0]);var u={};return s.reduce(function(f,l){for(var d=0,p=l.length;d=2?ur(u[0]-u[1])*2*l:l,r&&(t.ticks||t.niceTicks)){var d=(t.ticks||t.niceTicks).map(function(p){var m=o?o.indexOf(p):p;return{coordinate:i(m)+l,value:p,offset:l}});return d.filter(function(p){return!su(p.coordinate)})}return t.isCategorical&&t.categoricalDomain?t.categoricalDomain.map(function(p,m){return{coordinate:i(p)+l,value:p,index:m,offset:l}}):i.ticks&&!n?i.ticks(t.tickCount).map(function(p){return{coordinate:i(p)+l,value:p,offset:l}}):i.domain().map(function(p,m){return{coordinate:i(p)+l,value:o?o[p]:p,index:m,offset:l}})},Wx=new WeakMap,Vf=function(t,r){if(typeof r!="function")return t;Wx.has(t)||Wx.set(t,new WeakMap);var n=Wx.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},UD=function(t,r,n){var i=t.scale,o=t.type,s=t.layout,u=t.axisType;if(i==="auto")return s==="radial"&&u==="radiusAxis"?{scale:Cc(),realScaleType:"band"}:s==="radial"&&u==="angleAxis"?{scale:xh(),realScaleType:"linear"}:o==="category"&&r&&(r.indexOf("LineChart")>=0||r.indexOf("AreaChart")>=0||r.indexOf("ComposedChart")>=0&&!n)?{scale:dc(),realScaleType:"point"}:o==="category"?{scale:Cc(),realScaleType:"band"}:{scale:xh(),realScaleType:"linear"};if(Ho(i)){var f="scale".concat(xp(i));return{scale:(KC[f]||dc)(),realScaleType:KC[f]?f:"point"}}return ze(i)?{scale:i}:{scale:dc(),realScaleType:"point"}},uN=1e-4,WD=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])-uN,s=Math.max(i[0],i[1])+uN,u=t(r[0]),f=t(r[n-1]);(us||fs)&&t.domain([r[0],r[n-1]])}},RK=function(t,r){if(!t)return null;for(var n=0,i=t.length;ni)&&(o[1]=i),o[0]>i&&(o[0]=i),o[1]=0?(t[u][n][0]=o,t[u][n][1]=o+f,o=t[u][n][1]):(t[u][n][0]=s,t[u][n][1]=s+f,s=t[u][n][1])}},DK=function(t){var r=t.length;if(!(r<=0))for(var n=0,i=t[0].length;n=0?(t[s][n][0]=o,t[s][n][1]=o+u,o=t[s][n][1]):(t[s][n][0]=0,t[s][n][1]=0)}},LK={sign:IK,expand:j9,none:ds,silhouette:O9,wiggle:E9,positive:DK},$K=function(t,r,n){var i=r.map(function(u){return u.props.dataKey}),o=LK[n],s=_9().keys(i).value(function(u,f){return+Bt(u,f,0)}).order(Zb).offset(o);return s(t)},BK=function(t,r,n,i,o,s){if(!t)return null;var u=s?r.reverse():r,f={},l=u.reduce(function(p,m){var g,b=(g=m.type)!==null&&g!==void 0&&g.defaultProps?Pt(Pt({},m.type.defaultProps),m.props):m.props,y=b.stackId,w=b.hide;if(w)return p;var j=b[n],O=p[j]||{hasStack:!1,stackGroups:{}};if(Ft(y)){var E=O.stackGroups[y]||{numericAxisId:n,cateAxisId:i,items:[]};E.items.push(m),O.hasStack=!0,O.stackGroups[y]=E}else O.stackGroups[Hs("_stackId_")]={numericAxisId:n,cateAxisId:i,items:[m]};return Pt(Pt({},p),{},is({},j,O))},f),d={};return Object.keys(l).reduce(function(p,m){var g=l[m];if(g.hasStack){var b={};g.stackGroups=Object.keys(g.stackGroups).reduce(function(y,w){var j=g.stackGroups[w];return Pt(Pt({},y),{},is({},w,{numericAxisId:n,cateAxisId:i,items:j.items,stackedData:$K(t,j.items,o)}))},b)}return Pt(Pt({},p),{},is({},m,g))},d)},HD=function(t,r){var n=r.realScaleType,i=r.type,o=r.tickCount,s=r.originalDomain,u=r.allowDecimals,f=n||r.scale;if(f!=="auto"&&f!=="linear")return null;if(o&&i==="number"&&s&&(s[0]==="auto"||s[1]==="auto")){var l=t.domain();if(!l.length)return null;var d=JG(l,o,u);return t.domain([Ip(d),Mp(d)]),{niceTicks:d}}if(o&&i==="number"){var p=t.domain(),m=eK(p,o,u);return{niceTicks:m}}return null};function fN(e){var t=e.axis,r=e.ticks,n=e.bandSize,i=e.entry,o=e.index,s=e.dataKey;if(t.type==="category"){if(!t.allowDuplicatedCategory&&t.dataKey&&!Ue(i[t.dataKey])){var u=Jd(r,"value",i[t.dataKey]);if(u)return u.coordinate+n/2}return r[o]?r[o].coordinate+n/2:null}var f=Bt(i,Ue(s)?t.dataKey:s);return Ue(f)?null:t.scale(f)}var dN=function(t){var r=t.axis,n=t.ticks,i=t.offset,o=t.bandSize,s=t.entry,u=t.index;if(r.type==="category")return n[u]?n[u].coordinate+i:null;var f=Bt(s,r.dataKey,r.domain[u]);return Ue(f)?null:r.scale(f)-o/2+i},FK=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]},zK=function(t,r){var n,i=(n=t.type)!==null&&n!==void 0&&n.defaultProps?Pt(Pt({},t.type.defaultProps),t.props):t.props,o=i.stackId;if(Ft(o)){var s=r[o];if(s){var u=s.items.indexOf(t);return u>=0?s.stackedData[u]:null}}return null},qK=function(t){return t.reduce(function(r,n){return[Ip(n.concat([r[0]]).filter(ge)),Mp(n.concat([r[1]]).filter(ge))]},[1/0,-1/0])},VD=function(t,r,n){return Object.keys(t).reduce(function(i,o){var s=t[o],u=s.stackedData,f=u.reduce(function(l,d){var p=qK(d.slice(r,n+1));return[Math.min(l[0],p[0]),Math.max(l[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})},hN=/^dataMin[\s]*-[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,pN=/^dataMax[\s]*\+[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,_1=function(t,r,n){if(ze(t))return t(r,n);if(!Array.isArray(t))return r;var i=[];if(ge(t[0]))i[0]=n?t[0]:Math.min(t[0],r[0]);else if(hN.test(t[0])){var o=+hN.exec(t[0])[1];i[0]=r[0]-o}else ze(t[0])?i[0]=t[0](r[0]):i[0]=r[0];if(ge(t[1]))i[1]=n?t[1]:Math.max(t[1],r[1]);else if(pN.test(t[1])){var s=+pN.exec(t[1])[1];i[1]=r[1]+s}else ze(t[1])?i[1]=t[1](r[1]):i[1]=r[1];return i},Eh=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=iS(r,function(p){return p.coordinate}),s=1/0,u=1,f=o.length;ue.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},QK=function(t,r,n,i,o){var s=t.width,u=t.height,f=t.startAngle,l=t.endAngle,d=fr(t.cx,s,s/2),p=fr(t.cy,u,u/2),m=XD(s,u,n),g=fr(t.innerRadius,m,0),b=fr(t.outerRadius,m,m*.8),y=Object.keys(r);return y.reduce(function(w,j){var O=r[j],E=O.domain,N=O.reversed,A;if(Ue(O.range))i==="angleAxis"?A=[f,l]:i==="radiusAxis"&&(A=[g,b]),N&&(A=[A[1],A[0]]);else{A=O.range;var C=A,T=HK(C,2);f=T[0],l=T[1]}var R=UD(O,o),I=R.realScaleType,z=R.scale;z.domain(E).range(A),WD(z);var $=HD(z,mi(mi({},O),{},{realScaleType:I})),L=mi(mi(mi({},O),$),{},{range:A,radius:b,realScaleType:I,scale:z,cx:d,cy:p,innerRadius:g,outerRadius:b,startAngle:f,endAngle:l});return mi(mi({},w),{},KD({},j,L))},{})},ZK=function(t,r){var n=t.x,i=t.y,o=r.x,s=r.y;return Math.sqrt(Math.pow(n-o,2)+Math.pow(i-s,2))},JK=function(t,r){var n=t.x,i=t.y,o=r.cx,s=r.cy,u=ZK({x:n,y:i},{x:o,y:s});if(u<=0)return{radius:u};var f=(n-o)/u,l=Math.acos(f);return i>s&&(l=2*Math.PI-l),{radius:u,angle:YK(l),angleInRadian:l}},eX=function(t){var r=t.startAngle,n=t.endAngle,i=Math.floor(r/360),o=Math.floor(n/360),s=Math.min(i,o);return{startAngle:r-s*360,endAngle:n-s*360}},tX=function(t,r){var n=r.startAngle,i=r.endAngle,o=Math.floor(n/360),s=Math.floor(i/360),u=Math.min(o,s);return t+u*360},yN=function(t,r){var n=t.x,i=t.y,o=JK({x:n,y:i},r),s=o.radius,u=o.angle,f=r.innerRadius,l=r.outerRadius;if(sl)return!1;if(s===0)return!0;var d=eX(r),p=d.startAngle,m=d.endAngle,g=u,b;if(p<=m){for(;g>m;)g-=360;for(;g=p&&g<=m}else{for(;g>p;)g-=360;for(;g=m&&g<=p}return b?mi(mi({},r),{},{radius:s,angle:tX(g,r)}):null},YD=function(t){return!_.isValidElement(t)&&!ze(t)&&typeof t!="boolean"?t.className:""};function Bc(e){"@babel/helpers - typeof";return Bc=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Bc(e)}var rX=["offset"];function nX(e){return sX(e)||aX(e)||oX(e)||iX()}function iX(){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 oX(e,t){if(e){if(typeof e=="string")return j1(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 j1(e,t)}}function aX(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function sX(e){if(Array.isArray(e))return j1(e)}function j1(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 cX(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 xN(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 $t(e){for(var t=1;t=0?1:-1,E,N;i==="insideStart"?(E=g+O*s,N=y):i==="insideEnd"?(E=b-O*s,N=!y):i==="end"&&(E=b+O*s,N=y),N=j<=0?N:!N;var A=mt(l,d,w,E),C=mt(l,d,w,E+(N?1:-1)*359),T="M".concat(A.x,",").concat(A.y,`
- A`).concat(w,",").concat(w,",0,1,").concat(N?0:1,`,
- `).concat(C.x,",").concat(C.y),R=Ue(t.id)?Hs("recharts-radial-line-"):t.id;return F.createElement("text",Fc({},n,{dominantBaseline:"central",className:We("recharts-radial-bar-label",u)}),F.createElement("defs",null,F.createElement("path",{id:R,d:T})),F.createElement("textPath",{xlinkHref:"#".concat(R)},r))},vX=function(t){var r=t.viewBox,n=t.offset,i=t.position,o=r,s=o.cx,u=o.cy,f=o.innerRadius,l=o.outerRadius,d=o.startAngle,p=o.endAngle,m=(d+p)/2;if(i==="outside"){var g=mt(s,u,l+n,m),b=g.x,y=g.y;return{x:b,y,textAnchor:b>=s?"start":"end",verticalAnchor:"middle"}}if(i==="center")return{x:s,y:u,textAnchor:"middle",verticalAnchor:"middle"};if(i==="centerTop")return{x:s,y:u,textAnchor:"middle",verticalAnchor:"start"};if(i==="centerBottom")return{x:s,y:u,textAnchor:"middle",verticalAnchor:"end"};var w=(f+l)/2,j=mt(s,u,w,m),O=j.x,E=j.y;return{x:O,y:E,textAnchor:"middle",verticalAnchor:"middle"}},gX=function(t){var r=t.viewBox,n=t.parentViewBox,i=t.offset,o=t.position,s=r,u=s.x,f=s.y,l=s.width,d=s.height,p=d>=0?1:-1,m=p*i,g=p>0?"end":"start",b=p>0?"start":"end",y=l>=0?1:-1,w=y*i,j=y>0?"end":"start",O=y>0?"start":"end";if(o==="top"){var E={x:u+l/2,y:f-p*i,textAnchor:"middle",verticalAnchor:g};return $t($t({},E),n?{height:Math.max(f-n.y,0),width:l}:{})}if(o==="bottom"){var N={x:u+l/2,y:f+d+m,textAnchor:"middle",verticalAnchor:b};return $t($t({},N),n?{height:Math.max(n.y+n.height-(f+d),0),width:l}:{})}if(o==="left"){var A={x:u-w,y:f+d/2,textAnchor:j,verticalAnchor:"middle"};return $t($t({},A),n?{width:Math.max(A.x-n.x,0),height:d}:{})}if(o==="right"){var C={x:u+l+w,y:f+d/2,textAnchor:O,verticalAnchor:"middle"};return $t($t({},C),n?{width:Math.max(n.x+n.width-C.x,0),height:d}:{})}var T=n?{width:l,height:d}:{};return o==="insideLeft"?$t({x:u+w,y:f+d/2,textAnchor:O,verticalAnchor:"middle"},T):o==="insideRight"?$t({x:u+l-w,y:f+d/2,textAnchor:j,verticalAnchor:"middle"},T):o==="insideTop"?$t({x:u+l/2,y:f+m,textAnchor:"middle",verticalAnchor:b},T):o==="insideBottom"?$t({x:u+l/2,y:f+d-m,textAnchor:"middle",verticalAnchor:g},T):o==="insideTopLeft"?$t({x:u+w,y:f+m,textAnchor:O,verticalAnchor:b},T):o==="insideTopRight"?$t({x:u+l-w,y:f+m,textAnchor:j,verticalAnchor:b},T):o==="insideBottomLeft"?$t({x:u+w,y:f+d-m,textAnchor:O,verticalAnchor:g},T):o==="insideBottomRight"?$t({x:u+l-w,y:f+d-m,textAnchor:j,verticalAnchor:g},T):Ws(o)&&(ge(o.x)||$o(o.x))&&(ge(o.y)||$o(o.y))?$t({x:u+fr(o.x,l),y:f+fr(o.y,d),textAnchor:"end",verticalAnchor:"end"},T):$t({x:u+l/2,y:f+d/2,textAnchor:"middle",verticalAnchor:"middle"},T)},yX=function(t){return"cx"in t&&ge(t.cx)};function Vt(e){var t=e.offset,r=t===void 0?5:t,n=lX(e,rX),i=$t({offset:r},n),o=i.viewBox,s=i.position,u=i.value,f=i.children,l=i.content,d=i.className,p=d===void 0?"":d,m=i.textBreakAll;if(!o||Ue(u)&&Ue(f)&&!_.isValidElement(l)&&!ze(l))return null;if(_.isValidElement(l))return _.cloneElement(l,i);var g;if(ze(l)){if(g=_.createElement(l,i),_.isValidElement(g))return g}else g=hX(i);var b=yX(o),y=Le(i,!0);if(b&&(s==="insideStart"||s==="insideEnd"||s==="end"))return mX(i,g,y);var w=b?vX(i):gX(i);return F.createElement(Go,Fc({className:We("recharts-label",p)},y,w,{breakAll:m}),g)}Vt.displayName="Label";var QD=function(t){var r=t.cx,n=t.cy,i=t.angle,o=t.startAngle,s=t.endAngle,u=t.r,f=t.radius,l=t.innerRadius,d=t.outerRadius,p=t.x,m=t.y,g=t.top,b=t.left,y=t.width,w=t.height,j=t.clockWise,O=t.labelViewBox;if(O)return O;if(ge(y)&&ge(w)){if(ge(p)&&ge(m))return{x:p,y:m,width:y,height:w};if(ge(g)&&ge(b))return{x:g,y:b,width:y,height:w}}return ge(p)&&ge(m)?{x:p,y:m,width:0,height:0}:ge(r)&&ge(n)?{cx:r,cy:n,startAngle:o||i||0,endAngle:s||i||0,innerRadius:l||0,outerRadius:d||f||u||0,clockWise:j}:t.viewBox?t.viewBox:{}},xX=function(t,r){return t?t===!0?F.createElement(Vt,{key:"label-implicit",viewBox:r}):Ft(t)?F.createElement(Vt,{key:"label-implicit",viewBox:r,value:t}):_.isValidElement(t)?t.type===Vt?_.cloneElement(t,{key:"label-implicit",viewBox:r}):F.createElement(Vt,{key:"label-implicit",content:t,viewBox:r}):ze(t)?F.createElement(Vt,{key:"label-implicit",content:t,viewBox:r}):Ws(t)?F.createElement(Vt,Fc({viewBox:r},t,{key:"label-implicit"})):null:null},bX=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=QD(t),s=Wr(i,Vt).map(function(f,l){return _.cloneElement(f,{viewBox:r||o,key:"label-".concat(l)})});if(!n)return s;var u=xX(t.label,r||o);return[u].concat(nX(s))};Vt.parseViewBox=QD;Vt.renderCallByParent=bX;var Hx,bN;function wX(){if(bN)return Hx;bN=1;function e(t){var r=t==null?0:t.length;return r?t[r-1]:void 0}return Hx=e,Hx}var SX=wX();const _X=ot(SX);function zc(e){"@babel/helpers - typeof";return zc=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},zc(e)}var jX=["valueAccessor"],OX=["data","dataKey","clockWise","id","textBreakAll"];function EX(e){return NX(e)||CX(e)||AX(e)||PX()}function PX(){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 AX(e,t){if(e){if(typeof e=="string")return O1(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 O1(e,t)}}function CX(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function NX(e){if(Array.isArray(e))return O1(e)}function O1(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 MX(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 IX=function(t){return Array.isArray(t.value)?_X(t.value):t.value};function wi(e){var t=e.valueAccessor,r=t===void 0?IX:t,n=_N(e,jX),i=n.data,o=n.dataKey,s=n.clockWise,u=n.id,f=n.textBreakAll,l=_N(n,OX);return!i||!i.length?null:F.createElement(rt,{className:"recharts-label-list"},i.map(function(d,p){var m=Ue(o)?r(d,p):Bt(d&&d.payload,o),g=Ue(u)?{}:{id:"".concat(u,"-").concat(p)};return F.createElement(Vt,Ah({},Le(d,!0),l,g,{parentViewBox:d.parentViewBox,value:m,textBreakAll:f,viewBox:Vt.parseViewBox(Ue(s)?d:SN(SN({},d),{},{clockWise:s})),key:"label-".concat(p),index:p}))}))}wi.displayName="LabelList";function DX(e,t){return e?e===!0?F.createElement(wi,{key:"labelList-implicit",data:t}):F.isValidElement(e)||ze(e)?F.createElement(wi,{key:"labelList-implicit",data:t,content:e}):Ws(e)?F.createElement(wi,Ah({data:t},e,{key:"labelList-implicit"})):null:null}function LX(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=Wr(n,wi).map(function(s,u){return _.cloneElement(s,{data:t,key:"labelList-".concat(u)})});if(!r)return i;var o=DX(e.label,t);return[o].concat(EX(i))}wi.renderCallByParent=LX;function qc(e){"@babel/helpers - typeof";return qc=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},qc(e)}function E1(){return E1=Object.assign?Object.assign.bind():function(e){for(var t=1;t180),",").concat(+(s>l),`,
- `).concat(p.x,",").concat(p.y,`
- `);if(i>0){var g=mt(r,n,i,s),b=mt(r,n,i,l);m+="L ".concat(b.x,",").concat(b.y,`
- A `).concat(i,",").concat(i,`,0,
- `).concat(+(Math.abs(f)>180),",").concat(+(s<=l),`,
- `).concat(g.x,",").concat(g.y," Z")}else m+="L ".concat(r,",").concat(n," Z");return m},qX=function(t){var r=t.cx,n=t.cy,i=t.innerRadius,o=t.outerRadius,s=t.cornerRadius,u=t.forceCornerRadius,f=t.cornerIsExternal,l=t.startAngle,d=t.endAngle,p=ur(d-l),m=Gf({cx:r,cy:n,radius:o,angle:l,sign:p,cornerRadius:s,cornerIsExternal:f}),g=m.circleTangency,b=m.lineTangency,y=m.theta,w=Gf({cx:r,cy:n,radius:o,angle:d,sign:-p,cornerRadius:s,cornerIsExternal:f}),j=w.circleTangency,O=w.lineTangency,E=w.theta,N=f?Math.abs(l-d):Math.abs(l-d)-y-E;if(N<0)return u?"M ".concat(b.x,",").concat(b.y,`
- a`).concat(s,",").concat(s,",0,0,1,").concat(s*2,`,0
- a`).concat(s,",").concat(s,",0,0,1,").concat(-s*2,`,0
- `):ZD({cx:r,cy:n,innerRadius:i,outerRadius:o,startAngle:l,endAngle:d});var A="M ".concat(b.x,",").concat(b.y,`
- A`).concat(s,",").concat(s,",0,0,").concat(+(p<0),",").concat(g.x,",").concat(g.y,`
- A`).concat(o,",").concat(o,",0,").concat(+(N>180),",").concat(+(p<0),",").concat(j.x,",").concat(j.y,`
- A`).concat(s,",").concat(s,",0,0,").concat(+(p<0),",").concat(O.x,",").concat(O.y,`
- `);if(i>0){var C=Gf({cx:r,cy:n,radius:i,angle:l,sign:p,isExternal:!0,cornerRadius:s,cornerIsExternal:f}),T=C.circleTangency,R=C.lineTangency,I=C.theta,z=Gf({cx:r,cy:n,radius:i,angle:d,sign:-p,isExternal:!0,cornerRadius:s,cornerIsExternal:f}),$=z.circleTangency,L=z.lineTangency,U=z.theta,W=f?Math.abs(l-d):Math.abs(l-d)-I-U;if(W<0&&s===0)return"".concat(A,"L").concat(r,",").concat(n,"Z");A+="L".concat(L.x,",").concat(L.y,`
- A`).concat(s,",").concat(s,",0,0,").concat(+(p<0),",").concat($.x,",").concat($.y,`
- A`).concat(i,",").concat(i,",0,").concat(+(W>180),",").concat(+(p>0),",").concat(T.x,",").concat(T.y,`
- A`).concat(s,",").concat(s,",0,0,").concat(+(p<0),",").concat(R.x,",").concat(R.y,"Z")}else A+="L".concat(r,",").concat(n,"Z");return A},UX={cx:0,cy:0,innerRadius:0,outerRadius:0,startAngle:0,endAngle:0,cornerRadius:0,forceCornerRadius:!1,cornerIsExternal:!1},JD=function(t){var r=ON(ON({},UX),t),n=r.cx,i=r.cy,o=r.innerRadius,s=r.outerRadius,u=r.cornerRadius,f=r.forceCornerRadius,l=r.cornerIsExternal,d=r.startAngle,p=r.endAngle,m=r.className;if(s0&&Math.abs(d-p)<360?w=qX({cx:n,cy:i,innerRadius:o,outerRadius:s,cornerRadius:Math.min(y,b/2),forceCornerRadius:f,cornerIsExternal:l,startAngle:d,endAngle:p}):w=ZD({cx:n,cy:i,innerRadius:o,outerRadius:s,startAngle:d,endAngle:p}),F.createElement("path",E1({},Le(r,!0),{className:g,d:w,role:"img"}))};function Uc(e){"@babel/helpers - typeof";return Uc=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Uc(e)}function P1(){return P1=Object.assign?Object.assign.bind():function(e){for(var t=1;ttY.call(e,t));function ca(e,t){return e===t||!e&&!t&&e!==e&&t!==t}const iY="__v",oY="__o",aY="_owner",{getOwnPropertyDescriptor:RN,keys:MN}=Object;function sY(e,t){return e.byteLength===t.byteLength&&Nh(new Uint8Array(e),new Uint8Array(t))}function lY(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 cY(e,t){return e.byteLength===t.byteLength&&Nh(new Uint8Array(e.buffer,e.byteOffset,e.byteLength),new Uint8Array(t.buffer,t.byteOffset,t.byteLength))}function uY(e,t){return ca(e.getTime(),t.getTime())}function fY(e,t){return e.name===t.name&&e.message===t.message&&e.cause===t.cause&&e.stack===t.stack}function dY(e,t){return e===t}function IN(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 s,u,f=0;for(;(s=o.next())&&!s.done;){const l=t.entries();let d=!1,p=0;for(;(u=l.next())&&!u.done;){if(i[p]){p++;continue}const m=s.value,g=u.value;if(r.equals(m[0],g[0],f,p,e,t,r)&&r.equals(m[1],g[1],m[0],g[0],e,t,r)){d=i[p]=!0;break}p++}if(!d)return!1;f++}return!0}const hY=ca;function pY(e,t,r){const n=MN(e);let i=n.length;if(MN(t).length!==i)return!1;for(;i-- >0;)if(!eL(e,t,r,n[i]))return!1;return!0}function Ql(e,t,r){const n=kN(e);let i=n.length;if(kN(t).length!==i)return!1;let o,s,u;for(;i-- >0;)if(o=n[i],!eL(e,t,r,o)||(s=RN(e,o),u=RN(t,o),(s||u)&&(!s||!u||s.configurable!==u.configurable||s.enumerable!==u.enumerable||s.writable!==u.writable)))return!1;return!0}function mY(e,t){return ca(e.valueOf(),t.valueOf())}function vY(e,t){return e.source===t.source&&e.flags===t.flags}function DN(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 s,u;for(;(s=o.next())&&!s.done;){const f=t.values();let l=!1,d=0;for(;(u=f.next())&&!u.done;){if(!i[d]&&r.equals(s.value,u.value,s.value,u.value,e,t,r)){l=i[d]=!0;break}d++}if(!l)return!1}return!0}function Nh(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 gY(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 eL(e,t,r,n){return(n===aY||n===oY||n===iY)&&(e.$$typeof||t.$$typeof)?!0:nY(t,n)&&r.equals(e[n],t[n],n,n,e,t,r)}const yY="[object ArrayBuffer]",xY="[object Arguments]",bY="[object Boolean]",wY="[object DataView]",SY="[object Date]",_Y="[object Error]",jY="[object Map]",OY="[object Number]",EY="[object Object]",PY="[object RegExp]",AY="[object Set]",CY="[object String]",NY={"[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},TY="[object URL]",kY=Object.prototype.toString;function RY({areArrayBuffersEqual:e,areArraysEqual:t,areDataViewsEqual:r,areDatesEqual:n,areErrorsEqual:i,areFunctionsEqual:o,areMapsEqual:s,areNumbersEqual:u,areObjectsEqual:f,arePrimitiveWrappersEqual:l,areRegExpsEqual:d,areSetsEqual:p,areTypedArraysEqual:m,areUrlsEqual:g,unknownTagComparators:b}){return function(w,j,O){if(w===j)return!0;if(w==null||j==null)return!1;const E=typeof w;if(E!==typeof j)return!1;if(E!=="object")return E==="number"?u(w,j,O):E==="function"?o(w,j,O):!1;const N=w.constructor;if(N!==j.constructor)return!1;if(N===Object)return f(w,j,O);if(Array.isArray(w))return t(w,j,O);if(N===Date)return n(w,j,O);if(N===RegExp)return d(w,j,O);if(N===Map)return s(w,j,O);if(N===Set)return p(w,j,O);const A=kY.call(w);if(A===SY)return n(w,j,O);if(A===PY)return d(w,j,O);if(A===jY)return s(w,j,O);if(A===AY)return p(w,j,O);if(A===EY)return typeof w.then!="function"&&typeof j.then!="function"&&f(w,j,O);if(A===TY)return g(w,j,O);if(A===_Y)return i(w,j,O);if(A===xY)return f(w,j,O);if(NY[A])return m(w,j,O);if(A===yY)return e(w,j,O);if(A===wY)return r(w,j,O);if(A===bY||A===OY||A===CY)return l(w,j,O);if(b){let C=b[A];if(!C){const T=rY(w);T&&(C=b[T])}if(C)return C(w,j,O)}return!1}}function MY({circular:e,createCustomConfig:t,strict:r}){let n={areArrayBuffersEqual:sY,areArraysEqual:r?Ql:lY,areDataViewsEqual:cY,areDatesEqual:uY,areErrorsEqual:fY,areFunctionsEqual:dY,areMapsEqual:r?Xx(IN,Ql):IN,areNumbersEqual:hY,areObjectsEqual:r?Ql:pY,arePrimitiveWrappersEqual:mY,areRegExpsEqual:vY,areSetsEqual:r?Xx(DN,Ql):DN,areTypedArraysEqual:r?Xx(Nh,Ql):Nh,areUrlsEqual:gY,unknownTagComparators:void 0};if(t&&(n=Object.assign({},n,t(n))),e){const i=Xf(n.areArraysEqual),o=Xf(n.areMapsEqual),s=Xf(n.areObjectsEqual),u=Xf(n.areSetsEqual);n=Object.assign({},n,{areArraysEqual:i,areMapsEqual:o,areObjectsEqual:s,areSetsEqual:u})}return n}function IY(e){return function(t,r,n,i,o,s,u){return e(t,r,u)}}function DY({circular:e,comparator:t,createState:r,equals:n,strict:i}){if(r)return function(u,f){const{cache:l=e?new WeakMap:void 0,meta:d}=r();return t(u,f,{cache:l,equals:n,meta:d,strict:i})};if(e)return function(u,f){return t(u,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(u,f){return t(u,f,o)}}const LY=fo();fo({strict:!0});fo({circular:!0});fo({circular:!0,strict:!0});fo({createInternalComparator:()=>ca});fo({strict:!0,createInternalComparator:()=>ca});fo({circular:!0,createInternalComparator:()=>ca});fo({circular:!0,createInternalComparator:()=>ca,strict:!0});function fo(e={}){const{circular:t=!1,createInternalComparator:r,createState:n,strict:i=!1}=e,o=MY(e),s=RY(o),u=r?r(s):IY(s);return DY({circular:t,comparator:s,createState:n,equals:u,strict:i})}function $Y(e){typeof requestAnimationFrame<"u"&&requestAnimationFrame(e)}function LN(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):$Y(i)};requestAnimationFrame(n)}function A1(e){"@babel/helpers - typeof";return A1=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},A1(e)}function BY(e){return UY(e)||qY(e)||zY(e)||FY()}function FY(){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 zY(e,t){if(e){if(typeof e=="string")return $N(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 $N(e,t)}}function $N(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:j<0?0:j},y=function(j){for(var O=j>1?1:j,E=O,N=0;N<8;++N){var A=p(E)-O,C=g(E);if(Math.abs(A-O)| 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,s=t.dt,u=s===void 0?17:s,f=function(d,p,m){var g=-(d-p)*n,b=m*o,y=m+(g-b)*u/1e3,w=m*u/1e3+d;return Math.abs(w-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 bQ(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 Yx(e){return jQ(e)||_Q(e)||SQ(e)||wQ()}function wQ(){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 SQ(e,t){if(e){if(typeof e=="string")return R1(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 R1(e,t)}}function _Q(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function jQ(e){if(Array.isArray(e))return R1(e)}function R1(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 Rh(e){return Rh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Rh(e)}var Zn=(function(e){CQ(r,e);var t=NQ(r);function r(n,i){var o;OQ(this,r),o=t.call(this,n,i);var s=o.props,u=s.isActive,f=s.attributeName,l=s.from,d=s.to,p=s.steps,m=s.children,g=s.duration;if(o.handleStyleChange=o.handleStyleChange.bind(D1(o)),o.changeStyle=o.changeStyle.bind(D1(o)),!u||g<=0)return o.state={style:{}},typeof m=="function"&&(o.state={style:d}),I1(o);if(p&&p.length)o.state={style:p[0].style};else if(l){if(typeof m=="function")return o.state={style:l},I1(o);o.state={style:f?sc({},f,l):l}}else o.state={style:{}};return o}return PQ(r,[{key:"componentDidMount",value:function(){var i=this.props,o=i.isActive,s=i.canBegin;this.mounted=!0,!(!o||!s)&&this.runAnimation(this.props)}},{key:"componentDidUpdate",value:function(i){var o=this.props,s=o.isActive,u=o.canBegin,f=o.attributeName,l=o.shouldReAnimate,d=o.to,p=o.from,m=this.state.style;if(u){if(!s){var g={style:f?sc({},f,d):d};this.state&&m&&(f&&m[f]!==d||!f&&m!==d)&&this.setState(g);return}if(!(LY(i.to,d)&&i.canBegin&&i.isActive)){var b=!i.canBegin||!i.isActive;this.manager&&this.manager.stop(),this.stopJSAnimation&&this.stopJSAnimation();var y=b||l?p:i.to;if(this.state&&m){var w={style:f?sc({},f,y):y};(f&&m[f]!==y||!f&&m!==y)&&this.setState(w)}this.runAnimation(wn(wn({},this.props),{},{from:y,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,s=i.from,u=i.to,f=i.duration,l=i.easing,d=i.begin,p=i.onAnimationEnd,m=i.onAnimationStart,g=gQ(s,u,aQ(l),f,this.changeStyle),b=function(){o.stopJSAnimation=g()};this.manager.start([m,d,b,f,p])}},{key:"runStepAnimation",value:function(i){var o=this,s=i.steps,u=i.begin,f=i.onAnimationStart,l=s[0],d=l.style,p=l.duration,m=p===void 0?0:p,g=function(y,w,j){if(j===0)return y;var O=w.duration,E=w.easing,N=E===void 0?"ease":E,A=w.style,C=w.properties,T=w.onAnimationEnd,R=j>0?s[j-1]:w,I=C||Object.keys(A);if(typeof N=="function"||N==="spring")return[].concat(Yx(y),[o.runJSAnimation.bind(o,{from:R.style,to:A,duration:O,easing:N}),O]);var z=zN(I,O,N),$=wn(wn(wn({},R.style),A),{},{transition:z});return[].concat(Yx(y),[$,O,T]).filter(KY)};return this.manager.start([f].concat(Yx(s.reduce(g,[d,Math.max(m,u)])),[i.onAnimationEnd]))}},{key:"runAnimation",value:function(i){this.manager||(this.manager=WY());var o=i.begin,s=i.duration,u=i.attributeName,f=i.to,l=i.easing,d=i.onAnimationStart,p=i.onAnimationEnd,m=i.steps,g=i.children,b=this.manager;if(this.unSubscribe=b.subscribe(this.handleStyleChange),typeof l=="function"||typeof g=="function"||l==="spring"){this.runJSAnimation(i);return}if(m.length>1){this.runStepAnimation(i);return}var y=u?sc({},u,f):f,w=zN(Object.keys(y),s,l);b.start([d,o,wn(wn({},y),{},{transition:w}),s,p])}},{key:"render",value:function(){var i=this.props,o=i.children;i.begin;var s=i.duration;i.attributeName,i.easing;var u=i.isActive;i.steps,i.from,i.to,i.canBegin,i.onAnimationEnd,i.shouldReAnimate,i.onAnimationReStart;var f=xQ(i,yQ),l=_.Children.count(o),d=this.state.style;if(typeof o=="function")return o(d);if(!u||l===0||s<=0)return o;var p=function(g){var b=g.props,y=b.style,w=y===void 0?{}:y,j=b.className,O=_.cloneElement(g,wn(wn({},f),{},{style:wn(wn({},w),d),className:j}));return O};return l===1?p(_.Children.only(o)):F.createElement("div",null,_.Children.map(o,function(m){return p(m)}))}}]),r})(_.PureComponent);Zn.displayName="Animate";Zn.defaultProps={begin:0,duration:1e3,from:"",to:"",attributeName:"",easing:"ease",isActive:!0,canBegin:!0,steps:[],onAnimationEnd:function(){},onAnimationStart:function(){}};Zn.propTypes={from:st.oneOfType([st.object,st.string]),to:st.oneOfType([st.object,st.string]),attributeName:st.string,duration:st.number,begin:st.number,easing:st.oneOfType([st.string,st.func]),steps:st.arrayOf(st.shape({duration:st.number.isRequired,style:st.object.isRequired,easing:st.oneOfType([st.oneOf(["ease","ease-in","ease-out","ease-in-out","linear"]),st.func]),properties:st.arrayOf("string"),onAnimationEnd:st.func})),children:st.oneOfType([st.node,st.func]),isActive:st.bool,canBegin:st.bool,onAnimationEnd:st.func,shouldReAnimate:st.bool,onAnimationStart:st.func,onAnimationReStart:st.func};function Vc(e){"@babel/helpers - typeof";return Vc=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Vc(e)}function Mh(){return Mh=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,l=i>=0&&n>=0||i<0&&n<0?1:0,d;if(s>0&&o instanceof Array){for(var p=[0,0,0,0],m=0,g=4;ms?s:o[m];d="M".concat(t,",").concat(r+u*p[0]),p[0]>0&&(d+="A ".concat(p[0],",").concat(p[0],",0,0,").concat(l,",").concat(t+f*p[0],",").concat(r)),d+="L ".concat(t+n-f*p[1],",").concat(r),p[1]>0&&(d+="A ".concat(p[1],",").concat(p[1],",0,0,").concat(l,`,
- `).concat(t+n,",").concat(r+u*p[1])),d+="L ".concat(t+n,",").concat(r+i-u*p[2]),p[2]>0&&(d+="A ".concat(p[2],",").concat(p[2],",0,0,").concat(l,`,
- `).concat(t+n-f*p[2],",").concat(r+i)),d+="L ".concat(t+f*p[3],",").concat(r+i),p[3]>0&&(d+="A ".concat(p[3],",").concat(p[3],",0,0,").concat(l,`,
- `).concat(t,",").concat(r+i-u*p[3])),d+="Z"}else if(s>0&&o===+o&&o>0){var b=Math.min(s,o);d="M ".concat(t,",").concat(r+u*b,`
- A `).concat(b,",").concat(b,",0,0,").concat(l,",").concat(t+f*b,",").concat(r,`
- L `).concat(t+n-f*b,",").concat(r,`
- A `).concat(b,",").concat(b,",0,0,").concat(l,",").concat(t+n,",").concat(r+u*b,`
- L `).concat(t+n,",").concat(r+i-u*b,`
- A `).concat(b,",").concat(b,",0,0,").concat(l,",").concat(t+n-f*b,",").concat(r+i,`
- L `).concat(t+f*b,",").concat(r+i,`
- A `).concat(b,",").concat(b,",0,0,").concat(l,",").concat(t,",").concat(r+i-u*b," Z")}else d="M ".concat(t,",").concat(r," h ").concat(n," v ").concat(i," h ").concat(-n," Z");return d},FQ=function(t,r){if(!t||!r)return!1;var n=t.x,i=t.y,o=r.x,s=r.y,u=r.width,f=r.height;if(Math.abs(u)>0&&Math.abs(f)>0){var l=Math.min(o,o+u),d=Math.max(o,o+u),p=Math.min(s,s+f),m=Math.max(s,s+f);return n>=l&&n<=d&&i>=p&&i<=m}return!1},zQ={x:0,y:0,width:0,height:0,radius:0,isAnimationActive:!1,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:"ease"},TS=function(t){var r=XN(XN({},zQ),t),n=_.useRef(),i=_.useState(-1),o=kQ(i,2),s=o[0],u=o[1];_.useEffect(function(){if(n.current&&n.current.getTotalLength)try{var N=n.current.getTotalLength();N&&u(N)}catch{}},[]);var f=r.x,l=r.y,d=r.width,p=r.height,m=r.radius,g=r.className,b=r.animationEasing,y=r.animationDuration,w=r.animationBegin,j=r.isAnimationActive,O=r.isUpdateAnimationActive;if(f!==+f||l!==+l||d!==+d||p!==+p||d===0||p===0)return null;var E=We("recharts-rectangle",g);return O?F.createElement(Zn,{canBegin:s>0,from:{width:d,height:p,x:f,y:l},to:{width:d,height:p,x:f,y:l},duration:y,animationEasing:b,isActive:O},function(N){var A=N.width,C=N.height,T=N.x,R=N.y;return F.createElement(Zn,{canBegin:s>0,from:"0px ".concat(s===-1?1:s,"px"),to:"".concat(s,"px 0px"),attributeName:"strokeDasharray",begin:w,duration:y,isActive:j,easing:b},F.createElement("path",Mh({},Le(r,!0),{className:E,d:YN(T,R,A,C,m),ref:n})))}):F.createElement("path",Mh({},Le(r,!0),{className:E,d:YN(f,l,d,p,m)}))},qQ=["points","className","baseLinePoints","connectNulls"];function Ya(){return Ya=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 WQ(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 QN(e){return KQ(e)||GQ(e)||VQ(e)||HQ()}function HQ(){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 VQ(e,t){if(e){if(typeof e=="string")return L1(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 L1(e,t)}}function GQ(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function KQ(e){if(Array.isArray(e))return L1(e)}function L1(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){ZN(n)?r[r.length-1].push(n):r[r.length-1].length>0&&r.push([])}),ZN(t[0])&&r[r.length-1].push(t[0]),r[r.length-1].length<=0&&(r=r.slice(0,-1)),r},mc=function(t,r){var n=XQ(t);r&&(n=[n.reduce(function(o,s){return[].concat(QN(o),QN(s))},[])]);var i=n.map(function(o){return o.reduce(function(s,u,f){return"".concat(s).concat(f===0?"M":"L").concat(u.x,",").concat(u.y)},"")}).join("");return n.length===1?"".concat(i,"Z"):i},YQ=function(t,r,n){var i=mc(t,n);return"".concat(i.slice(-1)==="Z"?i.slice(0,-1):i,"L").concat(mc(r.reverse(),n).slice(1))},QQ=function(t){var r=t.points,n=t.className,i=t.baseLinePoints,o=t.connectNulls,s=UQ(t,qQ);if(!r||!r.length)return null;var u=We("recharts-polygon",n);if(i&&i.length){var f=s.stroke&&s.stroke!=="none",l=YQ(r,i,o);return F.createElement("g",{className:u},F.createElement("path",Ya({},Le(s,!0),{fill:l.slice(-1)==="Z"?s.fill:"none",stroke:"none",d:l})),f?F.createElement("path",Ya({},Le(s,!0),{fill:"none",d:mc(r,o)})):null,f?F.createElement("path",Ya({},Le(s,!0),{fill:"none",d:mc(i,o)})):null)}var d=mc(r,o);return F.createElement("path",Ya({},Le(s,!0),{fill:d.slice(-1)==="Z"?s.fill:"none",className:u,d}))};function $1(){return $1=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 iZ(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 oZ=function(t,r,n,i,o,s){return"M".concat(t,",").concat(o,"v").concat(i,"M").concat(s,",").concat(r,"h").concat(n)},aZ=function(t){var r=t.x,n=r===void 0?0:r,i=t.y,o=i===void 0?0:i,s=t.top,u=s===void 0?0:s,f=t.left,l=f===void 0?0:f,d=t.width,p=d===void 0?0:d,m=t.height,g=m===void 0?0:m,b=t.className,y=nZ(t,ZQ),w=JQ({x:n,y:o,top:u,left:l,width:p,height:g},y);return!ge(n)||!ge(o)||!ge(p)||!ge(g)||!ge(u)||!ge(l)?null:F.createElement("path",B1({},Le(w,!0),{className:We("recharts-cross",b),d:oZ(n,o,p,g,u,l)}))},Qx,eT;function sZ(){if(eT)return Qx;eT=1;var e=Rp(),t=wD(),r=ri();function n(i,o){return i&&i.length?e(i,r(o,2),t):void 0}return Qx=n,Qx}var lZ=sZ();const cZ=ot(lZ);var Zx,tT;function uZ(){if(tT)return Zx;tT=1;var e=Rp(),t=ri(),r=SD();function n(i,o){return i&&i.length?e(i,t(o,2),r):void 0}return Zx=n,Zx}var fZ=uZ();const dZ=ot(fZ);var hZ=["cx","cy","angle","ticks","axisLine"],pZ=["ticks","tick","angle","tickFormatter","stroke"];function Ss(e){"@babel/helpers - typeof";return Ss=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},Ss(e)}function vc(){return vc=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 mZ(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 vZ(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function iT(e,t){for(var r=0;rsT?s=i==="outer"?"start":"end":o<-sT?s=i==="outer"?"end":"start":s="middle",s}},{key:"renderAxisLine",value:function(){var n=this.props,i=n.cx,o=n.cy,s=n.radius,u=n.axisLine,f=n.axisLineType,l=ko(ko({},Le(this.props,!1)),{},{fill:"none"},Le(u,!1));if(f==="circle")return F.createElement($p,Lo({className:"recharts-polar-angle-axis-line"},l,{cx:i,cy:o,r:s}));var d=this.props.ticks,p=d.map(function(m){return mt(i,o,s,m.coordinate)});return F.createElement(QQ,Lo({className:"recharts-polar-angle-axis-line"},l,{points:p}))}},{key:"renderTicks",value:function(){var n=this,i=this.props,o=i.ticks,s=i.tick,u=i.tickLine,f=i.tickFormatter,l=i.stroke,d=Le(this.props,!1),p=Le(s,!1),m=ko(ko({},d),{},{fill:"none"},Le(u,!1)),g=o.map(function(b,y){var w=n.getTickLineCoord(b),j=n.getTickTextAnchor(b),O=ko(ko(ko({textAnchor:j},d),{},{stroke:"none",fill:l},p),{},{index:y,payload:b,x:w.x2,y:w.y2});return F.createElement(rt,Lo({className:We("recharts-polar-angle-axis-tick",YD(s)),key:"tick-".concat(b.coordinate)},Vo(n.props,b,y)),u&&F.createElement("line",Lo({className:"recharts-polar-angle-axis-tick-line"},m,w)),s&&t.renderTickItem(s,O,f?f(b.value,y):b.value))});return F.createElement(rt,{className:"recharts-polar-angle-axis-ticks"},g)}},{key:"render",value:function(){var n=this.props,i=n.ticks,o=n.radius,s=n.axisLine;return o<=0||!i||!i.length?null:F.createElement(rt,{className:We("recharts-polar-angle-axis",this.props.className)},s&&this.renderAxisLine(),this.renderTicks())}}],[{key:"renderTickItem",value:function(n,i,o){var s;return F.isValidElement(n)?s=F.cloneElement(n,i):ze(n)?s=n(i):s=F.createElement(Go,Lo({},i,{className:"recharts-polar-angle-axis-tick-value"}),o),s}}])})(_.PureComponent);zp(qp,"displayName","PolarAngleAxis");zp(qp,"axisType","angleAxis");zp(qp,"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 Jx,lT;function TZ(){if(lT)return Jx;lT=1;var e=wI(),t=e(Object.getPrototypeOf,Object);return Jx=t,Jx}var eb,cT;function kZ(){if(cT)return eb;cT=1;var e=Ai(),t=TZ(),r=Ci(),n="[object Object]",i=Function.prototype,o=Object.prototype,s=i.toString,u=o.hasOwnProperty,f=s.call(Object);function l(d){if(!r(d)||e(d)!=n)return!1;var p=t(d);if(p===null)return!0;var m=u.call(p,"constructor")&&p.constructor;return typeof m=="function"&&m instanceof m&&s.call(m)==f}return eb=l,eb}var RZ=kZ();const MZ=ot(RZ);var tb,uT;function IZ(){if(uT)return tb;uT=1;var e=Ai(),t=Ci(),r="[object Boolean]";function n(i){return i===!0||i===!1||t(i)&&e(i)==r}return tb=n,tb}var DZ=IZ();const LZ=ot(DZ);function Kc(e){"@babel/helpers - typeof";return Kc=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},Kc(e)}function Lh(){return Lh=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:l},to:{upperWidth:d,lowerWidth:p,height:m,x:f,y:l},duration:y,animationEasing:b,isActive:j},function(E){var N=E.upperWidth,A=E.lowerWidth,C=E.height,T=E.x,R=E.y;return F.createElement(Zn,{canBegin:s>0,from:"0px ".concat(s===-1?1:s,"px"),to:"".concat(s,"px 0px"),attributeName:"strokeDasharray",begin:w,duration:y,easing:b},F.createElement("path",Lh({},Le(r,!0),{className:O,d:pT(T,R,N,A,C),ref:n})))}):F.createElement("g",null,F.createElement("path",Lh({},Le(r,!0),{className:O,d:pT(f,l,d,p,m)})))},KZ=["option","shapeType","propTransformer","activeClassName","isActive"];function Xc(e){"@babel/helpers - typeof";return Xc=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},Xc(e)}function XZ(e,t){if(e==null)return{};var r=YZ(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 YZ(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 mT(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 $h(e){for(var t=1;t0?Ur(E,"paddingAngle",0):0;if(A){var T=Fr(A.endAngle-A.startAngle,E.endAngle-E.startAngle),R=ht(ht({},E),{},{startAngle:O+C,endAngle:O+T(y)+C});w.push(R),O=R.endAngle}else{var I=E.endAngle,z=E.startAngle,$=Fr(0,I-z),L=$(y),U=ht(ht({},E),{},{startAngle:O+C,endAngle:O+L+C});w.push(U),O=U.endAngle}}),F.createElement(rt,null,n.renderSectorsStatically(w))})}},{key:"attachKeyboardHandlers",value:function(n){var i=this;n.onkeydown=function(o){if(!o.altKey)switch(o.key){case"ArrowLeft":{var s=++i.state.sectorToFocus%i.sectorRefs.length;i.sectorRefs[s].focus(),i.setState({sectorToFocus:s});break}case"ArrowRight":{var u=--i.state.sectorToFocus<0?i.sectorRefs.length-1:i.state.sectorToFocus%i.sectorRefs.length;i.sectorRefs[u].focus(),i.setState({sectorToFocus:u});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,s=this.state.prevSectors;return o&&i&&i.length&&(!s||!hu(s,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,s=i.sectors,u=i.className,f=i.label,l=i.cx,d=i.cy,p=i.innerRadius,m=i.outerRadius,g=i.isAnimationActive,b=this.state.isAnimationFinished;if(o||!s||!s.length||!ge(l)||!ge(d)||!ge(p)||!ge(m))return null;var y=We("recharts-pie",u);return F.createElement(rt,{tabIndex:this.props.rootTabIndex,className:y,ref:function(j){n.pieRef=j}},this.renderSectors(),f&&this.renderLabels(s),Vt.renderCallByParent(this.props,null,!1),(!g||b)&&wi.renderCallByParent(this.props,s,!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?O:O-1)*f,N=w-O*g-E,A=i.reduce(function(R,I){var z=Bt(I,j,0);return R+(ge(z)?z:0)},0),C;if(A>0){var T;C=i.map(function(R,I){var z=Bt(R,j,0),$=Bt(R,d,I),L=(ge(z)?z:0)/A,U;I?U=T.endAngle+ur(y)*f*(z!==0?1:0):U=s;var W=U+ur(y)*((z!==0?g:0)+L*N),V=(U+W)/2,G=(b.innerRadius+b.outerRadius)/2,Y=[{name:$,value:z,payload:R,dataKey:j,type:m}],D=mt(b.cx,b.cy,G,V);return T=ht(ht(ht({percent:L,cornerRadius:o,name:$,tooltipPayload:Y,midAngle:V,middleRadius:G,tooltipPosition:D},R),b),{},{value:Bt(R,j),startAngle:U,endAngle:W,payload:R,paddingAngle:ur(y)*f}),T})}return ht(ht({},b),{},{sectors:C,data:i})});var rb,xT;function gJ(){if(xT)return rb;xT=1;var e=Math.ceil,t=Math.max;function r(n,i,o,s){for(var u=-1,f=t(e((i-n)/(o||1)),0),l=Array(f);f--;)l[s?f:++u]=n,n+=o;return l}return rb=r,rb}var nb,bT;function pL(){if(bT)return nb;bT=1;var e=LI(),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 nb=n,nb}var ib,wT;function yJ(){if(wT)return ib;wT=1;var e=gJ(),t=Op(),r=pL();function n(i){return function(o,s,u){return u&&typeof u!="number"&&t(o,s,u)&&(s=u=void 0),o=r(o),s===void 0?(s=o,o=0):s=r(s),u=u===void 0?o0&&n.handleDrag(i.changedTouches[0])}),Dr(n,"handleDragEnd",function(){n.setState({isTravellerMoving:!1,isSlideMoving:!1},function(){var i=n.props,o=i.endIndex,s=i.onDragEnd,u=i.startIndex;s?.({endIndex:o,startIndex:u})}),n.detachDragEndListener()}),Dr(n,"handleLeaveWrapper",function(){(n.state.isTravellerMoving||n.state.isSlideMoving)&&(n.leaveTimer=window.setTimeout(n.handleDragEnd,n.props.leaveTimeOut))}),Dr(n,"handleEnterSlideOrTraveller",function(){n.setState({isTextActive:!0})}),Dr(n,"handleLeaveSlideOrTraveller",function(){n.setState({isTextActive:!1})}),Dr(n,"handleSlideDragStart",function(i){var o=PT(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 NJ(t,e),EJ(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,s=this.state.scaleValues,u=this.props,f=u.gap,l=u.data,d=l.length-1,p=Math.min(i,o),m=Math.max(i,o),g=t.getIndexInRange(s,p),b=t.getIndexInRange(s,m);return{startIndex:g-g%f,endIndex:b===d?d:b-b%f}}},{key:"getTextOfTick",value:function(n){var i=this.props,o=i.data,s=i.tickFormatter,u=i.dataKey,f=Bt(o[n],u,n);return ze(s)?s(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,s=i.startX,u=i.endX,f=this.props,l=f.x,d=f.width,p=f.travellerWidth,m=f.startIndex,g=f.endIndex,b=f.onChange,y=n.pageX-o;y>0?y=Math.min(y,l+d-p-u,l+d-p-s):y<0&&(y=Math.max(y,l-s,l-u));var w=this.getIndex({startX:s+y,endX:u+y});(w.startIndex!==m||w.endIndex!==g)&&b&&b(w),this.setState({startX:s+y,endX:u+y,slideMoveStartX:n.pageX})}},{key:"handleTravellerDragStart",value:function(n,i){var o=PT(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,s=i.movingTravellerId,u=i.endX,f=i.startX,l=this.state[s],d=this.props,p=d.x,m=d.width,g=d.travellerWidth,b=d.onChange,y=d.gap,w=d.data,j={startX:this.state.startX,endX:this.state.endX},O=n.pageX-o;O>0?O=Math.min(O,p+m-g-l):O<0&&(O=Math.max(O,p-l)),j[s]=l+O;var E=this.getIndex(j),N=E.startIndex,A=E.endIndex,C=function(){var R=w.length-1;return s==="startX"&&(u>f?N%y===0:A%y===0)||uf?A%y===0:N%y===0)||u>f&&A===R};this.setState(Dr(Dr({},s,l+O),"brushMoveStartX",n.pageX),function(){b&&C()&&b(E)})}},{key:"handleTravellerMoveKeyboard",value:function(n,i){var o=this,s=this.state,u=s.scaleValues,f=s.startX,l=s.endX,d=this.state[i],p=u.indexOf(d);if(p!==-1){var m=p+n;if(!(m===-1||m>=u.length)){var g=u[m];i==="startX"&&g>=l||i==="endX"&&g<=f||this.setState(Dr({},i,g),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,s=n.width,u=n.height,f=n.fill,l=n.stroke;return F.createElement("rect",{stroke:l,fill:f,x:i,y:o,width:s,height:u})}},{key:"renderPanorama",value:function(){var n=this.props,i=n.x,o=n.y,s=n.width,u=n.height,f=n.data,l=n.children,d=n.padding,p=_.Children.only(l);return p?F.cloneElement(p,{x:i,y:o,width:s,height:u,margin:d,compact:!0,data:f}):null}},{key:"renderTravellerLayer",value:function(n,i){var o,s,u=this,f=this.props,l=f.y,d=f.travellerWidth,p=f.height,m=f.traveller,g=f.ariaLabel,b=f.data,y=f.startIndex,w=f.endIndex,j=Math.max(n,this.props.x),O=ab(ab({},Le(this.props,!1)),{},{x:j,y:l,width:d,height:p}),E=g||"Min value: ".concat((o=b[y])===null||o===void 0?void 0:o.name,", Max value: ").concat((s=b[w])===null||s===void 0?void 0:s.name);return F.createElement(rt,{tabIndex:0,role:"slider","aria-label":E,"aria-valuenow":n,className:"recharts-brush-traveller",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.travellerDragStartHandlers[i],onTouchStart:this.travellerDragStartHandlers[i],onKeyDown:function(A){["ArrowLeft","ArrowRight"].includes(A.key)&&(A.preventDefault(),A.stopPropagation(),u.handleTravellerMoveKeyboard(A.key==="ArrowRight"?1:-1,i))},onFocus:function(){u.setState({isTravellerFocused:!0})},onBlur:function(){u.setState({isTravellerFocused:!1})},style:{cursor:"col-resize"}},t.renderTraveller(m,O))}},{key:"renderSlide",value:function(n,i){var o=this.props,s=o.y,u=o.height,f=o.stroke,l=o.travellerWidth,d=Math.min(n,i)+l,p=Math.max(Math.abs(i-n)-l,0);return F.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:d,y:s,width:p,height:u})}},{key:"renderText",value:function(){var n=this.props,i=n.startIndex,o=n.endIndex,s=n.y,u=n.height,f=n.travellerWidth,l=n.stroke,d=this.state,p=d.startX,m=d.endX,g=5,b={pointerEvents:"none",fill:l};return F.createElement(rt,{className:"recharts-brush-texts"},F.createElement(Go,zh({textAnchor:"end",verticalAnchor:"middle",x:Math.min(p,m)-g,y:s+u/2},b),this.getTextOfTick(i)),F.createElement(Go,zh({textAnchor:"start",verticalAnchor:"middle",x:Math.max(p,m)+f+g,y:s+u/2},b),this.getTextOfTick(o)))}},{key:"render",value:function(){var n=this.props,i=n.data,o=n.className,s=n.children,u=n.x,f=n.y,l=n.width,d=n.height,p=n.alwaysShowText,m=this.state,g=m.startX,b=m.endX,y=m.isTextActive,w=m.isSlideMoving,j=m.isTravellerMoving,O=m.isTravellerFocused;if(!i||!i.length||!ge(u)||!ge(f)||!ge(l)||!ge(d)||l<=0||d<=0)return null;var E=We("recharts-brush",o),N=F.Children.count(s)===1,A=jJ("userSelect","none");return F.createElement(rt,{className:E,onMouseLeave:this.handleLeaveWrapper,onTouchMove:this.handleTouchMove,style:A},this.renderBackground(),N&&this.renderPanorama(),this.renderSlide(g,b),this.renderTravellerLayer(g,"startX"),this.renderTravellerLayer(b,"endX"),(y||w||j||O||p)&&this.renderText())}}],[{key:"renderDefaultTraveller",value:function(n){var i=n.x,o=n.y,s=n.width,u=n.height,f=n.stroke,l=Math.floor(o+u/2)-1;return F.createElement(F.Fragment,null,F.createElement("rect",{x:i,y:o,width:s,height:u,fill:f,stroke:"none"}),F.createElement("line",{x1:i+1,y1:l,x2:i+s-1,y2:l,fill:"none",stroke:"#fff"}),F.createElement("line",{x1:i+1,y1:l+2,x2:i+s-1,y2:l+2,fill:"none",stroke:"#fff"}))}},{key:"renderTraveller",value:function(n,i){var o;return F.isValidElement(n)?o=F.cloneElement(n,i):ze(n)?o=n(i):o=t.renderDefaultTraveller(i),o}},{key:"getDerivedStateFromProps",value:function(n,i){var o=n.data,s=n.width,u=n.x,f=n.travellerWidth,l=n.updateId,d=n.startIndex,p=n.endIndex;if(o!==i.prevData||l!==i.prevUpdateId)return ab({prevData:o,prevTravellerWidth:f,prevUpdateId:l,prevX:u,prevWidth:s},o&&o.length?kJ({data:o,width:s,x:u,travellerWidth:f,startIndex:d,endIndex:p}):{scale:null,scaleValues:null});if(i.scale&&(s!==i.prevWidth||u!==i.prevX||f!==i.prevTravellerWidth)){i.scale.range([u,u+s-f]);var m=i.scale.domain().map(function(g){return i.scale(g)});return{prevData:o,prevTravellerWidth:f,prevUpdateId:l,prevX:u,prevWidth:s,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,s=0,u=o-1;u-s>1;){var f=Math.floor((s+u)/2);n[f]>i?u=f:s=f}return i>=n[u]?u:s}}])})(_.PureComponent);Dr(Es,"displayName","Brush");Dr(Es,"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 sb,AT;function RJ(){if(AT)return sb;AT=1;var e=nS();function t(r,n){var i;return e(r,function(o,s,u){return i=n(o,s,u),!i}),!!i}return sb=t,sb}var lb,CT;function MJ(){if(CT)return lb;CT=1;var e=pI(),t=ri(),r=RJ(),n=Er(),i=Op();function o(s,u,f){var l=n(s)?e:r;return f&&i(s,u,f)&&(u=void 0),l(s,t(u,3))}return lb=o,lb}var IJ=MJ();const DJ=ot(IJ);var Kn=function(t,r){var n=t.alwaysShow,i=t.ifOverflow;return n&&(i="extendDomain"),i===r},cb,NT;function LJ(){if(NT)return cb;NT=1;var e=kI();function t(r,n,i){n=="__proto__"&&e?e(r,n,{configurable:!0,enumerable:!0,value:i,writable:!0}):r[n]=i}return cb=t,cb}var ub,TT;function $J(){if(TT)return ub;TT=1;var e=LJ(),t=NI(),r=ri();function n(i,o){var s={};return o=r(o,3),t(i,function(u,f,l){e(s,f,o(u,f,l))}),s}return ub=n,ub}var BJ=$J();const FJ=ot(BJ);var fb,kT;function zJ(){if(kT)return fb;kT=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 YJ(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 QJ(e,t){var r=e.x,n=e.y,i=XJ(e,HJ),o="".concat(r),s=parseInt(o,10),u="".concat(n),f=parseInt(u,10),l="".concat(t.height||i.height),d=parseInt(l,10),p="".concat(t.width||i.width),m=parseInt(p,10);return Zl(Zl(Zl(Zl(Zl({},t),i),s?{x:s}:{}),f?{y:f}:{}),{},{height:d,width:m,name:t.name,radius:t.radius})}function DT(e){return F.createElement(fL,W1({shapeType:"rectangle",propTransformer:QJ,activeClassName:"recharts-active-bar"},e))}var ZJ=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=ge(n)||yq(n);return o?t(n,i):(o||Xo(),r)}},JJ=["value","background"],xL;function Ps(e){"@babel/helpers - typeof";return Ps=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},Ps(e)}function eee(e,t){if(e==null)return{};var r=tee(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 tee(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 Uh(){return Uh=Object.assign?Object.assign.bind():function(e){for(var t=1;t0&&Math.abs(V)0&&Math.abs(W)0&&(U=Math.min((te||0)-(W[ve-1]||0),U))}),Number.isFinite(U)){var V=U/L,G=y.layout==="vertical"?n.height:n.width;if(y.padding==="gap"&&(T=V*G/2),y.padding==="no-gap"){var Y=fr(t.barCategoryGap,V*G),D=V*G/2;T=D-Y-(D-Y)/G*Y}}}i==="xAxis"?R=[n.left+(E.left||0)+(T||0),n.left+n.width-(E.right||0)-(T||0)]:i==="yAxis"?R=f==="horizontal"?[n.top+n.height-(E.bottom||0),n.top+(E.top||0)]:[n.top+(E.top||0)+(T||0),n.top+n.height-(E.bottom||0)-(T||0)]:R=y.range,A&&(R=[R[1],R[0]]);var Q=UD(y,o,m),J=Q.scale,M=Q.realScaleType;J.domain(j).range(R),WD(J);var B=HD(J,Pn(Pn({},y),{},{realScaleType:M}));i==="xAxis"?($=w==="top"&&!N||w==="bottom"&&N,I=n.left,z=p[C]-$*y.height):i==="yAxis"&&($=w==="left"&&!N||w==="right"&&N,I=p[C]-$*y.width,z=n.top);var Z=Pn(Pn(Pn({},y),B),{},{realScaleType:M,x:I,y:z,scale:J,width:i==="xAxis"?n.width:y.width,height:i==="yAxis"?n.height:y.height});return Z.bandSize=Eh(Z,B),!y.hide&&i==="xAxis"?p[C]+=($?-1:1)*Z.height:y.hide||(p[C]+=($?-1:1)*Z.width),Pn(Pn({},g),{},Hp({},b,Z))},{})},jL=function(t,r){var n=t.x,i=t.y,o=r.x,s=r.y;return{x:Math.min(n,o),y:Math.min(i,s),width:Math.abs(o-n),height:Math.abs(s-i)}},dee=function(t){var r=t.x1,n=t.y1,i=t.x2,o=t.y2;return jL({x:r,y:n},{x:i,y:o})},OL=(function(){function e(t){cee(this,e),this.scale=t}return uee(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 s=this.bandwidth?this.bandwidth()/2:0;return this.scale(r)+s}case"end":{var u=this.bandwidth?this.bandwidth():0;return this.scale(r)+u}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)}}])})();Hp(OL,"EPS",1e-4);var kS=function(t){var r=Object.keys(t).reduce(function(n,i){return Pn(Pn({},n),{},Hp({},i,OL.create(t[i])))},{});return Pn(Pn({},r),{},{apply:function(i){var o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},s=o.bandAware,u=o.position;return FJ(i,function(f,l){return r[l].apply(f,{bandAware:s,position:u})})},isInRange:function(i){return yL(i,function(o,s){return r[s].isInRange(o)})}})};function hee(e){return(e%180+180)%180}var pee=function(t){var r=t.width,n=t.height,i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,o=hee(i),s=o*Math.PI/180,u=Math.atan(n/r),f=s>u&&s-1?f[l?o[d]:d]:void 0}}return pb=n,pb}var mb,qT;function vee(){if(qT)return mb;qT=1;var e=pL();function t(r){var n=e(r),i=n%1;return n===n?i?n-i:n:0}return mb=t,mb}var vb,UT;function gee(){if(UT)return vb;UT=1;var e=OI(),t=ri(),r=vee(),n=Math.max;function i(o,s,u){var f=o==null?0:o.length;if(!f)return-1;var l=u==null?0:r(u);return l<0&&(l=n(f+l,0)),e(o,t(s,3),l)}return vb=i,vb}var gb,WT;function yee(){if(WT)return gb;WT=1;var e=mee(),t=gee(),r=e(t);return gb=r,gb}var xee=yee();const bee=ot(xee);var wee=zM();const See=ot(wee);var _ee=See(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("")}),RS=_.createContext(void 0),MS=_.createContext(void 0),EL=_.createContext(void 0),PL=_.createContext({}),AL=_.createContext(void 0),CL=_.createContext(0),NL=_.createContext(0),HT=function(t){var r=t.state,n=r.xAxisMap,i=r.yAxisMap,o=r.offset,s=t.clipPathId,u=t.children,f=t.width,l=t.height,d=_ee(o);return F.createElement(RS.Provider,{value:n},F.createElement(MS.Provider,{value:i},F.createElement(PL.Provider,{value:o},F.createElement(EL.Provider,{value:d},F.createElement(AL.Provider,{value:s},F.createElement(CL.Provider,{value:l},F.createElement(NL.Provider,{value:f},u)))))))},jee=function(){return _.useContext(AL)},TL=function(t){var r=_.useContext(RS);r==null&&Xo();var n=r[t];return n==null&&Xo(),n},Oee=function(){var t=_.useContext(RS);return to(t)},Eee=function(){var t=_.useContext(MS),r=bee(t,function(n){return yL(n.domain,Number.isFinite)});return r||to(t)},kL=function(t){var r=_.useContext(MS);r==null&&Xo();var n=r[t];return n==null&&Xo(),n},Pee=function(){var t=_.useContext(EL);return t},Aee=function(){return _.useContext(PL)},IS=function(){return _.useContext(NL)},DS=function(){return _.useContext(CL)};function As(e){"@babel/helpers - typeof";return As=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},As(e)}function Cee(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Nee(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 fte(e,t){return BL(e,t+1)}function dte(e,t,r,n,i){for(var o=(n||[]).slice(),s=t.start,u=t.end,f=0,l=1,d=s,p=function(){var b=n?.[f];if(b===void 0)return{v:BL(n,l)};var y=f,w,j=function(){return w===void 0&&(w=r(b,y)),w},O=b.coordinate,E=f===0||Kh(e,O,j,d,u);E||(f=0,d=s,l+=1),E&&(d=O+e*(j()/2+i),f+=l)},m;l<=o.length;)if(m=p(),m)return m.v;return[]}function eu(e){"@babel/helpers - typeof";return eu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},eu(e)}function JT(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 ir(e){for(var t=1;t0?g.coordinate-w*e:g.coordinate})}else o[m]=g=ir(ir({},g),{},{tickCoord:g.coordinate});var j=Kh(e,g.tickCoord,y,u,f);j&&(f=g.tickCoord-e*(y()/2+i),o[m]=ir(ir({},g),{},{isShow:!0}))},d=s-1;d>=0;d--)l(d);return o}function gte(e,t,r,n,i,o){var s=(n||[]).slice(),u=s.length,f=t.start,l=t.end;if(o){var d=n[u-1],p=r(d,u-1),m=e*(d.coordinate+e*p/2-l);s[u-1]=d=ir(ir({},d),{},{tickCoord:m>0?d.coordinate-m*e:d.coordinate});var g=Kh(e,d.tickCoord,function(){return p},f,l);g&&(l=d.tickCoord-e*(p/2+i),s[u-1]=ir(ir({},d),{},{isShow:!0}))}for(var b=o?u-1:u,y=function(O){var E=s[O],N,A=function(){return N===void 0&&(N=r(E,O)),N};if(O===0){var C=e*(E.coordinate-e*A()/2-f);s[O]=E=ir(ir({},E),{},{tickCoord:C<0?E.coordinate-C*e:E.coordinate})}else s[O]=E=ir(ir({},E),{},{tickCoord:E.coordinate});var T=Kh(e,E.tickCoord,A,f,l);T&&(f=E.tickCoord+e*(A()/2+i),s[O]=ir(ir({},E),{},{isShow:!0}))},w=0;w=2?ur(i[1].coordinate-i[0].coordinate):1,j=ute(o,w,g);return f==="equidistantPreserveStart"?dte(w,j,y,i,s):(f==="preserveStart"||f==="preserveStartEnd"?m=gte(w,j,y,i,s,f==="preserveStartEnd"):m=vte(w,j,y,i,s),m.filter(function(O){return O.isShow}))}var yte=["viewBox"],xte=["viewBox"],bte=["ticks"];function Ts(e){"@babel/helpers - typeof";return Ts=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ts(e)}function Za(){return Za=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 wte(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 Ste(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function tk(e,t){for(var r=0;r0?f(this.props):f(g)),s<=0||u<=0||!b||!b.length?null:F.createElement(rt,{className:We("recharts-cartesian-axis",l),ref:function(w){n.layerReference=w}},o&&this.renderAxisLine(),this.renderTicks(b,this.state.fontSize,this.state.letterSpacing),Vt.renderCallByParent(this.props))}}],[{key:"renderTickItem",value:function(n,i,o){var s,u=We(i.className,"recharts-cartesian-axis-tick-value");return F.isValidElement(n)?s=F.cloneElement(n,Lt(Lt({},i),{},{className:u})):ze(n)?s=n(Lt(Lt({},i),{},{className:u})):s=F.createElement(Go,Za({},i,{className:"recharts-cartesian-axis-tick-value"}),o),s}}])})(_.Component);FS(Ys,"displayName","CartesianAxis");FS(Ys,"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 Cte=["x1","y1","x2","y2","key"],Nte=["offset"];function Yo(e){"@babel/helpers - typeof";return Yo=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},Yo(e)}function rk(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 or(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function Mte(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 Ite=function(t){var r=t.fill;if(!r||r==="none")return null;var n=t.fillOpacity,i=t.x,o=t.y,s=t.width,u=t.height,f=t.ry;return F.createElement("rect",{x:i,y:o,ry:f,width:s,height:u,stroke:"none",fill:r,fillOpacity:n,className:"recharts-cartesian-grid-bg"})};function qL(e,t){var r;if(F.isValidElement(e))r=F.cloneElement(e,t);else if(ze(e))r=e(t);else{var n=t.x1,i=t.y1,o=t.x2,s=t.y2,u=t.key,f=nk(t,Cte),l=Le(f,!1);l.offset;var d=nk(l,Nte);r=F.createElement("line",zo({},d,{x1:n,y1:i,x2:o,y2:s,fill:"none",key:u}))}return r}function Dte(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 s=o.map(function(u,f){var l=or(or({},e),{},{x1:t,y1:u,x2:t+r,y2:u,key:"line-".concat(f),index:f});return qL(i,l)});return F.createElement("g",{className:"recharts-cartesian-grid-horizontal"},s)}function Lte(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 s=o.map(function(u,f){var l=or(or({},e),{},{x1:u,y1:t,x2:u,y2:t+r,key:"line-".concat(f),index:f});return qL(i,l)});return F.createElement("g",{className:"recharts-cartesian-grid-vertical"},s)}function $te(e){var t=e.horizontalFill,r=e.fillOpacity,n=e.x,i=e.y,o=e.width,s=e.height,u=e.horizontalPoints,f=e.horizontal,l=f===void 0?!0:f;if(!l||!t||!t.length)return null;var d=u.map(function(m){return Math.round(m+i-i)}).sort(function(m,g){return m-g});i!==d[0]&&d.unshift(0);var p=d.map(function(m,g){var b=!d[g+1],y=b?i+s-m:d[g+1]-m;if(y<=0)return null;var w=g%t.length;return F.createElement("rect",{key:"react-".concat(g),y:m,x:n,height:y,width:o,stroke:"none",fill:t[w],fillOpacity:r,className:"recharts-cartesian-grid-bg"})});return F.createElement("g",{className:"recharts-cartesian-gridstripes-horizontal"},p)}function Bte(e){var t=e.vertical,r=t===void 0?!0:t,n=e.verticalFill,i=e.fillOpacity,o=e.x,s=e.y,u=e.width,f=e.height,l=e.verticalPoints;if(!r||!n||!n.length)return null;var d=l.map(function(m){return Math.round(m+o-o)}).sort(function(m,g){return m-g});o!==d[0]&&d.unshift(0);var p=d.map(function(m,g){var b=!d[g+1],y=b?o+u-m:d[g+1]-m;if(y<=0)return null;var w=g%n.length;return F.createElement("rect",{key:"react-".concat(g),x:m,y:s,width:y,height:f,stroke:"none",fill:n[w],fillOpacity:i,className:"recharts-cartesian-grid-bg"})});return F.createElement("g",{className:"recharts-cartesian-gridstripes-vertical"},p)}var Fte=function(t,r){var n=t.xAxis,i=t.width,o=t.height,s=t.offset;return qD(BS(or(or(or({},Ys.defaultProps),n),{},{ticks:yi(n,!0),viewBox:{x:0,y:0,width:i,height:o}})),s.left,s.left+s.width,r)},zte=function(t,r){var n=t.yAxis,i=t.width,o=t.height,s=t.offset;return qD(BS(or(or(or({},Ys.defaultProps),n),{},{ticks:yi(n,!0),viewBox:{x:0,y:0,width:i,height:o}})),s.top,s.top+s.height,r)},Ba={horizontal:!0,vertical:!0,stroke:"#ccc",fill:"none",verticalFill:[],horizontalFill:[]};function Yh(e){var t,r,n,i,o,s,u=IS(),f=DS(),l=Aee(),d=or(or({},e),{},{stroke:(t=e.stroke)!==null&&t!==void 0?t:Ba.stroke,fill:(r=e.fill)!==null&&r!==void 0?r:Ba.fill,horizontal:(n=e.horizontal)!==null&&n!==void 0?n:Ba.horizontal,horizontalFill:(i=e.horizontalFill)!==null&&i!==void 0?i:Ba.horizontalFill,vertical:(o=e.vertical)!==null&&o!==void 0?o:Ba.vertical,verticalFill:(s=e.verticalFill)!==null&&s!==void 0?s:Ba.verticalFill,x:ge(e.x)?e.x:l.left,y:ge(e.y)?e.y:l.top,width:ge(e.width)?e.width:l.width,height:ge(e.height)?e.height:l.height}),p=d.x,m=d.y,g=d.width,b=d.height,y=d.syncWithTicks,w=d.horizontalValues,j=d.verticalValues,O=Oee(),E=Eee();if(!ge(g)||g<=0||!ge(b)||b<=0||!ge(p)||p!==+p||!ge(m)||m!==+m)return null;var N=d.verticalCoordinatesGenerator||Fte,A=d.horizontalCoordinatesGenerator||zte,C=d.horizontalPoints,T=d.verticalPoints;if((!C||!C.length)&&ze(A)){var R=w&&w.length,I=A({yAxis:E?or(or({},E),{},{ticks:R?w:E.ticks}):void 0,width:u,height:f,offset:l},R?!0:y);Tn(Array.isArray(I),"horizontalCoordinatesGenerator should return Array but instead it returned [".concat(Yo(I),"]")),Array.isArray(I)&&(C=I)}if((!T||!T.length)&&ze(N)){var z=j&&j.length,$=N({xAxis:O?or(or({},O),{},{ticks:z?j:O.ticks}):void 0,width:u,height:f,offset:l},z?!0:y);Tn(Array.isArray($),"verticalCoordinatesGenerator should return Array but instead it returned [".concat(Yo($),"]")),Array.isArray($)&&(T=$)}return F.createElement("g",{className:"recharts-cartesian-grid"},F.createElement(Ite,{fill:d.fill,fillOpacity:d.fillOpacity,x:d.x,y:d.y,width:d.width,height:d.height,ry:d.ry}),F.createElement(Dte,zo({},d,{offset:l,horizontalPoints:C,xAxis:O,yAxis:E})),F.createElement(Lte,zo({},d,{offset:l,verticalPoints:T,xAxis:O,yAxis:E})),F.createElement($te,zo({},d,{horizontalPoints:C})),F.createElement(Bte,zo({},d,{verticalPoints:T})))}Yh.displayName="CartesianGrid";var qte=["type","layout","connectNulls","ref"],Ute=["key"];function ks(e){"@babel/helpers - typeof";return ks=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},ks(e)}function ik(e,t){if(e==null)return{};var r=Wte(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 Wte(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 gc(){return gc=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){g=[].concat(Fa(f.slice(0,b)),[p-y]);break}var w=g.length%2===0?[0,m]:[m];return[].concat(Fa(t.repeat(f,d)),Fa(g),w).map(function(j){return"".concat(j,"px")}).join(", ")}),An(r,"id",Hs("recharts-line-")),An(r,"pathRef",function(s){r.mainCurve=s}),An(r,"handleAnimationEnd",function(){r.setState({isAnimationFinished:!0}),r.props.onAnimationEnd&&r.props.onAnimationEnd()}),An(r,"handleAnimationStart",function(){r.setState({isAnimationFinished:!1}),r.props.onAnimationStart&&r.props.onAnimationStart()}),r}return ere(t,e),Yte(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,s=o.points,u=o.xAxis,f=o.yAxis,l=o.layout,d=o.children,p=Wr(d,pu);if(!p)return null;var m=function(y,w){return{x:y.x,y:y.y,value:y.value,errorVal:Bt(y.payload,w)}},g={clipPath:n?"url(#clipPath-".concat(i,")"):null};return F.createElement(rt,g,p.map(function(b){return F.cloneElement(b,{key:"bar-".concat(b.props.dataKey),data:s,xAxis:u,yAxis:f,layout:l,dataPointFormatter:m})}))}},{key:"renderDots",value:function(n,i,o){var s=this.props.isAnimationActive;if(s&&!this.state.isAnimationFinished)return null;var u=this.props,f=u.dot,l=u.points,d=u.dataKey,p=Le(this.props,!1),m=Le(f,!0),g=l.map(function(y,w){var j=Ir(Ir(Ir({key:"dot-".concat(w),r:3},p),m),{},{index:w,cx:y.x,cy:y.y,value:y.value,dataKey:d,payload:y.payload,points:l});return t.renderDotItem(f,j)}),b={clipPath:n?"url(#clipPath-".concat(i?"":"dots-").concat(o,")"):null};return F.createElement(rt,gc({className:"recharts-line-dots",key:"dots"},b),g)}},{key:"renderCurveStatically",value:function(n,i,o,s){var u=this.props,f=u.type,l=u.layout,d=u.connectNulls;u.ref;var p=ik(u,qte),m=Ir(Ir(Ir({},Le(p,!0)),{},{fill:"none",className:"recharts-line-curve",clipPath:i?"url(#clipPath-".concat(o,")"):null,points:n},s),{},{type:f,layout:l,connectNulls:d});return F.createElement(Ch,gc({},m,{pathRef:this.pathRef}))}},{key:"renderCurveWithAnimation",value:function(n,i){var o=this,s=this.props,u=s.points,f=s.strokeDasharray,l=s.isAnimationActive,d=s.animationBegin,p=s.animationDuration,m=s.animationEasing,g=s.animationId,b=s.animateNewValues,y=s.width,w=s.height,j=this.state,O=j.prevPoints,E=j.totalLength;return F.createElement(Zn,{begin:d,duration:p,isActive:l,easing:m,from:{t:0},to:{t:1},key:"line-".concat(g),onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},function(N){var A=N.t;if(O){var C=O.length/u.length,T=u.map(function(L,U){var W=Math.floor(U*C);if(O[W]){var V=O[W],G=Fr(V.x,L.x),Y=Fr(V.y,L.y);return Ir(Ir({},L),{},{x:G(A),y:Y(A)})}if(b){var D=Fr(y*2,L.x),Q=Fr(w/2,L.y);return Ir(Ir({},L),{},{x:D(A),y:Q(A)})}return Ir(Ir({},L),{},{x:L.x,y:L.y})});return o.renderCurveStatically(T,n,i)}var R=Fr(0,E),I=R(A),z;if(f){var $="".concat(f).split(/[,\s]+/gim).map(function(L){return parseFloat(L)});z=o.getStrokeDasharray(I,E,$)}else z=o.generateSimpleStrokeDasharray(E,I);return o.renderCurveStatically(u,n,i,{strokeDasharray:z})})}},{key:"renderCurve",value:function(n,i){var o=this.props,s=o.points,u=o.isAnimationActive,f=this.state,l=f.prevPoints,d=f.totalLength;return u&&s&&s.length&&(!l&&d>0||!hu(l,s))?this.renderCurveWithAnimation(n,i):this.renderCurveStatically(s,n,i)}},{key:"render",value:function(){var n,i=this.props,o=i.hide,s=i.dot,u=i.points,f=i.className,l=i.xAxis,d=i.yAxis,p=i.top,m=i.left,g=i.width,b=i.height,y=i.isAnimationActive,w=i.id;if(o||!u||!u.length)return null;var j=this.state.isAnimationFinished,O=u.length===1,E=We("recharts-line",f),N=l&&l.allowDataOverflow,A=d&&d.allowDataOverflow,C=N||A,T=Ue(w)?this.id:w,R=(n=Le(s,!1))!==null&&n!==void 0?n:{r:3,strokeWidth:2},I=R.r,z=I===void 0?3:I,$=R.strokeWidth,L=$===void 0?2:$,U=Nq(s)?s:{},W=U.clipDot,V=W===void 0?!0:W,G=z*2+L;return F.createElement(rt,{className:E},N||A?F.createElement("defs",null,F.createElement("clipPath",{id:"clipPath-".concat(T)},F.createElement("rect",{x:N?m:m-g/2,y:A?p:p-b/2,width:N?g:g*2,height:A?b:b*2})),!V&&F.createElement("clipPath",{id:"clipPath-dots-".concat(T)},F.createElement("rect",{x:m-G/2,y:p-G/2,width:g+G,height:b+G}))):null,!O&&this.renderCurve(C,T),this.renderErrorBar(C,T),(O||s)&&this.renderDots(C,V,T),(!y||j)&&wi.renderCallByParent(this.props,u))}}],[{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(Fa(n),[0]):n,s=[],u=0;ue.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 Wre(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 Hre(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Vre(e,t){for(var r=0;re.length)&&(t=e.length);for(var r=0,n=new Array(t);r0?s:t&&t.length&&ge(i)&&ge(o)?t.slice(i,o+1):[]};function n$(e){return e==="number"?[0,"auto"]:void 0}var cw=function(t,r,n,i){var o=t.graphicalItems,s=t.tooltipAxis,u=Yp(r,t);return n<0||!o||!o.length||n>=u.length?null:o.reduce(function(f,l){var d,p=(d=l.props.data)!==null&&d!==void 0?d:r;p&&t.dataStartIndex+t.dataEndIndex!==0&&t.dataEndIndex-t.dataStartIndex>=n&&(p=p.slice(t.dataStartIndex,t.dataEndIndex+1));var m;if(s.dataKey&&!s.allowDuplicatedCategory){var g=p===void 0?u:p;m=Jd(g,s.dataKey,i)}else m=p&&p[n]||u[n];return m?[].concat(Ds(f),[GD(l,m)]):f},[])},hk=function(t,r,n,i){var o=i||{x:t.chartX,y:t.chartY},s=ine(o,n),u=t.orderedTooltipTicks,f=t.tooltipAxis,l=t.tooltipTicks,d=PK(s,u,l,f);if(d>=0&&l){var p=l[d]&&l[d].value,m=cw(t,r,d,p),g=one(n,u,d,o);return{activeTooltipIndex:d,activeLabel:p,activePayload:m,activeCoordinate:g}}return null},ane=function(t,r){var n=r.axes,i=r.graphicalItems,o=r.axisType,s=r.axisIdKey,u=r.stackGroups,f=r.dataStartIndex,l=r.dataEndIndex,d=t.layout,p=t.children,m=t.stackOffset,g=zD(d,o);return n.reduce(function(b,y){var w,j=y.type.defaultProps!==void 0?ae(ae({},y.type.defaultProps),y.props):y.props,O=j.type,E=j.dataKey,N=j.allowDataOverflow,A=j.allowDuplicatedCategory,C=j.scale,T=j.ticks,R=j.includeHidden,I=j[s];if(b[I])return b;var z=Yp(t.data,{graphicalItems:i.filter(function(B){var Z,te=s in B.props?B.props[s]:(Z=B.type.defaultProps)===null||Z===void 0?void 0:Z[s];return te===I}),dataStartIndex:f,dataEndIndex:l}),$=z.length,L,U,W;kre(j.domain,N,O)&&(L=_1(j.domain,null,N),g&&(O==="number"||C!=="auto")&&(W=hc(z,E,"category")));var V=n$(O);if(!L||L.length===0){var G,Y=(G=j.domain)!==null&&G!==void 0?G:V;if(E){if(L=hc(z,E,O),O==="category"&&g){var D=bq(L);A&&D?(U=L,L=Fh(0,$)):A||(L=mN(Y,L,y).reduce(function(B,Z){return B.indexOf(Z)>=0?B:[].concat(Ds(B),[Z])},[]))}else if(O==="category")A?L=L.filter(function(B){return B!==""&&!Ue(B)}):L=mN(Y,L,y).reduce(function(B,Z){return B.indexOf(Z)>=0||Z===""||Ue(Z)?B:[].concat(Ds(B),[Z])},[]);else if(O==="number"){var Q=kK(z,i.filter(function(B){var Z,te,ve=s in B.props?B.props[s]:(Z=B.type.defaultProps)===null||Z===void 0?void 0:Z[s],xe="hide"in B.props?B.props.hide:(te=B.type.defaultProps)===null||te===void 0?void 0:te.hide;return ve===I&&(R||!xe)}),E,o,d);Q&&(L=Q)}g&&(O==="number"||C!=="auto")&&(W=hc(z,E,"category"))}else g?L=Fh(0,$):u&&u[I]&&u[I].hasStack&&O==="number"?L=m==="expand"?[0,1]:VD(u[I].stackGroups,f,l):L=FD(z,i.filter(function(B){var Z=s in B.props?B.props[s]:B.type.defaultProps[s],te="hide"in B.props?B.props.hide:B.type.defaultProps.hide;return Z===I&&(R||!te)}),O,d,!0);if(O==="number")L=aw(p,L,I,o,T),Y&&(L=_1(Y,L,N));else if(O==="category"&&Y){var J=Y,M=L.every(function(B){return J.indexOf(B)>=0});M&&(L=J)}}return ae(ae({},b),{},Be({},I,ae(ae({},j),{},{axisType:o,domain:L,categoricalDomain:W,duplicateDomain:U,originalDomain:(w=j.domain)!==null&&w!==void 0?w:V,isCategorical:g,layout:d})))},{})},sne=function(t,r){var n=r.graphicalItems,i=r.Axis,o=r.axisType,s=r.axisIdKey,u=r.stackGroups,f=r.dataStartIndex,l=r.dataEndIndex,d=t.layout,p=t.children,m=Yp(t.data,{graphicalItems:n,dataStartIndex:f,dataEndIndex:l}),g=m.length,b=zD(d,o),y=-1;return n.reduce(function(w,j){var O=j.type.defaultProps!==void 0?ae(ae({},j.type.defaultProps),j.props):j.props,E=O[s],N=n$("number");if(!w[E]){y++;var A;return b?A=Fh(0,g):u&&u[E]&&u[E].hasStack?(A=VD(u[E].stackGroups,f,l),A=aw(p,A,E,o)):(A=_1(N,FD(m,n.filter(function(C){var T,R,I=s in C.props?C.props[s]:(T=C.type.defaultProps)===null||T===void 0?void 0:T[s],z="hide"in C.props?C.props.hide:(R=C.type.defaultProps)===null||R===void 0?void 0:R.hide;return I===E&&!z}),"number",d),i.defaultProps.allowDataOverflow),A=aw(p,A,E,o)),ae(ae({},w),{},Be({},E,ae(ae({axisType:o},i.defaultProps),{},{hide:!0,orientation:Ur(rne,"".concat(o,".").concat(y%2),null),domain:A,originalDomain:N,isCategorical:b,layout:d})))}return w},{})},lne=function(t,r){var n=r.axisType,i=n===void 0?"xAxis":n,o=r.AxisComp,s=r.graphicalItems,u=r.stackGroups,f=r.dataStartIndex,l=r.dataEndIndex,d=t.children,p="".concat(i,"Id"),m=Wr(d,o),g={};return m&&m.length?g=ane(t,{axes:m,graphicalItems:s,axisType:i,axisIdKey:p,stackGroups:u,dataStartIndex:f,dataEndIndex:l}):s&&s.length&&(g=sne(t,{Axis:o,graphicalItems:s,axisType:i,axisIdKey:p,stackGroups:u,dataStartIndex:f,dataEndIndex:l})),g},cne=function(t){var r=to(t),n=yi(r,!1,!0);return{tooltipTicks:n,orderedTooltipTicks:iS(n,function(i){return i.coordinate}),tooltipAxis:r,tooltipAxisBandSize:Eh(r,n)}},pk=function(t){var r=t.children,n=t.defaultShowTooltip,i=Lr(r,Es),o=0,s=0;return t.data&&t.data.length!==0&&(s=t.data.length-1),i&&i.props&&(i.props.startIndex>=0&&(o=i.props.startIndex),i.props.endIndex>=0&&(s=i.props.endIndex)),{chartX:0,chartY:0,dataStartIndex:o,dataEndIndex:s,activeTooltipIndex:-1,isTooltipActive:!!n}},une=function(t){return!t||!t.length?!1:t.some(function(r){var n=xi(r&&r.type);return n&&n.indexOf("Bar")>=0})},mk=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"}},fne=function(t,r){var n=t.props,i=t.graphicalItems,o=t.xAxisMap,s=o===void 0?{}:o,u=t.yAxisMap,f=u===void 0?{}:u,l=n.width,d=n.height,p=n.children,m=n.margin||{},g=Lr(p,Es),b=Lr(p,rs),y=Object.keys(f).reduce(function(A,C){var T=f[C],R=T.orientation;return!T.mirror&&!T.hide?ae(ae({},A),{},Be({},R,A[R]+T.width)):A},{left:m.left||0,right:m.right||0}),w=Object.keys(s).reduce(function(A,C){var T=s[C],R=T.orientation;return!T.mirror&&!T.hide?ae(ae({},A),{},Be({},R,Ur(A,"".concat(R))+T.height)):A},{top:m.top||0,bottom:m.bottom||0}),j=ae(ae({},w),y),O=j.bottom;g&&(j.bottom+=g.props.height||Es.defaultProps.height),b&&r&&(j=NK(j,i,n,r));var E=l-j.left-j.right,N=d-j.top-j.bottom;return ae(ae({brushBottom:O},j),{},{width:Math.max(E,0),height:Math.max(N,0)})},dne=function(t,r){if(r==="xAxis")return t[r].width;if(r==="yAxis")return t[r].height},zS=function(t){var r=t.chartName,n=t.GraphicalChild,i=t.defaultTooltipEventType,o=i===void 0?"axis":i,s=t.validateTooltipEventTypes,u=s===void 0?["axis"]:s,f=t.axisComponents,l=t.legendContent,d=t.formatAxisMap,p=t.defaultProps,m=function(j,O){var E=O.graphicalItems,N=O.stackGroups,A=O.offset,C=O.updateId,T=O.dataStartIndex,R=O.dataEndIndex,I=j.barSize,z=j.layout,$=j.barGap,L=j.barCategoryGap,U=j.maxBarSize,W=mk(z),V=W.numericAxisName,G=W.cateAxisName,Y=une(E),D=[];return E.forEach(function(Q,J){var M=Yp(j.data,{graphicalItems:[Q],dataStartIndex:T,dataEndIndex:R}),B=Q.type.defaultProps!==void 0?ae(ae({},Q.type.defaultProps),Q.props):Q.props,Z=B.dataKey,te=B.maxBarSize,ve=B["".concat(V,"Id")],xe=B["".concat(G,"Id")],X={},ue=f.reduce(function(Kt,Xt){var fa=O["".concat(Xt.axisType,"Map")],rl=B["".concat(Xt.axisType,"Id")];fa&&fa[rl]||Xt.axisType==="zAxis"||Xo();var nl=fa[rl];return ae(ae({},Kt),{},Be(Be({},Xt.axisType,nl),"".concat(Xt.axisType,"Ticks"),yi(nl)))},X),ie=ue[G],de=ue["".concat(G,"Ticks")],ye=N&&N[ve]&&N[ve].hasStack&&zK(Q,N[ve].stackGroups),oe=xi(Q.type).indexOf("Bar")>=0,$e=Eh(ie,de),Me=[],Ye=Y&&AK({barSize:I,stackGroups:N,totalSize:dne(ue,G)});if(oe){var lt,vt,vr=Ue(te)?U:te,Pr=(lt=(vt=Eh(ie,de,!0))!==null&&vt!==void 0?vt:vr)!==null&<!==void 0?lt:0;Me=CK({barGap:$,barCategoryGap:L,bandSize:Pr!==$e?Pr:$e,sizeList:Ye[xe],maxBarSize:vr}),Pr!==$e&&(Me=Me.map(function(Kt){return ae(ae({},Kt),{},{position:ae(ae({},Kt.position),{},{offset:Kt.position.offset-Pr/2})})}))}var Ar=Q&&Q.type&&Q.type.getComposedData;Ar&&D.push({props:ae(ae({},Ar(ae(ae({},ue),{},{displayedData:M,props:j,dataKey:Z,item:Q,bandSize:$e,barPosition:Me,offset:A,stackedData:ye,layout:z,dataStartIndex:T,dataEndIndex:R}))),{},Be(Be(Be({key:Q.key||"item-".concat(J)},V,ue[V]),G,ue[G]),"animationId",C)),childIndex:Rq(Q,j.children),item:Q})}),D},g=function(j,O){var E=j.props,N=j.dataStartIndex,A=j.dataEndIndex,C=j.updateId;if(!C2({props:E}))return null;var T=E.children,R=E.layout,I=E.stackOffset,z=E.data,$=E.reverseStackOrder,L=mk(R),U=L.numericAxisName,W=L.cateAxisName,V=Wr(T,n),G=BK(z,V,"".concat(U,"Id"),"".concat(W,"Id"),I,$),Y=f.reduce(function(B,Z){var te="".concat(Z.axisType,"Map");return ae(ae({},B),{},Be({},te,lne(E,ae(ae({},Z),{},{graphicalItems:V,stackGroups:Z.axisType===U&&G,dataStartIndex:N,dataEndIndex:A}))))},{}),D=fne(ae(ae({},Y),{},{props:E,graphicalItems:V}),O?.legendBBox);Object.keys(Y).forEach(function(B){Y[B]=d(E,Y[B],D,B.replace("Map",""),r)});var Q=Y["".concat(W,"Map")],J=cne(Q),M=m(E,ae(ae({},Y),{},{dataStartIndex:N,dataEndIndex:A,updateId:C,graphicalItems:V,stackGroups:G,offset:D}));return ae(ae({formattedGraphicalItems:M,graphicalItems:V,offset:D,stackGroups:G},J),Y)},b=(function(w){function j(O){var E,N,A;return Hre(this,j),A=Kre(this,j,[O]),Be(A,"eventEmitterSymbol",Symbol("rechartsEventEmitter")),Be(A,"accessibilityManager",new Tre),Be(A,"handleLegendBBoxUpdate",function(C){if(C){var T=A.state,R=T.dataStartIndex,I=T.dataEndIndex,z=T.updateId;A.setState(ae({legendBBox:C},g({props:A.props,dataStartIndex:R,dataEndIndex:I,updateId:z},ae(ae({},A.state),{},{legendBBox:C}))))}}),Be(A,"handleReceiveSyncEvent",function(C,T,R){if(A.props.syncId===C){if(R===A.eventEmitterSymbol&&typeof A.props.syncMethod!="function")return;A.applySyncEvent(T)}}),Be(A,"handleBrushChange",function(C){var T=C.startIndex,R=C.endIndex;if(T!==A.state.dataStartIndex||R!==A.state.dataEndIndex){var I=A.state.updateId;A.setState(function(){return ae({dataStartIndex:T,dataEndIndex:R},g({props:A.props,dataStartIndex:T,dataEndIndex:R,updateId:I},A.state))}),A.triggerSyncEvent({dataStartIndex:T,dataEndIndex:R})}}),Be(A,"handleMouseEnter",function(C){var T=A.getMouseInfo(C);if(T){var R=ae(ae({},T),{},{isTooltipActive:!0});A.setState(R),A.triggerSyncEvent(R);var I=A.props.onMouseEnter;ze(I)&&I(R,C)}}),Be(A,"triggeredAfterMouseMove",function(C){var T=A.getMouseInfo(C),R=T?ae(ae({},T),{},{isTooltipActive:!0}):{isTooltipActive:!1};A.setState(R),A.triggerSyncEvent(R);var I=A.props.onMouseMove;ze(I)&&I(R,C)}),Be(A,"handleItemMouseEnter",function(C){A.setState(function(){return{isTooltipActive:!0,activeItem:C,activePayload:C.tooltipPayload,activeCoordinate:C.tooltipPosition||{x:C.cx,y:C.cy}}})}),Be(A,"handleItemMouseLeave",function(){A.setState(function(){return{isTooltipActive:!1}})}),Be(A,"handleMouseMove",function(C){C.persist(),A.throttleTriggeredAfterMouseMove(C)}),Be(A,"handleMouseLeave",function(C){A.throttleTriggeredAfterMouseMove.cancel();var T={isTooltipActive:!1};A.setState(T),A.triggerSyncEvent(T);var R=A.props.onMouseLeave;ze(R)&&R(T,C)}),Be(A,"handleOuterEvent",function(C){var T=kq(C),R=Ur(A.props,"".concat(T));if(T&&ze(R)){var I,z;/.*touch.*/i.test(T)?z=A.getMouseInfo(C.changedTouches[0]):z=A.getMouseInfo(C),R((I=z)!==null&&I!==void 0?I:{},C)}}),Be(A,"handleClick",function(C){var T=A.getMouseInfo(C);if(T){var R=ae(ae({},T),{},{isTooltipActive:!0});A.setState(R),A.triggerSyncEvent(R);var I=A.props.onClick;ze(I)&&I(R,C)}}),Be(A,"handleMouseDown",function(C){var T=A.props.onMouseDown;if(ze(T)){var R=A.getMouseInfo(C);T(R,C)}}),Be(A,"handleMouseUp",function(C){var T=A.props.onMouseUp;if(ze(T)){var R=A.getMouseInfo(C);T(R,C)}}),Be(A,"handleTouchMove",function(C){C.changedTouches!=null&&C.changedTouches.length>0&&A.throttleTriggeredAfterMouseMove(C.changedTouches[0])}),Be(A,"handleTouchStart",function(C){C.changedTouches!=null&&C.changedTouches.length>0&&A.handleMouseDown(C.changedTouches[0])}),Be(A,"handleTouchEnd",function(C){C.changedTouches!=null&&C.changedTouches.length>0&&A.handleMouseUp(C.changedTouches[0])}),Be(A,"handleDoubleClick",function(C){var T=A.props.onDoubleClick;if(ze(T)){var R=A.getMouseInfo(C);T(R,C)}}),Be(A,"handleContextMenu",function(C){var T=A.props.onContextMenu;if(ze(T)){var R=A.getMouseInfo(C);T(R,C)}}),Be(A,"triggerSyncEvent",function(C){A.props.syncId!==void 0&&bb.emit(wb,A.props.syncId,C,A.eventEmitterSymbol)}),Be(A,"applySyncEvent",function(C){var T=A.props,R=T.layout,I=T.syncMethod,z=A.state.updateId,$=C.dataStartIndex,L=C.dataEndIndex;if(C.dataStartIndex!==void 0||C.dataEndIndex!==void 0)A.setState(ae({dataStartIndex:$,dataEndIndex:L},g({props:A.props,dataStartIndex:$,dataEndIndex:L,updateId:z},A.state)));else if(C.activeTooltipIndex!==void 0){var U=C.chartX,W=C.chartY,V=C.activeTooltipIndex,G=A.state,Y=G.offset,D=G.tooltipTicks;if(!Y)return;if(typeof I=="function")V=I(D,C);else if(I==="value"){V=-1;for(var Q=0;Q=0){var ye,oe;if(U.dataKey&&!U.allowDuplicatedCategory){var $e=typeof U.dataKey=="function"?de:"payload.".concat(U.dataKey.toString());ye=Jd(Q,$e,V),oe=J&&M&&Jd(M,$e,V)}else ye=Q?.[W],oe=J&&M&&M[W];if(xe||ve){var Me=C.props.activeIndex!==void 0?C.props.activeIndex:W;return[_.cloneElement(C,ae(ae(ae({},I.props),ue),{},{activeIndex:Me})),null,null]}if(!Ue(ye))return[ie].concat(Ds(A.renderActivePoints({item:I,activePoint:ye,basePoint:oe,childIndex:W,isRange:J})))}else{var Ye,lt=(Ye=A.getItemByXY(A.state.activeCoordinate))!==null&&Ye!==void 0?Ye:{graphicalItem:ie},vt=lt.graphicalItem,vr=vt.item,Pr=vr===void 0?C:vr,Ar=vt.childIndex,Kt=ae(ae(ae({},I.props),ue),{},{activeIndex:Ar});return[_.cloneElement(Pr,Kt),null,null]}return J?[ie,null,null]:[ie,null]}),Be(A,"renderCustomized",function(C,T,R){return _.cloneElement(C,ae(ae({key:"recharts-customized-".concat(R)},A.props),A.state))}),Be(A,"renderMap",{CartesianGrid:{handler:Qf,once:!0},ReferenceArea:{handler:A.renderReferenceElement},ReferenceLine:{handler:Qf},ReferenceDot:{handler:A.renderReferenceElement},XAxis:{handler:Qf},YAxis:{handler:Qf},Brush:{handler:A.renderBrush,once:!0},Bar:{handler:A.renderGraphicChild},Line:{handler:A.renderGraphicChild},Area:{handler:A.renderGraphicChild},Radar:{handler:A.renderGraphicChild},RadialBar:{handler:A.renderGraphicChild},Scatter:{handler:A.renderGraphicChild},Pie:{handler:A.renderGraphicChild},Funnel:{handler:A.renderGraphicChild},Tooltip:{handler:A.renderCursor,once:!0},PolarGrid:{handler:A.renderPolarGrid,once:!0},PolarAngleAxis:{handler:A.renderPolarAxis},PolarRadiusAxis:{handler:A.renderPolarAxis},Customized:{handler:A.renderCustomized}}),A.clipPathId="".concat((E=O.id)!==null&&E!==void 0?E:Hs("recharts"),"-clip"),A.throttleTriggeredAfterMouseMove=$I(A.triggeredAfterMouseMove,(N=O.throttleDelay)!==null&&N!==void 0?N:1e3/60),A.state={},A}return Qre(j,w),Gre(j,[{key:"componentDidMount",value:function(){var E,N;this.addListener(),this.accessibilityManager.setDetails({container:this.container,offset:{left:(E=this.props.margin.left)!==null&&E!==void 0?E:0,top:(N=this.props.margin.top)!==null&&N!==void 0?N:0},coordinateList:this.state.tooltipTicks,mouseHandlerCallback:this.triggeredAfterMouseMove,layout:this.props.layout}),this.displayDefaultTooltip()}},{key:"displayDefaultTooltip",value:function(){var E=this.props,N=E.children,A=E.data,C=E.height,T=E.layout,R=Lr(N,Br);if(R){var I=R.props.defaultIndex;if(!(typeof I!="number"||I<0||I>this.state.tooltipTicks.length-1)){var z=this.state.tooltipTicks[I]&&this.state.tooltipTicks[I].value,$=cw(this.state,A,I,z),L=this.state.tooltipTicks[I].coordinate,U=(this.state.offset.top+C)/2,W=T==="horizontal",V=W?{x:L,y:U}:{y:L,x:U},G=this.state.formattedGraphicalItems.find(function(D){var Q=D.item;return Q.type.name==="Scatter"});G&&(V=ae(ae({},V),G.props.points[I].tooltipPosition),$=G.props.points[I].tooltipPayload);var Y={activeTooltipIndex:I,isTooltipActive:!0,activeLabel:z,activePayload:$,activeCoordinate:V};this.setState(Y),this.renderCursor(R),this.accessibilityManager.setIndex(I)}}}},{key:"getSnapshotBeforeUpdate",value:function(E,N){if(!this.props.accessibilityLayer)return null;if(this.state.tooltipTicks!==N.tooltipTicks&&this.accessibilityManager.setDetails({coordinateList:this.state.tooltipTicks}),this.props.layout!==E.layout&&this.accessibilityManager.setDetails({layout:this.props.layout}),this.props.margin!==E.margin){var A,C;this.accessibilityManager.setDetails({offset:{left:(A=this.props.margin.left)!==null&&A!==void 0?A:0,top:(C=this.props.margin.top)!==null&&C!==void 0?C:0}})}return null}},{key:"componentDidUpdate",value:function(E){Hb([Lr(E.children,Br)],[Lr(this.props.children,Br)])||this.displayDefaultTooltip()}},{key:"componentWillUnmount",value:function(){this.removeListener(),this.throttleTriggeredAfterMouseMove.cancel()}},{key:"getTooltipEventType",value:function(){var E=Lr(this.props.children,Br);if(E&&typeof E.props.shared=="boolean"){var N=E.props.shared?"axis":"item";return u.indexOf(N)>=0?N:o}return o}},{key:"getMouseInfo",value:function(E){if(!this.container)return null;var N=this.container,A=N.getBoundingClientRect(),C=xW(A),T={chartX:Math.round(E.pageX-C.left),chartY:Math.round(E.pageY-C.top)},R=A.width/N.offsetWidth||1,I=this.inRange(T.chartX,T.chartY,R);if(!I)return null;var z=this.state,$=z.xAxisMap,L=z.yAxisMap,U=this.getTooltipEventType(),W=hk(this.state,this.props.data,this.props.layout,I);if(U!=="axis"&&$&&L){var V=to($).scale,G=to(L).scale,Y=V&&V.invert?V.invert(T.chartX):null,D=G&&G.invert?G.invert(T.chartY):null;return ae(ae({},T),{},{xValue:Y,yValue:D},W)}return W?ae(ae({},T),W):null}},{key:"inRange",value:function(E,N){var A=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,C=this.props.layout,T=E/A,R=N/A;if(C==="horizontal"||C==="vertical"){var I=this.state.offset,z=T>=I.left&&T<=I.left+I.width&&R>=I.top&&R<=I.top+I.height;return z?{x:T,y:R}:null}var $=this.state,L=$.angleAxisMap,U=$.radiusAxisMap;if(L&&U){var W=to(L);return yN({x:T,y:R},W)}return null}},{key:"parseEventsOfWrapper",value:function(){var E=this.props.children,N=this.getTooltipEventType(),A=Lr(E,Br),C={};A&&N==="axis"&&(A.props.trigger==="click"?C={onClick:this.handleClick}:C={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 T=eh(this.props,this.handleOuterEvent);return ae(ae({},T),C)}},{key:"addListener",value:function(){bb.on(wb,this.handleReceiveSyncEvent)}},{key:"removeListener",value:function(){bb.removeListener(wb,this.handleReceiveSyncEvent)}},{key:"filterFormatItem",value:function(E,N,A){for(var C=this.state.formattedGraphicalItems,T=0,R=C.length;Th.jsxs("div",{className:"flex items-center justify-between p-3 bg-gray-50 rounded-lg border border-gray-100 hover:bg-gray-100 transition-colors",children:[h.jsxs("div",{className:"flex items-center gap-3",children:[h.jsx("div",{className:"w-10 h-10 rounded-full bg-blue-100 flex items-center justify-center text-blue-600 font-bold text-xs",children:e.template.substring(0,2)}),h.jsxs("div",{children:[h.jsx("p",{className:"text-sm font-semibold text-gray-900",children:e.product}),h.jsxs("p",{className:"text-xs text-gray-500",children:[e.id," • ",e.user]})]})]}),h.jsxs("div",{className:"flex items-center gap-4",children:[h.jsx("span",{className:"text-xs text-gray-500 font-medium",children:e.time}),h.jsx(Cn,{variant:"secondary",className:e.status==="expired"?"bg-red-100 text-red-700":"bg-green-100 text-green-700",children:e.status})]})]},e.id))})})]})]}),h.jsx("div",{className:"space-y-6",children:h.jsxs($r,{className:"shadow-sm border-gray-200",children:[h.jsx(On,{children:h.jsxs(En,{className:"text-base font-bold text-gray-800 flex items-center gap-2",children:[h.jsx(Hd,{className:"w-5 h-5 text-gray-500"}),"By Category"]})}),h.jsxs(nn,{children:[h.jsxs("div",{className:"h-[200px] relative",children:[h.jsx(uh,{width:"100%",height:"100%",children:h.jsxs(pne,{children:[h.jsx(Ti,{data:_b,cx:"50%",cy:"50%",innerRadius:60,outerRadius:80,paddingAngle:5,dataKey:"value",children:_b.map((e,t)=>h.jsx(Ep,{fill:e.color},`cell-${t}`))}),h.jsx(Br,{})]})}),h.jsxs("div",{className:"absolute inset-0 flex items-center justify-center flex-col pointer-events-none",children:[h.jsx("span",{className:"text-2xl font-bold text-gray-900",children:"1000"}),h.jsx("span",{className:"text-xs text-gray-500",children:"Total"})]})]}),h.jsx("div",{className:"mt-4 space-y-2",children:_b.map(e=>h.jsxs("div",{className:"flex items-center justify-between text-sm",children:[h.jsxs("div",{className:"flex items-center gap-2",children:[h.jsx("div",{className:"w-3 h-3 rounded-full",style:{backgroundColor:e.color}}),h.jsx("span",{className:"text-gray-600",children:e.name})]}),h.jsx("span",{className:"font-medium text-gray-900",children:e.value})]},e.name))})]})]})})]})]})}function za({title:e,value:t,trend:r,trendUp:n,icon:i,color:o,bgColor:s}){return h.jsx($r,{className:"border-gray-200 shadow-sm hover:shadow-md transition-shadow",children:h.jsxs(nn,{className:"p-6",children:[h.jsxs("div",{className:"flex justify-between items-start",children:[h.jsxs("div",{children:[h.jsx("p",{className:"text-sm font-medium text-gray-500 mb-1",children:e}),h.jsx("h3",{className:"text-2xl font-bold text-gray-900",children:t})]}),h.jsx("div",{className:`p-2 rounded-lg ${s}`,children:h.jsx(i,{className:`w-5 h-5 ${o}`})})]}),h.jsxs("div",{className:"mt-4 flex items-center text-sm",children:[n?h.jsx(XR,{className:"w-4 h-4 text-green-500 mr-1"}):h.jsx(v8,{className:"w-4 h-4 text-red-500 mr-1"}),h.jsx("span",{className:n?"text-green-600 font-medium":"text-red-600 font-medium",children:r}),h.jsx("span",{className:"text-gray-400 ml-1",children:"Vs. last period"})]})]})})}function yne({title:e}){return h.jsxs("div",{className:"space-y-6",children:[h.jsx("div",{className:"grid gap-4 md:grid-cols-2 lg:grid-cols-4",children:[1,2,3,4].map(t=>h.jsxs($r,{children:[h.jsx(On,{className:"flex flex-row items-center justify-between space-y-0 pb-2",children:h.jsxs(En,{className:"text-sm font-medium",children:["Metric ",t]})}),h.jsxs(nn,{children:[h.jsx("div",{className:"text-2xl font-bold",children:"000"}),h.jsx("p",{className:"text-xs text-muted-foreground",children:"+0.0% from last month"})]})]},t))}),h.jsx($r,{className:"min-h-[400px] flex items-center justify-center border-dashed",children:h.jsxs("div",{className:"text-center text-muted-foreground",children:[h.jsxs("h3",{className:"text-lg font-medium",children:[e," Module"]}),h.jsx("p",{children:"This module is currently under development."})]})})]})}function hr({className:e,...t}){return h.jsx("div",{"data-slot":"table-container",className:"relative w-full overflow-x-auto",children:h.jsx("table",{"data-slot":"table",className:Te("w-full caption-bottom text-sm",e),...t})})}function pr({className:e,...t}){return h.jsx("thead",{"data-slot":"table-header",className:Te("[&_tr]:border-b",e),...t})}function mr({className:e,...t}){return h.jsx("tbody",{"data-slot":"table-body",className:Te("[&_tr:last-child]:border-0",e),...t})}function Ke({className:e,...t}){return h.jsx("tr",{"data-slot":"table-row",className:Te("hover:bg-muted/50 data-[state=selected]:bg-muted border-b transition-colors",e),...t})}function me({className:e,...t}){return h.jsx("th",{"data-slot":"table-head",className:Te("text-foreground h-10 px-2 text-left align-middle font-medium whitespace-nowrap [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]",e),...t})}function se({className:e,...t}){return h.jsx("td",{"data-slot":"table-cell",className:Te("p-2 align-middle whitespace-nowrap [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]",e),...t})}function vk(e){const t=xne(e),r=_.forwardRef((n,i)=>{const{children:o,...s}=n,u=_.Children.toArray(o),f=u.find(wne);if(f){const l=f.props.children,d=u.map(p=>p===f?_.Children.count(l)>1?_.Children.only(null):_.isValidElement(l)?l.props.children:null:p);return h.jsx(t,{...s,ref:i,children:_.isValidElement(l)?_.cloneElement(l,void 0,d):null})}return h.jsx(t,{...s,ref:i,children:o})});return r.displayName=`${e}.Slot`,r}function xne(e){const t=_.forwardRef((r,n)=>{const{children:i,...o}=r;if(_.isValidElement(i)){const s=_ne(i),u=Sne(o,i.props);return i.type!==_.Fragment&&(u.ref=n?ia(n,s):s),_.cloneElement(i,u)}return _.Children.count(i)>1?_.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var bne=Symbol("radix.slottable");function wne(e){return _.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===bne}function Sne(e,t){const r={...t};for(const n in t){const i=e[n],o=t[n];/^on[A-Z]/.test(n)?i&&o?r[n]=(...u)=>{const f=o(...u);return i(...u),f}:i&&(r[n]=i):n==="style"?r[n]={...i,...o}:n==="className"&&(r[n]=[i,o].filter(Boolean).join(" "))}return{...e,...r}}function _ne(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,r=t&&"isReactWarning"in t&&t.isReactWarning,r?e.props.ref:e.props.ref||e.ref)}function o$(e){const t=e+"CollectionProvider",[r,n]=In(t),[i,o]=r(t,{collectionRef:{current:null},itemMap:new Map}),s=y=>{const{scope:w,children:j}=y,O=F.useRef(null),E=F.useRef(new Map).current;return h.jsx(i,{scope:w,itemMap:E,collectionRef:O,children:j})};s.displayName=t;const u=e+"CollectionSlot",f=vk(u),l=F.forwardRef((y,w)=>{const{scope:j,children:O}=y,E=o(u,j),N=Xe(w,E.collectionRef);return h.jsx(f,{ref:N,children:O})});l.displayName=u;const d=e+"CollectionItemSlot",p="data-radix-collection-item",m=vk(d),g=F.forwardRef((y,w)=>{const{scope:j,children:O,...E}=y,N=F.useRef(null),A=Xe(w,N),C=o(d,j);return F.useEffect(()=>(C.itemMap.set(N,{ref:N,...E}),()=>void C.itemMap.delete(N))),h.jsx(m,{[p]:"",ref:A,children:O})});g.displayName=d;function b(y){const w=o(e+"CollectionConsumer",y);return F.useCallback(()=>{const O=w.collectionRef.current;if(!O)return[];const E=Array.from(O.querySelectorAll(`[${p}]`));return Array.from(w.itemMap.values()).sort((C,T)=>E.indexOf(C.ref.current)-E.indexOf(T.ref.current))},[w.collectionRef,w.itemMap])}return[{Provider:s,Slot:l,ItemSlot:g},b,n]}function jne(e,t=globalThis?.document){const r=ar(e);_.useEffect(()=>{const n=i=>{i.key==="Escape"&&r(i)};return t.addEventListener("keydown",n,{capture:!0}),()=>t.removeEventListener("keydown",n,{capture:!0})},[r,t])}var One="DismissableLayer",uw="dismissableLayer.update",Ene="dismissableLayer.pointerDownOutside",Pne="dismissableLayer.focusOutside",gk,a$=_.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),mu=_.forwardRef((e,t)=>{const{disableOutsidePointerEvents:r=!1,onEscapeKeyDown:n,onPointerDownOutside:i,onFocusOutside:o,onInteractOutside:s,onDismiss:u,...f}=e,l=_.useContext(a$),[d,p]=_.useState(null),m=d?.ownerDocument??globalThis?.document,[,g]=_.useState({}),b=Xe(t,T=>p(T)),y=Array.from(l.layers),[w]=[...l.layersWithOutsidePointerEventsDisabled].slice(-1),j=y.indexOf(w),O=d?y.indexOf(d):-1,E=l.layersWithOutsidePointerEventsDisabled.size>0,N=O>=j,A=Nne(T=>{const R=T.target,I=[...l.branches].some(z=>z.contains(R));!N||I||(i?.(T),s?.(T),T.defaultPrevented||u?.())},m),C=Tne(T=>{const R=T.target;[...l.branches].some(z=>z.contains(R))||(o?.(T),s?.(T),T.defaultPrevented||u?.())},m);return jne(T=>{O===l.layers.size-1&&(n?.(T),!T.defaultPrevented&&u&&(T.preventDefault(),u()))},m),_.useEffect(()=>{if(d)return r&&(l.layersWithOutsidePointerEventsDisabled.size===0&&(gk=m.body.style.pointerEvents,m.body.style.pointerEvents="none"),l.layersWithOutsidePointerEventsDisabled.add(d)),l.layers.add(d),yk(),()=>{r&&l.layersWithOutsidePointerEventsDisabled.size===1&&(m.body.style.pointerEvents=gk)}},[d,m,r,l]),_.useEffect(()=>()=>{d&&(l.layers.delete(d),l.layersWithOutsidePointerEventsDisabled.delete(d),yk())},[d,l]),_.useEffect(()=>{const T=()=>g({});return document.addEventListener(uw,T),()=>document.removeEventListener(uw,T)},[]),h.jsx(qe.div,{...f,ref:b,style:{pointerEvents:E?N?"auto":"none":void 0,...e.style},onFocusCapture:ke(e.onFocusCapture,C.onFocusCapture),onBlurCapture:ke(e.onBlurCapture,C.onBlurCapture),onPointerDownCapture:ke(e.onPointerDownCapture,A.onPointerDownCapture)})});mu.displayName=One;var Ane="DismissableLayerBranch",Cne=_.forwardRef((e,t)=>{const r=_.useContext(a$),n=_.useRef(null),i=Xe(t,n);return _.useEffect(()=>{const o=n.current;if(o)return r.branches.add(o),()=>{r.branches.delete(o)}},[r.branches]),h.jsx(qe.div,{...e,ref:i})});Cne.displayName=Ane;function Nne(e,t=globalThis?.document){const r=ar(e),n=_.useRef(!1),i=_.useRef(()=>{});return _.useEffect(()=>{const o=u=>{if(u.target&&!n.current){let f=function(){s$(Ene,r,l,{discrete:!0})};const l={originalEvent:u};u.pointerType==="touch"?(t.removeEventListener("click",i.current),i.current=f,t.addEventListener("click",i.current,{once:!0})):f()}else t.removeEventListener("click",i.current);n.current=!1},s=window.setTimeout(()=>{t.addEventListener("pointerdown",o)},0);return()=>{window.clearTimeout(s),t.removeEventListener("pointerdown",o),t.removeEventListener("click",i.current)}},[t,r]),{onPointerDownCapture:()=>n.current=!0}}function Tne(e,t=globalThis?.document){const r=ar(e),n=_.useRef(!1);return _.useEffect(()=>{const i=o=>{o.target&&!n.current&&s$(Pne,r,{originalEvent:o},{discrete:!1})};return t.addEventListener("focusin",i),()=>t.removeEventListener("focusin",i)},[t,r]),{onFocusCapture:()=>n.current=!0,onBlurCapture:()=>n.current=!1}}function yk(){const e=new CustomEvent(uw);document.dispatchEvent(e)}function s$(e,t,r,{discrete:n}){const i=r.originalEvent.target,o=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:r});t&&i.addEventListener(e,t,{once:!0}),n?IF(i,o):i.dispatchEvent(o)}var jb=0;function qS(){_.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??xk()),document.body.insertAdjacentElement("beforeend",e[1]??xk()),jb++,()=>{jb===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),jb--}},[])}function xk(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var Ob="focusScope.autoFocusOnMount",Eb="focusScope.autoFocusOnUnmount",bk={bubbles:!1,cancelable:!0},kne="FocusScope",Qp=_.forwardRef((e,t)=>{const{loop:r=!1,trapped:n=!1,onMountAutoFocus:i,onUnmountAutoFocus:o,...s}=e,[u,f]=_.useState(null),l=ar(i),d=ar(o),p=_.useRef(null),m=Xe(t,y=>f(y)),g=_.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;_.useEffect(()=>{if(n){let y=function(E){if(g.paused||!u)return;const N=E.target;u.contains(N)?p.current=N:Ji(p.current,{select:!0})},w=function(E){if(g.paused||!u)return;const N=E.relatedTarget;N!==null&&(u.contains(N)||Ji(p.current,{select:!0}))},j=function(E){if(document.activeElement===document.body)for(const A of E)A.removedNodes.length>0&&Ji(u)};document.addEventListener("focusin",y),document.addEventListener("focusout",w);const O=new MutationObserver(j);return u&&O.observe(u,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",y),document.removeEventListener("focusout",w),O.disconnect()}}},[n,u,g.paused]),_.useEffect(()=>{if(u){Sk.add(g);const y=document.activeElement;if(!u.contains(y)){const j=new CustomEvent(Ob,bk);u.addEventListener(Ob,l),u.dispatchEvent(j),j.defaultPrevented||(Rne($ne(l$(u)),{select:!0}),document.activeElement===y&&Ji(u))}return()=>{u.removeEventListener(Ob,l),setTimeout(()=>{const j=new CustomEvent(Eb,bk);u.addEventListener(Eb,d),u.dispatchEvent(j),j.defaultPrevented||Ji(y??document.body,{select:!0}),u.removeEventListener(Eb,d),Sk.remove(g)},0)}}},[u,l,d,g]);const b=_.useCallback(y=>{if(!r&&!n||g.paused)return;const w=y.key==="Tab"&&!y.altKey&&!y.ctrlKey&&!y.metaKey,j=document.activeElement;if(w&&j){const O=y.currentTarget,[E,N]=Mne(O);E&&N?!y.shiftKey&&j===N?(y.preventDefault(),r&&Ji(E,{select:!0})):y.shiftKey&&j===E&&(y.preventDefault(),r&&Ji(N,{select:!0})):j===O&&y.preventDefault()}},[r,n,g.paused]);return h.jsx(qe.div,{tabIndex:-1,...s,ref:m,onKeyDown:b})});Qp.displayName=kne;function Rne(e,{select:t=!1}={}){const r=document.activeElement;for(const n of e)if(Ji(n,{select:t}),document.activeElement!==r)return}function Mne(e){const t=l$(e),r=wk(t,e),n=wk(t.reverse(),e);return[r,n]}function l$(e){const t=[],r=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:n=>{const i=n.tagName==="INPUT"&&n.type==="hidden";return n.disabled||n.hidden||i?NodeFilter.FILTER_SKIP:n.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;r.nextNode();)t.push(r.currentNode);return t}function wk(e,t){for(const r of e)if(!Ine(r,{upTo:t}))return r}function Ine(e,{upTo:t}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function Dne(e){return e instanceof HTMLInputElement&&"select"in e}function Ji(e,{select:t=!1}={}){if(e&&e.focus){const r=document.activeElement;e.focus({preventScroll:!0}),e!==r&&Dne(e)&&t&&e.select()}}var Sk=Lne();function Lne(){let e=[];return{add(t){const r=e[0];t!==r&&r?.pause(),e=_k(e,t),e.unshift(t)},remove(t){e=_k(e,t),e[0]?.resume()}}}function _k(e,t){const r=[...e],n=r.indexOf(t);return n!==-1&&r.splice(n,1),r}function $ne(e){return e.filter(t=>t.tagName!=="A")}var Bne=Ew[" useId ".trim().toString()]||(()=>{}),Fne=0;function Xn(e){const[t,r]=_.useState(Bne());return Rt(()=>{r(n=>n??String(Fne++))},[e]),e||(t?`radix-${t}`:"")}const zne=["top","right","bottom","left"],ao=Math.min,zr=Math.max,tp=Math.round,Zf=Math.floor,Yn=e=>({x:e,y:e}),qne={left:"right",right:"left",bottom:"top",top:"bottom"},Une={start:"end",end:"start"};function fw(e,t,r){return zr(e,ao(t,r))}function Oi(e,t){return typeof e=="function"?e(t):e}function Ei(e){return e.split("-")[0]}function Zs(e){return e.split("-")[1]}function US(e){return e==="x"?"y":"x"}function WS(e){return e==="y"?"height":"width"}const Wne=new Set(["top","bottom"]);function Vn(e){return Wne.has(Ei(e))?"y":"x"}function HS(e){return US(Vn(e))}function Hne(e,t,r){r===void 0&&(r=!1);const n=Zs(e),i=HS(e),o=WS(i);let s=i==="x"?n===(r?"end":"start")?"right":"left":n==="start"?"bottom":"top";return t.reference[o]>t.floating[o]&&(s=rp(s)),[s,rp(s)]}function Vne(e){const t=rp(e);return[dw(e),t,dw(t)]}function dw(e){return e.replace(/start|end/g,t=>Une[t])}const jk=["left","right"],Ok=["right","left"],Gne=["top","bottom"],Kne=["bottom","top"];function Xne(e,t,r){switch(e){case"top":case"bottom":return r?t?Ok:jk:t?jk:Ok;case"left":case"right":return t?Gne:Kne;default:return[]}}function Yne(e,t,r,n){const i=Zs(e);let o=Xne(Ei(e),r==="start",n);return i&&(o=o.map(s=>s+"-"+i),t&&(o=o.concat(o.map(dw)))),o}function rp(e){return e.replace(/left|right|bottom|top/g,t=>qne[t])}function Qne(e){return{top:0,right:0,bottom:0,left:0,...e}}function c$(e){return typeof e!="number"?Qne(e):{top:e,right:e,bottom:e,left:e}}function np(e){const{x:t,y:r,width:n,height:i}=e;return{width:n,height:i,top:r,left:t,right:t+n,bottom:r+i,x:t,y:r}}function Ek(e,t,r){let{reference:n,floating:i}=e;const o=Vn(t),s=HS(t),u=WS(s),f=Ei(t),l=o==="y",d=n.x+n.width/2-i.width/2,p=n.y+n.height/2-i.height/2,m=n[u]/2-i[u]/2;let g;switch(f){case"top":g={x:d,y:n.y-i.height};break;case"bottom":g={x:d,y:n.y+n.height};break;case"right":g={x:n.x+n.width,y:p};break;case"left":g={x:n.x-i.width,y:p};break;default:g={x:n.x,y:n.y}}switch(Zs(t)){case"start":g[s]-=m*(r&&l?-1:1);break;case"end":g[s]+=m*(r&&l?-1:1);break}return g}async function Zne(e,t){var r;t===void 0&&(t={});const{x:n,y:i,platform:o,rects:s,elements:u,strategy:f}=e,{boundary:l="clippingAncestors",rootBoundary:d="viewport",elementContext:p="floating",altBoundary:m=!1,padding:g=0}=Oi(t,e),b=c$(g),w=u[m?p==="floating"?"reference":"floating":p],j=np(await o.getClippingRect({element:(r=await(o.isElement==null?void 0:o.isElement(w)))==null||r?w:w.contextElement||await(o.getDocumentElement==null?void 0:o.getDocumentElement(u.floating)),boundary:l,rootBoundary:d,strategy:f})),O=p==="floating"?{x:n,y:i,width:s.floating.width,height:s.floating.height}:s.reference,E=await(o.getOffsetParent==null?void 0:o.getOffsetParent(u.floating)),N=await(o.isElement==null?void 0:o.isElement(E))?await(o.getScale==null?void 0:o.getScale(E))||{x:1,y:1}:{x:1,y:1},A=np(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({elements:u,rect:O,offsetParent:E,strategy:f}):O);return{top:(j.top-A.top+b.top)/N.y,bottom:(A.bottom-j.bottom+b.bottom)/N.y,left:(j.left-A.left+b.left)/N.x,right:(A.right-j.right+b.right)/N.x}}const Jne=async(e,t,r)=>{const{placement:n="bottom",strategy:i="absolute",middleware:o=[],platform:s}=r,u=o.filter(Boolean),f=await(s.isRTL==null?void 0:s.isRTL(t));let l=await s.getElementRects({reference:e,floating:t,strategy:i}),{x:d,y:p}=Ek(l,n,f),m=n,g={},b=0;for(let w=0;w({name:"arrow",options:e,async fn(t){const{x:r,y:n,placement:i,rects:o,platform:s,elements:u,middlewareData:f}=t,{element:l,padding:d=0}=Oi(e,t)||{};if(l==null)return{};const p=c$(d),m={x:r,y:n},g=HS(i),b=WS(g),y=await s.getDimensions(l),w=g==="y",j=w?"top":"left",O=w?"bottom":"right",E=w?"clientHeight":"clientWidth",N=o.reference[b]+o.reference[g]-m[g]-o.floating[b],A=m[g]-o.reference[g],C=await(s.getOffsetParent==null?void 0:s.getOffsetParent(l));let T=C?C[E]:0;(!T||!await(s.isElement==null?void 0:s.isElement(C)))&&(T=u.floating[E]||o.floating[b]);const R=N/2-A/2,I=T/2-y[b]/2-1,z=ao(p[j],I),$=ao(p[O],I),L=z,U=T-y[b]-$,W=T/2-y[b]/2+R,V=fw(L,W,U),G=!f.arrow&&Zs(i)!=null&&W!==V&&o.reference[b]/2-(WW<=0)){var $,L;const W=((($=o.flip)==null?void 0:$.index)||0)+1,V=T[W];if(V&&(!(p==="alignment"?O!==Vn(V):!1)||z.every(D=>Vn(D.placement)===O?D.overflows[0]>0:!0)))return{data:{index:W,overflows:z},reset:{placement:V}};let G=(L=z.filter(Y=>Y.overflows[0]<=0).sort((Y,D)=>Y.overflows[1]-D.overflows[1])[0])==null?void 0:L.placement;if(!G)switch(g){case"bestFit":{var U;const Y=(U=z.filter(D=>{if(C){const Q=Vn(D.placement);return Q===O||Q==="y"}return!0}).map(D=>[D.placement,D.overflows.filter(Q=>Q>0).reduce((Q,J)=>Q+J,0)]).sort((D,Q)=>D[1]-Q[1])[0])==null?void 0:U[0];Y&&(G=Y);break}case"initialPlacement":G=u;break}if(i!==G)return{reset:{placement:G}}}return{}}}};function Pk(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function Ak(e){return zne.some(t=>e[t]>=0)}const rie=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:r,platform:n}=t,{strategy:i="referenceHidden",...o}=Oi(e,t);switch(i){case"referenceHidden":{const s=await n.detectOverflow(t,{...o,elementContext:"reference"}),u=Pk(s,r.reference);return{data:{referenceHiddenOffsets:u,referenceHidden:Ak(u)}}}case"escaped":{const s=await n.detectOverflow(t,{...o,altBoundary:!0}),u=Pk(s,r.floating);return{data:{escapedOffsets:u,escaped:Ak(u)}}}default:return{}}}}},u$=new Set(["left","top"]);async function nie(e,t){const{placement:r,platform:n,elements:i}=e,o=await(n.isRTL==null?void 0:n.isRTL(i.floating)),s=Ei(r),u=Zs(r),f=Vn(r)==="y",l=u$.has(s)?-1:1,d=o&&f?-1:1,p=Oi(t,e);let{mainAxis:m,crossAxis:g,alignmentAxis:b}=typeof p=="number"?{mainAxis:p,crossAxis:0,alignmentAxis:null}:{mainAxis:p.mainAxis||0,crossAxis:p.crossAxis||0,alignmentAxis:p.alignmentAxis};return u&&typeof b=="number"&&(g=u==="end"?b*-1:b),f?{x:g*d,y:m*l}:{x:m*l,y:g*d}}const iie=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var r,n;const{x:i,y:o,placement:s,middlewareData:u}=t,f=await nie(t,e);return s===((r=u.offset)==null?void 0:r.placement)&&(n=u.arrow)!=null&&n.alignmentOffset?{}:{x:i+f.x,y:o+f.y,data:{...f,placement:s}}}}},oie=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:r,y:n,placement:i,platform:o}=t,{mainAxis:s=!0,crossAxis:u=!1,limiter:f={fn:j=>{let{x:O,y:E}=j;return{x:O,y:E}}},...l}=Oi(e,t),d={x:r,y:n},p=await o.detectOverflow(t,l),m=Vn(Ei(i)),g=US(m);let b=d[g],y=d[m];if(s){const j=g==="y"?"top":"left",O=g==="y"?"bottom":"right",E=b+p[j],N=b-p[O];b=fw(E,b,N)}if(u){const j=m==="y"?"top":"left",O=m==="y"?"bottom":"right",E=y+p[j],N=y-p[O];y=fw(E,y,N)}const w=f.fn({...t,[g]:b,[m]:y});return{...w,data:{x:w.x-r,y:w.y-n,enabled:{[g]:s,[m]:u}}}}}},aie=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:r,y:n,placement:i,rects:o,middlewareData:s}=t,{offset:u=0,mainAxis:f=!0,crossAxis:l=!0}=Oi(e,t),d={x:r,y:n},p=Vn(i),m=US(p);let g=d[m],b=d[p];const y=Oi(u,t),w=typeof y=="number"?{mainAxis:y,crossAxis:0}:{mainAxis:0,crossAxis:0,...y};if(f){const E=m==="y"?"height":"width",N=o.reference[m]-o.floating[E]+w.mainAxis,A=o.reference[m]+o.reference[E]-w.mainAxis;gA&&(g=A)}if(l){var j,O;const E=m==="y"?"width":"height",N=u$.has(Ei(i)),A=o.reference[p]-o.floating[E]+(N&&((j=s.offset)==null?void 0:j[p])||0)+(N?0:w.crossAxis),C=o.reference[p]+o.reference[E]+(N?0:((O=s.offset)==null?void 0:O[p])||0)-(N?w.crossAxis:0);b |