@undp/data-viz 2.3.17 → 2.4.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.
Files changed (440) hide show
  1. package/dist/AreaChart.cjs +1 -1
  2. package/dist/AreaChart.cjs.map +1 -1
  3. package/dist/AreaChart.d.ts +2 -0
  4. package/dist/AreaChart.js +356 -354
  5. package/dist/AreaChart.js.map +1 -1
  6. package/dist/{Axis-Jt_tmhxS.cjs → Axis-BTaS9oPQ.cjs} +2 -2
  7. package/dist/{Axis-Jt_tmhxS.cjs.map → Axis-BTaS9oPQ.cjs.map} +1 -1
  8. package/dist/{Axis-RyGdzLrG.js → Axis-CNZYWzH0.js} +2 -2
  9. package/dist/{Axis-RyGdzLrG.js.map → Axis-CNZYWzH0.js.map} +1 -1
  10. package/dist/{AxisTitle-DGjX1_2v.js → AxisTitle-CyLCqpW6.js} +2 -2
  11. package/dist/{AxisTitle-DGjX1_2v.js.map → AxisTitle-CyLCqpW6.js.map} +1 -1
  12. package/dist/{AxisTitle-DV4n0RxE.cjs → AxisTitle-DP_evhbe.cjs} +2 -2
  13. package/dist/{AxisTitle-DV4n0RxE.cjs.map → AxisTitle-DP_evhbe.cjs.map} +1 -1
  14. package/dist/BarGraph.cjs +1 -1
  15. package/dist/BarGraph.cjs.map +1 -1
  16. package/dist/BarGraph.d.ts +6 -0
  17. package/dist/BarGraph.js +1735 -1726
  18. package/dist/BarGraph.js.map +1 -1
  19. package/dist/BasicStatCard.cjs +1 -1
  20. package/dist/BasicStatCard.cjs.map +1 -1
  21. package/dist/BasicStatCard.d.ts +2 -0
  22. package/dist/BasicStatCard.js +46 -45
  23. package/dist/BasicStatCard.js.map +1 -1
  24. package/dist/BeeSwarmChart.cjs +1 -1
  25. package/dist/BeeSwarmChart.cjs.map +1 -1
  26. package/dist/BeeSwarmChart.d.ts +2 -0
  27. package/dist/BeeSwarmChart.js +266 -266
  28. package/dist/BeeSwarmChart.js.map +1 -1
  29. package/dist/BiVariateChoroplethMap.cjs +1 -1
  30. package/dist/BiVariateChoroplethMap.cjs.map +1 -1
  31. package/dist/BiVariateChoroplethMap.d.ts +2 -0
  32. package/dist/BiVariateChoroplethMap.js +300 -298
  33. package/dist/BiVariateChoroplethMap.js.map +1 -1
  34. package/dist/BulletChart.cjs +1 -1
  35. package/dist/BulletChart.cjs.map +1 -1
  36. package/dist/BulletChart.d.ts +2 -0
  37. package/dist/BulletChart.js +469 -469
  38. package/dist/BulletChart.js.map +1 -1
  39. package/dist/ButterflyChart.cjs +1 -1
  40. package/dist/ButterflyChart.cjs.map +1 -1
  41. package/dist/ButterflyChart.d.ts +2 -0
  42. package/dist/ButterflyChart.js +330 -328
  43. package/dist/ButterflyChart.js.map +1 -1
  44. package/dist/ChoroplethMap.cjs +1 -1
  45. package/dist/ChoroplethMap.cjs.map +1 -1
  46. package/dist/ChoroplethMap.d.ts +2 -0
  47. package/dist/ChoroplethMap.js +303 -301
  48. package/dist/ChoroplethMap.js.map +1 -1
  49. package/dist/CirclePackingGraph.cjs +1 -1
  50. package/dist/CirclePackingGraph.d.ts +2 -0
  51. package/dist/CirclePackingGraph.js +4 -4
  52. package/dist/ColorLegend.cjs +1 -1
  53. package/dist/ColorLegend.js +2 -2
  54. package/dist/ColorLegendWithMouseOver.cjs +1 -1
  55. package/dist/ColorLegendWithMouseOver.js +2 -2
  56. package/dist/CopyTextButton.cjs +1 -1
  57. package/dist/CopyTextButton.cjs.map +1 -1
  58. package/dist/CopyTextButton.js +7 -9
  59. package/dist/CopyTextButton.js.map +1 -1
  60. package/dist/CsvDownloadButton.cjs +1 -1
  61. package/dist/CsvDownloadButton.js +2 -2
  62. package/dist/DataCards.cjs +1 -1
  63. package/dist/DataCards.cjs.map +1 -1
  64. package/dist/DataCards.js +10 -12
  65. package/dist/DataCards.js.map +1 -1
  66. package/dist/DataTable.cjs +1 -1
  67. package/dist/DataTable.cjs.map +1 -1
  68. package/dist/DataTable.d.ts +2 -0
  69. package/dist/DataTable.js +103 -102
  70. package/dist/DataTable.js.map +1 -1
  71. package/dist/{DetailsModal-C3qlUyFK.js → DetailsModal-B2XBWR7w.js} +4 -4
  72. package/dist/{DetailsModal-C3qlUyFK.js.map → DetailsModal-B2XBWR7w.js.map} +1 -1
  73. package/dist/{DetailsModal-DIRTulvr.cjs → DetailsModal-jmmKRMRM.cjs} +2 -2
  74. package/dist/{DetailsModal-DIRTulvr.cjs.map → DetailsModal-jmmKRMRM.cjs.map} +1 -1
  75. package/dist/DifferenceLineChart.cjs +1 -1
  76. package/dist/DifferenceLineChart.cjs.map +1 -1
  77. package/dist/DifferenceLineChart.d.ts +4 -0
  78. package/dist/DifferenceLineChart.js +441 -437
  79. package/dist/DifferenceLineChart.js.map +1 -1
  80. package/dist/DonutChart.cjs +1 -1
  81. package/dist/DonutChart.cjs.map +1 -1
  82. package/dist/DonutChart.d.ts +4 -0
  83. package/dist/DonutChart.js +146 -142
  84. package/dist/DonutChart.js.map +1 -1
  85. package/dist/DotDensityMap.cjs +1 -1
  86. package/dist/DotDensityMap.cjs.map +1 -1
  87. package/dist/DotDensityMap.js +265 -268
  88. package/dist/DotDensityMap.js.map +1 -1
  89. package/dist/{DropdownSelect-NNpOs7DX.cjs → DropdownSelect-CX1yMemd.cjs} +2 -2
  90. package/dist/DropdownSelect-CX1yMemd.cjs.map +1 -0
  91. package/dist/{DropdownSelect-B2WTeedJ.js → DropdownSelect-Dz7imdTB.js} +6 -9
  92. package/dist/DropdownSelect-Dz7imdTB.js.map +1 -0
  93. package/dist/DualAxisLineChart.cjs +1 -1
  94. package/dist/DualAxisLineChart.cjs.map +1 -1
  95. package/dist/DualAxisLineChart.d.ts +4 -0
  96. package/dist/DualAxisLineChart.js +336 -332
  97. package/dist/DualAxisLineChart.js.map +1 -1
  98. package/dist/DumbbellChart.cjs +1 -1
  99. package/dist/DumbbellChart.cjs.map +1 -1
  100. package/dist/DumbbellChart.d.ts +2 -0
  101. package/dist/DumbbellChart.js +484 -484
  102. package/dist/DumbbellChart.js.map +1 -1
  103. package/dist/{EmptyState-B4c-CrXs.cjs → EmptyState-CFmiFPHz.cjs} +2 -2
  104. package/dist/{EmptyState-B4c-CrXs.cjs.map → EmptyState-CFmiFPHz.cjs.map} +1 -1
  105. package/dist/{EmptyState-B3fPoH6L.js → EmptyState-CaxXCkiN.js} +4 -4
  106. package/dist/{EmptyState-B3fPoH6L.js.map → EmptyState-CaxXCkiN.js.map} +1 -1
  107. package/dist/ExcelDownloadButton.cjs +1 -1
  108. package/dist/ExcelDownloadButton.js +2 -2
  109. package/dist/FootNote.cjs +1 -1
  110. package/dist/FootNote.js +2 -2
  111. package/dist/GeoHubCompareMaps.cjs +1 -1
  112. package/dist/GeoHubCompareMaps.cjs.map +1 -1
  113. package/dist/GeoHubCompareMaps.js +111 -111
  114. package/dist/GeoHubCompareMaps.js.map +1 -1
  115. package/dist/GeoHubMap.cjs +1 -1
  116. package/dist/GeoHubMap.cjs.map +1 -1
  117. package/dist/GeoHubMap.js +71 -71
  118. package/dist/GeoHubMap.js.map +1 -1
  119. package/dist/GeoHubMapWithLayerSelection.cjs +1 -1
  120. package/dist/GeoHubMapWithLayerSelection.cjs.map +1 -1
  121. package/dist/GeoHubMapWithLayerSelection.js +83 -83
  122. package/dist/GeoHubMapWithLayerSelection.js.map +1 -1
  123. package/dist/{GraphContainer-DwMxWRCi.js → GraphContainer-B8ZqOzKI.js} +2 -2
  124. package/dist/{GraphContainer-DwMxWRCi.js.map → GraphContainer-B8ZqOzKI.js.map} +1 -1
  125. package/dist/{GraphContainer-B1EDxJ0S.cjs → GraphContainer-Cul9b74X.cjs} +2 -2
  126. package/dist/{GraphContainer-B1EDxJ0S.cjs.map → GraphContainer-Cul9b74X.cjs.map} +1 -1
  127. package/dist/GraphDescription.cjs +1 -1
  128. package/dist/GraphDescription.js +2 -2
  129. package/dist/{GraphEl-CnJf8b50.js → GraphEl-B73N4RIA.js} +48 -10
  130. package/dist/GraphEl-B73N4RIA.js.map +1 -0
  131. package/dist/GraphEl-Lt1og0C-.cjs +2 -0
  132. package/dist/GraphEl-Lt1og0C-.cjs.map +1 -0
  133. package/dist/GraphFooter.cjs +1 -1
  134. package/dist/GraphFooter.js +2 -2
  135. package/dist/GraphHeader.cjs +1 -1
  136. package/dist/GraphHeader.js +1 -1
  137. package/dist/GraphTitle.cjs +1 -1
  138. package/dist/GraphTitle.js +2 -2
  139. package/dist/GriddedGraphs.cjs +1 -1
  140. package/dist/GriddedGraphs.d.ts +1 -0
  141. package/dist/GriddedGraphs.js +6 -6
  142. package/dist/GriddedGraphsFromConfig.cjs +1 -1
  143. package/dist/GriddedGraphsFromConfig.d.ts +1 -0
  144. package/dist/GriddedGraphsFromConfig.js +2 -2
  145. package/dist/HeatMap.cjs +1 -1
  146. package/dist/HeatMap.cjs.map +1 -1
  147. package/dist/HeatMap.d.ts +4 -0
  148. package/dist/HeatMap.js +158 -155
  149. package/dist/HeatMap.js.map +1 -1
  150. package/dist/Histogram.cjs +1 -1
  151. package/dist/Histogram.cjs.map +1 -1
  152. package/dist/Histogram.d.ts +2 -0
  153. package/dist/Histogram.js +81 -80
  154. package/dist/Histogram.js.map +1 -1
  155. package/dist/HybridMap.cjs +1 -1
  156. package/dist/HybridMap.cjs.map +1 -1
  157. package/dist/HybridMap.d.ts +2 -0
  158. package/dist/HybridMap.js +314 -315
  159. package/dist/HybridMap.js.map +1 -1
  160. package/dist/ImageDownloadButton.cjs +1 -1
  161. package/dist/ImageDownloadButton.js +2 -2
  162. package/dist/LineChartWithConfidenceInterval.cjs +1 -1
  163. package/dist/LineChartWithConfidenceInterval.cjs.map +1 -1
  164. package/dist/LineChartWithConfidenceInterval.d.ts +2 -0
  165. package/dist/LineChartWithConfidenceInterval.js +367 -365
  166. package/dist/LineChartWithConfidenceInterval.js.map +1 -1
  167. package/dist/LinearColorLegend.cjs +1 -1
  168. package/dist/LinearColorLegend.cjs.map +1 -1
  169. package/dist/LinearColorLegend.d.ts +1 -0
  170. package/dist/LinearColorLegend.js +38 -37
  171. package/dist/LinearColorLegend.js.map +1 -1
  172. package/dist/{Modal-ZX55hLH-.cjs → Modal-BIErPPKT.cjs} +5 -5
  173. package/dist/{Modal-ZX55hLH-.cjs.map → Modal-BIErPPKT.cjs.map} +1 -1
  174. package/dist/{Modal-BV4rkoLM.js → Modal-CrUYln5V.js} +4 -4
  175. package/dist/{Modal-BV4rkoLM.js.map → Modal-CrUYln5V.js.map} +1 -1
  176. package/dist/MultiGraphDashboard.cjs +1 -1
  177. package/dist/MultiGraphDashboard.d.ts +1 -0
  178. package/dist/MultiGraphDashboard.js +4 -4
  179. package/dist/MultiGraphDashboardFromConfig.cjs +1 -1
  180. package/dist/MultiGraphDashboardFromConfig.d.ts +1 -0
  181. package/dist/MultiGraphDashboardFromConfig.js +2 -2
  182. package/dist/MultiGraphDashboardWideToLongFormat.cjs +1 -1
  183. package/dist/MultiGraphDashboardWideToLongFormat.js +4 -4
  184. package/dist/MultiGraphDashboardWideToLongFormatFromConfig.cjs +1 -1
  185. package/dist/MultiGraphDashboardWideToLongFormatFromConfig.js +2 -2
  186. package/dist/MultiLineAltChart.cjs +1 -1
  187. package/dist/MultiLineAltChart.cjs.map +1 -1
  188. package/dist/MultiLineAltChart.d.ts +2 -0
  189. package/dist/MultiLineAltChart.js +419 -420
  190. package/dist/MultiLineAltChart.js.map +1 -1
  191. package/dist/MultiLineChart.cjs +1 -1
  192. package/dist/MultiLineChart.cjs.map +1 -1
  193. package/dist/MultiLineChart.d.ts +4 -0
  194. package/dist/MultiLineChart.js +410 -409
  195. package/dist/MultiLineChart.js.map +1 -1
  196. package/dist/ParetoChart.cjs +1 -1
  197. package/dist/ParetoChart.cjs.map +1 -1
  198. package/dist/ParetoChart.d.ts +2 -0
  199. package/dist/ParetoChart.js +273 -271
  200. package/dist/ParetoChart.js.map +1 -1
  201. package/dist/PerformanceIntensiveMultiGraphDashboard.cjs +1 -1
  202. package/dist/PerformanceIntensiveMultiGraphDashboard.d.ts +1 -0
  203. package/dist/PerformanceIntensiveMultiGraphDashboard.js +4 -4
  204. package/dist/PerformanceIntensiveMultiGraphDashboardFromConfig.cjs +1 -1
  205. package/dist/PerformanceIntensiveMultiGraphDashboardFromConfig.d.ts +1 -0
  206. package/dist/PerformanceIntensiveMultiGraphDashboardFromConfig.js +2 -2
  207. package/dist/PerformanceIntensiveScrollStory.cjs +1 -1
  208. package/dist/PerformanceIntensiveScrollStory.d.ts +1 -0
  209. package/dist/PerformanceIntensiveScrollStory.js +3 -3
  210. package/dist/RadarChart.cjs +1 -1
  211. package/dist/RadarChart.cjs.map +1 -1
  212. package/dist/RadarChart.d.ts +2 -0
  213. package/dist/RadarChart.js +221 -219
  214. package/dist/RadarChart.js.map +1 -1
  215. package/dist/{ReferenceLine-M9aP3dj-.cjs → ReferenceLine-CpU4G01Y.cjs} +2 -2
  216. package/dist/{ReferenceLine-M9aP3dj-.cjs.map → ReferenceLine-CpU4G01Y.cjs.map} +1 -1
  217. package/dist/{ReferenceLine-CNEjAYvv.js → ReferenceLine-D41VuUhE.js} +3 -3
  218. package/dist/{ReferenceLine-CNEjAYvv.js.map → ReferenceLine-D41VuUhE.js.map} +1 -1
  219. package/dist/{RegressionLine-Ci-Dh0w0.cjs → RegressionLine-BFoBiVJk.cjs} +2 -2
  220. package/dist/{RegressionLine-Ci-Dh0w0.cjs.map → RegressionLine-BFoBiVJk.cjs.map} +1 -1
  221. package/dist/{RegressionLine-BDrndQxo.js → RegressionLine-CuwB42I6.js} +4 -4
  222. package/dist/{RegressionLine-BDrndQxo.js.map → RegressionLine-CuwB42I6.js.map} +1 -1
  223. package/dist/SVGDownloadButton.cjs +1 -1
  224. package/dist/SVGDownloadButton.js +2 -2
  225. package/dist/SankeyChart.cjs +1 -1
  226. package/dist/SankeyChart.cjs.map +1 -1
  227. package/dist/SankeyChart.d.ts +2 -0
  228. package/dist/SankeyChart.js +404 -408
  229. package/dist/SankeyChart.js.map +1 -1
  230. package/dist/ScatterPlot.cjs +1 -1
  231. package/dist/ScatterPlot.cjs.map +1 -1
  232. package/dist/ScatterPlot.d.ts +2 -0
  233. package/dist/ScatterPlot.js +444 -445
  234. package/dist/ScatterPlot.js.map +1 -1
  235. package/dist/ScrollStory.cjs +1 -1
  236. package/dist/ScrollStory.d.ts +1 -0
  237. package/dist/ScrollStory.js +3 -3
  238. package/dist/SimpleLineChart.cjs +1 -1
  239. package/dist/SimpleLineChart.cjs.map +1 -1
  240. package/dist/SimpleLineChart.d.ts +2 -0
  241. package/dist/SimpleLineChart.js +360 -358
  242. package/dist/SimpleLineChart.js.map +1 -1
  243. package/dist/SingleGraphDashboard.cjs +1 -1
  244. package/dist/SingleGraphDashboard.d.ts +1 -0
  245. package/dist/SingleGraphDashboard.js +6 -6
  246. package/dist/SingleGraphDashboardFromConfig.cjs +1 -1
  247. package/dist/SingleGraphDashboardFromConfig.d.ts +1 -0
  248. package/dist/SingleGraphDashboardFromConfig.js +2 -2
  249. package/dist/SingleGraphDashboardGeoHubMaps.cjs +1 -1
  250. package/dist/SingleGraphDashboardGeoHubMaps.d.ts +1 -0
  251. package/dist/SingleGraphDashboardGeoHubMaps.js +3 -3
  252. package/dist/SingleGraphDashboardGeoHubMapsFromConfig.cjs +1 -1
  253. package/dist/SingleGraphDashboardGeoHubMapsFromConfig.d.ts +1 -0
  254. package/dist/SingleGraphDashboardGeoHubMapsFromConfig.js +2 -2
  255. package/dist/SingleGraphDashboardThreeDGraphs.cjs +1 -1
  256. package/dist/SingleGraphDashboardThreeDGraphs.d.ts +1 -0
  257. package/dist/SingleGraphDashboardThreeDGraphs.js +6 -6
  258. package/dist/SingleGraphDashboardThreeDGraphsFromConfig.cjs +1 -1
  259. package/dist/SingleGraphDashboardThreeDGraphsFromConfig.d.ts +1 -0
  260. package/dist/SingleGraphDashboardThreeDGraphsFromConfig.js +2 -2
  261. package/dist/SlopeChart.cjs +1 -1
  262. package/dist/SlopeChart.cjs.map +1 -1
  263. package/dist/SlopeChart.js +259 -262
  264. package/dist/SlopeChart.js.map +1 -1
  265. package/dist/{Source-BOSAl3UX.cjs → Source-PKuwZOn3.cjs} +2 -2
  266. package/dist/{Source-BOSAl3UX.cjs.map → Source-PKuwZOn3.cjs.map} +1 -1
  267. package/dist/{Source-Djkz-7jX.js → Source-QGk8vhkS.js} +3 -3
  268. package/dist/{Source-Djkz-7jX.js.map → Source-QGk8vhkS.js.map} +1 -1
  269. package/dist/Source.cjs +1 -1
  270. package/dist/Source.js +3 -3
  271. package/dist/SparkLine.cjs +1 -1
  272. package/dist/SparkLine.js +3 -3
  273. package/dist/{Spinner-CtJETd5V.js → Spinner-B2IIKg9r.js} +2 -2
  274. package/dist/{Spinner-CtJETd5V.js.map → Spinner-B2IIKg9r.js.map} +1 -1
  275. package/dist/{Spinner-jTMOLuw_.cjs → Spinner-WHzzloYQ.cjs} +2 -2
  276. package/dist/{Spinner-jTMOLuw_.cjs.map → Spinner-WHzzloYQ.cjs.map} +1 -1
  277. package/dist/StatCardFromData.cjs +1 -1
  278. package/dist/StatCardFromData.cjs.map +1 -1
  279. package/dist/StatCardFromData.d.ts +4 -0
  280. package/dist/StatCardFromData.js +97 -95
  281. package/dist/StatCardFromData.js.map +1 -1
  282. package/dist/StripChart.cjs +1 -1
  283. package/dist/StripChart.cjs.map +1 -1
  284. package/dist/StripChart.d.ts +2 -0
  285. package/dist/StripChart.js +343 -343
  286. package/dist/StripChart.js.map +1 -1
  287. package/dist/ThreeDGlobe.cjs +1 -1
  288. package/dist/ThreeDGlobe.cjs.map +1 -1
  289. package/dist/ThreeDGlobe.d.ts +2 -0
  290. package/dist/ThreeDGlobe.js +198 -196
  291. package/dist/ThreeDGlobe.js.map +1 -1
  292. package/dist/ThresholdColorLegendWithMouseOver.cjs +1 -1
  293. package/dist/ThresholdColorLegendWithMouseOver.cjs.map +1 -1
  294. package/dist/ThresholdColorLegendWithMouseOver.d.ts +2 -0
  295. package/dist/ThresholdColorLegendWithMouseOver.js +50 -48
  296. package/dist/ThresholdColorLegendWithMouseOver.js.map +1 -1
  297. package/dist/{Tooltip-CohiIbLZ.js → Tooltip-Bj-s__cI.js} +3 -3
  298. package/dist/{Tooltip-CohiIbLZ.js.map → Tooltip-Bj-s__cI.js.map} +1 -1
  299. package/dist/{Tooltip-BLa2EfMs.cjs → Tooltip-Hr46paWP.cjs} +2 -2
  300. package/dist/{Tooltip-BLa2EfMs.cjs.map → Tooltip-Hr46paWP.cjs.map} +1 -1
  301. package/dist/TreeMapGraph.cjs +1 -1
  302. package/dist/TreeMapGraph.cjs.map +1 -1
  303. package/dist/TreeMapGraph.d.ts +2 -0
  304. package/dist/TreeMapGraph.js +139 -140
  305. package/dist/TreeMapGraph.js.map +1 -1
  306. package/dist/Types.d.ts +1 -0
  307. package/dist/{Typography-DMVW6JnV.js → Typography-BO0gQDIT.js} +2 -2
  308. package/dist/{Typography-DMVW6JnV.js.map → Typography-BO0gQDIT.js.map} +1 -1
  309. package/dist/{Typography-CZZxlj1W.cjs → Typography-BqmyF1gP.cjs} +2 -2
  310. package/dist/{Typography-CZZxlj1W.cjs.map → Typography-BqmyF1gP.cjs.map} +1 -1
  311. package/dist/UnitChart.cjs +1 -1
  312. package/dist/UnitChart.cjs.map +1 -1
  313. package/dist/UnitChart.d.ts +4 -0
  314. package/dist/UnitChart.js +88 -86
  315. package/dist/UnitChart.js.map +1 -1
  316. package/dist/WaterfallChart.cjs +1 -1
  317. package/dist/WaterfallChart.cjs.map +1 -1
  318. package/dist/WaterfallChart.d.ts +2 -0
  319. package/dist/WaterfallChart.js +257 -258
  320. package/dist/WaterfallChart.js.map +1 -1
  321. package/dist/{XAxesLabels-IwjMJkYS.js → XAxesLabels-B9gkjUiC.js} +3 -3
  322. package/dist/{XAxesLabels-IwjMJkYS.js.map → XAxesLabels-B9gkjUiC.js.map} +1 -1
  323. package/dist/{XAxesLabels-C6o9jJal.cjs → XAxesLabels-C03jHniq.cjs} +2 -2
  324. package/dist/{XAxesLabels-C6o9jJal.cjs.map → XAxesLabels-C03jHniq.cjs.map} +1 -1
  325. package/dist/XTicksAndGridLines-C5DuC5oY.cjs +2 -0
  326. package/dist/XTicksAndGridLines-C5DuC5oY.cjs.map +1 -0
  327. package/dist/XTicksAndGridLines-gdbGX2rm.js +39 -0
  328. package/dist/XTicksAndGridLines-gdbGX2rm.js.map +1 -0
  329. package/dist/{YAxesLabels-BQ2aCazV.cjs → YAxesLabels-DeENFC2M.cjs} +2 -2
  330. package/dist/{YAxesLabels-BQ2aCazV.cjs.map → YAxesLabels-DeENFC2M.cjs.map} +1 -1
  331. package/dist/{YAxesLabels-DoGvgHdw.js → YAxesLabels-hWEUCTvs.js} +3 -3
  332. package/dist/{YAxesLabels-DoGvgHdw.js.map → YAxesLabels-hWEUCTvs.js.map} +1 -1
  333. package/dist/YTicksAndGridLines-CsNSq9W9.js +39 -0
  334. package/dist/YTicksAndGridLines-CsNSq9W9.js.map +1 -0
  335. package/dist/YTicksAndGridLines-DFjm8RCc.cjs +2 -0
  336. package/dist/YTicksAndGridLines-DFjm8RCc.cjs.map +1 -0
  337. package/dist/{checkIfMultiple-TOaaUwS7.cjs → checkIfMultiple-CH5tqj4q.cjs} +2 -2
  338. package/dist/checkIfMultiple-CH5tqj4q.cjs.map +1 -0
  339. package/dist/{checkIfMultiple-B97uOUVq.js → checkIfMultiple-Dpyy6BUP.js} +6 -6
  340. package/dist/checkIfMultiple-Dpyy6BUP.js.map +1 -0
  341. package/dist/{customArea-B1LWQBmM.cjs → customArea-BAcQ3pBM.cjs} +2 -2
  342. package/dist/{customArea-B1LWQBmM.cjs.map → customArea-BAcQ3pBM.cjs.map} +1 -1
  343. package/dist/{customArea-Cc2whe6P.js → customArea-D89lETG0.js} +3 -3
  344. package/dist/{customArea-Cc2whe6P.js.map → customArea-D89lETG0.js.map} +1 -1
  345. package/dist/getSliderMarks-BzrpHrHS.cjs +2 -0
  346. package/dist/getSliderMarks-BzrpHrHS.cjs.map +1 -0
  347. package/dist/{getSliderMarks-vXsR8RrR.js → getSliderMarks-X-_goqH9.js} +3 -4
  348. package/dist/getSliderMarks-X-_goqH9.js.map +1 -0
  349. package/dist/{index-CZ0elhKR.js → index-ApTBN0kp.js} +20 -10
  350. package/dist/{index-CZ0elhKR.js.map → index-ApTBN0kp.js.map} +1 -1
  351. package/dist/index-B0Awa_de.js +377 -0
  352. package/dist/index-B0Awa_de.js.map +1 -0
  353. package/dist/{index-sbKVyHS2.cjs → index-BhI7mBJx.cjs} +2 -2
  354. package/dist/{index-sbKVyHS2.cjs.map → index-BhI7mBJx.cjs.map} +1 -1
  355. package/dist/{index-D69M6klB.cjs → index-BuhBhuCq.cjs} +2 -2
  356. package/dist/{index-D69M6klB.cjs.map → index-BuhBhuCq.cjs.map} +1 -1
  357. package/dist/{index-CHPV5EwG-BCLAYDCV.js → index-CHPV5EwG-BzibaIRc.js} +5 -9
  358. package/dist/index-CHPV5EwG-BzibaIRc.js.map +1 -0
  359. package/dist/{index-CHPV5EwG-6v2a2njQ.cjs → index-CHPV5EwG-D4pAp7u0.cjs} +3 -3
  360. package/dist/index-CHPV5EwG-D4pAp7u0.cjs.map +1 -0
  361. package/dist/index-CP8cmNzt.cjs +2 -0
  362. package/dist/index-CP8cmNzt.cjs.map +1 -0
  363. package/dist/{index-Co3YGYe1.js → index-Cv_5q6Rb.js} +3 -3
  364. package/dist/{index-Co3YGYe1.js.map → index-Cv_5q6Rb.js.map} +1 -1
  365. package/dist/{index-D_dtv_T9.js → index-DHVGV8Df.js} +3 -3
  366. package/dist/{index-D_dtv_T9.js.map → index-DHVGV8Df.js.map} +1 -1
  367. package/dist/{index-CoobIWNj.cjs → index-FXfr51ZM.cjs} +2 -2
  368. package/dist/{index-CoobIWNj.cjs.map → index-FXfr51ZM.cjs.map} +1 -1
  369. package/dist/{index-D6CYcVc7-BOa7Dpvf.js → index-Scxs_wcm-BAjU0Cob.js} +16 -16
  370. package/dist/index-Scxs_wcm-BAjU0Cob.js.map +1 -0
  371. package/dist/index-Scxs_wcm-DUDU-Gll.cjs +2 -0
  372. package/dist/index-Scxs_wcm-DUDU-Gll.cjs.map +1 -0
  373. package/dist/{index-DoS4bGNa-C3DbPpy3.cjs → index-w64Zl8io-DrMm5QSb.cjs} +2 -2
  374. package/dist/index-w64Zl8io-DrMm5QSb.cjs.map +1 -0
  375. package/dist/{index-DoS4bGNa-Bgab95kx.js → index-w64Zl8io-ihagHOdP.js} +2 -2
  376. package/dist/index-w64Zl8io-ihagHOdP.js.map +1 -0
  377. package/dist/index.cjs +1 -1
  378. package/dist/index.d.ts +92 -17
  379. package/dist/index.js +3 -3
  380. package/dist/numberFormattingFunction-Cn9R7CM9.cjs +2 -0
  381. package/dist/numberFormattingFunction-Cn9R7CM9.cjs.map +1 -0
  382. package/dist/numberFormattingFunction-DqMf_v1m.js +28 -0
  383. package/dist/numberFormattingFunction-DqMf_v1m.js.map +1 -0
  384. package/dist/{proxy--_f6k3NR.js → proxy-BsxtcZKa.js} +2 -2
  385. package/dist/{proxy--_f6k3NR.js.map → proxy-BsxtcZKa.js.map} +1 -1
  386. package/dist/{proxy-C4-uo6nS.cjs → proxy-CqH8m8IQ.cjs} +2 -2
  387. package/dist/{proxy-C4-uo6nS.cjs.map → proxy-CqH8m8IQ.cjs.map} +1 -1
  388. package/dist/{string2HTML-DUYZT1L9.js → string2HTML-BrFperRM.js} +2 -2
  389. package/dist/{string2HTML-DUYZT1L9.js.map → string2HTML-BrFperRM.js.map} +1 -1
  390. package/dist/{string2HTML-xx9MzTtY.cjs → string2HTML-ZoGd08P_.cjs} +2 -2
  391. package/dist/{string2HTML-xx9MzTtY.cjs.map → string2HTML-ZoGd08P_.cjs.map} +1 -1
  392. package/dist/style.css +1 -1
  393. package/dist/{use-in-view-DqvKAveg.js → use-in-view-KOXq5Kmc.js} +2 -2
  394. package/dist/{use-in-view-DqvKAveg.js.map → use-in-view-KOXq5Kmc.js.map} +1 -1
  395. package/dist/{use-in-view-C3o_ntMv.cjs → use-in-view-dnRv_qqF.cjs} +2 -2
  396. package/dist/{use-in-view-C3o_ntMv.cjs.map → use-in-view-dnRv_qqF.cjs.map} +1 -1
  397. package/dist/utils.cjs +1 -1
  398. package/dist/utils.d.ts +9 -18
  399. package/dist/utils.js +1 -1
  400. package/dist/x-BXShoIAM-BC2sxios.cjs +2 -0
  401. package/dist/x-BXShoIAM-BC2sxios.cjs.map +1 -0
  402. package/dist/{x-BBpi7a_7-BsvWCzYM.js → x-BXShoIAM-D6VWO6z5.js} +3 -5
  403. package/dist/x-BXShoIAM-D6VWO6z5.js.map +1 -0
  404. package/package.json +2 -2
  405. package/dist/DropdownSelect-B2WTeedJ.js.map +0 -1
  406. package/dist/DropdownSelect-NNpOs7DX.cjs.map +0 -1
  407. package/dist/GraphEl-CnJf8b50.js.map +0 -1
  408. package/dist/GraphEl-D_w0Qak4.cjs +0 -2
  409. package/dist/GraphEl-D_w0Qak4.cjs.map +0 -1
  410. package/dist/XTicksAndGridLines-BDmF9etl.js +0 -38
  411. package/dist/XTicksAndGridLines-BDmF9etl.js.map +0 -1
  412. package/dist/XTicksAndGridLines-CekrPykD.cjs +0 -2
  413. package/dist/XTicksAndGridLines-CekrPykD.cjs.map +0 -1
  414. package/dist/YTicksAndGridLines-C3GW1xFG.js +0 -38
  415. package/dist/YTicksAndGridLines-C3GW1xFG.js.map +0 -1
  416. package/dist/YTicksAndGridLines-UzVC5eBM.cjs +0 -2
  417. package/dist/YTicksAndGridLines-UzVC5eBM.cjs.map +0 -1
  418. package/dist/checkIfMultiple-B97uOUVq.js.map +0 -1
  419. package/dist/checkIfMultiple-TOaaUwS7.cjs.map +0 -1
  420. package/dist/getSliderMarks-CIuSoedo.cjs +0 -2
  421. package/dist/getSliderMarks-CIuSoedo.cjs.map +0 -1
  422. package/dist/getSliderMarks-vXsR8RrR.js.map +0 -1
  423. package/dist/index-C6VwVS8W.js +0 -378
  424. package/dist/index-C6VwVS8W.js.map +0 -1
  425. package/dist/index-CHPV5EwG-6v2a2njQ.cjs.map +0 -1
  426. package/dist/index-CHPV5EwG-BCLAYDCV.js.map +0 -1
  427. package/dist/index-D6CYcVc7-BOa7Dpvf.js.map +0 -1
  428. package/dist/index-D6CYcVc7-CTEcAtiQ.cjs +0 -2
  429. package/dist/index-D6CYcVc7-CTEcAtiQ.cjs.map +0 -1
  430. package/dist/index-DoS4bGNa-Bgab95kx.js.map +0 -1
  431. package/dist/index-DoS4bGNa-C3DbPpy3.cjs.map +0 -1
  432. package/dist/index-_TlgeI_i.cjs +0 -2
  433. package/dist/index-_TlgeI_i.cjs.map +0 -1
  434. package/dist/numberFormattingFunction-02t-wJta.cjs +0 -2
  435. package/dist/numberFormattingFunction-02t-wJta.cjs.map +0 -1
  436. package/dist/numberFormattingFunction-14YCbkN2.js +0 -13
  437. package/dist/numberFormattingFunction-14YCbkN2.js.map +0 -1
  438. package/dist/x-BBpi7a_7-BsvWCzYM.js.map +0 -1
  439. package/dist/x-BBpi7a_7-DXYIEFwN.cjs +0 -2
  440. package/dist/x-BBpi7a_7-DXYIEFwN.cjs.map +0 -1
