@undp/data-viz 2.0.8 → 2.1.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 (215) hide show
  1. package/dist/AreaChart.cjs +1 -1
  2. package/dist/AreaChart.d.ts +2 -0
  3. package/dist/AreaChart.js +1 -1
  4. package/dist/BarGraph.cjs +1 -1
  5. package/dist/BarGraph.cjs.map +1 -1
  6. package/dist/BarGraph.d.ts +2 -0
  7. package/dist/BarGraph.js +1188 -1213
  8. package/dist/BarGraph.js.map +1 -1
  9. package/dist/BasicStatCard.d.ts +2 -0
  10. package/dist/BeeSwarmChart.cjs +1 -1
  11. package/dist/BeeSwarmChart.cjs.map +1 -1
  12. package/dist/BeeSwarmChart.d.ts +2 -0
  13. package/dist/BeeSwarmChart.js +258 -267
  14. package/dist/BeeSwarmChart.js.map +1 -1
  15. package/dist/BiVariateChoroplethMap.cjs +1 -1
  16. package/dist/BiVariateChoroplethMap.cjs.map +1 -1
  17. package/dist/BiVariateChoroplethMap.d.ts +2 -0
  18. package/dist/BiVariateChoroplethMap.js +126 -131
  19. package/dist/BiVariateChoroplethMap.js.map +1 -1
  20. package/dist/BulletChart.cjs +1 -1
  21. package/dist/BulletChart.cjs.map +1 -1
  22. package/dist/BulletChart.d.ts +2 -0
  23. package/dist/BulletChart.js +404 -413
  24. package/dist/BulletChart.js.map +1 -1
  25. package/dist/ButterflyChart.cjs +1 -1
  26. package/dist/ButterflyChart.cjs.map +1 -1
  27. package/dist/ButterflyChart.d.ts +2 -0
  28. package/dist/ButterflyChart.js +179 -184
  29. package/dist/ButterflyChart.js.map +1 -1
  30. package/dist/ChoroplethMap.cjs +1 -1
  31. package/dist/ChoroplethMap.cjs.map +1 -1
  32. package/dist/ChoroplethMap.d.ts +2 -0
  33. package/dist/ChoroplethMap.js +268 -273
  34. package/dist/ChoroplethMap.js.map +1 -1
  35. package/dist/CirclePackingGraph.cjs +1 -1
  36. package/dist/CirclePackingGraph.d.ts +2 -0
  37. package/dist/CirclePackingGraph.js +1 -1
  38. package/dist/DataCards.cjs +1 -1
  39. package/dist/DataCards.d.ts +2 -0
  40. package/dist/DataCards.js +2 -2
  41. package/dist/DataTable.d.ts +2 -0
  42. package/dist/DetailsModal-0Ry5nXiC.js +32 -0
  43. package/dist/DetailsModal-0Ry5nXiC.js.map +1 -0
  44. package/dist/DetailsModal-BN0HDFlV.cjs +2 -0
  45. package/dist/DetailsModal-BN0HDFlV.cjs.map +1 -0
  46. package/dist/DifferenceLineChart.cjs +1 -1
  47. package/dist/DifferenceLineChart.d.ts +2 -0
  48. package/dist/DifferenceLineChart.js +1 -1
  49. package/dist/DonutChart.cjs +1 -1
  50. package/dist/DonutChart.cjs.map +1 -1
  51. package/dist/DonutChart.d.ts +2 -0
  52. package/dist/DonutChart.js +185 -190
  53. package/dist/DonutChart.js.map +1 -1
  54. package/dist/DotDensityMap.cjs +1 -1
  55. package/dist/DotDensityMap.cjs.map +1 -1
  56. package/dist/DotDensityMap.d.ts +2 -0
  57. package/dist/DotDensityMap.js +198 -203
  58. package/dist/DotDensityMap.js.map +1 -1
  59. package/dist/DualAxisLineChart.cjs +1 -1
  60. package/dist/DualAxisLineChart.d.ts +2 -0
  61. package/dist/DualAxisLineChart.js +1 -1
  62. package/dist/DumbbellChart.cjs +1 -1
  63. package/dist/DumbbellChart.cjs.map +1 -1
  64. package/dist/DumbbellChart.d.ts +2 -0
  65. package/dist/DumbbellChart.js +364 -373
  66. package/dist/DumbbellChart.js.map +1 -1
  67. package/dist/GeoHubCompareMaps.d.ts +2 -0
  68. package/dist/GeoHubMap.d.ts +2 -0
  69. package/dist/GeoHubMapWithLayerSelection.d.ts +2 -0
  70. package/dist/{GraphEl-BcKU0bG1.cjs → GraphEl-B16EYkko.cjs} +2 -2
  71. package/dist/{GraphEl-BcKU0bG1.cjs.map → GraphEl-B16EYkko.cjs.map} +1 -1
  72. package/dist/{GraphEl-CGq1EWRn.js → GraphEl-ebgfxefq.js} +3 -3
  73. package/dist/{GraphEl-CGq1EWRn.js.map → GraphEl-ebgfxefq.js.map} +1 -1
  74. package/dist/GriddedGraphs.cjs +1 -1
  75. package/dist/GriddedGraphs.cjs.map +1 -1
  76. package/dist/GriddedGraphs.d.ts +3 -0
  77. package/dist/GriddedGraphs.js +158 -146
  78. package/dist/GriddedGraphs.js.map +1 -1
  79. package/dist/GriddedGraphsFromConfig.d.ts +3 -0
  80. package/dist/HeatMap.cjs +1 -1
  81. package/dist/HeatMap.cjs.map +1 -1
  82. package/dist/HeatMap.d.ts +2 -0
  83. package/dist/HeatMap.js +111 -116
  84. package/dist/HeatMap.js.map +1 -1
  85. package/dist/Histogram.cjs +1 -1
  86. package/dist/Histogram.d.ts +2 -0
  87. package/dist/Histogram.js +1 -1
  88. package/dist/HybridMap.cjs +1 -1
  89. package/dist/HybridMap.cjs.map +1 -1
  90. package/dist/HybridMap.d.ts +2 -0
  91. package/dist/HybridMap.js +202 -207
  92. package/dist/HybridMap.js.map +1 -1
  93. package/dist/LineChartWithConfidenceInterval.cjs +1 -1
  94. package/dist/LineChartWithConfidenceInterval.d.ts +2 -0
  95. package/dist/LineChartWithConfidenceInterval.js +1 -1
  96. package/dist/{Modal-DGcuAHyK.js → Modal-bMQA6bL_.js} +5 -5
  97. package/dist/{Modal-DGcuAHyK.js.map → Modal-bMQA6bL_.js.map} +1 -1
  98. package/dist/MultiGraphDashboard.cjs +1 -1
  99. package/dist/MultiGraphDashboard.cjs.map +1 -1
  100. package/dist/MultiGraphDashboard.d.ts +3 -0
  101. package/dist/MultiGraphDashboard.js +90 -85
  102. package/dist/MultiGraphDashboard.js.map +1 -1
  103. package/dist/MultiGraphDashboardFromConfig.d.ts +3 -0
  104. package/dist/MultiGraphDashboardWideToLongFormat.d.ts +2 -0
  105. package/dist/MultiGraphDashboardWideToLongFormat.js +1 -1
  106. package/dist/MultiGraphDashboardWideToLongFormatFromConfig.d.ts +2 -0
  107. package/dist/MultiLineAltChart.cjs +1 -1
  108. package/dist/MultiLineAltChart.d.ts +2 -0
  109. package/dist/MultiLineAltChart.js +1 -1
  110. package/dist/MultiLineChart.cjs +1 -1
  111. package/dist/MultiLineChart.d.ts +2 -0
  112. package/dist/MultiLineChart.js +1 -1
  113. package/dist/ParetoChart.cjs +1 -1
  114. package/dist/ParetoChart.cjs.map +1 -1
  115. package/dist/ParetoChart.d.ts +2 -0
  116. package/dist/ParetoChart.js +187 -192
  117. package/dist/ParetoChart.js.map +1 -1
  118. package/dist/PerformanceIntensiveMultiGraphDashboard.cjs +1 -1
  119. package/dist/PerformanceIntensiveMultiGraphDashboard.cjs.map +1 -1
  120. package/dist/PerformanceIntensiveMultiGraphDashboard.d.ts +3 -0
  121. package/dist/PerformanceIntensiveMultiGraphDashboard.js +76 -72
  122. package/dist/PerformanceIntensiveMultiGraphDashboard.js.map +1 -1
  123. package/dist/PerformanceIntensiveMultiGraphDashboardFromConfig.d.ts +3 -0
  124. package/dist/PerformanceIntensiveScrollStory.d.ts +2 -0
  125. package/dist/RadarChart.cjs +1 -1
  126. package/dist/RadarChart.cjs.map +1 -1
  127. package/dist/RadarChart.d.ts +2 -0
  128. package/dist/RadarChart.js +158 -163
  129. package/dist/RadarChart.js.map +1 -1
  130. package/dist/SankeyChart.cjs +1 -1
  131. package/dist/SankeyChart.cjs.map +1 -1
  132. package/dist/SankeyChart.d.ts +2 -0
  133. package/dist/SankeyChart.js +172 -177
  134. package/dist/SankeyChart.js.map +1 -1
  135. package/dist/ScatterPlot.cjs +1 -1
  136. package/dist/ScatterPlot.cjs.map +1 -1
  137. package/dist/ScatterPlot.d.ts +2 -0
  138. package/dist/ScatterPlot.js +222 -227
  139. package/dist/ScatterPlot.js.map +1 -1
  140. package/dist/ScrollStory.d.ts +2 -0
  141. package/dist/SimpleLineChart.cjs +1 -1
  142. package/dist/SimpleLineChart.d.ts +2 -0
  143. package/dist/SimpleLineChart.js +1 -1
  144. package/dist/SingleGraphDashboard.cjs +1 -1
  145. package/dist/SingleGraphDashboard.cjs.map +1 -1
  146. package/dist/SingleGraphDashboard.d.ts +3 -0
  147. package/dist/SingleGraphDashboard.js +131 -128
  148. package/dist/SingleGraphDashboard.js.map +1 -1
  149. package/dist/SingleGraphDashboardFromConfig.d.ts +3 -0
  150. package/dist/SingleGraphDashboardGeoHubMaps.d.ts +2 -0
  151. package/dist/SingleGraphDashboardGeoHubMapsFromConfig.d.ts +2 -0
  152. package/dist/SingleGraphDashboardThreeDGraphs.cjs +1 -1
  153. package/dist/SingleGraphDashboardThreeDGraphs.cjs.map +1 -1
  154. package/dist/SingleGraphDashboardThreeDGraphs.d.ts +3 -0
  155. package/dist/SingleGraphDashboardThreeDGraphs.js +145 -141
  156. package/dist/SingleGraphDashboardThreeDGraphs.js.map +1 -1
  157. package/dist/SingleGraphDashboardThreeDGraphsFromConfig.d.ts +3 -0
  158. package/dist/SlopeChart.cjs +1 -1
  159. package/dist/SlopeChart.cjs.map +1 -1
  160. package/dist/SlopeChart.d.ts +2 -0
  161. package/dist/SlopeChart.js +182 -187
  162. package/dist/SlopeChart.js.map +1 -1
  163. package/dist/SparkLine.cjs +1 -1
  164. package/dist/SparkLine.d.ts +2 -0
  165. package/dist/SparkLine.js +1 -1
  166. package/dist/StatCardFromData.d.ts +2 -0
  167. package/dist/StripChart.cjs +1 -1
  168. package/dist/StripChart.cjs.map +1 -1
  169. package/dist/StripChart.d.ts +2 -0
  170. package/dist/StripChart.js +249 -258
  171. package/dist/StripChart.js.map +1 -1
  172. package/dist/ThreeDGlobe.cjs +1 -1
  173. package/dist/ThreeDGlobe.cjs.map +1 -1
  174. package/dist/ThreeDGlobe.d.ts +2 -0
  175. package/dist/ThreeDGlobe.js +142 -147
  176. package/dist/ThreeDGlobe.js.map +1 -1
  177. package/dist/Tooltip-Dj5eVppQ.js +45 -0
  178. package/dist/Tooltip-Dj5eVppQ.js.map +1 -0
  179. package/dist/Tooltip-uUdw6wJL.cjs +2 -0
  180. package/dist/Tooltip-uUdw6wJL.cjs.map +1 -0
  181. package/dist/TreeMapGraph.cjs +1 -1
  182. package/dist/TreeMapGraph.cjs.map +1 -1
  183. package/dist/TreeMapGraph.d.ts +2 -0
  184. package/dist/TreeMapGraph.js +159 -164
  185. package/dist/TreeMapGraph.js.map +1 -1
  186. package/dist/Types.d.ts +3 -0
  187. package/dist/UnitChart.d.ts +2 -0
  188. package/dist/{checkIfMultiple-Y9iKaV_u.js → checkIfMultiple-CIRtG0KE.js} +2 -2
  189. package/dist/{checkIfMultiple-Y9iKaV_u.js.map → checkIfMultiple-CIRtG0KE.js.map} +1 -1
  190. package/dist/getUniqValue-DsqSii6M.js +11 -0
  191. package/dist/getUniqValue-DsqSii6M.js.map +1 -0
  192. package/dist/getUniqValue-NX8DgwND.cjs +2 -0
  193. package/dist/getUniqValue-NX8DgwND.cjs.map +1 -0
  194. package/dist/index-BBV4tAeA.js +330 -0
  195. package/dist/index-BBV4tAeA.js.map +1 -0
  196. package/dist/index-CF5hnGvG.cjs +2 -0
  197. package/dist/index-CF5hnGvG.cjs.map +1 -0
  198. package/dist/index.cjs +1 -1
  199. package/dist/index.d.ts +3 -0
  200. package/dist/index.js +2 -2
  201. package/dist/utils.cjs +1 -1
  202. package/dist/utils.js +1 -1
  203. package/package.json +1 -1
  204. package/dist/Tooltip-4dJo4_AF.cjs +0 -2
  205. package/dist/Tooltip-4dJo4_AF.cjs.map +0 -1
  206. package/dist/Tooltip-CwWUegPB.js +0 -43
  207. package/dist/Tooltip-CwWUegPB.js.map +0 -1
  208. package/dist/getUniqValue-BKHCm3zE.js +0 -11
  209. package/dist/getUniqValue-BKHCm3zE.js.map +0 -1
  210. package/dist/getUniqValue-RViz8tTw.cjs +0 -2
  211. package/dist/getUniqValue-RViz8tTw.cjs.map +0 -1
  212. package/dist/index-B2LQV7Tk.js +0 -335
  213. package/dist/index-B2LQV7Tk.js.map +0 -1
  214. package/dist/index-xRHRLDIp.cjs +0 -2
  215. package/dist/index-xRHRLDIp.cjs.map +0 -1
