@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
@@ -0,0 +1,2 @@
1
+ "use strict";const d=require("./index-CHPV5EwG-D4pAp7u0.cjs"),q=require("react"),Fe=require("./index-Cno4Q0YE.cjs"),We=require("./Spinner-WHzzloYQ.cjs"),Pe=require("./Typography-BqmyF1gP.cjs"),Ie=require("./Tooltip-Hr46paWP.cjs"),Ye=require("./numberFormattingFunction-Cn9R7CM9.cjs"),Ge=require("./getTextColorBasedOnBgColor-nqY-bsM_.cjs"),Ve=require("./Colors.cjs"),Be=require("./checkIfNullOrUndefined-BCW3Y1ML.cjs"),Xe=require("./DetailsModal-jmmKRMRM.cjs"),Ue=require("./pow-BnyPO-NX.cjs"),ze=require("./y-QcCbqrzx.cjs"),Je=require("./GraphFooter.cjs"),Ke=require("./GraphHeader.cjs"),Qe=require("./ColorLegendWithMouseOver.cjs"),Ze=require("./EmptyState-CFmiFPHz.cjs"),He=require("./uniqBy-O05lp2S5.cjs"),Te=require("./GraphContainer-Cul9b74X.cjs");function Ne(r,e){let n,s;if(e===void 0)for(const l of r)l!=null&&(n===void 0?l>=l&&(n=s=l):(n>l&&(n=l),s<l&&(s=l)));else{let l=-1;for(let g of r)(g=e(g,++l,r))!=null&&(n===void 0?g>=g&&(n=s=g):(n>g&&(n=g),s<g&&(s=g)))}return[n,s]}function H(r){return function(){return r}}function _e(r,e,n,s){var l=H(.1),g=!0,E=H(Math.min((n-r)/2,(s-e)/2)),a,z,P,f,R,u,w,m,N,$;typeof r!="function"&&(r=H(r==null?-100:+r)),typeof n!="function"&&(n=H(n==null?100:+n)),typeof e!="function"&&(e=H(e==null?-100:+e)),typeof s!="function"&&(s=H(s==null?100:+s));function T(t,o,F,i,V){return(t-o)*Math.min(2,Math.abs(t-o)/t)*F*V}function x(t){for(var o=0,F=a.length,i;o<F;++o)i=a[o],i.x<f[o]+m[o]||i.x>R[o]-m[o]||i.y<u[o]+m[o]||i.y>w[o]-m[o]?(i.vx+=T(N[o],i.x,z[o],m[o],t),i.vy+=T($[o],i.y,P[o],m[o],t)):i.y<u[o]+m[o]||i.y>w[o]-m[o],g&&(i.x>=R[o]&&(i.vx+=R[o]-i.x),i.x<=f[o]&&(i.vx+=f[o]-i.x),i.y>=w[o]&&(i.vy+=w[o]-i.y),i.y<=u[o]&&(i.vy+=u[o]-i.y))}function S(){if(a){var t,o=a.length;for(z=new Array(o),P=new Array(o),f=new Array(o),u=new Array(o),R=new Array(o),w=new Array(o),$=new Array(o),N=new Array(o),m=new Array(o),t=0;t<o;++t)z[t]=isNaN(f[t]=+r(a[t],t,a))||isNaN(R[t]=+n(a[t],t,a))?0:+l(a[t],t,a),P[t]=isNaN(u[t]=+e(a[t],t,a))||isNaN(w[t]=+s(a[t],t,a))?0:+l(a[t],t,a),N[t]=f[t]+(R[t]-f[t])/2,$[t]=u[t]+(w[t]-u[t])/2,m[t]=+E(a[t],t,a)}}return x.initialize=function(t){a=t,S()},x.x0=function(t){return arguments.length?(r=typeof t=="function"?t:H(+t),S(),x):r},x.x1=function(t){return arguments.length?(n=typeof t=="function"?t:H(+t),S(),x):n},x.y0=function(t){return arguments.length?(e=typeof t=="function"?t:H(+t),S(),x):e},x.y1=function(t){return arguments.length?(s=typeof t=="function"?t:H(+t),S(),x):s},x.strength=function(t){return arguments.length?(l=typeof t=="function"?t:H(+t),S(),x):l},x.border=function(t){return arguments.length?(E=typeof t=="function"?t:H(+t),S(),x):E},x.hardBoundary=function(t){return arguments.length?(g=t,x):g},x}const et=r=>{const e=d.compilerRuntimeExports.c(107),{data:n,colors:s,leftMargin:l,width:g,height:E,colorDomain:a,selectedColor:z,rightMargin:P,topMargin:f,bottomMargin:R,showLabels:u,tooltip:w,onSeriesMouseOver:m,showValues:N,suffix:$,prefix:T,highlightedDataPoints:x,onSeriesMouseClick:S,maxRadiusValue:t,radius:o,resetSelectionOnDoubleClick:F,detailsOnClick:i,styles:V,classNames:D,dimmedOpacity:J,precision:K,locale:Q}=r,qe=q.useRef(null),[ye,Oe]=q.useState(void 0),[B,Ee]=q.useState(void 0),[G,ke]=q.useState(void 0),[Z,be]=q.useState(void 0),[je,Me]=q.useState(void 0),[j,v]=q.useState(null);let Ce;e[0]!==R||e[1]!==l||e[2]!==P||e[3]!==f?(Ce={top:f,bottom:R,left:l,right:P},e[0]=R,e[1]=l,e[2]=P,e[3]=f,e[4]=Ce):Ce=e[4];const _=Ce,I=g-_.left-_.right,Y=E-_.top-_.bottom;let ae;e[5]!==n?(ae=n.filter(tt).length===0?n:Fe.orderBy(n.filter(ot),"radius","asc"),e[5]=n,e[6]=ae):ae=e[6];const X=ae;let ce;e[7]!==n||e[8]!==t||e[9]!==o?(ce=n.filter(nt).length!==n.length?Ue.sqrt().domain([0,Be.checkIfNullOrUndefined(t)?Math.max(...n.map(rt).filter(it)):t]).range([.25,o]).nice():void 0,e[7]=n,e[8]=t,e[9]=o,e[10]=ce):ce=e[10];const p=ce;let ue;e[11]!==X||e[12]!==Y||e[13]!==I||e[14]!==o||e[15]!==p?(ue=()=>{(()=>{const h=X.map(st);ze.forceSimulation(h).force("y",ze.forceY(y=>Y/2).strength(1)).force("x",ze.forceX(y=>I/2).strength(1)).force("collide",ze.forceCollide(y=>p?p(y.size||0)+1:o+1)).force("charge",ze.forceManyBody().strength(-15)).force("boundary",_e(0,0,I,Y).strength(.2).border(50)).alphaDecay(.05).tick(1e4).on("tick",()=>{v(h)}).on("end",()=>{v(h);const y=Ne(h,b=>b.x-(p?p(b.size||0)+1:o+1))[0]||0,O=Ne(h,b=>b.y-(p?p(b.size||0)+1:o+1))[0]||0,A=Ne(h,b=>b.x+(p?p(b.size||0)+1:o+1))[1]||0,W=Ne(h,b=>b.y+(p?p(b.size||0)+1:o+1))[1]||0;ke([y,O,y<0?A-y:A,O<0?W-O:W])})})()},e[11]=X,e[12]=Y,e[13]=I,e[14]=o,e[15]=p,e[16]=ue):ue=e[16];let fe;e[17]!==n||e[18]!==X||e[19]!==Y||e[20]!==I||e[21]!==t||e[22]!==o||e[23]!==p?(fe=[n,o,Y,I,t,X,p],e[17]=n,e[18]=X,e[19]=Y,e[20]=I,e[21]=t,e[22]=o,e[23]=p,e[24]=fe):fe=e[24],q.useEffect(ue,fe);let he;e[25]!==m?(he=(c,h)=>{Oe(h),Me(c.clientY),be(c.clientX),m?.(h)},e[25]=m,e[26]=he):he=e[26];const ee=he;let de;e[27]===Symbol.for("react.memo_cache_sentinel")?(de=(c,h)=>{Oe(h),Me(c.clientY),be(c.clientX)},e[27]=de):de=e[27];const Re=de;let te;e[28]!==i||e[29]!==B||e[30]!==S||e[31]!==F?(te=c=>{(S||i)&&(B===c.label&&F?(Ee(void 0),S?.(void 0)):(Ee(c.label),S?.(c)))},e[28]=i,e[29]=B,e[30]=S,e[31]=F,e[32]=te):te=e[32];const oe=te;let ge;e[33]!==m?(ge=()=>{Oe(void 0),be(void 0),Me(void 0),m?.(void 0)},e[33]=m,e[34]=ge):ge=e[34];const k=ge;let pe;e[35]!==a||e[36]!==s||e[37]!==n?(pe=c=>n.filter(lt).length===0?s[0]:c.color?s[a.indexOf(c.color)]:Ve.Colors.gray,e[35]=a,e[36]=s,e[37]=n,e[38]=pe):pe=e[38];const ne=pe;let me;e[39]!==a||e[40]!==s||e[41]!==J||e[42]!==x||e[43]!==z?(me=c=>z?c.color&&s[a.indexOf(c.color)]===z?1:J:x?x.indexOf(c.label)!==-1?.85:J:.85,e[39]=a,e[40]=s,e[41]=J,e[42]=x,e[43]=z,e[44]=me):me=e[44];const re=me;if(!j){const c=`${g}px`,h=`${E}px`;let L;e[45]!==c||e[46]!==h?(L={width:c,height:h},e[45]=c,e[46]=h,e[47]=L):L=e[47];let y;e[48]===Symbol.for("react.memo_cache_sentinel")?(y=d.jsxRuntimeExports.jsx("div",{className:"flex m-auto items-center justify-center p-0 leading-none text-base h-40",children:d.jsxRuntimeExports.jsx(We.w,{})}),e[48]=y):y=e[48];let O;return e[49]!==L?(O=d.jsxRuntimeExports.jsx("div",{style:L,children:y}),e[49]=L,e[50]=O):O=e[50],O}if(G){const c=`${g}px`,h=`${E}px`,L=`${G[0]>0?0:G[0]} ${G[1]>0?0:G[1]} ${g<G[2]?G[2]:g} ${E<G[3]?G[3]:E}`,y=`translate(${_.left},${_.top})`;let O;if(e[51]!==D?.graphObjectValues||e[52]!==j||e[53]!==ne||e[54]!==re||e[55]!==oe||e[56]!==ee||e[57]!==k||e[58]!==Q||e[59]!==K||e[60]!==T||e[61]!==o||e[62]!==p||e[63]!==u||e[64]!==N||e[65]!==V?.graphObjectValues||e[66]!==$){let le;e[68]!==D?.graphObjectValues||e[69]!==ne||e[70]!==re||e[71]!==oe||e[72]!==ee||e[73]!==k||e[74]!==Q||e[75]!==K||e[76]!==T||e[77]!==o||e[78]!==p||e[79]!==u||e[80]!==N||e[81]!==V?.graphObjectValues||e[82]!==$?(le=C=>{const we=ne(C),xe=re(C),M=p?p(C.size||0):o,ve=M>20&&(u||N);return d.jsxRuntimeExports.jsxs("g",{className:"undp-viz-g-with-hover",opacity:xe,transform:`translate(${C.x},${C.y})`,onMouseEnter:U=>ee(U,C),onMouseMove:U=>Re(U,C),onClick:()=>oe(C),onMouseLeave:k,children:[d.jsxRuntimeExports.jsx("circle",{cx:0,cy:0,r:M,fill:we}),(ve||N)&&C.size!==void 0&&C.size!==null&&M>=15&&d.jsxRuntimeExports.jsx("g",{children:d.jsxRuntimeExports.jsx("foreignObject",{y:0-M,x:0-M,width:2*M,height:2*M,children:d.jsxRuntimeExports.jsxs("div",{className:"flex flex-col justify-center items-center h-full py-0 px-3",style:{display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"center",height:"100%",padding:"0 0.75rem"},children:[u&&d.jsxRuntimeExports.jsx(Pe._,{className:d.mo("text-center leading-[1.25] overflow-hidden m-0 circle-packing-label",D?.graphObjectValues),marginBottom:"none",style:{fontSize:`${Math.min(Math.max(Math.round(M/4),12),Math.max(Math.round(M*12/`${C.label}`.length),12),14)}px`,WebkitLineClamp:M*2<60?1:M*2<75?2:M*2<100?3:void 0,display:"-webkit-box",WebkitBoxOrient:"vertical",color:Ge.getTextColorBasedOnBgColor(we),hyphens:"auto",...V?.graphObjectValues||{}},children:C.label}),N&&d.jsxRuntimeExports.jsx(Pe._,{className:"text-center font-bold leading-[1.25] w-full m-0 circle-packing-value",marginBottom:"none",style:{fontSize:`${Math.min(Math.max(Math.round(M/4),14),14)}px`,color:Ge.getTextColorBasedOnBgColor(we)},children:Ye.numberFormattingFunction(C.size,void 0,K,T,$,Q)})]})})})]},C.label)},e[68]=D?.graphObjectValues,e[69]=ne,e[70]=re,e[71]=oe,e[72]=ee,e[73]=k,e[74]=Q,e[75]=K,e[76]=T,e[77]=o,e[78]=p,e[79]=u,e[80]=N,e[81]=V?.graphObjectValues,e[82]=$,e[83]=le):le=e[83],O=j.map(le),e[51]=D?.graphObjectValues,e[52]=j,e[53]=ne,e[54]=re,e[55]=oe,e[56]=ee,e[57]=k,e[58]=Q,e[59]=K,e[60]=T,e[61]=o,e[62]=p,e[63]=u,e[64]=N,e[65]=V?.graphObjectValues,e[66]=$,e[67]=O}else O=e[67];let A;e[84]!==y||e[85]!==O?(A=d.jsxRuntimeExports.jsx("g",{transform:y,children:O}),e[84]=y,e[85]=O,e[86]=A):A=e[86];let W;e[87]!==c||e[88]!==h||e[89]!==L||e[90]!==A?(W=d.jsxRuntimeExports.jsx("svg",{width:c,height:h,viewBox:L,direction:"ltr",ref:qe,children:A}),e[87]=c,e[88]=h,e[89]=L,e[90]=A,e[91]=W):W=e[91];let b;e[92]!==D?.tooltip||e[93]!==Z||e[94]!==je||e[95]!==ye||e[96]!==V?.tooltip||e[97]!==w?(b=ye&&w&&Z&&je&&d.jsxRuntimeExports.jsx(Ie.Tooltip,{data:ye,body:w,xPos:Z,yPos:je,backgroundStyle:V?.tooltip,className:D?.tooltip}),e[92]=D?.tooltip,e[93]=Z,e[94]=je,e[95]=ye,e[96]=V?.tooltip,e[97]=w,e[98]=b):b=e[98];let ie;e[99]!==D?.modal||e[100]!==i||e[101]!==B?(ie=i&&B!==void 0?d.jsxRuntimeExports.jsx(Xe.DetailsModal,{body:i,data:B,setData:Ee,className:D?.modal}):null,e[99]=D?.modal,e[100]=i,e[101]=B,e[102]=ie):ie=e[102];let se;return e[103]!==W||e[104]!==b||e[105]!==ie?(se=d.jsxRuntimeExports.jsxs(d.jsxRuntimeExports.Fragment,{children:[W,b,ie]}),e[103]=W,e[104]=b,e[105]=ie,e[106]=se):se=e[106],se}return null};function tt(r){return!Be.checkIfNullOrUndefined(r.size)}function ot(r){return!Be.checkIfNullOrUndefined(r.size)}function nt(r){return r.size===void 0||r.size===null}function rt(r){return r.size}function it(r){return r!=null}function st(r){return{...r,...r.data&&{data:{...r.data}}}}function lt(r){return r.color}function at(r,e,n,s){const l=r.filter(f=>f!=null),g=s===!1?Math.sqrt(e*n/Math.PI):Math.min(e,n)/2,E=l.reduce((f,R)=>f+R,0),a=Math.max(...l),z=f=>f<=5?.9:f<=10?.85:f<=20?.8:.7,P=f=>f<=200?.85:f<=250?.95:1;return g*Math.sqrt(a/E)*(s?P(g):1)*(s?z(l.length):1)}function ct(r){const e=d.compilerRuntimeExports.c(83),{data:n,graphTitle:s,colors:l,suffix:g,sources:E,prefix:a,graphDescription:z,leftMargin:P,rightMargin:f,height:R,width:u,footNote:w,colorDomain:m,colorLegendTitle:N,padding:$,backgroundColor:T,topMargin:x,bottomMargin:S,showLabels:t,relativeHeight:o,tooltip:F,onSeriesMouseOver:i,showColorScale:V,showValues:D,graphID:J,highlightedDataPoints:K,onSeriesMouseClick:Q,graphDownload:qe,dataDownload:ye,language:Oe,showNAColor:B,minHeight:Ee,theme:G,ariaLabel:ke,radius:Z,maxRadiusValue:be,resetSelectionOnDoubleClick:je,detailsOnClick:Me,styles:j,classNames:v,dimmedOpacity:Ce,precision:_,circularBoundary:I,locale:Y}=r,ae=g===void 0?"":g,X=a===void 0?"":a,ce=P===void 0?0:P,p=f===void 0?0:f,ue=T===void 0?!1:T,fe=x===void 0?0:x,he=S===void 0?0:S,ee=t===void 0?!0:t,de=V===void 0?!0:V,Re=qe===void 0?!1:qe,te=ye===void 0?!1:ye,oe=Oe===void 0?"en":Oe,ge=Ee===void 0?0:Ee,k=G===void 0?"light":G,pe=je===void 0?!0:je,ne=Ce===void 0?.3:Ce,me=_===void 0?2:_,re=I===void 0?!0:I,c=Y===void 0?"en":Y,[h,L]=q.useState(0),[y,O]=q.useState(0),[A,W]=q.useState(void 0),b=q.useRef(null),ie=q.useRef(null);let se,le;e[0]===Symbol.for("react.memo_cache_sentinel")?(se=()=>{const Le=new ResizeObserver(Ae=>{L(Ae[0].target.clientWidth||620),O(Ae[0].target.clientHeight||480)});return b.current&&Le.observe(b.current),()=>Le.disconnect()},le=[],e[0]=se,e[1]=le):(se=e[0],le=e[1]),q.useEffect(se,le);const C=v?.graphContainer,we=j?.graphContainer;let xe;e[2]!==v?.description||e[3]!==v?.title||e[4]!==n||e[5]!==te||e[6]!==z||e[7]!==Re||e[8]!==s||e[9]!==j?.description||e[10]!==j?.title||e[11]!==u?(xe=s||z||Re||te?d.jsxRuntimeExports.jsx(Ke.GraphHeader,{styles:{title:j?.title,description:j?.description},classNames:{title:v?.title,description:v?.description},graphTitle:s,graphDescription:z,width:u,graphDownload:Re?ie:void 0,dataDownload:te?n.map(yt).filter(vt).length>0?n.map(xt).filter(mt):n.filter(pt):null}):null,e[2]=v?.description,e[3]=v?.title,e[4]=n,e[5]=te,e[6]=z,e[7]=Re,e[8]=s,e[9]=j?.description,e[10]=j?.title,e[11]=u,e[12]=xe):xe=e[12];let M;e[13]!==v?.colorLegend||e[14]!==m||e[15]!==N||e[16]!==l||e[17]!==n||e[18]!==de||e[19]!==B||e[20]!==k||e[21]!==u?(M=de&&n.filter(gt).length!==0&&n.length>0?d.jsxRuntimeExports.jsx(Qe.ColorLegendWithMouseOver,{width:u,colorLegendTitle:N,colors:l||Ve.Colors[k].categoricalColors.colors,colorDomain:m||He.uniqBy(n,"color",!0),setSelectedColor:W,showNAColor:B??!0,isCenter:!0,className:v?.colorLegend}):null,e[13]=v?.colorLegend,e[14]=m,e[15]=N,e[16]=l,e[17]=n,e[18]=de,e[19]=B,e[20]=k,e[21]=u,e[22]=M):M=e[22];let ve;e[23]!==n.length?(ve=n.length===0&&d.jsxRuntimeExports.jsx(Ze.EmptyState,{}),e[23]=n.length,e[24]=ve):ve=e[24];let U;e[25]!==he||e[26]!==re||e[27]!==v||e[28]!==m||e[29]!==l||e[30]!==n||e[31]!==Me||e[32]!==ne||e[33]!==K||e[34]!==ce||e[35]!==c||e[36]!==be||e[37]!==Q||e[38]!==i||e[39]!==me||e[40]!==X||e[41]!==Z||e[42]!==pe||e[43]!==p||e[44]!==A||e[45]!==ee||e[46]!==D||e[47]!==j||e[48]!==ae||e[49]!==y||e[50]!==h||e[51]!==k||e[52]!==F||e[53]!==fe?(U=h&&y&&n.length>0?d.jsxRuntimeExports.jsx(et,{data:n,colors:n.filter(dt).length===0?l?[l]:[Ve.Colors.primaryColors["blue-600"]]:l||Ve.Colors[k].categoricalColors.colors,colorDomain:n.filter(ht).length===0?[]:m||He.uniqBy(n,"color",!0),width:h,height:y,leftMargin:ce,rightMargin:p,topMargin:fe,bottomMargin:he,showLabels:ee,showValues:D!==!1?n.filter(ft).length!==0:D,selectedColor:A,suffix:ae,prefix:X,tooltip:F,onSeriesMouseOver:i,highlightedDataPoints:K,onSeriesMouseClick:Q,theme:k,radius:Z||at(n.map(ut),h,y,re),maxRadiusValue:be,resetSelectionOnDoubleClick:pe,detailsOnClick:Me,styles:j,classNames:v,dimmedOpacity:ne,precision:me,locale:c}):null,e[25]=he,e[26]=re,e[27]=v,e[28]=m,e[29]=l,e[30]=n,e[31]=Me,e[32]=ne,e[33]=K,e[34]=ce,e[35]=c,e[36]=be,e[37]=Q,e[38]=i,e[39]=me,e[40]=X,e[41]=Z,e[42]=pe,e[43]=p,e[44]=A,e[45]=ee,e[46]=D,e[47]=j,e[48]=ae,e[49]=y,e[50]=h,e[51]=k,e[52]=F,e[53]=fe,e[54]=U):U=e[54];let Se;e[55]!==ve||e[56]!==U?(Se=d.jsxRuntimeExports.jsxs(Te.GraphArea,{ref:b,children:[ve,U]}),e[55]=ve,e[56]=U,e[57]=Se):Se=e[57];let De;e[58]!==v?.footnote||e[59]!==v?.source||e[60]!==w||e[61]!==E||e[62]!==j?.footnote||e[63]!==j?.source||e[64]!==u?(De=E||w?d.jsxRuntimeExports.jsx(Je.GraphFooter,{styles:{footnote:j?.footnote,source:j?.source},classNames:{footnote:v?.footnote,source:v?.source},sources:E,footNote:w,width:u}):null,e[58]=v?.footnote,e[59]=v?.source,e[60]=w,e[61]=E,e[62]=j?.footnote,e[63]=j?.source,e[64]=u,e[65]=De):De=e[65];let $e;return e[66]!==ke||e[67]!==ue||e[68]!==J||e[69]!==R||e[70]!==oe||e[71]!==ge||e[72]!==$||e[73]!==o||e[74]!==C||e[75]!==we||e[76]!==xe||e[77]!==M||e[78]!==Se||e[79]!==De||e[80]!==k||e[81]!==u?($e=d.jsxRuntimeExports.jsxs(Te.GraphContainer,{className:C,style:we,id:J,ref:ie,"aria-label":ke,backgroundColor:ue,theme:k,language:oe,minHeight:ge,width:u,height:R,relativeHeight:o,padding:$,children:[xe,M,Se,De]}),e[66]=ke,e[67]=ue,e[68]=J,e[69]=R,e[70]=oe,e[71]=ge,e[72]=$,e[73]=o,e[74]=C,e[75]=we,e[76]=xe,e[77]=M,e[78]=Se,e[79]=De,e[80]=k,e[81]=u,e[82]=$e):$e=e[82],$e}function ut(r){return r.size}function ft(r){return r.size}function ht(r){return r.color}function dt(r){return r.color}function gt(r){return r.color}function pt(r){return r!==void 0}function mt(r){return r!==void 0}function xt(r){return r.data}function vt(r){return r!==void 0}function yt(r){return r.data}exports.CirclePackingGraph=ct;exports.extent=Ne;
2
+ //# sourceMappingURL=index-CP8cmNzt.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index-CP8cmNzt.cjs","sources":["../node_modules/d3-array/src/extent.js","../node_modules/d3-force-boundary/dist/d3-force-boundary.esm.js","../src/Components/Graphs/CirclePackingGraph/Graph.tsx","../src/Components/Graphs/CirclePackingGraph/getMaxCircleRadius.ts","../src/Components/Graphs/CirclePackingGraph/index.tsx"],"sourcesContent":["export default function extent(values, valueof) {\n let min;\n let max;\n if (valueof === undefined) {\n for (const value of values) {\n if (value != null) {\n if (min === undefined) {\n if (value >= value) min = max = value;\n } else {\n if (min > value) min = value;\n if (max < value) max = value;\n }\n }\n }\n } else {\n let index = -1;\n for (let value of values) {\n if ((value = valueof(value, ++index, values)) != null) {\n if (min === undefined) {\n if (value >= value) min = max = value;\n } else {\n if (min > value) min = value;\n if (max < value) max = value;\n }\n }\n }\n }\n return [min, max];\n}\n","// https://observablehq.com/@john-guerra/d3-force-boundary v0.0.2 Copyright 2022 John Alexis Guerra Gómez\nfunction constant(x) {\n return function() {\n return x;\n };\n}\n\nfunction forceBoundary(x0, y0, x1, y1) {\n var strength = constant(0.1),\n hardBoundary = true,\n border = constant( Math.min((x1 - x0)/2, (y1 - y0)/2) ),\n nodes,\n strengthsX,\n strengthsY,\n x0z, x1z,\n y0z, y1z,\n borderz,\n halfX, halfY;\n\n if (typeof x0 !== \"function\") x0 = constant(x0 == null ? -100 : +x0);\n if (typeof x1 !== \"function\") x1 = constant(x1 == null ? 100 : +x1);\n if (typeof y0 !== \"function\") y0 = constant(y0 == null ? -100 : +y0);\n if (typeof y1 !== \"function\") y1 = constant(y1 == null ? 100 : +y1);\n\n function getVx(halfX, x, strengthX, border, alpha) {\n return (halfX - x) * Math.min(2, Math.abs( halfX - x) / halfX) * strengthX * alpha;\n }\n\n function force(alpha) {\n for (var i = 0, n = nodes.length, node; i < n; ++i) {\n node = nodes[i];\n // debugger;\n if ((node.x < (x0z[i] + borderz[i]) || node.x > (x1z[i] - borderz[i])) ||\n (node.y < (y0z[i] + borderz[i]) || node.y > (y1z[i] - borderz[i]))) {\n node.vx += getVx(halfX[i], node.x, strengthsX[i], borderz[i], alpha);\n node.vy += getVx(halfY[i], node.y, strengthsY[i], borderz[i], alpha);\n } else if (node.y < (y0z[i] + borderz[i]) || node.y > (y1z[i] - borderz[i])) ;\n\n if (hardBoundary) {\n if (node.x >= x1z[i]) node.vx += x1z[i] - node.x;\n if (node.x <= x0z[i]) node.vx += x0z[i] - node.x;\n if (node.y >= y1z[i]) node.vy += y1z[i] - node.y;\n if (node.y <= y0z[i]) node.vy += y0z[i] - node.y;\n }\n }\n }\n\n function initialize() {\n if (!nodes) return;\n var i, n = nodes.length;\n strengthsX = new Array(n);\n strengthsY = new Array(n);\n x0z = new Array(n);\n y0z = new Array(n);\n x1z = new Array(n);\n y1z = new Array(n);\n halfY = new Array(n);\n halfX = new Array(n);\n borderz = new Array(n);\n\n for (i = 0; i < n; ++i) {\n strengthsX[i] = (isNaN(x0z[i] = +x0(nodes[i], i, nodes)) ||\n isNaN(x1z[i] = +x1(nodes[i], i, nodes))) ? 0 : +strength(nodes[i], i, nodes);\n strengthsY[i] = (isNaN(y0z[i] = +y0(nodes[i], i, nodes)) ||\n isNaN(y1z[i] = +y1(nodes[i], i, nodes))) ? 0 : +strength(nodes[i], i, nodes);\n halfX[i] = x0z[i] + (x1z[i] - x0z[i])/2,\n halfY[i] = y0z[i] + (y1z[i] - y0z[i])/2;\n borderz[i] = +border(nodes[i], i, nodes);\n }\n }\n\n force.initialize = function(_) {\n nodes = _;\n initialize();\n };\n\n force.x0 = function(_) {\n return arguments.length ? (x0 = typeof _ === \"function\" ? _ : constant(+_), initialize(), force) : x0;\n };\n\n force.x1 = function(_) {\n return arguments.length ? (x1 = typeof _ === \"function\" ? _ : constant(+_), initialize(), force) : x1;\n };\n\n force.y0 = function(_) {\n return arguments.length ? (y0 = typeof _ === \"function\" ? _ : constant(+_), initialize(), force) : y0;\n };\n\n force.y1 = function(_) {\n return arguments.length ? (y1 = typeof _ === \"function\" ? _ : constant(+_), initialize(), force) : y1;\n };\n\n force.strength = function(_) {\n return arguments.length ? (strength = typeof _ === \"function\" ? _ : constant(+_), initialize(), force) : strength;\n };\n\n force.border = function(_) {\n return arguments.length ? (border = typeof _ === \"function\" ? _ : constant(+_), initialize(), force) : border;\n };\n\n force.hardBoundary = function(_) {\n return arguments.length ? (hardBoundary = _, force) : hardBoundary;\n };\n\n return force;\n}\n\nexport default forceBoundary;\n","import { useEffect, useState, useRef } from 'react';\r\nimport { forceCollide, forceManyBody, forceSimulation, forceX, forceY } from 'd3-force';\r\nimport orderBy from 'lodash.orderby';\r\nimport { scaleSqrt } from 'd3-scale';\r\nimport { extent } from 'd3-array';\r\nimport forceBoundary from 'd3-force-boundary';\r\nimport { cn } from '@undp/design-system-react/cn';\r\nimport { Spinner } from '@undp/design-system-react/Spinner';\r\nimport { P } from '@undp/design-system-react/Typography';\r\n\r\nimport { ClassNameObject, StyleObject, TreeMapDataType } from '@/Types';\r\nimport { Tooltip } from '@/Components/Elements/Tooltip';\r\nimport { numberFormattingFunction } from '@/Utils/numberFormattingFunction';\r\nimport { getTextColorBasedOnBgColor } from '@/Utils/getTextColorBasedOnBgColor';\r\nimport { Colors } from '@/Components/ColorPalette';\r\nimport { checkIfNullOrUndefined } from '@/Utils/checkIfNullOrUndefined';\r\nimport { DetailsModal } from '@/Components/Elements/DetailsModal';\r\n\r\ninterface Props {\r\n data: TreeMapDataType[];\r\n colors: string[];\r\n colorDomain: string[];\r\n leftMargin: number;\r\n rightMargin: number;\r\n topMargin: number;\r\n bottomMargin: number;\r\n showLabels: boolean;\r\n showValues: boolean;\r\n width: number;\r\n height: number;\r\n suffix: string;\r\n prefix: string;\r\n selectedColor?: string;\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n tooltip?: string | ((_d: any) => React.ReactNode);\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n onSeriesMouseOver?: (_d: any) => void;\r\n highlightedDataPoints?: (string | number)[];\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n onSeriesMouseClick?: (_d: any) => void;\r\n theme: 'light' | 'dark';\r\n maxRadiusValue?: number;\r\n radius: number;\r\n resetSelectionOnDoubleClick: boolean;\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n detailsOnClick?: string | ((_d: any) => React.ReactNode);\r\n styles?: StyleObject;\r\n classNames?: ClassNameObject;\r\n dimmedOpacity: number;\r\n precision: number;\r\n locale: string;\r\n}\r\n\r\ninterface TreeMapDataTypeForBubbleChart extends TreeMapDataType {\r\n x: number;\r\n y: number;\r\n vx: number;\r\n vy: number;\r\n}\r\n\r\nexport const Graph = (props: Props) => {\r\n const {\r\n data,\r\n colors,\r\n leftMargin,\r\n width,\r\n height,\r\n colorDomain,\r\n selectedColor,\r\n rightMargin,\r\n topMargin,\r\n bottomMargin,\r\n showLabels,\r\n tooltip,\r\n onSeriesMouseOver,\r\n showValues,\r\n suffix,\r\n prefix,\r\n highlightedDataPoints,\r\n onSeriesMouseClick,\r\n maxRadiusValue,\r\n radius,\r\n resetSelectionOnDoubleClick,\r\n detailsOnClick,\r\n styles,\r\n classNames,\r\n dimmedOpacity,\r\n precision,\r\n locale,\r\n } = props;\r\n const svgRef = useRef(null);\r\n\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n const [mouseOverData, setMouseOverData] = useState<any>(undefined);\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n const [mouseClickData, setMouseClickData] = useState<any>(undefined);\r\n const [viewPortDimensions, setViewPortDimensions] = useState<\r\n [number, number, number, number] | undefined\r\n >(undefined);\r\n const [eventX, setEventX] = useState<number | undefined>(undefined);\r\n const [eventY, setEventY] = useState<number | undefined>(undefined);\r\n const [finalData, setFinalData] = useState<TreeMapDataTypeForBubbleChart[] | null>(null);\r\n\r\n const margin = {\r\n top: topMargin,\r\n bottom: bottomMargin,\r\n left: leftMargin,\r\n right: rightMargin,\r\n };\r\n\r\n const graphWidth = width - margin.left - margin.right;\r\n const graphHeight = height - margin.top - margin.bottom;\r\n\r\n // Memoize data ordering and radius scale\r\n const dataOrdered =\r\n data.filter(d => !checkIfNullOrUndefined(d.size)).length === 0\r\n ? data\r\n : orderBy(\r\n data.filter(d => !checkIfNullOrUndefined(d.size)),\r\n 'radius',\r\n 'asc',\r\n );\r\n\r\n const radiusScale =\r\n data.filter(d => d.size === undefined || d.size === null).length !== data.length\r\n ? scaleSqrt()\r\n .domain([\r\n 0,\r\n checkIfNullOrUndefined(maxRadiusValue)\r\n ? Math.max(...data.map(d => d.size).filter(d => d !== undefined && d !== null))\r\n : (maxRadiusValue as number),\r\n ])\r\n .range([0.25, radius])\r\n .nice()\r\n : undefined;\r\n\r\n // Memoize simulation setup\r\n useEffect(() => {\r\n const setupSimulation = () => {\r\n const dataTemp = dataOrdered.map(d => ({ ...d, ...(d.data && { data: { ...d.data } }) }));\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n const simulation = forceSimulation(dataTemp as any)\r\n .force('y', forceY(_d => graphHeight / 2).strength(1))\r\n .force('x', forceX(_d => graphWidth / 2).strength(1))\r\n .force(\r\n 'collide',\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n forceCollide((d: any) => (radiusScale ? radiusScale(d.size || 0) + 1 : radius + 1)),\r\n )\r\n .force('charge', forceManyBody().strength(-15))\r\n .force('boundary', forceBoundary(0, 0, graphWidth, graphHeight).strength(0.2).border(50))\r\n .alphaDecay(0.05)\r\n .tick(10000);\r\n\r\n simulation\r\n .on('tick', () => {\r\n setFinalData(dataTemp as TreeMapDataTypeForBubbleChart[]);\r\n })\r\n .on('end', () => {\r\n setFinalData(dataTemp as TreeMapDataTypeForBubbleChart[]);\r\n const xMinExtent =\r\n extent(\r\n dataTemp as TreeMapDataTypeForBubbleChart[],\r\n d => d.x - (radiusScale ? radiusScale(d.size || 0) + 1 : radius + 1),\r\n )[0] || 0;\r\n const yMinExtent =\r\n extent(\r\n dataTemp as TreeMapDataTypeForBubbleChart[],\r\n d => d.y - (radiusScale ? radiusScale(d.size || 0) + 1 : radius + 1),\r\n )[0] || 0;\r\n const xMaxExtent =\r\n extent(\r\n dataTemp as TreeMapDataTypeForBubbleChart[],\r\n d => d.x + (radiusScale ? radiusScale(d.size || 0) + 1 : radius + 1),\r\n )[1] || 0;\r\n const yMaxExtent =\r\n extent(\r\n dataTemp as TreeMapDataTypeForBubbleChart[],\r\n d => d.y + (radiusScale ? radiusScale(d.size || 0) + 1 : radius + 1),\r\n )[1] || 0;\r\n setViewPortDimensions([\r\n xMinExtent,\r\n yMinExtent,\r\n xMinExtent < 0 ? xMaxExtent - xMinExtent : xMaxExtent,\r\n yMinExtent < 0 ? yMaxExtent - yMinExtent : yMaxExtent,\r\n ]);\r\n });\r\n };\r\n\r\n setupSimulation();\r\n }, [data, radius, graphHeight, graphWidth, maxRadiusValue, dataOrdered, radiusScale]);\r\n\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n const handleMouseEnter = (event: any, d: any) => {\r\n setMouseOverData(d);\r\n setEventY(event.clientY);\r\n setEventX(event.clientX);\r\n onSeriesMouseOver?.(d);\r\n };\r\n\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n const handleMouseMove = (event: any, d: any) => {\r\n setMouseOverData(d);\r\n setEventY(event.clientY);\r\n setEventX(event.clientX);\r\n };\r\n\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n const handleClick = (d: any) => {\r\n if (onSeriesMouseClick || detailsOnClick) {\r\n if (mouseClickData === d.label && resetSelectionOnDoubleClick) {\r\n setMouseClickData(undefined);\r\n onSeriesMouseClick?.(undefined);\r\n } else {\r\n setMouseClickData(d.label);\r\n onSeriesMouseClick?.(d);\r\n }\r\n }\r\n };\r\n\r\n const handleMouseLeave = () => {\r\n setMouseOverData(undefined);\r\n setEventX(undefined);\r\n setEventY(undefined);\r\n onSeriesMouseOver?.(undefined);\r\n };\r\n\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n const getCircleColor = (d: any) =>\r\n data.filter(el => el.color).length === 0\r\n ? colors[0]\r\n : !d.color\r\n ? Colors.gray\r\n : colors[colorDomain.indexOf(d.color)];\r\n\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n const getOpacity = (d: any) =>\r\n selectedColor\r\n ? d.color\r\n ? colors[colorDomain.indexOf(d.color)] === selectedColor\r\n ? 1\r\n : dimmedOpacity\r\n : dimmedOpacity\r\n : highlightedDataPoints\r\n ? highlightedDataPoints.indexOf(d.label) !== -1\r\n ? 0.85\r\n : dimmedOpacity\r\n : 0.85;\r\n\r\n // Render loading state\r\n if (!finalData) {\r\n return (\r\n <div style={{ width: `${width}px`, height: `${height}px` }}>\r\n <div className='flex m-auto items-center justify-center p-0 leading-none text-base h-40'>\r\n <Spinner />\r\n </div>\r\n </div>\r\n );\r\n }\r\n if (viewPortDimensions) {\r\n return (\r\n <>\r\n <svg\r\n width={`${width}px`}\r\n height={`${height}px`}\r\n viewBox={`${viewPortDimensions[0] > 0 ? 0 : viewPortDimensions[0]} ${\r\n viewPortDimensions[1] > 0 ? 0 : viewPortDimensions[1]\r\n } ${width < viewPortDimensions[2] ? viewPortDimensions[2] : width} ${\r\n height < viewPortDimensions[3] ? viewPortDimensions[3] : height\r\n }`}\r\n direction='ltr'\r\n ref={svgRef}\r\n >\r\n <g transform={`translate(${margin.left},${margin.top})`}>\r\n {finalData.map(d => {\r\n const circleColor = getCircleColor(d);\r\n const opacity = getOpacity(d);\r\n const bubbleRadius = radiusScale ? radiusScale(d.size || 0) : radius;\r\n const showLabel = bubbleRadius > 20 && (showLabels || showValues);\r\n return (\r\n <g\r\n className='undp-viz-g-with-hover'\r\n key={d.label}\r\n opacity={opacity}\r\n transform={`translate(${d.x},${d.y})`}\r\n onMouseEnter={event => handleMouseEnter(event, d)}\r\n onMouseMove={event => handleMouseMove(event, d)}\r\n onClick={() => handleClick(d)}\r\n onMouseLeave={handleMouseLeave}\r\n >\r\n <circle cx={0} cy={0} r={bubbleRadius} fill={circleColor} />\r\n {(showLabel || showValues) &&\r\n d.size !== undefined &&\r\n d.size !== null &&\r\n bubbleRadius >= 15 && (\r\n <g>\r\n <foreignObject\r\n y={0 - bubbleRadius}\r\n x={0 - bubbleRadius}\r\n width={2 * bubbleRadius}\r\n height={2 * bubbleRadius}\r\n >\r\n <div\r\n className='flex flex-col justify-center items-center h-full py-0 px-3'\r\n style={{\r\n display: 'flex',\r\n flexDirection: 'column',\r\n justifyContent: 'center',\r\n alignItems: 'center',\r\n height: '100%',\r\n padding: '0 0.75rem',\r\n }}\r\n >\r\n {showLabels && (\r\n <P\r\n className={cn(\r\n 'text-center leading-[1.25] overflow-hidden m-0 circle-packing-label',\r\n classNames?.graphObjectValues,\r\n )}\r\n marginBottom='none'\r\n style={{\r\n fontSize: `${Math.min(\r\n Math.max(Math.round(bubbleRadius / 4), 12),\r\n Math.max(\r\n Math.round((bubbleRadius * 12) / `${d.label}`.length),\r\n 12,\r\n ),\r\n 14,\r\n )}px`,\r\n WebkitLineClamp:\r\n bubbleRadius * 2 < 60\r\n ? 1\r\n : bubbleRadius * 2 < 75\r\n ? 2\r\n : bubbleRadius * 2 < 100\r\n ? 3\r\n : undefined,\r\n display: '-webkit-box',\r\n WebkitBoxOrient: 'vertical',\r\n color: getTextColorBasedOnBgColor(circleColor),\r\n hyphens: 'auto',\r\n ...(styles?.graphObjectValues || {}),\r\n }}\r\n >\r\n {d.label}\r\n </P>\r\n )}\r\n {showValues && (\r\n <P\r\n className='text-center font-bold leading-[1.25] w-full m-0 circle-packing-value'\r\n marginBottom='none'\r\n style={{\r\n fontSize: `${Math.min(\r\n Math.max(Math.round(bubbleRadius / 4), 14),\r\n 14,\r\n )}px`,\r\n color: getTextColorBasedOnBgColor(circleColor),\r\n }}\r\n >\r\n {numberFormattingFunction(\r\n d.size,\r\n undefined,\r\n precision,\r\n prefix,\r\n suffix,\r\n locale,\r\n )}\r\n </P>\r\n )}\r\n </div>\r\n </foreignObject>\r\n </g>\r\n )}\r\n </g>\r\n );\r\n })}\r\n </g>\r\n </svg>\r\n {mouseOverData && tooltip && eventX && eventY && (\r\n <Tooltip\r\n data={mouseOverData}\r\n body={tooltip}\r\n xPos={eventX}\r\n yPos={eventY}\r\n backgroundStyle={styles?.tooltip}\r\n className={classNames?.tooltip}\r\n />\r\n )}\r\n {detailsOnClick && mouseClickData !== undefined ? (\r\n <DetailsModal\r\n body={detailsOnClick}\r\n data={mouseClickData}\r\n setData={setMouseClickData}\r\n className={classNames?.modal}\r\n />\r\n ) : null}\r\n </>\r\n );\r\n }\r\n return null;\r\n};\r\n","export function getMaxCircleRadius(\r\n values: (number | undefined | null)[],\r\n width: number,\r\n height: number,\r\n circularBoundary?: boolean,\r\n) {\r\n const filteredValues = values.filter(d => d !== undefined && d !== null);\r\n const containerRadius =\r\n circularBoundary === false\r\n ? Math.sqrt((width * height) / Math.PI)\r\n : Math.min(width, height) / 2;\r\n const totalValue = filteredValues.reduce((sum, v) => sum + v, 0);\r\n const maxValue = Math.max(...filteredValues);\r\n const getPackingEfficiency = (n: number) => {\r\n if (n <= 5) return 0.9;\r\n if (n <= 10) return 0.85;\r\n if (n <= 20) return 0.8;\r\n return 0.7;\r\n };\r\n const getEfficiencyBecauseOfContainerRadius = (r: number) => {\r\n if (r <= 200) return 0.85;\r\n if (r <= 250) return 0.95;\r\n return 1;\r\n };\r\n return (\r\n containerRadius *\r\n Math.sqrt(maxValue / totalValue) *\r\n (circularBoundary ? getEfficiencyBecauseOfContainerRadius(containerRadius) : 1) *\r\n (circularBoundary ? getPackingEfficiency(filteredValues.length) : 1)\r\n );\r\n}\r\n","import { useState, useRef, useEffect } from 'react';\r\n\r\nimport { Graph } from './Graph';\r\nimport { getMaxCircleRadius } from './getMaxCircleRadius';\r\n\r\nimport { Languages, SourcesDataType, StyleObject, ClassNameObject, TreeMapDataType } from '@/Types';\r\nimport { GraphFooter } from '@/Components/Elements/GraphFooter';\r\nimport { GraphHeader } from '@/Components/Elements/GraphHeader';\r\nimport { ColorLegendWithMouseOver } from '@/Components/Elements/ColorLegendWithMouseOver';\r\nimport { Colors } from '@/Components/ColorPalette';\r\nimport { EmptyState } from '@/Components/Elements/EmptyState';\r\nimport { uniqBy } from '@/Utils/uniqBy';\r\nimport { GraphArea, GraphContainer } from '@/Components/Elements/GraphContainer';\r\n\r\ninterface Props {\r\n // Data\r\n /** Array of data objects */\r\n data: TreeMapDataType[];\r\n\r\n // Titles, Labels, and Sources\r\n /** Title of the graph */\r\n graphTitle?: string | React.ReactNode;\r\n /** Description of the graph */\r\n graphDescription?: string | React.ReactNode;\r\n /** Footnote for the graph */\r\n footNote?: string | React.ReactNode;\r\n /** Source data for the graph */\r\n sources?: SourcesDataType[];\r\n /** Accessibility label */\r\n ariaLabel?: string;\r\n\r\n // Colors and Styling\r\n /** Color or array of colors for circle */\r\n colors?: string | string[];\r\n /** Domain of colors for the graph */\r\n colorDomain?: string[];\r\n /** Title for the color legend */\r\n colorLegendTitle?: string;\r\n /** Background color of the graph */\r\n backgroundColor?: string | boolean;\r\n /** Custom styles for the graph. Each object should be a valid React CSS style object. */\r\n styles?: StyleObject;\r\n /** Custom class names */\r\n classNames?: ClassNameObject;\r\n\r\n // Size and Spacing\r\n /** Width of the graph */\r\n width?: number;\r\n /** Height of the graph */\r\n height?: number;\r\n /** Minimum height of the graph */\r\n minHeight?: number;\r\n /** Relative height scaling factor. This overwrites the height props */\r\n relativeHeight?: number;\r\n /** Padding around the graph. Defaults to 0 if no backgroundColor is mentioned else defaults to 1rem */\r\n padding?: string;\r\n /** Left margin of the graph */\r\n leftMargin?: number;\r\n /** Right margin of the graph */\r\n rightMargin?: number;\r\n /** Top margin of the graph */\r\n topMargin?: number;\r\n /** Bottom margin of the graph */\r\n bottomMargin?: number;\r\n\r\n // Values and Ticks\r\n /** Prefix for values */\r\n prefix?: string;\r\n /** Suffix for values */\r\n suffix?: string;\r\n /** Maximum value mapped to the radius chart */\r\n maxRadiusValue?: number;\r\n\r\n // Graph Parameters\r\n /** If true, the graph will be rendered in a circle layout */\r\n circularBoundary?: boolean;\r\n /** Maximum radius of the circle */\r\n radius?: number;\r\n /** Toggle visibility of labels */\r\n showLabels?: boolean;\r\n /** Toggle visibility of values */\r\n showValues?: boolean;\r\n /** Toggle visibility of color scale. This is only applicable if the data props hae color parameter */\r\n showColorScale?: boolean;\r\n /** Toggle visibility of NA color in the color scale. This is only applicable if the data props hae color parameter and showColorScale prop is true */\r\n showNAColor?: boolean;\r\n /** Data points to highlight. Use the label value from data to highlight the data point */\r\n highlightedDataPoints?: (string | number)[];\r\n /** Defines the opacity of the non-highlighted data */\r\n dimmedOpacity?: number;\r\n /** Specifies the number of decimal places to display in the value. */\r\n precision?: number;\r\n /** Locale for number formatting. Must matches what `Intl.NumberFormat` expects. */\r\n locale?: string;\r\n /** Enable graph download option as png */\r\n graphDownload?: boolean;\r\n /** Enable data download option as a csv */\r\n dataDownload?: boolean;\r\n /** Reset selection on double-click. Only applicable when used in a dashboard context with filters. */\r\n resetSelectionOnDoubleClick?: boolean;\r\n\r\n // Interactions and Callbacks\r\n /** Tooltip content. If the type is string then this uses the [handlebar](../?path=/docs/misc-handlebars-templates-and-custom-helpers--docs) template to display the data */\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n tooltip?: string | ((_d: any) => React.ReactNode);\r\n /** Details displayed on the modal when user clicks of a data point. If the type is string then this uses the [handlebar](../?path=/docs/misc-handlebars-templates-and-custom-helpers--docs) template to display the data */\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n detailsOnClick?: string | ((_d: any) => React.ReactNode);\r\n /** Callback for mouse over event */\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n onSeriesMouseOver?: (_d: any) => void;\r\n /** Callback for mouse click event */\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n onSeriesMouseClick?: (_d: any) => void;\r\n\r\n // Configuration and Options\r\n /** Language setting */\r\n language?: Languages;\r\n /** Color theme */\r\n theme?: 'light' | 'dark';\r\n /** Unique ID for the graph */\r\n graphID?: string;\r\n}\r\n\r\nexport function CirclePackingGraph(props: Props) {\r\n const {\r\n data,\r\n graphTitle,\r\n colors,\r\n suffix = '',\r\n sources,\r\n prefix = '',\r\n graphDescription,\r\n leftMargin = 0,\r\n rightMargin = 0,\r\n height,\r\n width,\r\n footNote,\r\n colorDomain,\r\n colorLegendTitle,\r\n padding,\r\n backgroundColor = false,\r\n topMargin = 0,\r\n bottomMargin = 0,\r\n showLabels = true,\r\n relativeHeight,\r\n tooltip,\r\n onSeriesMouseOver,\r\n showColorScale = true,\r\n showValues,\r\n graphID,\r\n highlightedDataPoints,\r\n onSeriesMouseClick,\r\n graphDownload = false,\r\n dataDownload = false,\r\n language = 'en',\r\n showNAColor,\r\n minHeight = 0,\r\n theme = 'light',\r\n ariaLabel,\r\n radius,\r\n maxRadiusValue,\r\n resetSelectionOnDoubleClick = true,\r\n detailsOnClick,\r\n styles,\r\n classNames,\r\n dimmedOpacity = 0.3,\r\n precision = 2,\r\n circularBoundary = true,\r\n locale = 'en',\r\n } = props;\r\n const [svgWidth, setSvgWidth] = useState(0);\r\n const [svgHeight, setSvgHeight] = useState(0);\r\n const [selectedColor, setSelectedColor] = useState<string | undefined>(undefined);\r\n const graphDiv = useRef<HTMLDivElement>(null);\r\n const graphParentDiv = useRef<HTMLDivElement>(null);\r\n useEffect(() => {\r\n const resizeObserver = new ResizeObserver(entries => {\r\n setSvgWidth(entries[0].target.clientWidth || 620);\r\n setSvgHeight(entries[0].target.clientHeight || 480);\r\n });\r\n if (graphDiv.current) {\r\n resizeObserver.observe(graphDiv.current);\r\n }\r\n return () => resizeObserver.disconnect();\r\n }, []);\r\n return (\r\n <GraphContainer\r\n className={classNames?.graphContainer}\r\n style={styles?.graphContainer}\r\n id={graphID}\r\n ref={graphParentDiv}\r\n aria-label={ariaLabel}\r\n backgroundColor={backgroundColor}\r\n theme={theme}\r\n language={language}\r\n minHeight={minHeight}\r\n width={width}\r\n height={height}\r\n relativeHeight={relativeHeight}\r\n padding={padding}\r\n >\r\n {graphTitle || graphDescription || graphDownload || dataDownload ? (\r\n <GraphHeader\r\n styles={{\r\n title: styles?.title,\r\n description: styles?.description,\r\n }}\r\n classNames={{\r\n title: classNames?.title,\r\n description: classNames?.description,\r\n }}\r\n graphTitle={graphTitle}\r\n graphDescription={graphDescription}\r\n width={width}\r\n graphDownload={graphDownload ? graphParentDiv : undefined}\r\n dataDownload={\r\n dataDownload\r\n ? data.map(d => d.data).filter(d => d !== undefined).length > 0\r\n ? data.map(d => d.data).filter(d => d !== undefined)\r\n : data.filter(d => d !== undefined)\r\n : null\r\n }\r\n />\r\n ) : null}\r\n {showColorScale && data.filter(el => el.color).length !== 0 && data.length > 0 ? (\r\n <ColorLegendWithMouseOver\r\n width={width}\r\n colorLegendTitle={colorLegendTitle}\r\n colors={(colors as string[] | undefined) || Colors[theme].categoricalColors.colors}\r\n colorDomain={colorDomain || (uniqBy(data, 'color', true) as string[])}\r\n setSelectedColor={setSelectedColor}\r\n showNAColor={showNAColor === undefined || showNAColor === null ? true : showNAColor}\r\n isCenter\r\n className={classNames?.colorLegend}\r\n />\r\n ) : null}\r\n <GraphArea ref={graphDiv}>\r\n {data.length === 0 && <EmptyState />}\r\n {svgWidth && svgHeight && data.length > 0 ? (\r\n <Graph\r\n data={data}\r\n colors={\r\n data.filter(el => el.color).length === 0\r\n ? colors\r\n ? [colors as string]\r\n : [Colors.primaryColors['blue-600']]\r\n : (colors as string[] | undefined) || Colors[theme].categoricalColors.colors\r\n }\r\n colorDomain={\r\n data.filter(el => el.color).length === 0\r\n ? []\r\n : colorDomain || (uniqBy(data, 'color', true) as string[])\r\n }\r\n width={svgWidth}\r\n height={svgHeight}\r\n leftMargin={leftMargin}\r\n rightMargin={rightMargin}\r\n topMargin={topMargin}\r\n bottomMargin={bottomMargin}\r\n showLabels={showLabels}\r\n showValues={\r\n showValues !== false\r\n ? data.filter(el => el.size).length !== 0\r\n : (showValues as boolean)\r\n }\r\n selectedColor={selectedColor}\r\n suffix={suffix}\r\n prefix={prefix}\r\n tooltip={tooltip}\r\n onSeriesMouseOver={onSeriesMouseOver}\r\n highlightedDataPoints={highlightedDataPoints}\r\n onSeriesMouseClick={onSeriesMouseClick}\r\n theme={theme}\r\n radius={\r\n !radius\r\n ? getMaxCircleRadius(\r\n data.map(d => d.size),\r\n svgWidth,\r\n svgHeight,\r\n circularBoundary,\r\n )\r\n : radius\r\n }\r\n maxRadiusValue={maxRadiusValue}\r\n resetSelectionOnDoubleClick={resetSelectionOnDoubleClick}\r\n detailsOnClick={detailsOnClick}\r\n styles={styles}\r\n classNames={classNames}\r\n dimmedOpacity={dimmedOpacity}\r\n precision={precision}\r\n locale={locale}\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":["extent","values","valueof","min","max","value","index","constant","x","forceBoundary","x0","y0","x1","y1","strength","hardBoundary","border","nodes","strengthsX","strengthsY","x0z","x1z","y0z","y1z","borderz","halfX","halfY","getVx","strengthX","alpha","force","i","n","node","initialize","_","Graph","props","$","_c","data","colors","leftMargin","width","height","colorDomain","selectedColor","rightMargin","topMargin","bottomMargin","showLabels","tooltip","onSeriesMouseOver","showValues","suffix","prefix","highlightedDataPoints","onSeriesMouseClick","maxRadiusValue","radius","resetSelectionOnDoubleClick","detailsOnClick","styles","classNames","dimmedOpacity","precision","locale","svgRef","useRef","mouseOverData","setMouseOverData","useState","undefined","mouseClickData","setMouseClickData","viewPortDimensions","setViewPortDimensions","eventX","setEventX","eventY","setEventY","finalData","setFinalData","t0","top","bottom","left","right","margin","graphWidth","graphHeight","t1","filter","_temp","length","orderBy","_temp2","dataOrdered","t2","_temp3","scaleSqrt","domain","checkIfNullOrUndefined","Math","map","_temp4","_temp5","range","nice","radiusScale","t3","setupSimulation","dataTemp","_temp6","forceSimulation","forceY","_d","forceX","_d_0","forceCollide","d_5","d","size","forceManyBody","alphaDecay","tick","on","xMinExtent","d_6","yMinExtent","d_7","y","xMaxExtent","d_8","yMaxExtent","d_9","t4","useEffect","t5","event","d_10","clientY","clientX","handleMouseEnter","t6","Symbol","for","event_0","d_11","handleMouseMove","t7","d_12","label","handleClick","t8","handleMouseLeave","t9","d_13","_temp7","color","indexOf","Colors","gray","getCircleColor","t10","d_14","getOpacity","t11","t12","t13","t14","jsx","Spinner","t15","graphObjectValues","t16","d_15","circleColor","opacity","bubbleRadius","showLabel","jsxs","event_1","event_2","display","flexDirection","justifyContent","alignItems","padding","P","cn","fontSize","round","WebkitLineClamp","WebkitBoxOrient","getTextColorBasedOnBgColor","hyphens","numberFormattingFunction","t17","t18","Tooltip","t19","modal","DetailsModal","t20","Fragment","d_0","d_3","d_1","d_2","d_4","el","getMaxCircleRadius","circularBoundary","filteredValues","containerRadius","sqrt","PI","totalValue","reduce","sum","v","maxValue","getPackingEfficiency","getEfficiencyBecauseOfContainerRadius","r","CirclePackingGraph","graphTitle","sources","graphDescription","footNote","colorLegendTitle","backgroundColor","relativeHeight","showColorScale","graphID","graphDownload","dataDownload","language","showNAColor","minHeight","theme","ariaLabel","svgWidth","setSvgWidth","svgHeight","setSvgHeight","setSelectedColor","graphDiv","graphParentDiv","resizeObserver","ResizeObserver","entries","target","clientWidth","clientHeight","current","observe","disconnect","t21","graphContainer","t22","t23","description","title","GraphHeader","t24","colorLegend","ColorLegendWithMouseOver","categoricalColors","uniqBy","t25","EmptyState","t26","primaryColors","_temp8","_temp9","_temp0","t27","GraphArea","t28","footnote","source","GraphFooter","t29","GraphContainer","el_2","el_1","el_0"],"mappings":"kvBAAe,SAASA,GAAOC,EAAQC,EAAS,CAC9C,IAAIC,EACAC,EACJ,GAAIF,IAAY,OACd,UAAWG,KAASJ,EACdI,GAAS,OACPF,IAAQ,OACNE,GAASA,IAAOF,EAAMC,EAAMC,IAE5BF,EAAME,IAAOF,EAAME,GACnBD,EAAMC,IAAOD,EAAMC,SAIxB,CACL,IAAIC,EAAQ,GACZ,QAASD,KAASJ,GACXI,EAAQH,EAAQG,EAAO,EAAEC,EAAOL,CAAM,IAAM,OAC3CE,IAAQ,OACNE,GAASA,IAAOF,EAAMC,EAAMC,IAE5BF,EAAME,IAAOF,EAAME,GACnBD,EAAMC,IAAOD,EAAMC,IAI/B,CACA,MAAO,CAACF,EAAKC,CAAG,CAClB,CC3BA,SAASG,EAASC,EAAG,CACnB,OAAO,UAAW,CAChB,OAAOA,CACT,CACF,CAEA,SAASC,GAAcC,EAAIC,EAAIC,EAAIC,EAAI,CACrC,IAAIC,EAAWP,EAAS,EAAG,EACvBQ,EAAe,GACfC,EAAST,EAAU,KAAK,KAAKK,EAAKF,GAAI,GAAIG,EAAKF,GAAI,CAAC,CAAC,EACrDM,EACAC,EACAC,EACAC,EAAKC,EACLC,EAAKC,EACLC,EACAC,EAAOC,EAEP,OAAOhB,GAAO,aAAYA,EAAKH,EAASG,GAAM,KAAO,KAAO,CAACA,CAAE,GAC/D,OAAOE,GAAO,aAAYA,EAAKL,EAAS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IAAK,CAzJjC,SAAA0J,GAAAU,EAAA,CAAA,OA2I6B3E,EAAEzF,IAAK,CA3IpC,SAAAyJ,GAAAY,EAAA,CAAA,OA8HyB5E,EAAEpD,KAAM,CA9HjC,SAAAD,GAAAkI,EAAA,CAAA,OAuHyB7E,EAAEpD,KAAM,CAvHjC,SAAA9C,GAAAkG,EAAA,CAAA,OAqGoCA,EAAEpD,KAAM,CArG5C,SAAArD,GAAAsG,EAAA,CAAA,OAgG4BvF,IAAMjD,MAAS,CAhG3C,SAAAiC,GAAAqG,EAAA,CAAA,OA+F6CrF,IAAMjD,MAAS,CA/F5D,SAAA2B,GAAAsB,EAAA,CAAA,OA+FyBA,EAACjF,IAAK,CA/F/B,SAAAwD,GAAA+G,EAAA,CAAA,OA8F2CtF,IAAMjD,MAAS,CA9F1D,SAAAqB,GAAAoH,EAAA,CAAA,OA8FuBxF,EAACjF,IAAK","x_google_ignoreList":[0,1]}
@@ -1,7 +1,7 @@
1
- import { j as R } from "./index-CHPV5EwG-BCLAYDCV.js";
1
+ import { j as R } from "./index-CHPV5EwG-BzibaIRc.js";
2
2
  import * as v from "react";
