@undp/data-viz 2.3.15 → 2.3.16

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