@@ -1,161 +1,160 @@
1
- import { j as o, m as se, c as ce } from "./index-CHPV5EwG-Curnpaqc.js";
2
- import { useState as D, useRef as $t, useEffect as Ut, useEffectEvent as me } from "react";
1
+ import { j as o, m as le, c as ce } from "./index-CHPV5EwG-Curnpaqc.js";
2
+ import { useState as k, useRef as Mt, useEffect as Ut, useEffectEvent as me } from "react";
3
3
  import { p as de, f as ue } from "./parse-DlCRUFh_.js";
4
4
  import { g as pe, N as fe } from "./getSliderMarks-HIDJ0_Cd.js";
5
5
  import { w as he } from "./Spinner-D7rnnwnA.js";
6
6
  import { i as ge } from "./index-Bwrro8-q.js";
7
- import { z as ye, t as ve, g as xe, a as be, b as we, c as je, d as ke } from "./zoom-C9MFjAaV.js";
8
- import { l as De } from "./Modal-DGcuAHyK.js";
9
- import { j as Ce } from "./Typography-PxtFcnJb.js";
10
- import { t as Ne } from "./index-GEsywGxz.js";
11
- import { T as Se } from "./Tooltip-CwWUegPB.js";
12
- import { Colors as E } from "./Colors.js";
13
- import { s as Oe } from "./string2HTML-DhG75NqA.js";
14
- import { X as Me, P as $e, e as Ee } from "./index-D491FEn1.js";
15
- import { s as Le } from "./pow-DE4c7dbW.js";
7
+ import { z as ye, t as xe, g as ve, a as be, b as we, c as je, d as De } from "./zoom-C9MFjAaV.js";
8
+ import { j as ke } from "./Typography-PxtFcnJb.js";
9
+ import { t as Ce } from "./index-GEsywGxz.js";
10
+ import { T as Ne } from "./Tooltip-Dj5eVppQ.js";
11
+ import { Colors as M } from "./Colors.js";
12
+ import { X as Se, P as Oe, e as $e } from "./index-D491FEn1.js";
13
+ import { D as Me } from "./DetailsModal-0Ry5nXiC.js";
14
+ import { s as Ee } from "./pow-DE4c7dbW.js";
16
15
  import { s as oe } from "./select-DKy99ogv.js";
