@undp/data-viz 2.1.9 → 2.2.1
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/AreaChart.cjs +1 -1
- package/dist/AreaChart.js +19 -19
- package/dist/AreaChart.js.map +1 -1
- package/dist/{Axis-CRyfcLjc.js → Axis-DoOqnt6g.js} +2 -2
- package/dist/{Axis-CRyfcLjc.js.map → Axis-DoOqnt6g.js.map} +1 -1
- package/dist/{Axis-DxRV2yMi.cjs → Axis-Dtjn-EgM.cjs} +2 -2
- package/dist/{Axis-DxRV2yMi.cjs.map → Axis-Dtjn-EgM.cjs.map} +1 -1
- package/dist/{AxisTitle-sS5bLLR7.cjs → AxisTitle-DV4n0RxE.cjs} +2 -2
- package/dist/{AxisTitle-sS5bLLR7.cjs.map → AxisTitle-DV4n0RxE.cjs.map} +1 -1
- package/dist/{AxisTitle-jeI7am8o.js → AxisTitle-VFq89Olw.js} +2 -2
- package/dist/{AxisTitle-jeI7am8o.js.map → AxisTitle-VFq89Olw.js.map} +1 -1
- package/dist/BarGraph.cjs +1 -1
- package/dist/BarGraph.js +24 -24
- package/dist/BarGraph.js.map +1 -1
- package/dist/BasicStatCard.cjs +1 -1
- package/dist/BasicStatCard.js +2 -2
- package/dist/BeeSwarmChart.cjs +1 -1
- package/dist/BeeSwarmChart.js +14 -14
- package/dist/BeeSwarmChart.js.map +1 -1
- package/dist/BiVariateChoroplethMap.cjs +1 -1
- package/dist/BiVariateChoroplethMap.cjs.map +1 -1
- package/dist/BiVariateChoroplethMap.js +48 -48
- package/dist/BiVariateChoroplethMap.js.map +1 -1
- package/dist/BulletChart.cjs +1 -1
- package/dist/BulletChart.js +22 -22
- package/dist/BulletChart.js.map +1 -1
- package/dist/ButterflyChart.cjs +1 -1
- package/dist/ButterflyChart.js +19 -19
- package/dist/ButterflyChart.js.map +1 -1
- package/dist/ChoroplethMap.cjs +1 -1
- package/dist/ChoroplethMap.cjs.map +1 -1
- package/dist/ChoroplethMap.js +51 -51
- package/dist/ChoroplethMap.js.map +1 -1
- package/dist/CirclePackingGraph.cjs +1 -1
- package/dist/CirclePackingGraph.js +4 -4
- package/dist/ColorLegend.cjs +1 -1
- package/dist/ColorLegend.js +2 -2
- package/dist/ColorLegendWithMouseOver.cjs +1 -1
- package/dist/ColorLegendWithMouseOver.js +2 -2
- package/dist/CopyTextButton.cjs +1 -16
- package/dist/CopyTextButton.cjs.map +1 -1
- package/dist/CopyTextButton.js +13 -31
- package/dist/CopyTextButton.js.map +1 -1
- package/dist/CsvDownloadButton.cjs +2 -20
- package/dist/CsvDownloadButton.cjs.map +1 -1
- package/dist/CsvDownloadButton.js +5 -26
- package/dist/CsvDownloadButton.js.map +1 -1
- package/dist/DataCards.cjs +1 -21
- package/dist/DataCards.cjs.map +1 -1
- package/dist/DataCards.js +18 -42
- package/dist/DataCards.js.map +1 -1
- package/dist/DataTable.cjs +1 -1
- package/dist/DataTable.js +6 -6
- package/dist/DataTable.js.map +1 -1
- package/dist/{DetailsModal-0Ry5nXiC.js → DetailsModal-BMCTgVsk.js} +4 -4
- package/dist/{DetailsModal-0Ry5nXiC.js.map → DetailsModal-BMCTgVsk.js.map} +1 -1
- package/dist/{DetailsModal-BN0HDFlV.cjs → DetailsModal-DHttOA80.cjs} +2 -2
- package/dist/{DetailsModal-BN0HDFlV.cjs.map → DetailsModal-DHttOA80.cjs.map} +1 -1
- package/dist/DifferenceLineChart.cjs +1 -1
- package/dist/DifferenceLineChart.js +22 -22
- package/dist/DifferenceLineChart.js.map +1 -1
- package/dist/DonutChart.cjs +1 -1
- package/dist/DonutChart.js +10 -10
- package/dist/DotDensityMap.cjs +1 -1
- package/dist/DotDensityMap.cjs.map +1 -1
- package/dist/DotDensityMap.js +78 -78
- package/dist/DotDensityMap.js.map +1 -1
- package/dist/{DropdownSelect-BbdPQa2k.js → DropdownSelect-D8rFbygC.js} +5 -33
- package/dist/{DropdownSelect-BbdPQa2k.js.map → DropdownSelect-D8rFbygC.js.map} +1 -1
- package/dist/{DropdownSelect-Doz3mCrM.cjs → DropdownSelect-NNpOs7DX.cjs} +2 -26
- package/dist/{DropdownSelect-Doz3mCrM.cjs.map → DropdownSelect-NNpOs7DX.cjs.map} +1 -1
- package/dist/DualAxisLineChart.cjs +1 -1
- package/dist/DualAxisLineChart.js +15 -15
- package/dist/DualAxisLineChart.js.map +1 -1
- package/dist/DumbbellChart.cjs +1 -1
- package/dist/DumbbellChart.js +22 -22
- package/dist/DumbbellChart.js.map +1 -1
- package/dist/{EmptyState-gLDRXBHm.cjs → EmptyState-CGeBqbmR.cjs} +2 -2
- package/dist/{EmptyState-gLDRXBHm.cjs.map → EmptyState-CGeBqbmR.cjs.map} +1 -1
- package/dist/EmptyState-tZBErBKF.js +15 -0
- package/dist/{EmptyState-C7ZXkZWd.js.map → EmptyState-tZBErBKF.js.map} +1 -1
- package/dist/ExcelDownloadButton.cjs +1 -1
- package/dist/ExcelDownloadButton.js +2 -2
- package/dist/FootNote.cjs +1 -1
- package/dist/FootNote.js +2 -2
- package/dist/GeoHubCompareMaps.cjs +1 -1
- package/dist/GeoHubCompareMaps.js +13 -13
- package/dist/GeoHubCompareMaps.js.map +1 -1
- package/dist/GeoHubMap.cjs +1 -1
- package/dist/GeoHubMap.js +8 -8
- package/dist/GeoHubMap.js.map +1 -1
- package/dist/GeoHubMapWithLayerSelection.cjs +1 -1
- package/dist/GeoHubMapWithLayerSelection.js +12 -12
- package/dist/GeoHubMapWithLayerSelection.js.map +1 -1
- package/dist/{GraphContainer-d8A46BK2.cjs → GraphContainer-B1EDxJ0S.cjs} +2 -2
- package/dist/{GraphContainer-d8A46BK2.cjs.map → GraphContainer-B1EDxJ0S.cjs.map} +1 -1
- package/dist/{GraphContainer-CRqzdKu2.js → GraphContainer-CF6ws3pd.js} +2 -2
- package/dist/{GraphContainer-CRqzdKu2.js.map → GraphContainer-CF6ws3pd.js.map} +1 -1
- package/dist/GraphDescription.cjs +1 -1
- package/dist/GraphDescription.js +2 -2
- package/dist/GraphEl-CBZdcvb7.cjs +2 -0
- package/dist/GraphEl-CBZdcvb7.cjs.map +1 -0
- package/dist/{GraphEl-Dyu_EIQb.js → GraphEl-DKrjuQNB.js} +79 -18
- package/dist/GraphEl-DKrjuQNB.js.map +1 -0
- package/dist/GraphFooter.cjs +1 -1
- package/dist/GraphFooter.js +2 -2
- package/dist/GraphHeader.cjs +1 -1
- package/dist/GraphHeader.js +1 -1
- package/dist/GraphTitle.cjs +1 -1
- package/dist/GraphTitle.js +2 -2
- package/dist/GriddedGraphs.cjs +1 -1
- package/dist/GriddedGraphs.d.ts +1 -1
- package/dist/GriddedGraphs.js +8 -8
- package/dist/GriddedGraphsFromConfig.cjs +1 -1
- package/dist/GriddedGraphsFromConfig.d.ts +1 -1
- package/dist/GriddedGraphsFromConfig.js +4 -4
- package/dist/GriddedGraphsFromConfig.js.map +1 -1
- package/dist/HeatMap.cjs +1 -1
- package/dist/HeatMap.js +14 -14
- package/dist/HeatMap.js.map +1 -1
- package/dist/Histogram.cjs +1 -1
- package/dist/Histogram.js +5 -5
- package/dist/Histogram.js.map +1 -1
- package/dist/HybridMap.cjs +1 -1
- package/dist/HybridMap.cjs.map +1 -1
- package/dist/HybridMap.js +48 -48
- package/dist/HybridMap.js.map +1 -1
- package/dist/ImageDownloadButton.cjs +1 -1
- package/dist/ImageDownloadButton.js +3 -3
- package/dist/LineChartWithConfidenceInterval.cjs +1 -1
- package/dist/LineChartWithConfidenceInterval.js +18 -18
- package/dist/LineChartWithConfidenceInterval.js.map +1 -1
- package/dist/LinearColorLegend.cjs +1 -1
- package/dist/LinearColorLegend.js +2 -2
- package/dist/{Modal-JW_IExO3.cjs → Modal-CaYa_TLE.cjs} +2 -2
- package/dist/{Modal-JW_IExO3.cjs.map → Modal-CaYa_TLE.cjs.map} +1 -1
- package/dist/{Modal-bMQA6bL_.js → Modal-Ch9wvKxF.js} +4 -4
- package/dist/{Modal-bMQA6bL_.js.map → Modal-Ch9wvKxF.js.map} +1 -1
- package/dist/MultiGraphDashboard.cjs +1 -1
- package/dist/MultiGraphDashboard.d.ts +1 -1
- package/dist/MultiGraphDashboard.js +5 -5
- package/dist/MultiGraphDashboardFromConfig.cjs +1 -1
- package/dist/MultiGraphDashboardFromConfig.d.ts +1 -1
- package/dist/MultiGraphDashboardFromConfig.js +4 -4
- package/dist/MultiGraphDashboardFromConfig.js.map +1 -1
- package/dist/MultiGraphDashboardWideToLongFormat.cjs +1 -1
- package/dist/MultiGraphDashboardWideToLongFormat.js +5 -5
- package/dist/MultiGraphDashboardWideToLongFormatFromConfig.cjs +1 -1
- package/dist/MultiGraphDashboardWideToLongFormatFromConfig.js +4 -4
- package/dist/MultiGraphDashboardWideToLongFormatFromConfig.js.map +1 -1
- package/dist/MultiLineAltChart.cjs +1 -1
- package/dist/MultiLineAltChart.js +17 -17
- package/dist/MultiLineAltChart.js.map +1 -1
- package/dist/MultiLineChart.cjs +1 -1
- package/dist/MultiLineChart.js +19 -19
- package/dist/MultiLineChart.js.map +1 -1
- package/dist/ParetoChart.cjs +1 -1
- package/dist/ParetoChart.js +15 -15
- package/dist/ParetoChart.js.map +1 -1
- package/dist/PerformanceIntensiveMultiGraphDashboard.cjs +1 -1
- package/dist/PerformanceIntensiveMultiGraphDashboard.d.ts +1 -1
- package/dist/PerformanceIntensiveMultiGraphDashboard.js +5 -5
- package/dist/PerformanceIntensiveMultiGraphDashboardFromConfig.cjs +1 -1
- package/dist/PerformanceIntensiveMultiGraphDashboardFromConfig.d.ts +1 -1
- package/dist/PerformanceIntensiveMultiGraphDashboardFromConfig.js +4 -4
- package/dist/PerformanceIntensiveMultiGraphDashboardFromConfig.js.map +1 -1
- package/dist/PerformanceIntensiveScrollStory.cjs +1 -1
- package/dist/PerformanceIntensiveScrollStory.d.ts +1 -1
- package/dist/PerformanceIntensiveScrollStory.js +6 -6
- package/dist/PerformanceIntensiveScrollStory.js.map +1 -1
- package/dist/RadarChart.cjs +1 -1
- package/dist/RadarChart.cjs.map +1 -1
- package/dist/RadarChart.js +9 -9
- package/dist/{ReferenceLine-2XCwHXQ4.js → ReferenceLine-DgtoRgw0.js} +5 -5
- package/dist/ReferenceLine-DgtoRgw0.js.map +1 -0
- package/dist/{ReferenceLine-BH0qdf4R.cjs → ReferenceLine-M9aP3dj-.cjs} +2 -2
- package/dist/{ReferenceLine-BH0qdf4R.cjs.map → ReferenceLine-M9aP3dj-.cjs.map} +1 -1
- package/dist/{RegressionLine-BOTTNSrr.cjs → RegressionLine-Ci-Dh0w0.cjs} +2 -2
- package/dist/{RegressionLine-BOTTNSrr.cjs.map → RegressionLine-Ci-Dh0w0.cjs.map} +1 -1
- package/dist/{RegressionLine-DAcY2DjT.js → RegressionLine-D2aqeBKp.js} +6 -6
- package/dist/RegressionLine-D2aqeBKp.js.map +1 -0
- package/dist/SVGDownloadButton.cjs +1 -1
- package/dist/SVGDownloadButton.js +2 -2
- package/dist/SankeyChart.cjs +1 -1
- package/dist/SankeyChart.cjs.map +1 -1
- package/dist/SankeyChart.js +61 -67
- package/dist/SankeyChart.js.map +1 -1
- package/dist/ScatterPlot.cjs +1 -1
- package/dist/ScatterPlot.js +23 -23
- package/dist/ScatterPlot.js.map +1 -1
- package/dist/ScrollStory.cjs +1 -1
- package/dist/ScrollStory.d.ts +1 -1
- package/dist/ScrollStory.js +4 -4
- package/dist/ScrollStory.js.map +1 -1
- package/dist/SimpleLineChart.cjs +1 -1
- package/dist/SimpleLineChart.js +19 -19
- package/dist/SimpleLineChart.js.map +1 -1
- package/dist/SingleGraphDashboard.cjs +1 -1
- package/dist/SingleGraphDashboard.d.ts +1 -1
- package/dist/SingleGraphDashboard.js +9 -9
- package/dist/SingleGraphDashboardFromConfig.cjs +1 -1
- package/dist/SingleGraphDashboardFromConfig.d.ts +1 -1
- package/dist/SingleGraphDashboardFromConfig.js +4 -4
- package/dist/SingleGraphDashboardFromConfig.js.map +1 -1
- package/dist/SingleGraphDashboardGeoHubMaps.cjs +1 -1
- package/dist/SingleGraphDashboardGeoHubMaps.js +5 -5
- package/dist/SingleGraphDashboardGeoHubMaps.js.map +1 -1
- package/dist/SingleGraphDashboardGeoHubMapsFromConfig.cjs +1 -1
- package/dist/SingleGraphDashboardGeoHubMapsFromConfig.js +4 -4
- package/dist/SingleGraphDashboardGeoHubMapsFromConfig.js.map +1 -1
- package/dist/SingleGraphDashboardThreeDGraphs.cjs +1 -1
- package/dist/SingleGraphDashboardThreeDGraphs.cjs.map +1 -1
- package/dist/SingleGraphDashboardThreeDGraphs.js +63 -70
- package/dist/SingleGraphDashboardThreeDGraphs.js.map +1 -1
- package/dist/SingleGraphDashboardThreeDGraphsFromConfig.cjs +1 -1
- package/dist/SingleGraphDashboardThreeDGraphsFromConfig.js +4 -4
- package/dist/SingleGraphDashboardThreeDGraphsFromConfig.js.map +1 -1
- package/dist/SlopeChart.cjs +1 -1
- package/dist/SlopeChart.js +12 -12
- package/dist/SlopeChart.js.map +1 -1
- package/dist/{Source-DYMJRrsq.cjs → Source-B5AoSlsi.cjs} +2 -2
- package/dist/{Source-DYMJRrsq.cjs.map → Source-B5AoSlsi.cjs.map} +1 -1
- package/dist/{Source-DwTHB8fn.js → Source-F8EYCYkV.js} +4 -4
- package/dist/{Source-DwTHB8fn.js.map → Source-F8EYCYkV.js.map} +1 -1
- package/dist/Source.cjs +1 -1
- package/dist/Source.js +3 -3
- package/dist/SparkLine.cjs +1 -1
- package/dist/SparkLine.js +8 -8
- package/dist/SparkLine.js.map +1 -1
- package/dist/{Spinner-DVBnY6Vg.js → Spinner--r2RrJV8.js} +2 -2
- package/dist/{Spinner-DVBnY6Vg.js.map → Spinner--r2RrJV8.js.map} +1 -1
- package/dist/{Spinner-CQZcjzwd.cjs → Spinner-jTMOLuw_.cjs} +2 -2
- package/dist/{Spinner-CQZcjzwd.cjs.map → Spinner-jTMOLuw_.cjs.map} +1 -1
- package/dist/StatCardFromData.cjs +1 -1
- package/dist/StatCardFromData.js +2 -2
- package/dist/StripChart.cjs +1 -1
- package/dist/StripChart.js +10 -10
- package/dist/StripChart.js.map +1 -1
- package/dist/ThreeDGlobe.cjs +1 -1
- package/dist/ThreeDGlobe.js +13 -13
- package/dist/ThreeDGlobe.js.map +1 -1
- package/dist/ThresholdColorLegendWithMouseOver.cjs +1 -1
- package/dist/ThresholdColorLegendWithMouseOver.js +3 -3
- package/dist/ThresholdColorLegendWithMouseOver.js.map +1 -1
- package/dist/{Tooltip-uUdw6wJL.cjs → Tooltip-BLa2EfMs.cjs} +2 -2
- package/dist/{Tooltip-uUdw6wJL.cjs.map → Tooltip-BLa2EfMs.cjs.map} +1 -1
- package/dist/{Tooltip-Dj5eVppQ.js → Tooltip-BRnAz2Gv.js} +3 -3
- package/dist/{Tooltip-Dj5eVppQ.js.map → Tooltip-BRnAz2Gv.js.map} +1 -1
- package/dist/TreeMapGraph.cjs +1 -1
- package/dist/TreeMapGraph.js +10 -10
- package/dist/TreeMapGraph.js.map +1 -1
- package/dist/Types.d.ts +8 -1
- package/dist/{Typography-PxtFcnJb.js → Typography-hWfh3H0J.js} +2 -2
- package/dist/{Typography-PxtFcnJb.js.map → Typography-hWfh3H0J.js.map} +1 -1
- package/dist/{Typography-DX7PlgQU.cjs → Typography-sa1UE0oF.cjs} +2 -2
- package/dist/{Typography-DX7PlgQU.cjs.map → Typography-sa1UE0oF.cjs.map} +1 -1
- package/dist/UnitChart.cjs +1 -1
- package/dist/UnitChart.js +8 -8
- package/dist/WaterfallChart.cjs +2 -0
- package/dist/WaterfallChart.cjs.map +1 -0
- package/dist/WaterfallChart.d.ts +207 -0
- package/dist/WaterfallChart.js +427 -0
- package/dist/WaterfallChart.js.map +1 -0
- package/dist/{XAxesLabels-Bt5NZBmX.cjs → XAxesLabels-C6o9jJal.cjs} +2 -2
- package/dist/{XAxesLabels-Bt5NZBmX.cjs.map → XAxesLabels-C6o9jJal.cjs.map} +1 -1
- package/dist/{XAxesLabels-Dy8E1SEo.js → XAxesLabels-rhK7lRjO.js} +3 -3
- package/dist/{XAxesLabels-Dy8E1SEo.js.map → XAxesLabels-rhK7lRjO.js.map} +1 -1
- package/dist/{XTicksAndGridLines-CObVFSm4.js → XTicksAndGridLines-CVZkZkpS.js} +2 -2
- package/dist/{XTicksAndGridLines-CObVFSm4.js.map → XTicksAndGridLines-CVZkZkpS.js.map} +1 -1
- package/dist/{XTicksAndGridLines-B6CELS7q.cjs → XTicksAndGridLines-CekrPykD.cjs} +2 -2
- package/dist/{XTicksAndGridLines-B6CELS7q.cjs.map → XTicksAndGridLines-CekrPykD.cjs.map} +1 -1
- package/dist/{YAxesLabels-DesLesUP.cjs → YAxesLabels-BQ2aCazV.cjs} +2 -2
- package/dist/{YAxesLabels-DesLesUP.cjs.map → YAxesLabels-BQ2aCazV.cjs.map} +1 -1
- package/dist/{YAxesLabels-a57ZRv-0.js → YAxesLabels-QICWVsHf.js} +3 -3
- package/dist/{YAxesLabels-a57ZRv-0.js.map → YAxesLabels-QICWVsHf.js.map} +1 -1
- package/dist/{YTicksAndGridLines-Blepl7XF.js → YTicksAndGridLines-GnXnSRF2.js} +2 -2
- package/dist/{YTicksAndGridLines-Blepl7XF.js.map → YTicksAndGridLines-GnXnSRF2.js.map} +1 -1
- package/dist/{YTicksAndGridLines-4pxTRlRK.cjs → YTicksAndGridLines-UzVC5eBM.cjs} +2 -2
- package/dist/{YTicksAndGridLines-4pxTRlRK.cjs.map → YTicksAndGridLines-UzVC5eBM.cjs.map} +1 -1
- package/dist/{band-DHUZ2X7J.js → band-DYty33LD.js} +2 -2
- package/dist/{band-DHUZ2X7J.js.map → band-DYty33LD.js.map} +1 -1
- package/dist/{checkIfMultiple-CIRtG0KE.js → checkIfMultiple-D9fVkeOq.js} +7 -19
- package/dist/{checkIfMultiple-CIRtG0KE.js.map → checkIfMultiple-D9fVkeOq.js.map} +1 -1
- package/dist/checkIfMultiple-DxnGtm3t.cjs +2 -0
- package/dist/{checkIfMultiple-wg6hJLXy.cjs.map → checkIfMultiple-DxnGtm3t.cjs.map} +1 -1
- package/dist/{customArea-BUhPiPT6.js → customArea-ASDaSE4u.js} +5 -5
- package/dist/{customArea-BUhPiPT6.js.map → customArea-ASDaSE4u.js.map} +1 -1
- package/dist/{customArea-CMF5g-C3.cjs → customArea-B1LWQBmM.cjs} +2 -2
- package/dist/{customArea-CMF5g-C3.cjs.map → customArea-B1LWQBmM.cjs.map} +1 -1
- package/dist/defaultLocale-C4wbwF1n.cjs +2 -0
- package/dist/defaultLocale-C4wbwF1n.cjs.map +1 -0
- package/dist/defaultLocale-CPy_WVtp.js +172 -0
- package/dist/defaultLocale-CPy_WVtp.js.map +1 -0
- package/dist/{ensureCompleteData-DH5c52Ub.js → ensureCompleteData-CDIukSG6.js} +2 -2
- package/dist/{ensureCompleteData-DH5c52Ub.js.map → ensureCompleteData-CDIukSG6.js.map} +1 -1
- package/dist/{ensureCompleteData-pZ9QO6kB.cjs → ensureCompleteData-D9bQTiVS.cjs} +2 -2
- package/dist/{ensureCompleteData-pZ9QO6kB.cjs.map → ensureCompleteData-D9bQTiVS.cjs.map} +1 -1
- package/dist/{fetchAndParseData-BpqkBPQL.js → fetchAndParseData-BAXhgTDM.js} +12 -18
- package/dist/{fetchAndParseData-BpqkBPQL.js.map → fetchAndParseData-BAXhgTDM.js.map} +1 -1
- package/dist/{fetchAndParseData-l5HGMAEs.cjs → fetchAndParseData-QTF6tjij.cjs} +3 -8
- package/dist/{fetchAndParseData-l5HGMAEs.cjs.map → fetchAndParseData-QTF6tjij.cjs.map} +1 -1
- package/dist/fetchAndParseData.cjs +1 -1
- package/dist/fetchAndParseData.js +1 -1
- package/dist/getCentroidCoordinates-CtBGrNC8.cjs +2 -0
- package/dist/getCentroidCoordinates-CtBGrNC8.cjs.map +1 -0
- package/dist/{getCentroidCoordinates-D7r34N4w.js → getCentroidCoordinates-s0OOUjLF.js} +15 -15
- package/dist/getCentroidCoordinates-s0OOUjLF.js.map +1 -0
- package/dist/{getGraphList-Dxwo9TDb.js → getGraphList-Bpd3PVmF.js} +7 -1
- package/dist/getGraphList-Bpd3PVmF.js.map +1 -0
- package/dist/getGraphList-DQ24IzAn.cjs +2 -0
- package/dist/getGraphList-DQ24IzAn.cjs.map +1 -0
- package/dist/{getJenks-GYmdwBqm.cjs → getJenks-BzJvhy_H.cjs} +2 -2
- package/dist/{getJenks-GYmdwBqm.cjs.map → getJenks-BzJvhy_H.cjs.map} +1 -1
- package/dist/{getJenks-BbngDoBQ.js → getJenks-DTCcQSDi.js} +2 -2
- package/dist/{getJenks-BbngDoBQ.js.map → getJenks-DTCcQSDi.js.map} +1 -1
- package/dist/getSliderMarks-CIuSoedo.cjs +2 -0
- package/dist/{getSliderMarks-BmADcPQt.cjs.map → getSliderMarks-CIuSoedo.cjs.map} +1 -1
- package/dist/{getSliderMarks-HIDJ0_Cd.js → getSliderMarks-Cvg8zHBU.js} +4 -9
- package/dist/getSliderMarks-Cvg8zHBU.js.map +1 -0
- package/dist/{imageDownload-NYXbvKob.cjs → imageDownload-61q6jyJW.cjs} +3 -3
- package/dist/imageDownload-61q6jyJW.cjs.map +1 -0
- package/dist/{imageDownload-BU4qnxJP.js → imageDownload-Diofs_vY.js} +14 -15
- package/dist/imageDownload-Diofs_vY.js.map +1 -0
- package/dist/{index-D491FEn1.js → index-BQYOuXdl.js} +15 -15
- package/dist/{index-D491FEn1.js.map → index-BQYOuXdl.js.map} +1 -1
- package/dist/{index-DxXnJ8Ti.cjs → index-C5K--w8d.cjs} +2 -2
- package/dist/index-C5K--w8d.cjs.map +1 -0
- package/dist/{index-DRXx7m-C.cjs → index-C6er0ety.cjs} +2 -2
- package/dist/{index-DRXx7m-C.cjs.map → index-C6er0ety.cjs.map} +1 -1
- package/dist/{index-CHPV5EwG-CTPQjnHt.cjs → index-CHPV5EwG-6v2a2njQ.cjs} +5 -69
- package/dist/{index-CHPV5EwG-CTPQjnHt.cjs.map → index-CHPV5EwG-6v2a2njQ.cjs.map} +1 -1
- package/dist/{index-CHPV5EwG-Curnpaqc.js → index-CHPV5EwG-DecW7_qr.js} +5 -77
- package/dist/{index-CHPV5EwG-Curnpaqc.js.map → index-CHPV5EwG-DecW7_qr.js.map} +1 -1
- package/dist/{index-SKgJALZg.js → index-CSiFiXPj.js} +3 -3
- package/dist/{index-SKgJALZg.js.map → index-CSiFiXPj.js.map} +1 -1
- package/dist/index-CoobIWNj.cjs +10 -0
- package/dist/index-CoobIWNj.cjs.map +1 -0
- package/dist/index-CtMBjvtq.js +148 -0
- package/dist/index-CtMBjvtq.js.map +1 -0
- package/dist/{index-Cw8sCyo_-BrHiWiRF.cjs → index-Cw8sCyo_-CEcCMKUi.cjs} +2 -2
- package/dist/{index-Cw8sCyo_-BrHiWiRF.cjs.map → index-Cw8sCyo_-CEcCMKUi.cjs.map} +1 -1
- package/dist/{index-Cw8sCyo_-B2hEKjzG.js → index-Cw8sCyo_-n4AacHGk.js} +6 -4
- package/dist/{index-Cw8sCyo_-B2hEKjzG.js.map → index-Cw8sCyo_-n4AacHGk.js.map} +1 -1
- package/dist/{index-R1gTfap5.js → index-D5ihtaJJ.js} +12 -12
- package/dist/{index-R1gTfap5.js.map → index-D5ihtaJJ.js.map} +1 -1
- package/dist/{index-B_sAFsEV.cjs → index-D69M6klB.cjs} +2 -2
- package/dist/{index-B_sAFsEV.cjs.map → index-D69M6klB.cjs.map} +1 -1
- package/dist/{index-GEsywGxz.js → index-DCsFBfJ_.js} +160 -104
- package/dist/index-DCsFBfJ_.js.map +1 -0
- package/dist/{index-WML2dCZ0.cjs → index-Dgjq6aZ2.cjs} +2 -2
- package/dist/{index-WML2dCZ0.cjs.map → index-Dgjq6aZ2.cjs.map} +1 -1
- package/dist/{index-Dzc_aaI9-BmkfPMyc.cjs → index-Dzc_aaI9-C3DbPpy3.cjs} +2 -2
- package/dist/{index-Dzc_aaI9-BmkfPMyc.cjs.map → index-Dzc_aaI9-C3DbPpy3.cjs.map} +1 -1
- package/dist/{index-Dzc_aaI9-Bb7gobH_.js → index-Dzc_aaI9-CG2Ar7l1.js} +4 -4
- package/dist/{index-Dzc_aaI9-Bb7gobH_.js.map → index-Dzc_aaI9-CG2Ar7l1.js.map} +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.d.ts +213 -3252
- package/dist/index.js +145 -161
- package/dist/index.js.map +1 -1
- package/dist/{linear-BqltdMeF.js → linear-CalFSAaO.js} +2 -2
- package/dist/{linear-BqltdMeF.js.map → linear-CalFSAaO.js.map} +1 -1
- package/dist/{linear-BwPAspcq.cjs → linear-CgUCbw9F.cjs} +2 -2
- package/dist/{linear-BwPAspcq.cjs.map → linear-CgUCbw9F.cjs.map} +1 -1
- package/dist/{ordinal-BJ6O_LC5.js → ordinal-CHaxGJ_l.js} +2 -2
- package/dist/{ordinal-BJ6O_LC5.js.map → ordinal-CHaxGJ_l.js.map} +1 -1
- package/dist/{parse-DlCRUFh_.js → parse-Dv4of-PN.js} +2 -67
- package/dist/{parse-DlCRUFh_.js.map → parse-Dv4of-PN.js.map} +1 -1
- package/dist/parse-xYI9yrvL.cjs +2 -0
- package/dist/{parse-hMnG_lRV.cjs.map → parse-xYI9yrvL.cjs.map} +1 -1
- package/dist/{pow-DgrUorRi.cjs → pow-BnyPO-NX.cjs} +2 -2
- package/dist/{pow-DgrUorRi.cjs.map → pow-BnyPO-NX.cjs.map} +1 -1
- package/dist/{pow-CM2aze4M.js → pow-CaIrlM4J.js} +2 -2
- package/dist/{pow-CM2aze4M.js.map → pow-CaIrlM4J.js.map} +1 -1
- package/dist/proxy-C4-uo6nS.cjs +2 -0
- package/dist/proxy-C4-uo6nS.cjs.map +1 -0
- package/dist/{proxy-BxkFHwUw.js → proxy-DRuSUlPL.js} +2828 -2717
- package/dist/proxy-DRuSUlPL.js.map +1 -0
- package/dist/{string2HTML-DhG75NqA.js → string2HTML-DUYZT1L9.js} +17 -17
- package/dist/{string2HTML-DhG75NqA.js.map → string2HTML-DUYZT1L9.js.map} +1 -1
- package/dist/{string2HTML-CPGr_I5E.cjs → string2HTML-xx9MzTtY.cjs} +3 -3
- package/dist/{string2HTML-CPGr_I5E.cjs.map → string2HTML-xx9MzTtY.cjs.map} +1 -1
- package/dist/style.css +1 -1
- package/dist/{time-BUL-dwnK.js → time-CAtex-RV.js} +2 -2
- package/dist/{time-BUL-dwnK.js.map → time-CAtex-RV.js.map} +1 -1
- package/dist/{time-CZd5YLSP.cjs → time-CkcKbhwe.cjs} +2 -2
- package/dist/{time-CZd5YLSP.cjs.map → time-CkcKbhwe.cjs.map} +1 -1
- package/dist/transformData.cjs +1 -1
- package/dist/transformData.d.ts +1 -1
- package/dist/transformData.js +3 -3
- package/dist/transformDataForAggregation-BFdha9Dx.cjs +2 -0
- package/dist/transformDataForAggregation-BFdha9Dx.cjs.map +1 -0
- package/dist/{transformDataForAggregation-j34UL73s.js → transformDataForAggregation-wdPf8bNt.js} +26 -11
- package/dist/transformDataForAggregation-wdPf8bNt.js.map +1 -0
- package/dist/{transformDataForGraphFromFile-CuXxR8uA.cjs → transformDataForGraphFromFile-DOhp1qrp.cjs} +2 -2
- package/dist/{transformDataForGraphFromFile-CuXxR8uA.cjs.map → transformDataForGraphFromFile-DOhp1qrp.cjs.map} +1 -1
- package/dist/{transformDataForGraphFromFile-DyP-83Nh.js → transformDataForGraphFromFile-dt9sHTVy.js} +3 -3
- package/dist/{transformDataForGraphFromFile-DyP-83Nh.js.map → transformDataForGraphFromFile-dt9sHTVy.js.map} +1 -1
- package/dist/{use-in-view-QcfiW0w3.cjs → use-in-view-C3o_ntMv.cjs} +2 -2
- package/dist/use-in-view-C3o_ntMv.cjs.map +1 -0
- package/dist/{use-in-view-Cxa7y1TH.js → use-in-view-Dl5L8LtP.js} +2 -2
- package/dist/use-in-view-Dl5L8LtP.js.map +1 -0
- package/dist/utils.cjs +1 -1
- package/dist/utils.js +4 -4
- package/dist/{x-BBpi7a_7-WVdj1j6r.js → x-BBpi7a_7-BsvWCzYM.js} +1 -31
- package/dist/{x-BBpi7a_7-WVdj1j6r.js.map → x-BBpi7a_7-BsvWCzYM.js.map} +1 -1
- package/dist/x-BBpi7a_7-DXYIEFwN.cjs +2 -0
- package/dist/{x-BBpi7a_7-mTo40uId.cjs.map → x-BBpi7a_7-DXYIEFwN.cjs.map} +1 -1
- package/dist/{zoom-C9MFjAaV.js → zoom-5AkJSuWO.js} +3 -3
- package/dist/zoom-5AkJSuWO.js.map +1 -0
- package/dist/{zoom-DPw8bba-.cjs → zoom-ChcvXFIz.cjs} +2 -2
- package/dist/zoom-ChcvXFIz.cjs.map +1 -0
- package/package.json +23 -15
- package/readme.md +33 -22
- package/dist/EmptyState-C7ZXkZWd.js +0 -15
- package/dist/GraphEl-BixTEyKW.cjs +0 -2
- package/dist/GraphEl-BixTEyKW.cjs.map +0 -1
- package/dist/GraphEl-Dyu_EIQb.js.map +0 -1
- package/dist/ReferenceLine-2XCwHXQ4.js.map +0 -1
- package/dist/RegressionLine-DAcY2DjT.js.map +0 -1
- package/dist/checkIfMultiple-wg6hJLXy.cjs +0 -12
- package/dist/defaultLocale-BEa-49Qz.js +0 -172
- package/dist/defaultLocale-BEa-49Qz.js.map +0 -1
- package/dist/defaultLocale-DIVzfLaQ.cjs +0 -2
- package/dist/defaultLocale-DIVzfLaQ.cjs.map +0 -1
- package/dist/getCentroidCoordinates-D7r34N4w.js.map +0 -1
- package/dist/getCentroidCoordinates-Dng1HVjO.cjs +0 -2
- package/dist/getCentroidCoordinates-Dng1HVjO.cjs.map +0 -1
- package/dist/getGraphList-CA17dvFB.cjs +0 -2
- package/dist/getGraphList-CA17dvFB.cjs.map +0 -1
- package/dist/getGraphList-Dxwo9TDb.js.map +0 -1
- package/dist/getSchema.cjs +0 -2
- package/dist/getSchema.cjs.map +0 -1
- package/dist/getSchema.d.ts +0 -3258
- package/dist/getSchema.js +0 -1129
- package/dist/getSchema.js.map +0 -1
- package/dist/getSliderMarks-BmADcPQt.cjs +0 -6
- package/dist/getSliderMarks-HIDJ0_Cd.js.map +0 -1
- package/dist/imageDownload-BU4qnxJP.js.map +0 -1
- package/dist/imageDownload-NYXbvKob.cjs.map +0 -1
- package/dist/index-BqfRwk1n.js +0 -146
- package/dist/index-BqfRwk1n.js.map +0 -1
- package/dist/index-DG2bgAva.cjs +0 -10
- package/dist/index-DG2bgAva.cjs.map +0 -1
- package/dist/index-DxXnJ8Ti.cjs.map +0 -1
- package/dist/index-GEsywGxz.js.map +0 -1
- package/dist/parse-hMnG_lRV.cjs +0 -2
- package/dist/proxy-BxkFHwUw.js.map +0 -1
- package/dist/proxy-BxvUI_9l.cjs +0 -2
- package/dist/proxy-BxvUI_9l.cjs.map +0 -1
- package/dist/transformDataForAggregation-CYoB5Xsk.cjs +0 -2
- package/dist/transformDataForAggregation-CYoB5Xsk.cjs.map +0 -1
- package/dist/transformDataForAggregation-j34UL73s.js.map +0 -1
- package/dist/use-in-view-Cxa7y1TH.js.map +0 -1
- package/dist/use-in-view-QcfiW0w3.cjs.map +0 -1
- package/dist/validateSchema.cjs +0 -2
- package/dist/validateSchema.cjs.map +0 -1
- package/dist/validateSchema.d.ts +0 -66
- package/dist/validateSchema.js +0 -109
- package/dist/validateSchema.js.map +0 -1
- package/dist/x-BBpi7a_7-mTo40uId.cjs +0 -27
- package/dist/zoom-C9MFjAaV.js.map +0 -1
- package/dist/zoom-DPw8bba-.cjs.map +0 -1
package/dist/StripChart.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"StripChart.js","sources":["../src/Utils/getTickPosition.ts","../src/Components/Graphs/StripChart/Graph.tsx","../src/Components/Graphs/StripChart/index.tsx"],"sourcesContent":["export function getTickPositions(count: number, width: number) {\r\n if (count < 2) return [];\r\n const step = width / (count - 1);\r\n return Array.from({ length: count }, (_, i) => i * step);\r\n}\r\n","import isEqual from 'fast-deep-equal';\r\nimport { useRef, useState } from 'react';\r\nimport { scaleLinear } from 'd3-scale';\r\nimport { cn } from '@undp/design-system-react/cn';\r\nimport { AnimatePresence, motion, useInView } from 'motion/react';\r\nimport orderBy from 'lodash.orderby';\r\n\r\nimport {\r\n AnimateDataType,\r\n ClassNameObject,\r\n CustomLayerDataType,\r\n StripChartDataType,\r\n StyleObject,\r\n} from '@/Types';\r\nimport { Tooltip } from '@/Components/Elements/Tooltip';\r\nimport { checkIfNullOrUndefined } from '@/Utils/checkIfNullOrUndefined';\r\nimport { numberFormattingFunction } from '@/Utils/numberFormattingFunction';\r\nimport { Colors } from '@/Components/ColorPalette';\r\nimport { getTickPositions } from '@/Utils/getTickPosition';\r\nimport { DetailsModal } from '@/Components/Elements/DetailsModal';\r\n\r\ninterface Props {\r\n data: StripChartDataType[];\r\n width: number;\r\n height: number;\r\n selectedColor?: string;\r\n colors: string[];\r\n colorDomain: string[];\r\n radius: number;\r\n leftMargin?: number;\r\n rightMargin?: number;\r\n topMargin?: number;\r\n bottomMargin?: number;\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n tooltip?: string | ((_d: any) => React.ReactNode);\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n onSeriesMouseOver?: (_d: any) => void;\r\n highlightedDataPoints: (string | number)[];\r\n maxValue?: number;\r\n minValue?: number;\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n onSeriesMouseClick?: (_d: any) => void;\r\n prefix: string;\r\n suffix: string;\r\n stripType: 'strip' | 'dot';\r\n highlightColor?: string;\r\n dotOpacity: number;\r\n resetSelectionOnDoubleClick: boolean;\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n detailsOnClick?: string | ((_d: any) => React.ReactNode);\r\n styles?: StyleObject;\r\n classNames?: ClassNameObject;\r\n valueColor?: string;\r\n animate: AnimateDataType;\r\n noOfTicks: number;\r\n dimmedOpacity: number;\r\n precision: number;\r\n customLayers: CustomLayerDataType[];\r\n}\r\n\r\nexport function VerticalGraph(props: Props) {\r\n const {\r\n data,\r\n width,\r\n height,\r\n colors,\r\n colorDomain,\r\n radius,\r\n leftMargin = 20,\r\n rightMargin = 20,\r\n topMargin = 10,\r\n bottomMargin = 10,\r\n tooltip,\r\n onSeriesMouseOver,\r\n highlightedDataPoints,\r\n selectedColor,\r\n minValue,\r\n maxValue,\r\n onSeriesMouseClick,\r\n noOfTicks,\r\n prefix,\r\n suffix,\r\n stripType,\r\n highlightColor,\r\n dotOpacity,\r\n resetSelectionOnDoubleClick,\r\n detailsOnClick,\r\n styles,\r\n classNames,\r\n valueColor,\r\n animate,\r\n dimmedOpacity,\r\n precision,\r\n customLayers,\r\n } = props;\r\n const svgRef = useRef(null);\r\n const isInView = useInView(svgRef, {\r\n once: animate.once,\r\n amount: animate.amount,\r\n });\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n const [mouseOverData, setMouseOverData] = useState<any>(undefined);\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n const [mouseClickData, setMouseClickData] = useState<any>(undefined);\r\n const [eventX, setEventX] = useState<number | undefined>(undefined);\r\n const [eventY, setEventY] = useState<number | undefined>(undefined);\r\n const margin = {\r\n top: topMargin,\r\n bottom: bottomMargin,\r\n left: leftMargin,\r\n right: rightMargin,\r\n };\r\n const graphWidth = width - margin.left - margin.right;\r\n const graphHeight = height - margin.top - margin.bottom;\r\n\r\n const dataWithId = data.map((d, i) => ({ ...d, id: `${i}` }));\r\n\r\n const sortedData = orderBy(\r\n dataWithId,\r\n [\r\n item => {\r\n const index = (highlightedDataPoints || []).indexOf(item.label);\r\n return index === -1 ? Infinity : index;\r\n },\r\n ],\r\n ['desc'],\r\n );\r\n const yMaxValue = !checkIfNullOrUndefined(maxValue)\r\n ? (maxValue as number)\r\n : Math.max(...data.filter(d => !checkIfNullOrUndefined(d.position)).map(d => d.position)) < 0\r\n ? 0\r\n : Math.max(...data.filter(d => !checkIfNullOrUndefined(d.position)).map(d => d.position));\r\n const yMinValue = !checkIfNullOrUndefined(minValue)\r\n ? (minValue as number)\r\n : Math.min(...data.filter(d => !checkIfNullOrUndefined(d.position)).map(d => d.position)) >= 0\r\n ? 0\r\n : Math.min(...data.filter(d => !checkIfNullOrUndefined(d.position)).map(d => d.position));\r\n const y = scaleLinear().domain([yMinValue, yMaxValue]).range([graphHeight, 0]).nice();\r\n const ticks = getTickPositions(noOfTicks, graphHeight);\r\n return (\r\n <>\r\n <motion.svg\r\n width={`${width}px`}\r\n height={`${height}px`}\r\n viewBox={`0 0 ${width} ${height}`}\r\n direction='ltr'\r\n ref={svgRef}\r\n >\r\n <g transform={`translate(${margin.left},${margin.top})`}>\r\n {customLayers.filter(d => d.position === 'before').map(d => d.layer)}\r\n <AnimatePresence>\r\n {sortedData.map(d => {\r\n return (\r\n <motion.g\r\n className='undp-viz-g-with-hover'\r\n key={d.label}\r\n variants={{\r\n initial: {\r\n opacity: 0,\r\n x: graphWidth / 2,\r\n y: y(0),\r\n },\r\n whileInView: {\r\n x: graphWidth / 2,\r\n y: y(d.position),\r\n opacity: selectedColor\r\n ? d.color\r\n ? colors[colorDomain.indexOf(d.color)] === selectedColor\r\n ? 0.95\r\n : dimmedOpacity\r\n : dimmedOpacity\r\n : highlightedDataPoints.length !== 0\r\n ? highlightedDataPoints.indexOf(d.label) !== -1\r\n ? 0.95\r\n : dimmedOpacity\r\n : dotOpacity,\r\n transition: { duration: animate.duration },\r\n },\r\n }}\r\n initial='initial'\r\n animate={isInView ? 'whileInView' : 'initial'}\r\n exit={{ opacity: 0, transition: { duration: animate.duration } }}\r\n onMouseEnter={event => {\r\n setMouseOverData(d);\r\n setEventY(event.clientY);\r\n setEventX(event.clientX);\r\n onSeriesMouseOver?.(d);\r\n }}\r\n onClick={() => {\r\n if (onSeriesMouseClick || detailsOnClick) {\r\n if (isEqual(mouseClickData, d) && resetSelectionOnDoubleClick) {\r\n setMouseClickData(undefined);\r\n onSeriesMouseClick?.(undefined);\r\n } else {\r\n setMouseClickData(d);\r\n onSeriesMouseClick?.(d);\r\n }\r\n }\r\n }}\r\n onMouseMove={event => {\r\n setMouseOverData(d);\r\n setEventY(event.clientY);\r\n setEventX(event.clientX);\r\n }}\r\n onMouseLeave={() => {\r\n setMouseOverData(undefined);\r\n setEventX(undefined);\r\n setEventY(undefined);\r\n onSeriesMouseOver?.(undefined);\r\n }}\r\n >\r\n {stripType === 'dot' ? (\r\n <motion.circle\r\n cy={0}\r\n cx={0}\r\n variants={{\r\n initial: {\r\n fill:\r\n highlightColor && highlightedDataPoints\r\n ? highlightedDataPoints.indexOf(d.label) !== -1\r\n ? highlightColor\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)]\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)],\r\n },\r\n whileInView: {\r\n fill:\r\n highlightColor && highlightedDataPoints\r\n ? highlightedDataPoints.indexOf(d.label) !== -1\r\n ? highlightColor\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)]\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)],\r\n transition: { duration: animate.duration },\r\n },\r\n }}\r\n initial='initial'\r\n animate={isInView ? 'whileInView' : 'initial'}\r\n exit={{ opacity: 0, transition: { duration: animate.duration } }}\r\n r={radius}\r\n />\r\n ) : (\r\n <motion.rect\r\n y={-1}\r\n height={2}\r\n variants={{\r\n initial: {\r\n x: 0 - radius,\r\n width: radius * 2,\r\n fill:\r\n highlightColor && highlightedDataPoints\r\n ? highlightedDataPoints.indexOf(d.label) !== -1\r\n ? highlightColor\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)]\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)],\r\n },\r\n whileInView: {\r\n x: 0 - radius,\r\n width: radius * 2,\r\n fill:\r\n highlightColor && highlightedDataPoints\r\n ? highlightedDataPoints.indexOf(d.label) !== -1\r\n ? highlightColor\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)]\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)],\r\n transition: { duration: animate.duration },\r\n },\r\n }}\r\n initial='initial'\r\n animate={isInView ? 'whileInView' : 'initial'}\r\n exit={{ opacity: 0, transition: { duration: animate.duration } }}\r\n />\r\n )}\r\n {highlightedDataPoints.length !== 0 ? (\r\n highlightedDataPoints.indexOf(d.label) !== -1 ? (\r\n <motion.text\r\n y={0}\r\n dy='0.33em'\r\n variants={{\r\n initial: {\r\n opacity: 0,\r\n x: 0 + radius + 3,\r\n fill:\r\n valueColor ||\r\n (highlightColor && highlightedDataPoints\r\n ? highlightedDataPoints.indexOf(d.label) !== -1\r\n ? highlightColor\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)]\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)]),\r\n },\r\n whileInView: {\r\n opacity: 1,\r\n x: 0 + radius + 3,\r\n fill:\r\n valueColor ||\r\n (highlightColor && highlightedDataPoints\r\n ? highlightedDataPoints.indexOf(d.label) !== -1\r\n ? highlightColor\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)]\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)]),\r\n transition: { duration: animate.duration },\r\n },\r\n }}\r\n initial='initial'\r\n animate={isInView ? 'whileInView' : 'initial'}\r\n exit={{ opacity: 0, transition: { duration: animate.duration } }}\r\n style={{\r\n textAnchor: 'start',\r\n ...(styles?.graphObjectValues || {}),\r\n }}\r\n className={cn(\r\n 'graph-value text-sm font-bold',\r\n classNames?.graphObjectValues,\r\n )}\r\n >\r\n {numberFormattingFunction(d.position, 'NA', precision, prefix, suffix)}\r\n </motion.text>\r\n ) : null\r\n ) : null}\r\n </motion.g>\r\n );\r\n })}\r\n {ticks.map((tick, i) => (\r\n <text\r\n key={i}\r\n y={tick}\r\n x={graphWidth / 2 + radius + 5}\r\n style={{\r\n textAnchor: 'start',\r\n ...(styles?.yAxis?.labels || {}),\r\n }}\r\n className={cn(\r\n 'fill-primary-gray-550 dark:fill-primary-gray-500 text-xs',\r\n classNames?.yAxis?.labels,\r\n )}\r\n >\r\n {numberFormattingFunction(y.invert(tick), 'NA', precision, prefix, suffix)}\r\n </text>\r\n ))}\r\n </AnimatePresence>\r\n {customLayers.filter(d => d.position === 'after').map(d => d.layer)}\r\n </g>\r\n </motion.svg>\r\n {mouseOverData && tooltip && eventX && eventY ? (\r\n <Tooltip\r\n data={mouseOverData}\r\n body={tooltip}\r\n xPos={eventX}\r\n yPos={eventY}\r\n backgroundStyle={styles?.tooltip}\r\n className={classNames?.tooltip}\r\n />\r\n ) : null}\r\n {detailsOnClick && mouseClickData !== undefined ? (\r\n <DetailsModal\r\n body={detailsOnClick}\r\n data={mouseClickData}\r\n setData={setMouseClickData}\r\n className={classNames?.modal}\r\n />\r\n ) : null}\r\n </>\r\n );\r\n}\r\n\r\nexport function HorizontalGraph(props: Props) {\r\n const {\r\n data,\r\n width,\r\n height,\r\n colors,\r\n colorDomain,\r\n radius,\r\n leftMargin = 5,\r\n rightMargin = 5,\r\n topMargin = 10,\r\n bottomMargin = 10,\r\n tooltip,\r\n onSeriesMouseOver,\r\n highlightedDataPoints,\r\n selectedColor,\r\n minValue,\r\n maxValue,\r\n onSeriesMouseClick,\r\n prefix,\r\n suffix,\r\n stripType,\r\n highlightColor,\r\n dotOpacity,\r\n resetSelectionOnDoubleClick,\r\n detailsOnClick,\r\n styles,\r\n classNames,\r\n valueColor,\r\n animate,\r\n noOfTicks,\r\n dimmedOpacity,\r\n precision,\r\n customLayers,\r\n } = props;\r\n const svgRef = useRef(null);\r\n const isInView = useInView(svgRef, {\r\n once: animate.once,\r\n amount: animate.amount,\r\n });\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n const [mouseOverData, setMouseOverData] = useState<any>(undefined);\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n const [mouseClickData, setMouseClickData] = useState<any>(undefined);\r\n const [eventX, setEventX] = useState<number | undefined>(undefined);\r\n const [eventY, setEventY] = useState<number | undefined>(undefined);\r\n const margin = {\r\n top: topMargin,\r\n bottom: bottomMargin,\r\n left: leftMargin,\r\n right: rightMargin,\r\n };\r\n const graphWidth = width - margin.left - margin.right;\r\n const graphHeight = height - margin.top - margin.bottom;\r\n\r\n const dataWithId = data.map((d, i) => ({ ...d, id: `${i}` }));\r\n\r\n const sortedData = orderBy(\r\n dataWithId,\r\n [\r\n item => {\r\n const index = (highlightedDataPoints || []).indexOf(item.label);\r\n return index === -1 ? Infinity : index;\r\n },\r\n ],\r\n ['desc'],\r\n );\r\n const xMaxValue = !checkIfNullOrUndefined(maxValue)\r\n ? (maxValue as number)\r\n : Math.max(...data.filter(d => !checkIfNullOrUndefined(d.position)).map(d => d.position)) < 0\r\n ? 0\r\n : Math.max(...data.filter(d => !checkIfNullOrUndefined(d.position)).map(d => d.position));\r\n const xMinValue = !checkIfNullOrUndefined(minValue)\r\n ? (minValue as number)\r\n : Math.min(...data.filter(d => !checkIfNullOrUndefined(d.position)).map(d => d.position)) >= 0\r\n ? 0\r\n : Math.min(...data.filter(d => !checkIfNullOrUndefined(d.position)).map(d => d.position));\r\n const x = scaleLinear().domain([xMinValue, xMaxValue]).range([0, graphWidth]).nice();\r\n const ticks = getTickPositions(noOfTicks, graphWidth);\r\n return (\r\n <>\r\n <motion.svg\r\n width={`${width}px`}\r\n height={`${height}px`}\r\n viewBox={`0 0 ${width} ${height}`}\r\n direction='ltr'\r\n ref={svgRef}\r\n >\r\n <g transform={`translate(${margin.left},${margin.top})`}>\r\n {customLayers.filter(d => d.position === 'before').map(d => d.layer)}\r\n <AnimatePresence>\r\n {sortedData.map(d => {\r\n return (\r\n <motion.g\r\n className='undp-viz-g-with-hover'\r\n key={d.label}\r\n variants={{\r\n initial: {\r\n opacity: 0,\r\n x: x(0),\r\n y: graphHeight / 2,\r\n },\r\n whileInView: {\r\n x: x(d.position),\r\n y: graphHeight / 2,\r\n opacity: selectedColor\r\n ? d.color\r\n ? colors[colorDomain.indexOf(d.color)] === selectedColor\r\n ? 0.95\r\n : dimmedOpacity\r\n : dimmedOpacity\r\n : highlightedDataPoints.length !== 0\r\n ? highlightedDataPoints.indexOf(d.label) !== -1\r\n ? 0.95\r\n : dimmedOpacity\r\n : dotOpacity,\r\n transition: { duration: animate.duration },\r\n },\r\n }}\r\n initial='initial'\r\n animate={isInView ? 'whileInView' : 'initial'}\r\n exit={{ opacity: 0, transition: { duration: animate.duration } }}\r\n onMouseEnter={event => {\r\n setMouseOverData(d);\r\n setEventY(event.clientY);\r\n setEventX(event.clientX);\r\n onSeriesMouseOver?.(d);\r\n }}\r\n onClick={() => {\r\n if (onSeriesMouseClick || detailsOnClick) {\r\n if (isEqual(mouseClickData, d) && resetSelectionOnDoubleClick) {\r\n setMouseClickData(undefined);\r\n onSeriesMouseClick?.(undefined);\r\n } else {\r\n setMouseClickData(d);\r\n onSeriesMouseClick?.(d);\r\n }\r\n }\r\n }}\r\n onMouseMove={event => {\r\n setMouseOverData(d);\r\n setEventY(event.clientY);\r\n setEventX(event.clientX);\r\n }}\r\n onMouseLeave={() => {\r\n setMouseOverData(undefined);\r\n setEventX(undefined);\r\n setEventY(undefined);\r\n onSeriesMouseOver?.(undefined);\r\n }}\r\n >\r\n {stripType === 'dot' ? (\r\n <motion.circle\r\n cy={0}\r\n cx={0}\r\n variants={{\r\n initial: {\r\n fill:\r\n highlightColor && highlightedDataPoints\r\n ? highlightedDataPoints.indexOf(d.label) !== -1\r\n ? highlightColor\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)]\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)],\r\n },\r\n whileInView: {\r\n fill:\r\n highlightColor && highlightedDataPoints\r\n ? highlightedDataPoints.indexOf(d.label) !== -1\r\n ? highlightColor\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)]\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)],\r\n transition: { duration: animate.duration },\r\n },\r\n }}\r\n initial='initial'\r\n animate={isInView ? 'whileInView' : 'initial'}\r\n exit={{ opacity: 0, transition: { duration: animate.duration } }}\r\n r={radius}\r\n />\r\n ) : (\r\n <motion.rect\r\n x={-1}\r\n width={2}\r\n variants={{\r\n initial: {\r\n y: 0 - radius,\r\n height: radius * 2,\r\n fill:\r\n highlightColor && highlightedDataPoints\r\n ? highlightedDataPoints.indexOf(d.label) !== -1\r\n ? highlightColor\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)]\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)],\r\n },\r\n whileInView: {\r\n y: 0 - radius,\r\n height: radius * 2,\r\n fill:\r\n highlightColor && highlightedDataPoints\r\n ? highlightedDataPoints.indexOf(d.label) !== -1\r\n ? highlightColor\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)]\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)],\r\n transition: { duration: animate.duration },\r\n },\r\n }}\r\n initial='initial'\r\n animate={isInView ? 'whileInView' : 'initial'}\r\n exit={{ opacity: 0, transition: { duration: animate.duration } }}\r\n />\r\n )}\r\n {highlightedDataPoints.length !== 0 ? (\r\n highlightedDataPoints.indexOf(d.label) !== -1 ? (\r\n <motion.text\r\n x={0}\r\n variants={{\r\n initial: {\r\n opacity: 0,\r\n y: 0 - radius - 5,\r\n fill:\r\n valueColor ||\r\n (highlightColor && highlightedDataPoints\r\n ? highlightedDataPoints.indexOf(d.label) !== -1\r\n ? highlightColor\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)]\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)]),\r\n },\r\n whileInView: {\r\n opacity: 1,\r\n y: 0 - radius - 5,\r\n fill:\r\n valueColor ||\r\n (highlightColor && highlightedDataPoints\r\n ? highlightedDataPoints.indexOf(d.label) !== -1\r\n ? highlightColor\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)]\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)]),\r\n transition: { duration: animate.duration },\r\n },\r\n }}\r\n initial='initial'\r\n animate={isInView ? 'whileInView' : 'initial'}\r\n exit={{ opacity: 0, transition: { duration: animate.duration } }}\r\n style={{\r\n textAnchor: 'middle',\r\n ...(styles?.graphObjectValues || {}),\r\n }}\r\n className={cn(\r\n 'graph-value text-sm font-bold',\r\n classNames?.graphObjectValues,\r\n )}\r\n >\r\n {numberFormattingFunction(d.position, 'NA', precision, prefix, suffix)}\r\n </motion.text>\r\n ) : null\r\n ) : null}\r\n </motion.g>\r\n );\r\n })}\r\n {ticks.map((tick, i) => (\r\n <text\r\n key={i}\r\n x={tick}\r\n y={graphHeight / 2 + radius}\r\n style={{\r\n textAnchor: i === 0 ? 'start' : i === ticks.length - 1 ? 'end' : 'middle',\r\n ...(styles?.xAxis?.labels || {}),\r\n }}\r\n className={cn(\r\n 'fill-primary-gray-550 dark:fill-primary-gray-500 text-xs',\r\n classNames?.xAxis?.labels,\r\n )}\r\n dy='1em'\r\n >\r\n {numberFormattingFunction(x.invert(tick), 'NA', precision, prefix, suffix)}\r\n </text>\r\n ))}\r\n </AnimatePresence>\r\n {customLayers.filter(d => d.position === 'after').map(d => d.layer)}\r\n </g>\r\n </motion.svg>\r\n {mouseOverData && tooltip && eventX && eventY ? (\r\n <Tooltip\r\n data={mouseOverData}\r\n body={tooltip}\r\n xPos={eventX}\r\n yPos={eventY}\r\n backgroundStyle={styles?.tooltip}\r\n className={classNames?.tooltip}\r\n />\r\n ) : null}\r\n {detailsOnClick && mouseClickData !== undefined ? (\r\n <DetailsModal\r\n body={detailsOnClick}\r\n data={mouseClickData}\r\n setData={setMouseClickData}\r\n className={classNames?.modal}\r\n />\r\n ) : null}\r\n </>\r\n );\r\n}\r\n","import { useEffect, useRef, useState } from 'react';\r\n\r\nimport { HorizontalGraph, VerticalGraph } from './Graph';\r\n\r\nimport { uniqBy } from '@/Utils/uniqBy';\r\nimport { Colors } from '@/Components/ColorPalette';\r\nimport {\r\n SourcesDataType,\r\n Languages,\r\n StripChartDataType,\r\n StyleObject,\r\n ClassNameObject,\r\n CustomLayerDataType,\r\n AnimateDataType,\r\n} from '@/Types';\r\nimport { GraphArea, GraphContainer } from '@/Components/Elements/GraphContainer';\r\nimport { EmptyState } from '@/Components/Elements/EmptyState';\r\nimport { ColorLegendWithMouseOver } from '@/Components/Elements/ColorLegendWithMouseOver';\r\nimport { GraphFooter } from '@/Components/Elements/GraphFooter';\r\nimport { GraphHeader } from '@/Components/Elements/GraphHeader';\r\n\r\ninterface Props {\r\n // Data\r\n /** Array of data objects */\r\n data: StripChartDataType[];\r\n\r\n /** Orientation of the graph */\r\n orientation?: 'vertical' | 'horizontal';\r\n\r\n // Titles, Labels, and Sources\r\n /** Title of the graph */\r\n graphTitle?: string | React.ReactNode;\r\n /** Description of the graph */\r\n graphDescription?: string | React.ReactNode;\r\n /** Footnote for the graph */\r\n footNote?: string | React.ReactNode;\r\n /** Source data for the graph */\r\n sources?: SourcesDataType[];\r\n /** Accessibility label */\r\n ariaLabel?: string;\r\n\r\n // Colors and Styling\r\n /** Color or array of colors for circles */\r\n colors?: string | string[];\r\n /** Color of the highlighted data points */\r\n highlightColor?: string;\r\n /** Domain of colors for the graph */\r\n colorDomain?: string[];\r\n /** Title for the color legend */\r\n colorLegendTitle?: string;\r\n /** Color of value labels */\r\n valueColor?: string;\r\n /** Background color of the graph */\r\n backgroundColor?: string | boolean;\r\n /** Custom styles for the graph. Each object should be a valid React CSS style object. */\r\n styles?: StyleObject;\r\n /** Custom class names */\r\n classNames?: ClassNameObject;\r\n\r\n // Size and Spacing\r\n /** Width of the graph */\r\n width?: number;\r\n /** Height of the graph */\r\n height?: number;\r\n /** Minimum height of the graph */\r\n minHeight?: number;\r\n /** Relative height scaling factor. This overwrites the height props */\r\n relativeHeight?: number;\r\n /** Padding around the graph. Defaults to 0 if no backgroundColor is mentioned else defaults to 1rem */\r\n padding?: string;\r\n /** Left margin of the graph */\r\n leftMargin?: number;\r\n /** Right margin of the graph */\r\n rightMargin?: number;\r\n /** Top margin of the graph */\r\n topMargin?: number;\r\n /** Bottom margin of the graph */\r\n bottomMargin?: number;\r\n\r\n // Values and Ticks\r\n /** Prefix for values */\r\n prefix?: string;\r\n /** Suffix for values */\r\n suffix?: string;\r\n /** Maximum value for the chart */\r\n maxValue?: number;\r\n /** Minimum value for the chart */\r\n minValue?: number;\r\n\r\n // Graph Parameters\r\n /** Number of ticks on the axis */\r\n noOfTicks?: number;\r\n /** Radius of the dots or width of the strips */\r\n radius?: number;\r\n /** Opacity of each dot or strip */\r\n dotOpacity?: number;\r\n /** Type of strip */\r\n stripType?: 'strip' | 'dot';\r\n /** Toggle visibility of color scale. This is only applicable if the data props hae color parameter */\r\n showColorScale?: boolean;\r\n /** Toggle visibility of NA color in the color scale. This is only applicable if the data props hae color parameter and showColorScale prop is true */\r\n showNAColor?: boolean;\r\n /** Data points to highlight. Use the label value from data to highlight the data point */\r\n highlightedDataPoints?: (string | number)[];\r\n /** Defines the opacity of the non-highlighted data */\r\n dimmedOpacity?: number;\r\n /** Toggles if the graph animates in when loaded. */\r\n animate?: boolean | AnimateDataType;\r\n /** Specifies the number of decimal places to display in the value. */\r\n precision?: number;\r\n /** Optional SVG <g> element or function that renders custom content behind or in front of the graph. */\r\n customLayers?: CustomLayerDataType[];\r\n /** Enable graph download option as png */\r\n graphDownload?: boolean;\r\n /** Enable data download option as a csv */\r\n dataDownload?: boolean;\r\n /** Reset selection on double-click. Only applicable when used in a dashboard context with filters. */\r\n resetSelectionOnDoubleClick?: boolean;\r\n\r\n // Interactions and Callbacks\r\n /** Tooltip content. If the type is string then this uses the [handlebar](../?path=/docs/misc-handlebars-templates-and-custom-helpers--docs) template to display the data */\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n tooltip?: string | ((_d: any) => React.ReactNode);\r\n /** Details displayed on the modal when user clicks of a data point. If the type is string then this uses the [handlebar](../?path=/docs/misc-handlebars-templates-and-custom-helpers--docs) template to display the data */\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n detailsOnClick?: string | ((_d: any) => React.ReactNode);\r\n /** Callback for mouse over event */\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n onSeriesMouseOver?: (_d: any) => void;\r\n /** Callback for mouse click event */\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n onSeriesMouseClick?: (_d: any) => void;\r\n\r\n // Configuration and Options\r\n /** Language setting */\r\n language?: Languages;\r\n /** Color theme */\r\n theme?: 'light' | 'dark';\r\n /** Unique ID for the graph */\r\n graphID?: string;\r\n}\r\n\r\nexport function StripChart(props: Props) {\r\n const {\r\n data,\r\n graphTitle,\r\n colors,\r\n sources,\r\n graphDescription,\r\n height,\r\n width,\r\n footNote,\r\n colorDomain,\r\n colorLegendTitle,\r\n radius = 5,\r\n padding,\r\n backgroundColor = false,\r\n leftMargin,\r\n rightMargin,\r\n topMargin,\r\n bottomMargin,\r\n tooltip,\r\n relativeHeight,\r\n onSeriesMouseOver,\r\n showColorScale = true,\r\n highlightedDataPoints = [],\r\n graphID,\r\n minValue,\r\n maxValue,\r\n onSeriesMouseClick,\r\n noOfTicks = 2,\r\n graphDownload = false,\r\n dataDownload = false,\r\n prefix = '',\r\n suffix = '',\r\n stripType = 'dot',\r\n language = 'en',\r\n highlightColor,\r\n dotOpacity = 0.3,\r\n showNAColor = true,\r\n minHeight = 0,\r\n theme = 'light',\r\n ariaLabel,\r\n valueColor,\r\n resetSelectionOnDoubleClick = true,\r\n detailsOnClick,\r\n orientation = 'vertical',\r\n styles,\r\n classNames,\r\n animate = false,\r\n dimmedOpacity = 0.3,\r\n precision = 2,\r\n customLayers = [],\r\n } = props;\r\n\r\n const Comp = orientation === 'horizontal' ? HorizontalGraph : VerticalGraph;\r\n\r\n const [svgWidth, setSvgWidth] = useState(0);\r\n const [svgHeight, setSvgHeight] = useState(0);\r\n const [selectedColor, setSelectedColor] = useState<string | undefined>(undefined);\r\n\r\n const graphDiv = useRef<HTMLDivElement>(null);\r\n const graphParentDiv = useRef<HTMLDivElement>(null);\r\n useEffect(() => {\r\n const resizeObserver = new ResizeObserver(entries => {\r\n setSvgWidth(entries[0].target.clientWidth || 620);\r\n setSvgHeight(entries[0].target.clientHeight || 480);\r\n });\r\n if (graphDiv.current) {\r\n resizeObserver.observe(graphDiv.current);\r\n }\r\n return () => resizeObserver.disconnect();\r\n }, []);\r\n return (\r\n <GraphContainer\r\n className={classNames?.graphContainer}\r\n style={styles?.graphContainer}\r\n id={graphID}\r\n ref={graphParentDiv}\r\n aria-label={ariaLabel}\r\n backgroundColor={backgroundColor}\r\n theme={theme}\r\n language={language}\r\n minHeight={minHeight}\r\n width={width}\r\n height={height}\r\n relativeHeight={relativeHeight}\r\n padding={padding}\r\n >\r\n {graphTitle || graphDescription || graphDownload || dataDownload ? (\r\n <GraphHeader\r\n styles={{\r\n title: styles?.title,\r\n description: styles?.description,\r\n }}\r\n classNames={{\r\n title: classNames?.title,\r\n description: classNames?.description,\r\n }}\r\n graphTitle={graphTitle}\r\n graphDescription={graphDescription}\r\n width={width}\r\n graphDownload={graphDownload ? graphParentDiv : undefined}\r\n dataDownload={\r\n dataDownload\r\n ? data.map(d => d.data).filter(d => d !== undefined).length > 0\r\n ? data.map(d => d.data).filter(d => d !== undefined)\r\n : data.filter(d => d !== undefined)\r\n : null\r\n }\r\n />\r\n ) : null}\r\n {showColorScale !== false && data.filter(el => el.color).length !== 0 && data.length > 0 ? (\r\n <ColorLegendWithMouseOver\r\n width={width}\r\n colorLegendTitle={colorLegendTitle}\r\n colors={(colors as string[] | undefined) || Colors[theme].categoricalColors.colors}\r\n colorDomain={colorDomain || (uniqBy(data, 'color', true) as string[])}\r\n setSelectedColor={setSelectedColor}\r\n showNAColor={showNAColor}\r\n className={classNames?.colorLegend}\r\n />\r\n ) : null}\r\n <GraphArea ref={graphDiv}>\r\n {data.length === 0 && <EmptyState />}\r\n {svgWidth && svgHeight && data.length > 0 ? (\r\n <Comp\r\n data={data}\r\n width={svgWidth}\r\n height={svgHeight}\r\n colorDomain={\r\n data.filter(el => el.color).length === 0\r\n ? []\r\n : colorDomain || (uniqBy(data, 'color', true) as string[])\r\n }\r\n colors={\r\n data.filter(el => el.color).length === 0\r\n ? colors\r\n ? [colors as string]\r\n : [Colors.primaryColors['blue-600']]\r\n : (colors as string[] | undefined) || Colors[theme].categoricalColors.colors\r\n }\r\n selectedColor={selectedColor}\r\n radius={radius}\r\n leftMargin={leftMargin}\r\n rightMargin={rightMargin}\r\n topMargin={topMargin}\r\n bottomMargin={bottomMargin}\r\n tooltip={tooltip}\r\n onSeriesMouseOver={onSeriesMouseOver}\r\n highlightedDataPoints={highlightedDataPoints}\r\n minValue={minValue}\r\n maxValue={maxValue}\r\n onSeriesMouseClick={onSeriesMouseClick}\r\n prefix={prefix}\r\n suffix={suffix}\r\n stripType={stripType}\r\n highlightColor={highlightColor}\r\n dotOpacity={dotOpacity}\r\n resetSelectionOnDoubleClick={resetSelectionOnDoubleClick}\r\n detailsOnClick={detailsOnClick}\r\n styles={styles}\r\n classNames={classNames}\r\n valueColor={valueColor}\r\n animate={\r\n animate === true\r\n ? { duration: 0.5, once: true, amount: 0.5 }\r\n : animate || { duration: 0, once: true, amount: 0 }\r\n }\r\n noOfTicks={noOfTicks}\r\n dimmedOpacity={dimmedOpacity}\r\n precision={precision}\r\n customLayers={customLayers}\r\n />\r\n ) : null}\r\n </GraphArea>\r\n {sources || footNote ? (\r\n <GraphFooter\r\n styles={{ footnote: styles?.footnote, source: styles?.source }}\r\n classNames={{\r\n footnote: classNames?.footnote,\r\n source: classNames?.source,\r\n }}\r\n sources={sources}\r\n footNote={footNote}\r\n width={width}\r\n />\r\n ) : null}\r\n </GraphContainer>\r\n );\r\n}\r\n"],"names":["getTickPositions","count","width","step","Array","from","length","_","i","VerticalGraph","props","$","_c","data","height","colors","colorDomain","radius","leftMargin","t0","rightMargin","t1","topMargin","t2","bottomMargin","t3","tooltip","onSeriesMouseOver","highlightedDataPoints","selectedColor","minValue","maxValue","onSeriesMouseClick","noOfTicks","prefix","suffix","stripType","highlightColor","dotOpacity","resetSelectionOnDoubleClick","detailsOnClick","styles","classNames","valueColor","animate","dimmedOpacity","precision","customLayers","undefined","svgRef","useRef","t4","amount","once","isInView","useInView","mouseOverData","setMouseOverData","useState","mouseClickData","setMouseClickData","eventX","setEventX","eventY","setEventY","t5","top","bottom","left","right","margin","graphWidth","graphHeight","T0","T1","t10","t11","t12","t13","t14","t6","t7","t8","t9","duration","graphObjectValues","yAxis","labels","dataWithId","map","_temp","t15","item","index","indexOf","label","Infinity","sortedData","orderBy","t16","checkIfNullOrUndefined","Math","max","filter","_temp2","_temp3","_temp4","_temp5","yMaxValue","t17","min","_temp6","_temp7","_temp8","_temp9","yMinValue","y","scaleLinear","domain","range","nice","ticks","motion","svg","_temp0","_temp1","AnimatePresence","d_10","jsxs","initial","opacity","x","whileInView","d","position","color","transition","event","clientY","clientX","isEqual","event_0","fill","_temp10","Colors","gray","_temp11","_temp12","_temp13","jsx","_temp14","_temp15","_temp16","_temp17","_temp18","_temp19","_temp20","_temp21","textAnchor","cn","numberFormattingFunction","tick","i_0","invert","_temp22","_temp23","t18","t19","Tooltip","t20","modal","DetailsModal","t21","Fragment","d_12","layer","d_11","el_10","el","el_9","el_8","el_7","el_6","el_5","el_4","el_3","el_2","el_1","el_0","d_9","d_8","d_5","d_4","d_7","d_6","d_1","d_0","d_3","d_2","id","HorizontalGraph","xAxis","_temp24","_temp25","_temp26","_temp27","_temp28","xMaxValue","_temp29","_temp30","_temp31","_temp32","xMinValue","_temp33","_temp34","_temp35","_temp36","_temp37","_temp38","_temp39","_temp40","_temp41","_temp42","_temp43","_temp44","_temp45","_temp46","_temp47","_temp48","StripChart","graphTitle","sources","graphDescription","footNote","colorLegendTitle","padding","backgroundColor","relativeHeight","showColorScale","graphID","graphDownload","dataDownload","language","showNAColor","minHeight","theme","ariaLabel","orientation","t22","Comp","svgWidth","setSvgWidth","svgHeight","setSvgHeight","setSelectedColor","graphDiv","graphParentDiv","t23","t24","Symbol","for","resizeObserver","ResizeObserver","entries","target","clientWidth","clientHeight","current","observe","disconnect","useEffect","t25","graphContainer","t26","t27","description","title","GraphHeader","t28","colorLegend","ColorLegendWithMouseOver","categoricalColors","uniqBy","t29","EmptyState","t30","primaryColors","t31","GraphArea","t32","footnote","source","GraphFooter","t33","GraphContainer"],"mappings":";;;;;;;;;;;;;;;;;;;AAAO,SAASA,GAAiBC,GAAeC,G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x"],"sourcesContent":["export function getTickPositions(count: number, width: number) {\r\n if (count < 2) return [];\r\n const step = width / (count - 1);\r\n return Array.from({ length: count }, (_, i) => i * step);\r\n}\r\n","import isEqual from 'fast-deep-equal';\r\nimport { useRef, useState } from 'react';\r\nimport { scaleLinear } from 'd3-scale';\r\nimport { cn } from '@undp/design-system-react/cn';\r\nimport { AnimatePresence, motion, useInView } from 'motion/react';\r\nimport orderBy from 'lodash.orderby';\r\n\r\nimport {\r\n AnimateDataType,\r\n ClassNameObject,\r\n CustomLayerDataType,\r\n StripChartDataType,\r\n StyleObject,\r\n} from '@/Types';\r\nimport { Tooltip } from '@/Components/Elements/Tooltip';\r\nimport { checkIfNullOrUndefined } from '@/Utils/checkIfNullOrUndefined';\r\nimport { numberFormattingFunction } from '@/Utils/numberFormattingFunction';\r\nimport { Colors } from '@/Components/ColorPalette';\r\nimport { getTickPositions } from '@/Utils/getTickPosition';\r\nimport { DetailsModal } from '@/Components/Elements/DetailsModal';\r\n\r\ninterface Props {\r\n data: StripChartDataType[];\r\n width: number;\r\n height: number;\r\n selectedColor?: string;\r\n colors: string[];\r\n colorDomain: string[];\r\n radius: number;\r\n leftMargin?: number;\r\n rightMargin?: number;\r\n topMargin?: number;\r\n bottomMargin?: number;\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n tooltip?: string | ((_d: any) => React.ReactNode);\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n onSeriesMouseOver?: (_d: any) => void;\r\n highlightedDataPoints: (string | number)[];\r\n maxValue?: number;\r\n minValue?: number;\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n onSeriesMouseClick?: (_d: any) => void;\r\n prefix: string;\r\n suffix: string;\r\n stripType: 'strip' | 'dot';\r\n highlightColor?: string;\r\n dotOpacity: number;\r\n resetSelectionOnDoubleClick: boolean;\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n detailsOnClick?: string | ((_d: any) => React.ReactNode);\r\n styles?: StyleObject;\r\n classNames?: ClassNameObject;\r\n valueColor?: string;\r\n animate: AnimateDataType;\r\n noOfTicks: number;\r\n dimmedOpacity: number;\r\n precision: number;\r\n customLayers: CustomLayerDataType[];\r\n}\r\n\r\nexport function VerticalGraph(props: Props) {\r\n const {\r\n data,\r\n width,\r\n height,\r\n colors,\r\n colorDomain,\r\n radius,\r\n leftMargin = 20,\r\n rightMargin = 20,\r\n topMargin = 10,\r\n bottomMargin = 10,\r\n tooltip,\r\n onSeriesMouseOver,\r\n highlightedDataPoints,\r\n selectedColor,\r\n minValue,\r\n maxValue,\r\n onSeriesMouseClick,\r\n noOfTicks,\r\n prefix,\r\n suffix,\r\n stripType,\r\n highlightColor,\r\n dotOpacity,\r\n resetSelectionOnDoubleClick,\r\n detailsOnClick,\r\n styles,\r\n classNames,\r\n valueColor,\r\n animate,\r\n dimmedOpacity,\r\n precision,\r\n customLayers,\r\n } = props;\r\n const svgRef = useRef(null);\r\n const isInView = useInView(svgRef, {\r\n once: animate.once,\r\n amount: animate.amount,\r\n });\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n const [mouseOverData, setMouseOverData] = useState<any>(undefined);\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n const [mouseClickData, setMouseClickData] = useState<any>(undefined);\r\n const [eventX, setEventX] = useState<number | undefined>(undefined);\r\n const [eventY, setEventY] = useState<number | undefined>(undefined);\r\n const margin = {\r\n top: topMargin,\r\n bottom: bottomMargin,\r\n left: leftMargin,\r\n right: rightMargin,\r\n };\r\n const graphWidth = width - margin.left - margin.right;\r\n const graphHeight = height - margin.top - margin.bottom;\r\n\r\n const dataWithId = data.map((d, i) => ({ ...d, id: `${i}` }));\r\n\r\n const sortedData = orderBy(\r\n dataWithId,\r\n [\r\n item => {\r\n const index = (highlightedDataPoints || []).indexOf(item.label);\r\n return index === -1 ? Infinity : index;\r\n },\r\n ],\r\n ['desc'],\r\n );\r\n const yMaxValue = !checkIfNullOrUndefined(maxValue)\r\n ? (maxValue as number)\r\n : Math.max(...data.filter(d => !checkIfNullOrUndefined(d.position)).map(d => d.position)) < 0\r\n ? 0\r\n : Math.max(...data.filter(d => !checkIfNullOrUndefined(d.position)).map(d => d.position));\r\n const yMinValue = !checkIfNullOrUndefined(minValue)\r\n ? (minValue as number)\r\n : Math.min(...data.filter(d => !checkIfNullOrUndefined(d.position)).map(d => d.position)) >= 0\r\n ? 0\r\n : Math.min(...data.filter(d => !checkIfNullOrUndefined(d.position)).map(d => d.position));\r\n const y = scaleLinear().domain([yMinValue, yMaxValue]).range([graphHeight, 0]).nice();\r\n const ticks = getTickPositions(noOfTicks, graphHeight);\r\n return (\r\n <>\r\n <motion.svg\r\n width={`${width}px`}\r\n height={`${height}px`}\r\n viewBox={`0 0 ${width} ${height}`}\r\n direction='ltr'\r\n ref={svgRef}\r\n >\r\n <g transform={`translate(${margin.left},${margin.top})`}>\r\n {customLayers.filter(d => d.position === 'before').map(d => d.layer)}\r\n <AnimatePresence>\r\n {sortedData.map(d => {\r\n return (\r\n <motion.g\r\n className='undp-viz-g-with-hover'\r\n key={d.label}\r\n variants={{\r\n initial: {\r\n opacity: 0,\r\n x: graphWidth / 2,\r\n y: y(0),\r\n },\r\n whileInView: {\r\n x: graphWidth / 2,\r\n y: y(d.position),\r\n opacity: selectedColor\r\n ? d.color\r\n ? colors[colorDomain.indexOf(d.color)] === selectedColor\r\n ? 0.95\r\n : dimmedOpacity\r\n : dimmedOpacity\r\n : highlightedDataPoints.length !== 0\r\n ? highlightedDataPoints.indexOf(d.label) !== -1\r\n ? 0.95\r\n : dimmedOpacity\r\n : dotOpacity,\r\n transition: { duration: animate.duration },\r\n },\r\n }}\r\n initial='initial'\r\n animate={isInView ? 'whileInView' : 'initial'}\r\n exit={{ opacity: 0, transition: { duration: animate.duration } }}\r\n onMouseEnter={event => {\r\n setMouseOverData(d);\r\n setEventY(event.clientY);\r\n setEventX(event.clientX);\r\n onSeriesMouseOver?.(d);\r\n }}\r\n onClick={() => {\r\n if (onSeriesMouseClick || detailsOnClick) {\r\n if (isEqual(mouseClickData, d) && resetSelectionOnDoubleClick) {\r\n setMouseClickData(undefined);\r\n onSeriesMouseClick?.(undefined);\r\n } else {\r\n setMouseClickData(d);\r\n onSeriesMouseClick?.(d);\r\n }\r\n }\r\n }}\r\n onMouseMove={event => {\r\n setMouseOverData(d);\r\n setEventY(event.clientY);\r\n setEventX(event.clientX);\r\n }}\r\n onMouseLeave={() => {\r\n setMouseOverData(undefined);\r\n setEventX(undefined);\r\n setEventY(undefined);\r\n onSeriesMouseOver?.(undefined);\r\n }}\r\n >\r\n {stripType === 'dot' ? (\r\n <motion.circle\r\n cy={0}\r\n cx={0}\r\n variants={{\r\n initial: {\r\n fill:\r\n highlightColor && highlightedDataPoints\r\n ? highlightedDataPoints.indexOf(d.label) !== -1\r\n ? highlightColor\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)]\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)],\r\n },\r\n whileInView: {\r\n fill:\r\n highlightColor && highlightedDataPoints\r\n ? highlightedDataPoints.indexOf(d.label) !== -1\r\n ? highlightColor\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)]\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)],\r\n transition: { duration: animate.duration },\r\n },\r\n }}\r\n initial='initial'\r\n animate={isInView ? 'whileInView' : 'initial'}\r\n exit={{ opacity: 0, transition: { duration: animate.duration } }}\r\n r={radius}\r\n />\r\n ) : (\r\n <motion.rect\r\n y={-1}\r\n height={2}\r\n variants={{\r\n initial: {\r\n x: 0 - radius,\r\n width: radius * 2,\r\n fill:\r\n highlightColor && highlightedDataPoints\r\n ? highlightedDataPoints.indexOf(d.label) !== -1\r\n ? highlightColor\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)]\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)],\r\n },\r\n whileInView: {\r\n x: 0 - radius,\r\n width: radius * 2,\r\n fill:\r\n highlightColor && highlightedDataPoints\r\n ? highlightedDataPoints.indexOf(d.label) !== -1\r\n ? highlightColor\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)]\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)],\r\n transition: { duration: animate.duration },\r\n },\r\n }}\r\n initial='initial'\r\n animate={isInView ? 'whileInView' : 'initial'}\r\n exit={{ opacity: 0, transition: { duration: animate.duration } }}\r\n />\r\n )}\r\n {highlightedDataPoints.length !== 0 ? (\r\n highlightedDataPoints.indexOf(d.label) !== -1 ? (\r\n <motion.text\r\n y={0}\r\n dy='0.33em'\r\n variants={{\r\n initial: {\r\n opacity: 0,\r\n x: 0 + radius + 3,\r\n fill:\r\n valueColor ||\r\n (highlightColor && highlightedDataPoints\r\n ? highlightedDataPoints.indexOf(d.label) !== -1\r\n ? highlightColor\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)]\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)]),\r\n },\r\n whileInView: {\r\n opacity: 1,\r\n x: 0 + radius + 3,\r\n fill:\r\n valueColor ||\r\n (highlightColor && highlightedDataPoints\r\n ? highlightedDataPoints.indexOf(d.label) !== -1\r\n ? highlightColor\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)]\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)]),\r\n transition: { duration: animate.duration },\r\n },\r\n }}\r\n initial='initial'\r\n animate={isInView ? 'whileInView' : 'initial'}\r\n exit={{ opacity: 0, transition: { duration: animate.duration } }}\r\n style={{\r\n textAnchor: 'start',\r\n ...(styles?.graphObjectValues || {}),\r\n }}\r\n className={cn(\r\n 'graph-value text-sm font-bold',\r\n classNames?.graphObjectValues,\r\n )}\r\n >\r\n {numberFormattingFunction(d.position, 'NA', precision, prefix, suffix)}\r\n </motion.text>\r\n ) : null\r\n ) : null}\r\n </motion.g>\r\n );\r\n })}\r\n {ticks.map((tick, i) => (\r\n <text\r\n key={i}\r\n y={tick}\r\n x={graphWidth / 2 + radius + 5}\r\n style={{\r\n textAnchor: 'start',\r\n ...(styles?.yAxis?.labels || {}),\r\n }}\r\n className={cn(\r\n 'fill-primary-gray-550 dark:fill-primary-gray-500 text-xs',\r\n classNames?.yAxis?.labels,\r\n )}\r\n >\r\n {numberFormattingFunction(y.invert(tick), 'NA', precision, prefix, suffix)}\r\n </text>\r\n ))}\r\n </AnimatePresence>\r\n {customLayers.filter(d => d.position === 'after').map(d => d.layer)}\r\n </g>\r\n </motion.svg>\r\n {mouseOverData && tooltip && eventX && eventY ? (\r\n <Tooltip\r\n data={mouseOverData}\r\n body={tooltip}\r\n xPos={eventX}\r\n yPos={eventY}\r\n backgroundStyle={styles?.tooltip}\r\n className={classNames?.tooltip}\r\n />\r\n ) : null}\r\n {detailsOnClick && mouseClickData !== undefined ? (\r\n <DetailsModal\r\n body={detailsOnClick}\r\n data={mouseClickData}\r\n setData={setMouseClickData}\r\n className={classNames?.modal}\r\n />\r\n ) : null}\r\n </>\r\n );\r\n}\r\n\r\nexport function HorizontalGraph(props: Props) {\r\n const {\r\n data,\r\n width,\r\n height,\r\n colors,\r\n colorDomain,\r\n radius,\r\n leftMargin = 5,\r\n rightMargin = 5,\r\n topMargin = 10,\r\n bottomMargin = 10,\r\n tooltip,\r\n onSeriesMouseOver,\r\n highlightedDataPoints,\r\n selectedColor,\r\n minValue,\r\n maxValue,\r\n onSeriesMouseClick,\r\n prefix,\r\n suffix,\r\n stripType,\r\n highlightColor,\r\n dotOpacity,\r\n resetSelectionOnDoubleClick,\r\n detailsOnClick,\r\n styles,\r\n classNames,\r\n valueColor,\r\n animate,\r\n noOfTicks,\r\n dimmedOpacity,\r\n precision,\r\n customLayers,\r\n } = props;\r\n const svgRef = useRef(null);\r\n const isInView = useInView(svgRef, {\r\n once: animate.once,\r\n amount: animate.amount,\r\n });\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n const [mouseOverData, setMouseOverData] = useState<any>(undefined);\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n const [mouseClickData, setMouseClickData] = useState<any>(undefined);\r\n const [eventX, setEventX] = useState<number | undefined>(undefined);\r\n const [eventY, setEventY] = useState<number | undefined>(undefined);\r\n const margin = {\r\n top: topMargin,\r\n bottom: bottomMargin,\r\n left: leftMargin,\r\n right: rightMargin,\r\n };\r\n const graphWidth = width - margin.left - margin.right;\r\n const graphHeight = height - margin.top - margin.bottom;\r\n\r\n const dataWithId = data.map((d, i) => ({ ...d, id: `${i}` }));\r\n\r\n const sortedData = orderBy(\r\n dataWithId,\r\n [\r\n item => {\r\n const index = (highlightedDataPoints || []).indexOf(item.label);\r\n return index === -1 ? Infinity : index;\r\n },\r\n ],\r\n ['desc'],\r\n );\r\n const xMaxValue = !checkIfNullOrUndefined(maxValue)\r\n ? (maxValue as number)\r\n : Math.max(...data.filter(d => !checkIfNullOrUndefined(d.position)).map(d => d.position)) < 0\r\n ? 0\r\n : Math.max(...data.filter(d => !checkIfNullOrUndefined(d.position)).map(d => d.position));\r\n const xMinValue = !checkIfNullOrUndefined(minValue)\r\n ? (minValue as number)\r\n : Math.min(...data.filter(d => !checkIfNullOrUndefined(d.position)).map(d => d.position)) >= 0\r\n ? 0\r\n : Math.min(...data.filter(d => !checkIfNullOrUndefined(d.position)).map(d => d.position));\r\n const x = scaleLinear().domain([xMinValue, xMaxValue]).range([0, graphWidth]).nice();\r\n const ticks = getTickPositions(noOfTicks, graphWidth);\r\n return (\r\n <>\r\n <motion.svg\r\n width={`${width}px`}\r\n height={`${height}px`}\r\n viewBox={`0 0 ${width} ${height}`}\r\n direction='ltr'\r\n ref={svgRef}\r\n >\r\n <g transform={`translate(${margin.left},${margin.top})`}>\r\n {customLayers.filter(d => d.position === 'before').map(d => d.layer)}\r\n <AnimatePresence>\r\n {sortedData.map(d => {\r\n return (\r\n <motion.g\r\n className='undp-viz-g-with-hover'\r\n key={d.label}\r\n variants={{\r\n initial: {\r\n opacity: 0,\r\n x: x(0),\r\n y: graphHeight / 2,\r\n },\r\n whileInView: {\r\n x: x(d.position),\r\n y: graphHeight / 2,\r\n opacity: selectedColor\r\n ? d.color\r\n ? colors[colorDomain.indexOf(d.color)] === selectedColor\r\n ? 0.95\r\n : dimmedOpacity\r\n : dimmedOpacity\r\n : highlightedDataPoints.length !== 0\r\n ? highlightedDataPoints.indexOf(d.label) !== -1\r\n ? 0.95\r\n : dimmedOpacity\r\n : dotOpacity,\r\n transition: { duration: animate.duration },\r\n },\r\n }}\r\n initial='initial'\r\n animate={isInView ? 'whileInView' : 'initial'}\r\n exit={{ opacity: 0, transition: { duration: animate.duration } }}\r\n onMouseEnter={event => {\r\n setMouseOverData(d);\r\n setEventY(event.clientY);\r\n setEventX(event.clientX);\r\n onSeriesMouseOver?.(d);\r\n }}\r\n onClick={() => {\r\n if (onSeriesMouseClick || detailsOnClick) {\r\n if (isEqual(mouseClickData, d) && resetSelectionOnDoubleClick) {\r\n setMouseClickData(undefined);\r\n onSeriesMouseClick?.(undefined);\r\n } else {\r\n setMouseClickData(d);\r\n onSeriesMouseClick?.(d);\r\n }\r\n }\r\n }}\r\n onMouseMove={event => {\r\n setMouseOverData(d);\r\n setEventY(event.clientY);\r\n setEventX(event.clientX);\r\n }}\r\n onMouseLeave={() => {\r\n setMouseOverData(undefined);\r\n setEventX(undefined);\r\n setEventY(undefined);\r\n onSeriesMouseOver?.(undefined);\r\n }}\r\n >\r\n {stripType === 'dot' ? (\r\n <motion.circle\r\n cy={0}\r\n cx={0}\r\n variants={{\r\n initial: {\r\n fill:\r\n highlightColor && highlightedDataPoints\r\n ? highlightedDataPoints.indexOf(d.label) !== -1\r\n ? highlightColor\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)]\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)],\r\n },\r\n whileInView: {\r\n fill:\r\n highlightColor && highlightedDataPoints\r\n ? highlightedDataPoints.indexOf(d.label) !== -1\r\n ? highlightColor\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)]\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)],\r\n transition: { duration: animate.duration },\r\n },\r\n }}\r\n initial='initial'\r\n animate={isInView ? 'whileInView' : 'initial'}\r\n exit={{ opacity: 0, transition: { duration: animate.duration } }}\r\n r={radius}\r\n />\r\n ) : (\r\n <motion.rect\r\n x={-1}\r\n width={2}\r\n variants={{\r\n initial: {\r\n y: 0 - radius,\r\n height: radius * 2,\r\n fill:\r\n highlightColor && highlightedDataPoints\r\n ? highlightedDataPoints.indexOf(d.label) !== -1\r\n ? highlightColor\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)]\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)],\r\n },\r\n whileInView: {\r\n y: 0 - radius,\r\n height: radius * 2,\r\n fill:\r\n highlightColor && highlightedDataPoints\r\n ? highlightedDataPoints.indexOf(d.label) !== -1\r\n ? highlightColor\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)]\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)],\r\n transition: { duration: animate.duration },\r\n },\r\n }}\r\n initial='initial'\r\n animate={isInView ? 'whileInView' : 'initial'}\r\n exit={{ opacity: 0, transition: { duration: animate.duration } }}\r\n />\r\n )}\r\n {highlightedDataPoints.length !== 0 ? (\r\n highlightedDataPoints.indexOf(d.label) !== -1 ? (\r\n <motion.text\r\n x={0}\r\n variants={{\r\n initial: {\r\n opacity: 0,\r\n y: 0 - radius - 5,\r\n fill:\r\n valueColor ||\r\n (highlightColor && highlightedDataPoints\r\n ? highlightedDataPoints.indexOf(d.label) !== -1\r\n ? highlightColor\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)]\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)]),\r\n },\r\n whileInView: {\r\n opacity: 1,\r\n y: 0 - radius - 5,\r\n fill:\r\n valueColor ||\r\n (highlightColor && highlightedDataPoints\r\n ? highlightedDataPoints.indexOf(d.label) !== -1\r\n ? highlightColor\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)]\r\n : data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)]),\r\n transition: { duration: animate.duration },\r\n },\r\n }}\r\n initial='initial'\r\n animate={isInView ? 'whileInView' : 'initial'}\r\n exit={{ opacity: 0, transition: { duration: animate.duration } }}\r\n style={{\r\n textAnchor: 'middle',\r\n ...(styles?.graphObjectValues || {}),\r\n }}\r\n className={cn(\r\n 'graph-value text-sm font-bold',\r\n classNames?.graphObjectValues,\r\n )}\r\n >\r\n {numberFormattingFunction(d.position, 'NA', precision, prefix, suffix)}\r\n </motion.text>\r\n ) : null\r\n ) : null}\r\n </motion.g>\r\n );\r\n })}\r\n {ticks.map((tick, i) => (\r\n <text\r\n key={i}\r\n x={tick}\r\n y={graphHeight / 2 + radius}\r\n style={{\r\n textAnchor: i === 0 ? 'start' : i === ticks.length - 1 ? 'end' : 'middle',\r\n ...(styles?.xAxis?.labels || {}),\r\n }}\r\n className={cn(\r\n 'fill-primary-gray-550 dark:fill-primary-gray-500 text-xs',\r\n classNames?.xAxis?.labels,\r\n )}\r\n dy='1em'\r\n >\r\n {numberFormattingFunction(x.invert(tick), 'NA', precision, prefix, suffix)}\r\n </text>\r\n ))}\r\n </AnimatePresence>\r\n {customLayers.filter(d => d.position === 'after').map(d => d.layer)}\r\n </g>\r\n </motion.svg>\r\n {mouseOverData && tooltip && eventX && eventY ? (\r\n <Tooltip\r\n data={mouseOverData}\r\n body={tooltip}\r\n xPos={eventX}\r\n yPos={eventY}\r\n backgroundStyle={styles?.tooltip}\r\n className={classNames?.tooltip}\r\n />\r\n ) : null}\r\n {detailsOnClick && mouseClickData !== undefined ? (\r\n <DetailsModal\r\n body={detailsOnClick}\r\n data={mouseClickData}\r\n setData={setMouseClickData}\r\n className={classNames?.modal}\r\n />\r\n ) : null}\r\n </>\r\n );\r\n}\r\n","import { useEffect, useRef, useState } from 'react';\r\n\r\nimport { HorizontalGraph, VerticalGraph } from './Graph';\r\n\r\nimport { uniqBy } from '@/Utils/uniqBy';\r\nimport { Colors } from '@/Components/ColorPalette';\r\nimport {\r\n SourcesDataType,\r\n Languages,\r\n StripChartDataType,\r\n StyleObject,\r\n ClassNameObject,\r\n CustomLayerDataType,\r\n AnimateDataType,\r\n} from '@/Types';\r\nimport { GraphArea, GraphContainer } from '@/Components/Elements/GraphContainer';\r\nimport { EmptyState } from '@/Components/Elements/EmptyState';\r\nimport { ColorLegendWithMouseOver } from '@/Components/Elements/ColorLegendWithMouseOver';\r\nimport { GraphFooter } from '@/Components/Elements/GraphFooter';\r\nimport { GraphHeader } from '@/Components/Elements/GraphHeader';\r\n\r\ninterface Props {\r\n // Data\r\n /** Array of data objects */\r\n data: StripChartDataType[];\r\n\r\n /** Orientation of the graph */\r\n orientation?: 'vertical' | 'horizontal';\r\n\r\n // Titles, Labels, and Sources\r\n /** Title of the graph */\r\n graphTitle?: string | React.ReactNode;\r\n /** Description of the graph */\r\n graphDescription?: string | React.ReactNode;\r\n /** Footnote for the graph */\r\n footNote?: string | React.ReactNode;\r\n /** Source data for the graph */\r\n sources?: SourcesDataType[];\r\n /** Accessibility label */\r\n ariaLabel?: string;\r\n\r\n // Colors and Styling\r\n /** Color or array of colors for circles */\r\n colors?: string | string[];\r\n /** Color of the highlighted data points */\r\n highlightColor?: string;\r\n /** Domain of colors for the graph */\r\n colorDomain?: string[];\r\n /** Title for the color legend */\r\n colorLegendTitle?: string;\r\n /** Color of value labels */\r\n valueColor?: string;\r\n /** Background color of the graph */\r\n backgroundColor?: string | boolean;\r\n /** Custom styles for the graph. Each object should be a valid React CSS style object. */\r\n styles?: StyleObject;\r\n /** Custom class names */\r\n classNames?: ClassNameObject;\r\n\r\n // Size and Spacing\r\n /** Width of the graph */\r\n width?: number;\r\n /** Height of the graph */\r\n height?: number;\r\n /** Minimum height of the graph */\r\n minHeight?: number;\r\n /** Relative height scaling factor. This overwrites the height props */\r\n relativeHeight?: number;\r\n /** Padding around the graph. Defaults to 0 if no backgroundColor is mentioned else defaults to 1rem */\r\n padding?: string;\r\n /** Left margin of the graph */\r\n leftMargin?: number;\r\n /** Right margin of the graph */\r\n rightMargin?: number;\r\n /** Top margin of the graph */\r\n topMargin?: number;\r\n /** Bottom margin of the graph */\r\n bottomMargin?: number;\r\n\r\n // Values and Ticks\r\n /** Prefix for values */\r\n prefix?: string;\r\n /** Suffix for values */\r\n suffix?: string;\r\n /** Maximum value for the chart */\r\n maxValue?: number;\r\n /** Minimum value for the chart */\r\n minValue?: number;\r\n\r\n // Graph Parameters\r\n /** Number of ticks on the axis */\r\n noOfTicks?: number;\r\n /** Radius of the dots or width of the strips */\r\n radius?: number;\r\n /** Opacity of each dot or strip */\r\n dotOpacity?: number;\r\n /** Type of strip */\r\n stripType?: 'strip' | 'dot';\r\n /** Toggle visibility of color scale. This is only applicable if the data props hae color parameter */\r\n showColorScale?: boolean;\r\n /** Toggle visibility of NA color in the color scale. This is only applicable if the data props hae color parameter and showColorScale prop is true */\r\n showNAColor?: boolean;\r\n /** Data points to highlight. Use the label value from data to highlight the data point */\r\n highlightedDataPoints?: (string | number)[];\r\n /** Defines the opacity of the non-highlighted data */\r\n dimmedOpacity?: number;\r\n /** Toggles if the graph animates in when loaded. */\r\n animate?: boolean | AnimateDataType;\r\n /** Specifies the number of decimal places to display in the value. */\r\n precision?: number;\r\n /** Optional SVG <g> element or function that renders custom content behind or in front of the graph. */\r\n customLayers?: CustomLayerDataType[];\r\n /** Enable graph download option as png */\r\n graphDownload?: boolean;\r\n /** Enable data download option as a csv */\r\n dataDownload?: boolean;\r\n /** Reset selection on double-click. Only applicable when used in a dashboard context with filters. */\r\n resetSelectionOnDoubleClick?: boolean;\r\n\r\n // Interactions and Callbacks\r\n /** Tooltip content. If the type is string then this uses the [handlebar](../?path=/docs/misc-handlebars-templates-and-custom-helpers--docs) template to display the data */\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n tooltip?: string | ((_d: any) => React.ReactNode);\r\n /** Details displayed on the modal when user clicks of a data point. If the type is string then this uses the [handlebar](../?path=/docs/misc-handlebars-templates-and-custom-helpers--docs) template to display the data */\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n detailsOnClick?: string | ((_d: any) => React.ReactNode);\r\n /** Callback for mouse over event */\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n onSeriesMouseOver?: (_d: any) => void;\r\n /** Callback for mouse click event */\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n onSeriesMouseClick?: (_d: any) => void;\r\n\r\n // Configuration and Options\r\n /** Language setting */\r\n language?: Languages;\r\n /** Color theme */\r\n theme?: 'light' | 'dark';\r\n /** Unique ID for the graph */\r\n graphID?: string;\r\n}\r\n\r\nexport function StripChart(props: Props) {\r\n const {\r\n data,\r\n graphTitle,\r\n colors,\r\n sources,\r\n graphDescription,\r\n height,\r\n width,\r\n footNote,\r\n colorDomain,\r\n colorLegendTitle,\r\n radius = 5,\r\n padding,\r\n backgroundColor = false,\r\n leftMargin,\r\n rightMargin,\r\n topMargin,\r\n bottomMargin,\r\n tooltip,\r\n relativeHeight,\r\n onSeriesMouseOver,\r\n showColorScale = true,\r\n highlightedDataPoints = [],\r\n graphID,\r\n minValue,\r\n maxValue,\r\n onSeriesMouseClick,\r\n noOfTicks = 2,\r\n graphDownload = false,\r\n dataDownload = false,\r\n prefix = '',\r\n suffix = '',\r\n stripType = 'dot',\r\n language = 'en',\r\n highlightColor,\r\n dotOpacity = 0.3,\r\n showNAColor = true,\r\n minHeight = 0,\r\n theme = 'light',\r\n ariaLabel,\r\n valueColor,\r\n resetSelectionOnDoubleClick = true,\r\n detailsOnClick,\r\n orientation = 'vertical',\r\n styles,\r\n classNames,\r\n animate = false,\r\n dimmedOpacity = 0.3,\r\n precision = 2,\r\n customLayers = [],\r\n } = props;\r\n\r\n const Comp = orientation === 'horizontal' ? HorizontalGraph : VerticalGraph;\r\n\r\n const [svgWidth, setSvgWidth] = useState(0);\r\n const [svgHeight, setSvgHeight] = useState(0);\r\n const [selectedColor, setSelectedColor] = useState<string | undefined>(undefined);\r\n\r\n const graphDiv = useRef<HTMLDivElement>(null);\r\n const graphParentDiv = useRef<HTMLDivElement>(null);\r\n useEffect(() => {\r\n const resizeObserver = new ResizeObserver(entries => {\r\n setSvgWidth(entries[0].target.clientWidth || 620);\r\n setSvgHeight(entries[0].target.clientHeight || 480);\r\n });\r\n if (graphDiv.current) {\r\n resizeObserver.observe(graphDiv.current);\r\n }\r\n return () => resizeObserver.disconnect();\r\n }, []);\r\n return (\r\n <GraphContainer\r\n className={classNames?.graphContainer}\r\n style={styles?.graphContainer}\r\n id={graphID}\r\n ref={graphParentDiv}\r\n aria-label={ariaLabel}\r\n backgroundColor={backgroundColor}\r\n theme={theme}\r\n language={language}\r\n minHeight={minHeight}\r\n width={width}\r\n height={height}\r\n relativeHeight={relativeHeight}\r\n padding={padding}\r\n >\r\n {graphTitle || graphDescription || graphDownload || dataDownload ? (\r\n <GraphHeader\r\n styles={{\r\n title: styles?.title,\r\n description: styles?.description,\r\n }}\r\n classNames={{\r\n title: classNames?.title,\r\n description: classNames?.description,\r\n }}\r\n graphTitle={graphTitle}\r\n graphDescription={graphDescription}\r\n width={width}\r\n graphDownload={graphDownload ? graphParentDiv : undefined}\r\n dataDownload={\r\n dataDownload\r\n ? data.map(d => d.data).filter(d => d !== undefined).length > 0\r\n ? data.map(d => d.data).filter(d => d !== undefined)\r\n : data.filter(d => d !== undefined)\r\n : null\r\n }\r\n />\r\n ) : null}\r\n {showColorScale !== false && data.filter(el => el.color).length !== 0 && data.length > 0 ? (\r\n <ColorLegendWithMouseOver\r\n width={width}\r\n colorLegendTitle={colorLegendTitle}\r\n colors={(colors as string[] | undefined) || Colors[theme].categoricalColors.colors}\r\n colorDomain={colorDomain || (uniqBy(data, 'color', true) as string[])}\r\n setSelectedColor={setSelectedColor}\r\n showNAColor={showNAColor}\r\n className={classNames?.colorLegend}\r\n />\r\n ) : null}\r\n <GraphArea ref={graphDiv}>\r\n {data.length === 0 && <EmptyState />}\r\n {svgWidth && svgHeight && data.length > 0 ? (\r\n <Comp\r\n data={data}\r\n width={svgWidth}\r\n height={svgHeight}\r\n colorDomain={\r\n data.filter(el => el.color).length === 0\r\n ? []\r\n : colorDomain || (uniqBy(data, 'color', true) as string[])\r\n }\r\n colors={\r\n data.filter(el => el.color).length === 0\r\n ? colors\r\n ? [colors as string]\r\n : [Colors.primaryColors['blue-600']]\r\n : (colors as string[] | undefined) || Colors[theme].categoricalColors.colors\r\n }\r\n selectedColor={selectedColor}\r\n radius={radius}\r\n leftMargin={leftMargin}\r\n rightMargin={rightMargin}\r\n topMargin={topMargin}\r\n bottomMargin={bottomMargin}\r\n tooltip={tooltip}\r\n onSeriesMouseOver={onSeriesMouseOver}\r\n highlightedDataPoints={highlightedDataPoints}\r\n minValue={minValue}\r\n maxValue={maxValue}\r\n onSeriesMouseClick={onSeriesMouseClick}\r\n prefix={prefix}\r\n suffix={suffix}\r\n stripType={stripType}\r\n highlightColor={highlightColor}\r\n dotOpacity={dotOpacity}\r\n resetSelectionOnDoubleClick={resetSelectionOnDoubleClick}\r\n detailsOnClick={detailsOnClick}\r\n styles={styles}\r\n classNames={classNames}\r\n valueColor={valueColor}\r\n animate={\r\n animate === true\r\n ? { duration: 0.5, once: true, amount: 0.5 }\r\n : animate || { duration: 0, once: true, amount: 0 }\r\n }\r\n noOfTicks={noOfTicks}\r\n dimmedOpacity={dimmedOpacity}\r\n precision={precision}\r\n customLayers={customLayers}\r\n />\r\n ) : null}\r\n </GraphArea>\r\n {sources || footNote ? (\r\n <GraphFooter\r\n styles={{ footnote: styles?.footnote, source: styles?.source }}\r\n classNames={{\r\n footnote: classNames?.footnote,\r\n source: classNames?.source,\r\n }}\r\n sources={sources}\r\n footNote={footNote}\r\n width={width}\r\n />\r\n ) : null}\r\n </GraphContainer>\r\n );\r\n}\r\n"],"names":["getTickPositions","count","width","step","Array","from","length","_","i","VerticalGraph","props","$","_c","data","height","colors","colorDomain","radius","leftMargin","t0","rightMargin","t1","topMargin","t2","bottomMargin","t3","tooltip","onSeriesMouseOver","highlightedDataPoints","selectedColor","minValue","maxValue","onSeriesMouseClick","noOfTicks","prefix","suffix","stripType","highlightColor","dotOpacity","resetSelectionOnDoubleClick","detailsOnClick","styles","classNames","valueColor","animate","dimmedOpacity","precision","customLayers","undefined","svgRef","useRef","t4","amount","once","isInView","useInView","mouseOverData","setMouseOverData","useState","mouseClickData","setMouseClickData","eventX","setEventX","eventY","setEventY","t5","top","bottom","left","right","margin","graphWidth","graphHeight","T0","T1","t10","t11","t12","t13","t14","t6","t7","t8","t9","duration","graphObjectValues","yAxis","labels","dataWithId","map","_temp","t15","item","index","indexOf","label","Infinity","sortedData","orderBy","t16","checkIfNullOrUndefined","Math","max","filter","_temp2","_temp3","_temp4","_temp5","yMaxValue","t17","min","_temp6","_temp7","_temp8","_temp9","yMinValue","y","scaleLinear","domain","range","nice","ticks","motion","svg","_temp0","_temp1","AnimatePresence","d_10","jsxs","initial","opacity","x","whileInView","d","position","color","transition","event","clientY","clientX","isEqual","event_0","fill","_temp10","Colors","gray","_temp11","_temp12","_temp13","jsx","_temp14","_temp15","_temp16","_temp17","_temp18","_temp19","_temp20","_temp21","textAnchor","cn","numberFormattingFunction","tick","i_0","invert","_temp22","_temp23","t18","t19","Tooltip","t20","modal","DetailsModal","t21","Fragment","d_12","layer","d_11","el_10","el","el_9","el_8","el_7","el_6","el_5","el_4","el_3","el_2","el_1","el_0","d_9","d_8","d_5","d_4","d_7","d_6","d_1","d_0","d_3","d_2","id","HorizontalGraph","xAxis","_temp24","_temp25","_temp26","_temp27","_temp28","xMaxValue","_temp29","_temp30","_temp31","_temp32","xMinValue","_temp33","_temp34","_temp35","_temp36","_temp37","_temp38","_temp39","_temp40","_temp41","_temp42","_temp43","_temp44","_temp45","_temp46","_temp47","_temp48","StripChart","graphTitle","sources","graphDescription","footNote","colorLegendTitle","padding","backgroundColor","relativeHeight","showColorScale","graphID","graphDownload","dataDownload","language","showNAColor","minHeight","theme","ariaLabel","orientation","t22","Comp","svgWidth","setSvgWidth","svgHeight","setSvgHeight","setSelectedColor","graphDiv","graphParentDiv","t23","t24","Symbol","for","resizeObserver","ResizeObserver","entries","target","clientWidth","clientHeight","current","observe","disconnect","useEffect","t25","graphContainer","t26","t27","description","title","GraphHeader","t28","colorLegend","ColorLegendWithMouseOver","categoricalColors","uniqBy","t29","EmptyState","t30","primaryColors","t31","GraphArea","t32","footnote","source","GraphFooter","t33","GraphContainer"],"mappings":";;;;;;;;;;;;;;;;;;;AAAO,SAASA,GAAiBC,GAAeC,GAAe;AAC7D,MAAID,IAAQ,EAAG,QAAO,CAAA;AACtB,QAAME,IAAOD,KAASD,IAAQ;AAC9B,SAAOG,MAAMC,KAAK;AAAA,IAAEC,QAAQL;AAAAA,EAAAA,GAAS,CAACM,GAAGC,MAAMA,IAAIL,CAAI;AACzD;ACwDO,SAAAM,GAAAC,GAAA;AAAA,QAAAC,IAAAC,GAAAA,EAAA,EAAA,GACL;AAAA,IAAAC,MAAAA;AAAAA,IAAAX,OAAAA;AAAAA,IAAAY,QAAAA;AAAAA,IAAAC,QAAAA;AAAAA,IAAAC,aAAAA;AAAAA,IAAAC,QAAAA;AAAAA,IAAAC,YAAAC;AAAAA,IAAAC,aAAAC;AAAAA,IAAAC,WAAAC;AAAAA,IAAAC,cAAAC;AAAAA,IAAAC,SAAAA;AAAAA,IAAAC,mBAAAA;AAAAA,IAAAC,uBAAAA;AAAAA,IAAAC,eAAAA;AAAAA,IAAAC,UAAAA;AAAAA,IAAAC,UAAAA;AAAAA,IAAAC,oBAAAA;AAAAA,IAAAC,WAAAA;AAAAA,IAAAC,QAAAA;AAAAA,IAAAC,QAAAA;AAAAA,IAAAC,WAAAA;AAAAA,IAAAC,gBAAAA;AAAAA,IAAAC,YAAAA;AAAAA,IAAAC,6BAAAA;AAAAA,IAAAC,gBAAAA;AAAAA,IAAAC,QAAAA;AAAAA,IAAAC,YAAAA;AAAAA,IAAAC,YAAAA;AAAAA,IAAAC,SAAAA;AAAAA,IAAAC,eAAAA;AAAAA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D,MAAMrF;AAAS;AAxG5D,SAAAyD,GAAA4B,GAAA;AAAA,SAwGyBA,EAACxH;AAAK;AAxG/B,SAAA2F,GAAA6F,GAAA;AAAA,SAuG2ChE,MAAMrF;AAAS;AAvG1D,SAAA0C,GAAA4G,GAAA;AAAA,SAuGuBjE,EAACxH;AAAK;"}
|
package/dist/ThreeDGlobe.cjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("./index-CHPV5EwG-CTPQjnHt.cjs"),h=require("react"),nt=require("./Spinner-CQZcjzwd.cjs"),lt=require("react-globe.gl"),ct=require("./index-DQA8q5sC.cjs"),dt=require("three"),Ke=require("./Typography-DX7PlgQU.cjs"),ut=require("./_commonjsHelpers-BH3jXuIh.cjs"),pt=require("./Tooltip-uUdw6wJL.cjs"),ht=require("./numberFormattingFunction-02t-wJta.cjs"),mt=require("./index-DRXx7m-C.cjs"),gt=require("./getCentroidCoordinates-Dng1HVjO.cjs"),xt=require("./DetailsModal-BN0HDFlV.cjs"),ft=require("./ordinal-CrsysVE-.cjs"),vt=require("./threshold-DNsSUf8Q.cjs"),yt=require("./GraphHeader.cjs"),bt=require("./GraphFooter.cjs"),wt=require("./fetchAndParseData-l5HGMAEs.cjs"),te=require("./Colors.cjs"),jt=require("./getUniqValue-NX8DgwND.cjs"),Ct=require("./getJenks-GYmdwBqm.cjs"),Qe=require("./GraphContainer-d8A46BK2.cjs");function Rt(t){const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const n in t)if(n!=="default"){const x=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(e,n,x.get?x:{enumerable:!0,get:()=>t[n]})}}return e.default=t,Object.freeze(e)}const U=Rt(dt);var Ye,et;function St(){if(et)return Ye;et=1;var t=function(o){return o.charAt(0)==="#"?o.slice(1):o},e=function(o){var l=o.length===3||o.length===4,v=l?"".concat(o.slice(0,1)).concat(o.slice(0,1)):o.slice(0,2),a=l?"".concat(o.slice(1,2)).concat(o.slice(1,2)):o.slice(2,4),j=l?"".concat(o.slice(2,3)).concat(o.slice(2,3)):o.slice(4,6),q=(l?"".concat(o.slice(3,4)).concat(o.slice(3,4)):o.slice(6,8))||"ff";return{r:v,g:a,b:j,a:q}},n=function(o){return parseInt(o,16)},x=function(o){var l=o.r,v=o.g,a=o.b,j=o.a;return{r:n(l),g:n(v),b:n(a),a:+(n(j)/255).toFixed(2)}},w=function(o){return!isNaN(parseFloat(o))&&isFinite(o)},R=function(o,l){var v=o.r,a=o.g,j=o.b,q=o.a,P=w(l)?l:q;return"rgba(".concat(v,", ").concat(a,", ").concat(j,", ").concat(P,")")},f=function(o,l){var v=t(o),a=e(v),j=x(a);return R(j,l)};return Ye=f,Ye}var Et=St();const tt=ut.getDefaultExportFromCjs(Et);function Dt(t){let e;switch(t.type){case"ambient":e=new U.AmbientLight(t.color,t.intensity);break;case"directional":e=new U.DirectionalLight(t.color,t.intensity),t.position&&(t.position==="camera"?e.position.set(0,0,0):e.position.set(t.position.x,t.position.y,t.position.z)),(t.target||t.position==="camera")&&e.target.position.set(t.target?.x||0,t.target?.y||0,t.target?.z===void 0?-1:t.target.z),t.castShadow&&(e.castShadow=!0,t.shadow&&(e.shadow.mapSize.width=t.shadow.mapSize.width,e.shadow.mapSize.height=t.shadow.mapSize.height,e.shadow.camera.near=t.shadow.camera.near,e.shadow.camera.far=t.shadow.camera.far));break;case"point":e=new U.PointLight(t.color,t.intensity,t.distance||0,t.decay||2),t.position&&(t.position==="camera"?e.position.set(0,0,0):e.position.set(t.position.x,t.position.y,t.position.z));break;case"spot":e=new U.SpotLight(t.color,t.intensity,t.distance||0,t.angle||Math.PI/3,t.penumbra||0,t.decay||2),t.position&&(t.position==="camera"?e.position.set(0,0,0):e.position.set(t.position.x,t.position.y,t.position.z)),(t.target||t.position==="camera")&&e.target.position.set(t.target?.x||0,t.target?.y||0,t.target?.z||0),t.castShadow&&(e.castShadow=!0,t.shadow&&(e.shadow.mapSize.width=t.shadow.mapSize.width,e.shadow.mapSize.height=t.shadow.mapSize.height,e.shadow.camera.near=t.shadow.camera.near,e.shadow.camera.far=t.shadow.camera.far));break;default:throw new Error("Unknown light type")}return e}function Nt(t){const{width:e,autoRotate:n,data:x,enableZoom:w,categorical:R,colorDomain:f,colors:c,globeMaterial:o,height:l,polygonData:v,mapProperty:a,mapBorderColor:j,atmosphereColor:q,tooltip:P,styles:fe,classNames:_,mapNoDataColor:oe,colorLegendTitle:C,showColorScale:re,hoverStrokeColor:se,detailsOnClick:$,onSeriesMouseClick:V,onSeriesMouseOver:ve,resetSelectionOnDoubleClick:ye,highlightedIds:T,scale:M,globeOffset:m,polygonAltitude:g,centerLng:W,centerLat:Z,atmosphereAltitude:ie,globeCurvatureResolution:J,fogSettings:L,lights:z,highlightedAltitude:ae,selectedId:y,collapseColorScaleByDefault:X,dimmedOpacity:A}=t,[B,be]=h.useState(!1),u=h.useRef(void 0),[H,N]=h.useState(void 0),[we,ne]=h.useState(X===void 0?!(e<680):!X),[le,ce]=h.useState({x:0,y:0}),[S,de]=h.useState(void 0),Y=R?ft.ordinal().domain(f).range(c):vt.threshold().domain(f).range(c);h.useEffect(()=>{u.current&&(u.current.controls().enableZoom=w)},[w]),h.useEffect(()=>{u.current&&(S||y?u.current.controls().autoRotate=!1:(u.current.controls().autoRotate=n!==0,u.current.controls().autoRotateSpeed=n))},[S,y,n]),h.useEffect(()=>{if(u.current&&y){const r=v.find(b=>b.properties[a]===y),[s,d]=gt.getCentroidCoordinates(r);u.current.pointOfView({lat:d,lng:s,altitude:M},1e3)}},[y,M,v,a]),h.useEffect(()=>{const r=u.current?.renderer().domElement;if(!r)return;const s=d=>{ce({x:d.clientX,y:d.clientY})};return r.addEventListener("mousemove",s),()=>r.removeEventListener("mousemove",s)},[]),h.useEffect(()=>{u.current&&u.current.pointOfView({lat:Z,lng:W,altitude:M},1e3)},[M,W,Z]);const E=o||new U.MeshBasicMaterial({color:"#FFF"}),G=h.useCallback(()=>{if(!u.current)return;const r=u.current.scene(),s=u.current.camera();let d=[];r.traverse(p=>{p instanceof U.Light&&d.push(p)}),d=[...d,...s.children],d.forEach(p=>p.parent?.remove(p)),z.map(p=>Dt(p)).forEach((p,D)=>{z[D].type!=="ambient"&&z[D].position==="camera"?(s.add(p),z[D].type!=="point"&&s.add(p.target)):r.add(p)}),L&&(r.fog=new U.Fog(L.color,L.near,L.far))},[z,L]),k=()=>{be(!0),G()};return h.useEffect(()=>{B&&G()},[B,G]),i.jsxRuntimeExports.jsxs("div",{className:"relative",children:[i.jsxRuntimeExports.jsx(lt,{ref:u,height:l,width:e,globeOffset:m,lineHoverPrecision:0,polygonsData:v,polygonAltitude:r=>T.includes(r?.properties?.[a])||r?.properties?.[a]===y||r?.properties?.[a]===S?.id||r?.properties?.[a]===H?.id?ae:g,polygonCapColor:r=>{const s=y?r?.properties?.[a]===y?1:A:T.length!==0?T.includes(r?.properties?.[a])?1:A:1,d=r?.properties?.[a],b=x.find(D=>D.id===d)?.x,p=b!=null?Y(b):oe;return tt(p,`${s}`)},polygonSideColor:r=>{const s=r?.properties?.[a],d=x.find(D=>D.id===s)?.x,b=y?r?.properties?.[a]===y?1:A:T.length!==0?T.includes(r?.properties?.[a])?1:A:1,p=d!=null?Y(d):oe;return tt(p,`${b}`)},polygonStrokeColor:r=>r?.properties?.[a]===S?.id?se:j,onGlobeClick:()=>{N(void 0)},onPolygonClick:r=>{const s=r?.properties?.[a]?x.find(d=>d.id===r?.properties?.[a]):void 0;(V||$)&&(ct.isEqual(H,s)&&ye&&s?(N(void 0),V?.(void 0)):(N(s),V?.(s)))},onPolygonHover:r=>{const s=r?.properties?.[a]?x.find(d=>d.id===r?.properties?.[a]):void 0;de(s),ve?.(s)},atmosphereColor:q,atmosphereAltitude:ie,globeCurvatureResolution:J,globeMaterial:E,backgroundColor:"rgba(0, 0, 0, 0)",polygonsTransitionDuration:100,onGlobeReady:()=>{if(u.current){u.current.pointOfView({lat:Z,lng:W});const r=u.current.scene();setTimeout(()=>{(r.children[3]?.children[0]?.children[4]?.children||[]).forEach(b=>{const p=b.children[1];p.renderOrder=2})},300);const s=u.current.camera();r.add(s),k()}}}),re===!1?null:i.jsxRuntimeExports.jsx("div",{className:i.mo("absolute left-4 bottom-4 map-color-legend",_?.colorLegend),children:we?i.jsxRuntimeExports.jsxs(i.jsxRuntimeExports.Fragment,{children:[i.jsxRuntimeExports.jsx("div",{className:"color-legend-close-button bg-[rgba(240,240,240,0.7)] dark:bg-[rgba(30,30,30,0.7)] border border-[var(--gray-400)] rounded-full w-6 h-6 p-[3px] cursor-pointer z-10 absolute right-[-0.75rem] top-[-0.75rem]",onClick:()=>{ne(!1)},children:i.jsxRuntimeExports.jsx(mt.X,{})}),i.jsxRuntimeExports.jsxs("div",{className:"color-legend-box p-2 bg-[rgba(240,240,240,0.7)] dark:bg-[rgba(30,30,30,0.7)]",style:{width:R?void 0:"340px"},children:[C&&C!==""?i.jsxRuntimeExports.jsx(Ke.j,{size:"xs",marginBottom:"xs",className:"p-0 leading-normal overflow-hidden text-primary-gray-700 dark:text-primary-gray-300",style:{display:"-webkit-box",WebkitLineClamp:"1",WebkitBoxOrient:"vertical"},children:C}):null,R?i.jsxRuntimeExports.jsx("div",{className:"flex flex-col gap-3",children:f.map((r,s)=>i.jsxRuntimeExports.jsxs("div",{className:"flex gap-2 items-center",children:[i.jsxRuntimeExports.jsx("div",{className:"w-2 h-2 rounded-full",style:{backgroundColor:c[s%c.length]}}),i.jsxRuntimeExports.jsx(Ke.j,{size:"sm",marginBottom:"none",leading:"none",children:r})]},s))}):i.jsxRuntimeExports.jsx("svg",{width:"100%",viewBox:"0 0 320 30",direction:"ltr",children:i.jsxRuntimeExports.jsxs("g",{children:[f.map((r,s)=>i.jsxRuntimeExports.jsxs("g",{className:"cursor-pointer",children:[i.jsxRuntimeExports.jsx("rect",{x:s*320/c.length+1,y:1,width:320/c.length-2,height:8,style:{fill:c[s],stroke:c[s]}}),i.jsxRuntimeExports.jsx("text",{x:(s+1)*320/c.length,y:25,className:"fill-primary-gray-700 dark:fill-primary-gray-300 text-xs",style:{textAnchor:"middle"},children:ht.numberFormattingFunction(r,"NA")})]},s)),i.jsxRuntimeExports.jsx("g",{children:i.jsxRuntimeExports.jsx("rect",{x:f.length*320/c.length+1,y:1,width:320/c.length-2,height:8,style:{fill:c[f.length],stroke:c[f.length]}})})]})})]})]}):i.jsxRuntimeExports.jsx("button",{type:"button",className:"mb-0 border-0 bg-transparent p-0 self-start",onClick:()=>{ne(!0)},children:i.jsxRuntimeExports.jsx("div",{className:"show-color-legend-button items-start text-sm font-medium cursor-pointer p-2 mb-0 flex text-primary-black dark:text-primary-gray-300 bg-primary-gray-300 dark:bg-primary-gray-600 border-primary-gray-400 dark:border-primary-gray-500",children:"Show Legend"})})}),S&&P?i.jsxRuntimeExports.jsx(pt.Tooltip,{data:S,body:P,xPos:le.x,yPos:le.y,backgroundStyle:fe?.tooltip,className:_?.tooltip}):null,$&&H!==void 0?i.jsxRuntimeExports.jsx(xt.DetailsModal,{body:$,data:H,setData:N,className:_?.modal}):null]})}function kt(t){const e=i.compilerRuntimeExports.c(97),{data:n,mapData:x,graphTitle:w,colors:R,sources:f,graphDescription:c,height:o,width:l,footNote:v,colorDomain:a,colorLegendTitle:j,scaleType:q,padding:P,mapNoDataColor:fe,backgroundColor:_,mapBorderColor:oe,relativeHeight:C,tooltip:re,graphID:se,mapProperty:$,dataDownload:V,language:ve,minHeight:ye,theme:T,ariaLabel:M,styles:m,classNames:g,autoRotate:W,enableZoom:Z,globeMaterial:ie,centerPoint:J,atmosphereColor:L,showColorScale:z,resetSelectionOnDoubleClick:ae,detailsOnClick:y,onSeriesMouseOver:X,onSeriesMouseClick:A,highlightedIds:B,highlightedAltitude:be,dimmedOpacity:u,scale:H,globeOffset:N,polygonAltitude:we,globeCurvatureResolution:ne,atmosphereAltitude:le,fogSettings:ce,lights:S,selectedId:de,collapseColorScaleByDefault:Y}=t,E=x===void 0?"https://raw.githubusercontent.com/UNDP-Data/dv-country-geojson/refs/heads/main/worldMap-simplified.json":x,G=v===void 0?"The designations employed and the presentation of material on this map do not imply the expression of any opinion whatsoever on the part of the Secretariat of the United Nations or UNDP concerning the legal status of any country, territory, city or area or its authorities, or concerning the delimitation of its frontiers or boundaries.":v,k=q===void 0?"threshold":q,r=fe===void 0?te.Colors.light.graphNoData:fe,s=_===void 0?!1:_,d=oe===void 0?te.Colors.light.grays["gray-500"]:oe,b=$===void 0?"ISO3":$,p=V===void 0?!1:V,D=ve===void 0?"en":ve,O=ye===void 0?0:ye,F=T===void 0?"light":T,ue=W===void 0?!0:W,Le=Z===void 0?!0:Z;let je;e[0]!==J?(je=J===void 0?[0,0]:J,e[0]=J,e[1]=je):je=e[1];const Ce=je,ze=L===void 0?"#999":L,Ae=z===void 0?!0:z,Ge=ae===void 0?!0:ae;let Re;e[2]!==B?(Re=B===void 0?[]:B,e[2]=B,e[3]=Re):Re=e[3];const Fe=Re,Be=be===void 0?.1:be,He=u===void 0?.3:u,Ie=H===void 0?1:H;let Se;e[4]!==N?(Se=N===void 0?[0,0]:N,e[4]=N,e[5]=Se):Se=e[5];const Ue=Se,_e=we===void 0?.01:we,$e=ne===void 0?4:ne,Ve=le===void 0?.15:le;let Ee;e[6]!==S?(Ee=S===void 0?[{type:"ambient",color:4210752,intensity:.4},{type:"directional",color:16777215,intensity:1,position:{x:5,y:10,z:5}}]:S,e[6]=S,e[7]=Ee):Ee=e[7];const We=Ee,[De,ot]=h.useState(void 0),[I,rt]=h.useState(0),[pe,st]=h.useState(0),Ze=h.useRef(null),it=h.useRef(null);let Ne,ke;e[8]===Symbol.for("react.memo_cache_sentinel")?(Ne=()=>{const ge=new ResizeObserver(xe=>{rt(xe[0].target.clientWidth||620),st(xe[0].target.clientHeight||480)});return Ze.current&&ge.observe(Ze.current),()=>ge.disconnect()},ke=[],e[8]=Ne,e[9]=ke):(Ne=e[8],ke=e[9]),h.useEffect(Ne,ke);let Oe;e[10]===Symbol.for("react.memo_cache_sentinel")?(Oe=ge=>{ot(ge)},e[10]=Oe):Oe=e[10];const he=h.useEffectEvent(Oe);let qe;e[11]!==E||e[12]!==he?(qe=()=>{typeof E=="string"?wt.fetchAndParseJSON(E).then(xe=>{if(E==="https://raw.githubusercontent.com/UNDP-Data/dv-country-geojson/refs/heads/main/worldMap-simplified.json"){const at=xe.features.map(zt);he(at)}else he(xe.features)}):he(E.features)},e[11]=E,e[12]=he,e[13]=qe):qe=e[13];let Pe;e[14]!==E?(Pe=[E],e[14]=E,e[15]=Pe):Pe=e[15],h.useEffect(qe,Pe);let Te;e[16]!==a||e[17]!==R?.length||e[18]!==n||e[19]!==k?(Te=a||(k==="categorical"?jt.getUniqValue(n,"x"):Ct.getJenks(n.map(Lt),R?.length||4)),e[16]=a,e[17]=R?.length,e[18]=n,e[19]=k,e[20]=Te):Te=e[20];const me=Te,Je=g?.graphContainer,Xe=m?.graphContainer;let K;e[21]!==g?.description||e[22]!==g?.title||e[23]!==n||e[24]!==p||e[25]!==c||e[26]!==w||e[27]!==m?.description||e[28]!==m?.title||e[29]!==l?(K=w||c||p?i.jsxRuntimeExports.jsx(yt.GraphHeader,{styles:{title:m?.title,description:m?.description},classNames:{title:g?.title,description:g?.description},graphTitle:w,graphDescription:c,width:l,graphDownload:void 0,dataDownload:p?n.map(Mt).filter(Tt).length>0?n.map(Pt).filter(qt):n.filter(Ot):null}):null,e[21]=g?.description,e[22]=g?.title,e[23]=n,e[24]=p,e[25]=c,e[26]=w,e[27]=m?.description,e[28]=m?.title,e[29]=l,e[30]=K):K=e[30];let Q;e[31]!==Ve||e[32]!==ze||e[33]!==ue||e[34]!==Ce||e[35]!==g||e[36]!==Y||e[37]!==j||e[38]!==R||e[39]!==n||e[40]!==y||e[41]!==He||e[42]!==me||e[43]!==Le||e[44]!==ce||e[45]!==$e||e[46]!==ie||e[47]!==Ue||e[48]!==o||e[49]!==Be||e[50]!==Fe||e[51]!==We||e[52]!==d||e[53]!==r||e[54]!==b||e[55]!==De||e[56]!==O||e[57]!==A||e[58]!==X||e[59]!==_e||e[60]!==C||e[61]!==Ge||e[62]!==Ie||e[63]!==k||e[64]!==de||e[65]!==Ae||e[66]!==m||e[67]!==pe||e[68]!==I||e[69]!==F||e[70]!==re||e[71]!==l?(Q=i.jsxRuntimeExports.jsx(Qe.GraphArea,{ref:Ze,children:I&&pe&&De?i.jsxRuntimeExports.jsx(Nt,{data:n,globeOffset:Ue,polygonData:De,colorDomain:me,width:I,height:pe,colors:R||(k==="categorical"?te.Colors[F].sequentialColors[`neutralColorsx0${me.length}`]:te.Colors[F].sequentialColors[`neutralColorsx0${me.length+1}`]),mapNoDataColor:r,categorical:k==="categorical",mapBorderColor:d,tooltip:re,mapProperty:b,styles:m,classNames:g,autoRotate:ue===!0?1.5:ue===!1?0:ue,enableZoom:Le,globeMaterial:ie,atmosphereColor:ze,colorLegendTitle:j,showColorScale:Ae,hoverStrokeColor:F==="light"?te.Colors.light.grays["gray-700"]:te.Colors.light.grays["gray-300"],highlightedIds:Fe,resetSelectionOnDoubleClick:Ge,detailsOnClick:y,onSeriesMouseOver:X,onSeriesMouseClick:A,scale:Ie,polygonAltitude:_e,centerLat:Ce[0],centerLng:Ce[1],atmosphereAltitude:Ve,globeCurvatureResolution:$e,fogSettings:ce,lights:We,highlightedAltitude:Be,selectedId:de,collapseColorScaleByDefault:Y,dimmedOpacity:He}):i.jsxRuntimeExports.jsx("div",{style:{height:`${Math.max(O,o||(C?O?(l||I)*C>O?(l||I)*C:O:(l||I)*C:pe))}px`},className:"flex items-center justify-center",children:i.jsxRuntimeExports.jsx(nt.w,{"aria-label":"Loading graph"})})}),e[31]=Ve,e[32]=ze,e[33]=ue,e[34]=Ce,e[35]=g,e[36]=Y,e[37]=j,e[38]=R,e[39]=n,e[40]=y,e[41]=He,e[42]=me,e[43]=Le,e[44]=ce,e[45]=$e,e[46]=ie,e[47]=Ue,e[48]=o,e[49]=Be,e[50]=Fe,e[51]=We,e[52]=d,e[53]=r,e[54]=b,e[55]=De,e[56]=O,e[57]=A,e[58]=X,e[59]=_e,e[60]=C,e[61]=Ge,e[62]=Ie,e[63]=k,e[64]=de,e[65]=Ae,e[66]=m,e[67]=pe,e[68]=I,e[69]=F,e[70]=re,e[71]=l,e[72]=Q):Q=e[72];let ee;e[73]!==g?.footnote||e[74]!==g?.source||e[75]!==G||e[76]!==f||e[77]!==m?.footnote||e[78]!==m?.source||e[79]!==l?(ee=f||G?i.jsxRuntimeExports.jsx(bt.GraphFooter,{styles:{footnote:m?.footnote,source:m?.source},classNames:{footnote:g?.footnote,source:g?.source},sources:f,footNote:G,width:l}):null,e[73]=g?.footnote,e[74]=g?.source,e[75]=G,e[76]=f,e[77]=m?.footnote,e[78]=m?.source,e[79]=l,e[80]=ee):ee=e[80];let Me;return e[81]!==M||e[82]!==s||e[83]!==se||e[84]!==o||e[85]!==D||e[86]!==O||e[87]!==P||e[88]!==C||e[89]!==Je||e[90]!==Xe||e[91]!==K||e[92]!==Q||e[93]!==ee||e[94]!==F||e[95]!==l?(Me=i.jsxRuntimeExports.jsxs(Qe.GraphContainer,{className:Je,style:Xe,id:se,ref:it,"aria-label":M,backgroundColor:s,theme:F,language:D,minHeight:O,width:l,height:o,relativeHeight:C,padding:P,children:[K,Q,ee]}),e[81]=M,e[82]=s,e[83]=se,e[84]=o,e[85]=D,e[86]=O,e[87]=P,e[88]=C,e[89]=Je,e[90]=Xe,e[91]=K,e[92]=Q,e[93]=ee,e[94]=F,e[95]=l,e[96]=Me):Me=e[96],Me}function Ot(t){return t!==void 0}function qt(t){return t!==void 0}function Pt(t){return t.data}function Tt(t){return t!==void 0}function Mt(t){return t.data}function Lt(t){return t.x}function zt(t){if(t.geometry.type==="Polygon"){const x=[...t.geometry.coordinates[0]].reverse(),w={...t.geometry,coordinates:[x]};return{...t,geometry:w}}const e=[];t.geometry.coordinates.forEach(x=>{const w=[...x[0]].reverse();e.push([w])});const n={...t.geometry,coordinates:e};return{...t,geometry:n}}exports.ThreeDGlobe=kt;
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("./index-CHPV5EwG-6v2a2njQ.cjs"),h=require("react"),nt=require("./Spinner-jTMOLuw_.cjs"),lt=require("react-globe.gl"),ct=require("./index-DQA8q5sC.cjs"),dt=require("three"),Ke=require("./Typography-sa1UE0oF.cjs"),ut=require("./_commonjsHelpers-BH3jXuIh.cjs"),pt=require("./Tooltip-BLa2EfMs.cjs"),ht=require("./numberFormattingFunction-02t-wJta.cjs"),mt=require("./index-C6er0ety.cjs"),gt=require("./getCentroidCoordinates-CtBGrNC8.cjs"),xt=require("./DetailsModal-DHttOA80.cjs"),ft=require("./ordinal-CrsysVE-.cjs"),vt=require("./threshold-DNsSUf8Q.cjs"),yt=require("./GraphHeader.cjs"),bt=require("./GraphFooter.cjs"),wt=require("./fetchAndParseData-QTF6tjij.cjs"),te=require("./Colors.cjs"),jt=require("./getUniqValue-NX8DgwND.cjs"),Ct=require("./getJenks-BzJvhy_H.cjs"),Qe=require("./GraphContainer-B1EDxJ0S.cjs");function Rt(t){const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const n in t)if(n!=="default"){const x=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(e,n,x.get?x:{enumerable:!0,get:()=>t[n]})}}return e.default=t,Object.freeze(e)}const U=Rt(dt);var Ye,et;function St(){if(et)return Ye;et=1;var t=function(o){return o.charAt(0)==="#"?o.slice(1):o},e=function(o){var l=o.length===3||o.length===4,v=l?"".concat(o.slice(0,1)).concat(o.slice(0,1)):o.slice(0,2),a=l?"".concat(o.slice(1,2)).concat(o.slice(1,2)):o.slice(2,4),j=l?"".concat(o.slice(2,3)).concat(o.slice(2,3)):o.slice(4,6),q=(l?"".concat(o.slice(3,4)).concat(o.slice(3,4)):o.slice(6,8))||"ff";return{r:v,g:a,b:j,a:q}},n=function(o){return parseInt(o,16)},x=function(o){var l=o.r,v=o.g,a=o.b,j=o.a;return{r:n(l),g:n(v),b:n(a),a:+(n(j)/255).toFixed(2)}},w=function(o){return!isNaN(parseFloat(o))&&isFinite(o)},R=function(o,l){var v=o.r,a=o.g,j=o.b,q=o.a,P=w(l)?l:q;return"rgba(".concat(v,", ").concat(a,", ").concat(j,", ").concat(P,")")},f=function(o,l){var v=t(o),a=e(v),j=x(a);return R(j,l)};return Ye=f,Ye}var Et=St();const tt=ut.getDefaultExportFromCjs(Et);function Dt(t){let e;switch(t.type){case"ambient":e=new U.AmbientLight(t.color,t.intensity);break;case"directional":e=new U.DirectionalLight(t.color,t.intensity),t.position&&(t.position==="camera"?e.position.set(0,0,0):e.position.set(t.position.x,t.position.y,t.position.z)),(t.target||t.position==="camera")&&e.target.position.set(t.target?.x||0,t.target?.y||0,t.target?.z===void 0?-1:t.target.z),t.castShadow&&(e.castShadow=!0,t.shadow&&(e.shadow.mapSize.width=t.shadow.mapSize.width,e.shadow.mapSize.height=t.shadow.mapSize.height,e.shadow.camera.near=t.shadow.camera.near,e.shadow.camera.far=t.shadow.camera.far));break;case"point":e=new U.PointLight(t.color,t.intensity,t.distance||0,t.decay||2),t.position&&(t.position==="camera"?e.position.set(0,0,0):e.position.set(t.position.x,t.position.y,t.position.z));break;case"spot":e=new U.SpotLight(t.color,t.intensity,t.distance||0,t.angle||Math.PI/3,t.penumbra||0,t.decay||2),t.position&&(t.position==="camera"?e.position.set(0,0,0):e.position.set(t.position.x,t.position.y,t.position.z)),(t.target||t.position==="camera")&&e.target.position.set(t.target?.x||0,t.target?.y||0,t.target?.z||0),t.castShadow&&(e.castShadow=!0,t.shadow&&(e.shadow.mapSize.width=t.shadow.mapSize.width,e.shadow.mapSize.height=t.shadow.mapSize.height,e.shadow.camera.near=t.shadow.camera.near,e.shadow.camera.far=t.shadow.camera.far));break;default:throw new Error("Unknown light type")}return e}function Nt(t){const{width:e,autoRotate:n,data:x,enableZoom:w,categorical:R,colorDomain:f,colors:c,globeMaterial:o,height:l,polygonData:v,mapProperty:a,mapBorderColor:j,atmosphereColor:q,tooltip:P,styles:fe,classNames:_,mapNoDataColor:oe,colorLegendTitle:C,showColorScale:re,hoverStrokeColor:se,detailsOnClick:$,onSeriesMouseClick:V,onSeriesMouseOver:ve,resetSelectionOnDoubleClick:ye,highlightedIds:T,scale:M,globeOffset:m,polygonAltitude:g,centerLng:W,centerLat:Z,atmosphereAltitude:ie,globeCurvatureResolution:J,fogSettings:L,lights:z,highlightedAltitude:ae,selectedId:y,collapseColorScaleByDefault:X,dimmedOpacity:A}=t,[B,be]=h.useState(!1),u=h.useRef(void 0),[H,N]=h.useState(void 0),[we,ne]=h.useState(X===void 0?!(e<680):!X),[le,ce]=h.useState({x:0,y:0}),[S,de]=h.useState(void 0),Y=R?ft.ordinal().domain(f).range(c):vt.threshold().domain(f).range(c);h.useEffect(()=>{u.current&&(u.current.controls().enableZoom=w)},[w]),h.useEffect(()=>{u.current&&(S||y?u.current.controls().autoRotate=!1:(u.current.controls().autoRotate=n!==0,u.current.controls().autoRotateSpeed=n))},[S,y,n]),h.useEffect(()=>{if(u.current&&y){const r=v.find(b=>b.properties[a]===y),[s,d]=gt.getCentroidCoordinates(r);u.current.pointOfView({lat:d,lng:s,altitude:M},1e3)}},[y,M,v,a]),h.useEffect(()=>{const r=u.current?.renderer().domElement;if(!r)return;const s=d=>{ce({x:d.clientX,y:d.clientY})};return r.addEventListener("mousemove",s),()=>r.removeEventListener("mousemove",s)},[]),h.useEffect(()=>{u.current&&u.current.pointOfView({lat:Z,lng:W,altitude:M},1e3)},[M,W,Z]);const E=o||new U.MeshBasicMaterial({color:"#FFF"}),G=h.useCallback(()=>{if(!u.current)return;const r=u.current.scene(),s=u.current.camera();let d=[];r.traverse(p=>{p instanceof U.Light&&d.push(p)}),d=[...d,...s.children],d.forEach(p=>p.parent?.remove(p)),z.map(p=>Dt(p)).forEach((p,D)=>{z[D].type!=="ambient"&&z[D].position==="camera"?(s.add(p),z[D].type!=="point"&&s.add(p.target)):r.add(p)}),L&&(r.fog=new U.Fog(L.color,L.near,L.far))},[z,L]),k=()=>{be(!0),G()};return h.useEffect(()=>{B&&G()},[B,G]),i.jsxRuntimeExports.jsxs("div",{className:"relative",children:[i.jsxRuntimeExports.jsx(lt,{ref:u,height:l,width:e,globeOffset:m,lineHoverPrecision:0,polygonsData:v,polygonAltitude:r=>T.includes(r?.properties?.[a])||r?.properties?.[a]===y||r?.properties?.[a]===S?.id||r?.properties?.[a]===H?.id?ae:g,polygonCapColor:r=>{const s=y?r?.properties?.[a]===y?1:A:T.length!==0?T.includes(r?.properties?.[a])?1:A:1,d=r?.properties?.[a],b=x.find(D=>D.id===d)?.x,p=b!=null?Y(b):oe;return tt(p,`${s}`)},polygonSideColor:r=>{const s=r?.properties?.[a],d=x.find(D=>D.id===s)?.x,b=y?r?.properties?.[a]===y?1:A:T.length!==0?T.includes(r?.properties?.[a])?1:A:1,p=d!=null?Y(d):oe;return tt(p,`${b}`)},polygonStrokeColor:r=>r?.properties?.[a]===S?.id?se:j,onGlobeClick:()=>{N(void 0)},onPolygonClick:r=>{const s=r?.properties?.[a]?x.find(d=>d.id===r?.properties?.[a]):void 0;(V||$)&&(ct.isEqual(H,s)&&ye&&s?(N(void 0),V?.(void 0)):(N(s),V?.(s)))},onPolygonHover:r=>{const s=r?.properties?.[a]?x.find(d=>d.id===r?.properties?.[a]):void 0;de(s),ve?.(s)},atmosphereColor:q,atmosphereAltitude:ie,globeCurvatureResolution:J,globeMaterial:E,backgroundColor:"rgba(0, 0, 0, 0)",polygonsTransitionDuration:100,onGlobeReady:()=>{if(u.current){u.current.pointOfView({lat:Z,lng:W});const r=u.current.scene();setTimeout(()=>{(r.children[3]?.children[0]?.children[4]?.children||[]).forEach(b=>{const p=b.children[1];p.renderOrder=2})},300);const s=u.current.camera();r.add(s),k()}}}),re===!1?null:i.jsxRuntimeExports.jsx("div",{className:i.mo("absolute left-4 bottom-4 map-color-legend",_?.colorLegend),children:we?i.jsxRuntimeExports.jsxs(i.jsxRuntimeExports.Fragment,{children:[i.jsxRuntimeExports.jsx("div",{className:"color-legend-close-button bg-[rgba(240,240,240,0.7)] dark:bg-[rgba(30,30,30,0.7)] border border-[var(--gray-400)] rounded-full w-6 h-6 p-[3px] cursor-pointer z-10 absolute right-[-0.75rem] top-[-0.75rem]",onClick:()=>{ne(!1)},children:i.jsxRuntimeExports.jsx(mt.X,{})}),i.jsxRuntimeExports.jsxs("div",{className:"color-legend-box p-2 bg-[rgba(240,240,240,0.7)] dark:bg-[rgba(30,30,30,0.7)]",style:{width:R?void 0:"340px"},children:[C&&C!==""?i.jsxRuntimeExports.jsx(Ke.j,{size:"xs",marginBottom:"xs",className:"p-0 leading-normal overflow-hidden text-primary-gray-700 dark:text-primary-gray-300",style:{display:"-webkit-box",WebkitLineClamp:"1",WebkitBoxOrient:"vertical"},children:C}):null,R?i.jsxRuntimeExports.jsx("div",{className:"flex flex-col gap-3",children:f.map((r,s)=>i.jsxRuntimeExports.jsxs("div",{className:"flex gap-2 items-center",children:[i.jsxRuntimeExports.jsx("div",{className:"w-2 h-2 rounded-full",style:{backgroundColor:c[s%c.length]}}),i.jsxRuntimeExports.jsx(Ke.j,{size:"sm",marginBottom:"none",leading:"none",children:r})]},s))}):i.jsxRuntimeExports.jsx("svg",{width:"100%",viewBox:"0 0 320 30",direction:"ltr",children:i.jsxRuntimeExports.jsxs("g",{children:[f.map((r,s)=>i.jsxRuntimeExports.jsxs("g",{className:"cursor-pointer",children:[i.jsxRuntimeExports.jsx("rect",{x:s*320/c.length+1,y:1,width:320/c.length-2,height:8,style:{fill:c[s],stroke:c[s]}}),i.jsxRuntimeExports.jsx("text",{x:(s+1)*320/c.length,y:25,className:"fill-primary-gray-700 dark:fill-primary-gray-300 text-xs",style:{textAnchor:"middle"},children:ht.numberFormattingFunction(r,"NA")})]},s)),i.jsxRuntimeExports.jsx("g",{children:i.jsxRuntimeExports.jsx("rect",{x:f.length*320/c.length+1,y:1,width:320/c.length-2,height:8,style:{fill:c[f.length],stroke:c[f.length]}})})]})})]})]}):i.jsxRuntimeExports.jsx("button",{type:"button",className:"mb-0 border-0 bg-transparent p-0 self-start",onClick:()=>{ne(!0)},children:i.jsxRuntimeExports.jsx("div",{className:"show-color-legend-button items-start text-sm font-medium cursor-pointer p-2 mb-0 flex text-primary-black dark:text-primary-gray-300 bg-primary-gray-300 dark:bg-primary-gray-600 border-primary-gray-400 dark:border-primary-gray-500",children:"Show Legend"})})}),S&&P?i.jsxRuntimeExports.jsx(pt.Tooltip,{data:S,body:P,xPos:le.x,yPos:le.y,backgroundStyle:fe?.tooltip,className:_?.tooltip}):null,$&&H!==void 0?i.jsxRuntimeExports.jsx(xt.DetailsModal,{body:$,data:H,setData:N,className:_?.modal}):null]})}function kt(t){const e=i.compilerRuntimeExports.c(97),{data:n,mapData:x,graphTitle:w,colors:R,sources:f,graphDescription:c,height:o,width:l,footNote:v,colorDomain:a,colorLegendTitle:j,scaleType:q,padding:P,mapNoDataColor:fe,backgroundColor:_,mapBorderColor:oe,relativeHeight:C,tooltip:re,graphID:se,mapProperty:$,dataDownload:V,language:ve,minHeight:ye,theme:T,ariaLabel:M,styles:m,classNames:g,autoRotate:W,enableZoom:Z,globeMaterial:ie,centerPoint:J,atmosphereColor:L,showColorScale:z,resetSelectionOnDoubleClick:ae,detailsOnClick:y,onSeriesMouseOver:X,onSeriesMouseClick:A,highlightedIds:B,highlightedAltitude:be,dimmedOpacity:u,scale:H,globeOffset:N,polygonAltitude:we,globeCurvatureResolution:ne,atmosphereAltitude:le,fogSettings:ce,lights:S,selectedId:de,collapseColorScaleByDefault:Y}=t,E=x===void 0?"https://raw.githubusercontent.com/UNDP-Data/dv-country-geojson/refs/heads/main/worldMap-simplified.json":x,G=v===void 0?"The designations employed and the presentation of material on this map do not imply the expression of any opinion whatsoever on the part of the Secretariat of the United Nations or UNDP concerning the legal status of any country, territory, city or area or its authorities, or concerning the delimitation of its frontiers or boundaries.":v,k=q===void 0?"threshold":q,r=fe===void 0?te.Colors.light.graphNoData:fe,s=_===void 0?!1:_,d=oe===void 0?te.Colors.light.grays["gray-500"]:oe,b=$===void 0?"ISO3":$,p=V===void 0?!1:V,D=ve===void 0?"en":ve,O=ye===void 0?0:ye,F=T===void 0?"light":T,ue=W===void 0?!0:W,Le=Z===void 0?!0:Z;let je;e[0]!==J?(je=J===void 0?[0,0]:J,e[0]=J,e[1]=je):je=e[1];const Ce=je,ze=L===void 0?"#999":L,Ae=z===void 0?!0:z,Ge=ae===void 0?!0:ae;let Re;e[2]!==B?(Re=B===void 0?[]:B,e[2]=B,e[3]=Re):Re=e[3];const Fe=Re,Be=be===void 0?.1:be,He=u===void 0?.3:u,Ie=H===void 0?1:H;let Se;e[4]!==N?(Se=N===void 0?[0,0]:N,e[4]=N,e[5]=Se):Se=e[5];const Ue=Se,_e=we===void 0?.01:we,$e=ne===void 0?4:ne,Ve=le===void 0?.15:le;let Ee;e[6]!==S?(Ee=S===void 0?[{type:"ambient",color:4210752,intensity:.4},{type:"directional",color:16777215,intensity:1,position:{x:5,y:10,z:5}}]:S,e[6]=S,e[7]=Ee):Ee=e[7];const We=Ee,[De,ot]=h.useState(void 0),[I,rt]=h.useState(0),[pe,st]=h.useState(0),Ze=h.useRef(null),it=h.useRef(null);let Ne,ke;e[8]===Symbol.for("react.memo_cache_sentinel")?(Ne=()=>{const ge=new ResizeObserver(xe=>{rt(xe[0].target.clientWidth||620),st(xe[0].target.clientHeight||480)});return Ze.current&&ge.observe(Ze.current),()=>ge.disconnect()},ke=[],e[8]=Ne,e[9]=ke):(Ne=e[8],ke=e[9]),h.useEffect(Ne,ke);let Oe;e[10]===Symbol.for("react.memo_cache_sentinel")?(Oe=ge=>{ot(ge)},e[10]=Oe):Oe=e[10];const he=h.useEffectEvent(Oe);let qe;e[11]!==E||e[12]!==he?(qe=()=>{typeof E=="string"?wt.fetchAndParseJSON(E).then(xe=>{if(E==="https://raw.githubusercontent.com/UNDP-Data/dv-country-geojson/refs/heads/main/worldMap-simplified.json"){const at=xe.features.map(zt);he(at)}else he(xe.features)}):he(E.features)},e[11]=E,e[12]=he,e[13]=qe):qe=e[13];let Pe;e[14]!==E?(Pe=[E],e[14]=E,e[15]=Pe):Pe=e[15],h.useEffect(qe,Pe);let Te;e[16]!==a||e[17]!==R?.length||e[18]!==n||e[19]!==k?(Te=a||(k==="categorical"?jt.getUniqValue(n,"x"):Ct.getJenks(n.map(Lt),R?.length||4)),e[16]=a,e[17]=R?.length,e[18]=n,e[19]=k,e[20]=Te):Te=e[20];const me=Te,Je=g?.graphContainer,Xe=m?.graphContainer;let K;e[21]!==g?.description||e[22]!==g?.title||e[23]!==n||e[24]!==p||e[25]!==c||e[26]!==w||e[27]!==m?.description||e[28]!==m?.title||e[29]!==l?(K=w||c||p?i.jsxRuntimeExports.jsx(yt.GraphHeader,{styles:{title:m?.title,description:m?.description},classNames:{title:g?.title,description:g?.description},graphTitle:w,graphDescription:c,width:l,graphDownload:void 0,dataDownload:p?n.map(Mt).filter(Tt).length>0?n.map(Pt).filter(qt):n.filter(Ot):null}):null,e[21]=g?.description,e[22]=g?.title,e[23]=n,e[24]=p,e[25]=c,e[26]=w,e[27]=m?.description,e[28]=m?.title,e[29]=l,e[30]=K):K=e[30];let Q;e[31]!==Ve||e[32]!==ze||e[33]!==ue||e[34]!==Ce||e[35]!==g||e[36]!==Y||e[37]!==j||e[38]!==R||e[39]!==n||e[40]!==y||e[41]!==He||e[42]!==me||e[43]!==Le||e[44]!==ce||e[45]!==$e||e[46]!==ie||e[47]!==Ue||e[48]!==o||e[49]!==Be||e[50]!==Fe||e[51]!==We||e[52]!==d||e[53]!==r||e[54]!==b||e[55]!==De||e[56]!==O||e[57]!==A||e[58]!==X||e[59]!==_e||e[60]!==C||e[61]!==Ge||e[62]!==Ie||e[63]!==k||e[64]!==de||e[65]!==Ae||e[66]!==m||e[67]!==pe||e[68]!==I||e[69]!==F||e[70]!==re||e[71]!==l?(Q=i.jsxRuntimeExports.jsx(Qe.GraphArea,{ref:Ze,children:I&&pe&&De?i.jsxRuntimeExports.jsx(Nt,{data:n,globeOffset:Ue,polygonData:De,colorDomain:me,width:I,height:pe,colors:R||(k==="categorical"?te.Colors[F].sequentialColors[`neutralColorsx0${me.length}`]:te.Colors[F].sequentialColors[`neutralColorsx0${me.length+1}`]),mapNoDataColor:r,categorical:k==="categorical",mapBorderColor:d,tooltip:re,mapProperty:b,styles:m,classNames:g,autoRotate:ue===!0?1.5:ue===!1?0:ue,enableZoom:Le,globeMaterial:ie,atmosphereColor:ze,colorLegendTitle:j,showColorScale:Ae,hoverStrokeColor:F==="light"?te.Colors.light.grays["gray-700"]:te.Colors.light.grays["gray-300"],highlightedIds:Fe,resetSelectionOnDoubleClick:Ge,detailsOnClick:y,onSeriesMouseOver:X,onSeriesMouseClick:A,scale:Ie,polygonAltitude:_e,centerLat:Ce[0],centerLng:Ce[1],atmosphereAltitude:Ve,globeCurvatureResolution:$e,fogSettings:ce,lights:We,highlightedAltitude:Be,selectedId:de,collapseColorScaleByDefault:Y,dimmedOpacity:He}):i.jsxRuntimeExports.jsx("div",{style:{height:`${Math.max(O,o||(C?O?(l||I)*C>O?(l||I)*C:O:(l||I)*C:pe))}px`},className:"flex items-center justify-center",children:i.jsxRuntimeExports.jsx(nt.w,{"aria-label":"Loading graph"})})}),e[31]=Ve,e[32]=ze,e[33]=ue,e[34]=Ce,e[35]=g,e[36]=Y,e[37]=j,e[38]=R,e[39]=n,e[40]=y,e[41]=He,e[42]=me,e[43]=Le,e[44]=ce,e[45]=$e,e[46]=ie,e[47]=Ue,e[48]=o,e[49]=Be,e[50]=Fe,e[51]=We,e[52]=d,e[53]=r,e[54]=b,e[55]=De,e[56]=O,e[57]=A,e[58]=X,e[59]=_e,e[60]=C,e[61]=Ge,e[62]=Ie,e[63]=k,e[64]=de,e[65]=Ae,e[66]=m,e[67]=pe,e[68]=I,e[69]=F,e[70]=re,e[71]=l,e[72]=Q):Q=e[72];let ee;e[73]!==g?.footnote||e[74]!==g?.source||e[75]!==G||e[76]!==f||e[77]!==m?.footnote||e[78]!==m?.source||e[79]!==l?(ee=f||G?i.jsxRuntimeExports.jsx(bt.GraphFooter,{styles:{footnote:m?.footnote,source:m?.source},classNames:{footnote:g?.footnote,source:g?.source},sources:f,footNote:G,width:l}):null,e[73]=g?.footnote,e[74]=g?.source,e[75]=G,e[76]=f,e[77]=m?.footnote,e[78]=m?.source,e[79]=l,e[80]=ee):ee=e[80];let Me;return e[81]!==M||e[82]!==s||e[83]!==se||e[84]!==o||e[85]!==D||e[86]!==O||e[87]!==P||e[88]!==C||e[89]!==Je||e[90]!==Xe||e[91]!==K||e[92]!==Q||e[93]!==ee||e[94]!==F||e[95]!==l?(Me=i.jsxRuntimeExports.jsxs(Qe.GraphContainer,{className:Je,style:Xe,id:se,ref:it,"aria-label":M,backgroundColor:s,theme:F,language:D,minHeight:O,width:l,height:o,relativeHeight:C,padding:P,children:[K,Q,ee]}),e[81]=M,e[82]=s,e[83]=se,e[84]=o,e[85]=D,e[86]=O,e[87]=P,e[88]=C,e[89]=Je,e[90]=Xe,e[91]=K,e[92]=Q,e[93]=ee,e[94]=F,e[95]=l,e[96]=Me):Me=e[96],Me}function Ot(t){return t!==void 0}function qt(t){return t!==void 0}function Pt(t){return t.data}function Tt(t){return t!==void 0}function Mt(t){return t.data}function Lt(t){return t.x}function zt(t){if(t.geometry.type==="Polygon"){const x=[...t.geometry.coordinates[0]].reverse(),w={...t.geometry,coordinates:[x]};return{...t,geometry:w}}const e=[];t.geometry.coordinates.forEach(x=>{const w=[...x[0]].reverse();e.push([w])});const n={...t.geometry,coordinates:e};return{...t,geometry:n}}exports.ThreeDGlobe=kt;
|
|
2
2
|
//# sourceMappingURL=ThreeDGlobe.cjs.map
|
package/dist/ThreeDGlobe.js
CHANGED
|
@@ -1,25 +1,25 @@
|
|
|
1
|
-
import { j as i, m as lt, c as ct } from "./index-CHPV5EwG-
|
|
1
|
+
import { j as i, m as lt, c as ct } from "./index-CHPV5EwG-DecW7_qr.js";
|
|
2
2
|
import { useState as I, useRef as Qe, useEffect as G, useCallback as dt, useEffectEvent as pt } from "react";
|
|
3
|
-
import { w as ht } from "./Spinner
|
|
3
|
+
import { w as ht } from "./Spinner--r2RrJV8.js";
|
|
4
4
|
import mt from "react-globe.gl";
|
|
5
5
|
import { i as ut } from "./index-Bwrro8-q.js";
|
|
6
6
|
import * as $ from "three";
|
|
7
|
-
import { j as et } from "./Typography-
|
|
7
|
+
import { j as et } from "./Typography-hWfh3H0J.js";
|
|
8
8
|
import { g as gt } from "./_commonjsHelpers-ByX85dGu.js";
|
|
9
|
-
import { T as ft } from "./Tooltip-
|
|
9
|
+
import { T as ft } from "./Tooltip-BRnAz2Gv.js";
|
|
10
10
|
import { n as vt } from "./numberFormattingFunction-14YCbkN2.js";
|
|
11
|
-
import { X as yt } from "./index-
|
|
12
|
-
import { g as bt } from "./getCentroidCoordinates-
|
|
13
|
-
import { D as xt } from "./DetailsModal-
|
|
14
|
-
import { o as wt } from "./ordinal-
|
|
11
|
+
import { X as yt } from "./index-BQYOuXdl.js";
|
|
12
|
+
import { g as bt } from "./getCentroidCoordinates-s0OOUjLF.js";
|
|
13
|
+
import { D as xt } from "./DetailsModal-BMCTgVsk.js";
|
|
14
|
+
import { o as wt } from "./ordinal-CHaxGJ_l.js";
|
|
15
15
|
import { t as Ct } from "./threshold-DFfqcDMa.js";
|
|
16
16
|
import { GraphHeader as Dt } from "./GraphHeader.js";
|
|
17
17
|
import { GraphFooter as St } from "./GraphFooter.js";
|
|
18
|
-
import { f as jt } from "./fetchAndParseData-
|
|
18
|
+
import { f as jt } from "./fetchAndParseData-BAXhgTDM.js";
|
|
19
19
|
import { Colors as oe } from "./Colors.js";
|
|
20
20
|
import { g as Nt } from "./getUniqValue-DsqSii6M.js";
|
|
21
|
-
import { g as kt } from "./getJenks-
|
|
22
|
-
import { a as Rt, G as Ot } from "./GraphContainer-
|
|
21
|
+
import { g as kt } from "./getJenks-DTCcQSDi.js";
|
|
22
|
+
import { a as Rt, G as Ot } from "./GraphContainer-CF6ws3pd.js";
|
|
23
23
|
var Ke, tt;
|
|
24
24
|
function Lt() {
|
|
25
25
|
if (tt) return Ke;
|
|
@@ -317,14 +317,14 @@ function lo(t) {
|
|
|
317
317
|
}] : S, e[6] = S, e[7] = ke) : ke = e[7];
|
|
318
318
|
const _e = ke, [Re, rt] = I(void 0), [H, at] = I(0), [me, it] = I(0), Je = Qe(null), st = Qe(null);
|
|
319
319
|
let Oe, Le;
|
|
320
|
-
e[8] === Symbol.for("react.memo_cache_sentinel") ? (Oe = () => {
|
|
320
|
+
e[8] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (Oe = () => {
|
|
321
321
|
const fe = new ResizeObserver((ve) => {
|
|
322
322
|
at(ve[0].target.clientWidth || 620), it(ve[0].target.clientHeight || 480);
|
|
323
323
|
});
|
|
324
324
|
return Je.current && fe.observe(Je.current), () => fe.disconnect();
|
|
325
325
|
}, Le = [], e[8] = Oe, e[9] = Le) : (Oe = e[8], Le = e[9]), G(Oe, Le);
|
|
326
326
|
let Pe;
|
|
327
|
-
e[10] === Symbol.for("react.memo_cache_sentinel") ? (Pe = (fe) => {
|
|
327
|
+
e[10] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (Pe = (fe) => {
|
|
328
328
|
rt(fe);
|
|
329
329
|
}, e[10] = Pe) : Pe = e[10];
|
|
330
330
|
const ue = pt(Pe);
|