@undp/data-viz 2.3.13 → 2.3.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/BiVariateChoroplethMap.cjs +1 -1
- package/dist/BiVariateChoroplethMap.cjs.map +1 -1
- package/dist/BiVariateChoroplethMap.d.ts +6 -0
- package/dist/BiVariateChoroplethMap.js +330 -297
- package/dist/BiVariateChoroplethMap.js.map +1 -1
- package/dist/ChoroplethMap.cjs +1 -1
- package/dist/ChoroplethMap.cjs.map +1 -1
- package/dist/ChoroplethMap.d.ts +6 -0
- package/dist/ChoroplethMap.js +359 -326
- package/dist/ChoroplethMap.js.map +1 -1
- package/dist/DotDensityMap.cjs +1 -1
- package/dist/DotDensityMap.cjs.map +1 -1
- package/dist/DotDensityMap.d.ts +8 -1
- package/dist/DotDensityMap.js +319 -286
- package/dist/DotDensityMap.js.map +1 -1
- package/dist/{GraphEl-Bb5oGHoa.js → GraphEl-BgNA-xFf.js} +10 -5
- package/dist/GraphEl-BgNA-xFf.js.map +1 -0
- package/dist/GraphEl-Bl1Hnqnd.cjs +2 -0
- package/dist/GraphEl-Bl1Hnqnd.cjs.map +1 -0
- package/dist/GriddedGraphs.cjs +1 -1
- package/dist/GriddedGraphs.d.ts +8 -1
- package/dist/GriddedGraphs.js +1 -1
- package/dist/GriddedGraphsFromConfig.d.ts +8 -1
- package/dist/HybridMap.cjs +1 -1
- package/dist/HybridMap.cjs.map +1 -1
- package/dist/HybridMap.d.ts +8 -1
- package/dist/HybridMap.js +416 -382
- package/dist/HybridMap.js.map +1 -1
- package/dist/MultiGraphDashboard.d.ts +8 -1
- package/dist/MultiGraphDashboardFromConfig.d.ts +8 -1
- package/dist/PerformanceIntensiveMultiGraphDashboard.d.ts +8 -1
- package/dist/PerformanceIntensiveMultiGraphDashboardFromConfig.d.ts +8 -1
- package/dist/PerformanceIntensiveScrollStory.d.ts +8 -1
- package/dist/ScatterPlot.cjs +1 -1
- package/dist/ScatterPlot.cjs.map +1 -1
- package/dist/ScatterPlot.d.ts +2 -0
- package/dist/ScatterPlot.js +408 -403
- package/dist/ScatterPlot.js.map +1 -1
- package/dist/ScrollStory.d.ts +8 -1
- package/dist/SingleGraphDashboard.cjs +1 -1
- package/dist/SingleGraphDashboard.d.ts +8 -1
- package/dist/SingleGraphDashboard.js +1 -1
- package/dist/SingleGraphDashboardFromConfig.d.ts +8 -1
- package/dist/SingleGraphDashboardGeoHubMaps.d.ts +8 -1
- package/dist/SingleGraphDashboardGeoHubMapsFromConfig.d.ts +8 -1
- package/dist/SingleGraphDashboardThreeDGraphs.d.ts +8 -1
- package/dist/SingleGraphDashboardThreeDGraphsFromConfig.d.ts +8 -1
- package/dist/StripChart.cjs +1 -1
- package/dist/StripChart.cjs.map +1 -1
- package/dist/StripChart.js +330 -334
- package/dist/StripChart.js.map +1 -1
- package/dist/Types.d.ts +9 -1
- package/dist/index.d.ts +36 -3
- package/dist/style.css +1 -1
- package/package.json +1 -1
- package/dist/GraphEl-Bb5oGHoa.js.map +0 -1
- package/dist/GraphEl-BerZfJ3j.cjs +0 -2
- package/dist/GraphEl-BerZfJ3j.cjs.map +0 -1
package/dist/ScatterPlot.cjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("./index-CHPV5EwG-6v2a2njQ.cjs"),ei=require("./parse-xYI9yrvL.cjs"),E=require("react"),ti=require("./getSliderMarks-CIuSoedo.cjs"),ii=require("./index-DQA8q5sC.cjs"),pi=require("./index-Cno4Q0YE.cjs"),ni=require("./simple-statistics-xm8c0LQQ.cjs"),hi=require("./Tooltip-BLa2EfMs.cjs"),b=require("./checkIfNullOrUndefined-BCW3Y1ML.cjs"),te=require("./Colors.cjs"),oi=require("./numberFormattingFunction-02t-wJta.cjs"),_t=require("./customArea-B1LWQBmM.cjs"),si=require("./Axis-Jt_tmhxS.cjs"),li=require("./AxisTitle-DV4n0RxE.cjs"),gi=require("./XTicksAndGridLines-CekrPykD.cjs"),ri=require("./ReferenceLine-M9aP3dj-.cjs"),yi=require("./RegressionLine-Ci-Dh0w0.cjs"),vi=require("./YTicksAndGridLines-UzVC5eBM.cjs"),bi=require("./index-D69M6klB.cjs"),Ai=require("./DetailsModal-DIRTulvr.cjs"),ji=require("./pow-BnyPO-NX.cjs"),ai=require("./linear-CgUCbw9F.cjs"),Oi=require("./delaunay-rcy0HhZi.cjs"),Ht=require("./proxy-C4-uo6nS.cjs"),Ci=require("./use-in-view-C3o_ntMv.cjs"),ci=require("./index-CoobIWNj.cjs"),Ri=require("./GraphFooter.cjs"),ki=require("./GraphHeader.cjs"),wi=require("./ColorLegendWithMouseOver.cjs"),Li=require("./EmptyState-B4c-CrXs.cjs"),ui=require("./index-sbKVyHS2.cjs"),Si=require("./ensureCompleteData-D9bQTiVS.cjs"),xi=require("./uniqBy-O05lp2S5.cjs"),fi=require("./GraphContainer-B1EDxJ0S.cjs");function Ei(i){const e=o.compilerRuntimeExports.c(217),{data:n,width:ie,height:w,showLabels:Fe,colors:f,colorDomain:R,radius:P,xAxisTitle:y,yAxisTitle:H,leftMargin:T,rightMargin:dt,topMargin:wt,bottomMargin:Xt,tooltip:pt,onSeriesMouseOver:ne,refXValues:Lt,refYValues:St,highlightAreaSettings:Et,selectedColor:Se,highlightedDataPoints:G,maxRadiusValue:ht,maxXValue:gt,minXValue:k,maxYValue:Ue,minYValue:j,onSeriesMouseClick:N,rtl:He,annotations:Ge,customHighlightAreaSettings:We,regressionLine:Ee,resetSelectionOnDoubleClick:Ne,detailsOnClick:$,noOfXTicks:Be,noOfYTicks:ze,labelColor:W,xSuffix:$e,ySuffix:Me,xPrefix:De,yPrefix:Ve,styles:s,classNames:l,animate:a,dimmedOpacity:M,precision:D,showHighlightedDataPointsLabels:Nt,customLayers:V}=i,yt=E.useRef(null);let vt;e[0]!==a.amount||e[1]!==a.once?(vt={once:a.once,amount:a.amount},e[0]=a.amount,e[1]=a.once,e[2]=vt):vt=e[2];const A=Ci.useInView(yt,vt),[L,qe]=E.useState(void 0),[X,Je]=E.useState(void 0),[bt,oe]=E.useState(void 0),[p,c]=E.useState(void 0),$t=y?Xt+50:Xt,Mt=H?T+30:T;let At;e[3]!==dt||e[4]!==$t||e[5]!==Mt||e[6]!==wt?(At={top:wt,bottom:$t,left:Mt,right:dt},e[3]=dt,e[4]=$t,e[5]=Mt,e[6]=wt,e[7]=At):At=e[7];const d=At;let B,se,le,re,ae,ce,Y,ue,xe,fe,z,me,J,de,K,pe,F,Q;if(e[8]!==a||e[9]!==Ge||e[10]!==l?.graphObjectValues||e[11]!==l?.regLine||e[12]!==l?.xAxis?.axis||e[13]!==l?.xAxis?.gridLines||e[14]!==l?.xAxis?.labels||e[15]!==l?.xAxis?.title||e[16]!==l?.yAxis?.gridLines||e[17]!==l?.yAxis?.labels||e[18]!==l?.yAxis?.title||e[19]!==R||e[20]!==f||e[21]!==We||e[22]!==V||e[23]!==n||e[24]!==$||e[25]!==M||e[26]!==w||e[27]!==Et||e[28]!==G||e[29]!==A||e[30]!==W||e[31]!==T||e[32]!==d.bottom||e[33]!==d.left||e[34]!==d.right||e[35]!==d.top||e[36]!==ht||e[37]!==gt||e[38]!==Ue||e[39]!==k||e[40]!==j||e[41]!==X||e[42]!==L||e[43]!==Be||e[44]!==ze||e[45]!==N||e[46]!==ne||e[47]!==D||e[48]!==P||e[49]!==Lt||e[50]!==St||e[51]!==Ee||e[52]!==Ne||e[53]!==He||e[54]!==Se||e[55]!==Nt||e[56]!==Fe||e[57]!==s?.graphObjectValues||e[58]!==s?.regLine||e[59]!==s?.xAxis?.axis||e[60]!==s?.xAxis?.gridLines||e[61]!==s?.xAxis?.labels||e[62]!==s?.xAxis?.title||e[63]!==s?.yAxis?.gridLines||e[64]!==s?.yAxis?.labels||e[65]!==s?.yAxis?.title||e[66]!==ie||e[67]!==y||e[68]!==De||e[69]!==$e||e[70]!==H||e[71]!==Ve||e[72]!==Me){const Ke=n.map(en),h=ie-d.left-d.right,v=w-d.top-d.bottom,S=n.filter(_i).length!==n.length?ji.sqrt().domain([0,ht]).range([.25,P]).nice():void 0,Pe=Ke.filter(Zi).length===0?Ke:pi.orderBy(Ke.filter(Qi),"radius","desc"),u=ai.linear().domain([k,gt]).range([0,h]).nice(),m=ai.linear().domain([j,Ue]).range([v,0]).nice(),Dt=u.ticks(Be),U=m.ticks(ze),Yt=Oi.Delaunay.from(Pe.filter(Ki),t=>u(t.x),t=>m(t.y)).voronoi([0,0,h<0?0:h,v<0?0:v]),Ft=ni.linearRegression(n.filter(Ji).map(t=>[u(t.x),m(t.y)])),Vt=ni.linearRegressionLine(Ft);se=Ht.motion.svg,ue=`${ie}px`,xe=`${w}px`,fe=`0 0 ${ie} ${w}`,z="ltr",me=yt,le=`translate(${d.left},${d.top})`;let Qe;e[91]!==a||e[92]!==We||e[93]!==A||e[94]!==u||e[95]!==m?(Qe=o.jsxRuntimeExports.jsx(_t.CustomArea,{areaSettings:We,scaleX:u,scaleY:m,animate:a,isInView:A},"custom-area"),e[91]=a,e[92]=We,e[93]=A,e[94]=u,e[95]=m,e[96]=Qe):Qe=e[96],re=o.jsxRuntimeExports.jsxs(ci.AnimatePresence,{children:[o.jsxRuntimeExports.jsx(bi.HighlightAreaForScatterPlot,{areaSettings:Et,width:h,height:v,scaleX:u,scaleY:m,animate:a,isInView:A},"highlight-area"),Qe]});const Ze=s?.yAxis?.gridLines,jt=s?.yAxis?.labels;let _e;e[97]!==Ze||e[98]!==jt?(_e={gridLines:Ze,labels:jt},e[97]=Ze,e[98]=jt,e[99]=_e):_e=e[99];const et=l?.yAxis?.gridLines,Ot=l?.yAxis?.labels;let Te;e[100]!==et||e[101]!==Ot?(Te={gridLines:et,labels:Ot},e[100]=et,e[101]=Ot,e[102]=Te):Te=e[102];const r=m(j<0?0:j),tt=m(j<0?0:j),Ut=h+d.right,it=j<0?0:j;let nt;e[103]!==D||e[104]!==it||e[105]!==Ve||e[106]!==Me?(nt=oi.numberFormattingFunction(it,"NA",D,Ve,Me),e[103]=D,e[104]=it,e[105]=Ve,e[106]=Me,e[107]=nt):nt=e[107];const q=m(j<0?0:j);let ot;e[108]!==q?(ot={x:0,y:q,dy:"0.33em",dx:-4},e[108]=q,e[109]=ot):ot=e[109];const Xe=l?.xAxis?.axis,x=l?.yAxis?.labels;let O;e[110]!==Xe||e[111]!==x?(O={axis:Xe,label:x},e[110]=Xe,e[111]=x,e[112]=O):O=e[112];const Ct=s?.xAxis?.axis;let je;e[113]!==s?.yAxis?.labels?(je=s?.yAxis?.labels||{},e[113]=s?.yAxis?.labels,e[114]=je):je=e[114];let st;e[115]!==je?(st={textAnchor:"end",...je},e[115]=je,e[116]=st):st=e[116];let Oe;e[117]!==Ct||e[118]!==st?(Oe={axis:Ct,label:st},e[117]=Ct,e[118]=st,e[119]=Oe):Oe=e[119];let Rt;e[120]!==r||e[121]!==tt||e[122]!==Ut||e[123]!==nt||e[124]!==ot||e[125]!==O||e[126]!==Oe?(Rt=o.jsxRuntimeExports.jsx(si.Axis,{y1:r,y2:tt,x1:0,x2:Ut,label:nt,labelPos:ot,classNames:O,styles:Oe}),e[120]=r,e[121]=tt,e[122]=Ut,e[123]=nt,e[124]=ot,e[125]=O,e[126]=Oe,e[127]=Rt):Rt=e[127];const lt=0-T-15,rt=v/2,at=s?.yAxis?.title,ct=l?.yAxis?.title;let ut;e[128]!==lt||e[129]!==rt||e[130]!==at||e[131]!==ct||e[132]!==H?(ut=o.jsxRuntimeExports.jsx(li.AxisTitle,{x:lt,y:rt,style:at,className:ct,text:H,rotate90:!0}),e[128]=lt,e[129]=rt,e[130]=at,e[131]=ct,e[132]=H,e[133]=ut):ut=e[133],ae=o.jsxRuntimeExports.jsxs("g",{children:[o.jsxRuntimeExports.jsx(vi.YTicksAndGridLines,{values:U.filter(zi),y:U.filter(Bi).map(t=>m(t)),x1:0,x2:h+d.right,styles:_e,classNames:Te,suffix:Me,prefix:Ve,labelType:"secondary",showGridLines:!0,labelPos:"side",precision:D}),Rt,ut]});const xt=s?.xAxis?.gridLines,ft=s?.xAxis?.labels;let mt;e[134]!==xt||e[135]!==ft?(mt={gridLines:xt,labels:ft},e[134]=xt,e[135]=ft,e[136]=mt):mt=e[136];const kt=l?.xAxis?.gridLines,Ce=l?.xAxis?.labels;let Z;e[137]!==kt||e[138]!==Ce?(Z={gridLines:kt,labels:Ce},e[137]=kt,e[138]=Ce,e[139]=Z):Z=e[139];const Re=u(k<0?0:k),ke=u(k<0?0:k),we=k<0?0:k;let I;e[140]!==D||e[141]!==we||e[142]!==De||e[143]!==$e?(I=oi.numberFormattingFunction(we,"NA",D,De,$e),e[140]=D,e[141]=we,e[142]=De,e[143]=$e,e[144]=I):I=e[144];const Le=u(k<0?0:k);let _;e[145]!==v||e[146]!==Le?(_={x:Le,y:v,dy:"1em",dx:0},e[145]=v,e[146]=Le,e[147]=_):_=e[147];const g=l?.xAxis?.axis,ee=l?.yAxis?.labels;let qt;e[148]!==g||e[149]!==ee?(qt={axis:g,label:ee},e[148]=g,e[149]=ee,e[150]=qt):qt=e[150];const Bt=s?.xAxis?.axis;let It;e[151]!==s?.yAxis?.labels?(It=s?.yAxis?.labels||{},e[151]=s?.yAxis?.labels,e[152]=It):It=e[152];let Pt;e[153]!==It?(Pt={textAnchor:"middle",...It},e[153]=It,e[154]=Pt):Pt=e[154];let Tt;e[155]!==Bt||e[156]!==Pt?(Tt={axis:Bt,label:Pt},e[155]=Bt,e[156]=Pt,e[157]=Tt):Tt=e[157];let Gt;e[158]!==v||e[159]!==Re||e[160]!==ke||e[161]!==I||e[162]!==_||e[163]!==qt||e[164]!==Tt?(Gt=o.jsxRuntimeExports.jsx(si.Axis,{x1:Re,x2:ke,y1:0,y2:v,label:I,labelPos:_,classNames:qt,styles:Tt}),e[158]=v,e[159]=Re,e[160]=ke,e[161]=I,e[162]=_,e[163]=qt,e[164]=Tt,e[165]=Gt):Gt=e[165];const zt=h/2,Jt=v+30,Kt=s?.xAxis?.title,Qt=l?.xAxis?.title;let Wt;e[166]!==zt||e[167]!==Jt||e[168]!==Kt||e[169]!==Qt||e[170]!==y?(Wt=o.jsxRuntimeExports.jsx(li.AxisTitle,{x:zt,y:Jt,style:Kt,className:Qt,text:y}),e[166]=zt,e[167]=Jt,e[168]=Kt,e[169]=Qt,e[170]=y,e[171]=Wt):Wt=e[171],ce=o.jsxRuntimeExports.jsxs("g",{children:[o.jsxRuntimeExports.jsx(gi.XTicksAndGridLines,{values:Dt.filter(Wi),x:Dt.filter(Gi).map(t=>u(t)),y1:0,y2:v,styles:mt,classNames:Z,suffix:$e,prefix:De,labelType:"primary",showGridLines:!0,precision:D}),Gt,Wt]}),e[172]!==V?(Y=V.filter(Hi).map(Ui),e[172]=V,e[173]=Y):Y=e[173],B=ci.AnimatePresence,J=Pe.filter(Fi).map((t,Ye)=>o.jsxRuntimeExports.jsx("path",{d:Yt.renderCell(Pe.findIndex(C=>C.id===t.id)),opacity:0,onMouseEnter:C=>{qe(t),c(C.clientY),oe(C.clientX),ne?.(t)},onMouseMove:C=>{qe(t),c(C.clientY),oe(C.clientX)},onMouseLeave:()=>{qe(void 0),oe(void 0),c(void 0),ne?.(void 0)},onClick:()=>{(N||$)&&(ii.isEqual(X,t)&&Ne?(Je(void 0),N?.(void 0)):(Je(t),N?.(t)))}},`tesselation_${t.label||Ye}`)),de=Pe.filter(Yi).map((t,Ye)=>o.jsxRuntimeExports.jsxs(Ht.motion.g,{variants:{initial:{x:u(t.x),y:m(t.y),opacity:Se?t.color&&f[R.indexOf(`${t.color}`)]===Se?1:M:L?L.id===t.id?1:M:G.length!==0?G.indexOf(t.label||"")!==-1?1:M:1},whileInView:{x:u(t.x),y:m(t.y),opacity:Se?t.color&&f[R.indexOf(`${t.color}`)]===Se?1:M:L?L.id===t.id?1:M:G.length!==0?G.indexOf(t.label||"")!==-1?1:M:1,transition:{duration:a.duration}}},initial:"initial",animate:A?"whileInView":"initial",exit:{opacity:0,transition:{duration:a.duration}},onMouseEnter:C=>{qe(t),c(C.clientY),oe(C.clientX),ne?.(t)},onMouseMove:C=>{qe(t),c(C.clientY),oe(C.clientX)},onMouseLeave:()=>{qe(void 0),oe(void 0),c(void 0),ne?.(void 0)},onClick:()=>{(N||$)&&(ii.isEqual(X,t)&&Ne?(Je(void 0),N?.(void 0)):(Je(t),N?.(t)))},children:[o.jsxRuntimeExports.jsx(Ht.motion.circle,{cx:0,cy:0,exit:{r:0,transition:{duration:a.duration}},variants:{initial:{r:0,fill:n.filter(Xi).length===0?f[0]:t.color?f[R.indexOf(`${t.color}`)]:te.Colors.gray,stroke:n.filter(Ti).length===0?f[0]:t.color?f[R.indexOf(`${t.color}`)]:te.Colors.gray},whileInView:{r:S?S(t.radius||0):P,fill:n.filter(Pi).length===0?f[0]:t.color?f[R.indexOf(`${t.color}`)]:te.Colors.gray,stroke:n.filter(Ii).length===0?f[0]:t.color?f[R.indexOf(`${t.color}`)]:te.Colors.gray,transition:{duration:a.duration}}},initial:"initial",animate:A?"whileInView":"initial",style:{fillOpacity:.6}}),Fe&&!b.checkIfNullOrUndefined(t.label)?o.jsxRuntimeExports.jsx(Ht.motion.text,{style:{...s?.graphObjectValues||{}},className:o.mo("graph-value text-sm",l?.graphObjectValues),y:0,exit:{opacity:0,transition:{duration:a.duration}},variants:{initial:{x:S?S(t.radius||0):P,opacity:0,fill:W||(n.filter(qi).length===0?f[0]:t.color?f[R.indexOf(`${t.color}`)]:te.Colors.gray)},whileInView:{x:S?S(t.radius||0):P,opacity:1,fill:W||(n.filter(Vi).length===0?f[0]:t.color?f[R.indexOf(`${t.color}`)]:te.Colors.gray),transition:{duration:a.duration}}},initial:"initial",animate:A?"whileInView":"initial",dy:"0.33em",dx:3,children:t.label}):G.length!==0&&!b.checkIfNullOrUndefined(t.label)&&Nt&&G.indexOf(t.label)!==-1?o.jsxRuntimeExports.jsx(Ht.motion.text,{style:{...s?.graphObjectValues||{}},className:o.mo("graph-value text-sm",l?.graphObjectValues),y:0,exit:{opacity:0,transition:{duration:a.duration}},variants:{initial:{x:S?S(t.radius||0):P,opacity:0,fill:W||(n.filter(Di).length===0?f[0]:t.color?f[R.indexOf(`${t.color}`)]:te.Colors.gray)},whileInView:{x:S?S(t.radius||0):P,opacity:1,fill:W||(n.filter(Mi).length===0?f[0]:t.color?f[R.indexOf(`${t.color}`)]:te.Colors.gray),transition:{duration:a.duration}}},initial:"initial",animate:A?"whileInView":"initial",dy:"0.33em",dx:3,children:t.label}):null]},`${t.label||Ye}`)),K=Lt.map((t,Ye)=>o.jsxRuntimeExports.jsx(ri.RefLineX,{text:t.text,color:t.color,x:u(t.value),y1:0,y2:v,textSide:u(t.value)>h*.75||He?"left":"right",classNames:t.classNames,styles:t.styles,animate:a,isInView:A},Ye)),pe=St.map((t,Ye)=>o.jsxRuntimeExports.jsx(ri.RefLineY,{text:t.text,color:t.color,y:m(t.value),x1:0,x2:h,classNames:t.classNames,styles:t.styles,animate:a,isInView:A},Ye));const Zt=Ge.map((t,Ye)=>{const C=_t.getLineEndPoint({x:t.xCoordinate?u(t.xCoordinate)+(t.xOffset||0):0+(t.xOffset||0),y:t.yCoordinate?m(t.yCoordinate)+(t.yOffset||0)-8:0+(t.yOffset||0)-8},{x:t.xCoordinate?u(t.xCoordinate):0,y:t.yCoordinate?m(t.yCoordinate):0},b.checkIfNullOrUndefined(t.connectorRadius)?3.5:t.connectorRadius),mi=t.showConnector?{y1:C.y,x1:C.x,y2:t.yCoordinate?m(t.yCoordinate)+(t.yOffset||0):0+(t.yOffset||0),x2:t.xCoordinate?u(t.xCoordinate)+(t.xOffset||0):0+(t.xOffset||0),cy:t.yCoordinate?m(t.yCoordinate):0,cx:t.xCoordinate?u(t.xCoordinate):0,circleRadius:b.checkIfNullOrUndefined(t.connectorRadius)?3.5:t.connectorRadius,strokeWidth:t.showConnector===!0?2:Math.min(t.showConnector||0,1)}:void 0,di={y:t.yCoordinate?m(t.yCoordinate)+(t.yOffset||0)-8:0+(t.yOffset||0)-8,x:He?0:t.xCoordinate?u(t.xCoordinate)+(t.xOffset||0):0+(t.xOffset||0),width:He?t.xCoordinate?u(t.xCoordinate)+(t.xOffset||0):0+(t.xOffset||0):h+d.right-(t.xCoordinate?u(t.xCoordinate)+(t.xOffset||0):0+(t.xOffset||0)),maxWidth:t.maxWidth,fontWeight:t.fontWeight,align:t.align};return o.jsxRuntimeExports.jsx(_t.Annotation,{color:t.color,connectorsSettings:mi,labelSettings:di,text:t.text,classNames:t.classNames,styles:t.styles,animate:a,isInView:A},Ye)});e[174]!==Zt?(F=o.jsxRuntimeExports.jsx("g",{children:Zt}),e[174]=Zt,e[175]=F):F=e[175],Q=Ee?o.jsxRuntimeExports.jsx(yi.RegressionLine,{x1:0,x2:h,y1:Vt(0),y2:Vt(h),graphHeight:v,graphWidth:h,className:l?.regLine,style:s?.regLine,color:typeof Ee=="string"?Ee:void 0,animate:a,isInView:A}):null,e[8]=a,e[9]=Ge,e[10]=l?.graphObjectValues,e[11]=l?.regLine,e[12]=l?.xAxis?.axis,e[13]=l?.xAxis?.gridLines,e[14]=l?.xAxis?.labels,e[15]=l?.xAxis?.title,e[16]=l?.yAxis?.gridLines,e[17]=l?.yAxis?.labels,e[18]=l?.yAxis?.title,e[19]=R,e[20]=f,e[21]=We,e[22]=V,e[23]=n,e[24]=$,e[25]=M,e[26]=w,e[27]=Et,e[28]=G,e[29]=A,e[30]=W,e[31]=T,e[32]=d.bottom,e[33]=d.left,e[34]=d.right,e[35]=d.top,e[36]=ht,e[37]=gt,e[38]=Ue,e[39]=k,e[40]=j,e[41]=X,e[42]=L,e[43]=Be,e[44]=ze,e[45]=N,e[46]=ne,e[47]=D,e[48]=P,e[49]=Lt,e[50]=St,e[51]=Ee,e[52]=Ne,e[53]=He,e[54]=Se,e[55]=Nt,e[56]=Fe,e[57]=s?.graphObjectValues,e[58]=s?.regLine,e[59]=s?.xAxis?.axis,e[60]=s?.xAxis?.gridLines,e[61]=s?.xAxis?.labels,e[62]=s?.xAxis?.title,e[63]=s?.yAxis?.gridLines,e[64]=s?.yAxis?.labels,e[65]=s?.yAxis?.title,e[66]=ie,e[67]=y,e[68]=De,e[69]=$e,e[70]=H,e[71]=Ve,e[72]=Me,e[73]=B,e[74]=se,e[75]=le,e[76]=re,e[77]=ae,e[78]=ce,e[79]=Y,e[80]=ue,e[81]=xe,e[82]=fe,e[83]=z,e[84]=me,e[85]=J,e[86]=de,e[87]=K,e[88]=pe,e[89]=F,e[90]=Q}else B=e[73],se=e[74],le=e[75],re=e[76],ae=e[77],ce=e[78],Y=e[79],ue=e[80],xe=e[81],fe=e[82],z=e[83],me=e[84],J=e[85],de=e[86],K=e[87],pe=e[88],F=e[89],Q=e[90];let he;e[176]!==B||e[177]!==J||e[178]!==de||e[179]!==K||e[180]!==pe||e[181]!==F||e[182]!==Q?(he=o.jsxRuntimeExports.jsxs(B,{children:[J,de,K,pe,F,Q]}),e[176]=B,e[177]=J,e[178]=de,e[179]=K,e[180]=pe,e[181]=F,e[182]=Q,e[183]=he):he=e[183];let ge;e[184]!==V?(ge=V.filter($i).map(Ni),e[184]=V,e[185]=ge):ge=e[185];let ye;e[186]!==le||e[187]!==re||e[188]!==ae||e[189]!==ce||e[190]!==Y||e[191]!==he||e[192]!==ge?(ye=o.jsxRuntimeExports.jsxs("g",{transform:le,children:[re,ae,ce,Y,he,ge]}),e[186]=le,e[187]=re,e[188]=ae,e[189]=ce,e[190]=Y,e[191]=he,e[192]=ge,e[193]=ye):ye=e[193];let ve;e[194]!==se||e[195]!==ue||e[196]!==xe||e[197]!==fe||e[198]!==z||e[199]!==me||e[200]!==ye?(ve=o.jsxRuntimeExports.jsx(se,{width:ue,height:xe,viewBox:fe,direction:z,ref:me,children:ye}),e[194]=se,e[195]=ue,e[196]=xe,e[197]=fe,e[198]=z,e[199]=me,e[200]=ye,e[201]=ve):ve=e[201];let be;e[202]!==l?.tooltip||e[203]!==bt||e[204]!==p||e[205]!==L||e[206]!==s?.tooltip||e[207]!==pt?(be=L&&pt&&bt&&p?o.jsxRuntimeExports.jsx(hi.Tooltip,{data:L,body:pt,xPos:bt,yPos:p,backgroundStyle:s?.tooltip,className:l?.tooltip}):null,e[202]=l?.tooltip,e[203]=bt,e[204]=p,e[205]=L,e[206]=s?.tooltip,e[207]=pt,e[208]=be):be=e[208];let Ae;e[209]!==l?.modal||e[210]!==$||e[211]!==X?(Ae=$&&X!==void 0?o.jsxRuntimeExports.jsx(Ai.DetailsModal,{body:$,data:X,setData:Je,className:l?.modal}):null,e[209]=l?.modal,e[210]=$,e[211]=X,e[212]=Ae):Ae=e[212];let Ie;return e[213]!==ve||e[214]!==be||e[215]!==Ae?(Ie=o.jsxRuntimeExports.jsxs(o.jsxRuntimeExports.Fragment,{children:[ve,be,Ae]}),e[213]=ve,e[214]=be,e[215]=Ae,e[216]=Ie):Ie=e[216],Ie}function Ni(i){return i.layer}function $i(i){return i.position==="after"}function Mi(i){return i.color}function Di(i){return i.color}function Vi(i){return i.color}function qi(i){return i.color}function Ii(i){return i.color}function Pi(i){return i.color}function Ti(i){return i.color}function Xi(i){return i.color}function Yi(i){return!b.checkIfNullOrUndefined(i.x)&&!b.checkIfNullOrUndefined(i.y)}function Fi(i){return!b.checkIfNullOrUndefined(i.x)&&!b.checkIfNullOrUndefined(i.y)}function Ui(i){return i.layer}function Hi(i){return i.position==="before"}function Gi(i){return i!==0}function Wi(i){return i!==0}function Bi(i){return i!==0}function zi(i){return i!==0}function Ji(i){return!b.checkIfNullOrUndefined(i.x)&&!b.checkIfNullOrUndefined(i.y)}function Ki(i){return!b.checkIfNullOrUndefined(i.x)&&!b.checkIfNullOrUndefined(i.y)}function Qi(i){return!b.checkIfNullOrUndefined(i.radius)}function Zi(i){return!b.checkIfNullOrUndefined(i.radius)}function _i(i){return i.radius===void 0||i.radius===null}function en(i,e){return{...i,id:`${e}`}}function tn(i){const e=o.compilerRuntimeExports.c(143),{data:n,graphTitle:ie,colors:w,sources:Fe,graphDescription:f,showLabels:R,height:P,width:y,footNote:H,colorDomain:T,colorLegendTitle:dt,radius:wt,xAxisTitle:Xt,yAxisTitle:pt,padding:ne,backgroundColor:Lt,leftMargin:St,rightMargin:Et,topMargin:Se,bottomMargin:G,tooltip:ht,relativeHeight:gt,onSeriesMouseOver:k,refXValues:Ue,refYValues:j,highlightAreaSettings:N,showColorScale:He,highlightedDataPoints:Ge,showHighlightedDataPointsLabels:We,graphID:Ee,maxRadiusValue:Ne,maxXValue:$,minXValue:Be,maxYValue:ze,minYValue:W,xSuffix:$e,ySuffix:Me,xPrefix:De,yPrefix:Ve,onSeriesMouseClick:s,graphDownload:l,dataDownload:a,language:M,showNAColor:D,minHeight:Nt,annotations:V,customHighlightAreaSettings:yt,theme:vt,regressionLine:A,ariaLabel:L,resetSelectionOnDoubleClick:qe,detailsOnClick:X,noOfXTicks:Je,noOfYTicks:bt,labelColor:oe,styles:p,classNames:c,animate:$t,dimmedOpacity:Mt,precision:At,customLayers:d,timeline:B}=i,se=R===void 0?!1:R,le=wt===void 0?5:wt,re=Xt===void 0?"X Axis":Xt,ae=pt===void 0?"Y Axis":pt,ce=Lt===void 0?!1:Lt,Y=St===void 0?0:St,ue=Et===void 0?10:Et,xe=Se===void 0?20:Se,fe=G===void 0?50:G;let z;e[0]!==Ue?(z=Ue===void 0?[]:Ue,e[0]=Ue,e[1]=z):z=e[1];const me=z;let J;e[2]!==j?(J=j===void 0?[]:j,e[2]=j,e[3]=J):J=e[3];const de=J;let K;e[4]!==N?(K=N===void 0?[]:N,e[4]=N,e[5]=K):K=e[5];const pe=K,F=He===void 0?!0:He;let Q;e[6]!==Ge?(Q=Ge===void 0?[]:Ge,e[6]=Ge,e[7]=Q):Q=e[7];const he=Q,ge=We===void 0?!1:We,ye=$e===void 0?"":$e,ve=Me===void 0?"":Me,be=De===void 0?"":De,Ae=Ve===void 0?"":Ve,Ie=l===void 0?!1:l,Ke=a===void 0?!1:a,h=M===void 0?"en":M,v=D===void 0?!0:D,S=Nt===void 0?0:Nt;let Pe;e[8]!==V?(Pe=V===void 0?[]:V,e[8]=V,e[9]=Pe):Pe=e[9];const u=Pe;let m;e[10]!==yt?(m=yt===void 0?[]:yt,e[10]=yt,e[11]=m):m=e[11];const Dt=m,U=vt===void 0?"light":vt,Yt=A===void 0?!1:A,Ft=qe===void 0?!0:qe,Vt=Je===void 0?5:Je,Qe=bt===void 0?5:bt,Ze=$t===void 0?!1:$t,jt=Mt===void 0?.3:Mt,_e=At===void 0?2:At;let et;e[12]!==d?(et=d===void 0?[]:d,e[12]=d,e[13]=et):et=e[13];const Ot=et;let Te;e[14]!==B?(Te=B===void 0?{enabled:!1,autoplay:!1,showOnlyActiveDate:!0}:B,e[14]=B,e[15]=Te):Te=e[15];const r=Te,[tt,Ut]=E.useState(0),[it,nt]=E.useState(0),[q,ot]=E.useState(r.autoplay);let Xe;if(e[16]!==n||e[17]!==r.dateFormat){let g;e[19]!==r.dateFormat?(g=ee=>ei.parse(`${ee.date}`,r.dateFormat||"yyyy",new Date).getTime(),e[19]=r.dateFormat,e[20]=g):g=e[20],Xe=[...new Set(n.filter(Nn).map(g))],Xe.sort(En),e[16]=n,e[17]=r.dateFormat,e[18]=Xe}else Xe=e[18];const x=Xe,[O,Ct]=E.useState(r.autoplay?0:x.length-1),[je,st]=E.useState(void 0),Oe=E.useRef(null),Rt=E.useRef(null);let lt,rt;e[21]===Symbol.for("react.memo_cache_sentinel")?(lt=()=>{const g=new ResizeObserver(ee=>{Ut(ee[0].target.clientWidth||620),nt(ee[0].target.clientHeight||480)});return Oe.current&&g.observe(Oe.current),()=>g.disconnect()},rt=[],e[21]=lt,e[22]=rt):(lt=e[21],rt=e[22]),E.useEffect(lt,rt);let at,ct;e[23]!==q||e[24]!==r.speed||e[25]!==x?(at=()=>{const g=setInterval(()=>{Ct(ee=>ee<x.length-1?ee+1:0)},(r.speed||2)*1e3);return q||clearInterval(g),()=>clearInterval(g)},ct=[x,q,r.speed],e[23]=q,e[24]=r.speed,e[25]=x,e[26]=at,e[27]=ct):(at=e[26],ct=e[27]),E.useEffect(at,ct);const ut=r.dateFormat||"yyyy";let xt;e[28]!==O||e[29]!==ut||e[30]!==r.showOnlyActiveDate||e[31]!==x?(xt=ti.getSliderMarks(x,O,r.showOnlyActiveDate,ut),e[28]=O,e[29]=ut,e[30]=r.showOnlyActiveDate,e[31]=x,e[32]=xt):xt=e[32];const ft=xt,mt=c?.graphContainer,kt=p?.graphContainer;let Ce;e[33]!==c?.description||e[34]!==c?.title||e[35]!==n||e[36]!==Ke||e[37]!==f||e[38]!==Ie||e[39]!==ie||e[40]!==p?.description||e[41]!==p?.title||e[42]!==y?(Ce=ie||f||Ie||Ke?o.jsxRuntimeExports.jsx(ki.GraphHeader,{styles:{title:p?.title,description:p?.description},classNames:{title:c?.title,description:c?.description},graphTitle:ie,graphDescription:f,width:y,graphDownload:Ie?Rt:void 0,dataDownload:Ke?n.map(Sn).filter(Ln).length>0?n.map(wn).filter(kn):n.filter(Rn):null}):null,e[33]=c?.description,e[34]=c?.title,e[35]=n,e[36]=Ke,e[37]=f,e[38]=Ie,e[39]=ie,e[40]=p?.description,e[41]=p?.title,e[42]=y,e[43]=Ce):Ce=e[43];let Z;e[44]!==O||e[45]!==ft||e[46]!==q||e[47]!==r.enabled||e[48]!==x?(Z=r.enabled&&x.length>0&&ft?o.jsxRuntimeExports.jsxs("div",{className:"flex gap-6 items-center",dir:"ltr",children:[o.jsxRuntimeExports.jsx("button",{type:"button",onClick:()=>{ot(!q)},className:"p-0 border-0 cursor-pointer bg-transparent","aria-label":q?"Click to pause animation":"Click to play animation",children:q?o.jsxRuntimeExports.jsx(ui.Pause,{}):o.jsxRuntimeExports.jsx(ui.Play,{})}),o.jsxRuntimeExports.jsx(ti.Nr,{min:x[0],max:x[x.length-1],marks:ft,step:null,defaultValue:x[x.length-1],value:x[O],onChangeComplete:g=>{Ct(x.indexOf(g))},onChange:g=>{Ct(x.indexOf(g))},"aria-label":"Time slider. Use arrow keys to adjust selected time period."})]}):null,e[44]=O,e[45]=ft,e[46]=q,e[47]=r.enabled,e[48]=x,e[49]=Z):Z=e[49];let Re;e[50]!==c?.colorLegend||e[51]!==T||e[52]!==dt||e[53]!==w||e[54]!==n||e[55]!==F||e[56]!==v||e[57]!==U||e[58]!==y?(Re=F&&n.filter(Cn).length!==0&&n.length>0?o.jsxRuntimeExports.jsx(wi.ColorLegendWithMouseOver,{width:y,colorLegendTitle:dt,colors:w||te.Colors[U].categoricalColors.colors,colorDomain:T||xi.uniqBy(n,"color",!0),setSelectedColor:st,showNAColor:v,className:c?.colorLegend}):null,e[50]=c?.colorLegend,e[51]=T,e[52]=dt,e[53]=w,e[54]=n,e[55]=F,e[56]=v,e[57]=U,e[58]=y,e[59]=Re):Re=e[59];let ke;e[60]!==n.length?(ke=n.length===0&&o.jsxRuntimeExports.jsx(Li.EmptyState,{}),e[60]=n.length,e[61]=ke):ke=e[61];let we;e[62]!==Ze||e[63]!==u||e[64]!==fe||e[65]!==c||e[66]!==T||e[67]!==w||e[68]!==Dt||e[69]!==Ot||e[70]!==n||e[71]!==X||e[72]!==jt||e[73]!==pe||e[74]!==he||e[75]!==O||e[76]!==oe||e[77]!==h||e[78]!==Y||e[79]!==Ne||e[80]!==$||e[81]!==ze||e[82]!==Be||e[83]!==W||e[84]!==Vt||e[85]!==Qe||e[86]!==s||e[87]!==k||e[88]!==_e||e[89]!==le||e[90]!==me||e[91]!==de||e[92]!==Yt||e[93]!==Ft||e[94]!==ue||e[95]!==je||e[96]!==ge||e[97]!==se||e[98]!==p||e[99]!==it||e[100]!==tt||e[101]!==U||e[102]!==r.dateFormat||e[103]!==r.enabled||e[104]!==ht||e[105]!==xe||e[106]!==x||e[107]!==re||e[108]!==be||e[109]!==ye||e[110]!==ae||e[111]!==Ae||e[112]!==ve?(we=tt&&it&&n.length>0?o.jsxRuntimeExports.jsx(Ei,{data:Si.ensureCompleteDataForScatterPlot(n,r.dateFormat||"yyyy").filter(g=>r.enabled?`${g.date}`===ei.format(new Date(x[O]),r.dateFormat||"yyyy"):g),width:tt,height:it,colorDomain:n.filter(On).length===0?[]:T||xi.uniqBy(n,"color",!0),colors:n.filter(jn).length===0?w?[w]:[te.Colors.primaryColors["blue-600"]]:w||te.Colors[U].categoricalColors.colors,xAxisTitle:re,yAxisTitle:ae,refXValues:me,refYValues:de,showLabels:se,radius:le,leftMargin:Y,rightMargin:ue,topMargin:xe,bottomMargin:fe,tooltip:ht,onSeriesMouseOver:k,highlightAreaSettings:pe,highlightedDataPoints:n.filter(An).length===0?[]:he,showHighlightedDataPointsLabels:ge,selectedColor:je,maxRadiusValue:b.checkIfNullOrUndefined(Ne)?Math.max(...n.map(bn).filter(vn)):Ne,maxXValue:b.checkIfNullOrUndefined($)?Math.max(...n.map(yn).filter(gn))>0?Math.max(...n.map(hn).filter(pn)):0:$,minXValue:b.checkIfNullOrUndefined(Be)?Math.min(...n.map(dn).filter(mn))>0?0:Math.min(...n.map(fn).filter(xn)):Be,maxYValue:b.checkIfNullOrUndefined(ze)?Math.max(...n.map(un).filter(cn))>0?Math.max(...n.map(an).filter(rn)):0:ze,minYValue:b.checkIfNullOrUndefined(W)?Math.min(...n.map(ln).filter(sn))>0?0:Math.min(...n.map(on).filter(nn)):W,onSeriesMouseClick:s,rtl:h==="he"||h==="ar",annotations:u,customHighlightAreaSettings:Dt,regressionLine:Yt,resetSelectionOnDoubleClick:Ft,detailsOnClick:X,noOfXTicks:Vt,noOfYTicks:Qe,labelColor:oe,xSuffix:ye,ySuffix:ve,xPrefix:be,yPrefix:Ae,styles:p,classNames:c,animate:Ze===!0?{duration:.5,once:!0,amount:.5}:Ze||{duration:0,once:!0,amount:0},dimmedOpacity:jt,precision:_e,customLayers:Ot}):null,e[62]=Ze,e[63]=u,e[64]=fe,e[65]=c,e[66]=T,e[67]=w,e[68]=Dt,e[69]=Ot,e[70]=n,e[71]=X,e[72]=jt,e[73]=pe,e[74]=he,e[75]=O,e[76]=oe,e[77]=h,e[78]=Y,e[79]=Ne,e[80]=$,e[81]=ze,e[82]=Be,e[83]=W,e[84]=Vt,e[85]=Qe,e[86]=s,e[87]=k,e[88]=_e,e[89]=le,e[90]=me,e[91]=de,e[92]=Yt,e[93]=Ft,e[94]=ue,e[95]=je,e[96]=ge,e[97]=se,e[98]=p,e[99]=it,e[100]=tt,e[101]=U,e[102]=r.dateFormat,e[103]=r.enabled,e[104]=ht,e[105]=xe,e[106]=x,e[107]=re,e[108]=be,e[109]=ye,e[110]=ae,e[111]=Ae,e[112]=ve,e[113]=we):we=e[113];let I;e[114]!==ke||e[115]!==we?(I=o.jsxRuntimeExports.jsxs(fi.GraphArea,{ref:Oe,children:[ke,we]}),e[114]=ke,e[115]=we,e[116]=I):I=e[116];let Le;e[117]!==c?.footnote||e[118]!==c?.source||e[119]!==H||e[120]!==Fe||e[121]!==p?.footnote||e[122]!==p?.source||e[123]!==y?(Le=Fe||H?o.jsxRuntimeExports.jsx(Ri.GraphFooter,{styles:{footnote:p?.footnote,source:p?.source},classNames:{footnote:c?.footnote,source:c?.source},sources:Fe,footNote:H,width:y}):null,e[117]=c?.footnote,e[118]=c?.source,e[119]=H,e[120]=Fe,e[121]=p?.footnote,e[122]=p?.source,e[123]=y,e[124]=Le):Le=e[124];let _;return e[125]!==L||e[126]!==ce||e[127]!==Ee||e[128]!==P||e[129]!==h||e[130]!==S||e[131]!==ne||e[132]!==gt||e[133]!==mt||e[134]!==kt||e[135]!==Ce||e[136]!==Z||e[137]!==Re||e[138]!==I||e[139]!==Le||e[140]!==U||e[141]!==y?(_=o.jsxRuntimeExports.jsxs(fi.GraphContainer,{className:mt,style:kt,id:Ee,ref:Rt,"aria-label":L,backgroundColor:ce,theme:U,language:h,minHeight:S,width:y,height:P,relativeHeight:gt,padding:ne,children:[Ce,Z,Re,I,Le]}),e[125]=L,e[126]=ce,e[127]=Ee,e[128]=P,e[129]=h,e[130]=S,e[131]=ne,e[132]=gt,e[133]=mt,e[134]=kt,e[135]=Ce,e[136]=Z,e[137]=Re,e[138]=I,e[139]=Le,e[140]=U,e[141]=y,e[142]=_):_=e[142],_}function nn(i){return i!=null}function on(i){return i.y}function sn(i){return i!=null}function ln(i){return i.y}function rn(i){return i!=null}function an(i){return i.y}function cn(i){return i!=null}function un(i){return i.y}function xn(i){return i!=null}function fn(i){return i.x}function mn(i){return i!=null}function dn(i){return i.x}function pn(i){return i!=null}function hn(i){return i.x}function gn(i){return i!=null}function yn(i){return i.x}function vn(i){return i!=null}function bn(i){return i.radius}function An(i){return i.label}function jn(i){return i.color}function On(i){return i.color}function Cn(i){return i.color}function Rn(i){return i!==void 0}function kn(i){return i!==void 0}function wn(i){return i.data}function Ln(i){return i!==void 0}function Sn(i){return i.data}function En(i,e){return i-e}function Nn(i){return i.date}exports.ScatterPlot=tn;
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("./index-CHPV5EwG-6v2a2njQ.cjs"),ti=require("./parse-xYI9yrvL.cjs"),E=require("react"),ii=require("./getSliderMarks-CIuSoedo.cjs"),oi=require("./index-DQA8q5sC.cjs"),hi=require("./index-Cno4Q0YE.cjs"),ni=require("./simple-statistics-xm8c0LQQ.cjs"),gi=require("./Tooltip-BLa2EfMs.cjs"),b=require("./checkIfNullOrUndefined-BCW3Y1ML.cjs"),te=require("./Colors.cjs"),si=require("./numberFormattingFunction-02t-wJta.cjs"),ei=require("./customArea-B1LWQBmM.cjs"),li=require("./Axis-Jt_tmhxS.cjs"),ri=require("./AxisTitle-DV4n0RxE.cjs"),yi=require("./XTicksAndGridLines-CekrPykD.cjs"),ai=require("./ReferenceLine-M9aP3dj-.cjs"),vi=require("./RegressionLine-Ci-Dh0w0.cjs"),bi=require("./YTicksAndGridLines-UzVC5eBM.cjs"),Ai=require("./index-D69M6klB.cjs"),ji=require("./DetailsModal-DIRTulvr.cjs"),Oi=require("./pow-BnyPO-NX.cjs"),ci=require("./linear-CgUCbw9F.cjs"),Ci=require("./delaunay-rcy0HhZi.cjs"),Gt=require("./proxy-C4-uo6nS.cjs"),ki=require("./use-in-view-C3o_ntMv.cjs"),ui=require("./index-CoobIWNj.cjs"),Ri=require("./GraphFooter.cjs"),wi=require("./GraphHeader.cjs"),Li=require("./ColorLegendWithMouseOver.cjs"),Si=require("./EmptyState-B4c-CrXs.cjs"),xi=require("./index-sbKVyHS2.cjs"),Ei=require("./ensureCompleteData-D9bQTiVS.cjs"),fi=require("./uniqBy-O05lp2S5.cjs"),mi=require("./GraphContainer-B1EDxJ0S.cjs");function Ni(i){const e=n.compilerRuntimeExports.c(218),{data:o,width:ie,height:w,showLabels:Ge,colors:x,colorDomain:k,radius:X,xAxisTitle:y,yAxisTitle:G,leftMargin:Y,rightMargin:dt,topMargin:kt,bottomMargin:Tt,tooltip:pt,onSeriesMouseOver:oe,refXValues:Rt,refYValues:wt,highlightAreaSettings:Lt,selectedColor:Le,highlightedDataPoints:W,maxRadiusValue:ht,maxXValue:gt,minXValue:R,maxYValue:We,minYValue:j,onSeriesMouseClick:N,rtl:Be,annotations:ze,customHighlightAreaSettings:Je,regressionLine:Se,resetSelectionOnDoubleClick:Ee,detailsOnClick:$,noOfXTicks:Ke,noOfYTicks:Qe,labelColor:B,xSuffix:Ne,ySuffix:$e,xPrefix:Ve,yPrefix:Me,styles:s,classNames:l,animate:c,dimmedOpacity:V,precision:M,showHighlightedDataPointsLabels:St,customLayers:D,showVoronoiTesselation:Ze}=i,Pt=E.useRef(null);let yt;e[0]!==c.amount||e[1]!==c.once?(yt={once:c.once,amount:c.amount},e[0]=c.amount,e[1]=c.once,e[2]=yt):yt=e[2];const A=ki.useInView(Pt,yt),[q,ne]=E.useState(void 0),[z,_e]=E.useState(void 0),[et,d]=E.useState(void 0),[f,De]=E.useState(void 0),Et=y?Tt+50:Tt,Nt=G?Y+30:Y;let qe;e[3]!==dt||e[4]!==Et||e[5]!==Nt||e[6]!==kt?(qe={top:kt,bottom:Et,left:Nt,right:dt},e[3]=dt,e[4]=Et,e[5]=Nt,e[6]=kt,e[7]=qe):qe=e[7];const p=qe;let Ie,se,le,re,ae,ce,F,ue,xe,fe,J,me,K,de,Q,pe,U,Z;if(e[8]!==c||e[9]!==ze||e[10]!==l?.graphObjectValues||e[11]!==l?.regLine||e[12]!==l?.xAxis?.axis||e[13]!==l?.xAxis?.gridLines||e[14]!==l?.xAxis?.labels||e[15]!==l?.xAxis?.title||e[16]!==l?.yAxis?.gridLines||e[17]!==l?.yAxis?.labels||e[18]!==l?.yAxis?.title||e[19]!==k||e[20]!==x||e[21]!==Je||e[22]!==D||e[23]!==o||e[24]!==$||e[25]!==V||e[26]!==w||e[27]!==Lt||e[28]!==W||e[29]!==A||e[30]!==B||e[31]!==Y||e[32]!==p.bottom||e[33]!==p.left||e[34]!==p.right||e[35]!==p.top||e[36]!==ht||e[37]!==gt||e[38]!==We||e[39]!==R||e[40]!==j||e[41]!==z||e[42]!==q||e[43]!==Ke||e[44]!==Qe||e[45]!==N||e[46]!==oe||e[47]!==M||e[48]!==X||e[49]!==Rt||e[50]!==wt||e[51]!==Se||e[52]!==Ee||e[53]!==Be||e[54]!==Le||e[55]!==St||e[56]!==Ge||e[57]!==Ze||e[58]!==s?.graphObjectValues||e[59]!==s?.regLine||e[60]!==s?.xAxis?.axis||e[61]!==s?.xAxis?.gridLines||e[62]!==s?.xAxis?.labels||e[63]!==s?.xAxis?.title||e[64]!==s?.yAxis?.gridLines||e[65]!==s?.yAxis?.labels||e[66]!==s?.yAxis?.title||e[67]!==ie||e[68]!==y||e[69]!==Ve||e[70]!==Ne||e[71]!==G||e[72]!==Me||e[73]!==$e){const tt=o.map(to),h=ie-p.left-p.right,v=w-p.top-p.bottom,L=o.filter(eo).length!==o.length?Oi.sqrt().domain([0,ht]).range([.25,X]).nice():void 0,Pe=tt.filter(_i).length===0?tt:hi.orderBy(tt.filter(Zi),"radius","desc"),u=ci.linear().domain([R,gt]).range([0,h]).nice(),m=ci.linear().domain([j,We]).range([v,0]).nice(),$t=u.ticks(Ke),H=m.ticks(Qe),Xt=Ci.Delaunay.from(Pe.filter(Qi),t=>u(t.x),t=>m(t.y)).voronoi([0,0,h<0?0:h,v<0?0:v]),Yt=ni.linearRegression(o.filter(Ki).map(t=>[u(t.x),m(t.y)])),Vt=ni.linearRegressionLine(Yt);se=Gt.motion.svg,ue=`${ie}px`,xe=`${w}px`,fe=`0 0 ${ie} ${w}`,J="ltr",me=Pt,le=`translate(${p.left},${p.top})`;let it;e[92]!==c||e[93]!==Je||e[94]!==A||e[95]!==u||e[96]!==m?(it=n.jsxRuntimeExports.jsx(ei.CustomArea,{areaSettings:Je,scaleX:u,scaleY:m,animate:c,isInView:A},"custom-area"),e[92]=c,e[93]=Je,e[94]=A,e[95]=u,e[96]=m,e[97]=it):it=e[97],re=n.jsxRuntimeExports.jsxs(ui.AnimatePresence,{children:[n.jsxRuntimeExports.jsx(Ai.HighlightAreaForScatterPlot,{areaSettings:Lt,width:h,height:v,scaleX:u,scaleY:m,animate:c,isInView:A},"highlight-area"),it]});const ot=s?.yAxis?.gridLines,vt=s?.yAxis?.labels;let nt;e[98]!==ot||e[99]!==vt?(nt={gridLines:ot,labels:vt},e[98]=ot,e[99]=vt,e[100]=nt):nt=e[100];const st=l?.yAxis?.gridLines,bt=l?.yAxis?.labels;let Xe;e[101]!==st||e[102]!==bt?(Xe={gridLines:st,labels:bt},e[101]=st,e[102]=bt,e[103]=Xe):Xe=e[103];const r=m(j<0?0:j),At=m(j<0?0:j),lt=h+p.right,Ft=j<0?0:j;let _;e[104]!==M||e[105]!==Ft||e[106]!==Me||e[107]!==$e?(_=si.numberFormattingFunction(Ft,"NA",M,Me,$e),e[104]=M,e[105]=Ft,e[106]=Me,e[107]=$e,e[108]=_):_=e[108];const Ut=m(j<0?0:j);let O;e[109]!==Ut?(O={x:0,y:Ut,dy:"0.33em",dx:-4},e[109]=Ut,e[110]=O):O=e[110];const Ht=l?.xAxis?.axis,Ye=l?.yAxis?.labels;let a;e[111]!==Ht||e[112]!==Ye?(a={axis:Ht,label:Ye},e[111]=Ht,e[112]=Ye,e[113]=a):a=e[113];const I=s?.xAxis?.axis;let je;e[114]!==s?.yAxis?.labels?(je=s?.yAxis?.labels||{},e[114]=s?.yAxis?.labels,e[115]=je):je=e[115];let Oe;e[116]!==je?(Oe={textAnchor:"end",...je},e[116]=je,e[117]=Oe):Oe=e[117];let rt;e[118]!==I||e[119]!==Oe?(rt={axis:I,label:Oe},e[118]=I,e[119]=Oe,e[120]=rt):rt=e[120];let at;e[121]!==r||e[122]!==At||e[123]!==lt||e[124]!==_||e[125]!==O||e[126]!==a||e[127]!==rt?(at=n.jsxRuntimeExports.jsx(li.Axis,{y1:r,y2:At,x1:0,x2:lt,label:_,labelPos:O,classNames:a,styles:rt}),e[121]=r,e[122]=At,e[123]=lt,e[124]=_,e[125]=O,e[126]=a,e[127]=rt,e[128]=at):at=e[128];const Mt=0-Y-15,ct=v/2,ut=s?.yAxis?.title,xt=l?.yAxis?.title;let Fe;e[129]!==Mt||e[130]!==ct||e[131]!==ut||e[132]!==xt||e[133]!==G?(Fe=n.jsxRuntimeExports.jsx(ri.AxisTitle,{x:Mt,y:ct,style:ut,className:xt,text:G,rotate90:!0}),e[129]=Mt,e[130]=ct,e[131]=ut,e[132]=xt,e[133]=G,e[134]=Fe):Fe=e[134],ae=n.jsxRuntimeExports.jsxs("g",{children:[n.jsxRuntimeExports.jsx(bi.YTicksAndGridLines,{values:H.filter(Ji),y:H.filter(zi).map(t=>m(t)),x1:0,x2:h+p.right,styles:nt,classNames:Xe,suffix:$e,prefix:Me,labelType:"secondary",showGridLines:!0,labelPos:"side",precision:M}),at,Fe]});const jt=s?.xAxis?.gridLines,ft=s?.xAxis?.labels;let Ue;e[135]!==jt||e[136]!==ft?(Ue={gridLines:jt,labels:ft},e[135]=jt,e[136]=ft,e[137]=Ue):Ue=e[137];const Ot=l?.xAxis?.gridLines,Ct=l?.xAxis?.labels;let ee;e[138]!==Ot||e[139]!==Ct?(ee={gridLines:Ot,labels:Ct},e[138]=Ot,e[139]=Ct,e[140]=ee):ee=e[140];const Ce=u(R<0?0:R),ke=u(R<0?0:R),Re=R<0?0:R;let T;e[141]!==M||e[142]!==Re||e[143]!==Ve||e[144]!==Ne?(T=si.numberFormattingFunction(Re,"NA",M,Ve,Ne),e[141]=M,e[142]=Re,e[143]=Ve,e[144]=Ne,e[145]=T):T=e[145];const we=u(R<0?0:R);let P;e[146]!==v||e[147]!==we?(P={x:we,y:v,dy:"1em",dx:0},e[146]=v,e[147]=we,e[148]=P):P=e[148];const mt=l?.xAxis?.axis,g=l?.yAxis?.labels;let S;e[149]!==mt||e[150]!==g?(S={axis:mt,label:g},e[149]=mt,e[150]=g,e[151]=S):S=e[151];const zt=s?.xAxis?.axis;let Dt;e[152]!==s?.yAxis?.labels?(Dt=s?.yAxis?.labels||{},e[152]=s?.yAxis?.labels,e[153]=Dt):Dt=e[153];let qt;e[154]!==Dt?(qt={textAnchor:"middle",...Dt},e[154]=Dt,e[155]=qt):qt=e[155];let It;e[156]!==zt||e[157]!==qt?(It={axis:zt,label:qt},e[156]=zt,e[157]=qt,e[158]=It):It=e[158];let Wt;e[159]!==v||e[160]!==Ce||e[161]!==ke||e[162]!==T||e[163]!==P||e[164]!==S||e[165]!==It?(Wt=n.jsxRuntimeExports.jsx(li.Axis,{x1:Ce,x2:ke,y1:0,y2:v,label:T,labelPos:P,classNames:S,styles:It}),e[159]=v,e[160]=Ce,e[161]=ke,e[162]=T,e[163]=P,e[164]=S,e[165]=It,e[166]=Wt):Wt=e[166];const Jt=h/2,Kt=v+30,Qt=s?.xAxis?.title,Zt=l?.xAxis?.title;let Bt;e[167]!==Jt||e[168]!==Kt||e[169]!==Qt||e[170]!==Zt||e[171]!==y?(Bt=n.jsxRuntimeExports.jsx(ri.AxisTitle,{x:Jt,y:Kt,style:Qt,className:Zt,text:y}),e[167]=Jt,e[168]=Kt,e[169]=Qt,e[170]=Zt,e[171]=y,e[172]=Bt):Bt=e[172],ce=n.jsxRuntimeExports.jsxs("g",{children:[n.jsxRuntimeExports.jsx(yi.XTicksAndGridLines,{values:$t.filter(Bi),x:$t.filter(Wi).map(t=>u(t)),y1:0,y2:v,styles:Ue,classNames:ee,suffix:Ne,prefix:Ve,labelType:"primary",showGridLines:!0,precision:M}),Wt,Bt]}),e[173]!==D?(F=D.filter(Gi).map(Hi),e[173]=D,e[174]=F):F=e[174],Ie=ui.AnimatePresence,K=Pe.filter(Ui).map((t,He)=>n.jsxRuntimeExports.jsx("path",{d:Xt.renderCell(Pe.findIndex(C=>C.id===t.id)),opacity:Ze?1:0,className:"stroke-primary-gray-700 dark:stroke-primary-gray-300",style:{fill:"none",strokeWidth:1},onMouseEnter:C=>{ne(t),De(C.clientY),d(C.clientX),oe?.(t)},onMouseMove:C=>{ne(t),De(C.clientY),d(C.clientX)},onMouseLeave:()=>{ne(void 0),d(void 0),De(void 0),oe?.(void 0)},onClick:()=>{(N||$)&&(oi.isEqual(z,t)&&Ee?(_e(void 0),N?.(void 0)):(_e(t),N?.(t)))}},`tesselation_${t.label||He}`)),de=Pe.filter(Fi).map((t,He)=>n.jsxRuntimeExports.jsxs(Gt.motion.g,{variants:{initial:{x:u(t.x),y:m(t.y),opacity:Le?t.color&&x[k.indexOf(`${t.color}`)]===Le?1:V:q?q.id===t.id?1:V:W.length!==0?W.indexOf(t.label||"")!==-1?1:V:1},whileInView:{x:u(t.x),y:m(t.y),opacity:Le?t.color&&x[k.indexOf(`${t.color}`)]===Le?1:V:q?q.id===t.id?1:V:W.length!==0?W.indexOf(t.label||"")!==-1?1:V:1,transition:{duration:c.duration}}},initial:"initial",animate:A?"whileInView":"initial",exit:{opacity:0,transition:{duration:c.duration}},onMouseEnter:C=>{ne(t),De(C.clientY),d(C.clientX),oe?.(t)},onMouseMove:C=>{ne(t),De(C.clientY),d(C.clientX)},onMouseLeave:()=>{ne(void 0),d(void 0),De(void 0),oe?.(void 0)},onClick:()=>{(N||$)&&(oi.isEqual(z,t)&&Ee?(_e(void 0),N?.(void 0)):(_e(t),N?.(t)))},children:[n.jsxRuntimeExports.jsx(Gt.motion.circle,{cx:0,cy:0,exit:{r:0,transition:{duration:c.duration}},variants:{initial:{r:0,fill:o.filter(Yi).length===0?x[0]:t.color?x[k.indexOf(`${t.color}`)]:te.Colors.gray,stroke:o.filter(Xi).length===0?x[0]:t.color?x[k.indexOf(`${t.color}`)]:te.Colors.gray},whileInView:{r:L?L(t.radius||0):X,fill:o.filter(Pi).length===0?x[0]:t.color?x[k.indexOf(`${t.color}`)]:te.Colors.gray,stroke:o.filter(Ti).length===0?x[0]:t.color?x[k.indexOf(`${t.color}`)]:te.Colors.gray,transition:{duration:c.duration}}},initial:"initial",animate:A?"whileInView":"initial",style:{fillOpacity:.6}}),Ge&&!b.checkIfNullOrUndefined(t.label)?n.jsxRuntimeExports.jsx(Gt.motion.text,{style:{...s?.graphObjectValues||{}},className:n.mo("graph-value text-sm",l?.graphObjectValues),y:0,exit:{opacity:0,transition:{duration:c.duration}},variants:{initial:{x:L?L(t.radius||0):X,opacity:0,fill:B||(o.filter(Ii).length===0?x[0]:t.color?x[k.indexOf(`${t.color}`)]:te.Colors.gray)},whileInView:{x:L?L(t.radius||0):X,opacity:1,fill:B||(o.filter(qi).length===0?x[0]:t.color?x[k.indexOf(`${t.color}`)]:te.Colors.gray),transition:{duration:c.duration}}},initial:"initial",animate:A?"whileInView":"initial",dy:"0.33em",dx:3,children:t.label}):W.length!==0&&!b.checkIfNullOrUndefined(t.label)&&St&&W.indexOf(t.label)!==-1?n.jsxRuntimeExports.jsx(Gt.motion.text,{style:{...s?.graphObjectValues||{}},className:n.mo("graph-value text-sm",l?.graphObjectValues),y:0,exit:{opacity:0,transition:{duration:c.duration}},variants:{initial:{x:L?L(t.radius||0):X,opacity:0,fill:B||(o.filter(Di).length===0?x[0]:t.color?x[k.indexOf(`${t.color}`)]:te.Colors.gray)},whileInView:{x:L?L(t.radius||0):X,opacity:1,fill:B||(o.filter(Mi).length===0?x[0]:t.color?x[k.indexOf(`${t.color}`)]:te.Colors.gray),transition:{duration:c.duration}}},initial:"initial",animate:A?"whileInView":"initial",dy:"0.33em",dx:3,children:t.label}):null]},`${t.label||He}`)),Q=Rt.map((t,He)=>n.jsxRuntimeExports.jsx(ai.RefLineX,{text:t.text,color:t.color,x:u(t.value),y1:0,y2:v,textSide:u(t.value)>h*.75||Be?"left":"right",classNames:t.classNames,styles:t.styles,animate:c,isInView:A},He)),pe=wt.map((t,He)=>n.jsxRuntimeExports.jsx(ai.RefLineY,{text:t.text,color:t.color,y:m(t.value),x1:0,x2:h,classNames:t.classNames,styles:t.styles,animate:c,isInView:A},He));const _t=ze.map((t,He)=>{const C=ei.getLineEndPoint({x:t.xCoordinate?u(t.xCoordinate)+(t.xOffset||0):0+(t.xOffset||0),y:t.yCoordinate?m(t.yCoordinate)+(t.yOffset||0)-8:0+(t.yOffset||0)-8},{x:t.xCoordinate?u(t.xCoordinate):0,y:t.yCoordinate?m(t.yCoordinate):0},b.checkIfNullOrUndefined(t.connectorRadius)?3.5:t.connectorRadius),di=t.showConnector?{y1:C.y,x1:C.x,y2:t.yCoordinate?m(t.yCoordinate)+(t.yOffset||0):0+(t.yOffset||0),x2:t.xCoordinate?u(t.xCoordinate)+(t.xOffset||0):0+(t.xOffset||0),cy:t.yCoordinate?m(t.yCoordinate):0,cx:t.xCoordinate?u(t.xCoordinate):0,circleRadius:b.checkIfNullOrUndefined(t.connectorRadius)?3.5:t.connectorRadius,strokeWidth:t.showConnector===!0?2:Math.min(t.showConnector||0,1)}:void 0,pi={y:t.yCoordinate?m(t.yCoordinate)+(t.yOffset||0)-8:0+(t.yOffset||0)-8,x:Be?0:t.xCoordinate?u(t.xCoordinate)+(t.xOffset||0):0+(t.xOffset||0),width:Be?t.xCoordinate?u(t.xCoordinate)+(t.xOffset||0):0+(t.xOffset||0):h+p.right-(t.xCoordinate?u(t.xCoordinate)+(t.xOffset||0):0+(t.xOffset||0)),maxWidth:t.maxWidth,fontWeight:t.fontWeight,align:t.align};return n.jsxRuntimeExports.jsx(ei.Annotation,{color:t.color,connectorsSettings:di,labelSettings:pi,text:t.text,classNames:t.classNames,styles:t.styles,animate:c,isInView:A},He)});e[175]!==_t?(U=n.jsxRuntimeExports.jsx("g",{children:_t}),e[175]=_t,e[176]=U):U=e[176],Z=Se?n.jsxRuntimeExports.jsx(vi.RegressionLine,{x1:0,x2:h,y1:Vt(0),y2:Vt(h),graphHeight:v,graphWidth:h,className:l?.regLine,style:s?.regLine,color:typeof Se=="string"?Se:void 0,animate:c,isInView:A}):null,e[8]=c,e[9]=ze,e[10]=l?.graphObjectValues,e[11]=l?.regLine,e[12]=l?.xAxis?.axis,e[13]=l?.xAxis?.gridLines,e[14]=l?.xAxis?.labels,e[15]=l?.xAxis?.title,e[16]=l?.yAxis?.gridLines,e[17]=l?.yAxis?.labels,e[18]=l?.yAxis?.title,e[19]=k,e[20]=x,e[21]=Je,e[22]=D,e[23]=o,e[24]=$,e[25]=V,e[26]=w,e[27]=Lt,e[28]=W,e[29]=A,e[30]=B,e[31]=Y,e[32]=p.bottom,e[33]=p.left,e[34]=p.right,e[35]=p.top,e[36]=ht,e[37]=gt,e[38]=We,e[39]=R,e[40]=j,e[41]=z,e[42]=q,e[43]=Ke,e[44]=Qe,e[45]=N,e[46]=oe,e[47]=M,e[48]=X,e[49]=Rt,e[50]=wt,e[51]=Se,e[52]=Ee,e[53]=Be,e[54]=Le,e[55]=St,e[56]=Ge,e[57]=Ze,e[58]=s?.graphObjectValues,e[59]=s?.regLine,e[60]=s?.xAxis?.axis,e[61]=s?.xAxis?.gridLines,e[62]=s?.xAxis?.labels,e[63]=s?.xAxis?.title,e[64]=s?.yAxis?.gridLines,e[65]=s?.yAxis?.labels,e[66]=s?.yAxis?.title,e[67]=ie,e[68]=y,e[69]=Ve,e[70]=Ne,e[71]=G,e[72]=Me,e[73]=$e,e[74]=Ie,e[75]=se,e[76]=le,e[77]=re,e[78]=ae,e[79]=ce,e[80]=F,e[81]=ue,e[82]=xe,e[83]=fe,e[84]=J,e[85]=me,e[86]=K,e[87]=de,e[88]=Q,e[89]=pe,e[90]=U,e[91]=Z}else Ie=e[74],se=e[75],le=e[76],re=e[77],ae=e[78],ce=e[79],F=e[80],ue=e[81],xe=e[82],fe=e[83],J=e[84],me=e[85],K=e[86],de=e[87],Q=e[88],pe=e[89],U=e[90],Z=e[91];let he;e[177]!==Ie||e[178]!==K||e[179]!==de||e[180]!==Q||e[181]!==pe||e[182]!==U||e[183]!==Z?(he=n.jsxRuntimeExports.jsxs(Ie,{children:[K,de,Q,pe,U,Z]}),e[177]=Ie,e[178]=K,e[179]=de,e[180]=Q,e[181]=pe,e[182]=U,e[183]=Z,e[184]=he):he=e[184];let ge;e[185]!==D?(ge=D.filter(Vi).map($i),e[185]=D,e[186]=ge):ge=e[186];let ye;e[187]!==le||e[188]!==re||e[189]!==ae||e[190]!==ce||e[191]!==F||e[192]!==he||e[193]!==ge?(ye=n.jsxRuntimeExports.jsxs("g",{transform:le,children:[re,ae,ce,F,he,ge]}),e[187]=le,e[188]=re,e[189]=ae,e[190]=ce,e[191]=F,e[192]=he,e[193]=ge,e[194]=ye):ye=e[194];let ve;e[195]!==se||e[196]!==ue||e[197]!==xe||e[198]!==fe||e[199]!==J||e[200]!==me||e[201]!==ye?(ve=n.jsxRuntimeExports.jsx(se,{width:ue,height:xe,viewBox:fe,direction:J,ref:me,children:ye}),e[195]=se,e[196]=ue,e[197]=xe,e[198]=fe,e[199]=J,e[200]=me,e[201]=ye,e[202]=ve):ve=e[202];let be;e[203]!==l?.tooltip||e[204]!==et||e[205]!==f||e[206]!==q||e[207]!==s?.tooltip||e[208]!==pt?(be=q&&pt&&et&&f?n.jsxRuntimeExports.jsx(gi.Tooltip,{data:q,body:pt,xPos:et,yPos:f,backgroundStyle:s?.tooltip,className:l?.tooltip}):null,e[203]=l?.tooltip,e[204]=et,e[205]=f,e[206]=q,e[207]=s?.tooltip,e[208]=pt,e[209]=be):be=e[209];let Ae;e[210]!==l?.modal||e[211]!==$||e[212]!==z?(Ae=$&&z!==void 0?n.jsxRuntimeExports.jsx(ji.DetailsModal,{body:$,data:z,setData:_e,className:l?.modal}):null,e[210]=l?.modal,e[211]=$,e[212]=z,e[213]=Ae):Ae=e[213];let Te;return e[214]!==ve||e[215]!==be||e[216]!==Ae?(Te=n.jsxRuntimeExports.jsxs(n.jsxRuntimeExports.Fragment,{children:[ve,be,Ae]}),e[214]=ve,e[215]=be,e[216]=Ae,e[217]=Te):Te=e[217],Te}function $i(i){return i.layer}function Vi(i){return i.position==="after"}function Mi(i){return i.color}function Di(i){return i.color}function qi(i){return i.color}function Ii(i){return i.color}function Ti(i){return i.color}function Pi(i){return i.color}function Xi(i){return i.color}function Yi(i){return i.color}function Fi(i){return!b.checkIfNullOrUndefined(i.x)&&!b.checkIfNullOrUndefined(i.y)}function Ui(i){return!b.checkIfNullOrUndefined(i.x)&&!b.checkIfNullOrUndefined(i.y)}function Hi(i){return i.layer}function Gi(i){return i.position==="before"}function Wi(i){return i!==0}function Bi(i){return i!==0}function zi(i){return i!==0}function Ji(i){return i!==0}function Ki(i){return!b.checkIfNullOrUndefined(i.x)&&!b.checkIfNullOrUndefined(i.y)}function Qi(i){return!b.checkIfNullOrUndefined(i.x)&&!b.checkIfNullOrUndefined(i.y)}function Zi(i){return!b.checkIfNullOrUndefined(i.radius)}function _i(i){return!b.checkIfNullOrUndefined(i.radius)}function eo(i){return i.radius===void 0||i.radius===null}function to(i,e){return{...i,id:`${e}`}}function io(i){const e=n.compilerRuntimeExports.c(144),{data:o,graphTitle:ie,colors:w,sources:Ge,graphDescription:x,showLabels:k,height:X,width:y,footNote:G,colorDomain:Y,colorLegendTitle:dt,radius:kt,xAxisTitle:Tt,yAxisTitle:pt,padding:oe,backgroundColor:Rt,leftMargin:wt,rightMargin:Lt,topMargin:Le,bottomMargin:W,tooltip:ht,relativeHeight:gt,onSeriesMouseOver:R,refXValues:We,refYValues:j,highlightAreaSettings:N,showColorScale:Be,highlightedDataPoints:ze,showHighlightedDataPointsLabels:Je,graphID:Se,maxRadiusValue:Ee,maxXValue:$,minXValue:Ke,maxYValue:Qe,minYValue:B,xSuffix:Ne,ySuffix:$e,xPrefix:Ve,yPrefix:Me,onSeriesMouseClick:s,graphDownload:l,dataDownload:c,language:V,showNAColor:M,minHeight:St,annotations:D,customHighlightAreaSettings:Ze,theme:Pt,regressionLine:yt,ariaLabel:A,resetSelectionOnDoubleClick:q,detailsOnClick:ne,noOfXTicks:z,noOfYTicks:_e,labelColor:et,styles:d,classNames:f,animate:De,dimmedOpacity:Et,precision:Nt,customLayers:qe,timeline:p,showVoronoiTesselation:Ie}=i,se=k===void 0?!1:k,le=kt===void 0?5:kt,re=Tt===void 0?"X Axis":Tt,ae=pt===void 0?"Y Axis":pt,ce=Rt===void 0?!1:Rt,F=wt===void 0?0:wt,ue=Lt===void 0?10:Lt,xe=Le===void 0?20:Le,fe=W===void 0?50:W;let J;e[0]!==We?(J=We===void 0?[]:We,e[0]=We,e[1]=J):J=e[1];const me=J;let K;e[2]!==j?(K=j===void 0?[]:j,e[2]=j,e[3]=K):K=e[3];const de=K;let Q;e[4]!==N?(Q=N===void 0?[]:N,e[4]=N,e[5]=Q):Q=e[5];const pe=Q,U=Be===void 0?!0:Be;let Z;e[6]!==ze?(Z=ze===void 0?[]:ze,e[6]=ze,e[7]=Z):Z=e[7];const he=Z,ge=Je===void 0?!1:Je,ye=Ne===void 0?"":Ne,ve=$e===void 0?"":$e,be=Ve===void 0?"":Ve,Ae=Me===void 0?"":Me,Te=l===void 0?!1:l,tt=c===void 0?!1:c,h=V===void 0?"en":V,v=M===void 0?!0:M,L=St===void 0?0:St;let Pe;e[8]!==D?(Pe=D===void 0?[]:D,e[8]=D,e[9]=Pe):Pe=e[9];const u=Pe;let m;e[10]!==Ze?(m=Ze===void 0?[]:Ze,e[10]=Ze,e[11]=m):m=e[11];const $t=m,H=Pt===void 0?"light":Pt,Xt=yt===void 0?!1:yt,Yt=q===void 0?!0:q,Vt=z===void 0?5:z,it=_e===void 0?5:_e,ot=De===void 0?!1:De,vt=Et===void 0?.3:Et,nt=Nt===void 0?2:Nt;let st;e[12]!==qe?(st=qe===void 0?[]:qe,e[12]=qe,e[13]=st):st=e[13];const bt=st;let Xe;e[14]!==p?(Xe=p===void 0?{enabled:!1,autoplay:!1,showOnlyActiveDate:!0}:p,e[14]=p,e[15]=Xe):Xe=e[15];const r=Xe,At=Ie===void 0?!1:Ie,[lt,Ft]=E.useState(0),[_,Ut]=E.useState(0),[O,Ht]=E.useState(r.autoplay);let Ye;if(e[16]!==o||e[17]!==r.dateFormat){let g;e[19]!==r.dateFormat?(g=S=>ti.parse(`${S.date}`,r.dateFormat||"yyyy",new Date).getTime(),e[19]=r.dateFormat,e[20]=g):g=e[20],Ye=[...new Set(o.filter($o).map(g))],Ye.sort(No),e[16]=o,e[17]=r.dateFormat,e[18]=Ye}else Ye=e[18];const a=Ye,[I,je]=E.useState(r.autoplay?0:a.length-1),[Oe,rt]=E.useState(void 0),at=E.useRef(null),Mt=E.useRef(null);let ct,ut;e[21]===Symbol.for("react.memo_cache_sentinel")?(ct=()=>{const g=new ResizeObserver(S=>{Ft(S[0].target.clientWidth||620),Ut(S[0].target.clientHeight||480)});return at.current&&g.observe(at.current),()=>g.disconnect()},ut=[],e[21]=ct,e[22]=ut):(ct=e[21],ut=e[22]),E.useEffect(ct,ut);let xt,Fe;e[23]!==O||e[24]!==r.speed||e[25]!==a?(xt=()=>{const g=setInterval(()=>{je(S=>S<a.length-1?S+1:0)},(r.speed||2)*1e3);return O||clearInterval(g),()=>clearInterval(g)},Fe=[a,O,r.speed],e[23]=O,e[24]=r.speed,e[25]=a,e[26]=xt,e[27]=Fe):(xt=e[26],Fe=e[27]),E.useEffect(xt,Fe);const jt=r.dateFormat||"yyyy";let ft;e[28]!==I||e[29]!==jt||e[30]!==r.showOnlyActiveDate||e[31]!==a?(ft=ii.getSliderMarks(a,I,r.showOnlyActiveDate,jt),e[28]=I,e[29]=jt,e[30]=r.showOnlyActiveDate,e[31]=a,e[32]=ft):ft=e[32];const Ue=ft,Ot=f?.graphContainer,Ct=d?.graphContainer;let ee;e[33]!==f?.description||e[34]!==f?.title||e[35]!==o||e[36]!==tt||e[37]!==x||e[38]!==Te||e[39]!==ie||e[40]!==d?.description||e[41]!==d?.title||e[42]!==y?(ee=ie||x||Te||tt?n.jsxRuntimeExports.jsx(wi.GraphHeader,{styles:{title:d?.title,description:d?.description},classNames:{title:f?.title,description:f?.description},graphTitle:ie,graphDescription:x,width:y,graphDownload:Te?Mt:void 0,dataDownload:tt?o.map(Eo).filter(So).length>0?o.map(Lo).filter(wo):o.filter(Ro):null}):null,e[33]=f?.description,e[34]=f?.title,e[35]=o,e[36]=tt,e[37]=x,e[38]=Te,e[39]=ie,e[40]=d?.description,e[41]=d?.title,e[42]=y,e[43]=ee):ee=e[43];let Ce;e[44]!==I||e[45]!==Ue||e[46]!==O||e[47]!==r.enabled||e[48]!==a?(Ce=r.enabled&&a.length>0&&Ue?n.jsxRuntimeExports.jsxs("div",{className:"flex gap-6 items-center",dir:"ltr",children:[n.jsxRuntimeExports.jsx("button",{type:"button",onClick:()=>{Ht(!O)},className:"p-0 border-0 cursor-pointer bg-transparent","aria-label":O?"Click to pause animation":"Click to play animation",children:O?n.jsxRuntimeExports.jsx(xi.Pause,{}):n.jsxRuntimeExports.jsx(xi.Play,{})}),n.jsxRuntimeExports.jsx(ii.Nr,{min:a[0],max:a[a.length-1],marks:Ue,step:null,defaultValue:a[a.length-1],value:a[I],onChangeComplete:g=>{je(a.indexOf(g))},onChange:g=>{je(a.indexOf(g))},"aria-label":"Time slider. Use arrow keys to adjust selected time period."})]}):null,e[44]=I,e[45]=Ue,e[46]=O,e[47]=r.enabled,e[48]=a,e[49]=Ce):Ce=e[49];let ke;e[50]!==f?.colorLegend||e[51]!==Y||e[52]!==dt||e[53]!==w||e[54]!==o||e[55]!==U||e[56]!==v||e[57]!==H||e[58]!==y?(ke=U&&o.filter(ko).length!==0&&o.length>0?n.jsxRuntimeExports.jsx(Li.ColorLegendWithMouseOver,{width:y,colorLegendTitle:dt,colors:w||te.Colors[H].categoricalColors.colors,colorDomain:Y||fi.uniqBy(o,"color",!0),setSelectedColor:rt,showNAColor:v,className:f?.colorLegend}):null,e[50]=f?.colorLegend,e[51]=Y,e[52]=dt,e[53]=w,e[54]=o,e[55]=U,e[56]=v,e[57]=H,e[58]=y,e[59]=ke):ke=e[59];let Re;e[60]!==o.length?(Re=o.length===0&&n.jsxRuntimeExports.jsx(Si.EmptyState,{}),e[60]=o.length,e[61]=Re):Re=e[61];let T;e[62]!==ot||e[63]!==u||e[64]!==fe||e[65]!==f||e[66]!==Y||e[67]!==w||e[68]!==$t||e[69]!==bt||e[70]!==o||e[71]!==ne||e[72]!==vt||e[73]!==pe||e[74]!==he||e[75]!==I||e[76]!==et||e[77]!==h||e[78]!==F||e[79]!==Ee||e[80]!==$||e[81]!==Qe||e[82]!==Ke||e[83]!==B||e[84]!==Vt||e[85]!==it||e[86]!==s||e[87]!==R||e[88]!==nt||e[89]!==le||e[90]!==me||e[91]!==de||e[92]!==Xt||e[93]!==Yt||e[94]!==ue||e[95]!==Oe||e[96]!==ge||e[97]!==se||e[98]!==At||e[99]!==d||e[100]!==_||e[101]!==lt||e[102]!==H||e[103]!==r.dateFormat||e[104]!==r.enabled||e[105]!==ht||e[106]!==xe||e[107]!==a||e[108]!==re||e[109]!==be||e[110]!==ye||e[111]!==ae||e[112]!==Ae||e[113]!==ve?(T=lt&&_&&o.length>0?n.jsxRuntimeExports.jsx(Ni,{data:Ei.ensureCompleteDataForScatterPlot(o,r.dateFormat||"yyyy").filter(g=>r.enabled?`${g.date}`===ti.format(new Date(a[I]),r.dateFormat||"yyyy"):g),width:lt,height:_,colorDomain:o.filter(Co).length===0?[]:Y||fi.uniqBy(o,"color",!0),colors:o.filter(Oo).length===0?w?[w]:[te.Colors.primaryColors["blue-600"]]:w||te.Colors[H].categoricalColors.colors,xAxisTitle:re,yAxisTitle:ae,refXValues:me,refYValues:de,showLabels:se,radius:le,leftMargin:F,rightMargin:ue,topMargin:xe,bottomMargin:fe,tooltip:ht,onSeriesMouseOver:R,highlightAreaSettings:pe,showVoronoiTesselation:At,highlightedDataPoints:o.filter(jo).length===0?[]:he,showHighlightedDataPointsLabels:ge,selectedColor:Oe,maxRadiusValue:b.checkIfNullOrUndefined(Ee)?Math.max(...o.map(Ao).filter(bo)):Ee,maxXValue:b.checkIfNullOrUndefined($)?Math.max(...o.map(vo).filter(yo))>0?Math.max(...o.map(go).filter(ho)):0:$,minXValue:b.checkIfNullOrUndefined(Ke)?Math.min(...o.map(po).filter(mo))>0?0:Math.min(...o.map(fo).filter(xo)):Ke,maxYValue:b.checkIfNullOrUndefined(Qe)?Math.max(...o.map(uo).filter(co))>0?Math.max(...o.map(ao).filter(ro)):0:Qe,minYValue:b.checkIfNullOrUndefined(B)?Math.min(...o.map(lo).filter(so))>0?0:Math.min(...o.map(no).filter(oo)):B,onSeriesMouseClick:s,rtl:h==="he"||h==="ar",annotations:u,customHighlightAreaSettings:$t,regressionLine:Xt,resetSelectionOnDoubleClick:Yt,detailsOnClick:ne,noOfXTicks:Vt,noOfYTicks:it,labelColor:et,xSuffix:ye,ySuffix:ve,xPrefix:be,yPrefix:Ae,styles:d,classNames:f,animate:ot===!0?{duration:.5,once:!0,amount:.5}:ot||{duration:0,once:!0,amount:0},dimmedOpacity:vt,precision:nt,customLayers:bt}):null,e[62]=ot,e[63]=u,e[64]=fe,e[65]=f,e[66]=Y,e[67]=w,e[68]=$t,e[69]=bt,e[70]=o,e[71]=ne,e[72]=vt,e[73]=pe,e[74]=he,e[75]=I,e[76]=et,e[77]=h,e[78]=F,e[79]=Ee,e[80]=$,e[81]=Qe,e[82]=Ke,e[83]=B,e[84]=Vt,e[85]=it,e[86]=s,e[87]=R,e[88]=nt,e[89]=le,e[90]=me,e[91]=de,e[92]=Xt,e[93]=Yt,e[94]=ue,e[95]=Oe,e[96]=ge,e[97]=se,e[98]=At,e[99]=d,e[100]=_,e[101]=lt,e[102]=H,e[103]=r.dateFormat,e[104]=r.enabled,e[105]=ht,e[106]=xe,e[107]=a,e[108]=re,e[109]=be,e[110]=ye,e[111]=ae,e[112]=Ae,e[113]=ve,e[114]=T):T=e[114];let we;e[115]!==Re||e[116]!==T?(we=n.jsxRuntimeExports.jsxs(mi.GraphArea,{ref:at,children:[Re,T]}),e[115]=Re,e[116]=T,e[117]=we):we=e[117];let P;e[118]!==f?.footnote||e[119]!==f?.source||e[120]!==G||e[121]!==Ge||e[122]!==d?.footnote||e[123]!==d?.source||e[124]!==y?(P=Ge||G?n.jsxRuntimeExports.jsx(Ri.GraphFooter,{styles:{footnote:d?.footnote,source:d?.source},classNames:{footnote:f?.footnote,source:f?.source},sources:Ge,footNote:G,width:y}):null,e[118]=f?.footnote,e[119]=f?.source,e[120]=G,e[121]=Ge,e[122]=d?.footnote,e[123]=d?.source,e[124]=y,e[125]=P):P=e[125];let mt;return e[126]!==A||e[127]!==ce||e[128]!==Se||e[129]!==X||e[130]!==h||e[131]!==L||e[132]!==oe||e[133]!==gt||e[134]!==Ot||e[135]!==Ct||e[136]!==ee||e[137]!==Ce||e[138]!==ke||e[139]!==we||e[140]!==P||e[141]!==H||e[142]!==y?(mt=n.jsxRuntimeExports.jsxs(mi.GraphContainer,{className:Ot,style:Ct,id:Se,ref:Mt,"aria-label":A,backgroundColor:ce,theme:H,language:h,minHeight:L,width:y,height:X,relativeHeight:gt,padding:oe,children:[ee,Ce,ke,we,P]}),e[126]=A,e[127]=ce,e[128]=Se,e[129]=X,e[130]=h,e[131]=L,e[132]=oe,e[133]=gt,e[134]=Ot,e[135]=Ct,e[136]=ee,e[137]=Ce,e[138]=ke,e[139]=we,e[140]=P,e[141]=H,e[142]=y,e[143]=mt):mt=e[143],mt}function oo(i){return i!=null}function no(i){return i.y}function so(i){return i!=null}function lo(i){return i.y}function ro(i){return i!=null}function ao(i){return i.y}function co(i){return i!=null}function uo(i){return i.y}function xo(i){return i!=null}function fo(i){return i.x}function mo(i){return i!=null}function po(i){return i.x}function ho(i){return i!=null}function go(i){return i.x}function yo(i){return i!=null}function vo(i){return i.x}function bo(i){return i!=null}function Ao(i){return i.radius}function jo(i){return i.label}function Oo(i){return i.color}function Co(i){return i.color}function ko(i){return i.color}function Ro(i){return i!==void 0}function wo(i){return i!==void 0}function Lo(i){return i.data}function So(i){return i!==void 0}function Eo(i){return i.data}function No(i,e){return i-e}function $o(i){return i.date}exports.ScatterPlot=io;
|
|
2
2
|
//# sourceMappingURL=ScatterPlot.cjs.map
|