17
16
  import { u as Pe } from "./use-in-view-Cxa7y1TH.js";
18
- import { m as Rt } from "./proxy-BxkFHwUw.js";
19
- import { A as _e } from "./index-BqfRwk1n.js";
20
- import { GraphFooter as ze } from "./GraphFooter.js";
21
- import { GraphHeader as Ie } from "./GraphHeader.js";
22
- import { f as Be } from "./fetchAndParseData-BpqkBPQL.js";
23
- import { c as We } from "./checkIfNullOrUndefined-DmfiKkNw.js";
17
+ import { m as Ht } from "./proxy-BxkFHwUw.js";
18
+ import { A as ze } from "./index-BqfRwk1n.js";
19
+ import { GraphFooter as Le } from "./GraphFooter.js";
20
+ import { GraphHeader as _e } from "./GraphHeader.js";
21
+ import { f as Ie } from "./fetchAndParseData-BpqkBPQL.js";
22
+ import { c as Be } from "./checkIfNullOrUndefined-DmfiKkNw.js";
24
23
  import { u as ae } from "./uniqBy-BHy4I8PK.js";
25
- import { a as Te, G as Ve } from "./GraphContainer-CRqzdKu2.js";
24
+ import { a as We, G as Ve } from "./GraphContainer-CRqzdKu2.js";
26
25
  import { s as Ae } from "./sort-BIvMlUH1.js";
