@undp/data-viz 1.5.8 → 2.0.0
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.cjs.map +1 -1
- package/dist/AreaChart.d.ts +1 -0
- package/dist/AreaChart.js +420 -520
- package/dist/AreaChart.js.map +1 -1
- package/dist/Axis-CRyfcLjc.js +32 -0
- package/dist/Axis-CRyfcLjc.js.map +1 -0
- package/dist/Axis-DxRV2yMi.cjs +2 -0
- package/dist/Axis-DxRV2yMi.cjs.map +1 -0
- package/dist/AxisTitle-jeI7am8o.js +29 -0
- package/dist/AxisTitle-jeI7am8o.js.map +1 -0
- package/dist/AxisTitle-sS5bLLR7.cjs +2 -0
- package/dist/AxisTitle-sS5bLLR7.cjs.map +1 -0
- package/dist/BarGraph.cjs +1 -1
- package/dist/BarGraph.cjs.map +1 -1
- package/dist/BarGraph.d.ts +1 -0
- package/dist/BarGraph.js +2188 -4045
- package/dist/BarGraph.js.map +1 -1
- package/dist/BasicStatCard.cjs +1 -1
- package/dist/BasicStatCard.cjs.map +1 -1
- package/dist/BasicStatCard.d.ts +1 -0
- package/dist/BasicStatCard.js +120 -186
- package/dist/BasicStatCard.js.map +1 -1
- package/dist/BeeSwarmChart.cjs +1 -1
- package/dist/BeeSwarmChart.cjs.map +1 -1
- package/dist/BeeSwarmChart.d.ts +5 -0
- package/dist/BeeSwarmChart.js +501 -1019
- package/dist/BeeSwarmChart.js.map +1 -1
- package/dist/BiVariateChoroplethMap.cjs +1 -1
- package/dist/BiVariateChoroplethMap.cjs.map +1 -1
- package/dist/BiVariateChoroplethMap.d.ts +3 -0
- package/dist/BiVariateChoroplethMap.js +458 -706
- package/dist/BiVariateChoroplethMap.js.map +1 -1
- package/dist/BulletChart.cjs +1 -1
- package/dist/BulletChart.cjs.map +1 -1
- package/dist/BulletChart.d.ts +1 -0
- package/dist/BulletChart.js +863 -1414
- package/dist/BulletChart.js.map +1 -1
- package/dist/ButterflyChart.cjs +1 -1
- package/dist/ButterflyChart.cjs.map +1 -1
- package/dist/ButterflyChart.d.ts +1 -0
- package/dist/ButterflyChart.js +474 -684
- package/dist/ButterflyChart.js.map +1 -1
- package/dist/ChoroplethMap.cjs +1 -1
- package/dist/ChoroplethMap.cjs.map +1 -1
- package/dist/ChoroplethMap.d.ts +3 -0
- package/dist/ChoroplethMap.js +469 -731
- package/dist/ChoroplethMap.js.map +1 -1
- package/dist/CirclePackingGraph.cjs +1 -1
- package/dist/CirclePackingGraph.d.ts +1 -0
- package/dist/CirclePackingGraph.js +5 -4
- package/dist/CirclePackingGraph.js.map +1 -1
- package/dist/ColorLegend.cjs +1 -1
- package/dist/ColorLegend.cjs.map +1 -1
- package/dist/ColorLegend.js +57 -44
- package/dist/ColorLegend.js.map +1 -1
- package/dist/ColorLegendWithMouseOver.cjs +1 -1
- package/dist/ColorLegendWithMouseOver.cjs.map +1 -1
- package/dist/ColorLegendWithMouseOver.js +60 -65
- package/dist/ColorLegendWithMouseOver.js.map +1 -1
- package/dist/Colors.cjs.map +1 -1
- package/dist/Colors.js +44 -430
- package/dist/Colors.js.map +1 -1
- package/dist/CopyTextButton.cjs +4 -4
- package/dist/CopyTextButton.cjs.map +1 -1
- package/dist/CopyTextButton.js +537 -455
- package/dist/CopyTextButton.js.map +1 -1
- package/dist/CsvDownloadButton.cjs +7 -7
- package/dist/CsvDownloadButton.cjs.map +1 -1
- package/dist/CsvDownloadButton.js +442 -447
- package/dist/CsvDownloadButton.js.map +1 -1
- package/dist/DataCards.cjs +5 -5
- package/dist/DataCards.cjs.map +1 -1
- package/dist/DataCards.d.ts +1 -0
- package/dist/DataCards.js +488 -581
- package/dist/DataCards.js.map +1 -1
- package/dist/DataTable.cjs +1 -1
- package/dist/DataTable.cjs.map +1 -1
- package/dist/DataTable.d.ts +1 -0
- package/dist/DataTable.js +183 -326
- package/dist/DataTable.js.map +1 -1
- package/dist/DifferenceLineChart.cjs +1 -1
- package/dist/DifferenceLineChart.cjs.map +1 -1
- package/dist/DifferenceLineChart.d.ts +1 -0
- package/dist/DifferenceLineChart.js +729 -794
- package/dist/DifferenceLineChart.js.map +1 -1
- package/dist/DonutChart.cjs +1 -1
- package/dist/DonutChart.cjs.map +1 -1
- package/dist/DonutChart.d.ts +1 -4
- package/dist/DonutChart.js +260 -444
- package/dist/DonutChart.js.map +1 -1
- package/dist/DotDensityMap.cjs +1 -1
- package/dist/DotDensityMap.cjs.map +1 -1
- package/dist/DotDensityMap.d.ts +3 -0
- package/dist/DotDensityMap.js +388 -582
- package/dist/DotDensityMap.js.map +1 -1
- package/dist/{DropdownSelect-CtOKZHD0.js → DropdownSelect-BbdPQa2k.js} +1401 -1374
- package/dist/DropdownSelect-BbdPQa2k.js.map +1 -0
- package/dist/DropdownSelect-Doz3mCrM.cjs +29 -0
- package/dist/DropdownSelect-Doz3mCrM.cjs.map +1 -0
- package/dist/DualAxisLineChart.cjs +1 -1
- package/dist/DualAxisLineChart.cjs.map +1 -1
- package/dist/DualAxisLineChart.d.ts +1 -0
- package/dist/DualAxisLineChart.js +617 -712
- package/dist/DualAxisLineChart.js.map +1 -1
- package/dist/DumbbellChart.cjs +1 -1
- package/dist/DumbbellChart.cjs.map +1 -1
- package/dist/DumbbellChart.d.ts +1 -0
- package/dist/DumbbellChart.js +789 -1499
- package/dist/DumbbellChart.js.map +1 -1
- package/dist/EmptyState-BZo1BbAn.js +15 -0
- package/dist/{EmptyState-DdTp-Mdn.js.map → EmptyState-BZo1BbAn.js.map} +1 -1
- package/dist/EmptyState-sAEZ_5rU.cjs +2 -0
- package/dist/{EmptyState-d8_8SxeW.cjs.map → EmptyState-sAEZ_5rU.cjs.map} +1 -1
- package/dist/ExcelDownloadButton.cjs +1 -1
- package/dist/ExcelDownloadButton.cjs.map +1 -1
- package/dist/ExcelDownloadButton.js +20 -24
- package/dist/ExcelDownloadButton.js.map +1 -1
- package/dist/FootNote.cjs +1 -1
- package/dist/FootNote.cjs.map +1 -1
- package/dist/FootNote.js +26 -17
- package/dist/FootNote.js.map +1 -1
- package/dist/GeoHubCompareMaps.cjs +1 -1
- package/dist/GeoHubCompareMaps.cjs.map +1 -1
- package/dist/GeoHubCompareMaps.d.ts +1 -0
- package/dist/GeoHubCompareMaps.js +264 -354
- package/dist/GeoHubCompareMaps.js.map +1 -1
- package/dist/GeoHubMap.cjs +1 -1
- package/dist/GeoHubMap.cjs.map +1 -1
- package/dist/GeoHubMap.d.ts +1 -0
- package/dist/GeoHubMap.js +214 -409
- package/dist/GeoHubMap.js.map +1 -1
- package/dist/GeoHubMapWithLayerSelection.cjs +1 -1
- package/dist/GeoHubMapWithLayerSelection.cjs.map +1 -1
- package/dist/GeoHubMapWithLayerSelection.d.ts +1 -0
- package/dist/GeoHubMapWithLayerSelection.js +192 -293
- package/dist/GeoHubMapWithLayerSelection.js.map +1 -1
- package/dist/GraphContainer-CRqzdKu2.js +78 -0
- package/dist/GraphContainer-CRqzdKu2.js.map +1 -0
- package/dist/GraphContainer-d8A46BK2.cjs +2 -0
- package/dist/GraphContainer-d8A46BK2.cjs.map +1 -0
- package/dist/GraphDescription.cjs +1 -1
- package/dist/GraphDescription.cjs.map +1 -1
- package/dist/GraphDescription.js +23 -17
- package/dist/GraphDescription.js.map +1 -1
- package/dist/GraphEl-BkyLYXG5.cjs +2 -0
- package/dist/GraphEl-BkyLYXG5.cjs.map +1 -0
- package/dist/{GraphEl-CqWzvOyr.js → GraphEl-DzRon4cb.js} +184 -202
- package/dist/GraphEl-DzRon4cb.js.map +1 -0
- package/dist/GraphFooter.cjs +1 -1
- package/dist/GraphFooter.cjs.map +1 -1
- package/dist/GraphFooter.js +28 -18
- package/dist/GraphFooter.js.map +1 -1
- package/dist/GraphHeader.cjs +1 -1
- package/dist/GraphHeader.cjs.map +1 -1
- package/dist/GraphHeader.d.ts +2 -1
- package/dist/GraphHeader.js +45 -59
- package/dist/GraphHeader.js.map +1 -1
- package/dist/GraphTitle.cjs +1 -1
- package/dist/GraphTitle.cjs.map +1 -1
- package/dist/GraphTitle.js +29 -24
- package/dist/GraphTitle.js.map +1 -1
- package/dist/GriddedGraphs.cjs +1 -1
- package/dist/GriddedGraphs.cjs.map +1 -1
- package/dist/GriddedGraphs.d.ts +2 -0
- package/dist/GriddedGraphs.js +216 -450
- package/dist/GriddedGraphs.js.map +1 -1
- package/dist/GriddedGraphsFromConfig.cjs +1 -1
- package/dist/GriddedGraphsFromConfig.cjs.map +1 -1
- package/dist/GriddedGraphsFromConfig.d.ts +2 -0
- package/dist/GriddedGraphsFromConfig.js +22 -36
- package/dist/GriddedGraphsFromConfig.js.map +1 -1
- package/dist/HeatMap.cjs +1 -1
- package/dist/HeatMap.cjs.map +1 -1
- package/dist/HeatMap.d.ts +1 -0
- package/dist/HeatMap.js +278 -446
- package/dist/HeatMap.js.map +1 -1
- package/dist/Histogram.cjs +1 -1
- package/dist/Histogram.cjs.map +1 -1
- package/dist/Histogram.d.ts +1 -0
- package/dist/Histogram.js +154 -264
- package/dist/Histogram.js.map +1 -1
- package/dist/ImageDownloadButton.cjs +1 -1
- package/dist/ImageDownloadButton.cjs.map +1 -1
- package/dist/ImageDownloadButton.d.ts +2 -1
- package/dist/ImageDownloadButton.js +21 -25
- package/dist/ImageDownloadButton.js.map +1 -1
- package/dist/LineChartWithConfidenceInterval.cjs +1 -1
- package/dist/LineChartWithConfidenceInterval.cjs.map +1 -1
- package/dist/LineChartWithConfidenceInterval.d.ts +1 -0
- package/dist/LineChartWithConfidenceInterval.js +674 -825
- package/dist/LineChartWithConfidenceInterval.js.map +1 -1
- package/dist/LinearColorLegend.cjs +1 -1
- package/dist/LinearColorLegend.cjs.map +1 -1
- package/dist/LinearColorLegend.js +49 -30
- package/dist/LinearColorLegend.js.map +1 -1
- package/dist/Modal-DGcuAHyK.js +1047 -0
- package/dist/Modal-DGcuAHyK.js.map +1 -0
- package/dist/Modal-JW_IExO3.cjs +46 -0
- package/dist/Modal-JW_IExO3.cjs.map +1 -0
- package/dist/MultiGraphDashboard.cjs +1 -1
- package/dist/MultiGraphDashboard.cjs.map +1 -1
- package/dist/MultiGraphDashboard.d.ts +2 -0
- package/dist/MultiGraphDashboard.js +122 -290
- package/dist/MultiGraphDashboard.js.map +1 -1
- package/dist/MultiGraphDashboardFromConfig.cjs +1 -1
- package/dist/MultiGraphDashboardFromConfig.cjs.map +1 -1
- package/dist/MultiGraphDashboardFromConfig.d.ts +2 -0
- package/dist/MultiGraphDashboardFromConfig.js +22 -31
- package/dist/MultiGraphDashboardFromConfig.js.map +1 -1
- package/dist/MultiGraphDashboardWideToLongFormat.cjs +1 -1
- package/dist/MultiGraphDashboardWideToLongFormat.cjs.map +1 -1
- package/dist/MultiGraphDashboardWideToLongFormat.d.ts +1 -0
- package/dist/MultiGraphDashboardWideToLongFormat.js +137 -223
- package/dist/MultiGraphDashboardWideToLongFormat.js.map +1 -1
- package/dist/MultiGraphDashboardWideToLongFormatFromConfig.cjs +1 -1
- package/dist/MultiGraphDashboardWideToLongFormatFromConfig.cjs.map +1 -1
- package/dist/MultiGraphDashboardWideToLongFormatFromConfig.d.ts +1 -0
- package/dist/MultiGraphDashboardWideToLongFormatFromConfig.js +25 -27
- package/dist/MultiGraphDashboardWideToLongFormatFromConfig.js.map +1 -1
- package/dist/MultiLineAltChart.cjs +1 -1
- package/dist/MultiLineAltChart.cjs.map +1 -1
- package/dist/MultiLineAltChart.d.ts +1 -0
- package/dist/MultiLineAltChart.js +581 -659
- package/dist/MultiLineAltChart.js.map +1 -1
- package/dist/MultiLineChart.cjs +1 -1
- package/dist/MultiLineChart.cjs.map +1 -1
- package/dist/MultiLineChart.d.ts +1 -0
- package/dist/MultiLineChart.js +617 -725
- package/dist/MultiLineChart.js.map +1 -1
- package/dist/ParetoChart.cjs +1 -1
- package/dist/ParetoChart.cjs.map +1 -1
- package/dist/ParetoChart.d.ts +1 -0
- package/dist/ParetoChart.js +531 -635
- package/dist/ParetoChart.js.map +1 -1
- package/dist/PerformanceIntensiveMultiGraphDashboard.cjs +1 -1
- package/dist/PerformanceIntensiveMultiGraphDashboard.cjs.map +1 -1
- package/dist/PerformanceIntensiveMultiGraphDashboard.d.ts +2 -0
- package/dist/PerformanceIntensiveMultiGraphDashboard.js +147 -338
- package/dist/PerformanceIntensiveMultiGraphDashboard.js.map +1 -1
- package/dist/PerformanceIntensiveMultiGraphDashboardFromConfig.cjs +1 -1
- package/dist/PerformanceIntensiveMultiGraphDashboardFromConfig.cjs.map +1 -1
- package/dist/PerformanceIntensiveMultiGraphDashboardFromConfig.d.ts +2 -0
- package/dist/PerformanceIntensiveMultiGraphDashboardFromConfig.js +22 -31
- package/dist/PerformanceIntensiveMultiGraphDashboardFromConfig.js.map +1 -1
- package/dist/PerformanceIntensiveScrollStory.cjs +1 -1
- package/dist/PerformanceIntensiveScrollStory.cjs.map +1 -1
- package/dist/PerformanceIntensiveScrollStory.d.ts +2 -0
- package/dist/PerformanceIntensiveScrollStory.js +93 -114
- package/dist/PerformanceIntensiveScrollStory.js.map +1 -1
- package/dist/RadarChart.cjs +1 -1
- package/dist/RadarChart.cjs.map +1 -1
- package/dist/RadarChart.d.ts +1 -0
- package/dist/RadarChart.js +426 -575
- package/dist/RadarChart.js.map +1 -1
- package/dist/ReferenceLine-2XCwHXQ4.js +162 -0
- package/dist/ReferenceLine-2XCwHXQ4.js.map +1 -0
- package/dist/ReferenceLine-BH0qdf4R.cjs +2 -0
- package/dist/ReferenceLine-BH0qdf4R.cjs.map +1 -0
- package/dist/RegressionLine-BOTTNSrr.cjs +2 -0
- package/dist/RegressionLine-BOTTNSrr.cjs.map +1 -0
- package/dist/RegressionLine-DAcY2DjT.js +87 -0
- package/dist/RegressionLine-DAcY2DjT.js.map +1 -0
- package/dist/SVGDownloadButton.cjs +1 -1
- package/dist/SVGDownloadButton.cjs.map +1 -1
- package/dist/SVGDownloadButton.js +21 -25
- package/dist/SVGDownloadButton.js.map +1 -1
- package/dist/SankeyChart.cjs +1 -1
- package/dist/SankeyChart.cjs.map +1 -1
- package/dist/SankeyChart.d.ts +1 -0
- package/dist/SankeyChart.js +665 -854
- package/dist/SankeyChart.js.map +1 -1
- package/dist/ScatterPlot.cjs +1 -1
- package/dist/ScatterPlot.cjs.map +1 -1
- package/dist/ScatterPlot.d.ts +1 -0
- package/dist/ScatterPlot.js +675 -815
- package/dist/ScatterPlot.js.map +1 -1
- package/dist/ScrollStory.cjs +1 -1
- package/dist/ScrollStory.cjs.map +1 -1
- package/dist/ScrollStory.d.ts +2 -0
- package/dist/ScrollStory.js +85 -97
- package/dist/ScrollStory.js.map +1 -1
- package/dist/SimpleLineChart.cjs +1 -1
- package/dist/SimpleLineChart.cjs.map +1 -1
- package/dist/SimpleLineChart.d.ts +1 -0
- package/dist/SimpleLineChart.js +504 -613
- package/dist/SimpleLineChart.js.map +1 -1
- package/dist/SingleGraphDashboard.cjs +1 -1
- package/dist/SingleGraphDashboard.cjs.map +1 -1
- package/dist/SingleGraphDashboard.d.ts +3 -1
- package/dist/SingleGraphDashboard.js +279 -507
- package/dist/SingleGraphDashboard.js.map +1 -1
- package/dist/SingleGraphDashboardFromConfig.cjs +1 -1
- package/dist/SingleGraphDashboardFromConfig.cjs.map +1 -1
- package/dist/SingleGraphDashboardFromConfig.d.ts +3 -1
- package/dist/SingleGraphDashboardFromConfig.js +25 -31
- package/dist/SingleGraphDashboardFromConfig.js.map +1 -1
- package/dist/SingleGraphDashboardGeoHubMaps.cjs +1 -1
- package/dist/SingleGraphDashboardGeoHubMaps.cjs.map +1 -1
- package/dist/SingleGraphDashboardGeoHubMaps.d.ts +2 -0
- package/dist/SingleGraphDashboardGeoHubMaps.js +146 -168
- package/dist/SingleGraphDashboardGeoHubMaps.js.map +1 -1
- package/dist/SingleGraphDashboardGeoHubMapsFromConfig.cjs +1 -1
- package/dist/SingleGraphDashboardGeoHubMapsFromConfig.cjs.map +1 -1
- package/dist/SingleGraphDashboardGeoHubMapsFromConfig.d.ts +2 -0
- package/dist/SingleGraphDashboardGeoHubMapsFromConfig.js +25 -21
- package/dist/SingleGraphDashboardGeoHubMapsFromConfig.js.map +1 -1
- package/dist/SingleGraphDashboardThreeDGraphs.cjs +1 -1
- package/dist/SingleGraphDashboardThreeDGraphs.cjs.map +1 -1
- package/dist/SingleGraphDashboardThreeDGraphs.d.ts +2 -0
- package/dist/SingleGraphDashboardThreeDGraphs.js +356 -589
- package/dist/SingleGraphDashboardThreeDGraphs.js.map +1 -1
- package/dist/SingleGraphDashboardThreeDGraphsFromConfig.cjs +1 -1
- package/dist/SingleGraphDashboardThreeDGraphsFromConfig.cjs.map +1 -1
- package/dist/SingleGraphDashboardThreeDGraphsFromConfig.d.ts +2 -0
- package/dist/SingleGraphDashboardThreeDGraphsFromConfig.js +25 -31
- package/dist/SingleGraphDashboardThreeDGraphsFromConfig.js.map +1 -1
- package/dist/SlopeChart.cjs +1 -1
- package/dist/SlopeChart.cjs.map +1 -1
- package/dist/SlopeChart.d.ts +1 -0
- package/dist/SlopeChart.js +539 -573
- package/dist/SlopeChart.js.map +1 -1
- package/dist/Source-DYMJRrsq.cjs +2 -0
- package/dist/Source-DYMJRrsq.cjs.map +1 -0
- package/dist/Source-DwTHB8fn.js +78 -0
- package/dist/Source-DwTHB8fn.js.map +1 -0
- package/dist/Source.cjs +1 -1
- package/dist/Source.cjs.map +1 -1
- package/dist/Source.js +4 -38
- package/dist/Source.js.map +1 -1
- package/dist/SparkLine.cjs +1 -1
- package/dist/SparkLine.cjs.map +1 -1
- package/dist/SparkLine.d.ts +1 -0
- package/dist/SparkLine.js +286 -314
- package/dist/SparkLine.js.map +1 -1
- package/dist/Spinner-D7rnnwnA.js +47 -0
- package/dist/Spinner-D7rnnwnA.js.map +1 -0
- package/dist/Spinner-DRMBUsX7.cjs +2 -0
- package/dist/Spinner-DRMBUsX7.cjs.map +1 -0
- package/dist/StatCardFromData.cjs +1 -1
- package/dist/StatCardFromData.cjs.map +1 -1
- package/dist/StatCardFromData.d.ts +1 -0
- package/dist/StatCardFromData.js +163 -243
- package/dist/StatCardFromData.js.map +1 -1
- package/dist/StripChart.cjs +1 -1
- package/dist/StripChart.cjs.map +1 -1
- package/dist/StripChart.d.ts +1 -0
- package/dist/StripChart.js +665 -983
- package/dist/StripChart.js.map +1 -1
- package/dist/ThreeDGlobe.cjs +1 -1
- package/dist/ThreeDGlobe.cjs.map +1 -1
- package/dist/ThreeDGlobe.d.ts +3 -0
- package/dist/ThreeDGlobe.js +355 -526
- package/dist/ThreeDGlobe.js.map +1 -1
- package/dist/ThresholdColorLegendWithMouseOver.cjs +1 -1
- package/dist/ThresholdColorLegendWithMouseOver.cjs.map +1 -1
- package/dist/ThresholdColorLegendWithMouseOver.js +96 -126
- package/dist/ThresholdColorLegendWithMouseOver.js.map +1 -1
- package/dist/Tooltip-4dJo4_AF.cjs +2 -0
- package/dist/Tooltip-4dJo4_AF.cjs.map +1 -0
- package/dist/Tooltip-CwWUegPB.js +43 -0
- package/dist/Tooltip-CwWUegPB.js.map +1 -0
- package/dist/TreeMapGraph.cjs +1 -1
- package/dist/TreeMapGraph.cjs.map +1 -1
- package/dist/TreeMapGraph.d.ts +1 -0
- package/dist/TreeMapGraph.js +479 -617
- package/dist/TreeMapGraph.js.map +1 -1
- package/dist/Types.d.ts +2 -0
- package/dist/Typography-DX7PlgQU.cjs +2 -0
- package/dist/Typography-DX7PlgQU.cjs.map +1 -0
- package/dist/Typography-PxtFcnJb.js +142 -0
- package/dist/Typography-PxtFcnJb.js.map +1 -0
- package/dist/UnitChart.cjs +1 -1
- package/dist/UnitChart.cjs.map +1 -1
- package/dist/UnitChart.d.ts +1 -0
- package/dist/UnitChart.js +160 -212
- package/dist/UnitChart.js.map +1 -1
- package/dist/XAxesLabels-D5X8jngD.cjs +2 -0
- package/dist/XAxesLabels-D5X8jngD.cjs.map +1 -0
- package/dist/XAxesLabels-DNO0KmjL.js +73 -0
- package/dist/XAxesLabels-DNO0KmjL.js.map +1 -0
- package/dist/XTicksAndGridLines-B6CELS7q.cjs +2 -0
- package/dist/XTicksAndGridLines-B6CELS7q.cjs.map +1 -0
- package/dist/XTicksAndGridLines-CObVFSm4.js +38 -0
- package/dist/XTicksAndGridLines-CObVFSm4.js.map +1 -0
- package/dist/YAxesLabels-DcS85Beo.cjs +2 -0
- package/dist/YAxesLabels-DcS85Beo.cjs.map +1 -0
- package/dist/YAxesLabels-Dnnng49-.js +70 -0
- package/dist/YAxesLabels-Dnnng49-.js.map +1 -0
- package/dist/YTicksAndGridLines-4pxTRlRK.cjs +2 -0
- package/dist/YTicksAndGridLines-4pxTRlRK.cjs.map +1 -0
- package/dist/YTicksAndGridLines-Blepl7XF.js +38 -0
- package/dist/YTicksAndGridLines-Blepl7XF.js.map +1 -0
- package/dist/{band-BEjh2CHI.js → band-CyHaVft5.js} +3 -3
- package/dist/{band-BEjh2CHI.js.map → band-CyHaVft5.js.map} +1 -1
- package/dist/{band-CAApY4Pd.cjs → band-VYfcZeJ2.cjs} +2 -2
- package/dist/{band-CAApY4Pd.cjs.map → band-VYfcZeJ2.cjs.map} +1 -1
- package/dist/checkIfMultiple-Y9iKaV_u.js +950 -0
- package/dist/checkIfMultiple-Y9iKaV_u.js.map +1 -0
- package/dist/checkIfMultiple-wg6hJLXy.cjs +12 -0
- package/dist/checkIfMultiple-wg6hJLXy.cjs.map +1 -0
- package/dist/customArea-BUhPiPT6.js +163 -0
- package/dist/{customArea-B-dWU0zZ.js.map → customArea-BUhPiPT6.js.map} +1 -1
- package/dist/customArea-CMF5g-C3.cjs +2 -0
- package/dist/{customArea-CK768gCn.cjs.map → customArea-CMF5g-C3.cjs.map} +1 -1
- package/dist/delaunay-C1uAf38t.js.map +1 -1
- package/dist/delaunay-rcy0HhZi.cjs.map +1 -1
- package/dist/{ensureCompleteData-DlmibgaI.js → ensureCompleteData-DNKEGRiP.js} +12 -32
- package/dist/{ensureCompleteData-DlmibgaI.js.map → ensureCompleteData-DNKEGRiP.js.map} +1 -1
- package/dist/{ensureCompleteData-DkQYPeDa.cjs → ensureCompleteData-I6nYmT8E.cjs} +2 -2
- package/dist/{ensureCompleteData-DkQYPeDa.cjs.map → ensureCompleteData-I6nYmT8E.cjs.map} +1 -1
- package/dist/{excelDownload-BOA-lskf.js → excelDownload-BEC1AyQW.js} +12 -2
- package/dist/{excelDownload-BOA-lskf.js.map → excelDownload-BEC1AyQW.js.map} +1 -1
- package/dist/excelDownload-BQpsCa62.cjs.map +1 -1
- package/dist/{fetchAndParseData-sapWbnYk.js → fetchAndParseData-BpqkBPQL.js} +15 -28
- package/dist/{fetchAndParseData-sapWbnYk.js.map → fetchAndParseData-BpqkBPQL.js.map} +1 -1
- package/dist/fetchAndParseData-l5HGMAEs.cjs +16 -0
- package/dist/{fetchAndParseData-Ba-_CgxS.cjs.map → fetchAndParseData-l5HGMAEs.cjs.map} +1 -1
- package/dist/fetchAndParseData.cjs +1 -1
- package/dist/fetchAndParseData.js +1 -1
- package/dist/{filterData-9nEcQ-Jp.js → filterData-DsAiFzKY.js} +3 -5
- package/dist/{filterData-9nEcQ-Jp.js.map → filterData-DsAiFzKY.js.map} +1 -1
- package/dist/{filterData-BoYadk0l.cjs → filterData-T5DQBE9b.cjs} +2 -2
- package/dist/{filterData-BoYadk0l.cjs.map → filterData-T5DQBE9b.cjs.map} +1 -1
- package/dist/generateRandomString-B5zBiJzS.cjs.map +1 -1
- package/dist/generateRandomString-za3IQGfQ.js.map +1 -1
- package/dist/{getCentroidCoordinates-Dfk6IqEG.js → getCentroidCoordinates-D7r34N4w.js} +2 -2
- package/dist/{getCentroidCoordinates-Dfk6IqEG.js.map → getCentroidCoordinates-D7r34N4w.js.map} +1 -1
- package/dist/{getCentroidCoordinates-DxTBqzp2.cjs → getCentroidCoordinates-Dng1HVjO.cjs} +2 -2
- package/dist/{getCentroidCoordinates-DxTBqzp2.cjs.map → getCentroidCoordinates-Dng1HVjO.cjs.map} +1 -1
- package/dist/getGraphList-BpEWn1Tk.js +227 -0
- package/dist/{getGraphList-DuColTJM.js.map → getGraphList-BpEWn1Tk.js.map} +1 -1
- package/dist/getGraphList-gf02xgT2.cjs.map +1 -1
- package/dist/getJenks-BbngDoBQ.js.map +1 -1
- package/dist/getJenks-GYmdwBqm.cjs.map +1 -1
- package/dist/getSchema.cjs.map +1 -1
- package/dist/getSchema.js +445 -231
- package/dist/getSchema.js.map +1 -1
- package/dist/getSliderMarks-BmADcPQt.cjs +6 -0
- package/dist/getSliderMarks-BmADcPQt.cjs.map +1 -0
- package/dist/getSliderMarks-HIDJ0_Cd.js +1033 -0
- package/dist/getSliderMarks-HIDJ0_Cd.js.map +1 -0
- package/dist/{getTextColorBasedOnBgColor-B6Nk2WBf.js → getTextColorBasedOnBgColor-CDY808zi.js} +11 -3
- package/dist/{getTextColorBasedOnBgColor-B6Nk2WBf.js.map → getTextColorBasedOnBgColor-CDY808zi.js.map} +1 -1
- package/dist/getTextColorBasedOnBgColor-nqY-bsM_.cjs.map +1 -1
- package/dist/{getUniqValue-DiCh_MOD.js → getUniqValue-BKHCm3zE.js} +2 -4
- package/dist/{getUniqValue-DiCh_MOD.js.map → getUniqValue-BKHCm3zE.js.map} +1 -1
- package/dist/getUniqValue-RViz8tTw.cjs.map +1 -1
- package/dist/{imageDownload-Dcci2LEy.js → imageDownload-BX6SILNZ.js} +4 -2
- package/dist/{imageDownload-Dcci2LEy.js.map → imageDownload-BX6SILNZ.js.map} +1 -1
- package/dist/imageDownload-CgDcm1Sj.cjs.map +1 -1
- package/dist/{index-DvVprvy6.js → index-BZQYSqar.js} +7 -7
- package/dist/{index-DvVprvy6.js.map → index-BZQYSqar.js.map} +1 -1
- package/dist/index-B_sAFsEV.cjs +2 -0
- package/dist/{index-BYzIB5V6.cjs.map → index-B_sAFsEV.cjs.map} +1 -1
- package/dist/index-BqfRwk1n.js +146 -0
- package/dist/index-BqfRwk1n.js.map +1 -0
- package/dist/{index-V_JXij1_.js → index-BuwmuDFJ.js} +3 -3
- package/dist/{index-V_JXij1_.js.map → index-BuwmuDFJ.js.map} +1 -1
- package/dist/index-CHPV5EwG-CTPQjnHt.cjs +84 -0
- package/dist/index-CHPV5EwG-CTPQjnHt.cjs.map +1 -0
- package/dist/{index-CHPV5EwG-BPSP-7Jg.js → index-CHPV5EwG-Curnpaqc.js} +937 -842
- package/dist/index-CHPV5EwG-Curnpaqc.js.map +1 -0
- package/dist/index-Cno4Q0YE.cjs +2 -0
- package/dist/{index-CQ3e6Ewi.cjs.map → index-Cno4Q0YE.cjs.map} +1 -1
- package/dist/{index-tvAyXPPW-DBlMKnNB.js → index-Cw8sCyo_-B2hEKjzG.js} +16 -16
- package/dist/{index-tvAyXPPW-DBlMKnNB.js.map → index-Cw8sCyo_-B2hEKjzG.js.map} +1 -1
- package/dist/index-Cw8sCyo_-BrHiWiRF.cjs +2 -0
- package/dist/index-Cw8sCyo_-BrHiWiRF.cjs.map +1 -0
- package/dist/index-CyZ1lmi_.cjs +2 -0
- package/dist/{index-D72cOtq7.cjs.map → index-CyZ1lmi_.cjs.map} +1 -1
- package/dist/index-D491FEn1.js +184 -0
- package/dist/index-D491FEn1.js.map +1 -0
- package/dist/index-DG2bgAva.cjs +10 -0
- package/dist/index-DG2bgAva.cjs.map +1 -0
- package/dist/index-DRXx7m-C.cjs +2 -0
- package/dist/index-DRXx7m-C.cjs.map +1 -0
- package/dist/index-DoY3Ga3W.cjs +2 -0
- package/dist/index-DoY3Ga3W.cjs.map +1 -0
- package/dist/index-DxXnJ8Ti.cjs +2 -0
- package/dist/index-DxXnJ8Ti.cjs.map +1 -0
- package/dist/{index-DG3YrCr5-D3FrrXj8.js → index-Dzc_aaI9-Bb7gobH_.js} +2 -2
- package/dist/{index-DG3YrCr5-D3FrrXj8.js.map → index-Dzc_aaI9-Bb7gobH_.js.map} +1 -1
- package/dist/{index-DG3YrCr5-v7rayV3N.cjs → index-Dzc_aaI9-BmkfPMyc.cjs} +2 -2
- package/dist/{index-DG3YrCr5-v7rayV3N.cjs.map → index-Dzc_aaI9-BmkfPMyc.cjs.map} +1 -1
- package/dist/{index-9tDEUqOZ.js → index-GEsywGxz.js} +9 -9
- package/dist/index-GEsywGxz.js.map +1 -0
- package/dist/index-SKgJALZg.js +99 -0
- package/dist/{index-DKCxu1Gh.js.map → index-SKgJALZg.js.map} +1 -1
- package/dist/index-leTnKT2q.js +329 -0
- package/dist/index-leTnKT2q.js.map +1 -0
- package/dist/index.cjs +1 -1
- package/dist/index.d.ts +19 -8
- package/dist/index.js +13 -13
- package/dist/{init-BhZylTFx.js → init-BJFW6EwE.js} +3 -3
- package/dist/{init-BhZylTFx.js.map → init-BJFW6EwE.js.map} +1 -1
- package/dist/{linear-BVckp9RD.cjs → linear-BwPAspcq.cjs} +2 -2
- package/dist/{linear-BVckp9RD.cjs.map → linear-BwPAspcq.cjs.map} +1 -1
- package/dist/{linear-DUdu7l2G.js → linear-BwnDd9KF.js} +3 -3
- package/dist/{linear-DUdu7l2G.js.map → linear-BwnDd9KF.js.map} +1 -1
- package/dist/numberFormattingFunction-02t-wJta.cjs.map +1 -1
- package/dist/numberFormattingFunction-14YCbkN2.js.map +1 -1
- package/dist/{ordinal-BOeNbyae.cjs → ordinal-CrsysVE-.cjs} +2 -2
- package/dist/ordinal-CrsysVE-.cjs.map +1 -0
- package/dist/{ordinal-w9Lu4Stb.js → ordinal-P77xw8aL.js} +24 -24
- package/dist/ordinal-P77xw8aL.js.map +1 -0
- package/dist/{pow-e8zx3AQJ.js → pow-DE4c7dbW.js} +3 -3
- package/dist/{pow-e8zx3AQJ.js.map → pow-DE4c7dbW.js.map} +1 -1
- package/dist/{pow-B5-jkdHU.cjs → pow-DgrUorRi.cjs} +2 -2
- package/dist/{pow-B5-jkdHU.cjs.map → pow-DgrUorRi.cjs.map} +1 -1
- package/dist/{proxy-CkpFesk1.js → proxy-BxkFHwUw.js} +144 -134
- package/dist/proxy-BxkFHwUw.js.map +1 -0
- package/dist/proxy-BxvUI_9l.cjs +2 -0
- package/dist/proxy-BxvUI_9l.cjs.map +1 -0
- package/dist/{removeOutliers-DR48e-18.js → removeOutliers-BqW0sPqj.js} +2 -5
- package/dist/{removeOutliers-DR48e-18.js.map → removeOutliers-BqW0sPqj.js.map} +1 -1
- package/dist/removeOutliers-WELHHqiI.cjs.map +1 -1
- package/dist/{sort-DfK1b0F5.js → sort-BIvMlUH1.js} +5 -5
- package/dist/{sort-DfK1b0F5.js.map → sort-BIvMlUH1.js.map} +1 -1
- package/dist/{string-CRoCZCYa.cjs → string-C-kRh1bQ.cjs} +2 -2
- package/dist/{string-CRoCZCYa.cjs.map → string-C-kRh1bQ.cjs.map} +1 -1
- package/dist/{string-B8KlVSPX.js → string-C_xJ4Wg4.js} +3 -3
- package/dist/{string-B8KlVSPX.js.map → string-C_xJ4Wg4.js.map} +1 -1
- package/dist/string2HTML-CPGr_I5E.cjs +3 -0
- package/dist/{string2HTML-z7CwHXcx.cjs.map → string2HTML-CPGr_I5E.cjs.map} +1 -1
- package/dist/{string2HTML-oFCROsus.js → string2HTML-DhG75NqA.js} +15 -9
- package/dist/{string2HTML-oFCROsus.js.map → string2HTML-DhG75NqA.js.map} +1 -1
- package/dist/style.css +1 -1
- package/dist/{svgDownload-C2-E3yf2.js → svgDownload-BAoarWNt.js} +4 -2
- package/dist/{svgDownload-C2-E3yf2.js.map → svgDownload-BAoarWNt.js.map} +1 -1
- package/dist/svgDownload-D9zEGjTF.cjs.map +1 -1
- package/dist/{threshold-DFfqcDMa.js → threshold-Bgr20hik.js} +2 -2
- package/dist/{threshold-DFfqcDMa.js.map → threshold-Bgr20hik.js.map} +1 -1
- package/dist/{time-Byw_jYQ7.cjs → time-CZd5YLSP.cjs} +2 -2
- package/dist/{time-Byw_jYQ7.cjs.map → time-CZd5YLSP.cjs.map} +1 -1
- package/dist/{time-BzJP5SPC.js → time-DCCfQk3V.js} +3 -3
- package/dist/{time-BzJP5SPC.js.map → time-DCCfQk3V.js.map} +1 -1
- package/dist/transformData.cjs +1 -1
- package/dist/transformData.js +3 -3
- package/dist/transformDataForAggregation-CE3bAlHU.js +585 -0
- package/dist/{transformDataForAggregation-sBpdlX8n.js.map → transformDataForAggregation-CE3bAlHU.js.map} +1 -1
- package/dist/transformDataForAggregation-KXGm6flX.cjs.map +1 -1
- package/dist/transformDataForGraphFromFile-BExxcITV.js +14 -0
- package/dist/{transformDataForGraphFromFile-ComYvzuz.js.map → transformDataForGraphFromFile-BExxcITV.js.map} +1 -1
- package/dist/{transformDataForGraphFromFile-DVZodTHd.cjs → transformDataForGraphFromFile-DaJHQCsL.cjs} +2 -2
- package/dist/{transformDataForGraphFromFile-DVZodTHd.cjs.map → transformDataForGraphFromFile-DaJHQCsL.cjs.map} +1 -1
- package/dist/transformDataForSelect-D8AuvYdf.js.map +1 -1
- package/dist/transformDataForSelect-YmStusCI.cjs.map +1 -1
- package/dist/uniqBy-BHy4I8PK.js.map +1 -1
- package/dist/uniqBy-O05lp2S5.cjs.map +1 -1
- package/dist/{use-in-view-yS6jzJAp.js → use-in-view-Cxa7y1TH.js} +2 -2
- package/dist/use-in-view-Cxa7y1TH.js.map +1 -0
- package/dist/use-in-view-QcfiW0w3.cjs +2 -0
- package/dist/use-in-view-QcfiW0w3.cjs.map +1 -0
- package/dist/utils.cjs +1 -1
- package/dist/utils.js +8 -8
- package/dist/validateSchema.cjs.map +1 -1
- package/dist/validateSchema.js +33 -29
- package/dist/validateSchema.js.map +1 -1
- package/dist/{x-BBpi7a_7-Dz2vKSfu.cjs → x-BBpi7a_7-mTo40uId.cjs} +2 -2
- package/dist/{x-BBpi7a_7-Dz2vKSfu.cjs.map → x-BBpi7a_7-mTo40uId.cjs.map} +1 -1
- package/dist/{y-D0sAaVii.js → y-BqfogMAB.js} +3 -3
- package/dist/{y-D0sAaVii.js.map → y-BqfogMAB.js.map} +1 -1
- package/dist/{zoom-QipiAl5W.js → zoom-C9MFjAaV.js} +5 -5
- package/dist/{zoom-QipiAl5W.js.map → zoom-C9MFjAaV.js.map} +1 -1
- package/dist/zoom-DPw8bba-.cjs +2 -0
- package/dist/{zoom-BiMNsz72.cjs.map → zoom-DPw8bba-.cjs.map} +1 -1
- package/package.json +9 -8
- package/dist/Axis-DE7dSn1_.cjs +0 -2
- package/dist/Axis-DE7dSn1_.cjs.map +0 -1
- package/dist/Axis-Ddg-seDi.js +0 -43
- package/dist/Axis-Ddg-seDi.js.map +0 -1
- package/dist/AxisTitle-BmHLMRJZ.js +0 -20
- package/dist/AxisTitle-BmHLMRJZ.js.map +0 -1
- package/dist/AxisTitle-CK9YeovX.cjs +0 -2
- package/dist/AxisTitle-CK9YeovX.cjs.map +0 -1
- package/dist/DropdownSelect-CtOKZHD0.js.map +0 -1
- package/dist/DropdownSelect-DBDM64B5.cjs +0 -29
- package/dist/DropdownSelect-DBDM64B5.cjs.map +0 -1
- package/dist/EmptyState-DdTp-Mdn.js +0 -22
- package/dist/EmptyState-d8_8SxeW.cjs +0 -2
- package/dist/GraphEl-C6yjl1VM.cjs +0 -2
- package/dist/GraphEl-C6yjl1VM.cjs.map +0 -1
- package/dist/GraphEl-CqWzvOyr.js.map +0 -1
- package/dist/Modal-DVVwpKhP.js +0 -1019
- package/dist/Modal-DVVwpKhP.js.map +0 -1
- package/dist/Modal-tXZlLE5s.cjs +0 -46
- package/dist/Modal-tXZlLE5s.cjs.map +0 -1
- package/dist/ReferenceLine-CFVBBN__.cjs +0 -2
- package/dist/ReferenceLine-CFVBBN__.cjs.map +0 -1
- package/dist/ReferenceLine-CfAW3vKJ.js +0 -128
- package/dist/ReferenceLine-CfAW3vKJ.js.map +0 -1
- package/dist/RegressionLine-C2--oMQq.js +0 -49
- package/dist/RegressionLine-C2--oMQq.js.map +0 -1
- package/dist/RegressionLine-Dj0GSiAp.cjs +0 -2
- package/dist/RegressionLine-Dj0GSiAp.cjs.map +0 -1
- package/dist/Spinner-C85UF28E.js +0 -30
- package/dist/Spinner-C85UF28E.js.map +0 -1
- package/dist/Spinner-DA6Z5E4n.cjs +0 -2
- package/dist/Spinner-DA6Z5E4n.cjs.map +0 -1
- package/dist/Tooltip-CVCGWyzw.js +0 -46
- package/dist/Tooltip-CVCGWyzw.js.map +0 -1
- package/dist/Tooltip-De16GWhY.cjs +0 -2
- package/dist/Tooltip-De16GWhY.cjs.map +0 -1
- package/dist/Typography-Ctgfl1J5.js +0 -140
- package/dist/Typography-Ctgfl1J5.js.map +0 -1
- package/dist/Typography-k-kOjICQ.cjs +0 -2
- package/dist/Typography-k-kOjICQ.cjs.map +0 -1
- package/dist/XAxesLabels-Drf7M3YK.cjs +0 -2
- package/dist/XAxesLabels-Drf7M3YK.cjs.map +0 -1
- package/dist/XAxesLabels-loO78vUO.js +0 -57
- package/dist/XAxesLabels-loO78vUO.js.map +0 -1
- package/dist/XTicksAndGridLines-Bn9u5gOM.js +0 -56
- package/dist/XTicksAndGridLines-Bn9u5gOM.js.map +0 -1
- package/dist/XTicksAndGridLines-CCzXIV8d.cjs +0 -2
- package/dist/XTicksAndGridLines-CCzXIV8d.cjs.map +0 -1
- package/dist/YAxesLabels-DECkMgq8.js +0 -52
- package/dist/YAxesLabels-DECkMgq8.js.map +0 -1
- package/dist/YAxesLabels-yRFFdx1s.cjs +0 -2
- package/dist/YAxesLabels-yRFFdx1s.cjs.map +0 -1
- package/dist/YTicksAndGridLines-B6ah7CRf.js +0 -56
- package/dist/YTicksAndGridLines-B6ah7CRf.js.map +0 -1
- package/dist/YTicksAndGridLines-DBDuz6vb.cjs +0 -2
- package/dist/YTicksAndGridLines-DBDuz6vb.cjs.map +0 -1
- package/dist/checkIfMultiple-BXbHUCWM.cjs +0 -12
- package/dist/checkIfMultiple-BXbHUCWM.cjs.map +0 -1
- package/dist/checkIfMultiple-ChTJk2Tk.js +0 -912
- package/dist/checkIfMultiple-ChTJk2Tk.js.map +0 -1
- package/dist/customArea-B-dWU0zZ.js +0 -175
- package/dist/customArea-CK768gCn.cjs +0 -2
- package/dist/fetchAndParseData-Ba-_CgxS.cjs +0 -16
- package/dist/getGraphList-DuColTJM.js +0 -265
- package/dist/getSliderMarks-9cNoRkDx.js +0 -1023
- package/dist/getSliderMarks-9cNoRkDx.js.map +0 -1
- package/dist/getSliderMarks-CRIbTGYV.cjs +0 -6
- package/dist/getSliderMarks-CRIbTGYV.cjs.map +0 -1
- package/dist/index-37q0ULNQ.js +0 -430
- package/dist/index-37q0ULNQ.js.map +0 -1
- package/dist/index-9tDEUqOZ.js.map +0 -1
- package/dist/index-BW8iNx7E.cjs +0 -10
- package/dist/index-BW8iNx7E.cjs.map +0 -1
- package/dist/index-BW_-wD2k.cjs +0 -2
- package/dist/index-BW_-wD2k.cjs.map +0 -1
- package/dist/index-BYzIB5V6.cjs +0 -2
- package/dist/index-BmCqpO1B.js +0 -342
- package/dist/index-BmCqpO1B.js.map +0 -1
- package/dist/index-CHPV5EwG-BPSP-7Jg.js.map +0 -1
- package/dist/index-CHPV5EwG-DDoeWRVt.cjs +0 -44
- package/dist/index-CHPV5EwG-DDoeWRVt.cjs.map +0 -1
- package/dist/index-CNvov0eg.js +0 -122
- package/dist/index-CNvov0eg.js.map +0 -1
- package/dist/index-CQ3e6Ewi.cjs +0 -2
- package/dist/index-CVlCtJbC.cjs +0 -2
- package/dist/index-CVlCtJbC.cjs.map +0 -1
- package/dist/index-CoZbeNM9.cjs +0 -2
- package/dist/index-CoZbeNM9.cjs.map +0 -1
- package/dist/index-D72cOtq7.cjs +0 -2
- package/dist/index-DKCxu1Gh.js +0 -77
- package/dist/index-tvAyXPPW-DPOG-C2i.cjs +0 -2
- package/dist/index-tvAyXPPW-DPOG-C2i.cjs.map +0 -1
- package/dist/ordinal-BOeNbyae.cjs.map +0 -1
- package/dist/ordinal-w9Lu4Stb.js.map +0 -1
- package/dist/proxy-BHRoeZgd.cjs +0 -2
- package/dist/proxy-BHRoeZgd.cjs.map +0 -1
- package/dist/proxy-CkpFesk1.js.map +0 -1
- package/dist/string2HTML-z7CwHXcx.cjs +0 -3
- package/dist/transformDataForAggregation-sBpdlX8n.js +0 -755
- package/dist/transformDataForGraphFromFile-ComYvzuz.js +0 -24
- package/dist/use-in-view-sQJZ_xDO.cjs +0 -2
- package/dist/use-in-view-sQJZ_xDO.cjs.map +0 -1
- package/dist/use-in-view-yS6jzJAp.js.map +0 -1
- package/dist/zoom-BiMNsz72.cjs +0 -2
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"EmptyState-
|
|
1
|
+
{"version":3,"file":"EmptyState-BZo1BbAn.js","sources":["../src/Components/Elements/EmptyState.tsx"],"sourcesContent":["import { P } from '@undp/design-system-react/Typography';\r\n\r\nimport { Alert } from '@/Components/Icons';\r\n\r\nexport function EmptyState() {\r\n return (\r\n <div className='flex w-full flex-col justify-center grow items-center gap-2 p-6'>\r\n <Alert />\r\n <P\r\n marginBottom='none'\r\n leading='none'\r\n size='lg'\r\n className='text-primary-gray-550 dark:text-primary-gray-550'\r\n >\r\n No data available\r\n </P>\r\n </div>\r\n );\r\n}\r\n"],"names":["EmptyState","$","_c","t0","Symbol","for","jsxs","jsx","Alert","P"],"mappings":";;;AAIO,SAAAA,IAAA;AAAA,QAAAC,IAAAC,EAAAA,EAAA,CAAA;AAAA,MAAAC;AAAA,SAAAF,EAAA,CAAA,MAAAG,OAAAC,IAAA,2BAAA,KAEHF,IAAAG,gBAAAA,EAAAA,KAAA,OAAA,EAAe,WAAA,mEACb,UAAA;AAAA,IAAAC,gBAAAA,EAAAA,IAACC,GAAA,EAAK;AAAA,IACND,gBAAAA,EAAAA,IAACE,GAAA,EACc,cAAA,QACL,SAAA,QACH,MAAA,MACK,WAAA,oDACX,UAAA,oBAAA,CAED;AAAA,EAAA,GACF,GAAMR,OAAAE,KAAAA,IAAAF,EAAA,CAAA,GAVNE;AAUM;"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";const t=require("./index-CHPV5EwG-CTPQjnHt.cjs"),s=require("./Typography-DX7PlgQU.cjs"),i=require("./index-DRXx7m-C.cjs");function n(){const r=t.compilerRuntimeExports.c(1);let e;return r[0]===Symbol.for("react.memo_cache_sentinel")?(e=t.jsxRuntimeExports.jsxs("div",{className:"flex w-full flex-col justify-center grow items-center gap-2 p-6",children:[t.jsxRuntimeExports.jsx(i.Alert,{}),t.jsxRuntimeExports.jsx(s.j,{marginBottom:"none",leading:"none",size:"lg",className:"text-primary-gray-550 dark:text-primary-gray-550",children:"No data available"})]}),r[0]=e):e=r[0],e}exports.EmptyState=n;
|
|
2
|
+
//# sourceMappingURL=EmptyState-sAEZ_5rU.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"EmptyState-
|
|
1
|
+
{"version":3,"file":"EmptyState-sAEZ_5rU.cjs","sources":["../src/Components/Elements/EmptyState.tsx"],"sourcesContent":["import { P } from '@undp/design-system-react/Typography';\r\n\r\nimport { Alert } from '@/Components/Icons';\r\n\r\nexport function EmptyState() {\r\n return (\r\n <div className='flex w-full flex-col justify-center grow items-center gap-2 p-6'>\r\n <Alert />\r\n <P\r\n marginBottom='none'\r\n leading='none'\r\n size='lg'\r\n className='text-primary-gray-550 dark:text-primary-gray-550'\r\n >\r\n No data available\r\n </P>\r\n </div>\r\n );\r\n}\r\n"],"names":["EmptyState","$","_c","t0","Symbol","for","jsxs","jsx","Alert","P"],"mappings":"uIAIO,SAAAA,GAAA,CAAA,MAAAC,EAAAC,EAAAA,uBAAAA,EAAA,CAAA,EAAA,IAAAC,EAAA,OAAAF,EAAA,CAAA,IAAAG,OAAAC,IAAA,2BAAA,GAEHF,EAAAG,EAAAA,kBAAAA,KAAA,MAAA,CAAe,UAAA,kEACb,SAAA,CAAAC,EAAAA,kBAAAA,IAACC,EAAAA,MAAA,EAAK,EACND,EAAAA,kBAAAA,IAACE,EAAAA,EAAA,CACc,aAAA,OACL,QAAA,OACH,KAAA,KACK,UAAA,mDACX,SAAA,mBAAA,CAED,CAAA,EACF,EAAMR,KAAAE,GAAAA,EAAAF,EAAA,CAAA,EAVNE,CAUM"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const u=require("./index-CHPV5EwG-CTPQjnHt.cjs"),b=require("./index-DRXx7m-C.cjs"),y=require("./excelDownload-BQpsCa62.cjs");function D(f){const e=u.compilerRuntimeExports.c(13),{buttonContent:n,buttonType:m,csvData:s,fileName:p,headers:a,xlsxHeader:i,wscols:c,buttonSmall:v,className:w}=f,r=m===void 0?"tertiary":m,x=p===void 0?"data":p,d=`${v?"p-2":"py-4 px-6"} ${w===void 0?"":w}`;let t;e[0]!==s||e[1]!==x||e[2]!==a||e[3]!==c||e[4]!==i?(t=()=>y.excelDownload(s,x,a,i,c),e[0]=s,e[1]=x,e[2]=a,e[3]=c,e[4]=i,e[5]=t):t=e[5];let o;e[6]!==n?(o=n||u.jsxRuntimeExports.jsx(b.FileDown,{}),e[6]=n,e[7]=o):o=e[7];let l;return e[8]!==r||e[9]!==d||e[10]!==t||e[11]!==o?(l=u.jsxRuntimeExports.jsx(b.x,{variant:r,className:d,onClick:t,"aria-label":"Click to download the data as xlsx",children:o}),e[8]=r,e[9]=d,e[10]=t,e[11]=o,e[12]=l):l=e[12],l}exports.ExcelDownloadButton=D;
|
|
2
2
|
//# sourceMappingURL=ExcelDownloadButton.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ExcelDownloadButton.cjs","sources":["../src/Components/Actions/ExcelDownloadButton.tsx"],"sourcesContent":["import { Button } from '@undp/design-system-react/Button';\r\nimport { JSX } from 'react';\r\n\r\nimport { excelDownload } from '@/Utils/excelDownload';\r\nimport { FileDown } from '@/Components/Icons';\r\n\r\ninterface WsColInterface {\r\n wch: number;\r\n}\r\n\r\ninterface Props {\r\n buttonContent?: string | JSX.Element;\r\n buttonType?:\r\n | 'primary'\r\n | 'primary-without-icon'\r\n | 'secondary'\r\n | 'secondary-without-icon'\r\n | 'tertiary';\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n csvData: any;\r\n fileName?: string;\r\n headers: string[];\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n xlsxHeader: any;\r\n wscols: WsColInterface[];\r\n buttonSmall?: boolean;\r\n className?: string;\r\n}\r\n\r\nexport function ExcelDownloadButton(props: Props) {\r\n const {\r\n buttonContent,\r\n buttonType = 'tertiary',\r\n csvData,\r\n fileName = 'data',\r\n headers,\r\n xlsxHeader,\r\n wscols,\r\n buttonSmall,\r\n className = '',\r\n } = props;\r\n return (\r\n <Button\r\n variant={buttonType}\r\n className={`${buttonSmall ? 'p-2' : 'py-4 px-6'} ${className}`}\r\n onClick={() => excelDownload(csvData, fileName, headers, xlsxHeader, wscols)}\r\n aria-label='Click to download the data as xlsx'\r\n >\r\n {buttonContent || <FileDown />}\r\n </Button>\r\n );\r\n}\r\n"],"names":["ExcelDownloadButton","props","buttonContent","buttonType","csvData","fileName","headers","xlsxHeader","wscols","buttonSmall","className","
|
|
1
|
+
{"version":3,"file":"ExcelDownloadButton.cjs","sources":["../src/Components/Actions/ExcelDownloadButton.tsx"],"sourcesContent":["import { Button } from '@undp/design-system-react/Button';\r\nimport { JSX } from 'react';\r\n\r\nimport { excelDownload } from '@/Utils/excelDownload';\r\nimport { FileDown } from '@/Components/Icons';\r\n\r\ninterface WsColInterface {\r\n wch: number;\r\n}\r\n\r\ninterface Props {\r\n buttonContent?: string | JSX.Element;\r\n buttonType?:\r\n | 'primary'\r\n | 'primary-without-icon'\r\n | 'secondary'\r\n | 'secondary-without-icon'\r\n | 'tertiary';\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n csvData: any;\r\n fileName?: string;\r\n headers: string[];\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n xlsxHeader: any;\r\n wscols: WsColInterface[];\r\n buttonSmall?: boolean;\r\n className?: string;\r\n}\r\n\r\nexport function ExcelDownloadButton(props: Props) {\r\n const {\r\n buttonContent,\r\n buttonType = 'tertiary',\r\n csvData,\r\n fileName = 'data',\r\n headers,\r\n xlsxHeader,\r\n wscols,\r\n buttonSmall,\r\n className = '',\r\n } = props;\r\n return (\r\n <Button\r\n variant={buttonType}\r\n className={`${buttonSmall ? 'p-2' : 'py-4 px-6'} ${className}`}\r\n onClick={() => excelDownload(csvData, fileName, headers, xlsxHeader, wscols)}\r\n aria-label='Click to download the data as xlsx'\r\n >\r\n {buttonContent || <FileDown />}\r\n </Button>\r\n );\r\n}\r\n"],"names":["ExcelDownloadButton","props","$","_c","buttonContent","buttonType","t0","csvData","fileName","t1","headers","xlsxHeader","wscols","buttonSmall","className","t2","undefined","t3","t4","excelDownload","t5","FileDown","t6","jsx","Button"],"mappings":"6MA6BO,SAAAA,EAAAC,EAAA,CAAA,MAAAC,EAAAC,EAAAA,uBAAAA,EAAA,EAAA,EACL,CAAAC,cAAAA,EAAAC,WAAAC,EAAAC,QAAAA,EAAAC,SAAAC,EAAAC,QAAAA,EAAAC,WAAAA,EAAAC,OAAAA,EAAAC,YAAAA,EAAAC,UAAAC,CAAAA,EAUId,EARFI,EAAAC,IAAAU,OAAA,WAAAV,EAEAE,EAAAC,IAAAO,OAAA,OAAAP,EAUaQ,KAAGJ,EAAA,MAAA,WAAiC,IALjDE,IAAAC,OAAA,GAAAD,CAK8D,GAAE,IAAAG,EAAAhB,EAAA,CAAA,IAAAK,GAAAL,EAAA,CAAA,IAAAM,GAAAN,EAAA,CAAA,IAAAQ,GAAAR,EAAA,CAAA,IAAAU,GAAAV,OAAAS,GACrDO,EAAAA,IAAMC,EAAAA,cAAcZ,EAASC,EAAUE,EAASC,EAAYC,CAAM,EAACV,KAAAK,EAAAL,KAAAM,EAAAN,KAAAQ,EAAAR,KAAAU,EAAAV,KAAAS,EAAAT,KAAAgB,GAAAA,EAAAhB,EAAA,CAAA,EAAA,IAAAkB,EAAAlB,OAAAE,GAG3EgB,EAAAhB,2BAAkBiB,EAAAA,SAAA,CAAA,CAAQ,EAAGnB,KAAAE,EAAAF,KAAAkB,GAAAA,EAAAlB,EAAA,CAAA,EAAA,IAAAoB,EAAA,OAAApB,EAAA,CAAA,IAAAG,GAAAH,EAAA,CAAA,IAAAe,GAAAf,EAAA,EAAA,IAAAgB,GAAAhB,QAAAkB,GANhCE,EAAAC,EAAAA,kBAAAA,IAACC,EAAAA,EAAA,CACUnB,QAAAA,EACE,UAAAY,EACF,QAAAC,EACE,aAAA,qCAEVE,SAAAA,CAAAA,CACH,EAASlB,KAAAG,EAAAH,KAAAe,EAAAf,MAAAgB,EAAAhB,MAAAkB,EAAAlB,MAAAoB,GAAAA,EAAApB,EAAA,EAAA,EAPToB,CAOS"}
|
|
@@ -1,30 +1,26 @@
|
|
|
1
|
-
import { j as
|
|
2
|
-
import { d as
|
|
3
|
-
import { e as
|
|
4
|
-
function
|
|
5
|
-
const {
|
|
6
|
-
buttonContent:
|
|
7
|
-
buttonType:
|
|
1
|
+
import { c as v, j as u } from "./index-CHPV5EwG-Curnpaqc.js";
|
|
2
|
+
import { d as w, x as j } from "./index-D491FEn1.js";
|
|
3
|
+
import { e as y } from "./excelDownload-BEC1AyQW.js";
|
|
4
|
+
function $(N) {
|
|
5
|
+
const t = v.c(13), {
|
|
6
|
+
buttonContent: s,
|
|
7
|
+
buttonType: d,
|
|
8
8
|
csvData: l,
|
|
9
|
-
fileName:
|
|
9
|
+
fileName: p,
|
|
10
10
|
headers: n,
|
|
11
|
-
xlsxHeader:
|
|
12
|
-
wscols:
|
|
13
|
-
buttonSmall:
|
|
14
|
-
className:
|
|
15
|
-
} =
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
"aria-label": "Click to download the data as xlsx",
|
|
23
|
-
children: o || /* @__PURE__ */ a.jsx(d, {})
|
|
24
|
-
}
|
|
25
|
-
);
|
|
11
|
+
xlsxHeader: i,
|
|
12
|
+
wscols: c,
|
|
13
|
+
buttonSmall: b,
|
|
14
|
+
className: f
|
|
15
|
+
} = N, r = d === void 0 ? "tertiary" : d, m = p === void 0 ? "data" : p, x = `${b ? "p-2" : "py-4 px-6"} ${f === void 0 ? "" : f}`;
|
|
16
|
+
let e;
|
|
17
|
+
t[0] !== l || t[1] !== m || t[2] !== n || t[3] !== c || t[4] !== i ? (e = () => y(l, m, n, i, c), t[0] = l, t[1] = m, t[2] = n, t[3] = c, t[4] = i, t[5] = e) : e = t[5];
|
|
18
|
+
let o;
|
|
19
|
+
t[6] !== s ? (o = s || /* @__PURE__ */ u.jsx(w, {}), t[6] = s, t[7] = o) : o = t[7];
|
|
20
|
+
let a;
|
|
21
|
+
return t[8] !== r || t[9] !== x || t[10] !== e || t[11] !== o ? (a = /* @__PURE__ */ u.jsx(j, { variant: r, className: x, onClick: e, "aria-label": "Click to download the data as xlsx", children: o }), t[8] = r, t[9] = x, t[10] = e, t[11] = o, t[12] = a) : a = t[12], a;
|
|
26
22
|
}
|
|
27
23
|
export {
|
|
28
|
-
|
|
24
|
+
$ as ExcelDownloadButton
|
|
29
25
|
};
|
|
30
26
|
//# sourceMappingURL=ExcelDownloadButton.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ExcelDownloadButton.js","sources":["../src/Components/Actions/ExcelDownloadButton.tsx"],"sourcesContent":["import { Button } from '@undp/design-system-react/Button';\r\nimport { JSX } from 'react';\r\n\r\nimport { excelDownload } from '@/Utils/excelDownload';\r\nimport { FileDown } from '@/Components/Icons';\r\n\r\ninterface WsColInterface {\r\n wch: number;\r\n}\r\n\r\ninterface Props {\r\n buttonContent?: string | JSX.Element;\r\n buttonType?:\r\n | 'primary'\r\n | 'primary-without-icon'\r\n | 'secondary'\r\n | 'secondary-without-icon'\r\n | 'tertiary';\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n csvData: any;\r\n fileName?: string;\r\n headers: string[];\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n xlsxHeader: any;\r\n wscols: WsColInterface[];\r\n buttonSmall?: boolean;\r\n className?: string;\r\n}\r\n\r\nexport function ExcelDownloadButton(props: Props) {\r\n const {\r\n buttonContent,\r\n buttonType = 'tertiary',\r\n csvData,\r\n fileName = 'data',\r\n headers,\r\n xlsxHeader,\r\n wscols,\r\n buttonSmall,\r\n className = '',\r\n } = props;\r\n return (\r\n <Button\r\n variant={buttonType}\r\n className={`${buttonSmall ? 'p-2' : 'py-4 px-6'} ${className}`}\r\n onClick={() => excelDownload(csvData, fileName, headers, xlsxHeader, wscols)}\r\n aria-label='Click to download the data as xlsx'\r\n >\r\n {buttonContent || <FileDown />}\r\n </Button>\r\n );\r\n}\r\n"],"names":["ExcelDownloadButton","props","buttonContent","buttonType","csvData","fileName","headers","xlsxHeader","wscols","buttonSmall","className","
|
|
1
|
+
{"version":3,"file":"ExcelDownloadButton.js","sources":["../src/Components/Actions/ExcelDownloadButton.tsx"],"sourcesContent":["import { Button } from '@undp/design-system-react/Button';\r\nimport { JSX } from 'react';\r\n\r\nimport { excelDownload } from '@/Utils/excelDownload';\r\nimport { FileDown } from '@/Components/Icons';\r\n\r\ninterface WsColInterface {\r\n wch: number;\r\n}\r\n\r\ninterface Props {\r\n buttonContent?: string | JSX.Element;\r\n buttonType?:\r\n | 'primary'\r\n | 'primary-without-icon'\r\n | 'secondary'\r\n | 'secondary-without-icon'\r\n | 'tertiary';\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n csvData: any;\r\n fileName?: string;\r\n headers: string[];\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n xlsxHeader: any;\r\n wscols: WsColInterface[];\r\n buttonSmall?: boolean;\r\n className?: string;\r\n}\r\n\r\nexport function ExcelDownloadButton(props: Props) {\r\n const {\r\n buttonContent,\r\n buttonType = 'tertiary',\r\n csvData,\r\n fileName = 'data',\r\n headers,\r\n xlsxHeader,\r\n wscols,\r\n buttonSmall,\r\n className = '',\r\n } = props;\r\n return (\r\n <Button\r\n variant={buttonType}\r\n className={`${buttonSmall ? 'p-2' : 'py-4 px-6'} ${className}`}\r\n onClick={() => excelDownload(csvData, fileName, headers, xlsxHeader, wscols)}\r\n aria-label='Click to download the data as xlsx'\r\n >\r\n {buttonContent || <FileDown />}\r\n </Button>\r\n );\r\n}\r\n"],"names":["ExcelDownloadButton","props","$","_c","buttonContent","buttonType","t0","csvData","fileName","t1","headers","xlsxHeader","wscols","buttonSmall","className","t2","undefined","t3","t4","excelDownload","t5","FileDown","t6","jsx","Button"],"mappings":";;;AA6BO,SAAAA,EAAAC,GAAA;AAAA,QAAAC,IAAAC,EAAAA,EAAA,EAAA,GACL;AAAA,IAAAC,eAAAA;AAAAA,IAAAC,YAAAC;AAAAA,IAAAC,SAAAA;AAAAA,IAAAC,UAAAC;AAAAA,IAAAC,SAAAA;AAAAA,IAAAC,YAAAA;AAAAA,IAAAC,QAAAA;AAAAA,IAAAC,aAAAA;AAAAA,IAAAC,WAAAC;AAAAA,EAAAA,IAUId,GARFI,IAAAC,MAAAU,SAAA,aAAAV,GAEAE,IAAAC,MAAAO,SAAA,SAAAP,GAUaQ,OAAGJ,IAAA,QAAA,WAAiC,IALjDE,MAAAC,SAAA,KAAAD,CAK8D;AAAE,MAAAG;AAAA,EAAAhB,EAAA,CAAA,MAAAK,KAAAL,EAAA,CAAA,MAAAM,KAAAN,EAAA,CAAA,MAAAQ,KAAAR,EAAA,CAAA,MAAAU,KAAAV,SAAAS,KACrDO,IAAAA,MAAMC,EAAcZ,GAASC,GAAUE,GAASC,GAAYC,CAAM,GAACV,OAAAK,GAAAL,OAAAM,GAAAN,OAAAQ,GAAAR,OAAAU,GAAAV,OAAAS,GAAAT,OAAAgB,KAAAA,IAAAhB,EAAA,CAAA;AAAA,MAAAkB;AAAA,EAAAlB,SAAAE,KAG3EgB,IAAAhB,2BAAkBiB,GAAA,CAAA,CAAQ,GAAGnB,OAAAE,GAAAF,OAAAkB,KAAAA,IAAAlB,EAAA,CAAA;AAAA,MAAAoB;AAAA,SAAApB,EAAA,CAAA,MAAAG,KAAAH,EAAA,CAAA,MAAAe,KAAAf,EAAA,EAAA,MAAAgB,KAAAhB,UAAAkB,KANhCE,IAAAC,gBAAAA,EAAAA,IAACC,GAAA,EACUnB,SAAAA,GACE,WAAAY,GACF,SAAAC,GACE,cAAA,sCAEVE,UAAAA,EAAAA,CACH,GAASlB,OAAAG,GAAAH,OAAAe,GAAAf,QAAAgB,GAAAhB,QAAAkB,GAAAlB,QAAAoB,KAAAA,IAAApB,EAAA,EAAA,GAPToB;AAOS;"}
|
package/dist/FootNote.cjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("./index-CHPV5EwG-CTPQjnHt.cjs"),m=require("./Typography-DX7PlgQU.cjs"),u=require("react");function p(c){const e=a.compilerRuntimeExports.c(12),{text:r,style:n,className:o}=c;let s;e[0]!==n?(s=n===void 0?{}:n,e[0]=n,e[1]=s):s=e[1];const i=s;if(typeof r=="string"){if(r.trim()==="")return null;let t;e[2]!==o?(t=a.mo("text-primary-gray-550 dark:text-primary-gray-40",o),e[2]=o,e[3]=t):t=e[3];let l;return e[4]!==i||e[5]!==t||e[6]!==r?(l=a.jsxRuntimeExports.jsx(m.j,{size:"sm",marginBottom:"none",className:t,"aria-label":"Graph footnote",style:i,children:r}),e[4]=i,e[5]=t,e[6]=r,e[7]=l):l=e[7],l}if(u.isValidElement(r)){let t;return e[8]!==o||e[9]!==i||e[10]!==r?(t=a.jsxRuntimeExports.jsx("div",{className:o,style:i,children:r}),e[8]=o,e[9]=i,e[10]=r,e[11]=t):t=e[11],t}return console.error("FootNote: Invalid text type. Expected string or React element."),null}exports.FootNote=p;
|
|
2
2
|
//# sourceMappingURL=FootNote.cjs.map
|
package/dist/FootNote.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FootNote.cjs","sources":["../src/Components/Typography/FootNote.tsx"],"sourcesContent":["import { cn } from '@undp/design-system-react/cn';\r\nimport { P } from '@undp/design-system-react/Typography';\r\nimport React from 'react';\r\n\r\ninterface Props {\r\n text: string | React.ReactNode;\r\n style?: React.CSSProperties;\r\n className?: string;\r\n}\r\n\r\nexport function FootNote(props: Props) {\r\n const { text, style = {}, className } = props;\r\n if (typeof text === 'string') {\r\n if (text.trim() === '') return null;\r\n return (\r\n <P\r\n size='sm'\r\n marginBottom='none'\r\n className={cn('text-primary-gray-550 dark:text-primary-gray-40', className)}\r\n aria-label='Graph footnote'\r\n style={style}\r\n >\r\n {text}\r\n </P>\r\n );\r\n }\r\n if (React.isValidElement(text))\r\n return (\r\n <div className={className} style={style}>\r\n {text}\r\n </div>\r\n );\r\n console.error('FootNote: Invalid text type. Expected string or React element.');\r\n return null;\r\n}\r\n"],"names":["FootNote","props","text","style","className","
|
|
1
|
+
{"version":3,"file":"FootNote.cjs","sources":["../src/Components/Typography/FootNote.tsx"],"sourcesContent":["import { cn } from '@undp/design-system-react/cn';\r\nimport { P } from '@undp/design-system-react/Typography';\r\nimport React from 'react';\r\n\r\ninterface Props {\r\n text: string | React.ReactNode;\r\n style?: React.CSSProperties;\r\n className?: string;\r\n}\r\n\r\nexport function FootNote(props: Props) {\r\n const { text, style = {}, className } = props;\r\n if (typeof text === 'string') {\r\n if (text.trim() === '') return null;\r\n return (\r\n <P\r\n size='sm'\r\n marginBottom='none'\r\n className={cn('text-primary-gray-550 dark:text-primary-gray-40', className)}\r\n aria-label='Graph footnote'\r\n style={style}\r\n >\r\n {text}\r\n </P>\r\n );\r\n }\r\n if (React.isValidElement(text))\r\n return (\r\n <div className={className} style={style}>\r\n {text}\r\n </div>\r\n );\r\n console.error('FootNote: Invalid text type. Expected string or React element.');\r\n return null;\r\n}\r\n"],"names":["FootNote","props","$","_c","text","style","t0","className","t1","undefined","trim","t2","cn","t3","jsx","P","React","isValidElement","console","error"],"mappings":"2LAUO,SAAAA,EAAAC,EAAA,CAAA,MAAAC,EAAAC,EAAAA,uBAAAA,EAAA,EAAA,EACL,CAAAC,KAAAA,EAAAC,MAA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-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
1
|
+
import { c, m as f, j as a } from "./index-CHPV5EwG-Curnpaqc.js";
|
|
2
|
+
import { j as p } from "./Typography-PxtFcnJb.js";
|
|
3
|
+
import x from "react";
|
|
4
|
+
function g(m) {
|
|
5
|
+
const t = c.c(12), {
|
|
6
|
+
text: r,
|
|
7
|
+
style: l,
|
|
8
|
+
className: o
|
|
9
|
+
} = m;
|
|
10
|
+
let s;
|
|
11
|
+
t[0] !== l ? (s = l === void 0 ? {} : l, t[0] = l, t[1] = s) : s = t[1];
|
|
12
|
+
const i = s;
|
|
13
|
+
if (typeof r == "string") {
|
|
14
|
+
if (r.trim() === "")
|
|
15
|
+
return null;
|
|
16
|
+
let e;
|
|
17
|
+
t[2] !== o ? (e = f("text-primary-gray-550 dark:text-primary-gray-40", o), t[2] = o, t[3] = e) : e = t[3];
|
|
18
|
+
let n;
|
|
19
|
+
return t[4] !== i || t[5] !== e || t[6] !== r ? (n = /* @__PURE__ */ a.jsx(p, { size: "sm", marginBottom: "none", className: e, "aria-label": "Graph footnote", style: i, children: r }), t[4] = i, t[5] = e, t[6] = r, t[7] = n) : n = t[7], n;
|
|
20
|
+
}
|
|
21
|
+
if (x.isValidElement(r)) {
|
|
22
|
+
let e;
|
|
23
|
+
return t[8] !== o || t[9] !== i || t[10] !== r ? (e = /* @__PURE__ */ a.jsx("div", { className: o, style: i, children: r }), t[8] = o, t[9] = i, t[10] = r, t[11] = e) : e = t[11], e;
|
|
24
|
+
}
|
|
25
|
+
return console.error("FootNote: Invalid text type. Expected string or React element."), null;
|
|
17
26
|
}
|
|
18
27
|
export {
|
|
19
|
-
|
|
28
|
+
g as FootNote
|
|
20
29
|
};
|
|
21
30
|
//# sourceMappingURL=FootNote.js.map
|
package/dist/FootNote.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FootNote.js","sources":["../src/Components/Typography/FootNote.tsx"],"sourcesContent":["import { cn } from '@undp/design-system-react/cn';\r\nimport { P } from '@undp/design-system-react/Typography';\r\nimport React from 'react';\r\n\r\ninterface Props {\r\n text: string | React.ReactNode;\r\n style?: React.CSSProperties;\r\n className?: string;\r\n}\r\n\r\nexport function FootNote(props: Props) {\r\n const { text, style = {}, className } = props;\r\n if (typeof text === 'string') {\r\n if (text.trim() === '') return null;\r\n return (\r\n <P\r\n size='sm'\r\n marginBottom='none'\r\n className={cn('text-primary-gray-550 dark:text-primary-gray-40', className)}\r\n aria-label='Graph footnote'\r\n style={style}\r\n >\r\n {text}\r\n </P>\r\n );\r\n }\r\n if (React.isValidElement(text))\r\n return (\r\n <div className={className} style={style}>\r\n {text}\r\n </div>\r\n );\r\n console.error('FootNote: Invalid text type. Expected string or React element.');\r\n return null;\r\n}\r\n"],"names":["FootNote","props","text","style","className","
|
|
1
|
+
{"version":3,"file":"FootNote.js","sources":["../src/Components/Typography/FootNote.tsx"],"sourcesContent":["import { cn } from '@undp/design-system-react/cn';\r\nimport { P } from '@undp/design-system-react/Typography';\r\nimport React from 'react';\r\n\r\ninterface Props {\r\n text: string | React.ReactNode;\r\n style?: React.CSSProperties;\r\n className?: string;\r\n}\r\n\r\nexport function FootNote(props: Props) {\r\n const { text, style = {}, className } = props;\r\n if (typeof text === 'string') {\r\n if (text.trim() === '') return null;\r\n return (\r\n <P\r\n size='sm'\r\n marginBottom='none'\r\n className={cn('text-primary-gray-550 dark:text-primary-gray-40', className)}\r\n aria-label='Graph footnote'\r\n style={style}\r\n >\r\n {text}\r\n </P>\r\n );\r\n }\r\n if (React.isValidElement(text))\r\n return (\r\n <div className={className} style={style}>\r\n {text}\r\n </div>\r\n );\r\n console.error('FootNote: Invalid text type. Expected string or React element.');\r\n return null;\r\n}\r\n"],"names":["FootNote","props","$","_c","text","style","t0","className","t1","undefined","trim","t2","cn","t3","jsx","P","React","isValidElement","console","error"],"mappings":";;;AAUO,SAAAA,EAAAC,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Property(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index-CHPV5EwG-DDoeWRVt.cjs"),n=require("react"),T=require("maplibre-gl"),O=require("pmtiles");;/* empty css */const C=require("@dnd-kit/core"),_=require("@dnd-kit/modifiers"),L=require("./index-BW_-wD2k.cjs"),I=require("./string2HTML-z7CwHXcx.cjs"),q=require("./select-Bnfk0lJx.cjs"),A=require("./GraphHeader.cjs"),W=require("./GraphFooter.cjs");function G(o){const s=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(o){for(const r in o)if(r!=="default"){const t=Object.getOwnPropertyDescriptor(o,r);Object.defineProperty(s,r,t.get?t:{enumerable:!0,get:()=>o[r]})}}return s.default=o,Object.freeze(s)}const v=G(T),X=G(O);function B(o,s){let r=!1;function t(i,p){if(!r){r=!0;const l=i.getCenter(),a=i.getZoom(),x=i.getBearing(),c=i.getPitch();p.jumpTo({center:l,zoom:a,bearing:x,pitch:c}),r=!1}}o.on("move",()=>{t(o,s)}),s.on("move",()=>{t(s,o)})}function F(o){const{height:s,width:r,mapStyles:t,center:i,zoomLevel:p,mapLegend:l}=o,[a,x]=n.useState(50),[c,S]=n.useState(!1),d=n.useRef(null),[N,M]=n.useState(!0),w=n.useRef(50),m=n.useRef(0),D=C.useSensors(C.useSensor(C.PointerSensor,{activationConstraint:{distance:0}})),k=()=>{S(!0),w.current=a,d.current&&(m.current=d.current.getBoundingClientRect().width)},h=u=>{if(!d.current||m.current===0)return;const g=u.delta.x/m.current*100,E=Math.max(0,Math.min(100,w.current+g));x(E)},f=()=>{S(!1)},z=u=>{if(c||!d.current)return;const g=d.current.getBoundingClientRect(),P=(u.clientX-g.left)/g.width*100;x(Math.max(0,Math.min(100,P)))},b=n.useRef(null),j=n.useRef(null),y=n.useRef(null),R=n.useRef(null);return n.useEffect(()=>{if(R.current&&j.current&&y.current&&r){q.select(R.current).selectAll(".maplibregl-compare").remove(),q.select(j.current).selectAll("div").remove(),q.select(y.current).selectAll("div").remove();const P=new X.Protocol;v.addProtocol("pmtiles",P.tile);const H=new v.Map({container:j.current,style:t[0],center:i||[0,0],zoom:p||4}),$=new v.Map({container:y.current,style:t[1],center:i||[0,0],zoom:p||4});$.addControl(new v.NavigationControl({visualizePitch:!0,showZoom:!0,showCompass:!0}),"bottom-right"),H.addControl(new v.ScaleControl,"bottom-left"),H.addControl(new v.NavigationControl({visualizePitch:!0,showZoom:!0,showCompass:!0}),"bottom-right"),$.addControl(new v.ScaleControl,"bottom-left"),B(H,$)}},[r,t,i,p]),e.jsxRuntimeExports.jsxs("div",{className:"flex flex-col grow justify-center leading-0",ref:b,"aria-label":"Map area",children:[e.jsxRuntimeExports.jsx("div",{style:{width:r,height:s},children:e.jsxRuntimeExports.jsx("div",{ref:R,className:"map maplibre-show-control relative w-full h-full",style:{inset:0},children:e.jsxRuntimeExports.jsx(C.DndContext,{sensors:D,modifiers:[_.restrictToHorizontalAxis],onDragStart:k,onDragMove:h,onDragEnd:f,children:e.jsxRuntimeExports.jsxs("div",{ref:d,style:{position:"relative",width:r,height:s,overflow:"hidden",cursor:c?"grabbing":"col-resize",userSelect:"none"},onClick:z,children:[e.jsxRuntimeExports.jsx("div",{ref:y,className:"absolute h-full rightMap w-full",style:{position:"absolute",top:0,left:0,clipPath:`polygon(${a}% 0%, ${a}% 100%, 100% 100%, 100% 0%)`}}),e.jsxRuntimeExports.jsx("div",{ref:j,className:"absolute h-full leftMap w-full",style:{position:"absolute",top:0,left:0,inset:0,clipPath:`polygon(0% 0%, ${a}% 0%, ${a}% 100%, 0% 100%)`}}),e.jsxRuntimeExports.jsx(Z,{position:a})]})})})}),l?e.jsxRuntimeExports.jsx("div",{className:"absolute left-[22px] bottom-13",children:N?e.jsxRuntimeExports.jsxs(e.jsxRuntimeExports.Fragment,{children:[e.jsxRuntimeExports.jsx("div",{style:{backgroundColor:"rgba(240,240,240, 0.7)",border:"1px solid var(--gray-400)",borderRadius:"999px",width:"24px",height:"24px",padding:"3px",cursor:"pointer",zIndex:10,position:"absolute",right:"-0.75rem",top:"-0.75rem"},onClick:()=>{M(!1)},children:e.jsxRuntimeExports.jsx(L.X,{})}),e.jsxRuntimeExports.jsx("div",{className:"p-2",style:{backgroundColor:"rgba(240,240,240, 0.7)"},dangerouslySetInnerHTML:typeof l=="string"?{__html:I.string2HTML(l)}:void 0,children:n.isValidElement(l)?l:null})]}):e.jsxRuntimeExports.jsx("button",{type:"button",className:"mb-0 border-0 bg-transparent p-0 self-start",onClick:()=>{M(!0)},children:e.jsxRuntimeExports.jsx("div",{className:"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-550 border-primary-gray-400 dark:border-primary-gray-500",children:"Show Legend"})})}):null]})}function Z(o){const{position:s}=o,{attributes:r,listeners:t,setNodeRef:i}=C.useDraggable({id:"slider-handle"});return e.jsxRuntimeExports.jsxs("div",{ref:i,style:{position:"absolute",left:`${s}%`,top:0,bottom:0,width:"40px",transform:"translateX(-50%)",cursor:"col-resize",display:"flex",justifyContent:"center",alignItems:"center",zIndex:10,touchAction:"none"},...t,...r,children:[e.jsxRuntimeExports.jsx("div",{className:"h-full bg-primary-blue-600 dark:bg-primary-blue-400",style:{width:"2px"}}),e.jsxRuntimeExports.jsx("div",{className:"flex bg-primary-blue-600 dark:bg-primary-blue-400 rounded-full absolute items-center justify-center text-primary-white font-primary-white",style:{boxShadow:"inset 0 0 0 1px #fff",width:"42px",height:"42px",top:"calc(50% - 21px)",left:"0",cursor:"col-resize"},children:e.jsxRuntimeExports.jsx(L.ChevronLeftRight,{})})]})}function V(o){const{graphTitle:s,height:r,width:t,relativeHeight:i,sources:p,graphDescription:l,footNote:a,padding:x,backgroundColor:c=!1,graphID:S,mapStyles:d,center:N=[0,0],zoomLevel:M=3,language:w="en",minHeight:m=0,theme:D="light",ariaLabel:k,styles:h,classNames:f,mapLegend:z}=o,[b,j]=n.useState(0),[y,R]=n.useState(0),u=n.useRef(null);return n.useEffect(()=>{const g=new ResizeObserver(E=>{j(t||E[0].target.clientWidth||620),R(r||E[0].target.clientHeight||480)});return u.current&&(R(u.current.clientHeight||480),j(u.current.clientWidth||620),t||g.observe(u.current)),()=>g.disconnect()},[t,r]),e.jsxRuntimeExports.jsx("div",{className:`${D||"light"} flex ${t?"w-fit grow-0":"w-full grow"}`,dir:w==="he"||w==="ar"?"rtl":void 0,children:e.jsxRuntimeExports.jsx("div",{className:e.mo(`${c?c===!0?"bg-primary-gray-200 dark:bg-primary-gray-650 ":"":"bg-transparent "}ml-auto mr-auto flex flex-col grow h-inherit ${w||"en"}`,t?"w-fit":"w-full",f?.graphContainer),style:{...h?.graphContainer||{},...c&&c!==!0?{backgroundColor:c}:{}},id:S,"aria-label":k||`${s?`The graph shows ${s}. `:""}This is a comparison between two maps.${l?` ${l}`:""}`,children:e.jsxRuntimeExports.jsx("div",{className:"flex grow",style:{padding:c?x||"1rem":x||0},children:e.jsxRuntimeExports.jsxs("div",{className:"flex flex-col w-full gap-4 grow justify-between",children:[s||l?e.jsxRuntimeExports.jsx(A.GraphHeader,{styles:{title:h?.title,description:h?.description},classNames:{title:f?.title,description:f?.description},graphTitle:s,graphDescription:l,width:t}):null,e.jsxRuntimeExports.jsx("div",{className:"flex flex-col grow justify-center leading-0",ref:u,"aria-label":"map area",children:(t||b)&&(r||y)?e.jsxRuntimeExports.jsx(F,{width:t||b,height:Math.max(m,r||(i?m?(t||b)*i>m?(t||b)*i:m:(t||b)*i:y)),mapStyles:d,center:N,zoomLevel:M,mapLegend:z}):null}),p||a?e.jsxRuntimeExports.jsx(W.GraphFooter,{styles:{footnote:h?.footnote,source:h?.source},classNames:{footnote:f?.footnote,source:f?.source},sources:p,footNote:a,width:t}):null]})})})})}exports.GeoHubCompareMaps=V;
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("./index-CHPV5EwG-CTPQjnHt.cjs"),u=require("react"),ce=require("maplibre-gl"),ae=require("pmtiles");;/* empty css */const Q=require("@dnd-kit/core"),ue=require("@dnd-kit/modifiers"),ie=require("./index-DRXx7m-C.cjs"),me=require("./string2HTML-CPGr_I5E.cjs"),se=require("./select-Bnfk0lJx.cjs"),fe=require("./GraphHeader.cjs"),pe=require("./GraphFooter.cjs"),ne=require("./GraphContainer-d8A46BK2.cjs");function le(f){const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(f){for(const n in f)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(f,n);Object.defineProperty(e,n,r.get?r:{enumerable:!0,get:()=>f[n]})}}return e.default=f,Object.freeze(e)}const $=le(ce),de=le(ae);function ge(f,e){let n=!1;function r(t,i){if(!n){n=!0;const m=t.getCenter(),l=t.getZoom(),s=t.getBearing(),p=t.getPitch();i.jumpTo({center:m,zoom:l,bearing:s,pitch:p}),n=!1}}f.on("move",()=>{r(f,e)}),e.on("move",()=>{r(e,f)})}function he(f){const e=o.compilerRuntimeExports.c(47),{height:n,width:r,mapStyles:t,center:i,zoomLevel:m,mapLegend:l}=f,[s,p]=u.useState(50),[x,v]=u.useState(!1),R=u.useRef(null),[z,B]=u.useState(!0),F=u.useRef(50),A=u.useRef(0);let G;e[0]===Symbol.for("react.memo_cache_sentinel")?(G={activationConstraint:{distance:0}},e[0]=G):G=e[0];const L=Q.useSensors(Q.useSensor(Q.PointerSensor,G));let c;e[1]!==s?(c=()=>{v(!0),F.current=s,R.current&&(A.current=R.current.getBoundingClientRect().width)},e[1]=s,e[2]=c):c=e[2];const a=c;let P;e[3]===Symbol.for("react.memo_cache_sentinel")?(P=Y=>{if(!R.current||A.current===0)return;const K=Y.delta.x/A.current*100,ee=Math.max(0,Math.min(100,F.current+K));p(ee)},e[3]=P):P=e[3];const Z=P;let C;e[4]===Symbol.for("react.memo_cache_sentinel")?(C=()=>{v(!1)},e[4]=C):C=e[4];const V=C;let k;e[5]!==x?(k=Y=>{if(x||!R.current)return;const K=R.current.getBoundingClientRect(),te=(Y.clientX-K.left)/K.width*100;p(Math.max(0,Math.min(100,te)))},e[5]=x,e[6]=k):k=e[6];const O=k,y=u.useRef(null),H=u.useRef(null),b=u.useRef(null),J=u.useRef(null);let M,I;e[7]!==i||e[8]!==t||e[9]!==r||e[10]!==m?(M=()=>{if(J.current&&H.current&&b.current&&r){se.select(J.current).selectAll(".maplibregl-compare").remove(),se.select(H.current).selectAll("div").remove(),se.select(b.current).selectAll("div").remove();const te=new de.Protocol;$.addProtocol("pmtiles",te.tile);const re=new $.Map({container:H.current,style:t[0],center:i||[0,0],zoom:m||4}),oe=new $.Map({container:b.current,style:t[1],center:i||[0,0],zoom:m||4});oe.addControl(new $.NavigationControl({visualizePitch:!0,showZoom:!0,showCompass:!0}),"bottom-right"),re.addControl(new $.ScaleControl,"bottom-left"),re.addControl(new $.NavigationControl({visualizePitch:!0,showZoom:!0,showCompass:!0}),"bottom-right"),oe.addControl(new $.ScaleControl,"bottom-left"),ge(re,oe)}},I=[r,t,i,m],e[7]=i,e[8]=t,e[9]=r,e[10]=m,e[11]=M,e[12]=I):(M=e[11],I=e[12]),u.useEffect(M,I);let w;e[13]!==n||e[14]!==r?(w={width:r,height:n},e[13]=n,e[14]=r,e[15]=w):w=e[15];let X;e[16]===Symbol.for("react.memo_cache_sentinel")?(X={inset:0},e[16]=X):X=e[16];let _;e[17]===Symbol.for("react.memo_cache_sentinel")?(_=[ue.restrictToHorizontalAxis],e[17]=_):_=e[17];const q=x?"grabbing":"col-resize";let S;e[18]!==n||e[19]!==q||e[20]!==r?(S={position:"relative",width:r,height:n,overflow:"hidden",cursor:q,userSelect:"none"},e[18]=n,e[19]=q,e[20]=r,e[21]=S):S=e[21];const T=`polygon(${s}% 0%, ${s}% 100%, 100% 100%, 100% 0%)`;let d;e[22]!==T?(d=o.jsxRuntimeExports.jsx("div",{ref:b,className:"absolute h-full rightMap w-full",style:{position:"absolute",top:0,left:0,clipPath:T}}),e[22]=T,e[23]=d):d=e[23];const E=`polygon(0% 0%, ${s}% 0%, ${s}% 100%, 0% 100%)`;let g;e[24]!==E?(g=o.jsxRuntimeExports.jsx("div",{ref:H,className:"absolute h-full leftMap w-full",style:{position:"absolute",top:0,left:0,inset:0,clipPath:E}}),e[24]=E,e[25]=g):g=e[25];let h;e[26]!==s?(h=o.jsxRuntimeExports.jsx(xe,{position:s}),e[26]=s,e[27]=h):h=e[27];let j;e[28]!==O||e[29]!==S||e[30]!==d||e[31]!==g||e[32]!==h?(j=o.jsxRuntimeExports.jsxs("div",{ref:R,style:S,onClick:O,children:[d,g,h]}),e[28]=O,e[29]=S,e[30]=d,e[31]=g,e[32]=h,e[33]=j):j=e[33];let D;e[34]!==a||e[35]!==L||e[36]!==j?(D=o.jsxRuntimeExports.jsx("div",{ref:J,className:"map maplibre-show-control relative w-full h-full",style:X,children:o.jsxRuntimeExports.jsx(Q.DndContext,{sensors:L,modifiers:_,onDragStart:a,onDragMove:Z,onDragEnd:V,children:j})}),e[34]=a,e[35]=L,e[36]=j,e[37]=D):D=e[37];let N;e[38]!==D||e[39]!==w?(N=o.jsxRuntimeExports.jsx("div",{style:w,children:D}),e[38]=D,e[39]=w,e[40]=N):N=e[40];let W;e[41]!==l||e[42]!==z?(W=l?o.jsxRuntimeExports.jsx("div",{className:"absolute left-[22px] bottom-13",children:z?o.jsxRuntimeExports.jsxs(o.jsxRuntimeExports.Fragment,{children:[o.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:()=>{B(!1)},children:o.jsxRuntimeExports.jsx(ie.X,{})}),o.jsxRuntimeExports.jsx("div",{className:"color-legend-box p-2 bg-[rgba(240,240,240,0.7)] dark:bg-[rgba(30,30,30,0.7)]",dangerouslySetInnerHTML:typeof l=="string"?{__html:me.string2HTML(l)}:void 0,children:u.isValidElement(l)?l:null})]}):o.jsxRuntimeExports.jsx("button",{type:"button",className:"mb-0 border-0 bg-transparent p-0 self-start",onClick:()=>{B(!0)},children:o.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"})})}):null,e[41]=l,e[42]=z,e[43]=W):W=e[43];let U;return e[44]!==N||e[45]!==W?(U=o.jsxRuntimeExports.jsxs("div",{className:"flex flex-col grow justify-center leading-0",ref:y,"aria-label":"Map area",children:[N,W]}),e[44]=N,e[45]=W,e[46]=U):U=e[46],U}function xe(f){const e=o.compilerRuntimeExports.c(10),{position:n}=f;let r;e[0]===Symbol.for("react.memo_cache_sentinel")?(r={id:"slider-handle"},e[0]=r):r=e[0];const{attributes:t,listeners:i,setNodeRef:m}=Q.useDraggable(r),l=`${n}%`;let s;e[1]!==l?(s={position:"absolute",left:l,top:0,bottom:0,width:"40px",transform:"translateX(-50%)",cursor:"col-resize",display:"flex",justifyContent:"center",alignItems:"center",zIndex:10,touchAction:"none"},e[1]=l,e[2]=s):s=e[2];let p;e[3]===Symbol.for("react.memo_cache_sentinel")?(p=o.jsxRuntimeExports.jsx("div",{className:"h-full bg-primary-blue-600 dark:bg-primary-blue-400",style:{width:"2px"}}),e[3]=p):p=e[3];let x;e[4]===Symbol.for("react.memo_cache_sentinel")?(x=o.jsxRuntimeExports.jsx("div",{className:"flex bg-primary-blue-600 dark:bg-primary-blue-400 rounded-full absolute items-center justify-center text-primary-white font-primary-white",style:{boxShadow:"inset 0 0 0 1px #fff",width:"42px",height:"42px",top:"calc(50% - 21px)",left:"0",cursor:"col-resize"},children:o.jsxRuntimeExports.jsx(ie.ChevronLeftRight,{})}),e[4]=x):x=e[4];let v;return e[5]!==t||e[6]!==i||e[7]!==m||e[8]!==s?(v=o.jsxRuntimeExports.jsxs("div",{ref:m,style:s,...i,...t,children:[p,x]}),e[5]=t,e[6]=i,e[7]=m,e[8]=s,e[9]=v):v=e[9],v}function be(f){const e=o.compilerRuntimeExports.c(49),{graphTitle:n,height:r,width:t,relativeHeight:i,sources:m,graphDescription:l,footNote:s,padding:p,backgroundColor:x,graphID:v,mapStyles:R,center:z,zoomLevel:B,language:F,minHeight:A,theme:G,ariaLabel:L,styles:c,classNames:a,mapLegend:P}=f,Z=x===void 0?!1:x;let C;e[0]!==z?(C=z===void 0?[0,0]:z,e[0]=z,e[1]=C):C=e[1];const V=C,k=B===void 0?3:B,O=F===void 0?"en":F,y=A===void 0?0:A,H=G===void 0?"light":G,[b,J]=u.useState(0),[M,I]=u.useState(0),w=u.useRef(null),X=u.useRef(null);let _,q;e[2]===Symbol.for("react.memo_cache_sentinel")?(_=()=>{const D=new ResizeObserver(N=>{J(N[0].target.clientWidth||620),I(N[0].target.clientHeight||480)});return w.current&&D.observe(w.current),()=>D.disconnect()},q=[],e[2]=_,e[3]=q):(_=e[2],q=e[3]),u.useEffect(_,q);const S=a?.graphContainer,T=c?.graphContainer;let d;e[4]!==a?.description||e[5]!==a?.title||e[6]!==l||e[7]!==n||e[8]!==c?.description||e[9]!==c?.title||e[10]!==t?(d=n||l?o.jsxRuntimeExports.jsx(fe.GraphHeader,{styles:{title:c?.title,description:c?.description},classNames:{title:a?.title,description:a?.description},graphTitle:n,graphDescription:l,width:t}):null,e[4]=a?.description,e[5]=a?.title,e[6]=l,e[7]=n,e[8]=c?.description,e[9]=c?.title,e[10]=t,e[11]=d):d=e[11];let E;e[12]!==V||e[13]!==r||e[14]!==P||e[15]!==R||e[16]!==y||e[17]!==i||e[18]!==M||e[19]!==b||e[20]!==t||e[21]!==k?(E=b&&M?o.jsxRuntimeExports.jsx(he,{width:t||b,height:Math.max(y,r||(i?y?(t||b)*i>y?(t||b)*i:y:(t||b)*i:M)),mapStyles:R,center:V,zoomLevel:k,mapLegend:P}):null,e[12]=V,e[13]=r,e[14]=P,e[15]=R,e[16]=y,e[17]=i,e[18]=M,e[19]=b,e[20]=t,e[21]=k,e[22]=E):E=e[22];let g;e[23]!==E?(g=o.jsxRuntimeExports.jsx(ne.GraphArea,{ref:w,children:E}),e[23]=E,e[24]=g):g=e[24];let h;e[25]!==a?.footnote||e[26]!==a?.source||e[27]!==s||e[28]!==m||e[29]!==c?.footnote||e[30]!==c?.source||e[31]!==t?(h=m||s?o.jsxRuntimeExports.jsx(pe.GraphFooter,{styles:{footnote:c?.footnote,source:c?.source},classNames:{footnote:a?.footnote,source:a?.source},sources:m,footNote:s,width:t}):null,e[25]=a?.footnote,e[26]=a?.source,e[27]=s,e[28]=m,e[29]=c?.footnote,e[30]=c?.source,e[31]=t,e[32]=h):h=e[32];let j;return e[33]!==L||e[34]!==Z||e[35]!==v||e[36]!==r||e[37]!==O||e[38]!==y||e[39]!==p||e[40]!==i||e[41]!==T||e[42]!==d||e[43]!==g||e[44]!==h||e[45]!==S||e[46]!==H||e[47]!==t?(j=o.jsxRuntimeExports.jsxs(ne.GraphContainer,{className:S,style:T,id:v,ref:X,"aria-label":L,backgroundColor:Z,theme:H,language:O,minHeight:y,width:t,height:r,relativeHeight:i,padding:p,children:[d,g,h]}),e[33]=L,e[34]=Z,e[35]=v,e[36]=r,e[37]=O,e[38]=y,e[39]=p,e[40]=i,e[41]=T,e[42]=d,e[43]=g,e[44]=h,e[45]=S,e[46]=H,e[47]=t,e[48]=j):j=e[48],j}exports.GeoHubCompareMaps=be;
|
|
2
2
|
//# sourceMappingURL=GeoHubCompareMaps.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"GeoHubCompareMaps.cjs","sources":["../src/Components/Graphs/Maps/GeoHubMaps/CompareMaps/Graph.tsx","../src/Components/Graphs/Maps/GeoHubMaps/CompareMaps/index.tsx"],"sourcesContent":["import { useRef, useEffect, useState } from 'react';\r\nimport * as maplibreGl from 'maplibre-gl';\r\nimport * as pmtiles from 'pmtiles';\r\nimport 'maplibre-gl/dist/maplibre-gl.css';\r\nimport { select } from 'd3-selection';\r\nimport {\r\n DndContext,\r\n useDraggable,\r\n useSensor,\r\n useSensors,\r\n PointerSensor,\r\n DragMoveEvent,\r\n} from '@dnd-kit/core';\r\nimport { restrictToHorizontalAxis } from '@dnd-kit/modifiers';\r\nimport React from 'react';\r\n\r\nimport { ChevronLeftRight, X } from '@/Components/Icons';\r\nimport { string2HTML } from '@/Utils/string2HTML';\r\n\r\ninterface Props {\r\n width: number;\r\n height: number;\r\n mapStyles: [string, string];\r\n center: [number, number];\r\n mapLegend?: string | React.ReactNode;\r\n zoomLevel: number;\r\n}\r\n\r\nfunction synchronizeMap(map1: maplibreGl.Map, map2: maplibreGl.Map) {\r\n let isSyncing = false;\r\n function syncMap(sourceMap: maplibreGl.Map, targetMap: maplibreGl.Map) {\r\n if (!isSyncing) {\r\n isSyncing = true;\r\n const center = sourceMap.getCenter();\r\n const zoom = sourceMap.getZoom();\r\n const bearing = sourceMap.getBearing();\r\n const pitch = sourceMap.getPitch();\r\n targetMap.jumpTo({\r\n center,\r\n zoom,\r\n bearing,\r\n pitch,\r\n });\r\n isSyncing = false;\r\n }\r\n }\r\n\r\n // Event listeners for map1\r\n map1.on('move', () => {\r\n syncMap(map1, map2);\r\n });\r\n\r\n // Event listeners for map2\r\n map2.on('move', () => {\r\n syncMap(map2, map1);\r\n });\r\n}\r\n\r\nexport function Graph(props: Props) {\r\n const { height, width, mapStyles, center, zoomLevel, mapLegend } = props;\r\n const [position, setPosition] = useState(50);\r\n const [isDragging, setIsDragging] = useState(false);\r\n const containerRef = useRef<HTMLDivElement>(null);\r\n const [showLegend, setShowLegend] = useState(true);\r\n const dragStartPositionRef = useRef(50);\r\n const sliderWidthRef = useRef(0);\r\n\r\n const sensors = useSensors(useSensor(PointerSensor, { activationConstraint: { distance: 0 } }));\r\n\r\n const handleDragStart = () => {\r\n setIsDragging(true);\r\n dragStartPositionRef.current = position;\r\n\r\n if (containerRef.current) {\r\n sliderWidthRef.current = containerRef.current.getBoundingClientRect().width;\r\n }\r\n };\r\n\r\n const handleDragMove = (event: DragMoveEvent) => {\r\n if (!containerRef.current || sliderWidthRef.current === 0) return;\r\n\r\n // Calculate position change as percentage of width\r\n const deltaPercentage = (event.delta.x / sliderWidthRef.current) * 100;\r\n const newPosition = Math.max(0, Math.min(100, dragStartPositionRef.current + deltaPercentage));\r\n\r\n setPosition(newPosition);\r\n };\r\n\r\n const handleDragEnd = () => {\r\n setIsDragging(false);\r\n };\r\n\r\n const handleClick = (e: React.MouseEvent) => {\r\n if (isDragging || !containerRef.current) return;\r\n\r\n const rect = containerRef.current.getBoundingClientRect();\r\n const clickX = e.clientX - rect.left;\r\n const newPosition = (clickX / rect.width) * 100;\r\n\r\n setPosition(Math.max(0, Math.min(100, newPosition)));\r\n };\r\n const graphDiv = useRef<HTMLDivElement>(null);\r\n const leftMapRef = useRef<HTMLDivElement>(null);\r\n const rightMapRef = useRef<HTMLDivElement>(null);\r\n const mapContainer = useRef<HTMLDivElement>(null);\r\n useEffect(() => {\r\n if (mapContainer.current && leftMapRef.current && rightMapRef.current && width) {\r\n const mapDiv = select(mapContainer.current);\r\n mapDiv.selectAll('.maplibregl-compare').remove();\r\n const leftMapDiv = select(leftMapRef.current);\r\n leftMapDiv.selectAll('div').remove();\r\n const rightMapDiv = select(rightMapRef.current);\r\n rightMapDiv.selectAll('div').remove();\r\n const protocol = new pmtiles.Protocol();\r\n maplibreGl.addProtocol('pmtiles', protocol.tile);\r\n const leftMap = new maplibreGl.Map({\r\n container: leftMapRef.current,\r\n style: mapStyles[0],\r\n center: center || [0, 0],\r\n zoom: zoomLevel || 4,\r\n });\r\n\r\n const rightMap = new maplibreGl.Map({\r\n container: rightMapRef.current,\r\n style: mapStyles[1],\r\n center: center || [0, 0],\r\n zoom: zoomLevel || 4,\r\n });\r\n rightMap.addControl(\r\n new maplibreGl.NavigationControl({\r\n visualizePitch: true,\r\n showZoom: true,\r\n showCompass: true,\r\n }),\r\n 'bottom-right',\r\n );\r\n leftMap.addControl(new maplibreGl.ScaleControl(), 'bottom-left');\r\n leftMap.addControl(\r\n new maplibreGl.NavigationControl({\r\n visualizePitch: true,\r\n showZoom: true,\r\n showCompass: true,\r\n }),\r\n 'bottom-right',\r\n );\r\n rightMap.addControl(new maplibreGl.ScaleControl(), 'bottom-left');\r\n synchronizeMap(leftMap, rightMap);\r\n }\r\n }, [width, mapStyles, center, zoomLevel]);\r\n return (\r\n <div\r\n className='flex flex-col grow justify-center leading-0'\r\n ref={graphDiv}\r\n aria-label='Map area'\r\n >\r\n <div\r\n style={{\r\n width,\r\n height,\r\n }}\r\n >\r\n <div\r\n ref={mapContainer}\r\n className='map maplibre-show-control relative w-full h-full'\r\n style={{ inset: 0 }}\r\n >\r\n <DndContext\r\n sensors={sensors}\r\n modifiers={[restrictToHorizontalAxis]}\r\n onDragStart={handleDragStart}\r\n onDragMove={handleDragMove}\r\n onDragEnd={handleDragEnd}\r\n >\r\n <div\r\n ref={containerRef}\r\n style={{\r\n position: 'relative',\r\n width,\r\n height,\r\n overflow: 'hidden',\r\n cursor: isDragging ? 'grabbing' : 'col-resize',\r\n userSelect: 'none', // Prevent text selection during drag\r\n }}\r\n onClick={handleClick}\r\n >\r\n <div\r\n ref={rightMapRef}\r\n className='absolute h-full rightMap w-full'\r\n style={{\r\n position: 'absolute',\r\n top: 0,\r\n left: 0,\r\n clipPath: `polygon(${position}% 0%, ${position}% 100%, 100% 100%, 100% 0%)`,\r\n }}\r\n />\r\n <div\r\n ref={leftMapRef}\r\n className='absolute h-full leftMap w-full'\r\n style={{\r\n position: 'absolute',\r\n top: 0,\r\n left: 0,\r\n inset: 0,\r\n clipPath: `polygon(0% 0%, ${position}% 0%, ${position}% 100%, 0% 100%)`,\r\n }}\r\n />\r\n\r\n <SliderHandle position={position} />\r\n </div>\r\n </DndContext>\r\n </div>\r\n </div>\r\n {mapLegend ? (\r\n <div className='absolute left-[22px] bottom-13'>\r\n {showLegend ? (\r\n <>\r\n <div\r\n style={{\r\n backgroundColor: 'rgba(240,240,240, 0.7)',\r\n border: '1px solid var(--gray-400)',\r\n borderRadius: '999px',\r\n width: '24px',\r\n height: '24px',\r\n padding: '3px',\r\n cursor: 'pointer',\r\n zIndex: 10,\r\n position: 'absolute',\r\n right: '-0.75rem',\r\n top: '-0.75rem',\r\n }}\r\n onClick={() => {\r\n setShowLegend(false);\r\n }}\r\n >\r\n <X />\r\n </div>\r\n <div\r\n className='p-2'\r\n style={{\r\n backgroundColor: 'rgba(240,240,240, 0.7)',\r\n }}\r\n dangerouslySetInnerHTML={\r\n typeof mapLegend === 'string' ? { __html: string2HTML(mapLegend) } : undefined\r\n }\r\n >\r\n {React.isValidElement(mapLegend) ? mapLegend : null}\r\n </div>\r\n </>\r\n ) : (\r\n <button\r\n type='button'\r\n className='mb-0 border-0 bg-transparent p-0 self-start'\r\n onClick={() => {\r\n setShowLegend(true);\r\n }}\r\n >\r\n <div className='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-550 border-primary-gray-400 dark:border-primary-gray-500'>\r\n Show Legend\r\n </div>\r\n </button>\r\n )}\r\n </div>\r\n ) : null}\r\n </div>\r\n );\r\n}\r\n\r\ninterface HandleProps {\r\n position: number;\r\n}\r\n\r\nfunction SliderHandle(props: HandleProps) {\r\n const { position } = props;\r\n const { attributes, listeners, setNodeRef } = useDraggable({ id: 'slider-handle' });\r\n\r\n return (\r\n <div\r\n ref={setNodeRef}\r\n style={{\r\n position: 'absolute',\r\n left: `${position}%`,\r\n top: 0,\r\n bottom: 0,\r\n width: '40px',\r\n transform: 'translateX(-50%)',\r\n cursor: 'col-resize',\r\n display: 'flex',\r\n justifyContent: 'center',\r\n alignItems: 'center',\r\n zIndex: 10,\r\n touchAction: 'none',\r\n }}\r\n {...listeners}\r\n {...attributes}\r\n >\r\n <div\r\n className='h-full bg-primary-blue-600 dark:bg-primary-blue-400'\r\n style={{ width: '2px' }}\r\n />\r\n <div\r\n className='flex bg-primary-blue-600 dark:bg-primary-blue-400 rounded-full absolute items-center justify-center text-primary-white font-primary-white'\r\n style={{\r\n boxShadow: 'inset 0 0 0 1px #fff',\r\n width: '42px',\r\n height: '42px',\r\n top: 'calc(50% - 21px)',\r\n left: '0',\r\n cursor: 'col-resize',\r\n }}\r\n >\r\n <ChevronLeftRight />\r\n </div>\r\n </div>\r\n );\r\n}\r\n","import { useRef, useEffect, useState } from 'react';\r\nimport { cn } from '@undp/design-system-react/cn';\r\n\r\nimport { Graph } from './Graph';\r\n\r\nimport { GraphHeader } from '@/Components/Elements/GraphHeader';\r\nimport { GraphFooter } from '@/Components/Elements/GraphFooter';\r\nimport { ClassNameObject, Languages, SourcesDataType, StyleObject } from '@/Types';\r\n\r\ninterface Props {\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 /** 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\r\n // Graph Parameters\r\n /** URLs for mapStyles JSON user wants to compare */\r\n mapStyles: [string, string];\r\n /** Defines the legend for the map. mapLegend with type string is show as innerHTML. */\r\n mapLegend?: string | React.ReactNode;\r\n /** Starting center point of the map */\r\n center?: [number, number];\r\n /** Starting zoom level of the map */\r\n zoomLevel?: number;\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\n/** For using these maps you will have to install [`maplibre`](https://maplibre.org/maplibre-gl-js/docs/#npm), [pmtiles](https://www.npmjs.com/package/pmtiles), [dnd-kit/core](https://www.npmjs.com/package/@dnd-kit/core), and [dnd-kit/modifier](https://www.npmjs.com/package/@dnd-kit/modifiers) package to your project */\r\nexport function GeoHubCompareMaps(props: Props) {\r\n const {\r\n graphTitle,\r\n height,\r\n width,\r\n relativeHeight,\r\n sources,\r\n graphDescription,\r\n footNote,\r\n padding,\r\n backgroundColor = false,\r\n graphID,\r\n mapStyles,\r\n center = [0, 0],\r\n zoomLevel = 3,\r\n language = 'en',\r\n minHeight = 0,\r\n theme = 'light',\r\n ariaLabel,\r\n styles,\r\n classNames,\r\n mapLegend,\r\n } = props;\r\n const [svgWidth, setSvgWidth] = useState(0);\r\n const [svgHeight, setSvgHeight] = useState(0);\r\n const graphDiv = useRef<HTMLDivElement>(null);\r\n useEffect(() => {\r\n const resizeObserver = new ResizeObserver(entries => {\r\n setSvgWidth(width || entries[0].target.clientWidth || 620);\r\n setSvgHeight(height || entries[0].target.clientHeight || 480);\r\n });\r\n if (graphDiv.current) {\r\n setSvgHeight(graphDiv.current.clientHeight || 480);\r\n setSvgWidth(graphDiv.current.clientWidth || 620);\r\n if (!width) resizeObserver.observe(graphDiv.current);\r\n }\r\n return () => resizeObserver.disconnect();\r\n }, [width, height]);\r\n return (\r\n <div\r\n className={`${theme || 'light'} flex ${width ? 'w-fit grow-0' : 'w-full grow'}`}\r\n dir={language === 'he' || language === 'ar' ? 'rtl' : undefined}\r\n >\r\n <div\r\n className={cn(\r\n `${\r\n !backgroundColor\r\n ? 'bg-transparent '\r\n : backgroundColor === true\r\n ? 'bg-primary-gray-200 dark:bg-primary-gray-650 '\r\n : ''\r\n }ml-auto mr-auto flex flex-col grow h-inherit ${language || 'en'}`,\r\n width ? 'w-fit' : 'w-full',\r\n classNames?.graphContainer,\r\n )}\r\n style={{\r\n ...(styles?.graphContainer || {}),\r\n ...(backgroundColor && backgroundColor !== true ? { backgroundColor } : {}),\r\n }}\r\n id={graphID}\r\n aria-label={\r\n ariaLabel ||\r\n `${\r\n graphTitle ? `The graph shows ${graphTitle}. ` : ''\r\n }This is a comparison between two maps.${graphDescription ? ` ${graphDescription}` : ''}`\r\n }\r\n >\r\n <div\r\n className='flex grow'\r\n style={{ padding: backgroundColor ? padding || '1rem' : padding || 0 }}\r\n >\r\n <div className='flex flex-col w-full gap-4 grow justify-between'>\r\n {graphTitle || graphDescription ? (\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 />\r\n ) : null}\r\n <div\r\n className='flex flex-col grow justify-center leading-0'\r\n ref={graphDiv}\r\n aria-label='map area'\r\n >\r\n {(width || svgWidth) && (height || svgHeight) ? (\r\n <Graph\r\n width={width || svgWidth}\r\n height={Math.max(\r\n minHeight,\r\n height ||\r\n (relativeHeight\r\n ? minHeight\r\n ? (width || svgWidth) * relativeHeight > minHeight\r\n ? (width || svgWidth) * relativeHeight\r\n : minHeight\r\n : (width || svgWidth) * relativeHeight\r\n : svgHeight),\r\n )}\r\n mapStyles={mapStyles}\r\n center={center}\r\n zoomLevel={zoomLevel}\r\n mapLegend={mapLegend}\r\n />\r\n ) : null}\r\n </div>\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 </div>\r\n </div>\r\n </div>\r\n </div>\r\n );\r\n}\r\n"],"names":["synchronizeMap","map1","map2","isSyncing","syncMap","sourceMap","targetMap","center","zoom","bearing","pitch","Graph","props","height","width","mapStyles","zoomLevel","mapLegend","position","setPosition","useState","isDragging","setIsDragging","containerRef","useRef","showLegend","setShowLegend","dragStartPositionRef","sliderWidthRef","sensors","useSensors","useSensor","PointerSensor","handleDragStart","handleDragMove","event","deltaPercentage","newPosition","handleDragEnd","handleClick","e","rect","graphDiv","leftMapRef","rightMapRef","mapContainer","useEffect","select","protocol","pmtiles","maplibreGl","leftMap","rightMap","jsxs","jsx","DndContext","restrictToHorizontalAxis","SliderHandle","Fragment","X","string2HTML","React","attributes","listeners","setNodeRef","useDraggable","ChevronLeftRight","GeoHubCompareMaps","graphTitle","relativeHeight","sources","graphDescription","footNote","padding","backgroundColor","graphID","language","minHeight","theme","ariaLabel","styles","classNames","svgWidth","setSvgWidth","svgHeight","setSvgHeight","resizeObserver","entries","cn","GraphHeader","GraphFooter"],"mappings":"qvBA4BA,SAASA,EAAeC,EAAsBC,EAAsB,CAClE,IAAIC,EAAY,GAChB,SAASC,EAAQC,EAA2BC,EAA2B,CACrE,GAAI,CAACH,EAAW,CACdA,EAAY,GACZ,MAAMI,EAASF,EAAU,UAAA,EACnBG,EAAOH,EAAU,QAAA,EACjBI,EAAUJ,EAAU,WAAA,EACpBK,EAAQL,EAAU,SAAA,EACxBC,EAAU,OAAO,CACf,OAAAC,EACA,KAAAC,EACA,QAAAC,EACA,MAAAC,CAAA,CACD,EACDP,EAAY,EACd,CACF,CAGAF,EAAK,GAAG,OAAQ,IAAM,CACpBG,EAAQH,EAAMC,CAAI,CACpB,CAAC,EAGDA,EAAK,GAAG,OAAQ,IAAM,CACpBE,EAAQF,EAAMD,CAAI,CACpB,CAAC,CACH,CAEO,SAASU,EAAMC,EAAc,CAClC,KAAM,CAAE,OAAAC,EAAQ,MAAAC,EAAO,UAAAC,EAAW,OAAAR,EAAQ,UAAAS,EAAW,UAAAC,GAAcL,EAC7D,CAACM,EAAUC,CAAW,EAAIC,EAAAA,SA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HubMaps/CompareMaps/Graph.tsx","../src/Components/Graphs/Maps/GeoHubMaps/CompareMaps/index.tsx"],"sourcesContent":["import { useRef, useEffect, useState } from 'react';\r\nimport * as maplibreGl from 'maplibre-gl';\r\nimport * as pmtiles from 'pmtiles';\r\nimport 'maplibre-gl/dist/maplibre-gl.css';\r\nimport { select } from 'd3-selection';\r\nimport {\r\n DndContext,\r\n useDraggable,\r\n useSensor,\r\n useSensors,\r\n PointerSensor,\r\n DragMoveEvent,\r\n} from '@dnd-kit/core';\r\nimport { restrictToHorizontalAxis } from '@dnd-kit/modifiers';\r\nimport React from 'react';\r\n\r\nimport { ChevronLeftRight, X } from '@/Components/Icons';\r\nimport { string2HTML } from '@/Utils/string2HTML';\r\n\r\ninterface Props {\r\n width: number;\r\n height: number;\r\n mapStyles: [string, string];\r\n center: [number, number];\r\n mapLegend?: string | React.ReactNode;\r\n zoomLevel: number;\r\n}\r\n\r\nfunction synchronizeMap(map1: maplibreGl.Map, map2: maplibreGl.Map) {\r\n let isSyncing = false;\r\n function syncMap(sourceMap: maplibreGl.Map, targetMap: maplibreGl.Map) {\r\n if (!isSyncing) {\r\n isSyncing = true;\r\n const center = sourceMap.getCenter();\r\n const zoom = sourceMap.getZoom();\r\n const bearing = sourceMap.getBearing();\r\n const pitch = sourceMap.getPitch();\r\n targetMap.jumpTo({\r\n center,\r\n zoom,\r\n bearing,\r\n pitch,\r\n });\r\n isSyncing = false;\r\n }\r\n }\r\n\r\n // Event listeners for map1\r\n map1.on('move', () => {\r\n syncMap(map1, map2);\r\n });\r\n\r\n // Event listeners for map2\r\n map2.on('move', () => {\r\n syncMap(map2, map1);\r\n });\r\n}\r\n\r\nexport function Graph(props: Props) {\r\n const { height, width, mapStyles, center, zoomLevel, mapLegend } = props;\r\n const [position, setPosition] = useState(50);\r\n const [isDragging, setIsDragging] = useState(false);\r\n const containerRef = useRef<HTMLDivElement>(null);\r\n const [showLegend, setShowLegend] = useState(true);\r\n const dragStartPositionRef = useRef(50);\r\n const sliderWidthRef = useRef(0);\r\n\r\n const sensors = useSensors(useSensor(PointerSensor, { activationConstraint: { distance: 0 } }));\r\n\r\n const handleDragStart = () => {\r\n setIsDragging(true);\r\n dragStartPositionRef.current = position;\r\n\r\n if (containerRef.current) {\r\n sliderWidthRef.current = containerRef.current.getBoundingClientRect().width;\r\n }\r\n };\r\n\r\n const handleDragMove = (event: DragMoveEvent) => {\r\n if (!containerRef.current || sliderWidthRef.current === 0) return;\r\n\r\n // Calculate position change as percentage of width\r\n const deltaPercentage = (event.delta.x / sliderWidthRef.current) * 100;\r\n const newPosition = Math.max(0, Math.min(100, dragStartPositionRef.current + deltaPercentage));\r\n\r\n setPosition(newPosition);\r\n };\r\n\r\n const handleDragEnd = () => {\r\n setIsDragging(false);\r\n };\r\n\r\n const handleClick = (e: React.MouseEvent) => {\r\n if (isDragging || !containerRef.current) return;\r\n\r\n const rect = containerRef.current.getBoundingClientRect();\r\n const clickX = e.clientX - rect.left;\r\n const newPosition = (clickX / rect.width) * 100;\r\n\r\n setPosition(Math.max(0, Math.min(100, newPosition)));\r\n };\r\n const graphDiv = useRef<HTMLDivElement>(null);\r\n const leftMapRef = useRef<HTMLDivElement>(null);\r\n const rightMapRef = useRef<HTMLDivElement>(null);\r\n const mapContainer = useRef<HTMLDivElement>(null);\r\n useEffect(() => {\r\n if (mapContainer.current && leftMapRef.current && rightMapRef.current && width) {\r\n const mapDiv = select(mapContainer.current);\r\n mapDiv.selectAll('.maplibregl-compare').remove();\r\n const leftMapDiv = select(leftMapRef.current);\r\n leftMapDiv.selectAll('div').remove();\r\n const rightMapDiv = select(rightMapRef.current);\r\n rightMapDiv.selectAll('div').remove();\r\n const protocol = new pmtiles.Protocol();\r\n maplibreGl.addProtocol('pmtiles', protocol.tile);\r\n const leftMap = new maplibreGl.Map({\r\n container: leftMapRef.current,\r\n style: mapStyles[0],\r\n center: center || [0, 0],\r\n zoom: zoomLevel || 4,\r\n });\r\n\r\n const rightMap = new maplibreGl.Map({\r\n container: rightMapRef.current,\r\n style: mapStyles[1],\r\n center: center || [0, 0],\r\n zoom: zoomLevel || 4,\r\n });\r\n rightMap.addControl(\r\n new maplibreGl.NavigationControl({\r\n visualizePitch: true,\r\n showZoom: true,\r\n showCompass: true,\r\n }),\r\n 'bottom-right',\r\n );\r\n leftMap.addControl(new maplibreGl.ScaleControl(), 'bottom-left');\r\n leftMap.addControl(\r\n new maplibreGl.NavigationControl({\r\n visualizePitch: true,\r\n showZoom: true,\r\n showCompass: true,\r\n }),\r\n 'bottom-right',\r\n );\r\n rightMap.addControl(new maplibreGl.ScaleControl(), 'bottom-left');\r\n synchronizeMap(leftMap, rightMap);\r\n }\r\n }, [width, mapStyles, center, zoomLevel]);\r\n return (\r\n <div\r\n className='flex flex-col grow justify-center leading-0'\r\n ref={graphDiv}\r\n aria-label='Map area'\r\n >\r\n <div\r\n style={{\r\n width,\r\n height,\r\n }}\r\n >\r\n <div\r\n ref={mapContainer}\r\n className='map maplibre-show-control relative w-full h-full'\r\n style={{ inset: 0 }}\r\n >\r\n <DndContext\r\n sensors={sensors}\r\n modifiers={[restrictToHorizontalAxis]}\r\n onDragStart={handleDragStart}\r\n onDragMove={handleDragMove}\r\n onDragEnd={handleDragEnd}\r\n >\r\n <div\r\n ref={containerRef}\r\n style={{\r\n position: 'relative',\r\n width,\r\n height,\r\n overflow: 'hidden',\r\n cursor: isDragging ? 'grabbing' : 'col-resize',\r\n userSelect: 'none', // Prevent text selection during drag\r\n }}\r\n onClick={handleClick}\r\n >\r\n <div\r\n ref={rightMapRef}\r\n className='absolute h-full rightMap w-full'\r\n style={{\r\n position: 'absolute',\r\n top: 0,\r\n left: 0,\r\n clipPath: `polygon(${position}% 0%, ${position}% 100%, 100% 100%, 100% 0%)`,\r\n }}\r\n />\r\n <div\r\n ref={leftMapRef}\r\n className='absolute h-full leftMap w-full'\r\n style={{\r\n position: 'absolute',\r\n top: 0,\r\n left: 0,\r\n inset: 0,\r\n clipPath: `polygon(0% 0%, ${position}% 0%, ${position}% 100%, 0% 100%)`,\r\n }}\r\n />\r\n\r\n <SliderHandle position={position} />\r\n </div>\r\n </DndContext>\r\n </div>\r\n </div>\r\n {mapLegend ? (\r\n <div className='absolute left-[22px] bottom-13'>\r\n {showLegend ? (\r\n <>\r\n <div\r\n 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]'\r\n onClick={() => {\r\n setShowLegend(false);\r\n }}\r\n >\r\n <X />\r\n </div>\r\n <div\r\n className='color-legend-box p-2 bg-[rgba(240,240,240,0.7)] dark:bg-[rgba(30,30,30,0.7)]'\r\n dangerouslySetInnerHTML={\r\n typeof mapLegend === 'string' ? { __html: string2HTML(mapLegend) } : undefined\r\n }\r\n >\r\n {React.isValidElement(mapLegend) ? mapLegend : null}\r\n </div>\r\n </>\r\n ) : (\r\n <button\r\n type='button'\r\n className='mb-0 border-0 bg-transparent p-0 self-start'\r\n onClick={() => {\r\n setShowLegend(true);\r\n }}\r\n >\r\n <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'>\r\n Show Legend\r\n </div>\r\n </button>\r\n )}\r\n </div>\r\n ) : null}\r\n </div>\r\n );\r\n}\r\n\r\ninterface HandleProps {\r\n position: number;\r\n}\r\n\r\nfunction SliderHandle(props: HandleProps) {\r\n const { position } = props;\r\n const { attributes, listeners, setNodeRef } = useDraggable({ id: 'slider-handle' });\r\n\r\n return (\r\n <div\r\n ref={setNodeRef}\r\n style={{\r\n position: 'absolute',\r\n left: `${position}%`,\r\n top: 0,\r\n bottom: 0,\r\n width: '40px',\r\n transform: 'translateX(-50%)',\r\n cursor: 'col-resize',\r\n display: 'flex',\r\n justifyContent: 'center',\r\n alignItems: 'center',\r\n zIndex: 10,\r\n touchAction: 'none',\r\n }}\r\n {...listeners}\r\n {...attributes}\r\n >\r\n <div\r\n className='h-full bg-primary-blue-600 dark:bg-primary-blue-400'\r\n style={{ width: '2px' }}\r\n />\r\n <div\r\n className='flex bg-primary-blue-600 dark:bg-primary-blue-400 rounded-full absolute items-center justify-center text-primary-white font-primary-white'\r\n style={{\r\n boxShadow: 'inset 0 0 0 1px #fff',\r\n width: '42px',\r\n height: '42px',\r\n top: 'calc(50% - 21px)',\r\n left: '0',\r\n cursor: 'col-resize',\r\n }}\r\n >\r\n <ChevronLeftRight />\r\n </div>\r\n </div>\r\n );\r\n}\r\n","import { useRef, useEffect, useState } from 'react';\r\n\r\nimport { Graph } from './Graph';\r\n\r\nimport { GraphHeader } from '@/Components/Elements/GraphHeader';\r\nimport { GraphFooter } from '@/Components/Elements/GraphFooter';\r\nimport { ClassNameObject, Languages, SourcesDataType, StyleObject } from '@/Types';\r\nimport { GraphArea, GraphContainer } from '@/Components/Elements/GraphContainer';\r\n\r\ninterface Props {\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 /** 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\r\n // Graph Parameters\r\n /** URLs for mapStyles JSON user wants to compare */\r\n mapStyles: [string, string];\r\n /** Defines the legend for the map. mapLegend with type string is show as innerHTML. */\r\n mapLegend?: string | React.ReactNode;\r\n /** Starting center point of the map */\r\n center?: [number, number];\r\n /** Starting zoom level of the map */\r\n zoomLevel?: number;\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\n/** For using these maps you will have to install [`maplibre`](https://maplibre.org/maplibre-gl-js/docs/#npm), [pmtiles](https://www.npmjs.com/package/pmtiles), [dnd-kit/core](https://www.npmjs.com/package/@dnd-kit/core), and [dnd-kit/modifier](https://www.npmjs.com/package/@dnd-kit/modifiers) package to your project */\r\nexport function GeoHubCompareMaps(props: Props) {\r\n const {\r\n graphTitle,\r\n height,\r\n width,\r\n relativeHeight,\r\n sources,\r\n graphDescription,\r\n footNote,\r\n padding,\r\n backgroundColor = false,\r\n graphID,\r\n mapStyles,\r\n center = [0, 0],\r\n zoomLevel = 3,\r\n language = 'en',\r\n minHeight = 0,\r\n theme = 'light',\r\n ariaLabel,\r\n styles,\r\n classNames,\r\n mapLegend,\r\n } = props;\r\n const [svgWidth, setSvgWidth] = useState(0);\r\n const [svgHeight, setSvgHeight] = useState(0);\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 ? (\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 />\r\n ) : null}\r\n <GraphArea ref={graphDiv}>\r\n {svgWidth && svgHeight ? (\r\n <Graph\r\n width={width || svgWidth}\r\n height={Math.max(\r\n minHeight,\r\n height ||\r\n (relativeHeight\r\n ? minHeight\r\n ? (width || svgWidth) * relativeHeight > minHeight\r\n ? (width || svgWidth) * relativeHeight\r\n : minHeight\r\n : (width || svgWidth) * relativeHeight\r\n : svgHeight),\r\n )}\r\n mapStyles={mapStyles}\r\n center={center}\r\n zoomLevel={zoomLevel}\r\n mapLegend={mapLegend}\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":["synchronizeMap","map1","map2","isSyncing","syncMap","sourceMap","targetMap","center","getCenter","zoom","getZoom","bearing","getBearing","pitch","getPitch","jumpTo","on","Graph","props","$","_c","height","width","mapStyles","zoomLevel","mapLegend","position","setPosition","useState","isDragging","setIsDragging","containerRef","useRef","showLegend","setShowLegend","dragStartPositionRef","sliderWidthRef","t0","Symbol","for","activationConstraint","distance","sensors","useSensors","useSensor","PointerSensor","t1","current","getBoundingClientRect","handleDragStart","t2","event","deltaPercentage","delta","x","newPosition","Math","max","min","handleDragMove","t3","handleDragEnd","t4","e","rect","newPosition_0","clientX","left","handleClick","graphDiv","leftMapRef","rightMapRef","mapContainer","t5","t6","select","selectAll","remove","protocol","pmtiles","Protocol","maplibreGl","addProtocol","tile","leftMap","Map","container","style","rightMap","addControl","NavigationControl","visualizePitch","showZoom","showCompass","ScaleControl","useEffect","t7","t8","inset","t9","restrictToHorizontalAxis","t10","t11","overflow","cursor","userSelect","t12","t13","top","clipPath","t14","t15","t16","SliderHandle","t17","t18","jsx","DndContext","t19","t20","jsxs","Fragment","X","__html","string2HTML","undefined","React","isValidElement","t21","id","attributes","listeners","setNodeRef","useDraggable","bottom","transform","display","justifyContent","alignItems","zIndex","touchAction","boxShadow","ChevronLeftRight","GeoHubCompareMaps","graphTitle","relativeHeight","sources","graphDescription","footNote","padding","backgroundColor","graphID","language","minHeight","theme","ariaLabel","styles","classNames","svgWidth","setSvgWidth","svgHeight","setSvgHeight","graphParentDiv","resizeObserver","ResizeObserver","entries","target","clientWidth","clientHeight","observe","disconnect","graphContainer","description","title","GraphHeader","GraphArea","footnote","source","GraphFooter","GraphContainer"],"mappings":"+yBA4BA,SAASA,GAAeC,EAAsBC,EAAsB,CAClE,IAAIC,EAAY,GAChB,SAASC,EAAQC,EAA2BC,EAA2B,CACrE,GAAI,CAACH,EAAW,CACdA,EAAY,GACZ,MAAMI,EAASF,EAAUG,UAAAA,EACnBC,EAAOJ,EAAUK,QAAAA,EACjBC,EAAUN,EAAUO,WAAAA,EACpBC,EAAQR,EAAUS,SAAAA,EACxBR,EAAUS,OAAO,CACfR,OAAAA,EACAE,KAAAA,EACAE,QAAAA,EACAE,MAAAA,CAAAA,CACD,EACDV,EAAY,EACd,CACF,CAGAF,EAAKe,GAAG,OAAQ,IAAM,CACpBZ,EAAQH,EAAMC,CAAI,CACpB,CAAC,EAGDA,EAAKc,GAAG,OAAQ,IAAM,CACpBZ,EAAQF,EAAMD,CAAI,CACpB,CAAC,CACH,CAEO,SAAAgB,GAAAC,EAAA,CAAA,MAAAC,EAAAC,EAAAA,uBAAAA,EAAA,EAAA,EACL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EAAA,EAAA,IAAAoI,GAAApI,EAAA,EAAA,IAAAE,GAAAF,EAAA,EAAA,IAAAqI,GAAArI,EAAA,EAAA,IAAAsI,GAAAtI,EAAA,EAAA,IAAAkI,GAAAlI,QAAA8H,GAAA9H,EAAA,EAAA,IAAAkF,GAAAlF,EAAA,EAAA,IAAAmF,GAAAnF,EAAA,EAAA,IAAAwF,GAAAxF,EAAA,EAAA,IAAA2F,GAAA3F,EAAA,EAAA,IAAAgF,GAAAhF,EAAA,EAAA,IAAAuI,GAAAvI,EAAA,EAAA,IAAAG,GA/DVyF,2BAACoE,kBAAA,CACY,UAAAhF,EACJ,MAAAE,EACHkD,GAAAA,EACCW,IAAAA,EACOP,aAAAA,EACKL,gBAAAA,EACVI,MAAAA,EACGF,SAAAA,EACCC,UAAAA,EACJnI,MAAAA,EACCD,OAAAA,EACQ4H,eAAAA,EACPI,QAAAA,EAER/C,SAAAA,CAAAA,EAeDK,EAsBCG,CAAAA,EAYH,EAAiB3F,MAAAwI,EAAAxI,MAAAmI,EAAAnI,MAAAoI,EAAApI,MAAAE,EAAAF,MAAAqI,EAAArI,MAAAsI,EAAAtI,MAAAkI,EAAAlI,MAAA8H,EAAA9H,MAAAkF,EAAAlF,MAAAmF,EAAAnF,MAAAwF,EAAAxF,MAAA2F,EAAA3F,MAAAgF,EAAAhF,MAAAuI,EAAAvI,MAAAG,EAAAH,MAAA4F,GAAAA,EAAA5F,EAAA,EAAA,EAhEjB4F,CAgEiB"}
|
|
@@ -29,6 +29,7 @@ declare interface ClassNameObject {
|
|
|
29
29
|
mouseOverLine?: string;
|
|
30
30
|
regLine?: string;
|
|
31
31
|
dataCards?: string;
|
|
32
|
+
colorLegend?: string;
|
|
32
33
|
}
|
|
33
34
|
|
|
34
35
|
/** For using these maps you will have to install [`maplibre`](https://maplibre.org/maplibre-gl-js/docs/#npm), [pmtiles](https://www.npmjs.com/package/pmtiles), [dnd-kit/core](https://www.npmjs.com/package/@dnd-kit/core), and [dnd-kit/modifier](https://www.npmjs.com/package/@dnd-kit/modifiers) package to your project */
|