3
3
  import { useId as T, useRef as P, useContext as D, useInsertionEffect as N, useMemo as $, Children as U, isValidElement as V, useState as z } from "react";
4
- import { M as X, i as _, u as S, P as B, a as F, b as G, L as O } from "./proxy--_f6k3NR.js";
4
+ import { M as X, i as _, u as S, P as B, a as F, b as G, L as O } from "./proxy-BsxtcZKa.js";
5
5
  function A(e, s) {
6
6
  if (typeof e == "function")
7
7
  return e(s);
@@ -145,4 +145,4 @@ const oe = ({ children: e, custom: s, initial: t = !0, onExitComplete: r, presen
145
145
  export {
146
146
  oe as A
147
147
  };
148
- //# sourceMappingURL=index-Co3YGYe1.js.map
148
+ //# sourceMappingURL=index-Cv_5q6Rb.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index-Co3YGYe1.js","sources":["../node_modules/framer-motion/dist/es/utils/use-composed-ref.mjs","../node_modules/framer-motion/dist/es/components/AnimatePresence/PopChild.mjs","../node_modules/framer-motion/dist/es/components/AnimatePresence/PresenceChild.mjs","../node_modules/framer-motion/dist/es/components/AnimatePresence/utils.mjs","../node_modules/framer-motion/dist/es/components/AnimatePresence/index.mjs"],"sourcesContent":["import * as React from 'react';\n\n/**\n * Taken from https://github.com/radix-ui/primitives/blob/main/packages/react/compose-refs/src/compose-refs.tsx\n */\n/**\n * Set a given ref to a given value\n * This utility takes care of different types of refs: callback refs and RefObject(s)\n */\nfunction setRef(ref, value) {\n if (typeof ref === \"function\") {\n return ref(value);\n }\n else if (ref !== null && ref !== undefined) {\n ref.current = value;\n }\n}\n/**\n * A utility to compose multiple refs together\n * Accepts callback refs and RefObject(s)\n */\nfunction composeRefs(...refs) {\n return (node) => {\n let hasCleanup = false;\n const cleanups = refs.map((ref) => {\n const cleanup = setRef(ref, node);\n if (!hasCleanup && typeof cleanup === \"function\") {\n hasCleanup = true;\n }\n return cleanup;\n });\n // React <19 will log an error to the console if a callback ref returns a\n // value. We don't use ref cleanups internally so this will only happen if a\n // user's ref callback returns a value, which we only expect if they are\n // using the cleanup functionality added in React 19.\n if (hasCleanup) {\n return () => {\n for (let i = 0; i < cleanups.length; i++) {\n const cleanup = cleanups[i];\n if (typeof cleanup === \"function\") {\n cleanup();\n }\n else {\n setRef(refs[i], null);\n }\n }\n };\n }\n };\n}\n/**\n * A custom hook that composes multiple refs\n * Accepts callback refs and RefObject(s)\n */\nfunction useComposedRefs(...refs) {\n // eslint-disable-next-line react-hooks/exhaustive-deps\n return React.useCallback(composeRefs(...refs), refs);\n}\n\nexport { useComposedRefs };\n//# sourceMappingURL=use-composed-ref.mjs.map\n","\"use client\";\nimport { jsx } from 'react/jsx-runtime';\nimport { isHTMLElement } from 'motion-dom';\nimport * as React from 'react';\nimport { useId, useRef, useContext, useInsertionEffect } from 'react';\nimport { MotionConfigContext } from '../../context/MotionConfigContext.mjs';\nimport { useComposedRefs } from '../../utils/use-composed-ref.mjs';\n\n/**\n * Measurement functionality has to be within a separate component\n * to leverage snapshot lifecycle.\n */\nclass PopChildMeasure extends React.Component {\n getSnapshotBeforeUpdate(prevProps) {\n const element = this.props.childRef.current;\n if (element && prevProps.isPresent && !this.props.isPresent) {\n const parent = element.offsetParent;\n const parentWidth = isHTMLElement(parent)\n ? parent.offsetWidth || 0\n : 0;\n const size = this.props.sizeRef.current;\n size.height = element.offsetHeight || 0;\n size.width = element.offsetWidth || 0;\n size.top = element.offsetTop;\n size.left = element.offsetLeft;\n size.right = parentWidth - size.width - size.left;\n }\n return null;\n }\n /**\n * Required with getSnapshotBeforeUpdate to stop React complaining.\n */\n componentDidUpdate() { }\n render() {\n return this.props.children;\n }\n}\nfunction PopChild({ children, isPresent, anchorX, root }) {\n const id = useId();\n const ref = useRef(null);\n const size = useRef({\n width: 0,\n height: 0,\n top: 0,\n left: 0,\n right: 0,\n });\n const { nonce } = useContext(MotionConfigContext);\n /**\n * In React 19, refs are passed via props.ref instead of element.ref.\n * We check props.ref first (React 19) and fall back to element.ref (React 18).\n */\n const childRef = children.props?.ref ??\n children?.ref;\n const composedRef = useComposedRefs(ref, childRef);\n /**\n * We create and inject a style block so we can apply this explicit\n * sizing in a non-destructive manner by just deleting the style block.\n *\n * We can't apply size via render as the measurement happens\n * in getSnapshotBeforeUpdate (post-render), likewise if we apply the\n * styles directly on the DOM node, we might be overwriting\n * styles set via the style prop.\n */\n useInsertionEffect(() => {\n const { width, height, top, left, right } = size.current;\n if (isPresent || !ref.current || !width || !height)\n return;\n const x = anchorX === \"left\" ? `left: ${left}` : `right: ${right}`;\n ref.current.dataset.motionPopId = id;\n const style = document.createElement(\"style\");\n if (nonce)\n style.nonce = nonce;\n const parent = root ?? document.head;\n parent.appendChild(style);\n if (style.sheet) {\n style.sheet.insertRule(`\n [data-motion-pop-id=\"${id}\"] {\n position: absolute !important;\n width: ${width}px !important;\n height: ${height}px !important;\n ${x}px !important;\n top: ${top}px !important;\n }\n `);\n }\n return () => {\n if (parent.contains(style)) {\n parent.removeChild(style);\n }\n };\n }, [isPresent]);\n return (jsx(PopChildMeasure, { isPresent: isPresent, childRef: ref, sizeRef: size, children: React.cloneElement(children, { ref: composedRef }) }));\n}\n\nexport { PopChild };\n//# sourceMappingURL=PopChild.mjs.map\n","\"use client\";\nimport { jsx } from 'react/jsx-runtime';\nimport * as React from 'react';\nimport { useId, useMemo } from 'react';\nimport { PresenceContext } from '../../context/PresenceContext.mjs';\nimport { useConstant } from '../../utils/use-constant.mjs';\nimport { PopChild } from './PopChild.mjs';\n\nconst PresenceChild = ({ children, initial, isPresent, onExitComplete, custom, presenceAffectsLayout, mode, anchorX, root }) => {\n const presenceChildren = useConstant(newChildrenMap);\n const id = useId();\n let isReusedContext = true;\n let context = useMemo(() => {\n isReusedContext = false;\n return {\n id,\n initial,\n isPresent,\n custom,\n onExitComplete: (childId) => {\n presenceChildren.set(childId, true);\n for (const isComplete of presenceChildren.values()) {\n if (!isComplete)\n return; // can stop searching when any is incomplete\n }\n onExitComplete && onExitComplete();\n },\n register: (childId) => {\n presenceChildren.set(childId, false);\n return () => presenceChildren.delete(childId);\n },\n };\n }, [isPresent, presenceChildren, onExitComplete]);\n /**\n * If the presence of a child affects the layout of the components around it,\n * we want to make a new context value to ensure they get re-rendered\n * so they can detect that layout change.\n */\n if (presenceAffectsLayout && isReusedContext) {\n context = { ...context };\n }\n useMemo(() => {\n presenceChildren.forEach((_, key) => presenceChildren.set(key, false));\n }, [isPresent]);\n /**\n * If there's no `motion` components to fire exit animations, we want to remove this\n * component immediately.\n */\n React.useEffect(() => {\n !isPresent &&\n !presenceChildren.size &&\n onExitComplete &&\n onExitComplete();\n }, [isPresent]);\n if (mode === \"popLayout\") {\n children = (jsx(PopChild, { isPresent: isPresent, anchorX: anchorX, root: root, children: children }));\n }\n return (jsx(PresenceContext.Provider, { value: context, children: children }));\n};\nfunction newChildrenMap() {\n return new Map();\n}\n\nexport { PresenceChild };\n//# sourceMappingURL=PresenceChild.mjs.map\n","import { Children, isValidElement } from 'react';\n\nconst getChildKey = (child) => child.key || \"\";\nfunction onlyElements(children) {\n const filtered = [];\n // We use forEach here instead of map as map mutates the component key by preprending `.$`\n Children.forEach(children, (child) => {\n if (isValidElement(child))\n filtered.push(child);\n });\n return filtered;\n}\n\nexport { getChildKey, onlyElements };\n//# sourceMappingURL=utils.mjs.map\n","\"use client\";\nimport { jsx, Fragment } from 'react/jsx-runtime';\nimport { useMemo, useRef, useState, useContext } from 'react';\nimport { LayoutGroupContext } from '../../context/LayoutGroupContext.mjs';\nimport { useConstant } from '../../utils/use-constant.mjs';\nimport { useIsomorphicLayoutEffect } from '../../utils/use-isomorphic-effect.mjs';\nimport { PresenceChild } from './PresenceChild.mjs';\nimport { usePresence } from './use-presence.mjs';\nimport { onlyElements, getChildKey } from './utils.mjs';\n\n/**\n * `AnimatePresence` enables the animation of components that have been removed from the tree.\n *\n * When adding/removing more than a single child, every child **must** be given a unique `key` prop.\n *\n * Any `motion` components that have an `exit` property defined will animate out when removed from\n * the tree.\n *\n * ```jsx\n * import { motion, AnimatePresence } from 'framer-motion'\n *\n * export const Items = ({ items }) => (\n * <AnimatePresence>\n * {items.map(item => (\n * <motion.div\n * key={item.id}\n * initial={{ opacity: 0 }}\n * animate={{ opacity: 1 }}\n * exit={{ opacity: 0 }}\n * />\n * ))}\n * </AnimatePresence>\n * )\n * ```\n *\n * You can sequence exit animations throughout a tree using variants.\n *\n * If a child contains multiple `motion` components with `exit` props, it will only unmount the child\n * once all `motion` components have finished animating out. Likewise, any components using\n * `usePresence` all need to call `safeToRemove`.\n *\n * @public\n */\nconst AnimatePresence = ({ children, custom, initial = true, onExitComplete, presenceAffectsLayout = true, mode = \"sync\", propagate = false, anchorX = \"left\", root }) => {\n const [isParentPresent, safeToRemove] = usePresence(propagate);\n /**\n * Filter any children that aren't ReactElements. We can only track components\n * between renders with a props.key.\n */\n const presentChildren = useMemo(() => onlyElements(children), [children]);\n /**\n * Track the keys of the currently rendered children. This is used to\n * determine which children are exiting.\n */\n const presentKeys = propagate && !isParentPresent ? [] : presentChildren.map(getChildKey);\n /**\n * If `initial={false}` we only want to pass this to components in the first render.\n */\n const isInitialRender = useRef(true);\n /**\n * A ref containing the currently present children. When all exit animations\n * are complete, we use this to re-render the component with the latest children\n * *committed* rather than the latest children *rendered*.\n */\n const pendingPresentChildren = useRef(presentChildren);\n /**\n * Track which exiting children have finished animating out.\n */\n const exitComplete = useConstant(() => new Map());\n /**\n * Track which components are currently processing exit to prevent duplicate processing.\n */\n const exitingComponents = useRef(new Set());\n /**\n * Save children to render as React state. To ensure this component is concurrent-safe,\n * we check for exiting children via an effect.\n */\n const [diffedChildren, setDiffedChildren] = useState(presentChildren);\n const [renderedChildren, setRenderedChildren] = useState(presentChildren);\n useIsomorphicLayoutEffect(() => {\n isInitialRender.current = false;\n pendingPresentChildren.current = presentChildren;\n /**\n * Update complete status of exiting children.\n */\n for (let i = 0; i < renderedChildren.length; i++) {\n const key = getChildKey(renderedChildren[i]);\n if (!presentKeys.includes(key)) {\n if (exitComplete.get(key) !== true) {\n exitComplete.set(key, false);\n }\n }\n else {\n exitComplete.delete(key);\n exitingComponents.current.delete(key);\n }\n }\n }, [renderedChildren, presentKeys.length, presentKeys.join(\"-\")]);\n const exitingChildren = [];\n if (presentChildren !== diffedChildren) {\n let nextChildren = [...presentChildren];\n /**\n * Loop through all the currently rendered components and decide which\n * are exiting.\n */\n for (let i = 0; i < renderedChildren.length; i++) {\n const child = renderedChildren[i];\n const key = getChildKey(child);\n if (!presentKeys.includes(key)) {\n nextChildren.splice(i, 0, child);\n exitingChildren.push(child);\n }\n }\n /**\n * If we're in \"wait\" mode, and we have exiting children, we want to\n * only render these until they've all exited.\n */\n if (mode === \"wait\" && exitingChildren.length) {\n nextChildren = exitingChildren;\n }\n setRenderedChildren(onlyElements(nextChildren));\n setDiffedChildren(presentChildren);\n /**\n * Early return to ensure once we've set state with the latest diffed\n * children, we can immediately re-render.\n */\n return null;\n }\n if (process.env.NODE_ENV !== \"production\" &&\n mode === \"wait\" &&\n renderedChildren.length > 1) {\n console.warn(`You're attempting to animate multiple children within AnimatePresence, but its mode is set to \"wait\". This will lead to odd visual behaviour.`);\n }\n /**\n * If we've been provided a forceRender function by the LayoutGroupContext,\n * we can use it to force a re-render amongst all surrounding components once\n * all components have finished animating out.\n */\n const { forceRender } = useContext(LayoutGroupContext);\n return (jsx(Fragment, { children: renderedChildren.map((child) => {\n const key = getChildKey(child);\n const isPresent = propagate && !isParentPresent\n ? false\n : presentChildren === renderedChildren ||\n presentKeys.includes(key);\n const onExit = () => {\n if (exitingComponents.current.has(key)) {\n return;\n }\n exitingComponents.current.add(key);\n if (exitComplete.has(key)) {\n exitComplete.set(key, true);\n }\n else {\n return;\n }\n let isEveryExitComplete = true;\n exitComplete.forEach((isExitComplete) => {\n if (!isExitComplete)\n isEveryExitComplete = false;\n });\n if (isEveryExitComplete) {\n forceRender?.();\n setRenderedChildren(pendingPresentChildren.current);\n propagate && safeToRemove?.();\n onExitComplete && onExitComplete();\n }\n };\n return (jsx(PresenceChild, { isPresent: isPresent, initial: !isInitialRender.current || initial\n ? undefined\n : false, custom: custom, presenceAffectsLayout: presenceAffectsLayout, mode: mode, root: root, onExitComplete: isPresent ? undefined : onExit, anchorX: anchorX, children: child }, key));\n }) }));\n};\n\nexport { AnimatePresence };\n//# sourceMappingURL=index.mjs.map\n"],"names":["setRef","ref","value","composeRefs","refs","node","hasCleanup","cleanups","cleanup","useComposedRefs","React","PopChildMeasure","prevProps","element","parent","parentWidth","isHTMLElement","size","PopChild","children","isPresent","anchorX","root","id","useId","useRef","nonce","useContext","MotionConfigContext","childRef","composedRef","useInsertionEffect","width","height","top","left","right","x","style","jsx","PresenceChild","initial","onExitComplete","custom","presenceAffectsLayout","mode","presenceChildren","useConstant","newChildrenMap","isReusedContext","context","useMemo","childId","isComplete","_","key","PresenceContext","getChildKey","child","onlyElements","filtered","Children","isValidElement","AnimatePresence","propagate","isParentPresent","safeToRemove","usePresence","presentChildren","presentKeys","isInitialRender","pendingPresentChildren","exitComplete","exitingComponents","diffedChildren","setDiffedChildren","useState","renderedChildren","setRenderedChildren","useIsomorphicLayoutEffect","i","exitingChildren","nextChildren","forceRender","LayoutGroupContext","Fragment","onExit","isEveryExitComplete","isExitComplete"],"mappings":";;;;AASA,SAASA,EAAOC,GAAKC,GAAO;AACxB,MAAI,OAAOD,KAAQ;AACf,WAAOA,EAAIC,CAAK;AAEf,EAAID,KAAQ,SACbA,EAAI,UAAUC;AAEtB;AAKA,SAASC,KAAeC,GAAM;AAC1B,SAAO,CAACC,MAAS;AACb,QAAIC,IAAa;AACjB,UAAMC,IAAWH,EAAK,IAAI,CAACH,MAAQ;AAC/B,YAAMO,IAAUR,EAAOC,GAAKI,CAAI;AAChC,aAAI,CAACC,KAAc,OAAOE,KAAY,eAClCF,IAAa,KAEVE;AAAA,IACX,CAAC;AAKD,QAAIF;AACA,aAAO,MAAM;AACT,iBAAS,IAAI,GAAG,IAAIC,EAAS,QAAQ,KAAK;AACtC,gBAAMC,IAAUD,EAAS,CAAC;AAC1B,UAAI,OAAOC,KAAY,aACnBA,EAAO,IAGPR,EAAOI,EAAK,CAAC,GAAG,IAAI;AAAA,QAE5B;AAAA,MACJ;AAAA,EAER;AACJ;AAKA,SAASK,KAAmBL,GAAM;AAE9B,SAAOM,EAAM,YAAYP,EAAY,GAAGC,CAAI,GAAGA,CAAI;AACvD;AC7CA,MAAMO,UAAwBD,EAAM,UAAU;AAAA,EAC1C,wBAAwBE,GAAW;AAC/B,UAAMC,IAAU,KAAK,MAAM,SAAS;AACpC,QAAIA,KAAWD,EAAU,aAAa,CAAC,KAAK,MAAM,WAAW;AACzD,YAAME,IAASD,EAAQ,cACjBE,IAAcC,EAAcF,CAAM,KAClCA,EAAO,eAAe,GAEtBG,IAAO,KAAK,MAAM,QAAQ;AAChC,MAAAA,EAAK,SAASJ,EAAQ,gBAAgB,GACtCI,EAAK,QAAQJ,EAAQ,eAAe,GACpCI,EAAK,MAAMJ,EAAQ,WACnBI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CAAG,GAC7BiB,EAAa,IAAIjB,CAAG;AACpB,QAAAiB,EAAa,IAAIjB,GAAK,EAAI;AAAA;AAG1B;AAEJ,UAAIgC,IAAsB;AAC1B,MAAAf,EAAa,QAAQ,CAACgB,MAAmB;AACrC,QAAKA,MACDD,IAAsB;AAAA,MAC9B,CAAC,GACGA,MACAJ,IAAW,GACXL,EAAoBP,EAAuB,OAAO,GAClDP,KAAaE,IAAY,GACzBxB,KAAkBA,EAAc;AAAA,IAExC;AACA,WAAQH,EAAAA,IAAIC,GAAe,EAAE,WAAWpB,GAAW,SAAS,CAACkD,EAAgB,WAAW7B,IAC9E,SACA,IAAO,QAAQE,GAAQ,uBAAuBC,GAAuB,MAAMC,GAAM,MAAMvB,GAAM,gBAAgBF,IAAY,SAAYkE,GAAQ,SAASjE,GAAS,UAAUqC,EAAK,GAAIH,CAAG;AAAA,EACnM,CAAC,EAAC,CAAE;AACZ;","x_google_ignoreList":[0,1,2,3,4]}
1
+ {"version":3,"file":"index-Cv_5q6Rb.js","sources":["../node_modules/framer-motion/dist/es/utils/use-composed-ref.mjs","../node_modules/framer-motion/dist/es/components/AnimatePresence/PopChild.mjs","../node_modules/framer-motion/dist/es/components/AnimatePresence/PresenceChild.mjs","../node_modules/framer-motion/dist/es/components/AnimatePresence/utils.mjs","../node_modules/framer-motion/dist/es/components/AnimatePresence/index.mjs"],"sourcesContent":["import * as React from 'react';\n\n/**\n * Taken from https://github.com/radix-ui/primitives/blob/main/packages/react/compose-refs/src/compose-refs.tsx\n */\n/**\n * Set a given ref to a given value\n * This utility takes care of different types of refs: callback refs and RefObject(s)\n */\nfunction setRef(ref, value) {\n if (typeof ref === \"function\") {\n return ref(value);\n }\n else if (ref !== null && ref !== undefined) {\n ref.current = value;\n }\n}\n/**\n * A utility to compose multiple refs together\n * Accepts callback refs and RefObject(s)\n */\nfunction composeRefs(...refs) {\n return (node) => {\n let hasCleanup = false;\n const cleanups = refs.map((ref) => {\n const cleanup = setRef(ref, node);\n if (!hasCleanup && typeof cleanup === \"function\") {\n hasCleanup = true;\n }\n return cleanup;\n });\n // React <19 will log an error to the console if a callback ref returns a\n // value. We don't use ref cleanups internally so this will only happen if a\n // user's ref callback returns a value, which we only expect if they are\n // using the cleanup functionality added in React 19.\n if (hasCleanup) {\n return () => {\n for (let i = 0; i < cleanups.length; i++) {\n const cleanup = cleanups[i];\n if (typeof cleanup === \"function\") {\n cleanup();\n }\n else {\n setRef(refs[i], null);\n }\n }\n };\n }\n };\n}\n/**\n * A custom hook that composes multiple refs\n * Accepts callback refs and RefObject(s)\n */\nfunction useComposedRefs(...refs) {\n // eslint-disable-next-line react-hooks/exhaustive-deps\n return React.useCallback(composeRefs(...refs), refs);\n}\n\nexport { useComposedRefs };\n//# sourceMappingURL=use-composed-ref.mjs.map\n","\"use client\";\nimport { jsx } from 'react/jsx-runtime';\nimport { isHTMLElement } from 'motion-dom';\nimport * as React from 'react';\nimport { useId, useRef, useContext, useInsertionEffect } from 'react';\nimport { MotionConfigContext } from '../../context/MotionConfigContext.mjs';\nimport { useComposedRefs } from '../../utils/use-composed-ref.mjs';\n\n/**\n * Measurement functionality has to be within a separate component\n * to leverage snapshot lifecycle.\n */\nclass PopChildMeasure extends React.Component {\n getSnapshotBeforeUpdate(prevProps) {\n const element = this.props.childRef.current;\n if (element && prevProps.isPresent && !this.props.isPresent) {\n const parent = element.offsetParent;\n const parentWidth = isHTMLElement(parent)\n ? parent.offsetWidth || 0\n : 0;\n const size = this.props.sizeRef.current;\n size.height = element.offsetHeight || 0;\n size.width = element.offsetWidth || 0;\n size.top = element.offsetTop;\n size.left = element.offsetLeft;\n size.right = parentWidth - size.width - size.left;\n }\n return null;\n }\n /**\n * Required with getSnapshotBeforeUpdate to stop React complaining.\n */\n componentDidUpdate() { }\n render() {\n return this.props.children;\n }\n}\nfunction PopChild({ children, isPresent, anchorX, root }) {\n const id = useId();\n const ref = useRef(null);\n const size = useRef({\n width: 0,\n height: 0,\n top: 0,\n left: 0,\n right: 0,\n });\n const { nonce } = useContext(MotionConfigContext);\n /**\n * In React 19, refs are passed via props.ref instead of element.ref.\n * We check props.ref first (React 19) and fall back to element.ref (React 18).\n */\n const childRef = children.props?.ref ??\n children?.ref;\n const composedRef = useComposedRefs(ref, childRef);\n /**\n * We create and inject a style block so we can apply this explicit\n * sizing in a non-destructive manner by just deleting the style block.\n *\n * We can't apply size via render as the measurement happens\n * in getSnapshotBeforeUpdate (post-render), likewise if we apply the\n * styles directly on the DOM node, we might be overwriting\n * styles set via the style prop.\n */\n useInsertionEffect(() => {\n const { width, height, top, left, right } = size.current;\n if (isPresent || !ref.current || !width || !height)\n return;\n const x = anchorX === \"left\" ? `left: ${left}` : `right: ${right}`;\n ref.current.dataset.motionPopId = id;\n const style = document.createElement(\"style\");\n if (nonce)\n style.nonce = nonce;\n const parent = root ?? document.head;\n parent.appendChild(style);\n if (style.sheet) {\n style.sheet.insertRule(`\n [data-motion-pop-id=\"${id}\"] {\n position: absolute !important;\n width: ${width}px !important;\n height: ${height}px !important;\n ${x}px !important;\n top: ${top}px !important;\n }\n `);\n }\n return () => {\n if (parent.contains(style)) {\n parent.removeChild(style);\n }\n };\n }, [isPresent]);\n return (jsx(PopChildMeasure, { isPresent: isPresent, childRef: ref, sizeRef: size, children: React.cloneElement(children, { ref: composedRef }) }));\n}\n\nexport { PopChild };\n//# sourceMappingURL=PopChild.mjs.map\n","\"use client\";\nimport { jsx } from 'react/jsx-runtime';\nimport * as React from 'react';\nimport { useId, useMemo } from 'react';\nimport { PresenceContext } from '../../context/PresenceContext.mjs';\nimport { useConstant } from '../../utils/use-constant.mjs';\nimport { PopChild } from './PopChild.mjs';\n\nconst PresenceChild = ({ children, initial, isPresent, onExitComplete, custom, presenceAffectsLayout, mode, anchorX, root }) => {\n const presenceChildren = useConstant(newChildrenMap);\n const id = useId();\n let isReusedContext = true;\n let context = useMemo(() => {\n isReusedContext = false;\n return {\n id,\n initial,\n isPresent,\n custom,\n onExitComplete: (childId) => {\n presenceChildren.set(childId, true);\n for (const isComplete of presenceChildren.values()) {\n if (!isComplete)\n return; // can stop searching when any is incomplete\n }\n onExitComplete && onExitComplete();\n },\n register: (childId) => {\n presenceChildren.set(childId, false);\n return () => presenceChildren.delete(childId);\n },\n };\n }, [isPresent, presenceChildren, onExitComplete]);\n /**\n * If the presence of a child affects the layout of the components around it,\n * we want to make a new context value to ensure they get re-rendered\n * so they can detect that layout change.\n */\n if (presenceAffectsLayout && isReusedContext) {\n context = { ...context };\n }\n useMemo(() => {\n presenceChildren.forEach((_, key) => presenceChildren.set(key, false));\n }, [isPresent]);\n /**\n * If there's no `motion` components to fire exit animations, we want to remove this\n * component immediately.\n */\n React.useEffect(() => {\n !isPresent &&\n !presenceChildren.size &&\n onExitComplete &&\n onExitComplete();\n }, [isPresent]);\n if (mode === \"popLayout\") {\n children = (jsx(PopChild, { isPresent: isPresent, anchorX: anchorX, root: root, children: children }));\n }\n return (jsx(PresenceContext.Provider, { value: context, children: children }));\n};\nfunction newChildrenMap() {\n return new Map();\n}\n\nexport { PresenceChild };\n//# sourceMappingURL=PresenceChild.mjs.map\n","import { Children, isValidElement } from 'react';\n\nconst getChildKey = (child) => child.key || \"\";\nfunction onlyElements(children) {\n const filtered = [];\n // We use forEach here instead of map as map mutates the component key by preprending `.$`\n Children.forEach(children, (child) => {\n if (isValidElement(child))\n filtered.push(child);\n });\n return filtered;\n}\n\nexport { getChildKey, onlyElements };\n//# sourceMappingURL=utils.mjs.map\n","\"use client\";\nimport { jsx, Fragment } from 'react/jsx-runtime';\nimport { useMemo, useRef, useState, useContext } from 'react';\nimport { LayoutGroupContext } from '../../context/LayoutGroupContext.mjs';\nimport { useConstant } from '../../utils/use-constant.mjs';\nimport { useIsomorphicLayoutEffect } from '../../utils/use-isomorphic-effect.mjs';\nimport { PresenceChild } from './PresenceChild.mjs';\nimport { usePresence } from './use-presence.mjs';\nimport { onlyElements, getChildKey } from './utils.mjs';\n\n/**\n * `AnimatePresence` enables the animation of components that have been removed from the tree.\n *\n * When adding/removing more than a single child, every child **must** be given a unique `key` prop.\n *\n * Any `motion` components that have an `exit` property defined will animate out when removed from\n * the tree.\n *\n * ```jsx\n * import { motion, AnimatePresence } from 'framer-motion'\n *\n * export const Items = ({ items }) => (\n * <AnimatePresence>\n * {items.map(item => (\n * <motion.div\n * key={item.id}\n * initial={{ opacity: 0 }}\n * animate={{ opacity: 1 }}\n * exit={{ opacity: 0 }}\n * />\n * ))}\n * </AnimatePresence>\n * )\n * ```\n *\n * You can sequence exit animations throughout a tree using variants.\n *\n * If a child contains multiple `motion` components with `exit` props, it will only unmount the child\n * once all `motion` components have finished animating out. Likewise, any components using\n * `usePresence` all need to call `safeToRemove`.\n *\n * @public\n */\nconst AnimatePresence = ({ children, custom, initial = true, onExitComplete, presenceAffectsLayout = true, mode = \"sync\", propagate = false, anchorX = \"left\", root }) => {\n const [isParentPresent, safeToRemove] = usePresence(propagate);\n /**\n * Filter any children that aren't ReactElements. We can only track components\n * between renders with a props.key.\n */\n const presentChildren = useMemo(() => onlyElements(children), [children]);\n /**\n * Track the keys of the currently rendered children. This is used to\n * determine which children are exiting.\n */\n const presentKeys = propagate && !isParentPresent ? [] : presentChildren.map(getChildKey);\n /**\n * If `initial={false}` we only want to pass this to components in the first render.\n */\n const isInitialRender = useRef(true);\n /**\n * A ref containing the currently present children. When all exit animations\n * are complete, we use this to re-render the component with the latest children\n * *committed* rather than the latest children *rendered*.\n */\n const pendingPresentChildren = useRef(presentChildren);\n /**\n * Track which exiting children have finished animating out.\n */\n const exitComplete = useConstant(() => new Map());\n /**\n * Track which components are currently processing exit to prevent duplicate processing.\n */\n const exitingComponents = useRef(new Set());\n /**\n * Save children to render as React state. To ensure this component is concurrent-safe,\n * we check for exiting children via an effect.\n */\n const [diffedChildren, setDiffedChildren] = useState(presentChildren);\n const [renderedChildren, setRenderedChildren] = useState(presentChildren);\n useIsomorphicLayoutEffect(() => {\n isInitialRender.current = false;\n pendingPresentChildren.current = presentChildren;\n /**\n * Update complete status of exiting children.\n */\n for (let i = 0; i < renderedChildren.length; i++) {\n const key = getChildKey(renderedChildren[i]);\n if (!presentKeys.includes(key)) {\n if (exitComplete.get(key) !== true) {\n exitComplete.set(key, false);\n }\n }\n else {\n exitComplete.delete(key);\n exitingComponents.current.delete(key);\n }\n }\n }, [renderedChildren, presentKeys.length, presentKeys.join(\"-\")]);\n const exitingChildren = [];\n if (presentChildren !== diffedChildren) {\n let nextChildren = [...presentChildren];\n /**\n * Loop through all the currently rendered components and decide which\n * are exiting.\n */\n for (let i = 0; i < renderedChildren.length; i++) {\n const child = renderedChildren[i];\n const key = getChildKey(child);\n if (!presentKeys.includes(key)) {\n nextChildren.splice(i, 0, child);\n exitingChildren.push(child);\n }\n }\n /**\n * If we're in \"wait\" mode, and we have exiting children, we want to\n * only render these until they've all exited.\n */\n if (mode === \"wait\" && exitingChildren.length) {\n nextChildren = exitingChildren;\n }\n setRenderedChildren(onlyElements(nextChildren));\n setDiffedChildren(presentChildren);\n /**\n * Early return to ensure once we've set state with the latest diffed\n * children, we can immediately re-render.\n */\n return null;\n }\n if (process.env.NODE_ENV !== \"production\" &&\n mode === \"wait\" &&\n renderedChildren.length > 1) {\n console.warn(`You're attempting to animate multiple children within AnimatePresence, but its mode is set to \"wait\". This will lead to odd visual behaviour.`);\n }\n /**\n * If we've been provided a forceRender function by the LayoutGroupContext,\n * we can use it to force a re-render amongst all surrounding components once\n * all components have finished animating out.\n */\n const { forceRender } = useContext(LayoutGroupContext);\n return (jsx(Fragment, { children: renderedChildren.map((child) => {\n const key = getChildKey(child);\n const isPresent = propagate && !isParentPresent\n ? false\n : presentChildren === renderedChildren ||\n presentKeys.includes(key);\n const onExit = () => {\n if (exitingComponents.current.has(key)) {\n return;\n }\n exitingComponents.current.add(key);\n if (exitComplete.has(key)) {\n exitComplete.set(key, true);\n }\n else {\n return;\n }\n let isEveryExitComplete = true;\n exitComplete.forEach((isExitComplete) => {\n if (!isExitComplete)\n isEveryExitComplete = false;\n });\n if (isEveryExitComplete) {\n forceRender?.();\n setRenderedChildren(pendingPresentChildren.current);\n propagate && safeToRemove?.();\n onExitComplete && onExitComplete();\n }\n };\n return (jsx(PresenceChild, { isPresent: isPresent, initial: !isInitialRender.current || initial\n ? undefined\n : false, custom: custom, presenceAffectsLayout: presenceAffectsLayout, mode: mode, root: root, onExitComplete: isPresent ? undefined : onExit, anchorX: anchorX, children: child }, key));\n }) }));\n};\n\nexport { AnimatePresence };\n//# sourceMappingURL=index.mjs.map\n"],"names":["setRef","ref","value","composeRefs","refs","node","hasCleanup","cleanups","cleanup","useComposedRefs","React","PopChildMeasure","prevProps","element","parent","parentWidth","isHTMLElement","size","PopChild","children","isPresent","anchorX","root","id","useId","useRef","nonce","useContext","MotionConfigContext","childRef","composedRef","useInsertionEffect","width","height","top","left","right","x","style","jsx","PresenceChild","initial","onExitComplete","custom","presenceAffectsLayout","mode","presenceChildren","useConstant","newChildrenMap","isReusedContext","context","useMemo","childId","isComplete","_","key","PresenceContext","getChildKey","child","onlyElements","filtered","Children","isValidElement","AnimatePresence","propagate","isParentPresent","safeToRemove","usePresence","presentChildren","presentKeys","isInitialRender","pendingPresentChildren","exitComplete","exitingComponents","diffedChildren","setDiffedChildren","useState","renderedChildren","setRenderedChildren","useIsomorphicLayoutEffect","i","exitingChildren","nextChildren","forceRender","LayoutGroupContext","Fragment","onExit","isEveryExitComplete","isExitComplete"],"mappings":";;;;AASA,SAASA,EAAOC,GAAKC,GAAO;AACxB,MAAI,OAAOD,KAAQ;AACf,WAAOA,EAAIC,CAAK;AAEf,EAAID,KAAQ,SACbA,EAAI,UAAUC;AAEtB;AAKA,SAASC,KAAeC,GAAM;AAC1B,SAAO,CAACC,MAAS;AACb,QAAIC,IAAa;AACjB,UAAMC,IAAWH,EAAK,IAAI,CAACH,MAAQ;AAC/B,YAAMO,IAAUR,EAAOC,GAAKI,CAAI;AAChC,aAAI,CAACC,KAAc,OAAOE,KAAY,eAClCF,IAAa,KAEVE;AAAA,IACX,CAAC;AA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AG;AAAA,EACnM,CAAC,EAAC,CAAE;AACZ;","x_google_ignoreList":[0,1,2,3,4]}
@@ -1,6 +1,6 @@
1
- import { c as w, j as h } from "./index-CHPV5EwG-BCLAYDCV.js";
1
+ import { c as w, j as h } from "./index-CHPV5EwG-BzibaIRc.js";
2
2
  import { Colors as x } from "./Colors.js";
3
- import { m as u } from "./proxy--_f6k3NR.js";
3
+ import { m as u } from "./proxy-BsxtcZKa.js";
4
4
  function V(d) {
5
5
  const i = w.c(15), {
6
6
  areaSettings: m,
@@ -96,4 +96,4 @@ export {
96
96
  V as H,
97
97
  k as a
98
98
  };
99
- //# sourceMappingURL=index-D_dtv_T9.js.map
99
+ //# sourceMappingURL=index-DHVGV8Df.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index-D_dtv_T9.js","sources":["../src/Components/Elements/HighlightArea/index.tsx"],"sourcesContent":["import { NumberValue } from 'd3-scale';\r\nimport { motion } from 'motion/react';\r\n\r\nimport { Colors } from '@/Components/ColorPalette';\r\nimport { AnimateDataType } from '@/Types';\r\n\r\ninterface Props {\r\n areaSettings: {\r\n coordinates: (Date | null | number)[];\r\n style?: React.CSSProperties;\r\n className?: string;\r\n color?: string;\r\n strokeWidth?: number;\r\n }[];\r\n width: number;\r\n height: number;\r\n scale: (value: Date | NumberValue) => number;\r\n animate: AnimateDataType;\r\n isInView: boolean;\r\n}\r\n\r\nexport function HighlightArea(props: Props) {\r\n const { areaSettings, width, height, scale, animate, isInView } = props;\r\n return (\r\n <>\r\n {areaSettings.map((d, i) => (\r\n <motion.g key={i}>\r\n {d.coordinates[0] === null && d.coordinates[1] === null ? null : (\r\n <motion.g>\r\n <motion.rect\r\n style={{\r\n fill: d.color || Colors.light.grays['gray-300'],\r\n strokeWidth: d.strokeWidth,\r\n ...(d.style || {}),\r\n }}\r\n className={d.className}\r\n y={0}\r\n height={height}\r\n variants={{\r\n initial: {\r\n width: 0,\r\n x: d.coordinates[0] ? scale(d.coordinates[0]) : 0,\r\n opacity: 1,\r\n },\r\n whileInView: {\r\n width: d.coordinates[1]\r\n ? scale(d.coordinates[1]) - (d.coordinates[0] ? scale(d.coordinates[0]) : 0)\r\n : width - (d.coordinates[0] ? scale(d.coordinates[0]) : 0),\r\n x: d.coordinates[0] ? scale(d.coordinates[0]) : 0,\r\n opacity: 1,\r\n transition: { duration: animate.duration },\r\n },\r\n }}\r\n initial='initial'\r\n animate={isInView ? 'whileInView' : 'initial'}\r\n exit={{ opacity: 0, width: 0, transition: { duration: animate.duration } }}\r\n />\r\n </motion.g>\r\n )}\r\n </motion.g>\r\n ))}\r\n </>\r\n );\r\n}\r\n\r\ninterface ScatterPlotProps {\r\n areaSettings: {\r\n coordinates: (Date | null | number)[];\r\n style?: React.CSSProperties;\r\n className?: string;\r\n color?: string;\r\n strokeWidth?: number;\r\n }[];\r\n width: number;\r\n height: number;\r\n scaleX: (value: Date | NumberValue) => number;\r\n scaleY: (value: Date | NumberValue) => number;\r\n animate: AnimateDataType;\r\n isInView: boolean;\r\n}\r\n\r\nexport function HighlightAreaForScatterPlot(props: ScatterPlotProps) {\r\n const { areaSettings, width, height, scaleX, scaleY, animate, isInView } = props;\r\n return (\r\n <>\r\n {areaSettings.map((d, i) => (\r\n <motion.g key={`highlight_area_${i}`}>\r\n {d.coordinates.filter(el => el === null).length === 4 ? null : (\r\n <motion.g>\r\n <motion.rect\r\n style={{\r\n fill: d.color || Colors.light.grays['gray-300'],\r\n strokeWidth: d.strokeWidth,\r\n ...(d.style || {}),\r\n }}\r\n className={d.className}\r\n variants={{\r\n initial: {\r\n x: d.coordinates[0] ? scaleX(d.coordinates[0] as number) : 0,\r\n width: 0,\r\n y: d.coordinates[3] ? scaleY(d.coordinates[3] as number) : 0,\r\n height: 0,\r\n },\r\n whileInView: {\r\n x: d.coordinates[0] ? scaleX(d.coordinates[0] as number) : 0,\r\n width: d.coordinates[1]\r\n ? scaleX(d.coordinates[1] as number) -\r\n (d.coordinates[0] ? scaleX(d.coordinates[0] as number) : 0)\r\n : width - (d.coordinates[0] ? scaleX(d.coordinates[0] as number) : 0),\r\n y: d.coordinates[3] ? scaleY(d.coordinates[3] as number) : 0,\r\n height:\r\n d.coordinates[2] !== null\r\n ? scaleY(d.coordinates[2] as number) -\r\n (d.coordinates[3] ? scaleY(d.coordinates[3] as number) : 0)\r\n : height -\r\n (d.coordinates[3] ? height - scaleY(d.coordinates[3] as number) : 0),\r\n transition: { duration: animate.duration },\r\n },\r\n }}\r\n initial='initial'\r\n animate={isInView ? 'whileInView' : 'initial'}\r\n exit={{\r\n opacity: 0,\r\n width: 0,\r\n height: 0,\r\n transition: { duration: animate.duration },\r\n }}\r\n />\r\n </motion.g>\r\n )}\r\n </motion.g>\r\n ))}\r\n </>\r\n );\r\n}\r\n"],"names":["HighlightArea","props","$","_c","areaSettings","width","height","scale","animate","isInView","t0","t1","d","i","jsx","motion","coordinates","fill","color","Colors","light","grays","strokeWidth","style","className","initial","x","opacity","whileInView","transition","duration","map","HighlightAreaForScatterPlot","scaleX","scaleY","filter","_temp","length","y","el"],"mappings":";;;AAqBO,SAAAA,EAAAC,GAAA;AAAA,QAAAC,IAAAC,EAAAA,EAAA,EAAA,GACL;AAAA,IAAAC,cAAAA;AAAAA,IAAAC,OAAAA;AAAAA,IAAAC,QAAAA;AAAAA,IAAAC,OAAAA;AAAAA,IAAAC,SAAAA;AAAAA,IAAAC,UAAAA;AAAAA,EAAAA,IAAkER;AAAM,MAAAS;AAAA,MAAAR,SAAAM,KAAAN,EAAA,CAAA,MAAAE,KAAAF,EAAA,CAAA,MAAAI,KAAAJ,EAAA,CAAA,MAAAO,KAAAP,SAAAK,KAAAL,EAAA,CAAA,MAAAG,GAAA;AAAA,QAAAM;AAAA,IAAAT,EAAA,CAAA,MAAAM,KAAAN,EAAA,CAAA,MAAAI,KAAAJ,EAAA,CAAA,MAAAO,KAAAP,EAAA,EAAA,MAAAK,KAAAL,UAAAG,KAGlDM,IAAAA,CAAAC,GAAAC,MAChBC,gBAAAA,EAAAA,IA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AAAC,UAAYtB,EAAOsB;AAAAA,MAAAA;AAAAA,IAAU,EAC3C,CAAC,EAAA,CAEL,EAAA,GA1CW,kBAAkBjB,CAAC,EA4ClC,GACDX,OAAAM,GAAAN,OAAAI,GAAAJ,QAAAO,GAAAP,QAAA+B,GAAA/B,QAAAgC,GAAAhC,QAAAG,GAAAH,QAAAS,KAAAA,IAAAT,EAAA,EAAA,GA9CAQ,IAAAN,EAAY2B,IAAKpB,CA8CjB,GAACT,OAAAM,GAAAN,OAAAE,GAAAF,OAAAI,GAAAJ,OAAAO,GAAAP,OAAA+B,GAAA/B,OAAAgC,GAAAhC,OAAAG,GAAAH,OAAAQ;AAAAA,EAAA;AAAAA,IAAAA,IAAAR,EAAA,CAAA;AAAA,MAAAS;AAAA,SAAAT,UAAAQ,KA/CJC,wCACGD,UAAAA,EAAAA,CA8CC,GACDR,QAAAQ,GAAAR,QAAAS,KAAAA,IAAAT,EAAA,EAAA,GAhDHS;AAgDG;AAnDA,SAAAyB,EAAAG,GAAA;AAAA,SAM+BA,MAAO;AAAI;"}
1
+ {"version":3,"file":"index-DHVGV8Df.js","sources":["../src/Components/Elements/HighlightArea/index.tsx"],"sourcesContent":["import { NumberValue } from 'd3-scale';\r\nimport { motion } from 'motion/react';\r\n\r\nimport { Colors } from '@/Components/ColorPalette';\r\nimport { AnimateDataType } from '@/Types';\r\n\r\ninterface Props {\r\n areaSettings: {\r\n coordinates: (Date | null | number)[];\r\n style?: React.CSSProperties;\r\n className?: string;\r\n color?: string;\r\n strokeWidth?: number;\r\n }[];\r\n width: number;\r\n height: number;\r\n scale: (value: Date | NumberValue) => number;\r\n animate: AnimateDataType;\r\n isInView: boolean;\r\n}\r\n\r\nexport function HighlightArea(props: Props) {\r\n const { areaSettings, width, height, scale, animate, isInView } = props;\r\n return (\r\n <>\r\n {areaSettings.map((d, i) => (\r\n <motion.g key={i}>\r\n {d.coordinates[0] === null && d.coordinates[1] === null ? null : (\r\n <motion.g>\r\n <motion.rect\r\n style={{\r\n fill: d.color || Colors.light.grays['gray-300'],\r\n strokeWidth: d.strokeWidth,\r\n ...(d.style || {}),\r\n }}\r\n className={d.className}\r\n y={0}\r\n height={height}\r\n variants={{\r\n initial: {\r\n width: 0,\r\n x: d.coordinates[0] ? scale(d.coordinates[0]) : 0,\r\n opacity: 1,\r\n },\r\n whileInView: {\r\n width: d.coordinates[1]\r\n ? scale(d.coordinates[1]) - (d.coordinates[0] ? scale(d.coordinates[0]) : 0)\r\n : width - (d.coordinates[0] ? scale(d.coordinates[0]) : 0),\r\n x: d.coordinates[0] ? scale(d.coordinates[0]) : 0,\r\n opacity: 1,\r\n transition: { duration: animate.duration },\r\n },\r\n }}\r\n initial='initial'\r\n animate={isInView ? 'whileInView' : 'initial'}\r\n exit={{ opacity: 0, width: 0, transition: { duration: animate.duration } }}\r\n />\r\n </motion.g>\r\n )}\r\n </motion.g>\r\n ))}\r\n </>\r\n );\r\n}\r\n\r\ninterface ScatterPlotProps {\r\n areaSettings: {\r\n coordinates: (Date | null | number)[];\r\n style?: React.CSSProperties;\r\n className?: string;\r\n color?: string;\r\n strokeWidth?: number;\r\n }[];\r\n width: number;\r\n height: number;\r\n scaleX: (value: Date | NumberValue) => number;\r\n scaleY: (value: Date | NumberValue) => number;\r\n animate: AnimateDataType;\r\n isInView: boolean;\r\n}\r\n\r\nexport function HighlightAreaForScatterPlot(props: ScatterPlotProps) {\r\n const { areaSettings, width, height, scaleX, scaleY, animate, isInView } = props;\r\n return (\r\n <>\r\n {areaSettings.map((d, i) => (\r\n <motion.g key={`highlight_area_${i}`}>\r\n {d.coordinates.filter(el => el === null).length === 4 ? null : (\r\n <motion.g>\r\n <motion.rect\r\n style={{\r\n fill: d.color || Colors.light.grays['gray-300'],\r\n strokeWidth: d.strokeWidth,\r\n ...(d.style || {}),\r\n }}\r\n className={d.className}\r\n variants={{\r\n initial: {\r\n x: d.coordinates[0] ? scaleX(d.coordinates[0] as number) : 0,\r\n width: 0,\r\n y: d.coordinates[3] ? scaleY(d.coordinates[3] as number) : 0,\r\n height: 0,\r\n },\r\n whileInView: {\r\n x: d.coordinates[0] ? scaleX(d.coordinates[0] as number) : 0,\r\n width: d.coordinates[1]\r\n ? scaleX(d.coordinates[1] as number) -\r\n (d.coordinates[0] ? scaleX(d.coordinates[0] as number) : 0)\r\n : width - (d.coordinates[0] ? scaleX(d.coordinates[0] as number) : 0),\r\n y: d.coordinates[3] ? scaleY(d.coordinates[3] as number) : 0,\r\n height:\r\n d.coordinates[2] !== null\r\n ? scaleY(d.coordinates[2] as number) -\r\n (d.coordinates[3] ? scaleY(d.coordinates[3] as number) : 0)\r\n : height -\r\n (d.coordinates[3] ? height - scaleY(d.coordinates[3] as number) : 0),\r\n transition: { duration: animate.duration },\r\n },\r\n }}\r\n initial='initial'\r\n animate={isInView ? 'whileInView' : 'initial'}\r\n exit={{\r\n opacity: 0,\r\n width: 0,\r\n height: 0,\r\n transition: { duration: animate.duration },\r\n }}\r\n />\r\n </motion.g>\r\n )}\r\n </motion.g>\r\n ))}\r\n </>\r\n );\r\n}\r\n"],"names":["HighlightArea","props","$","_c","areaSettings","width","height","scale","animate","isInView","t0","t1","d","i","jsx","motion","coordinates","fill","color","Colors","light","grays","strokeWidth","style","className","initial","x","opacity","whileInView","transition","duration","map","HighlightAreaForScatterPlot","scaleX","scaleY","filter","_temp","length","y","el"],"mappings":";;;AAqBO,SAAAA,EAAAC,GAAA;AAAA,QAAAC,IAAAC,EAAAA,EAAA,EAAA,GACL;AAAA,IAAAC,cAAAA;AAAAA,IAAAC,OAAAA;AAAAA,IAAAC,QAAAA;AAAAA,IAAAC,OAAAA;AAAAA,IAAAC,SAAAA;AAAAA,IAAAC,UAAAA;AAAAA,EAAAA,IAAkER;AAAM,MAAAS;AAAA,MAAAR,SAAAM,KAAAN,EAAA,CAAA,MAAAE,KAAAF,EAAA,CAAA,MAAAI,KAAAJ,EAAA,CAAA,MAAAO,KAAAP,SAAAK,KAAAL,EAAA,CAAA,MAAAG,GAAA;AA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,UAAAC,UAAYtB,EAAOsB;AAAAA,QAAAA;AAAAA,MAAU;AAAA,IAC3C,GAEM,SAAA,WACC,SAAArB,IAAA,gBAAA,WACH,MAAA;AAAA,MAAAkB,SACK;AAAA,MAACtB,OACH;AAAA,MAACC,QACA;AAAA,MAACuB,YACG;AAAA,QAAAC,UAAYtB,EAAOsB;AAAAA,MAAAA;AAAAA,IAAU,EAC3C,CAAC,EAAA,CAEL,EAAA,GA1CW,kBAAkBjB,CAAC,EA4ClC,GACDX,OAAAM,GAAAN,OAAAI,GAAAJ,QAAAO,GAAAP,QAAA+B,GAAA/B,QAAAgC,GAAAhC,QAAAG,GAAAH,QAAAS,KAAAA,IAAAT,EAAA,EAAA,GA9CAQ,IAAAN,EAAY2B,IAAKpB,CA8CjB,GAACT,OAAAM,GAAAN,OAAAE,GAAAF,OAAAI,GAAAJ,OAAAO,GAAAP,OAAA+B,GAAA/B,OAAAgC,GAAAhC,OAAAG,GAAAH,OAAAQ;AAAAA,EAAA;AAAAA,IAAAA,IAAAR,EAAA,CAAA;AAAA,MAAAS;AAAA,SAAAT,UAAAQ,KA/CJC,wCACGD,UAAAA,EAAAA,CA8CC,GACDR,QAAAQ,GAAAR,QAAAS,KAAAA,IAAAT,EAAA,EAAA,GAhDHS;AAgDG;AAnDA,SAAAyB,EAAAG,GAAA;AAAA,SAM+BA,MAAO;AAAI;"}
@@ -1,4 +1,4 @@
1
- "use strict";const w=require("./index-CHPV5EwG-6v2a2njQ.cjs"),o=require("react"),g=require("./proxy-C4-uo6nS.cjs");function T(e){const s=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const t in e)if(t!=="default"){const r=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(s,t,r.get?r:{enumerable:!0,get:()=>e[t]})}}return s.default=e,Object.freeze(s)}const M=T(o);function L(e,s){if(typeof e=="function")return e(s);e!=null&&(e.current=s)}function _(...e){return s=>{let t=!1;const r=e.map(u=>{const n=L(u,s);return!t&&typeof n=="function"&&(t=!0),n});if(t)return()=>{for(let u=0;u<r.length;u++){const n=r[u];typeof n=="function"?n():L(e[u],null)}}}}function A(...e){return M.useCallback(_(...e),e)}class q extends M.Component{getSnapshotBeforeUpdate(s){const t=this.props.childRef.current;if(t&&s.isPresent&&!this.props.isPresent){const r=t.offsetParent,u=g.isHTMLElement(r)&&r.offsetWidth||0,n=this.props.sizeRef.current;n.height=t.offsetHeight||0,n.width=t.offsetWidth||0,n.top=t.offsetTop,n.left=t.offsetLeft,n.right=u-n.width-n.left}return null}componentDidUpdate(){}render(){return this.props.children}}function H({children:e,isPresent:s,anchorX:t,root:r}){const u=o.useId(),n=o.useRef(null),h=o.useRef({width:0,height:0,top:0,left:0,right:0}),{nonce:R}=o.useContext(g.MotionConfigContext),j=e.props?.ref??e?.ref,f=A(n,j);return o.useInsertionEffect(()=>{const{width:y,height:c,top:l,left:a,right:m}=h.current;if(s||!n.current||!y||!c)return;const x=t==="left"?`left: ${a}`:`right: ${m}`;n.current.dataset.motionPopId=u;const d=document.createElement("style");R&&(d.nonce=R);const P=r??document.head;return P.appendChild(d),d.sheet&&d.sheet.insertRule(`
1
+ "use strict";const w=require("./index-CHPV5EwG-D4pAp7u0.cjs"),o=require("react"),g=require("./proxy-CqH8m8IQ.cjs");function T(e){const s=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const t in e)if(t!=="default"){const r=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(s,t,r.get?r:{enumerable:!0,get:()=>e[t]})}}return s.default=e,Object.freeze(s)}const M=T(o);function L(e,s){if(typeof e=="function")return e(s);e!=null&&(e.current=s)}function _(...e){return s=>{let t=!1;const r=e.map(u=>{const n=L(u,s);return!t&&typeof n=="function"&&(t=!0),n});if(t)return()=>{for(let u=0;u<r.length;u++){const n=r[u];typeof n=="function"?n():L(e[u],null)}}}}function A(...e){return M.useCallback(_(...e),e)}class q extends M.Component{getSnapshotBeforeUpdate(s){const t=this.props.childRef.current;if(t&&s.isPresent&&!this.props.isPresent){const r=t.offsetParent,u=g.isHTMLElement(r)&&r.offsetWidth||0,n=this.props.sizeRef.current;n.height=t.offsetHeight||0,n.width=t.offsetWidth||0,n.top=t.offsetTop,n.left=t.offsetLeft,n.right=u-n.width-n.left}return null}componentDidUpdate(){}render(){return this.props.children}}function H({children:e,isPresent:s,anchorX:t,root:r}){const u=o.useId(),n=o.useRef(null),h=o.useRef({width:0,height:0,top:0,left:0,right:0}),{nonce:R}=o.useContext(g.MotionConfigContext),j=e.props?.ref??e?.ref,f=A(n,j);return o.useInsertionEffect(()=>{const{width:y,height:c,top:l,left:a,right:m}=h.current;if(s||!n.current||!y||!c)return;const x=t==="left"?`left: ${a}`:`right: ${m}`;n.current.dataset.motionPopId=u;const d=document.createElement("style");R&&(d.nonce=R);const P=r??document.head;return P.appendChild(d),d.sheet&&d.sheet.insertRule(`
2
2
  [data-motion-pop-id="${u}"] {
3
3
  position: absolute !important;
4
4
  width: ${y}px !important;
@@ -7,4 +7,4 @@
7
7
  top: ${l}px !important;
8
8
  }
9
9
  `),()=>{P.contains(d)&&P.removeChild(d)}},[s]),w.jsxRuntimeExports.jsx(q,{isPresent:s,childRef:n,sizeRef:h,children:M.cloneElement(e,{ref:f})})}const N=({children:e,initial:s,isPresent:t,onExitComplete:r,custom:u,presenceAffectsLayout:n,mode:h,anchorX:R,root:j})=>{const f=g.useConstant(V),y=o.useId();let c=!0,l=o.useMemo(()=>(c=!1,{id:y,initial:s,isPresent:t,custom:u,onExitComplete:a=>{f.set(a,!0);for(const m of f.values())if(!m)return;r&&r()},register:a=>(f.set(a,!1),()=>f.delete(a))}),[t,f,r]);return n&&c&&(l={...l}),o.useMemo(()=>{f.forEach((a,m)=>f.set(m,!1))},[t]),M.useEffect(()=>{!t&&!f.size&&r&&r()},[t]),h==="popLayout"&&(e=w.jsxRuntimeExports.jsx(H,{isPresent:t,anchorX:R,root:j,children:e})),w.jsxRuntimeExports.jsx(g.PresenceContext.Provider,{value:l,children:e})};function V(){return new Map}const b=e=>e.key||"";function O(e){const s=[];return o.Children.forEach(e,t=>{o.isValidElement(t)&&s.push(t)}),s}const W=({children:e,custom:s,initial:t=!0,onExitComplete:r,presenceAffectsLayout:u=!0,mode:n="sync",propagate:h=!1,anchorX:R="left",root:j})=>{const[f,y]=g.usePresence(h),c=o.useMemo(()=>O(e),[e]),l=h&&!f?[]:c.map(b),a=o.useRef(!0),m=o.useRef(c),x=g.useConstant(()=>new Map),d=o.useRef(new Set),[P,S]=o.useState(c),[C,k]=o.useState(c);g.useIsomorphicLayoutEffect(()=>{a.current=!1,m.current=c;for(let p=0;p<C.length;p++){const i=b(C[p]);l.includes(i)?(x.delete(i),d.current.delete(i)):x.get(i)!==!0&&x.set(i,!1)}},[C,l.length,l.join("-")]);const v=[];if(c!==P){let p=[...c];for(let i=0;i<C.length;i++){const E=C[i],$=b(E);l.includes($)||(p.splice(i,0,E),v.push(E))}return n==="wait"&&v.length&&(p=v),k(O(p)),S(c),null}process.env.NODE_ENV!=="production"&&n==="wait"&&C.length>1&&console.warn(`You're attempting to animate multiple children within AnimatePresence, but its mode is set to "wait". This will lead to odd visual behaviour.`);const{forceRender:D}=o.useContext(g.LayoutGroupContext);return w.jsxRuntimeExports.jsx(w.jsxRuntimeExports.Fragment,{children:C.map(p=>{const i=b(p),E=h&&!f?!1:c===C||l.includes(i),$=()=>{if(d.current.has(i))return;if(d.current.add(i),x.has(i))x.set(i,!0);else return;let z=!0;x.forEach(I=>{I||(z=!1)}),z&&(D?.(),k(m.current),h&&y?.(),r&&r())};return w.jsxRuntimeExports.jsx(N,{isPresent:E,initial:!a.current||t?void 0:!1,custom:s,presenceAffectsLayout:u,mode:n,root:j,onExitComplete:E?void 0:$,anchorX:R,children:p},i)})})};exports.AnimatePresence=W;
10
- //# sourceMappingURL=index-CoobIWNj.cjs.map
10
+ //# sourceMappingURL=index-FXfr51ZM.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"index-CoobIWNj.cjs","sources":["../node_modules/framer-motion/dist/es/utils/use-composed-ref.mjs","../node_modules/framer-motion/dist/es/components/AnimatePresence/PopChild.mjs","../node_modules/framer-motion/dist/es/components/AnimatePresence/PresenceChild.mjs","../node_modules/framer-motion/dist/es/components/AnimatePresence/utils.mjs","../node_modules/framer-motion/dist/es/components/AnimatePresence/index.mjs"],"sourcesContent":["import * as React from 'react';\n\n/**\n * Taken from https://github.com/radix-ui/primitives/blob/main/packages/react/compose-refs/src/compose-refs.tsx\n */\n/**\n * Set a given ref to a given value\n * This utility takes care of different types of refs: callback refs and RefObject(s)\n */\nfunction setRef(ref, value) {\n if (typeof ref === \"function\") {\n return ref(value);\n }\n else if (ref !== null && ref !== undefined) {\n ref.current = value;\n }\n}\n/**\n * A utility to compose multiple refs together\n * Accepts callback refs and RefObject(s)\n */\nfunction composeRefs(...refs) {\n return (node) => {\n let hasCleanup = false;\n const cleanups = refs.map((ref) => {\n const cleanup = setRef(ref, node);\n if (!hasCleanup && typeof cleanup === \"function\") {\n hasCleanup = true;\n }\n return cleanup;\n });\n // React <19 will log an error to the console if a callback ref returns a\n // value. We don't use ref cleanups internally so this will only happen if a\n // user's ref callback returns a value, which we only expect if they are\n // using the cleanup functionality added in React 19.\n if (hasCleanup) {\n return () => {\n for (let i = 0; i < cleanups.length; i++) {\n const cleanup = cleanups[i];\n if (typeof cleanup === \"function\") {\n cleanup();\n }\n else {\n setRef(refs[i], null);\n }\n }\n };\n }\n };\n}\n/**\n * A custom hook that composes multiple refs\n * Accepts callback refs and RefObject(s)\n */\nfunction useComposedRefs(...refs) {\n // eslint-disable-next-line react-hooks/exhaustive-deps\n return React.useCallback(composeRefs(...refs), refs);\n}\n\nexport { useComposedRefs };\n//# sourceMappingURL=use-composed-ref.mjs.map\n","\"use client\";\nimport { jsx } from 'react/jsx-runtime';\nimport { isHTMLElement } from 'motion-dom';\nimport * as React from 'react';\nimport { useId, useRef, useContext, useInsertionEffect } from 'react';\nimport { MotionConfigContext } from '../../context/MotionConfigContext.mjs';\nimport { useComposedRefs } from '../../utils/use-composed-ref.mjs';\n\n/**\n * Measurement functionality has to be within a separate component\n * to leverage snapshot lifecycle.\n */\nclass PopChildMeasure extends React.Component {\n getSnapshotBeforeUpdate(prevProps) {\n const element = this.props.childRef.current;\n if (element && prevProps.isPresent && !this.props.isPresent) {\n const parent = element.offsetParent;\n const parentWidth = isHTMLElement(parent)\n ? parent.offsetWidth || 0\n : 0;\n const size = this.props.sizeRef.current;\n size.height = element.offsetHeight || 0;\n size.width = element.offsetWidth || 0;\n size.top = element.offsetTop;\n size.left = element.offsetLeft;\n size.right = parentWidth - size.width - size.left;\n }\n return null;\n }\n /**\n * Required with getSnapshotBeforeUpdate to stop React complaining.\n */\n componentDidUpdate() { }\n render() {\n return this.props.children;\n }\n}\nfunction PopChild({ children, isPresent, anchorX, root }) {\n const id = useId();\n const ref = useRef(null);\n const size = useRef({\n width: 0,\n height: 0,\n top: 0,\n left: 0,\n right: 0,\n });\n const { nonce } = useContext(MotionConfigContext);\n /**\n * In React 19, refs are passed via props.ref instead of element.ref.\n * We check props.ref first (React 19) and fall back to element.ref (React 18).\n */\n const childRef = children.props?.ref ??\n children?.ref;\n const composedRef = useComposedRefs(ref, childRef);\n /**\n * We create and inject a style block so we can apply this explicit\n * sizing in a non-destructive manner by just deleting the style block.\n *\n * We can't apply size via render as the measurement happens\n * in getSnapshotBeforeUpdate (post-render), likewise if we apply the\n * styles directly on the DOM node, we might be overwriting\n * styles set via the style prop.\n */\n useInsertionEffect(() => {\n const { width, height, top, left, right } = size.current;\n if (isPresent || !ref.current || !width || !height)\n return;\n const x = anchorX === \"left\" ? `left: ${left}` : `right: ${right}`;\n ref.current.dataset.motionPopId = id;\n const style = document.createElement(\"style\");\n if (nonce)\n style.nonce = nonce;\n const parent = root ?? document.head;\n parent.appendChild(style);\n if (style.sheet) {\n style.sheet.insertRule(`\n [data-motion-pop-id=\"${id}\"] {\n position: absolute !important;\n width: ${width}px !important;\n height: ${height}px !important;\n ${x}px !important;\n top: ${top}px !important;\n }\n `);\n }\n return () => {\n if (parent.contains(style)) {\n parent.removeChild(style);\n }\n };\n }, [isPresent]);\n return (jsx(PopChildMeasure, { isPresent: isPresent, childRef: ref, sizeRef: size, children: React.cloneElement(children, { ref: composedRef }) }));\n}\n\nexport { PopChild };\n//# sourceMappingURL=PopChild.mjs.map\n","\"use client\";\nimport { jsx } from 'react/jsx-runtime';\nimport * as React from 'react';\nimport { useId, useMemo } from 'react';\nimport { PresenceContext } from '../../context/PresenceContext.mjs';\nimport { useConstant } from '../../utils/use-constant.mjs';\nimport { PopChild } from './PopChild.mjs';\n\nconst PresenceChild = ({ children, initial, isPresent, onExitComplete, custom, presenceAffectsLayout, mode, anchorX, root }) => {\n const presenceChildren = useConstant(newChildrenMap);\n const id = useId();\n let isReusedContext = true;\n let context = useMemo(() => {\n isReusedContext = false;\n return {\n id,\n initial,\n isPresent,\n custom,\n onExitComplete: (childId) => {\n presenceChildren.set(childId, true);\n for (const isComplete of presenceChildren.values()) {\n if (!isComplete)\n return; // can stop searching when any is incomplete\n }\n onExitComplete && onExitComplete();\n },\n register: (childId) => {\n presenceChildren.set(childId, false);\n return () => presenceChildren.delete(childId);\n },\n };\n }, [isPresent, presenceChildren, onExitComplete]);\n /**\n * If the presence of a child affects the layout of the components around it,\n * we want to make a new context value to ensure they get re-rendered\n * so they can detect that layout change.\n */\n if (presenceAffectsLayout && isReusedContext) {\n context = { ...context };\n }\n useMemo(() => {\n presenceChildren.forEach((_, key) => presenceChildren.set(key, false));\n }, [isPresent]);\n /**\n * If there's no `motion` components to fire exit animations, we want to remove this\n * component immediately.\n */\n React.useEffect(() => {\n !isPresent &&\n !presenceChildren.size &&\n onExitComplete &&\n onExitComplete();\n }, [isPresent]);\n if (mode === \"popLayout\") {\n children = (jsx(PopChild, { isPresent: isPresent, anchorX: anchorX, root: root, children: children }));\n }\n return (jsx(PresenceContext.Provider, { value: context, children: children }));\n};\nfunction newChildrenMap() {\n return new Map();\n}\n\nexport { PresenceChild };\n//# sourceMappingURL=PresenceChild.mjs.map\n","import { Children, isValidElement } from 'react';\n\nconst getChildKey = (child) => child.key || \"\";\nfunction onlyElements(children) {\n const filtered = [];\n // We use forEach here instead of map as map mutates the component key by preprending `.$`\n Children.forEach(children, (child) => {\n if (isValidElement(child))\n filtered.push(child);\n });\n return filtered;\n}\n\nexport { getChildKey, onlyElements };\n//# sourceMappingURL=utils.mjs.map\n","\"use client\";\nimport { jsx, Fragment } from 'react/jsx-runtime';\nimport { useMemo, useRef, useState, useContext } from 'react';\nimport { LayoutGroupContext } from '../../context/LayoutGroupContext.mjs';\nimport { useConstant } from '../../utils/use-constant.mjs';\nimport { useIsomorphicLayoutEffect } from '../../utils/use-isomorphic-effect.mjs';\nimport { PresenceChild } from './PresenceChild.mjs';\nimport { usePresence } from './use-presence.mjs';\nimport { onlyElements, getChildKey } from './utils.mjs';\n\n/**\n * `AnimatePresence` enables the animation of components that have been removed from the tree.\n *\n * When adding/removing more than a single child, every child **must** be given a unique `key` prop.\n *\n * Any `motion` components that have an `exit` property defined will animate out when removed from\n * the tree.\n *\n * ```jsx\n * import { motion, AnimatePresence } from 'framer-motion'\n *\n * export const Items = ({ items }) => (\n * <AnimatePresence>\n * {items.map(item => (\n * <motion.div\n * key={item.id}\n * initial={{ opacity: 0 }}\n * animate={{ opacity: 1 }}\n * exit={{ opacity: 0 }}\n * />\n * ))}\n * </AnimatePresence>\n * )\n * ```\n *\n * You can sequence exit animations throughout a tree using variants.\n *\n * If a child contains multiple `motion` components with `exit` props, it will only unmount the child\n * once all `motion` components have finished animating out. Likewise, any components using\n * `usePresence` all need to call `safeToRemove`.\n *\n * @public\n */\nconst AnimatePresence = ({ children, custom, initial = true, onExitComplete, presenceAffectsLayout = true, mode = \"sync\", propagate = false, anchorX = \"left\", root }) => {\n const [isParentPresent, safeToRemove] = usePresence(propagate);\n /**\n * Filter any children that aren't ReactElements. We can only track components\n * between renders with a props.key.\n */\n const presentChildren = useMemo(() => onlyElements(children), [children]);\n /**\n * Track the keys of the currently rendered children. This is used to\n * determine which children are exiting.\n */\n const presentKeys = propagate && !isParentPresent ? [] : presentChildren.map(getChildKey);\n /**\n * If `initial={false}` we only want to pass this to components in the first render.\n */\n const isInitialRender = useRef(true);\n /**\n * A ref containing the currently present children. When all exit animations\n * are complete, we use this to re-render the component with the latest children\n * *committed* rather than the latest children *rendered*.\n */\n const pendingPresentChildren = useRef(presentChildren);\n /**\n * Track which exiting children have finished animating out.\n */\n const exitComplete = useConstant(() => new Map());\n /**\n * Track which components are currently processing exit to prevent duplicate processing.\n */\n const exitingComponents = useRef(new Set());\n /**\n * Save children to render as React state. To ensure this component is concurrent-safe,\n * we check for exiting children via an effect.\n */\n const [diffedChildren, setDiffedChildren] = useState(presentChildren);\n const [renderedChildren, setRenderedChildren] = useState(presentChildren);\n useIsomorphicLayoutEffect(() => {\n isInitialRender.current = false;\n pendingPresentChildren.current = presentChildren;\n /**\n * Update complete status of exiting children.\n */\n for (let i = 0; i < renderedChildren.length; i++) {\n const key = getChildKey(renderedChildren[i]);\n if (!presentKeys.includes(key)) {\n if (exitComplete.get(key) !== true) {\n exitComplete.set(key, false);\n }\n }\n else {\n exitComplete.delete(key);\n exitingComponents.current.delete(key);\n }\n }\n }, [renderedChildren, presentKeys.length, presentKeys.join(\"-\")]);\n const exitingChildren = [];\n if (presentChildren !== diffedChildren) {\n let nextChildren = [...presentChildren];\n /**\n * Loop through all the currently rendered components and decide which\n * are exiting.\n */\n for (let i = 0; i < renderedChildren.length; i++) {\n const child = renderedChildren[i];\n const key = getChildKey(child);\n if (!presentKeys.includes(key)) {\n nextChildren.splice(i, 0, child);\n exitingChildren.push(child);\n }\n }\n /**\n * If we're in \"wait\" mode, and we have exiting children, we want to\n * only render these until they've all exited.\n */\n if (mode === \"wait\" && exitingChildren.length) {\n nextChildren = exitingChildren;\n }\n setRenderedChildren(onlyElements(nextChildren));\n setDiffedChildren(presentChildren);\n /**\n * Early return to ensure once we've set state with the latest diffed\n * children, we can immediately re-render.\n */\n return null;\n }\n if (process.env.NODE_ENV !== \"production\" &&\n mode === \"wait\" &&\n renderedChildren.length > 1) {\n console.warn(`You're attempting to animate multiple children within AnimatePresence, but its mode is set to \"wait\". This will lead to odd visual behaviour.`);\n }\n /**\n * If we've been provided a forceRender function by the LayoutGroupContext,\n * we can use it to force a re-render amongst all surrounding components once\n * all components have finished animating out.\n */\n const { forceRender } = useContext(LayoutGroupContext);\n return (jsx(Fragment, { children: renderedChildren.map((child) => {\n const key = getChildKey(child);\n const isPresent = propagate && !isParentPresent\n ? false\n : presentChildren === renderedChildren ||\n presentKeys.includes(key);\n const onExit = () => {\n if (exitingComponents.current.has(key)) {\n return;\n }\n exitingComponents.current.add(key);\n if (exitComplete.has(key)) {\n exitComplete.set(key, true);\n }\n else {\n return;\n }\n let isEveryExitComplete = true;\n exitComplete.forEach((isExitComplete) => {\n if (!isExitComplete)\n isEveryExitComplete = false;\n });\n if (isEveryExitComplete) {\n forceRender?.();\n setRenderedChildren(pendingPresentChildren.current);\n propagate && safeToRemove?.();\n onExitComplete && onExitComplete();\n }\n };\n return (jsx(PresenceChild, { isPresent: isPresent, initial: !isInitialRender.current || initial\n ? undefined\n : false, custom: custom, presenceAffectsLayout: presenceAffectsLayout, mode: mode, root: root, onExitComplete: isPresent ? undefined : onExit, anchorX: anchorX, children: child }, key));\n }) }));\n};\n\nexport { AnimatePresence };\n//# sourceMappingURL=index.mjs.map\n"],"names":["setRef","ref","value","composeRefs","refs","node","hasCleanup","cleanups","cleanup","i","useComposedRefs","React","PopChildMeasure","prevProps","element","parent","parentWidth","isHTMLElement","size","PopChild","children","isPresent","anchorX","root","id","useId","useRef","nonce","useContext","MotionConfigContext","childRef","composedRef","useInsertionEffect","width","height","top","left","right","style","jsx","PresenceChild","initial","onExitComplete","custom","presenceAffectsLayout","mode","presenceChildren","useConstant","newChildrenMap","isReusedContext","context","useMemo","childId","isComplete","_","key","PresenceContext","getChildKey","child","onlyElements","filtered","Children","isValidElement","AnimatePresence","propagate","isParentPresent","safeToRemove","usePresence","presentChildren","presentKeys","isInitialRender","pendingPresentChildren","exitComplete","exitingComponents","diffedChildren","setDiffedChildren","useState","renderedChildren","setRenderedChildren","useIsomorphicLayoutEffect","exitingChildren","nextChildren","forceRender","LayoutGroupContext","Fragment","onExit","isEveryExitComplete","isExitComplete"],"mappings":"6YASA,SAASA,EAAOC,EAAKC,EAAO,CACxB,GAAI,OAAOD,GAAQ,WACf,OAAOA,EAAIC,CAAK,EAEXD,GAAQ,OACbA,EAAI,QAAUC,EAEtB,CAKA,SAASC,KAAeC,EAAM,CAC1B,OAAQC,GAAS,CACb,IAAIC,EAAa,GACjB,MAAMC,EAAWH,EAAK,IAAKH,GAAQ,CAC/B,MAAMO,EAAUR,EAAOC,EAAKI,CAAI,EAChC,MAAI,CAACC,GAAc,OAAOE,GAAY,aAClCF,EAAa,IAEVE,CACX,CAAC,EAKD,GAAIF,EACA,MAAO,IAAM,CACT,QAASG,EAAI,EAAGA,EAAIF,EAAS,OAAQE,IAAK,CACtC,MAAMD,EAAUD,EAASE,CAAC,EACtB,OAAOD,GAAY,WACnBA,EAAO,EAGPR,EAAOI,EAAKK,CAAC,EAAG,IAAI,CAE5B,CACJ,CAER,CACJ,CAKA,SAASC,KAAmBN,EAAM,CAE9B,OAAOO,EAAM,YAAYR,EAAY,GAAGC,CAAI,EAAGA,CAAI,CACvD,CC7CA,MAAMQ,UAAwBD,EAAM,SAAU,CAC1C,wBAAwBE,EAAW,CAC/B,MAAMC,EAAU,KAAK,MAAM,SAAS,QACpC,GAAIA,GAAWD,EAAU,WAAa,CAAC,KAAK,MAAM,UAAW,CACzD,MAAME,EAASD,EAAQ,aACjBE,EAAcC,EAAAA,cAAcF,CAAM,GAClCA,EAAO,aAAe,EAEtBG,EAAO,KAAK,MAAM,QAAQ,QAChCA,EAAK,OAASJ,EAAQ,cAAgB,EACtCI,EAAK,MAAQJ,EAAQ,aAAe,EACpCI,EAAK,IAAMJ,EAAQ,UACnBI,EA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Aa,QAASe,GAAmB,CAChCA,IACDD,EAAsB,GAC9B,CAAC,EACGA,IACAJ,IAAW,EACXJ,EAAoBP,EAAuB,OAAO,EAClDP,GAAaE,IAAY,EACzBxB,GAAkBA,EAAc,EAExC,EACA,OAAQH,EAAAA,kBAAAA,IAAIC,EAAe,CAAE,UAAWnB,EAAW,QAAS,CAACiD,EAAgB,SAAW7B,EAC9E,OACA,GAAO,OAAQE,EAAQ,sBAAuBC,EAAuB,KAAMC,EAAM,KAAMtB,EAAM,eAAgBF,EAAY,OAAYgE,EAAQ,QAAS/D,EAAS,SAAUoC,CAAK,EAAIH,CAAG,CACnM,CAAC,CAAC,CAAE,CACZ","x_google_ignoreList":[0,1,2,3,4]}
1
+ {"version":3,"file":"index-FXfr51ZM.cjs","sources":["../node_modules/framer-motion/dist/es/utils/use-composed-ref.mjs","../node_modules/framer-motion/dist/es/components/AnimatePresence/PopChild.mjs","../node_modules/framer-motion/dist/es/components/AnimatePresence/PresenceChild.mjs","../node_modules/framer-motion/dist/es/components/AnimatePresence/utils.mjs","../node_modules/framer-motion/dist/es/components/AnimatePresence/index.mjs"],"sourcesContent":["import * as React from 'react';\n\n/**\n * Taken from https://github.com/radix-ui/primitives/blob/main/packages/react/compose-refs/src/compose-refs.tsx\n */\n/**\n * Set a given ref to a given value\n * This utility takes care of different types of refs: callback refs and RefObject(s)\n */\nfunction setRef(ref, value) {\n if (typeof ref === \"function\") {\n return ref(value);\n }\n else if (ref !== null && ref !== undefined) {\n ref.current = value;\n }\n}\n/**\n * A utility to compose multiple refs together\n * Accepts callback refs and RefObject(s)\n */\nfunction composeRefs(...refs) {\n return (node) => {\n let hasCleanup = false;\n const cleanups = refs.map((ref) => {\n const cleanup = setRef(ref, node);\n if (!hasCleanup && typeof cleanup === \"function\") {\n hasCleanup = true;\n }\n return cleanup;\n });\n // React <19 will log an error to the console if a callback ref returns a\n // value. We don't use ref cleanups internally so this will only happen if a\n // user's ref callback returns a value, which we only expect if they are\n // using the cleanup functionality added in React 19.\n if (hasCleanup) {\n return () => {\n for (let i = 0; i < cleanups.length; i++) {\n const cleanup = cleanups[i];\n if (typeof cleanup === \"function\") {\n cleanup();\n }\n else {\n setRef(refs[i], null);\n }\n }\n };\n }\n };\n}\n/**\n * A custom hook that composes multiple refs\n * Accepts callback refs and RefObject(s)\n */\nfunction useComposedRefs(...refs) {\n // eslint-disable-next-line react-hooks/exhaustive-deps\n return React.useCallback(composeRefs(...refs), refs);\n}\n\nexport { useComposedRefs };\n//# sourceMappingURL=use-composed-ref.mjs.map\n","\"use client\";\nimport { jsx } from 'react/jsx-runtime';\nimport { isHTMLElement } from 'motion-dom';\nimport * as React from 'react';\nimport { useId, useRef, useContext, useInsertionEffect } from 'react';\nimport { MotionConfigContext } from '../../context/MotionConfigContext.mjs';\nimport { useComposedRefs } from '../../utils/use-composed-ref.mjs';\n\n/**\n * Measurement functionality has to be within a separate component\n * to leverage snapshot lifecycle.\n */\nclass PopChildMeasure extends React.Component {\n getSnapshotBeforeUpdate(prevProps) {\n const element = this.props.childRef.current;\n if (element && prevProps.isPresent && !this.props.isPresent) {\n const parent = element.offsetParent;\n const parentWidth = isHTMLElement(parent)\n ? parent.offsetWidth || 0\n : 0;\n const size = this.props.sizeRef.current;\n size.height = element.offsetHeight || 0;\n size.width = element.offsetWidth || 0;\n size.top = element.offsetTop;\n size.left = element.offsetLeft;\n size.right = parentWidth - size.width - size.left;\n }\n return null;\n }\n /**\n * Required with getSnapshotBeforeUpdate to stop React complaining.\n */\n componentDidUpdate() { }\n render() {\n return this.props.children;\n }\n}\nfunction PopChild({ children, isPresent, anchorX, root }) {\n const id = useId();\n const ref = useRef(null);\n const size = useRef({\n width: 0,\n height: 0,\n top: 0,\n left: 0,\n right: 0,\n });\n const { nonce } = useContext(MotionConfigContext);\n /**\n * In React 19, refs are passed via props.ref instead of element.ref.\n * We check props.ref first (React 19) and fall back to element.ref (React 18).\n */\n const childRef = children.props?.ref ??\n children?.ref;\n const composedRef = useComposedRefs(ref, childRef);\n /**\n * We create and inject a style block so we can apply this explicit\n * sizing in a non-destructive manner by just deleting the style block.\n *\n * We can't apply size via render as the measurement happens\n * in getSnapshotBeforeUpdate (post-render), likewise if we apply the\n * styles directly on the DOM node, we might be overwriting\n * styles set via the style prop.\n */\n useInsertionEffect(() => {\n const { width, height, top, left, right } = size.current;\n if (isPresent || !ref.current || !width || !height)\n return;\n const x = anchorX === \"left\" ? `left: ${left}` : `right: ${right}`;\n ref.current.dataset.motionPopId = id;\n const style = document.createElement(\"style\");\n if (nonce)\n style.nonce = nonce;\n const parent = root ?? document.head;\n parent.appendChild(style);\n if (style.sheet) {\n style.sheet.insertRule(`\n [data-motion-pop-id=\"${id}\"] {\n position: absolute !important;\n width: ${width}px !important;\n height: ${height}px !important;\n ${x}px !important;\n top: ${top}px !important;\n }\n `);\n }\n return () => {\n if (parent.contains(style)) {\n parent.removeChild(style);\n }\n };\n }, [isPresent]);\n return (jsx(PopChildMeasure, { isPresent: isPresent, childRef: ref, sizeRef: size, children: React.cloneElement(children, { ref: composedRef }) }));\n}\n\nexport { PopChild };\n//# sourceMappingURL=PopChild.mjs.map\n","\"use client\";\nimport { jsx } from 'react/jsx-runtime';\nimport * as React from 'react';\nimport { useId, useMemo } from 'react';\nimport { PresenceContext } from '../../context/PresenceContext.mjs';\nimport { useConstant } from '../../utils/use-constant.mjs';\nimport { PopChild } from './PopChild.mjs';\n\nconst PresenceChild = ({ children, initial, isPresent, onExitComplete, custom, presenceAffectsLayout, mode, anchorX, root }) => {\n const presenceChildren = useConstant(newChildrenMap);\n const id = useId();\n let isReusedContext = true;\n let context = useMemo(() => {\n isReusedContext = false;\n return {\n id,\n initial,\n isPresent,\n custom,\n onExitComplete: (childId) => {\n presenceChildren.set(childId, true);\n for (const isComplete of presenceChildren.values()) {\n if (!isComplete)\n return; // can stop searching when any is incomplete\n }\n onExitComplete && onExitComplete();\n },\n register: (childId) => {\n presenceChildren.set(childId, false);\n return () => presenceChildren.delete(childId);\n },\n };\n }, [isPresent, presenceChildren, onExitComplete]);\n /**\n * If the presence of a child affects the layout of the components around it,\n * we want to make a new context value to ensure they get re-rendered\n * so they can detect that layout change.\n */\n if (presenceAffectsLayout && isReusedContext) {\n context = { ...context };\n }\n useMemo(() => {\n presenceChildren.forEach((_, key) => presenceChildren.set(key, false));\n }, [isPresent]);\n /**\n * If there's no `motion` components to fire exit animations, we want to remove this\n * component immediately.\n */\n React.useEffect(() => {\n !isPresent &&\n !presenceChildren.size &&\n onExitComplete &&\n onExitComplete();\n }, [isPresent]);\n if (mode === \"popLayout\") {\n children = (jsx(PopChild, { isPresent: isPresent, anchorX: anchorX, root: root, children: children }));\n }\n return (jsx(PresenceContext.Provider, { value: context, children: children }));\n};\nfunction newChildrenMap() {\n return new Map();\n}\n\nexport { PresenceChild };\n//# sourceMappingURL=PresenceChild.mjs.map\n","import { Children, isValidElement } from 'react';\n\nconst getChildKey = (child) => child.key || \"\";\nfunction onlyElements(children) {\n const filtered = [];\n // We use forEach here instead of map as map mutates the component key by preprending `.$`\n Children.forEach(children, (child) => {\n if (isValidElement(child))\n filtered.push(child);\n });\n return filtered;\n}\n\nexport { getChildKey, onlyElements };\n//# sourceMappingURL=utils.mjs.map\n","\"use client\";\nimport { jsx, Fragment } from 'react/jsx-runtime';\nimport { useMemo, useRef, useState, useContext } from 'react';\nimport { LayoutGroupContext } from '../../context/LayoutGroupContext.mjs';\nimport { useConstant } from '../../utils/use-constant.mjs';\nimport { useIsomorphicLayoutEffect } from '../../utils/use-isomorphic-effect.mjs';\nimport { PresenceChild } from './PresenceChild.mjs';\nimport { usePresence } from './use-presence.mjs';\nimport { onlyElements, getChildKey } from './utils.mjs';\n\n/**\n * `AnimatePresence` enables the animation of components that have been removed from the tree.\n *\n * When adding/removing more than a single child, every child **must** be given a unique `key` prop.\n *\n * Any `motion` components that have an `exit` property defined will animate out when removed from\n * the tree.\n *\n * ```jsx\n * import { motion, AnimatePresence } from 'framer-motion'\n *\n * export const Items = ({ items }) => (\n * <AnimatePresence>\n * {items.map(item => (\n * <motion.div\n * key={item.id}\n * initial={{ opacity: 0 }}\n * animate={{ opacity: 1 }}\n * exit={{ opacity: 0 }}\n * />\n * ))}\n * </AnimatePresence>\n * )\n * ```\n *\n * You can sequence exit animations throughout a tree using variants.\n *\n * If a child contains multiple `motion` components with `exit` props, it will only unmount the child\n * once all `motion` components have finished animating out. Likewise, any components using\n * `usePresence` all need to call `safeToRemove`.\n *\n * @public\n */\nconst AnimatePresence = ({ children, custom, initial = true, onExitComplete, presenceAffectsLayout = true, mode = \"sync\", propagate = false, anchorX = \"left\", root }) => {\n const [isParentPresent, safeToRemove] = usePresence(propagate);\n /**\n * Filter any children that aren't ReactElements. We can only track components\n * between renders with a props.key.\n */\n const presentChildren = useMemo(() => onlyElements(children), [children]);\n /**\n * Track the keys of the currently rendered children. This is used to\n * determine which children are exiting.\n */\n const presentKeys = propagate && !isParentPresent ? [] : presentChildren.map(getChildKey);\n /**\n * If `initial={false}` we only want to pass this to components in the first render.\n */\n const isInitialRender = useRef(true);\n /**\n * A ref containing the currently present children. When all exit animations\n * are complete, we use this to re-render the component with the latest children\n * *committed* rather than the latest children *rendered*.\n */\n const pendingPresentChildren = useRef(presentChildren);\n /**\n * Track which exiting children have finished animating out.\n */\n const exitComplete = useConstant(() => new Map());\n /**\n * Track which components are currently processing exit to prevent duplicate processing.\n */\n const exitingComponents = useRef(new Set());\n /**\n * Save children to render as React state. To ensure this component is concurrent-safe,\n * we check for exiting children via an effect.\n */\n const [diffedChildren, setDiffedChildren] = useState(presentChildren);\n const [renderedChildren, setRenderedChildren] = useState(presentChildren);\n useIsomorphicLayoutEffect(() => {\n isInitialRender.current = false;\n pendingPresentChildren.current = presentChildren;\n /**\n * Update complete status of exiting children.\n */\n for (let i = 0; i < renderedChildren.length; i++) {\n const key = getChildKey(renderedChildren[i]);\n if (!presentKeys.includes(key)) {\n if (exitComplete.get(key) !== true) {\n exitComplete.set(key, false);\n }\n }\n else {\n exitComplete.delete(key);\n exitingComponents.current.delete(key);\n }\n }\n }, [renderedChildren, presentKeys.length, presentKeys.join(\"-\")]);\n const exitingChildren = [];\n if (presentChildren !== diffedChildren) {\n let nextChildren = [...presentChildren];\n /**\n * Loop through all the currently rendered components and decide which\n * are exiting.\n */\n for (let i = 0; i < renderedChildren.length; i++) {\n const child = renderedChildren[i];\n const key = getChildKey(child);\n if (!presentKeys.includes(key)) {\n nextChildren.splice(i, 0, child);\n exitingChildren.push(child);\n }\n }\n /**\n * If we're in \"wait\" mode, and we have exiting children, we want to\n * only render these until they've all exited.\n */\n if (mode === \"wait\" && exitingChildren.length) {\n nextChildren = exitingChildren;\n }\n setRenderedChildren(onlyElements(nextChildren));\n setDiffedChildren(presentChildren);\n /**\n * Early return to ensure once we've set state with the latest diffed\n * children, we can immediately re-render.\n */\n return null;\n }\n if (process.env.NODE_ENV !== \"production\" &&\n mode === \"wait\" &&\n renderedChildren.length > 1) {\n console.warn(`You're attempting to animate multiple children within AnimatePresence, but its mode is set to \"wait\". This will lead to odd visual behaviour.`);\n }\n /**\n * If we've been provided a forceRender function by the LayoutGroupContext,\n * we can use it to force a re-render amongst all surrounding components once\n * all components have finished animating out.\n */\n const { forceRender } = useContext(LayoutGroupContext);\n return (jsx(Fragment, { children: renderedChildren.map((child) => {\n const key = getChildKey(child);\n const isPresent = propagate && !isParentPresent\n ? false\n : presentChildren === renderedChildren ||\n presentKeys.includes(key);\n const onExit = () => {\n if (exitingComponents.current.has(key)) {\n return;\n }\n exitingComponents.current.add(key);\n if (exitComplete.has(key)) {\n exitComplete.set(key, true);\n }\n else {\n return;\n }\n let isEveryExitComplete = true;\n exitComplete.forEach((isExitComplete) => {\n if (!isExitComplete)\n isEveryExitComplete = false;\n });\n if (isEveryExitComplete) {\n forceRender?.();\n setRenderedChildren(pendingPresentChildren.current);\n propagate && safeToRemove?.();\n onExitComplete && onExitComplete();\n }\n };\n return (jsx(PresenceChild, { isPresent: isPresent, initial: !isInitialRender.current || initial\n ? undefined\n : false, custom: custom, presenceAffectsLayout: presenceAffectsLayout, mode: mode, root: root, onExitComplete: isPresent ? undefined : onExit, anchorX: anchorX, children: child }, key));\n }) }));\n};\n\nexport { AnimatePresence };\n//# sourceMappingURL=index.mjs.map\n"],"names":["setRef","ref","value","composeRefs","refs","node","hasCleanup","cleanups","cleanup","i","useComposedRefs","React","PopChildMeasure","prevProps","element","parent","parentWidth","isHTMLElement","size","PopChild","children","isPresent","anchorX","root","id","useId","useRef","nonce","useContext","MotionConfigContext","childRef","composedRef","useInsertionEffect","width","height","top","left","right","style","jsx","PresenceChild","initial","onExitComplete","custom","presenceAffectsLayout","mode","presenceChildren","useConstant","newChildrenMap","isReusedContext","context","useMemo","childId","isComplete","_","key","PresenceContext","getChildKey","child","onlyElements","filtered","Children","isValidElement","AnimatePresence","propagate","isParentPresent","safeToRemove","usePresence","presentChildren","presentKeys","isInitialRender","pendingPresentChildren","exitComplete","exitingComponents","diffedChildren","setDiffedChildren","useState","renderedChildren","setRenderedChildren","useIsomorphicLayoutEffect","exitingChildren","nextChildren","forceRender","LayoutGroupContext","Fragment","onExit","isEveryExitComplete","isExitComplete"],"mappings":"6YASA,SAASA,EAAOC,EAAKC,EAAO,CACxB,GAAI,OAAOD,GAAQ,WACf,OAAOA,EAAIC,CAAK,EAEXD,GAAQ,OACbA,EAAI,QAAUC,EAEtB,CAKA,SAASC,KAAeC,EAAM,CAC1B,OAAQC,GAAS,CACb,IAAIC,EAAa,GACjB,MAAMC,EAAWH,EAAK,IAAKH,GAAQ,CAC/B,MAAMO,EAAUR,EAAOC,EAAKI,CAAI,EAChC,MAAI,CAACC,GAAc,OAAOE,GAAY,aAClCF,EAAa,IAEVE,CACX,CAAC,EAKD,GAAIF,EACA,MAAO,IAAM,CACT,QAASG,EAAI,EAAGA,EAAIF,EAAS,OAAQE,IAAK,CACtC,MAAMD,EAAUD,EAASE,CAAC,EACtB,OAAOD,GAAY,WACnBA,EAAO,EAGPR,EAAOI,EAAKK,CAAC,EAAG,IA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