27
- import { a as Fe } from "./init-BJFW6EwE.js";
28
- function He(a) {
26
+ import { a as Te } from "./init-BJFW6EwE.js";
27
+ function Fe(a) {
29
28
  const {
30
29
  data: t,
31
30
  colors: r,
32
31
  mapData: q,
33
- colorLegendTitle: L,
32
+ colorLegendTitle: E,
34
33
  colorDomain: b,
35
34
  radius: N,
36
- height: h,
35
+ height: f,
37
36
  width: c,
38
37
  scale: u,
39
38
  centerPoint: P,
40
39
  tooltip: X,
41
- showLabels: ut,
42
- mapBorderWidth: pt,
43
- mapBorderColor: ft,
40
+ showLabels: pt,
41
+ mapBorderWidth: ft,
42
+ mapBorderColor: ht,
44
43
  mapNoDataColor: Y,
45
44
  onSeriesMouseOver: K,
46
45
  showColorScale: Et,
47
- zoomScaleExtend: Lt,
48
- zoomTranslateExtend: Pt,
49
- highlightedDataPoints: ht,
46
+ zoomScaleExtend: Pt,
47
+ zoomTranslateExtend: zt,
48
+ highlightedDataPoints: gt,
50
49
  onSeriesMouseClick: Z,
51
- resetSelectionOnDoubleClick: gt,
52
- detailsOnClick: p,
53
- styles: yt,
54
- classNames: vt,
55
- mapProjection: T,
50
+ resetSelectionOnDoubleClick: yt,
51
+ detailsOnClick: x,
52
+ styles: xt,
53
+ classNames: J,
54
+ mapProjection: W,
56
55
  zoomInteraction: C,
57
56
  animate: w,
58
- dimmedOpacity: J,
57
+ dimmedOpacity: Q,
59
58
  customLayers: V,
60
- maxRadiusValue: xt,
59
+ maxRadiusValue: vt,
61
60
  collapseColorScaleByDefault: bt
62
- } = a, [wt, jt] = D(void 0), [_t, kt] = D(bt === void 0 ? !(c < 680) : !bt), Q = $t(null), [S, tt] = D(void 0), [et, l] = D(void 0), [s, A] = D(void 0), [Dt, ot] = D(void 0), _ = $t(null), z = Pe(_, {
61
+ } = a, [wt, jt] = k(void 0), [Lt, Dt] = k(bt === void 0 ? !(c < 680) : !bt), tt = Mt(null), [A, et] = k(void 0), [ot, s] = k(void 0), [l, T] = k(void 0), [kt, rt] = k(void 0), z = Mt(null), L = Pe(z, {
63
62
  once: w.once,
64
63
  amount: w.amount
65
- }), F = $t(null), O = t.filter((e) => e.radius === void 0 || e.radius === null).length !== t.length ? Le().domain([0, xt]).range([0.25, N]).nice() : void 0;
64
+ }), F = Mt(null), S = t.filter((e) => e.radius === void 0 || e.radius === null).length !== t.length ? Ee().domain([0, vt]).range([0.25, N]).nice() : void 0;
66
65
  Ut(() => {
67
- const e = oe(F.current), g = oe(_.current), i = (n) => {
66
+ const e = oe(F.current), h = oe(z.current), i = (n) => {
68
67
  if (C === "noZoom") return !1;
69
68
  if (C === "button") return !n.type.includes("wheel");
70
- const j = n.type === "wheel", x = n.type.startsWith("touch"), v = n.type === "mousedown" || n.type === "mousemove";
71
- return x ? !0 : j ? C === "scroll" ? !0 : n.ctrlKey : v && !n.button && !n.ctrlKey;
72
- }, k = ye().scaleExtent(Lt).translateExtent(Pt || [[-20, -20], [c + 20, h + 20]]).filter(i).on("zoom", ({
69
+ const j = n.type === "wheel", v = n.type.startsWith("touch"), y = n.type === "mousedown" || n.type === "mousemove";
70
+ return v ? !0 : j ? C === "scroll" ? !0 : n.ctrlKey : y && !n.button && !n.ctrlKey;
71
+ }, D = ye().scaleExtent(Pt).translateExtent(zt || [[-20, -20], [c + 20, f + 20]]).filter(i).on("zoom", ({
73
72
  transform: n
74
73
  }) => {
75
74
  e.attr("transform", n);
76
75
  });
77
- g.call(k), Q.current = k;
78
- }, [h, c, C]);
79
- const I = ve(q), y = Ne(q), rt = I[2] - I[0], Ct = I[3] - I[1], Nt = c * 190 / 960 * 360 / rt, St = h * 190 / 678 * 180 / Ct, M = u * Math.min(Nt, St), B = T === "mercator" ? xe().rotate([0, 0]).center(P || y.geometry.coordinates).translate([c / 2, h / 2]).scale(M) : T === "equalEarth" ? be().rotate([0, 0]).center(P || y.geometry.coordinates).translate([c / 2, h / 2]).scale(M) : T === "naturalEarth" ? we().rotate([0, 0]).center(P || y.geometry.coordinates).translate([c / 2, h / 2]).scale(M) : T === "orthographic" ? je().rotate([0, 0]).center(P || y.geometry.coordinates).translate([c / 2, h / 2]).scale(M) : ke().rotate([0, 0]).center(P || y.geometry.coordinates).translate([c / 2, h / 2]).scale(M), at = (e) => {
80
- if (!_.current || !Q.current) return;
81
- oe(_.current).call(Q.current.scaleBy, e === "in" ? 1.2 : 1 / 1.2);
76
+ h.call(D), tt.current = D;
77
+ }, [f, c, C]);
78
+ const _ = xe(q), g = Ce(q), at = _[2] - _[0], Ct = _[3] - _[1], Nt = c * 190 / 960 * 360 / at, St = f * 190 / 678 * 180 / Ct, O = u * Math.min(Nt, St), I = W === "mercator" ? ve().rotate([0, 0]).center(P || g.geometry.coordinates).translate([c / 2, f / 2]).scale(O) : W === "equalEarth" ? be().rotate([0, 0]).center(P || g.geometry.coordinates).translate([c / 2, f / 2]).scale(O) : W === "naturalEarth" ? we().rotate([0, 0]).center(P || g.geometry.coordinates).translate([c / 2, f / 2]).scale(O) : W === "orthographic" ? je().rotate([0, 0]).center(P || g.geometry.coordinates).translate([c / 2, f / 2]).scale(O) : De().rotate([0, 0]).center(P || g.geometry.coordinates).translate([c / 2, f / 2]).scale(O), it = (e) => {
79
+ if (!z.current || !tt.current) return;
80
+ oe(z.current).call(tt.current.scaleBy, e === "in" ? 1.2 : 1 / 1.2);
82
81
  };
83
82
  return /* @__PURE__ */ o.jsxs(o.Fragment, { children: [
84
83
  /* @__PURE__ */ o.jsxs("div", { className: "relative", children: [
85
- /* @__PURE__ */ o.jsx(Rt.svg, { width: `${c}px`, height: `${h}px`, viewBox: `0 0 ${c} ${h}`, ref: _, direction: "ltr", children: /* @__PURE__ */ o.jsxs("g", { ref: F, children: [
84
+ /* @__PURE__ */ o.jsx(Ht.svg, { width: `${c}px`, height: `${f}px`, viewBox: `0 0 ${c} ${f}`, ref: z, direction: "ltr", children: /* @__PURE__ */ o.jsxs("g", { ref: F, children: [
86
85
  V.filter((e) => e.position === "before").map((e) => e.layer),
87
86
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
88
- q.features.map((e, g) => /* @__PURE__ */ o.jsx("g", { children: e.geometry.type === "MultiPolygon" ? (
87
+ q.features.map((e, h) => /* @__PURE__ */ o.jsx("g", { children: e.geometry.type === "MultiPolygon" ? (
89
88
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
90
- e.geometry.coordinates.map((i, k) => {
89
+ e.geometry.coordinates.map((i, D) => {
91
90
  let n = "";
92
91
  return i.forEach((j) => {
93
- let x = " M";
94
- j.forEach((v, it) => {
95
- const W = B([v[0], v[1]]);
96
- it !== j.length - 1 ? x = `${x}${W[0]} ${W[1]}L` : x = `${x}${W[0]} ${W[1]}`;
97
- }), n += x;
92
+ let v = " M";
93
+ j.forEach((y, nt) => {
94
+ const B = I([y[0], y[1]]);
95
+ nt !== j.length - 1 ? v = `${v}${B[0]} ${B[1]}L` : v = `${v}${B[0]} ${B[1]}`;
96
+ }), n += v;
98
97
  }), /* @__PURE__ */ o.jsx("path", { d: n, style: {
99
- stroke: ft,
100
- strokeWidth: pt,
98
+ stroke: ht,
99
+ strokeWidth: ft,
101
100
  fill: Y
102
- } }, k);
101
+ } }, D);
103
102
  })
104
103
  ) : (
105
104
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
106
- e.geometry.coordinates.map((i, k) => {
105
+ e.geometry.coordinates.map((i, D) => {
107
106
  let n = "M";
108
- return i.forEach((j, x) => {
109
- const v = B([j[0], j[1]]);
110
- x !== i.length - 1 ? n = `${n}${v[0]} ${v[1]}L` : n = `${n}${v[0]} ${v[1]}`;
107
+ return i.forEach((j, v) => {
108
+ const y = I([j[0], j[1]]);
109
+ v !== i.length - 1 ? n = `${n}${y[0]} ${y[1]}L` : n = `${n}${y[0]} ${y[1]}`;
111
110
  }), /* @__PURE__ */ o.jsx("path", { d: n, style: {
112
- stroke: ft,
113
- strokeWidth: pt,
111
+ stroke: ht,
112
+ strokeWidth: ft,
114
113
  fill: Y
115
- } }, k);
114
+ } }, D);
116
115
  })
117
- ) }, g)),
118
- /* @__PURE__ */ o.jsx(_e, { children: t.map((e) => {
119
- const g = t.filter((i) => i.color).length === 0 ? r[0] : e.color ? r[b.indexOf(`${e.color}`)] : E.gray;
120
- return /* @__PURE__ */ o.jsxs(Rt.g, { variants: {
116
+ ) }, h)),
117
+ /* @__PURE__ */ o.jsx(ze, { children: t.map((e) => {
118
+ const h = t.filter((i) => i.color).length === 0 ? r[0] : e.color ? r[b.indexOf(`${e.color}`)] : M.gray;
119
+ return /* @__PURE__ */ o.jsxs(Ht.g, { variants: {
121
120
  initial: {
122
121
  opacity: 0
123
122
  },
124
123
  whileInView: {
125
- opacity: wt ? wt === g ? 1 : J : ht.length !== 0 ? ht.indexOf(e.label || "") !== -1 ? 1 : J : 1,
124
+ opacity: wt ? wt === h ? 1 : Q : gt.length !== 0 ? gt.indexOf(e.label || "") !== -1 ? 1 : Q : 1,
126
125
  transition: {
127
126
  duration: w.duration
128
127
  }
129
128
  }
130
- }, initial: "initial", animate: z ? "whileInView" : "initial", exit: {
129
+ }, initial: "initial", animate: L ? "whileInView" : "initial", exit: {
131
130
  opacity: 0,
132
131
  transition: {
133
132
  duration: w.duration
134
133
  }
135
134
  }, onMouseEnter: (i) => {
136
- l(e), ot(i.clientY), A(i.clientX), K?.(e);
135
+ s(e), rt(i.clientY), T(i.clientX), K?.(e);
137
136
  }, onMouseMove: (i) => {
138
- l(e), ot(i.clientY), A(i.clientX);
137
+ s(e), rt(i.clientY), T(i.clientX);
139
138
  }, onMouseLeave: () => {
140
- l(void 0), A(void 0), ot(void 0), K?.(void 0);
139
+ s(void 0), T(void 0), rt(void 0), K?.(void 0);
141
140
  }, onClick: () => {
142
- (Z || p) && (ge(S, e) && gt ? (tt(void 0), Z?.(void 0)) : (tt(e), Z?.(e)));
143
- }, transform: `translate(${B([e.long, e.lat])[0]},${B([e.long, e.lat])[1]})`, children: [
144
- /* @__PURE__ */ o.jsx(Rt.circle, { cx: 0, cy: 0, variants: {
141
+ (Z || x) && (ge(A, e) && yt ? (et(void 0), Z?.(void 0)) : (et(e), Z?.(e)));
142
+ }, transform: `translate(${I([e.long, e.lat])[0]},${I([e.long, e.lat])[1]})`, children: [
143
+ /* @__PURE__ */ o.jsx(Ht.circle, { cx: 0, cy: 0, variants: {
145
144
  initial: {
146
145
  r: 0,
147
- fill: t.filter((i) => i.color).length === 0 ? r[0] : e.color ? r[b.indexOf(`${e.color}`)] : E.gray,
148
- stroke: t.filter((i) => i.color).length === 0 ? r[0] : e.color ? r[b.indexOf(`${e.color}`)] : E.gray
146
+ fill: t.filter((i) => i.color).length === 0 ? r[0] : e.color ? r[b.indexOf(`${e.color}`)] : M.gray,
147
+ stroke: t.filter((i) => i.color).length === 0 ? r[0] : e.color ? r[b.indexOf(`${e.color}`)] : M.gray
149
148
  },
150
149
  whileInView: {
151
- r: O ? O(e.radius || 0) : N,
152
- fill: t.filter((i) => i.color).length === 0 ? r[0] : e.color ? r[b.indexOf(`${e.color}`)] : E.gray,
153
- stroke: t.filter((i) => i.color).length === 0 ? r[0] : e.color ? r[b.indexOf(`${e.color}`)] : E.gray,
150
+ r: S ? S(e.radius || 0) : N,
151
+ fill: t.filter((i) => i.color).length === 0 ? r[0] : e.color ? r[b.indexOf(`${e.color}`)] : M.gray,
152
+ stroke: t.filter((i) => i.color).length === 0 ? r[0] : e.color ? r[b.indexOf(`${e.color}`)] : M.gray,
154
153
  transition: {
155
154
  duration: w.duration
156
155
  }
157
156
  }
158
- }, initial: "initial", animate: z ? "whileInView" : "initial", exit: {
157
+ }, initial: "initial", animate: L ? "whileInView" : "initial", exit: {
159
158
  r: 0,
160
159
  transition: {
161
160
  duration: w.duration
@@ -163,19 +162,19 @@ function He(a) {
163
162
  }, style: {
164
163
  fillOpacity: 0.8
165
164
  } }),
166
- ut && e.label ? /* @__PURE__ */ o.jsx(Rt.text, { variants: {
165
+ pt && e.label ? /* @__PURE__ */ o.jsx(Ht.text, { variants: {
167
166
  initial: {
168
167
  opacity: 0,
169
- x: O ? O(e.radius || 0) : N
168
+ x: S ? S(e.radius || 0) : N
170
169
  },
171
170
  whileInView: {
172
171
  opacity: 1,
173
- x: O ? O(e.radius || 0) : N,
172
+ x: S ? S(e.radius || 0) : N,
174
173
  transition: {
175
174
  duration: w.duration
176
175
  }
177
176
  }
178
- }, initial: "initial", animate: z ? "whileInView" : "initial", exit: {
177
+ }, initial: "initial", animate: L ? "whileInView" : "initial", exit: {
179
178
  opacity: 0,
180
179
  transition: {
181
180
  duration: w.duration
@@ -187,110 +186,106 @@ function He(a) {
187
186
  }) }),
188
187
  V.filter((e) => e.position === "after").map((e) => e.layer)
189
188
  ] }) }),
190
- t.filter((e) => e.color).length === 0 || Et === !1 ? null : /* @__PURE__ */ o.jsx("div", { className: se("absolute left-4 bottom-4 map-color-legend", vt?.colorLegend), children: _t ? /* @__PURE__ */ o.jsxs(o.Fragment, { children: [
189
+ t.filter((e) => e.color).length === 0 || Et === !1 ? null : /* @__PURE__ */ o.jsx("div", { className: le("absolute left-4 bottom-4 map-color-legend", J?.colorLegend), children: Lt ? /* @__PURE__ */ o.jsxs(o.Fragment, { children: [
191
190
  /* @__PURE__ */ o.jsx("div", { className: "color-legend-close-button bg-[rgba(240,240,240,0.7)] dark:bg-[rgba(30,30,30,0.7)] border border-[var(--gray-400)] rounded-full w-6 h-6 p-[3px] cursor-pointer z-10 absolute right-[-0.75rem] top-[-0.75rem]", onClick: () => {
192
- kt(!1);
193
- }, children: /* @__PURE__ */ o.jsx(Me, {}) }),
191
+ Dt(!1);
192
+ }, children: /* @__PURE__ */ o.jsx(Se, {}) }),
194
193
  /* @__PURE__ */ o.jsxs("div", { className: "p-2", style: {
195
194
  backgroundColor: "rgba(240,240,240, 0.7)"
196
195
  }, children: [
197
- L && L !== "" ? /* @__PURE__ */ o.jsx("p", { className: "p-0 leading-normal overflow-hidden text-primary-gray-700 dark:text-primary-gray-300", style: {
196
+ E && E !== "" ? /* @__PURE__ */ o.jsx("p", { className: "p-0 leading-normal overflow-hidden text-primary-gray-700 dark:text-primary-gray-300", style: {
198
197
  display: "-webkit-box",
199
198
  WebkitLineClamp: "1",
200
199
  WebkitBoxOrient: "vertical"
201
- }, children: L }) : null,
202
- /* @__PURE__ */ o.jsx("div", { className: "flex flex-col gap-3", children: b.map((e, g) => /* @__PURE__ */ o.jsxs("div", { className: "flex gap-2 items-center", onMouseOver: () => {
203
- jt(r[g % r.length]);
200
+ }, children: E }) : null,
201
+ /* @__PURE__ */ o.jsx("div", { className: "flex flex-col gap-3", children: b.map((e, h) => /* @__PURE__ */ o.jsxs("div", { className: "flex gap-2 items-center", onMouseOver: () => {
202
+ jt(r[h % r.length]);
204
203
  }, onMouseLeave: () => {
205
204
  jt(void 0);
206
205
  }, children: [
207
206
  /* @__PURE__ */ o.jsx("div", { className: "w-2 h-2 rounded-full", style: {
208
- backgroundColor: r[g % r.length]
207
+ backgroundColor: r[h % r.length]
209
208
  } }),
210
- /* @__PURE__ */ o.jsx(Ce, { size: "sm", marginBottom: "none", leading: "none", children: e })
211
- ] }, g)) })
209
+ /* @__PURE__ */ o.jsx(ke, { size: "sm", marginBottom: "none", leading: "none", children: e })
210
+ ] }, h)) })
212
211
  ] })
213
212
  ] }) : /* @__PURE__ */ o.jsx("button", { type: "button", className: "mb-0 border-0 bg-transparent p-0 self-start", onClick: () => {
214
- kt(!0);
213
+ Dt(!0);
215
214
  }, children: /* @__PURE__ */ o.jsx("div", { className: "show-color-legend-button items-start text-sm font-medium cursor-pointer p-2 mb-0 flex text-primary-black dark:text-primary-gray-300 bg-primary-gray-300 dark:bg-primary-gray-600 border-primary-gray-400 dark:border-primary-gray-500", children: "Show Legend" }) }) }),
216
215
  C === "button" && /* @__PURE__ */ o.jsxs("div", { className: "absolute left-4 top-4 flex flex-col zoom-buttons", children: [
217
- /* @__PURE__ */ o.jsx("button", { onClick: () => at("in"), className: "leading-0 px-2 py-3.5 text-primary-gray-700 border border-primary-gray-400 bg-primary-gray-200 dark:border-primary-gray-550 dark:bg-primary-gray-600 dark:text-primary-gray-100", children: "+" }),
218
- /* @__PURE__ */ o.jsx("button", { onClick: () => at("out"), className: "leading-0 px-2 py-3.5 text-primary-gray-700 border border-t-0 border-primary-gray-400 bg-primary-gray-200 dark:border-primary-gray-550 dark:bg-primary-gray-600 dark:text-primary-gray-100", children: "–" })
216
+ /* @__PURE__ */ o.jsx("button", { onClick: () => it("in"), className: "leading-0 px-2 py-3.5 text-primary-gray-700 border border-primary-gray-400 bg-primary-gray-200 dark:border-primary-gray-550 dark:bg-primary-gray-600 dark:text-primary-gray-100", children: "+" }),
217
+ /* @__PURE__ */ o.jsx("button", { onClick: () => it("out"), className: "leading-0 px-2 py-3.5 text-primary-gray-700 border border-t-0 border-primary-gray-400 bg-primary-gray-200 dark:border-primary-gray-550 dark:bg-primary-gray-600 dark:text-primary-gray-100", children: "–" })
219
218
  ] })
220
219
  ] }),
221
- p && S !== void 0 ? /* @__PURE__ */ o.jsx(De, { open: S !== void 0, onClose: () => {
222
- tt(void 0);
223
- }, children: /* @__PURE__ */ o.jsx("div", { className: "graph-modal-content m-0", dangerouslySetInnerHTML: typeof p == "string" ? {
224
- __html: Oe(p, S)
225
- } : void 0, children: typeof p == "function" ? p(S) : null }) }) : null,
226
- et && X && s && Dt ? /* @__PURE__ */ o.jsx(Se, { data: et, body: X, xPos: s, yPos: Dt, backgroundStyle: yt?.tooltip, className: vt?.tooltip }) : null
220
+ x && A !== void 0 ? /* @__PURE__ */ o.jsx(Me, { body: x, data: A, setData: et, className: J?.modal }) : null,
221
+ ot && X && l && kt ? /* @__PURE__ */ o.jsx(Ne, { data: ot, body: X, xPos: l, yPos: kt, backgroundStyle: xt?.tooltip, className: J?.tooltip }) : null
227
222
  ] });
228
223
  }
229
- function Mo(a) {
224
+ function So(a) {
230
225
  const t = ce.c(102), {
231
226
  data: r,
232
227
  mapData: q,
233
- graphTitle: L,
228
+ graphTitle: E,
234
229
  colors: b,
235
230
  sources: N,
236
- graphDescription: h,
231
+ graphDescription: f,
237
232
  height: c,
238
233
  width: u,
239
234
  footNote: P,
240
235
  colorLegendTitle: X,
241
- colorDomain: ut,
242
- radius: pt,
243
- scale: ft,
236
+ colorDomain: pt,
237
+ radius: ft,
238
+ scale: ht,
244
239
  centerPoint: Y,
245
240
  padding: K,
246
241
  mapBorderWidth: Et,
247
- mapNoDataColor: Lt,
248
- backgroundColor: Pt,
249
- showLabels: ht,
242
+ mapNoDataColor: Pt,
243
+ backgroundColor: zt,
244
+ showLabels: gt,
250
245
  mapBorderColor: Z,
251
- tooltip: gt,
252
- relativeHeight: p,
253
- onSeriesMouseOver: yt,
254
- isWorldMap: vt,
255
- showColorScale: T,
246
+ tooltip: yt,
247
+ relativeHeight: x,
248
+ onSeriesMouseOver: xt,
249
+ isWorldMap: J,
250
+ showColorScale: W,
256
251
  zoomScaleExtend: C,
257
252
  zoomTranslateExtend: w,
258
- graphID: J,
253
+ graphID: Q,
259
254
  highlightedDataPoints: V,
260
- onSeriesMouseClick: xt,
255
+ onSeriesMouseClick: vt,
261
256
  graphDownload: bt,
262
257
  dataDownload: wt,
263
258
  showAntarctica: jt,
264
- language: _t,
265
- minHeight: kt,
266
- theme: Q,
267
- ariaLabel: S,
268
- resetSelectionOnDoubleClick: tt,
269
- detailsOnClick: et,
270
- styles: l,
271
- classNames: s,
272
- mapProjection: A,
273
- zoomInteraction: Dt,
274
- animate: ot,
275
- dimmedOpacity: _,
276
- customLayers: z,
259
+ language: Lt,
260
+ minHeight: Dt,
261
+ theme: tt,
262
+ ariaLabel: A,
263
+ resetSelectionOnDoubleClick: et,
264
+ detailsOnClick: ot,
265
+ styles: s,
266
+ classNames: l,
267
+ mapProjection: T,
268
+ zoomInteraction: kt,
269
+ animate: rt,
270
+ dimmedOpacity: z,
271
+ customLayers: L,
277
272
  maxRadiusValue: F,
278
- timeline: O,
279
- collapseColorScaleByDefault: I
280
- } = a, y = q === void 0 ? "https://raw.githubusercontent.com/UNDP-Data/dv-country-geojson/refs/heads/main/worldMap.json" : q, rt = P === void 0 ? "The designations employed and the presentation of material on this map do not imply the expression of any opinion whatsoever on the part of the Secretariat of the United Nations or UNDP concerning the legal status of any country, territory, city or area or its authorities, or concerning the delimitation of its frontiers or boundaries." : P, Ct = pt === void 0 ? 5 : pt, Nt = ft === void 0 ? 0.95 : ft, St = Et === void 0 ? 0.5 : Et, M = Lt === void 0 ? E.light.graphNoData : Lt, B = Pt === void 0 ? !1 : Pt, at = ht === void 0 ? !1 : ht, e = Z === void 0 ? E.light.grays["gray-500"] : Z, g = vt === void 0 ? !0 : vt, i = T === void 0 ? !0 : T;
281
- let k;
282
- t[0] !== C ? (k = C === void 0 ? [0.8, 6] : C, t[0] = C, t[1] = k) : k = t[1];
283
- const n = k;
273
+ timeline: S,
274
+ collapseColorScaleByDefault: _
275
+ } = a, g = q === void 0 ? "https://raw.githubusercontent.com/UNDP-Data/dv-country-geojson/refs/heads/main/worldMap.json" : q, at = P === void 0 ? "The designations employed and the presentation of material on this map do not imply the expression of any opinion whatsoever on the part of the Secretariat of the United Nations or UNDP concerning the legal status of any country, territory, city or area or its authorities, or concerning the delimitation of its frontiers or boundaries." : P, Ct = ft === void 0 ? 5 : ft, Nt = ht === void 0 ? 0.95 : ht, St = Et === void 0 ? 0.5 : Et, O = Pt === void 0 ? M.light.graphNoData : Pt, I = zt === void 0 ? !1 : zt, it = gt === void 0 ? !1 : gt, e = Z === void 0 ? M.light.grays["gray-500"] : Z, h = J === void 0 ? !0 : J, i = W === void 0 ? !0 : W;
276
+ let D;
277
+ t[0] !== C ? (D = C === void 0 ? [0.8, 6] : C, t[0] = C, t[1] = D) : D = t[1];
278
+ const n = D;
284
279
  let j;
285
280
  t[2] !== V ? (j = V === void 0 ? [] : V, t[2] = V, t[3] = j) : j = t[3];
286
- const x = j, v = bt === void 0 ? !1 : bt, it = wt === void 0 ? !1 : wt, W = jt === void 0 ? !1 : jt, qt = _t === void 0 ? "en" : _t, $ = kt === void 0 ? 0 : kt, nt = Q === void 0 ? "light" : Q, Xt = tt === void 0 ? !0 : tt, Yt = Dt === void 0 ? "button" : Dt, zt = ot === void 0 ? !1 : ot, Kt = _ === void 0 ? 0.3 : _;
281
+ const v = j, y = bt === void 0 ? !1 : bt, nt = wt === void 0 ? !1 : wt, B = jt === void 0 ? !1 : jt, qt = Lt === void 0 ? "en" : Lt, $ = Dt === void 0 ? 0 : Dt, st = tt === void 0 ? "light" : tt, Xt = et === void 0 ? !0 : et, Yt = kt === void 0 ? "button" : kt, _t = rt === void 0 ? !1 : rt, Kt = z === void 0 ? 0.3 : z;
287
282
  let It;
288
- t[4] !== z ? (It = z === void 0 ? [] : z, t[4] = z, t[5] = It) : It = t[5];
289
- const Zt = It, f = O === void 0 ? {
283
+ t[4] !== L ? (It = L === void 0 ? [] : L, t[4] = L, t[5] = It) : It = t[5];
284
+ const Zt = It, p = S === void 0 ? {
290
285
  enabled: !1,
291
286
  autoplay: !1,
292
287
  showOnlyActiveDate: !0
293
- } : O, [H, ie] = D(0), [Ot, ne] = D(0), [G, Jt] = D(f.autoplay), m = Ae(ae(r, "date", !0).map((d) => de(`${d}`, f.dateFormat || "yyyy", /* @__PURE__ */ new Date()).getTime()), to), [R, Mt] = D(f.autoplay ? 0 : m.length - 1), [lt, le] = D(void 0), Qt = $t(null), re = $t(null);
288
+ } : S, [G, ie] = k(0), [Ot, ne] = k(0), [R, Jt] = k(p.autoplay), m = Ae(ae(r, "date", !0).map((d) => de(`${d}`, p.dateFormat || "yyyy", /* @__PURE__ */ new Date()).getTime()), Qe), [H, $t] = k(p.autoplay ? 0 : m.length - 1), [lt, se] = k(void 0), Qt = Mt(null), re = Mt(null);
294
289
  let Bt, Wt;
295
290
  t[6] === Symbol.for("react.memo_cache_sentinel") ? (Bt = () => {
296
291
  const d = new ResizeObserver((U) => {
@@ -298,74 +293,74 @@ function Mo(a) {
298
293
  });
299
294
  return Qt.current && d.observe(Qt.current), () => d.disconnect();
300
295
  }, Wt = [], t[6] = Bt, t[7] = Wt) : (Bt = t[6], Wt = t[7]), Ut(Bt, Wt);
296
+ let Vt;
297
+ t[8] === Symbol.for("react.memo_cache_sentinel") ? (Vt = (d) => {
298
+ se(d);
299
+ }, t[8] = Vt) : Vt = t[8];
300
+ const At = me(Vt);
301
301
  let Tt;
302
- t[8] === Symbol.for("react.memo_cache_sentinel") ? (Tt = (d) => {
303
- le(d);
304
- }, t[8] = Tt) : Tt = t[8];
305
- const Vt = me(Tt);
306
- let At;
307
- t[9] !== y || t[10] !== Vt ? (At = () => {
308
- typeof y == "string" ? Be(y).then((U) => {
309
- Vt(U);
310
- }) : Vt(y);
311
- }, t[9] = y, t[10] = Vt, t[11] = At) : At = t[11];
302
+ t[9] !== g || t[10] !== At ? (Tt = () => {
303
+ typeof g == "string" ? Ie(g).then((U) => {
304
+ At(U);
305
+ }) : At(g);
306
+ }, t[9] = g, t[10] = At, t[11] = Tt) : Tt = t[11];
312
307
  let Ft;
313
- t[12] !== y ? (Ft = [y], t[12] = y, t[13] = Ft) : Ft = t[13], Ut(At, Ft), Ut(() => {
308
+ t[12] !== g ? (Ft = [g], t[12] = g, t[13] = Ft) : Ft = t[13], Ut(Tt, Ft), Ut(() => {
314
309
  const d = setInterval(() => {
315
- Mt((U) => U < m.length - 1 ? U + 1 : 0);
316
- }, (f.speed || 2) * 1e3);
317
- return G || clearInterval(d), () => clearInterval(d);
318
- }, [m, G, f.speed]);
319
- const Ht = pe(m, R, f.showOnlyActiveDate, f.dateFormat || "yyyy"), te = s?.graphContainer, ee = l?.graphContainer;
320
- let st;
321
- t[14] !== s?.description || t[15] !== s?.title || t[16] !== r || t[17] !== it || t[18] !== h || t[19] !== v || t[20] !== L || t[21] !== l?.description || t[22] !== l?.title || t[23] !== u ? (st = L || h || v || it ? /* @__PURE__ */ o.jsx(Ie, { styles: {
322
- title: l?.title,
323
- description: l?.description
324
- }, classNames: {
310
+ $t((U) => U < m.length - 1 ? U + 1 : 0);
311
+ }, (p.speed || 2) * 1e3);
312
+ return R || clearInterval(d), () => clearInterval(d);
313
+ }, [m, R, p.speed]);
314
+ const Gt = pe(m, H, p.showOnlyActiveDate, p.dateFormat || "yyyy"), te = l?.graphContainer, ee = s?.graphContainer;
315
+ let ct;
316
+ t[14] !== l?.description || t[15] !== l?.title || t[16] !== r || t[17] !== nt || t[18] !== f || t[19] !== y || t[20] !== E || t[21] !== s?.description || t[22] !== s?.title || t[23] !== u ? (ct = E || f || y || nt ? /* @__PURE__ */ o.jsx(_e, { styles: {
325
317
  title: s?.title,
326
318
  description: s?.description
327
- }, graphTitle: L, graphDescription: h, width: u, graphDownload: v ? re : void 0, dataDownload: it ? r.map(Qe).filter(Je).length > 0 ? r.map(Ze).filter(Ke) : r.filter(Ye) : null }) : null, t[14] = s?.description, t[15] = s?.title, t[16] = r, t[17] = it, t[18] = h, t[19] = v, t[20] = L, t[21] = l?.description, t[22] = l?.title, t[23] = u, t[24] = st) : st = t[24];
328
- let ct;
329
- t[25] !== R || t[26] !== Ht || t[27] !== G || t[28] !== Mt || t[29] !== Jt || t[30] !== f.enabled || t[31] !== m ? (ct = f.enabled && m.length > 0 && Ht ? /* @__PURE__ */ o.jsxs("div", { className: "flex gap-6 items-center", dir: "ltr", children: [
319
+ }, classNames: {
320
+ title: l?.title,
321
+ description: l?.description
322
+ }, graphTitle: E, graphDescription: f, width: u, graphDownload: y ? re : void 0, dataDownload: nt ? r.map(Je).filter(Ze).length > 0 ? r.map(Ke).filter(Ye) : r.filter(Xe) : null }) : null, t[14] = l?.description, t[15] = l?.title, t[16] = r, t[17] = nt, t[18] = f, t[19] = y, t[20] = E, t[21] = s?.description, t[22] = s?.title, t[23] = u, t[24] = ct) : ct = t[24];
323
+ let mt;
324
+ t[25] !== H || t[26] !== Gt || t[27] !== R || t[28] !== $t || t[29] !== Jt || t[30] !== p.enabled || t[31] !== m ? (mt = p.enabled && m.length > 0 && Gt ? /* @__PURE__ */ o.jsxs("div", { className: "flex gap-6 items-center", dir: "ltr", children: [
330
325
  /* @__PURE__ */ o.jsx("button", { type: "button", onClick: () => {
331
- Jt(!G);
332
- }, className: "p-0 border-0 cursor-pointer bg-transparent", "aria-label": G ? "Click to pause animation" : "Click to play animation", children: G ? /* @__PURE__ */ o.jsx($e, {}) : /* @__PURE__ */ o.jsx(Ee, {}) }),
333
- /* @__PURE__ */ o.jsx(fe, { min: m[0], max: m[m.length - 1], marks: Ht, step: null, defaultValue: m[m.length - 1], value: m[R], onChangeComplete: (d) => {
334
- Mt(m.indexOf(d));
326
+ Jt(!R);
327
+ }, className: "p-0 border-0 cursor-pointer bg-transparent", "aria-label": R ? "Click to pause animation" : "Click to play animation", children: R ? /* @__PURE__ */ o.jsx(Oe, {}) : /* @__PURE__ */ o.jsx($e, {}) }),
328
+ /* @__PURE__ */ o.jsx(fe, { min: m[0], max: m[m.length - 1], marks: Gt, step: null, defaultValue: m[m.length - 1], value: m[H], onChangeComplete: (d) => {
329
+ $t(m.indexOf(d));
335
330
  }, onChange: (d) => {
336
- Mt(m.indexOf(d));
331
+ $t(m.indexOf(d));
337
332
  }, "aria-label": "Time slider. Use arrow keys to adjust selected time period." })
338
- ] }) : null, t[25] = R, t[26] = Ht, t[27] = G, t[28] = Mt, t[29] = Jt, t[30] = f.enabled, t[31] = m, t[32] = ct) : ct = t[32];
339
- let mt;
340
- t[33] !== zt || t[34] !== Y || t[35] !== s || t[36] !== I || t[37] !== ut || t[38] !== X || t[39] !== b || t[40] !== Zt || t[41] !== r || t[42] !== et || t[43] !== Kt || t[44] !== c || t[45] !== x || t[46] !== R || t[47] !== g || t[48] !== e || t[49] !== St || t[50] !== M || t[51] !== A || t[52] !== lt || t[53] !== F || t[54] !== $ || t[55] !== xt || t[56] !== yt || t[57] !== Ct || t[58] !== p || t[59] !== Xt || t[60] !== Nt || t[61] !== W || t[62] !== i || t[63] !== at || t[64] !== l || t[65] !== Ot || t[66] !== H || t[67] !== nt || t[68] !== f.dateFormat || t[69] !== f.enabled || t[70] !== gt || t[71] !== m || t[72] !== u || t[73] !== Yt || t[74] !== n || t[75] !== w ? (mt = /* @__PURE__ */ o.jsx(Te, { ref: Qt, children: H && Ot && lt ? /* @__PURE__ */ o.jsx(He, { data: r.filter((d) => f.enabled ? d.date === ue(new Date(m[R]), f.dateFormat || "yyyy") : d), mapData: W ? lt : {
333
+ ] }) : null, t[25] = H, t[26] = Gt, t[27] = R, t[28] = $t, t[29] = Jt, t[30] = p.enabled, t[31] = m, t[32] = mt) : mt = t[32];
334
+ let dt;
335
+ t[33] !== _t || t[34] !== Y || t[35] !== l || t[36] !== _ || t[37] !== pt || t[38] !== X || t[39] !== b || t[40] !== Zt || t[41] !== r || t[42] !== ot || t[43] !== Kt || t[44] !== c || t[45] !== v || t[46] !== H || t[47] !== h || t[48] !== e || t[49] !== St || t[50] !== O || t[51] !== T || t[52] !== lt || t[53] !== F || t[54] !== $ || t[55] !== vt || t[56] !== xt || t[57] !== Ct || t[58] !== x || t[59] !== Xt || t[60] !== Nt || t[61] !== B || t[62] !== i || t[63] !== it || t[64] !== s || t[65] !== Ot || t[66] !== G || t[67] !== st || t[68] !== p.dateFormat || t[69] !== p.enabled || t[70] !== yt || t[71] !== m || t[72] !== u || t[73] !== Yt || t[74] !== n || t[75] !== w ? (dt = /* @__PURE__ */ o.jsx(We, { ref: Qt, children: G && Ot && lt ? /* @__PURE__ */ o.jsx(Fe, { data: r.filter((d) => p.enabled ? d.date === ue(new Date(m[H]), p.dateFormat || "yyyy") : d), mapData: B ? lt : {
341
336
  ...lt,
342
- features: lt.features.filter(Xe)
343
- }, colorDomain: r.filter(qe).length === 0 ? [] : ut || ae(r, "color", !0), width: H, height: Ot, scale: Nt, centerPoint: Y, colors: r.filter(Ue).length === 0 ? b ? [b] : [E.primaryColors["blue-600"]] : b || E[nt].categoricalColors.colors, colorLegendTitle: X, radius: Ct, mapBorderWidth: St, mapNoDataColor: M, mapBorderColor: e, tooltip: gt, onSeriesMouseOver: yt, showLabels: at, isWorldMap: g, showColorScale: i, zoomScaleExtend: n, zoomTranslateExtend: w, onSeriesMouseClick: xt, highlightedDataPoints: x, resetSelectionOnDoubleClick: Xt, styles: l, classNames: s, zoomInteraction: Yt, detailsOnClick: et, mapProjection: A || (g ? "naturalEarth" : "mercator"), animate: zt === !0 ? {
337
+ features: lt.features.filter(qe)
338
+ }, colorDomain: r.filter(Ue).length === 0 ? [] : pt || ae(r, "color", !0), width: G, height: Ot, scale: Nt, centerPoint: Y, colors: r.filter(He).length === 0 ? b ? [b] : [M.primaryColors["blue-600"]] : b || M[st].categoricalColors.colors, colorLegendTitle: X, radius: Ct, mapBorderWidth: St, mapNoDataColor: O, mapBorderColor: e, tooltip: yt, onSeriesMouseOver: xt, showLabels: it, isWorldMap: h, showColorScale: i, zoomScaleExtend: n, zoomTranslateExtend: w, onSeriesMouseClick: vt, highlightedDataPoints: v, resetSelectionOnDoubleClick: Xt, styles: s, classNames: l, zoomInteraction: Yt, detailsOnClick: ot, mapProjection: T || (h ? "naturalEarth" : "mercator"), animate: _t === !0 ? {
344
339
  duration: 0.5,
345
340
  once: !0,
346
341
  amount: 0.5
347
- } : zt || {
342
+ } : _t || {
348
343
  duration: 0,
349
344
  once: !0,
350
345
  amount: 0
351
- }, dimmedOpacity: Kt, customLayers: Zt, maxRadiusValue: We(F) ? Math.max(...r.map(Re).filter(Ge)) : F, collapseColorScaleByDefault: I }) : /* @__PURE__ */ o.jsx("div", { style: {
352
- height: `${Math.max($, c || (p ? $ ? (u || H) * p > $ ? (u || H) * p : $ : (u || H) * p : Ot))}px`
353
- }, className: "flex items-center justify-center", children: /* @__PURE__ */ o.jsx(he, { "aria-label": "Loading graph" }) }) }), t[33] = zt, t[34] = Y, t[35] = s, t[36] = I, t[37] = ut, t[38] = X, t[39] = b, t[40] = Zt, t[41] = r, t[42] = et, t[43] = Kt, t[44] = c, t[45] = x, t[46] = R, t[47] = g, t[48] = e, t[49] = St, t[50] = M, t[51] = A, t[52] = lt, t[53] = F, t[54] = $, t[55] = xt, t[56] = yt, t[57] = Ct, t[58] = p, t[59] = Xt, t[60] = Nt, t[61] = W, t[62] = i, t[63] = at, t[64] = l, t[65] = Ot, t[66] = H, t[67] = nt, t[68] = f.dateFormat, t[69] = f.enabled, t[70] = gt, t[71] = m, t[72] = u, t[73] = Yt, t[74] = n, t[75] = w, t[76] = mt) : mt = t[76];
354
- let dt;
355
- t[77] !== s?.footnote || t[78] !== s?.source || t[79] !== rt || t[80] !== N || t[81] !== l?.footnote || t[82] !== l?.source || t[83] !== u ? (dt = N || rt ? /* @__PURE__ */ o.jsx(ze, { styles: {
356
- footnote: l?.footnote,
357
- source: l?.source
358
- }, classNames: {
346
+ }, dimmedOpacity: Kt, customLayers: Zt, maxRadiusValue: Be(F) ? Math.max(...r.map(Re).filter(Ge)) : F, collapseColorScaleByDefault: _ }) : /* @__PURE__ */ o.jsx("div", { style: {
347
+ height: `${Math.max($, c || (x ? $ ? (u || G) * x > $ ? (u || G) * x : $ : (u || G) * x : Ot))}px`
348
+ }, className: "flex items-center justify-center", children: /* @__PURE__ */ o.jsx(he, { "aria-label": "Loading graph" }) }) }), t[33] = _t, t[34] = Y, t[35] = l, t[36] = _, t[37] = pt, t[38] = X, t[39] = b, t[40] = Zt, t[41] = r, t[42] = ot, t[43] = Kt, t[44] = c, t[45] = v, t[46] = H, t[47] = h, t[48] = e, t[49] = St, t[50] = O, t[51] = T, t[52] = lt, t[53] = F, t[54] = $, t[55] = vt, t[56] = xt, t[57] = Ct, t[58] = x, t[59] = Xt, t[60] = Nt, t[61] = B, t[62] = i, t[63] = it, t[64] = s, t[65] = Ot, t[66] = G, t[67] = st, t[68] = p.dateFormat, t[69] = p.enabled, t[70] = yt, t[71] = m, t[72] = u, t[73] = Yt, t[74] = n, t[75] = w, t[76] = dt) : dt = t[76];
349
+ let ut;
350
+ t[77] !== l?.footnote || t[78] !== l?.source || t[79] !== at || t[80] !== N || t[81] !== s?.footnote || t[82] !== s?.source || t[83] !== u ? (ut = N || at ? /* @__PURE__ */ o.jsx(Le, { styles: {
359
351
  footnote: s?.footnote,
360
352
  source: s?.source
361
- }, sources: N, footNote: rt, width: u }) : null, t[77] = s?.footnote, t[78] = s?.source, t[79] = rt, t[80] = N, t[81] = l?.footnote, t[82] = l?.source, t[83] = u, t[84] = dt) : dt = t[84];
362
- let Gt;
363
- return t[85] !== S || t[86] !== B || t[87] !== J || t[88] !== c || t[89] !== qt || t[90] !== $ || t[91] !== K || t[92] !== p || t[93] !== te || t[94] !== ee || t[95] !== st || t[96] !== ct || t[97] !== mt || t[98] !== dt || t[99] !== nt || t[100] !== u ? (Gt = /* @__PURE__ */ o.jsxs(Ve, { className: te, style: ee, id: J, ref: re, "aria-label": S, backgroundColor: B, theme: nt, language: qt, minHeight: $, width: u, height: c, relativeHeight: p, padding: K, children: [
364
- st,
353
+ }, classNames: {
354
+ footnote: l?.footnote,
355
+ source: l?.source
356
+ }, sources: N, footNote: at, width: u }) : null, t[77] = l?.footnote, t[78] = l?.source, t[79] = at, t[80] = N, t[81] = s?.footnote, t[82] = s?.source, t[83] = u, t[84] = ut) : ut = t[84];
357
+ let Rt;
358
+ return t[85] !== A || t[86] !== I || t[87] !== Q || t[88] !== c || t[89] !== qt || t[90] !== $ || t[91] !== K || t[92] !== x || t[93] !== te || t[94] !== ee || t[95] !== ct || t[96] !== mt || t[97] !== dt || t[98] !== ut || t[99] !== st || t[100] !== u ? (Rt = /* @__PURE__ */ o.jsxs(Ve, { className: te, style: ee, id: Q, ref: re, "aria-label": A, backgroundColor: I, theme: st, language: qt, minHeight: $, width: u, height: c, relativeHeight: x, padding: K, children: [
365
359
  ct,
366
360
  mt,
367
- dt
368
- ] }), t[85] = S, t[86] = B, t[87] = J, t[88] = c, t[89] = qt, t[90] = $, t[91] = K, t[92] = p, t[93] = te, t[94] = ee, t[95] = st, t[96] = ct, t[97] = mt, t[98] = dt, t[99] = nt, t[100] = u, t[101] = Gt) : Gt = t[101], Gt;
361
+ dt,
362
+ ut
363
+ ] }), t[85] = A, t[86] = I, t[87] = Q, t[88] = c, t[89] = qt, t[90] = $, t[91] = K, t[92] = x, t[93] = te, t[94] = ee, t[95] = ct, t[96] = mt, t[97] = dt, t[98] = ut, t[99] = st, t[100] = u, t[101] = Rt) : Rt = t[101], Rt;
369
364
  }
370
365
  function Ge(a) {
371
366
  return a != null;
@@ -373,34 +368,34 @@ function Ge(a) {
373
368
  function Re(a) {
374
369
  return a.radius;
375
370
  }
371
+ function He(a) {
372
+ return a.color;
373
+ }
376
374
  function Ue(a) {
377
375
  return a.color;
378
376
  }
379
377
  function qe(a) {
380
- return a.color;
378
+ return a.properties.NAME !== "Antarctica";
381
379
  }
382
380
  function Xe(a) {
383
- return a.properties.NAME !== "Antarctica";
381
+ return a !== void 0;
384
382
  }
385
383
  function Ye(a) {
386
384
  return a !== void 0;
387
385
  }
388
386
  function Ke(a) {
389
- return a !== void 0;
390
- }
391
- function Ze(a) {
392
387
  return a.data;
393
388
  }
394
- function Je(a) {
389
+ function Ze(a) {
395
390
  return a !== void 0;
396
391
  }
397
- function Qe(a) {
392
+ function Je(a) {
398
393
  return a.data;
399
394
  }
400
- function to(a, t) {
401
- return Fe(a, t);
395
+ function Qe(a, t) {
396
+ return Te(a, t);
402
397
  }
403
398
  export {
404
- Mo as DotDensityMap
399
+ So as DotDensityMap
405
400
  };
406
401
  //# sourceMappingURL=DotDensityMap.js.map