@@ -1,5 +1,5 @@
1
- import { c as v, j as f } from "./index-CHPV5EwG-BCLAYDCV.js";
2
- import { d as w, u as j } from "./index-CZ0elhKR.js";
1
+ import { c as v, j as f } from "./index-CHPV5EwG-BzibaIRc.js";
2
+ import { d as w, u as j } from "./index-ApTBN0kp.js";
3
3
  import { e as y } from "./excelDownload-BEC1AyQW.js";
4
4
  function $(N) {
5
5
  const t = v.c(13), {
package/dist/FootNote.cjs CHANGED
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("./index-CHPV5EwG-6v2a2njQ.cjs"),m=require("./Typography-CZZxlj1W.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._,{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;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("./index-CHPV5EwG-D4pAp7u0.cjs"),m=require("./Typography-BqmyF1gP.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._,{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.js CHANGED
@@ -1,5 +1,5 @@
1
- import { c, m as f, j as a } from "./index-CHPV5EwG-BCLAYDCV.js";
2
- import { _ as p } from "./Typography-DMVW6JnV.js";
1
+ import { c, m as f, j as a } from "./index-CHPV5EwG-BzibaIRc.js";
2
+ import { _ as p } from "./Typography-BO0gQDIT.js";
3
3
  import x from "react";
4
4
  function g(m) {
5
5
  const t = c.c(12), {
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("./index-CHPV5EwG-6v2a2njQ.cjs"),a=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-sbKVyHS2.cjs"),me=require("./string2HTML-xx9MzTtY.cjs"),se=require("./select-Bnfk0lJx.cjs"),fe=require("./GraphHeader.cjs"),pe=require("./GraphFooter.cjs"),ne=require("./GraphContainer-B1EDxJ0S.cjs");function le(m){const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(m){for(const n in m)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(m,n);Object.defineProperty(e,n,r.get?r:{enumerable:!0,get:()=>m[n]})}}return e.default=m,Object.freeze(e)}const T=le(ce),de=le(ae);function ge(m,e){let n=!1;function r(o,f){if(!n){n=!0;const u=o.getCenter(),i=o.getZoom(),s=o.getBearing(),p=o.getPitch();f.jumpTo({center:u,zoom:i,bearing:s,pitch:p}),n=!1}}m.on("move",()=>{r(m,e)}),e.on("move",()=>{r(e,m)})}function he(m){const e=t.compilerRuntimeExports.c(47),{height:n,width:r,mapStyles:o,center:f,zoomLevel:u,mapLegend:i}=m,[s,p]=a.useState(50),[x,b]=a.useState(!1),y=a.useRef(null),[N,W]=a.useState(!0),B=a.useRef(50),$=a.useRef(0);let q;e[0]===Symbol.for("react.memo_cache_sentinel")?(q={activationConstraint:{distance:0}},e[0]=q):q=e[0];const G=Q.useSensors(Q.useSensor(Q.PointerSensor,q));let l;e[1]!==s?(l=()=>{b(!0),B.current=s,y.current&&($.current=y.current.getBoundingClientRect().width)},e[1]=s,e[2]=l):l=e[2];const c=l;let z;e[3]===Symbol.for("react.memo_cache_sentinel")?(z=Y=>{if(!y.current||$.current===0)return;const K=Y.delta.x/$.current*100,ee=Math.max(0,Math.min(100,B.current+K));p(ee)},e[3]=z):z=e[3];const F=z;let S;e[4]===Symbol.for("react.memo_cache_sentinel")?(S=()=>{b(!1)},e[4]=S):S=e[4];const Z=S;let P;e[5]!==x?(P=Y=>{if(x||!y.current)return;const K=y.current.getBoundingClientRect(),te=(Y.clientX-K.left)/K.width*100;p(Math.max(0,Math.min(100,te)))},e[5]=x,e[6]=P):P=e[6];const L=P,V=a.useRef(null),k=a.useRef(null),E=a.useRef(null),J=a.useRef(null);let C,A;e[7]!==f||e[8]!==o||e[9]!==r||e[10]!==u?(C=()=>{if(J.current&&k.current&&E.current&&r){se.select(J.current).selectAll(".maplibregl-compare").remove(),se.select(k.current).selectAll("div").remove(),se.select(E.current).selectAll("div").remove();const te=new de.Protocol;T.addProtocol("pmtiles",te.tile);const re=new T.Map({container:k.current,style:o[0],center:f||[0,0],zoom:u||4}),oe=new T.Map({container:E.current,style:o[1],center:f||[0,0],zoom:u||4});oe.addControl(new T.NavigationControl({visualizePitch:!0,showZoom:!0,showCompass:!0}),"bottom-right"),re.addControl(new T.ScaleControl,"bottom-left"),re.addControl(new T.NavigationControl({visualizePitch:!0,showZoom:!0,showCompass:!0}),"bottom-right"),oe.addControl(new T.ScaleControl,"bottom-left"),ge(re,oe)}},A=[r,o,f,u],e[7]=f,e[8]=o,e[9]=r,e[10]=u,e[11]=C,e[12]=A):(C=e[11],A=e[12]),a.useEffect(C,A);let j;e[13]!==n||e[14]!==r?(j={width:r,height:n},e[13]=n,e[14]=r,e[15]=j):j=e[15];let I;e[16]===Symbol.for("react.memo_cache_sentinel")?(I={inset:0},e[16]=I):I=e[16];let _;e[17]===Symbol.for("react.memo_cache_sentinel")?(_=[ue.restrictToHorizontalAxis],e[17]=_):_=e[17];const H=x?"grabbing":"col-resize";let R;e[18]!==n||e[19]!==H||e[20]!==r?(R={position:"relative",width:r,height:n,overflow:"hidden",cursor:H,userSelect:"none"},e[18]=n,e[19]=H,e[20]=r,e[21]=R):R=e[21];const O=`polygon(${s}% 0%, ${s}% 100%, 100% 100%, 100% 0%)`;let d;e[22]!==O?(d=t.jsxRuntimeExports.jsx("div",{ref:E,className:"absolute h-full rightMap w-full",style:{position:"absolute",top:0,left:0,clipPath:O}}),e[22]=O,e[23]=d):d=e[23];const w=`polygon(0% 0%, ${s}% 0%, ${s}% 100%, 0% 100%)`;let g;e[24]!==w?(g=t.jsxRuntimeExports.jsx("div",{ref:k,className:"absolute h-full leftMap w-full",style:{position:"absolute",top:0,left:0,inset:0,clipPath:w}}),e[24]=w,e[25]=g):g=e[25];let h;e[26]!==s?(h=t.jsxRuntimeExports.jsx(xe,{position:s}),e[26]=s,e[27]=h):h=e[27];let v;e[28]!==L||e[29]!==R||e[30]!==d||e[31]!==g||e[32]!==h?(v=t.jsxRuntimeExports.jsxs("div",{ref:y,style:R,onClick:L,children:[d,g,h]}),e[28]=L,e[29]=R,e[30]=d,e[31]=g,e[32]=h,e[33]=v):v=e[33];let M;e[34]!==c||e[35]!==G||e[36]!==v?(M=t.jsxRuntimeExports.jsx("div",{ref:J,className:"map maplibre-show-control relative w-full h-full",style:I,children:t.jsxRuntimeExports.jsx(Q.DndContext,{sensors:G,modifiers:_,onDragStart:c,onDragMove:F,onDragEnd:Z,children:v})}),e[34]=c,e[35]=G,e[36]=v,e[37]=M):M=e[37];let D;e[38]!==M||e[39]!==j?(D=t.jsxRuntimeExports.jsx("div",{style:j,children:M}),e[38]=M,e[39]=j,e[40]=D):D=e[40];let X;e[41]!==i||e[42]!==N?(X=i?t.jsxRuntimeExports.jsx("div",{className:"absolute left-[22px] bottom-13",children:N?t.jsxRuntimeExports.jsxs(t.jsxRuntimeExports.Fragment,{children:[t.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:()=>{W(!1)},children:t.jsxRuntimeExports.jsx(ie.X,{})}),t.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 i=="string"?{__html:me.string2HTML(i)}:void 0,children:a.isValidElement(i)?i:null})]}):t.jsxRuntimeExports.jsx("button",{type:"button",className:"mb-0 border-0 bg-transparent p-0 self-start",onClick:()=>{W(!0)},children:t.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]=i,e[42]=N,e[43]=X):X=e[43];let U;return e[44]!==D||e[45]!==X?(U=t.jsxRuntimeExports.jsxs("div",{className:"flex flex-col grow justify-center leading-0",ref:V,"aria-label":"Map area",children:[D,X]}),e[44]=D,e[45]=X,e[46]=U):U=e[46],U}function xe(m){const e=t.compilerRuntimeExports.c(10),{position:n}=m;let r;e[0]===Symbol.for("react.memo_cache_sentinel")?(r={id:"slider-handle"},e[0]=r):r=e[0];const{attributes:o,listeners:f,setNodeRef:u}=Q.useDraggable(r),i=`${n}%`;let s;e[1]!==i?(s={position:"absolute",left:i,top:0,bottom:0,width:"40px",transform:"translateX(-50%)",cursor:"col-resize",display:"flex",justifyContent:"center",alignItems:"center",zIndex:10,touchAction:"none"},e[1]=i,e[2]=s):s=e[2];let p;e[3]===Symbol.for("react.memo_cache_sentinel")?(p=t.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=t.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:t.jsxRuntimeExports.jsx(ie.ChevronLeftRight,{})}),e[4]=x):x=e[4];let b;return e[5]!==o||e[6]!==f||e[7]!==u||e[8]!==s?(b=t.jsxRuntimeExports.jsxs("div",{ref:u,style:s,...f,...o,children:[p,x]}),e[5]=o,e[6]=f,e[7]=u,e[8]=s,e[9]=b):b=e[9],b}function be(m){const e=t.compilerRuntimeExports.c(45),{graphTitle:n,height:r,width:o,relativeHeight:f,sources:u,graphDescription:i,footNote:s,padding:p,backgroundColor:x,graphID:b,mapStyles:y,center:N,zoomLevel:W,language:B,minHeight:$,theme:q,ariaLabel:G,styles:l,classNames:c,mapLegend:z}=m,F=x===void 0?!1:x;let S;e[0]!==N?(S=N===void 0?[0,0]:N,e[0]=N,e[1]=S):S=e[1];const Z=S,P=W===void 0?3:W,L=B===void 0?"en":B,V=$===void 0?0:$,k=q===void 0?"light":q,[E,J]=a.useState(0),[C,A]=a.useState(0),j=a.useRef(null),I=a.useRef(null);let _,H;e[2]===Symbol.for("react.memo_cache_sentinel")?(_=()=>{const M=new ResizeObserver(D=>{J(D[0].target.clientWidth||620),A(D[0].target.clientHeight||480)});return j.current&&M.observe(j.current),()=>M.disconnect()},H=[],e[2]=_,e[3]=H):(_=e[2],H=e[3]),a.useEffect(_,H);const R=c?.graphContainer,O=l?.graphContainer;let d;e[4]!==c?.description||e[5]!==c?.title||e[6]!==i||e[7]!==n||e[8]!==l?.description||e[9]!==l?.title||e[10]!==o?(d=n||i?t.jsxRuntimeExports.jsx(fe.GraphHeader,{styles:{title:l?.title,description:l?.description},classNames:{title:c?.title,description:c?.description},graphTitle:n,graphDescription:i,width:o}):null,e[4]=c?.description,e[5]=c?.title,e[6]=i,e[7]=n,e[8]=l?.description,e[9]=l?.title,e[10]=o,e[11]=d):d=e[11];let w;e[12]!==Z||e[13]!==z||e[14]!==y||e[15]!==C||e[16]!==E||e[17]!==P?(w=E&&C?t.jsxRuntimeExports.jsx(he,{width:E,height:C,mapStyles:y,center:Z,zoomLevel:P,mapLegend:z}):null,e[12]=Z,e[13]=z,e[14]=y,e[15]=C,e[16]=E,e[17]=P,e[18]=w):w=e[18];let g;e[19]!==w?(g=t.jsxRuntimeExports.jsx(ne.GraphArea,{ref:j,children:w}),e[19]=w,e[20]=g):g=e[20];let h;e[21]!==c?.footnote||e[22]!==c?.source||e[23]!==s||e[24]!==u||e[25]!==l?.footnote||e[26]!==l?.source||e[27]!==o?(h=u||s?t.jsxRuntimeExports.jsx(pe.GraphFooter,{styles:{footnote:l?.footnote,source:l?.source},classNames:{footnote:c?.footnote,source:c?.source},sources:u,footNote:s,width:o}):null,e[21]=c?.footnote,e[22]=c?.source,e[23]=s,e[24]=u,e[25]=l?.footnote,e[26]=l?.source,e[27]=o,e[28]=h):h=e[28];let v;return e[29]!==G||e[30]!==F||e[31]!==b||e[32]!==r||e[33]!==L||e[34]!==V||e[35]!==p||e[36]!==f||e[37]!==O||e[38]!==d||e[39]!==g||e[40]!==h||e[41]!==R||e[42]!==k||e[43]!==o?(v=t.jsxRuntimeExports.jsxs(ne.GraphContainer,{className:R,style:O,id:b,ref:I,"aria-label":G,backgroundColor:F,theme:k,language:L,minHeight:V,width:o,height:r,relativeHeight:f,padding:p,children:[d,g,h]}),e[29]=G,e[30]=F,e[31]=b,e[32]=r,e[33]=L,e[34]=V,e[35]=p,e[36]=f,e[37]=O,e[38]=d,e[39]=g,e[40]=h,e[41]=R,e[42]=k,e[43]=o,e[44]=v):v=e[44],v}exports.GeoHubCompareMaps=be;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("./index-CHPV5EwG-D4pAp7u0.cjs"),a=require("react"),ce=require("maplibre-gl"),ae=require("pmtiles");;/* empty css */const Q=require("@dnd-kit/core"),ue=require("@dnd-kit/modifiers"),ne=require("./index-BhI7mBJx.cjs"),me=require("./string2HTML-ZoGd08P_.cjs"),re=require("./select-Bnfk0lJx.cjs"),fe=require("./GraphHeader.cjs"),pe=require("./GraphFooter.cjs"),ie=require("./GraphContainer-Cul9b74X.cjs");function le(m){const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(m){for(const n in m)if(n!=="default"){const o=Object.getOwnPropertyDescriptor(m,n);Object.defineProperty(e,n,o.get?o:{enumerable:!0,get:()=>m[n]})}}return e.default=m,Object.freeze(e)}const T=le(ce),de=le(ae);function ge(m,e){let n=!1;function o(s,f){if(!n){n=!0;const u=s.getCenter(),i=s.getZoom(),r=s.getBearing(),p=s.getPitch();f.jumpTo({center:u,zoom:i,bearing:r,pitch:p}),n=!1}}m.on("move",()=>{o(m,e)}),e.on("move",()=>{o(e,m)})}function he(m){const e=t.compilerRuntimeExports.c(47),{height:n,width:o,mapStyles:s,center:f,zoomLevel:u,mapLegend:i}=m,[r,p]=a.useState(50),[x,b]=a.useState(!1),j=a.useRef(null),[N,W]=a.useState(!0),B=a.useRef(50),$=a.useRef(0);let q;e[0]===Symbol.for("react.memo_cache_sentinel")?(q={activationConstraint:{distance:0}},e[0]=q):q=e[0];const G=Q.useSensors(Q.useSensor(Q.PointerSensor,q));let l;e[1]!==r?(l=()=>{b(!0),B.current=r,j.current&&($.current=j.current.getBoundingClientRect().width)},e[1]=r,e[2]=l):l=e[2];const c=l;let z;e[3]===Symbol.for("react.memo_cache_sentinel")?(z=Y=>{if(!j.current||$.current===0)return;const K=Y.delta.x/$.current*100,ee=Math.max(0,Math.min(100,B.current+K));p(ee)},e[3]=z):z=e[3];const F=z;let S;e[4]===Symbol.for("react.memo_cache_sentinel")?(S=()=>{b(!1)},e[4]=S):S=e[4];const Z=S;let P;e[5]!==x?(P=Y=>{if(x||!j.current)return;const K=j.current.getBoundingClientRect(),te=(Y.clientX-K.left)/K.width*100;p(Math.max(0,Math.min(100,te)))},e[5]=x,e[6]=P):P=e[6];const L=P,V=a.useRef(null),H=a.useRef(null),E=a.useRef(null),J=a.useRef(null);let C,A;e[7]!==f||e[8]!==s||e[9]!==o||e[10]!==u?(C=()=>{if(J.current&&H.current&&E.current&&o){re.select(J.current).selectAll(".maplibregl-compare").remove(),re.select(H.current).selectAll("div").remove(),re.select(E.current).selectAll("div").remove();const te=new de.Protocol;T.addProtocol("pmtiles",te.tile);const oe=new T.Map({container:H.current,style:s[0],center:f||[0,0],zoom:u||4}),se=new T.Map({container:E.current,style:s[1],center:f||[0,0],zoom:u||4});se.addControl(new T.NavigationControl({visualizePitch:!0,showZoom:!0,showCompass:!0}),"bottom-right"),oe.addControl(new T.ScaleControl,"bottom-left"),oe.addControl(new T.NavigationControl({visualizePitch:!0,showZoom:!0,showCompass:!0}),"bottom-right"),se.addControl(new T.ScaleControl,"bottom-left"),ge(oe,se)}},A=[o,s,f,u],e[7]=f,e[8]=s,e[9]=o,e[10]=u,e[11]=C,e[12]=A):(C=e[11],A=e[12]),a.useEffect(C,A);let y;e[13]!==n||e[14]!==o?(y={width:o,height:n},e[13]=n,e[14]=o,e[15]=y):y=e[15];let I;e[16]===Symbol.for("react.memo_cache_sentinel")?(I={inset:0},e[16]=I):I=e[16];let _;e[17]===Symbol.for("react.memo_cache_sentinel")?(_=[ue.restrictToHorizontalAxis],e[17]=_):_=e[17];const k=x?"grabbing":"col-resize";let R;e[18]!==n||e[19]!==k||e[20]!==o?(R={position:"relative",width:o,height:n,overflow:"hidden",cursor:k,userSelect:"none"},e[18]=n,e[19]=k,e[20]=o,e[21]=R):R=e[21];const O=`polygon(${r}% 0%, ${r}% 100%, 100% 100%, 100% 0%)`;let d;e[22]!==O?(d=t.jsxRuntimeExports.jsx("div",{ref:E,className:"absolute h-full rightMap w-full",style:{position:"absolute",top:0,left:0,clipPath:O}}),e[22]=O,e[23]=d):d=e[23];const w=`polygon(0% 0%, ${r}% 0%, ${r}% 100%, 0% 100%)`;let g;e[24]!==w?(g=t.jsxRuntimeExports.jsx("div",{ref:H,className:"absolute h-full leftMap w-full",style:{position:"absolute",top:0,left:0,inset:0,clipPath:w}}),e[24]=w,e[25]=g):g=e[25];let h;e[26]!==r?(h=t.jsxRuntimeExports.jsx(xe,{position:r}),e[26]=r,e[27]=h):h=e[27];let v;e[28]!==L||e[29]!==R||e[30]!==d||e[31]!==g||e[32]!==h?(v=t.jsxRuntimeExports.jsxs("div",{ref:j,style:R,onClick:L,children:[d,g,h]}),e[28]=L,e[29]=R,e[30]=d,e[31]=g,e[32]=h,e[33]=v):v=e[33];let M;e[34]!==c||e[35]!==G||e[36]!==v?(M=t.jsxRuntimeExports.jsx("div",{ref:J,className:"map maplibre-show-control relative w-full h-full",style:I,children:t.jsxRuntimeExports.jsx(Q.DndContext,{sensors:G,modifiers:_,onDragStart:c,onDragMove:F,onDragEnd:Z,children:v})}),e[34]=c,e[35]=G,e[36]=v,e[37]=M):M=e[37];let D;e[38]!==M||e[39]!==y?(D=t.jsxRuntimeExports.jsx("div",{style:y,children:M}),e[38]=M,e[39]=y,e[40]=D):D=e[40];let X;e[41]!==i||e[42]!==N?(X=i?t.jsxRuntimeExports.jsx("div",{className:"absolute left-[22px] bottom-13",children:N?t.jsxRuntimeExports.jsxs(t.jsxRuntimeExports.Fragment,{children:[t.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:()=>{W(!1)},children:t.jsxRuntimeExports.jsx(ne.X,{})}),t.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 i=="string"?{__html:me.string2HTML(i)}:void 0,children:a.isValidElement(i)?i:null})]}):t.jsxRuntimeExports.jsx("button",{type:"button",className:"p-1 border-0 rounded-[2px] text-primary-gray-700 bg-primary-gray-300 dark:bg-primary-gray-500 map-legend-button",onClick:()=>{W(!0)},children:t.jsxRuntimeExports.jsx(ne.ExpandIcon,{})})}):null,e[41]=i,e[42]=N,e[43]=X):X=e[43];let U;return e[44]!==D||e[45]!==X?(U=t.jsxRuntimeExports.jsxs("div",{className:"flex flex-col grow justify-center leading-0",ref:V,"aria-label":"Map area",children:[D,X]}),e[44]=D,e[45]=X,e[46]=U):U=e[46],U}function xe(m){const e=t.compilerRuntimeExports.c(10),{position:n}=m;let o;e[0]===Symbol.for("react.memo_cache_sentinel")?(o={id:"slider-handle"},e[0]=o):o=e[0];const{attributes:s,listeners:f,setNodeRef:u}=Q.useDraggable(o),i=`${n}%`;let r;e[1]!==i?(r={position:"absolute",left:i,top:0,bottom:0,width:"40px",transform:"translateX(-50%)",cursor:"col-resize",display:"flex",justifyContent:"center",alignItems:"center",zIndex:10,touchAction:"none"},e[1]=i,e[2]=r):r=e[2];let p;e[3]===Symbol.for("react.memo_cache_sentinel")?(p=t.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=t.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:t.jsxRuntimeExports.jsx(ne.ChevronLeftRight,{})}),e[4]=x):x=e[4];let b;return e[5]!==s||e[6]!==f||e[7]!==u||e[8]!==r?(b=t.jsxRuntimeExports.jsxs("div",{ref:u,style:r,...f,...s,children:[p,x]}),e[5]=s,e[6]=f,e[7]=u,e[8]=r,e[9]=b):b=e[9],b}function be(m){const e=t.compilerRuntimeExports.c(45),{graphTitle:n,height:o,width:s,relativeHeight:f,sources:u,graphDescription:i,footNote:r,padding:p,backgroundColor:x,graphID:b,mapStyles:j,center:N,zoomLevel:W,language:B,minHeight:$,theme:q,ariaLabel:G,styles:l,classNames:c,mapLegend:z}=m,F=x===void 0?!1:x;let S;e[0]!==N?(S=N===void 0?[0,0]:N,e[0]=N,e[1]=S):S=e[1];const Z=S,P=W===void 0?3:W,L=B===void 0?"en":B,V=$===void 0?0:$,H=q===void 0?"light":q,[E,J]=a.useState(0),[C,A]=a.useState(0),y=a.useRef(null),I=a.useRef(null);let _,k;e[2]===Symbol.for("react.memo_cache_sentinel")?(_=()=>{const M=new ResizeObserver(D=>{J(D[0].target.clientWidth||620),A(D[0].target.clientHeight||480)});return y.current&&M.observe(y.current),()=>M.disconnect()},k=[],e[2]=_,e[3]=k):(_=e[2],k=e[3]),a.useEffect(_,k);const R=c?.graphContainer,O=l?.graphContainer;let d;e[4]!==c?.description||e[5]!==c?.title||e[6]!==i||e[7]!==n||e[8]!==l?.description||e[9]!==l?.title||e[10]!==s?(d=n||i?t.jsxRuntimeExports.jsx(fe.GraphHeader,{styles:{title:l?.title,description:l?.description},classNames:{title:c?.title,description:c?.description},graphTitle:n,graphDescription:i,width:s}):null,e[4]=c?.description,e[5]=c?.title,e[6]=i,e[7]=n,e[8]=l?.description,e[9]=l?.title,e[10]=s,e[11]=d):d=e[11];let w;e[12]!==Z||e[13]!==z||e[14]!==j||e[15]!==C||e[16]!==E||e[17]!==P?(w=E&&C?t.jsxRuntimeExports.jsx(he,{width:E,height:C,mapStyles:j,center:Z,zoomLevel:P,mapLegend:z}):null,e[12]=Z,e[13]=z,e[14]=j,e[15]=C,e[16]=E,e[17]=P,e[18]=w):w=e[18];let g;e[19]!==w?(g=t.jsxRuntimeExports.jsx(ie.GraphArea,{ref:y,children:w}),e[19]=w,e[20]=g):g=e[20];let h;e[21]!==c?.footnote||e[22]!==c?.source||e[23]!==r||e[24]!==u||e[25]!==l?.footnote||e[26]!==l?.source||e[27]!==s?(h=u||r?t.jsxRuntimeExports.jsx(pe.GraphFooter,{styles:{footnote:l?.footnote,source:l?.source},classNames:{footnote:c?.footnote,source:c?.source},sources:u,footNote:r,width:s}):null,e[21]=c?.footnote,e[22]=c?.source,e[23]=r,e[24]=u,e[25]=l?.footnote,e[26]=l?.source,e[27]=s,e[28]=h):h=e[28];let v;return e[29]!==G||e[30]!==F||e[31]!==b||e[32]!==o||e[33]!==L||e[34]!==V||e[35]!==p||e[36]!==f||e[37]!==O||e[38]!==d||e[39]!==g||e[40]!==h||e[41]!==R||e[42]!==H||e[43]!==s?(v=t.jsxRuntimeExports.jsxs(ie.GraphContainer,{className:R,style:O,id:b,ref:I,"aria-label":G,backgroundColor:F,theme:H,language:L,minHeight:V,width:s,height:o,relativeHeight:f,padding:p,children:[d,g,h]}),e[29]=G,e[30]=F,e[31]=b,e[32]=o,e[33]=L,e[34]=V,e[35]=p,e[36]=f,e[37]=O,e[38]=d,e[39]=g,e[40]=h,e[41]=R,e[42]=H,e[43]=s,e[44]=v):v=e[44],v}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 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={svgWidth}\r\n height={svgHeight}\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,EAA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EAAA,EAAA,EAAAyI,GAAAqB,OAAA9J,MAAAG,EAAAH,MAAA2F,GAAAA,EAAA3F,EAAA,EAAA,EAAA,IAAA4F,EAAA,OAAA5F,EAAA,EAAA,IAAAwI,GAAAxI,EAAA,EAAA,IAAAmI,GAAAnI,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,GArDVyF,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,EAYCG,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,EAtDjB4F,CAsDiB"}
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, ExpandIcon, 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='p-1 border-0 rounded-[2px] text-primary-gray-700 bg-primary-gray-300 dark:bg-primary-gray-500 map-legend-button'\r\n onClick={() => {\r\n setShowLegend(true);\r\n }}\r\n >\r\n <ExpandIcon />\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={svgWidth}\r\n height={svgHeight}\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","ExpandIcon","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,CAAAC,OAAAA,EAAAC,MAAAA,EAAAC,UAAAA,EAAAhB,OAAAA,EAAAiB,UAAAA,EAAAC,UAAAA,CAAAA,EAAmEP,EACnE,CAAAQ,EAAAC,CAAA,EAAgCC,EAAAA,SAAS,EAAE,EAC3C,CAAAC,EAAAC,CAAA,EAAoCF,EAAAA,SAAS,EAAK,EAClDG,EAAqBC,EAAAA,OAAuB,IAAI,EAChD,CAAAC,EAAAC,CAAA,EAAoCN,EAAAA,SAAS,EAAI,EACjDO,EAA6BH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