@undp/data-viz 2.0.0 → 2.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (112) hide show
  1. package/dist/BarGraph.cjs +1 -1
  2. package/dist/BarGraph.cjs.map +1 -1
  3. package/dist/BarGraph.js +957 -957
  4. package/dist/BarGraph.js.map +1 -1
  5. package/dist/BasicStatCard.cjs +1 -1
  6. package/dist/BasicStatCard.cjs.map +1 -1
  7. package/dist/BasicStatCard.js +45 -47
  8. package/dist/BasicStatCard.js.map +1 -1
  9. package/dist/BeeSwarmChart.cjs +1 -1
  10. package/dist/BeeSwarmChart.cjs.map +1 -1
  11. package/dist/BeeSwarmChart.js +76 -56
  12. package/dist/BeeSwarmChart.js.map +1 -1
  13. package/dist/BiVariateChoroplethMap.cjs +1 -1
  14. package/dist/BiVariateChoroplethMap.cjs.map +1 -1
  15. package/dist/BiVariateChoroplethMap.js +157 -157
  16. package/dist/BiVariateChoroplethMap.js.map +1 -1
  17. package/dist/ChoroplethMap.cjs +1 -1
  18. package/dist/ChoroplethMap.cjs.map +1 -1
  19. package/dist/ChoroplethMap.js +185 -185
  20. package/dist/ChoroplethMap.js.map +1 -1
  21. package/dist/CirclePackingGraph.cjs +1 -1
  22. package/dist/CirclePackingGraph.js +2 -4
  23. package/dist/CirclePackingGraph.js.map +1 -1
  24. package/dist/Data/barChart.json +70 -0
  25. package/dist/Data/basic.csv +20 -0
  26. package/dist/DifferenceLineChart.cjs +1 -1
  27. package/dist/DifferenceLineChart.cjs.map +1 -1
  28. package/dist/DifferenceLineChart.js +224 -223
  29. package/dist/DifferenceLineChart.js.map +1 -1
  30. package/dist/DotDensityMap.cjs +1 -1
  31. package/dist/DotDensityMap.cjs.map +1 -1
  32. package/dist/DotDensityMap.js +156 -156
  33. package/dist/DotDensityMap.js.map +1 -1
  34. package/dist/DualAxisLineChart.cjs +1 -1
  35. package/dist/DualAxisLineChart.cjs.map +1 -1
  36. package/dist/DualAxisLineChart.js +326 -325
  37. package/dist/DualAxisLineChart.js.map +1 -1
  38. package/dist/GeoHubCompareMaps.cjs +1 -1
  39. package/dist/GeoHubCompareMaps.cjs.map +1 -1
  40. package/dist/GeoHubCompareMaps.js +183 -183
  41. package/dist/GeoHubCompareMaps.js.map +1 -1
  42. package/dist/{GraphEl-DzRon4cb.js → GraphEl-BZne2JIx.js} +3 -3
  43. package/dist/{GraphEl-DzRon4cb.js.map → GraphEl-BZne2JIx.js.map} +1 -1
  44. package/dist/{GraphEl-BkyLYXG5.cjs → GraphEl-D5MUfp45.cjs} +2 -2
  45. package/dist/{GraphEl-BkyLYXG5.cjs.map → GraphEl-D5MUfp45.cjs.map} +1 -1
  46. package/dist/GriddedGraphs.cjs +1 -1
  47. package/dist/GriddedGraphs.js +1 -1
  48. package/dist/Histogram.cjs +1 -1
  49. package/dist/Histogram.js +1 -1
  50. package/dist/LineChartWithConfidenceInterval.cjs +1 -1
  51. package/dist/LineChartWithConfidenceInterval.cjs.map +1 -1
  52. package/dist/LineChartWithConfidenceInterval.js +133 -132
  53. package/dist/LineChartWithConfidenceInterval.js.map +1 -1
  54. package/dist/MultiGraphDashboard.cjs +1 -1
  55. package/dist/MultiGraphDashboard.cjs.map +1 -1
  56. package/dist/MultiGraphDashboard.js +52 -50
  57. package/dist/MultiGraphDashboard.js.map +1 -1
  58. package/dist/MultiGraphDashboardWideToLongFormat.cjs +1 -1
  59. package/dist/MultiGraphDashboardWideToLongFormat.cjs.map +1 -1
  60. package/dist/MultiGraphDashboardWideToLongFormat.js +11 -9
  61. package/dist/MultiGraphDashboardWideToLongFormat.js.map +1 -1
  62. package/dist/MultiLineAltChart.cjs +1 -1
  63. package/dist/MultiLineAltChart.cjs.map +1 -1
  64. package/dist/MultiLineAltChart.js +149 -148
  65. package/dist/MultiLineAltChart.js.map +1 -1
  66. package/dist/MultiLineChart.cjs +1 -1
  67. package/dist/MultiLineChart.cjs.map +1 -1
  68. package/dist/MultiLineChart.js +182 -181
  69. package/dist/MultiLineChart.js.map +1 -1
  70. package/dist/PerformanceIntensiveMultiGraphDashboard.cjs +1 -1
  71. package/dist/PerformanceIntensiveMultiGraphDashboard.cjs.map +1 -1
  72. package/dist/PerformanceIntensiveMultiGraphDashboard.js +14 -12
  73. package/dist/PerformanceIntensiveMultiGraphDashboard.js.map +1 -1
  74. package/dist/SimpleLineChart.cjs +1 -1
  75. package/dist/SimpleLineChart.cjs.map +1 -1
  76. package/dist/SimpleLineChart.js +123 -122
  77. package/dist/SimpleLineChart.js.map +1 -1
  78. package/dist/SingleGraphDashboard.cjs +1 -1
  79. package/dist/SingleGraphDashboard.cjs.map +1 -1
  80. package/dist/SingleGraphDashboard.js +83 -79
  81. package/dist/SingleGraphDashboard.js.map +1 -1
  82. package/dist/SingleGraphDashboardGeoHubMaps.cjs +1 -1
  83. package/dist/SingleGraphDashboardGeoHubMaps.cjs.map +1 -1
  84. package/dist/SingleGraphDashboardGeoHubMaps.js +49 -45
  85. package/dist/SingleGraphDashboardGeoHubMaps.js.map +1 -1
  86. package/dist/SingleGraphDashboardThreeDGraphs.cjs +1 -1
  87. package/dist/SingleGraphDashboardThreeDGraphs.cjs.map +1 -1
  88. package/dist/SingleGraphDashboardThreeDGraphs.js +56 -52
  89. package/dist/SingleGraphDashboardThreeDGraphs.js.map +1 -1
  90. package/dist/StatCardFromData.cjs +1 -1
  91. package/dist/StatCardFromData.cjs.map +1 -1
  92. package/dist/StatCardFromData.js +44 -46
  93. package/dist/StatCardFromData.js.map +1 -1
  94. package/dist/ThreeDGlobe.cjs +1 -1
  95. package/dist/ThreeDGlobe.cjs.map +1 -1
  96. package/dist/ThreeDGlobe.js +134 -134
  97. package/dist/ThreeDGlobe.js.map +1 -1
  98. package/dist/getNoOfTicks-C_1CFXv_.cjs +2 -0
  99. package/dist/getNoOfTicks-C_1CFXv_.cjs.map +1 -0
  100. package/dist/getNoOfTicks-CpmRjcRF.js +7 -0
  101. package/dist/getNoOfTicks-CpmRjcRF.js.map +1 -0
  102. package/dist/index-C6LorfZ-.cjs +2 -0
  103. package/dist/index-C6LorfZ-.cjs.map +1 -0
  104. package/dist/index-Ceppbd8C.js +342 -0
  105. package/dist/index-Ceppbd8C.js.map +1 -0
  106. package/dist/index.cjs +1 -1
  107. package/dist/index.js +1 -1
  108. package/package.json +1 -1
  109. package/dist/index-DoY3Ga3W.cjs +0 -2
  110. package/dist/index-DoY3Ga3W.cjs.map +0 -1
  111. package/dist/index-leTnKT2q.js +0 -329
  112. package/dist/index-leTnKT2q.js.map +0 -1
@@ -1,6 +1,6 @@
1
- import { c as se, j as r } from "./index-CHPV5EwG-Curnpaqc.js";
2
- import ie, { useState as Q, useRef as k, useEffect as ne } from "react";
3
- import * as T from "maplibre-gl";
1
+ import { c as se, j as t } from "./index-CHPV5EwG-Curnpaqc.js";
2
+ import ie, { useState as Q, useRef as z, useEffect as ne } from "react";
3
+ import * as I from "maplibre-gl";
4
4
  import * as ae from "pmtiles";
5
5
  /* empty css */
6
6
  import { useSensors as ce, useSensor as me, PointerSensor as fe, DndContext as de, useDraggable as ue } from "@dnd-kit/core";
@@ -11,180 +11,180 @@ import { s as le } from "./select-DKy99ogv.js";
11
11
  import { GraphHeader as ve } from "./GraphHeader.js";
12
12
  import { GraphFooter as ye } from "./GraphFooter.js";
13
13
  import { a as xe, G as we } from "./GraphContainer-CRqzdKu2.js";
14
- function je(S, e) {
15
- let a = !1;
16
- function o(t, s) {
17
- if (!a) {
18
- a = !0;
19
- const m = t.getCenter(), n = t.getZoom(), l = t.getBearing(), f = t.getPitch();
20
- s.jumpTo({
21
- center: m,
22
- zoom: n,
23
- bearing: l,
14
+ function je(j, e) {
15
+ let i = !1;
16
+ function l(o, m) {
17
+ if (!i) {
18
+ i = !0;
19
+ const c = o.getCenter(), s = o.getZoom(), r = o.getBearing(), f = o.getPitch();
20
+ m.jumpTo({
21
+ center: c,
22
+ zoom: s,
23
+ bearing: r,
24
24
  pitch: f
25
- }), a = !1;
25
+ }), i = !1;
26
26
  }
27
27
  }
28
- S.on("move", () => {
29
- o(S, e);
28
+ j.on("move", () => {
29
+ l(j, e);
30
30
  }), e.on("move", () => {
31
- o(e, S);
31
+ l(e, j);
32
32
  });
33
33
  }
34
- function Ce(S) {
34
+ function Ce(j) {
35
35
  const e = se.c(47), {
36
- height: a,
37
- width: o,
38
- mapStyles: t,
39
- center: s,
40
- zoomLevel: m,
41
- mapLegend: n
42
- } = S, [l, f] = Q(50), [h, b] = Q(!1), x = k(null), [P, F] = Q(!0), O = k(50), X = k(0);
43
- let $;
44
- e[0] === Symbol.for("react.memo_cache_sentinel") ? ($ = {
36
+ height: i,
37
+ width: l,
38
+ mapStyles: o,
39
+ center: m,
40
+ zoomLevel: c,
41
+ mapLegend: s
42
+ } = j, [r, f] = Q(50), [h, g] = Q(!1), v = z(null), [k, Z] = Q(!0), F = z(50), T = z(0);
43
+ let G;
44
+ e[0] === Symbol.for("react.memo_cache_sentinel") ? (G = {
45
45
  activationConstraint: {
46
46
  distance: 0
47
47
  }
48
- }, e[0] = $) : $ = e[0];
49
- const A = ce(me(fe, $));
50
- let i;
51
- e[1] !== l ? (i = () => {
52
- b(!0), O.current = l, x.current && (X.current = x.current.getBoundingClientRect().width);
53
- }, e[1] = l, e[2] = i) : i = e[2];
54
- const c = i;
55
- let R;
56
- e[3] === Symbol.for("react.memo_cache_sentinel") ? (R = (Y) => {
57
- if (!x.current || X.current === 0)
48
+ }, e[0] = G) : G = e[0];
49
+ const $ = ce(me(fe, G));
50
+ let n;
51
+ e[1] !== r ? (n = () => {
52
+ g(!0), F.current = r, v.current && (T.current = v.current.getBoundingClientRect().width);
53
+ }, e[1] = r, e[2] = n) : n = e[2];
54
+ const a = n;
55
+ let P;
56
+ e[3] === Symbol.for("react.memo_cache_sentinel") ? (P = (Y) => {
57
+ if (!v.current || T.current === 0)
58
58
  return;
59
- const K = Y.delta.x / X.current * 100, ee = Math.max(0, Math.min(100, O.current + K));
59
+ const K = Y.delta.x / T.current * 100, ee = Math.max(0, Math.min(100, F.current + K));
60
60
  f(ee);
61
- }, e[3] = R) : R = e[3];
62
- const V = R;
63
- let _;
64
- e[4] === Symbol.for("react.memo_cache_sentinel") ? (_ = () => {
65
- b(!1);
66
- }, e[4] = _) : _ = e[4];
67
- const q = _;
68
- let H;
69
- e[5] !== h ? (H = (Y) => {
70
- if (h || !x.current)
61
+ }, e[3] = P) : P = e[3];
62
+ const O = P;
63
+ let C;
64
+ e[4] === Symbol.for("react.memo_cache_sentinel") ? (C = () => {
65
+ g(!1);
66
+ }, e[4] = C) : C = e[4];
67
+ const V = C;
68
+ let R;
69
+ e[5] !== h ? (R = (Y) => {
70
+ if (h || !v.current)
71
71
  return;
72
- const K = x.current.getBoundingClientRect(), te = (Y.clientX - K.left) / K.width * 100;
72
+ const K = v.current.getBoundingClientRect(), te = (Y.clientX - K.left) / K.width * 100;
73
73
  f(Math.max(0, Math.min(100, te)));
74
- }, e[5] = h, e[6] = H) : H = e[6];
75
- const E = H, v = k(null), L = k(null), g = k(null), J = k(null);
76
- let M, W;
77
- e[7] !== s || e[8] !== t || e[9] !== o || e[10] !== m ? (M = () => {
78
- if (J.current && L.current && g.current && o) {
79
- le(J.current).selectAll(".maplibregl-compare").remove(), le(L.current).selectAll("div").remove(), le(g.current).selectAll("div").remove();
74
+ }, e[5] = h, e[6] = R) : R = e[6];
75
+ const A = R, q = z(null), H = z(null), S = z(null), J = z(null);
76
+ let _, X;
77
+ e[7] !== m || e[8] !== o || e[9] !== l || e[10] !== c ? (_ = () => {
78
+ if (J.current && H.current && S.current && l) {
79
+ le(J.current).selectAll(".maplibregl-compare").remove(), le(H.current).selectAll("div").remove(), le(S.current).selectAll("div").remove();
80
80
  const te = new ae.Protocol();
81
- T.addProtocol("pmtiles", te.tile);
82
- const oe = new T.Map({
83
- container: L.current,
84
- style: t[0],
85
- center: s || [0, 0],
86
- zoom: m || 4
87
- }), re = new T.Map({
88
- container: g.current,
89
- style: t[1],
90
- center: s || [0, 0],
91
- zoom: m || 4
81
+ I.addProtocol("pmtiles", te.tile);
82
+ const oe = new I.Map({
83
+ container: H.current,
84
+ style: o[0],
85
+ center: m || [0, 0],
86
+ zoom: c || 4
87
+ }), re = new I.Map({
88
+ container: S.current,
89
+ style: o[1],
90
+ center: m || [0, 0],
91
+ zoom: c || 4
92
92
  });
93
- re.addControl(new T.NavigationControl({
93
+ re.addControl(new I.NavigationControl({
94
94
  visualizePitch: !0,
95
95
  showZoom: !0,
96
96
  showCompass: !0
97
- }), "bottom-right"), oe.addControl(new T.ScaleControl(), "bottom-left"), oe.addControl(new T.NavigationControl({
97
+ }), "bottom-right"), oe.addControl(new I.ScaleControl(), "bottom-left"), oe.addControl(new I.NavigationControl({
98
98
  visualizePitch: !0,
99
99
  showZoom: !0,
100
100
  showCompass: !0
101
- }), "bottom-right"), re.addControl(new T.ScaleControl(), "bottom-left"), je(oe, re);
101
+ }), "bottom-right"), re.addControl(new I.ScaleControl(), "bottom-left"), je(oe, re);
102
102
  }
103
- }, W = [o, t, s, m], e[7] = s, e[8] = t, e[9] = o, e[10] = m, e[11] = M, e[12] = W) : (M = e[11], W = e[12]), ne(M, W);
104
- let w;
105
- e[13] !== a || e[14] !== o ? (w = {
106
- width: o,
107
- height: a
108
- }, e[13] = a, e[14] = o, e[15] = w) : w = e[15];
109
- let B;
110
- e[16] === Symbol.for("react.memo_cache_sentinel") ? (B = {
103
+ }, X = [l, o, m, c], e[7] = m, e[8] = o, e[9] = l, e[10] = c, e[11] = _, e[12] = X) : (_ = e[11], X = e[12]), ne(_, X);
104
+ let y;
105
+ e[13] !== i || e[14] !== l ? (y = {
106
+ width: l,
107
+ height: i
108
+ }, e[13] = i, e[14] = l, e[15] = y) : y = e[15];
109
+ let W;
110
+ e[16] === Symbol.for("react.memo_cache_sentinel") ? (W = {
111
111
  inset: 0
112
- }, e[16] = B) : B = e[16];
112
+ }, e[16] = W) : W = e[16];
113
113
  let D;
114
114
  e[17] === Symbol.for("react.memo_cache_sentinel") ? (D = [pe], e[17] = D) : D = e[17];
115
- const G = h ? "grabbing" : "col-resize";
116
- let j;
117
- e[18] !== a || e[19] !== G || e[20] !== o ? (j = {
115
+ const L = h ? "grabbing" : "col-resize";
116
+ let x;
117
+ e[18] !== i || e[19] !== L || e[20] !== l ? (x = {
118
118
  position: "relative",
119
- width: o,
120
- height: a,
119
+ width: l,
120
+ height: i,
121
121
  overflow: "hidden",
122
- cursor: G,
122
+ cursor: L,
123
123
  userSelect: "none"
124
- }, e[18] = a, e[19] = G, e[20] = o, e[21] = j) : j = e[21];
125
- const I = `polygon(${l}% 0%, ${l}% 100%, 100% 100%, 100% 0%)`;
124
+ }, e[18] = i, e[19] = L, e[20] = l, e[21] = x) : x = e[21];
125
+ const E = `polygon(${r}% 0%, ${r}% 100%, 100% 100%, 100% 0%)`;
126
126
  let d;
127
- e[22] !== I ? (d = /* @__PURE__ */ r.jsx("div", { ref: g, className: "absolute h-full rightMap w-full", style: {
127
+ e[22] !== E ? (d = /* @__PURE__ */ t.jsx("div", { ref: S, className: "absolute h-full rightMap w-full", style: {
128
128
  position: "absolute",
129
129
  top: 0,
130
130
  left: 0,
131
- clipPath: I
132
- } }), e[22] = I, e[23] = d) : d = e[23];
133
- const C = `polygon(0% 0%, ${l}% 0%, ${l}% 100%, 0% 100%)`;
131
+ clipPath: E
132
+ } }), e[22] = E, e[23] = d) : d = e[23];
133
+ const w = `polygon(0% 0%, ${r}% 0%, ${r}% 100%, 0% 100%)`;
134
134
  let u;
135
- e[24] !== C ? (u = /* @__PURE__ */ r.jsx("div", { ref: L, className: "absolute h-full leftMap w-full", style: {
135
+ e[24] !== w ? (u = /* @__PURE__ */ t.jsx("div", { ref: H, className: "absolute h-full leftMap w-full", style: {
136
136
  position: "absolute",
137
137
  top: 0,
138
138
  left: 0,
139
139
  inset: 0,
140
- clipPath: C
141
- } }), e[24] = C, e[25] = u) : u = e[25];
140
+ clipPath: w
141
+ } }), e[24] = w, e[25] = u) : u = e[25];
142
142
  let p;
143
- e[26] !== l ? (p = /* @__PURE__ */ r.jsx(Se, { position: l }), e[26] = l, e[27] = p) : p = e[27];
144
- let y;
145
- e[28] !== E || e[29] !== j || e[30] !== d || e[31] !== u || e[32] !== p ? (y = /* @__PURE__ */ r.jsxs("div", { ref: x, style: j, onClick: E, children: [
143
+ e[26] !== r ? (p = /* @__PURE__ */ t.jsx(Se, { position: r }), e[26] = r, e[27] = p) : p = e[27];
144
+ let b;
145
+ e[28] !== A || e[29] !== x || e[30] !== d || e[31] !== u || e[32] !== p ? (b = /* @__PURE__ */ t.jsxs("div", { ref: v, style: x, onClick: A, children: [
146
146
  d,
147
147
  u,
148
148
  p
149
- ] }), e[28] = E, e[29] = j, e[30] = d, e[31] = u, e[32] = p, e[33] = y) : y = e[33];
149
+ ] }), e[28] = A, e[29] = x, e[30] = d, e[31] = u, e[32] = p, e[33] = b) : b = e[33];
150
+ let M;
151
+ e[34] !== a || e[35] !== $ || e[36] !== b ? (M = /* @__PURE__ */ t.jsx("div", { ref: J, className: "map maplibre-show-control relative w-full h-full", style: W, children: /* @__PURE__ */ t.jsx(de, { sensors: $, modifiers: D, onDragStart: a, onDragMove: O, onDragEnd: V, children: b }) }), e[34] = a, e[35] = $, e[36] = b, e[37] = M) : M = e[37];
150
152
  let N;
151
- e[34] !== c || e[35] !== A || e[36] !== y ? (N = /* @__PURE__ */ r.jsx("div", { ref: J, className: "map maplibre-show-control relative w-full h-full", style: B, children: /* @__PURE__ */ r.jsx(de, { sensors: A, modifiers: D, onDragStart: c, onDragMove: V, onDragEnd: q, children: y }) }), e[34] = c, e[35] = A, e[36] = y, e[37] = N) : N = e[37];
152
- let z;
153
- e[38] !== N || e[39] !== w ? (z = /* @__PURE__ */ r.jsx("div", { style: w, children: N }), e[38] = N, e[39] = w, e[40] = z) : z = e[40];
154
- let Z;
155
- e[41] !== n || e[42] !== P ? (Z = n ? /* @__PURE__ */ r.jsx("div", { className: "absolute left-[22px] bottom-13", children: P ? /* @__PURE__ */ r.jsxs(r.Fragment, { children: [
156
- /* @__PURE__ */ r.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: () => {
157
- F(!1);
158
- }, children: /* @__PURE__ */ r.jsx(he, {}) }),
159
- /* @__PURE__ */ r.jsx("div", { className: "color-legend-box p-2 bg-[rgba(240,240,240,0.7)] dark:bg-[rgba(30,30,30,0.7)]", dangerouslySetInnerHTML: typeof n == "string" ? {
160
- __html: be(n)
161
- } : void 0, children: ie.isValidElement(n) ? n : null })
162
- ] }) : /* @__PURE__ */ r.jsx("button", { type: "button", className: "mb-0 border-0 bg-transparent p-0 self-start", onClick: () => {
163
- F(!0);
164
- }, children: /* @__PURE__ */ r.jsx("div", { className: "show-color-legend-button items-start text-sm font-medium cursor-pointer p-2 mb-0 flex text-primary-black dark:text-primary-gray-300 bg-primary-gray-300 dark:bg-primary-gray-600 border-primary-gray-400 dark:border-primary-gray-500", children: "Show Legend" }) }) }) : null, e[41] = n, e[42] = P, e[43] = Z) : Z = e[43];
153
+ e[38] !== M || e[39] !== y ? (N = /* @__PURE__ */ t.jsx("div", { style: y, children: M }), e[38] = M, e[39] = y, e[40] = N) : N = e[40];
154
+ let B;
155
+ e[41] !== s || e[42] !== k ? (B = s ? /* @__PURE__ */ t.jsx("div", { className: "absolute left-[22px] bottom-13", children: k ? /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
156
+ /* @__PURE__ */ t.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: () => {
157
+ Z(!1);
158
+ }, children: /* @__PURE__ */ t.jsx(he, {}) }),
159
+ /* @__PURE__ */ t.jsx("div", { className: "color-legend-box p-2 bg-[rgba(240,240,240,0.7)] dark:bg-[rgba(30,30,30,0.7)]", dangerouslySetInnerHTML: typeof s == "string" ? {
160
+ __html: be(s)
161
+ } : void 0, children: ie.isValidElement(s) ? s : null })
162
+ ] }) : /* @__PURE__ */ t.jsx("button", { type: "button", className: "mb-0 border-0 bg-transparent p-0 self-start", onClick: () => {
163
+ Z(!0);
164
+ }, children: /* @__PURE__ */ t.jsx("div", { className: "show-color-legend-button items-start text-sm font-medium cursor-pointer p-2 mb-0 flex text-primary-black dark:text-primary-gray-300 bg-primary-gray-300 dark:bg-primary-gray-600 border-primary-gray-400 dark:border-primary-gray-500", children: "Show Legend" }) }) }) : null, e[41] = s, e[42] = k, e[43] = B) : B = e[43];
165
165
  let U;
166
- return e[44] !== z || e[45] !== Z ? (U = /* @__PURE__ */ r.jsxs("div", { className: "flex flex-col grow justify-center leading-0", ref: v, "aria-label": "Map area", children: [
167
- z,
168
- Z
169
- ] }), e[44] = z, e[45] = Z, e[46] = U) : U = e[46], U;
166
+ return e[44] !== N || e[45] !== B ? (U = /* @__PURE__ */ t.jsxs("div", { className: "flex flex-col grow justify-center leading-0", ref: q, "aria-label": "Map area", children: [
167
+ N,
168
+ B
169
+ ] }), e[44] = N, e[45] = B, e[46] = U) : U = e[46], U;
170
170
  }
171
- function Se(S) {
171
+ function Se(j) {
172
172
  const e = se.c(10), {
173
- position: a
174
- } = S;
175
- let o;
176
- e[0] === Symbol.for("react.memo_cache_sentinel") ? (o = {
173
+ position: i
174
+ } = j;
175
+ let l;
176
+ e[0] === Symbol.for("react.memo_cache_sentinel") ? (l = {
177
177
  id: "slider-handle"
178
- }, e[0] = o) : o = e[0];
178
+ }, e[0] = l) : l = e[0];
179
179
  const {
180
- attributes: t,
181
- listeners: s,
182
- setNodeRef: m
183
- } = ue(o), n = `${a}%`;
184
- let l;
185
- e[1] !== n ? (l = {
180
+ attributes: o,
181
+ listeners: m,
182
+ setNodeRef: c
183
+ } = ue(l), s = `${i}%`;
184
+ let r;
185
+ e[1] !== s ? (r = {
186
186
  position: "absolute",
187
- left: n,
187
+ left: s,
188
188
  top: 0,
189
189
  bottom: 0,
190
190
  width: "40px",
@@ -195,86 +195,86 @@ function Se(S) {
195
195
  alignItems: "center",
196
196
  zIndex: 10,
197
197
  touchAction: "none"
198
- }, e[1] = n, e[2] = l) : l = e[2];
198
+ }, e[1] = s, e[2] = r) : r = e[2];
199
199
  let f;
200
- e[3] === Symbol.for("react.memo_cache_sentinel") ? (f = /* @__PURE__ */ r.jsx("div", { className: "h-full bg-primary-blue-600 dark:bg-primary-blue-400", style: {
200
+ e[3] === Symbol.for("react.memo_cache_sentinel") ? (f = /* @__PURE__ */ t.jsx("div", { className: "h-full bg-primary-blue-600 dark:bg-primary-blue-400", style: {
201
201
  width: "2px"
202
202
  } }), e[3] = f) : f = e[3];
203
203
  let h;
204
- e[4] === Symbol.for("react.memo_cache_sentinel") ? (h = /* @__PURE__ */ r.jsx("div", { className: "flex bg-primary-blue-600 dark:bg-primary-blue-400 rounded-full absolute items-center justify-center text-primary-white font-primary-white", style: {
204
+ e[4] === Symbol.for("react.memo_cache_sentinel") ? (h = /* @__PURE__ */ t.jsx("div", { className: "flex bg-primary-blue-600 dark:bg-primary-blue-400 rounded-full absolute items-center justify-center text-primary-white font-primary-white", style: {
205
205
  boxShadow: "inset 0 0 0 1px #fff",
206
206
  width: "42px",
207
207
  height: "42px",
208
208
  top: "calc(50% - 21px)",
209
209
  left: "0",
210
210
  cursor: "col-resize"
211
- }, children: /* @__PURE__ */ r.jsx(ge, {}) }), e[4] = h) : h = e[4];
212
- let b;
213
- return e[5] !== t || e[6] !== s || e[7] !== m || e[8] !== l ? (b = /* @__PURE__ */ r.jsxs("div", { ref: m, style: l, ...s, ...t, children: [
211
+ }, children: /* @__PURE__ */ t.jsx(ge, {}) }), e[4] = h) : h = e[4];
212
+ let g;
213
+ return e[5] !== o || e[6] !== m || e[7] !== c || e[8] !== r ? (g = /* @__PURE__ */ t.jsxs("div", { ref: c, style: r, ...m, ...o, children: [
214
214
  f,
215
215
  h
216
- ] }), e[5] = t, e[6] = s, e[7] = m, e[8] = l, e[9] = b) : b = e[9], b;
216
+ ] }), e[5] = o, e[6] = m, e[7] = c, e[8] = r, e[9] = g) : g = e[9], g;
217
217
  }
218
- function $e(S) {
219
- const e = se.c(49), {
220
- graphTitle: a,
221
- height: o,
222
- width: t,
223
- relativeHeight: s,
224
- sources: m,
225
- graphDescription: n,
226
- footNote: l,
218
+ function $e(j) {
219
+ const e = se.c(45), {
220
+ graphTitle: i,
221
+ height: l,
222
+ width: o,
223
+ relativeHeight: m,
224
+ sources: c,
225
+ graphDescription: s,
226
+ footNote: r,
227
227
  padding: f,
228
228
  backgroundColor: h,
229
- graphID: b,
230
- mapStyles: x,
231
- center: P,
232
- zoomLevel: F,
233
- language: O,
234
- minHeight: X,
235
- theme: $,
236
- ariaLabel: A,
237
- styles: i,
238
- classNames: c,
239
- mapLegend: R
240
- } = S, V = h === void 0 ? !1 : h;
241
- let _;
242
- e[0] !== P ? (_ = P === void 0 ? [0, 0] : P, e[0] = P, e[1] = _) : _ = e[1];
243
- const q = _, H = F === void 0 ? 3 : F, E = O === void 0 ? "en" : O, v = X === void 0 ? 0 : X, L = $ === void 0 ? "light" : $, [g, J] = Q(0), [M, W] = Q(0), w = k(null), B = k(null);
244
- let D, G;
229
+ graphID: g,
230
+ mapStyles: v,
231
+ center: k,
232
+ zoomLevel: Z,
233
+ language: F,
234
+ minHeight: T,
235
+ theme: G,
236
+ ariaLabel: $,
237
+ styles: n,
238
+ classNames: a,
239
+ mapLegend: P
240
+ } = j, O = h === void 0 ? !1 : h;
241
+ let C;
242
+ e[0] !== k ? (C = k === void 0 ? [0, 0] : k, e[0] = k, e[1] = C) : C = e[1];
243
+ const V = C, R = Z === void 0 ? 3 : Z, A = F === void 0 ? "en" : F, q = T === void 0 ? 0 : T, H = G === void 0 ? "light" : G, [S, J] = Q(0), [_, X] = Q(0), y = z(null), W = z(null);
244
+ let D, L;
245
245
  e[2] === Symbol.for("react.memo_cache_sentinel") ? (D = () => {
246
- const N = new ResizeObserver((z) => {
247
- J(z[0].target.clientWidth || 620), W(z[0].target.clientHeight || 480);
246
+ const M = new ResizeObserver((N) => {
247
+ J(N[0].target.clientWidth || 620), X(N[0].target.clientHeight || 480);
248
248
  });
249
- return w.current && N.observe(w.current), () => N.disconnect();
250
- }, G = [], e[2] = D, e[3] = G) : (D = e[2], G = e[3]), ne(D, G);
251
- const j = c?.graphContainer, I = i?.graphContainer;
249
+ return y.current && M.observe(y.current), () => M.disconnect();
250
+ }, L = [], e[2] = D, e[3] = L) : (D = e[2], L = e[3]), ne(D, L);
251
+ const x = a?.graphContainer, E = n?.graphContainer;
252
252
  let d;
253
- e[4] !== c?.description || e[5] !== c?.title || e[6] !== n || e[7] !== a || e[8] !== i?.description || e[9] !== i?.title || e[10] !== t ? (d = a || n ? /* @__PURE__ */ r.jsx(ve, { styles: {
254
- title: i?.title,
255
- description: i?.description
253
+ e[4] !== a?.description || e[5] !== a?.title || e[6] !== s || e[7] !== i || e[8] !== n?.description || e[9] !== n?.title || e[10] !== o ? (d = i || s ? /* @__PURE__ */ t.jsx(ve, { styles: {
254
+ title: n?.title,
255
+ description: n?.description
256
256
  }, classNames: {
257
- title: c?.title,
258
- description: c?.description
259
- }, graphTitle: a, graphDescription: n, width: t }) : null, e[4] = c?.description, e[5] = c?.title, e[6] = n, e[7] = a, e[8] = i?.description, e[9] = i?.title, e[10] = t, e[11] = d) : d = e[11];
260
- let C;
261
- e[12] !== q || e[13] !== o || e[14] !== R || e[15] !== x || e[16] !== v || e[17] !== s || e[18] !== M || e[19] !== g || e[20] !== t || e[21] !== H ? (C = g && M ? /* @__PURE__ */ r.jsx(Ce, { width: t || g, height: Math.max(v, o || (s ? v ? (t || g) * s > v ? (t || g) * s : v : (t || g) * s : M)), mapStyles: x, center: q, zoomLevel: H, mapLegend: R }) : null, e[12] = q, e[13] = o, e[14] = R, e[15] = x, e[16] = v, e[17] = s, e[18] = M, e[19] = g, e[20] = t, e[21] = H, e[22] = C) : C = e[22];
257
+ title: a?.title,
258
+ description: a?.description
259
+ }, graphTitle: i, graphDescription: s, width: o }) : null, e[4] = a?.description, e[5] = a?.title, e[6] = s, e[7] = i, e[8] = n?.description, e[9] = n?.title, e[10] = o, e[11] = d) : d = e[11];
260
+ let w;
261
+ e[12] !== V || e[13] !== P || e[14] !== v || e[15] !== _ || e[16] !== S || e[17] !== R ? (w = S && _ ? /* @__PURE__ */ t.jsx(Ce, { width: S, height: _, mapStyles: v, center: V, zoomLevel: R, mapLegend: P }) : null, e[12] = V, e[13] = P, e[14] = v, e[15] = _, e[16] = S, e[17] = R, e[18] = w) : w = e[18];
262
262
  let u;
263
- e[23] !== C ? (u = /* @__PURE__ */ r.jsx(xe, { ref: w, children: C }), e[23] = C, e[24] = u) : u = e[24];
263
+ e[19] !== w ? (u = /* @__PURE__ */ t.jsx(xe, { ref: y, children: w }), e[19] = w, e[20] = u) : u = e[20];
264
264
  let p;
265
- e[25] !== c?.footnote || e[26] !== c?.source || e[27] !== l || e[28] !== m || e[29] !== i?.footnote || e[30] !== i?.source || e[31] !== t ? (p = m || l ? /* @__PURE__ */ r.jsx(ye, { styles: {
266
- footnote: i?.footnote,
267
- source: i?.source
265
+ e[21] !== a?.footnote || e[22] !== a?.source || e[23] !== r || e[24] !== c || e[25] !== n?.footnote || e[26] !== n?.source || e[27] !== o ? (p = c || r ? /* @__PURE__ */ t.jsx(ye, { styles: {
266
+ footnote: n?.footnote,
267
+ source: n?.source
268
268
  }, classNames: {
269
- footnote: c?.footnote,
270
- source: c?.source
271
- }, sources: m, footNote: l, width: t }) : null, e[25] = c?.footnote, e[26] = c?.source, e[27] = l, e[28] = m, e[29] = i?.footnote, e[30] = i?.source, e[31] = t, e[32] = p) : p = e[32];
272
- let y;
273
- return e[33] !== A || e[34] !== V || e[35] !== b || e[36] !== o || e[37] !== E || e[38] !== v || e[39] !== f || e[40] !== s || e[41] !== I || e[42] !== d || e[43] !== u || e[44] !== p || e[45] !== j || e[46] !== L || e[47] !== t ? (y = /* @__PURE__ */ r.jsxs(we, { className: j, style: I, id: b, ref: B, "aria-label": A, backgroundColor: V, theme: L, language: E, minHeight: v, width: t, height: o, relativeHeight: s, padding: f, children: [
269
+ footnote: a?.footnote,
270
+ source: a?.source
271
+ }, sources: c, footNote: r, width: o }) : null, e[21] = a?.footnote, e[22] = a?.source, e[23] = r, e[24] = c, e[25] = n?.footnote, e[26] = n?.source, e[27] = o, e[28] = p) : p = e[28];
272
+ let b;
273
+ return e[29] !== $ || e[30] !== O || e[31] !== g || e[32] !== l || e[33] !== A || e[34] !== q || e[35] !== f || e[36] !== m || e[37] !== E || e[38] !== d || e[39] !== u || e[40] !== p || e[41] !== x || e[42] !== H || e[43] !== o ? (b = /* @__PURE__ */ t.jsxs(we, { className: x, style: E, id: g, ref: W, "aria-label": $, backgroundColor: O, theme: H, language: A, minHeight: q, width: o, height: l, relativeHeight: m, padding: f, children: [
274
274
  d,
275
275
  u,
276
276
  p
277
- ] }), e[33] = A, e[34] = V, e[35] = b, e[36] = o, e[37] = E, e[38] = v, e[39] = f, e[40] = s, e[41] = I, e[42] = d, e[43] = u, e[44] = p, e[45] = j, e[46] = L, e[47] = t, e[48] = y) : y = e[48], y;
277
+ ] }), e[29] = $, e[30] = O, e[31] = g, e[32] = l, e[33] = A, e[34] = q, e[35] = f, e[36] = m, e[37] = E, e[38] = d, e[39] = u, e[40] = p, e[41] = x, e[42] = H, e[43] = o, e[44] = b) : b = e[44], b;
278
278
  }
279
279
  export {
280
280
  $e as GeoHubCompareMaps