@undp/data-viz 2.3.13 → 2.3.15

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 (58) hide show
  1. package/dist/BiVariateChoroplethMap.cjs +1 -1
  2. package/dist/BiVariateChoroplethMap.cjs.map +1 -1
  3. package/dist/BiVariateChoroplethMap.d.ts +6 -0
  4. package/dist/BiVariateChoroplethMap.js +330 -297
  5. package/dist/BiVariateChoroplethMap.js.map +1 -1
  6. package/dist/ChoroplethMap.cjs +1 -1
  7. package/dist/ChoroplethMap.cjs.map +1 -1
  8. package/dist/ChoroplethMap.d.ts +6 -0
  9. package/dist/ChoroplethMap.js +359 -326
  10. package/dist/ChoroplethMap.js.map +1 -1
  11. package/dist/DotDensityMap.cjs +1 -1
  12. package/dist/DotDensityMap.cjs.map +1 -1
  13. package/dist/DotDensityMap.d.ts +8 -1
  14. package/dist/DotDensityMap.js +319 -286
  15. package/dist/DotDensityMap.js.map +1 -1
  16. package/dist/{GraphEl-Bb5oGHoa.js → GraphEl-BgNA-xFf.js} +10 -5
  17. package/dist/GraphEl-BgNA-xFf.js.map +1 -0
  18. package/dist/GraphEl-Bl1Hnqnd.cjs +2 -0
  19. package/dist/GraphEl-Bl1Hnqnd.cjs.map +1 -0
  20. package/dist/GriddedGraphs.cjs +1 -1
  21. package/dist/GriddedGraphs.d.ts +8 -1
  22. package/dist/GriddedGraphs.js +1 -1
  23. package/dist/GriddedGraphsFromConfig.d.ts +8 -1
  24. package/dist/HybridMap.cjs +1 -1
  25. package/dist/HybridMap.cjs.map +1 -1
  26. package/dist/HybridMap.d.ts +8 -1
  27. package/dist/HybridMap.js +416 -382
  28. package/dist/HybridMap.js.map +1 -1
  29. package/dist/MultiGraphDashboard.d.ts +8 -1
  30. package/dist/MultiGraphDashboardFromConfig.d.ts +8 -1
  31. package/dist/PerformanceIntensiveMultiGraphDashboard.d.ts +8 -1
  32. package/dist/PerformanceIntensiveMultiGraphDashboardFromConfig.d.ts +8 -1
  33. package/dist/PerformanceIntensiveScrollStory.d.ts +8 -1
  34. package/dist/ScatterPlot.cjs +1 -1
  35. package/dist/ScatterPlot.cjs.map +1 -1
  36. package/dist/ScatterPlot.d.ts +2 -0
  37. package/dist/ScatterPlot.js +408 -403
  38. package/dist/ScatterPlot.js.map +1 -1
  39. package/dist/ScrollStory.d.ts +8 -1
  40. package/dist/SingleGraphDashboard.cjs +1 -1
  41. package/dist/SingleGraphDashboard.d.ts +8 -1
  42. package/dist/SingleGraphDashboard.js +1 -1
  43. package/dist/SingleGraphDashboardFromConfig.d.ts +8 -1
  44. package/dist/SingleGraphDashboardGeoHubMaps.d.ts +8 -1
  45. package/dist/SingleGraphDashboardGeoHubMapsFromConfig.d.ts +8 -1
  46. package/dist/SingleGraphDashboardThreeDGraphs.d.ts +8 -1
  47. package/dist/SingleGraphDashboardThreeDGraphsFromConfig.d.ts +8 -1
  48. package/dist/StripChart.cjs +1 -1
  49. package/dist/StripChart.cjs.map +1 -1
  50. package/dist/StripChart.js +330 -334
  51. package/dist/StripChart.js.map +1 -1
  52. package/dist/Types.d.ts +9 -1
  53. package/dist/index.d.ts +36 -3
  54. package/dist/style.css +1 -1
  55. package/package.json +1 -1
  56. package/dist/GraphEl-Bb5oGHoa.js.map +0 -1
  57. package/dist/GraphEl-BerZfJ3j.cjs +0 -2
  58. package/dist/GraphEl-BerZfJ3j.cjs.map +0 -1
@@ -1,201 +1,219 @@
1
- import { j as o, m as Ot, c as Mt } from "./index-CHPV5EwG-BCLAYDCV.js";
2
- import { useMemo as It, useState as j, useRef as Ae, useEffect as tt, useEffectEvent as zt } from "react";
3
- import { g as Et, N as At } from "./getSliderMarks-vXsR8RrR.js";
4
- import { w as Pt } from "./Spinner-CtJETd5V.js";
5
- import { f as Bt, p as Lt } from "./parse-Dv4of-PN.js";
6
- import { i as _t } from "./index-Bwrro8-q.js";
7
- import { i as Wt, z as Ft, a as Tt, g as $t, b as Ht, c as Rt, d as Gt, e as Vt, f as Ut } from "./index-CKpKc9DR.js";
8
- import { i as Xt } from "./index-DCsFBfJ_.js";
9
- import { _ as vt } from "./Typography-DMVW6JnV.js";
10
- import { n as bt } from "./numberFormattingFunction-14YCbkN2.js";
11
- import { T as Yt } from "./Tooltip-CohiIbLZ.js";
12
- import { c as kt } from "./checkIfNullOrUndefined-DmfiKkNw.js";
13
- import { X as qt, P as Jt, e as Kt } from "./index-CZ0elhKR.js";
14
- import { D as Zt } from "./DetailsModal-C3qlUyFK.js";
15
- import { s as gt } from "./select-DKy99ogv.js";
16
- import { t as wt } from "./threshold-DFfqcDMa.js";
17
- import { m as et } from "./proxy--_f6k3NR.js";
18
- import { u as Qt } from "./use-in-view-DqvKAveg.js";
19
- import { A as eo } from "./index-Co3YGYe1.js";
20
- import { GraphHeader as to } from "./GraphHeader.js";
21
- import { GraphFooter as oo } from "./GraphFooter.js";
22
- import { Colors as yt } from "./Colors.js";
23
- import { f as ro } from "./fetchAndParseData-BAXhgTDM.js";
24
- import { g as Ct } from "./getJenks-DTCcQSDi.js";
25
- import { a as ao, G as no } from "./GraphContainer-DwMxWRCi.js";
26
- function io(n) {
1
+ import { j as o, m as Tt, c as $t } from "./index-CHPV5EwG-BCLAYDCV.js";
2
+ import { useMemo as St, useState as D, useRef as Ae, useEffect as _e, useEffectEvent as Nt } from "react";
3
+ import { g as Ht, N as Rt } from "./getSliderMarks-vXsR8RrR.js";
4
+ import { w as Gt } from "./Spinner-CtJETd5V.js";
5
+ import { f as Vt, p as Ut } from "./parse-Dv4of-PN.js";
6
+ import { i as Xt } from "./index-Bwrro8-q.js";
7
+ import { i as Mt, z as Yt, a as qt, g as Jt, b as Kt, c as Zt, d as Qt, e as eo, f as to } from "./index-CKpKc9DR.js";
8
+ import { i as oo } from "./index-DCsFBfJ_.js";
9
+ import { _ as Ot } from "./Typography-DMVW6JnV.js";
10
+ import { n as Bt } from "./numberFormattingFunction-14YCbkN2.js";
11
+ import { T as ro } from "./Tooltip-CohiIbLZ.js";
12
+ import { c as Et } from "./checkIfNullOrUndefined-DmfiKkNw.js";
13
+ import { X as ao, P as no, e as io } from "./index-CZ0elhKR.js";
14
+ import { D as so } from "./DetailsModal-C3qlUyFK.js";
15
+ import { s as Ct } from "./select-DKy99ogv.js";
16
+ import { t as It } from "./threshold-DFfqcDMa.js";
17
+ import { m as lt } from "./proxy--_f6k3NR.js";
18
+ import { u as lo } from "./use-in-view-DqvKAveg.js";
19
+ import { A as co } from "./index-Co3YGYe1.js";
20
+ import { GraphHeader as mo } from "./GraphHeader.js";
21
+ import { GraphFooter as po } from "./GraphFooter.js";
22
+ import { Colors as wt } from "./Colors.js";
23
+ import { f as zt } from "./fetchAndParseData-BAXhgTDM.js";
24
+ import { g as Wt } from "./getJenks-DTCcQSDi.js";
25
+ import { a as ho, G as fo } from "./GraphContainer-DwMxWRCi.js";
26
+ function uo(n) {
27
27
  const {
28
28
  data: e,
29
- xDomain: d,
30
- mapData: L,
29
+ xDomain: m,
30
+ mapData: F,
31
31
  xColorLegendTitle: Pe,
32
- yDomain: Y,
33
- yColorLegendTitle: q,
32
+ yDomain: Z,
33
+ yColorLegendTitle: Q,
34
34
  width: u,
35
35
  height: p,
36
36
  colors: h,
37
- scale: Be,
38
- centerPoint: k,
39
- mapBorderWidth: _,
40
- mapNoDataColor: J,
41
- mapBorderColor: pe,
42
- tooltip: K,
43
- onSeriesMouseOver: he,
44
- zoomScaleExtend: ue,
45
- zoomTranslateExtend: fe,
37
+ scale: Le,
38
+ centerPoint: C,
39
+ mapBorderWidth: M,
40
+ mapNoDataColor: ee,
41
+ mapBorderColor: te,
42
+ tooltip: oe,
43
+ onSeriesMouseOver: ue,
44
+ zoomScaleExtend: ge,
45
+ zoomTranslateExtend: ye,
46
46
  highlightedIds: w,
47
- onSeriesMouseClick: Z,
48
- mapProperty: N,
49
- resetSelectionOnDoubleClick: Le,
50
- detailsOnClick: y,
51
- showColorScale: ge,
52
- styles: _e,
53
- classNames: W,
54
- mapProjection: F,
55
- zoomInteraction: S,
56
- animate: O,
57
- dimmedOpacity: M,
58
- customLayers: Q,
59
- collapseColorScaleByDefault: ye,
60
- zoomAndCenterByHighlightedIds: xe,
61
- projectionRotate: T,
62
- rewindCoordinatesInMapData: ve
63
- } = n, x = It(() => ve ? Wt(L, {
47
+ onSeriesMouseClick: re,
48
+ mapProperty: O,
49
+ resetSelectionOnDoubleClick: Fe,
50
+ detailsOnClick: x,
51
+ showColorScale: ve,
52
+ styles: Te,
53
+ classNames: T,
54
+ mapProjection: $,
55
+ zoomInteraction: B,
56
+ animate: E,
57
+ dimmedOpacity: I,
58
+ customLayers: ae,
59
+ collapseColorScaleByDefault: xe,
60
+ zoomAndCenterByHighlightedIds: be,
61
+ projectionRotate: H,
62
+ rewindCoordinatesInMapData: U,
63
+ overlayMapData: X,
64
+ overlayMapBorderColor: $e,
65
+ overlayMapBorderWidth: He
66
+ } = n, v = St(() => U ? Mt(F, {
67
+ reverse: !0
68
+ }) : F, [F, U]), Re = St(() => !U || !X ? X : Mt(X, {
64
69
  reverse: !0
65
- }) : L, [L, ve]), [We, be] = j(ye === void 0 ? !(u < 680) : !ye), [$, ke] = j(void 0), [G, l] = j(void 0), [s, ee] = j(void 0), [we, te] = j(void 0), [Ce, H] = j(void 0), D = Ae(null), oe = Qt(D, {
66
- once: O.once,
67
- amount: O.amount
68
- }), je = Ae(null), R = Ae(null);
69
- tt(() => {
70
- const t = gt(je.current), r = gt(D.current), f = (m) => {
71
- if (S === "noZoom") return !1;
72
- if (S === "button") return !m.type.includes("wheel");
73
- const C = m.type === "wheel", v = m.type.startsWith("touch"), Ie = m.type === "mousedown" || m.type === "mousemove";
74
- return v ? !0 : C ? S === "scroll" ? !0 : m.ctrlKey : Ie && !m.button && !m.ctrlKey;
75
- }, b = Ft().scaleExtent(ue).translateExtent(fe || [[-20, -20], [u + 20, p + 20]]).filter(f).on("zoom", ({
76
- transform: m
70
+ }), [X, U]), [ke, c] = D(xe === void 0 ? !(u < 680) : !xe), [l, De] = D(void 0), [ne, ie] = D(void 0), [Y, R] = D(void 0), [q, J] = D(void 0), [Ce, G] = D(void 0), V = Ae(null), g = lo(V, {
71
+ once: E.once,
72
+ amount: E.amount
73
+ }), j = Ae(null), S = Ae(null);
74
+ _e(() => {
75
+ const t = Ct(j.current), r = Ct(V.current), d = (f) => {
76
+ if (B === "noZoom") return !1;
77
+ if (B === "button") return !f.type.includes("wheel");
78
+ const y = f.type === "wheel", b = f.type.startsWith("touch"), Ee = f.type === "mousedown" || f.type === "mousemove";
79
+ return b ? !0 : y ? B === "scroll" ? !0 : f.ctrlKey : Ee && !f.button && !f.ctrlKey;
80
+ }, k = Yt().scaleExtent(ge).translateExtent(ye || [[-20, -20], [u + 20, p + 20]]).filter(d).on("zoom", ({
81
+ transform: f
77
82
  }) => {
78
- t.attr("transform", m);
83
+ t.attr("transform", f);
79
84
  });
80
- r.call(b), R.current = b;
81
- }, [p, u, S]);
82
- const V = Tt({
83
- ...x,
84
- features: xe ? x.features.filter(
85
+ r.call(k), S.current = k;
86
+ }, [p, u, B]);
87
+ const z = qt({
88
+ ...v,
89
+ features: be ? v.features.filter(
85
90
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
86
- (t) => (w || []).length === 0 || w.indexOf(t.properties[N]) !== -1
87
- ) : x.features
88
- }), g = Xt({
89
- ...x,
90
- features: xe ? x.features.filter(
91
+ (t) => (w || []).length === 0 || w.indexOf(t.properties[O]) !== -1
92
+ ) : v.features
93
+ }), W = oo({
94
+ ...v,
95
+ features: be ? v.features.filter(
91
96
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
92
- (t) => (w || []).length === 0 || w.indexOf(t.properties[N]) !== -1
93
- ) : x.features
94
- }), I = (V[2] - V[0]) * 1.15, re = (V[3] - V[1]) * 1.15, De = u * 190 / 960 * 360 / I, Ne = p * 190 / 678 * 180 / re, z = Be * Math.min(De, Ne), Se = F === "mercator" ? $t().rotate(T).center(k || g.geometry.coordinates).translate([u / 2, p / 2]).scale(z) : F === "equalEarth" ? Ht().rotate(T).center(k || g.geometry.coordinates).translate([u / 2, p / 2]).scale(z) : F === "naturalEarth" ? Rt().rotate(T).center(k || g.geometry.coordinates).translate([u / 2, p / 2]).scale(z) : F === "orthographic" ? Gt().rotate(T).center(k || g.geometry.coordinates).translate([u / 2, p / 2]).scale(z) : Vt().rotate(T).center(k || g.geometry.coordinates).translate([u / 2, p / 2]).scale(z), U = Ut().projection(Se), Oe = Array.from({
95
- length: d.length
96
- }, (t, r) => r), Me = Array.from({
97
- length: Y.length
98
- }, (t, r) => r), ae = wt().domain(d).range(Oe), ne = wt().domain(Y).range(Me), ie = (t) => {
99
- if (!D.current || !R.current) return;
100
- gt(D.current).call(R.current.scaleBy, t === "in" ? 1.2 : 1 / 1.2);
97
+ (t) => (w || []).length === 0 || w.indexOf(t.properties[O]) !== -1
98
+ ) : v.features
99
+ }), we = (z[2] - z[0]) * 1.15, je = (z[3] - z[1]) * 1.15, Se = u * 190 / 960 * 360 / we, Ne = p * 190 / 678 * 180 / je, _ = Le * Math.min(Se, Ne), Me = $ === "mercator" ? Jt().rotate(H).center(C || W.geometry.coordinates).translate([u / 2, p / 2]).scale(_) : $ === "equalEarth" ? Kt().rotate(H).center(C || W.geometry.coordinates).translate([u / 2, p / 2]).scale(_) : $ === "naturalEarth" ? Zt().rotate(H).center(C || W.geometry.coordinates).translate([u / 2, p / 2]).scale(_) : $ === "orthographic" ? Qt().rotate(H).center(C || W.geometry.coordinates).translate([u / 2, p / 2]).scale(_) : eo().rotate(H).center(C || W.geometry.coordinates).translate([u / 2, p / 2]).scale(_), A = to().projection(Me), se = Array.from({
100
+ length: m.length
101
+ }, (t, r) => r), Oe = Array.from({
102
+ length: Z.length
103
+ }, (t, r) => r), Be = It().domain(m).range(se), le = It().domain(Z).range(Oe), ce = (t) => {
104
+ if (!V.current || !S.current) return;
105
+ Ct(V.current).call(S.current.scaleBy, t === "in" ? 1.2 : 1 / 1.2);
101
106
  };
102
107
  return /* @__PURE__ */ o.jsxs(o.Fragment, { children: [
103
108
  /* @__PURE__ */ o.jsxs("div", { className: "relative", children: [
104
- /* @__PURE__ */ o.jsx(et.svg, { viewBox: `0 0 ${u} ${p}`, width: `${u}px`, height: `${p}px`, ref: D, direction: "ltr", children: /* @__PURE__ */ o.jsxs("g", { ref: je, children: [
105
- Q.filter((t) => t.position === "before").map((t) => t.layer),
106
- x.features.map((t, r) => {
107
- if (!t.properties?.[N]) return null;
108
- const f = U(t);
109
- return f ? /* @__PURE__ */ o.jsx(et.g, { opacity: $ ? M : w.length !== 0 ? w.indexOf(t.properties[N]) !== -1 ? 1 : M : 1, children: /* @__PURE__ */ o.jsx("path", { d: f, style: {
110
- stroke: pe,
111
- strokeWidth: _,
112
- fill: J
109
+ /* @__PURE__ */ o.jsx(lt.svg, { viewBox: `0 0 ${u} ${p}`, width: `${u}px`, height: `${p}px`, ref: V, direction: "ltr", children: /* @__PURE__ */ o.jsxs("g", { ref: j, children: [
110
+ ae.filter((t) => t.position === "before").map((t) => t.layer),
111
+ v.features.map((t, r) => {
112
+ if (!t.properties?.[O]) return null;
113
+ const d = A(t);
114
+ return d ? /* @__PURE__ */ o.jsx(lt.g, { opacity: l ? I : w.length !== 0 ? w.indexOf(t.properties[O]) !== -1 ? 1 : I : 1, children: /* @__PURE__ */ o.jsx("path", { d, style: {
115
+ stroke: te,
116
+ strokeWidth: M,
117
+ fill: ee,
118
+ vectorEffect: "non-scaling-stroke"
113
119
  } }) }, r) : null;
114
120
  }),
115
- /* @__PURE__ */ o.jsx(eo, { children: e.map((t) => {
116
- const r = x.features.findIndex(
121
+ /* @__PURE__ */ o.jsx(co, { children: e.map((t) => {
122
+ const r = v.features.findIndex(
117
123
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
118
- (v) => t.id === v.properties[N]
124
+ (b) => t.id === b.properties[O]
119
125
  );
120
126
  if (r === -1) return null;
121
- const f = U(x.features[r]);
122
- if (!f) return null;
123
- const b = kt(t.x) ? void 0 : ae(t.x), m = kt(t.y) ? void 0 : ne(t.y), C = b !== void 0 && m !== void 0 ? h[m][b] : J;
124
- return /* @__PURE__ */ o.jsx(et.g, { className: "undp-map-shapes", variants: {
127
+ const d = A(v.features[r]);
128
+ if (!d) return null;
129
+ const k = Et(t.x) ? void 0 : Be(t.x), f = Et(t.y) ? void 0 : le(t.y), y = k !== void 0 && f !== void 0 ? h[f][k] : ee;
130
+ return /* @__PURE__ */ o.jsx(lt.g, { className: "undp-map-shapes", variants: {
125
131
  initial: {
126
132
  opacity: 0
127
133
  },
128
134
  whileInView: {
129
- opacity: $ ? $ === C ? 1 : M : w.length !== 0 ? w.indexOf(t.id) !== -1 ? 1 : M : 1,
135
+ opacity: l ? l === y ? 1 : I : w.length !== 0 ? w.indexOf(t.id) !== -1 ? 1 : I : 1,
130
136
  transition: {
131
- duration: O.duration
137
+ duration: E.duration
132
138
  }
133
139
  }
134
- }, initial: "initial", animate: oe ? "whileInView" : "initial", exit: {
140
+ }, initial: "initial", animate: g ? "whileInView" : "initial", exit: {
135
141
  opacity: 0,
136
142
  transition: {
137
- duration: O.duration
143
+ duration: E.duration
138
144
  }
139
- }, onMouseEnter: (v) => {
140
- ee(t), H(v.clientY), te(v.clientX), he?.(t);
145
+ }, onMouseEnter: (b) => {
146
+ R(t), G(b.clientY), J(b.clientX), ue?.(t);
141
147
  }, onClick: () => {
142
- (Z || y) && (_t(G, t) && Le ? (l(void 0), Z?.(void 0)) : (l(t), Z?.(t)));
143
- }, onMouseMove: (v) => {
144
- ee(t), H(v.clientY), te(v.clientX);
148
+ (re || x) && (Xt(ne, t) && Fe ? (ie(void 0), re?.(void 0)) : (ie(t), re?.(t)));
149
+ }, onMouseMove: (b) => {
150
+ R(t), G(b.clientY), J(b.clientX);
145
151
  }, onMouseLeave: () => {
146
- ee(void 0), te(void 0), H(void 0), he?.(void 0);
147
- }, children: /* @__PURE__ */ o.jsx(et.path, { d: f, variants: {
152
+ R(void 0), J(void 0), G(void 0), ue?.(void 0);
153
+ }, children: /* @__PURE__ */ o.jsx(lt.path, { d, variants: {
148
154
  initial: {
149
- fill: C,
155
+ fill: y,
150
156
  opacity: 0
151
157
  },
152
158
  whileInView: {
153
- fill: C,
159
+ fill: y,
154
160
  opacity: 1,
155
161
  transition: {
156
- duration: O.duration
162
+ duration: E.duration
157
163
  }
158
164
  }
159
- }, initial: "initial", animate: oe ? "whileInView" : "initial", exit: {
165
+ }, initial: "initial", animate: g ? "whileInView" : "initial", exit: {
160
166
  opacity: 0,
161
167
  transition: {
162
- duration: O.duration
168
+ duration: E.duration
163
169
  }
164
- }, className: `${C === J ? "stroke-primary-gray-400 dark:stroke-primary-gray-500" : "stroke-primary-white dark:stroke-primary-gray-650"}`, style: {
165
- stroke: pe,
166
- strokeWidth: _
170
+ }, className: `${y === ee ? "stroke-primary-gray-400 dark:stroke-primary-gray-500" : "stroke-primary-white dark:stroke-primary-gray-650"}`, style: {
171
+ stroke: te,
172
+ strokeWidth: M,
173
+ vectorEffect: "non-scaling-stroke"
167
174
  } }, `${t.id}`) }, t.id);
168
175
  }) }),
169
- s ? x.features.filter(
176
+ Y ? v.features.filter(
170
177
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
171
- (t) => t.properties[N] === s.id
172
- ).map((t, r) => /* @__PURE__ */ o.jsx("path", { d: U(t) || "", className: "stroke-primary-gray-700 dark:stroke-primary-gray-300", style: {
178
+ (t) => t.properties[O] === Y.id
179
+ ).map((t, r) => /* @__PURE__ */ o.jsx("path", { d: A(t) || "", className: "stroke-primary-gray-700 dark:stroke-primary-gray-300", style: {
173
180
  fill: "none",
174
181
  fillOpacity: 0,
175
- strokeWidth: "0.5"
182
+ strokeWidth: "0.5",
183
+ vectorEffect: "non-scaling-stroke"
176
184
  } }, r)) : null,
177
- Q.filter((t) => t.position === "after").map((t) => t.layer)
185
+ Re?.features.map((t, r) => {
186
+ const d = A(t);
187
+ return d ? /* @__PURE__ */ o.jsx("g", { children: /* @__PURE__ */ o.jsx("path", { d, style: {
188
+ stroke: $e || te,
189
+ strokeWidth: He || M + 1,
190
+ fill: "none",
191
+ pointerEvents: "none",
192
+ vectorEffect: "non-scaling-stroke"
193
+ } }) }, r) : null;
194
+ }),
195
+ ae.filter((t) => t.position === "after").map((t) => t.layer)
178
196
  ] }) }),
179
- ge === !1 ? null : /* @__PURE__ */ o.jsx("div", { className: Ot("absolute left-4 bottom-4 map-color-legend", W?.colorLegend), children: We ? /* @__PURE__ */ o.jsxs(o.Fragment, { children: [
197
+ ve === !1 ? null : /* @__PURE__ */ o.jsx("div", { className: Tt("absolute left-4 bottom-4 map-color-legend", T?.colorLegend), children: ke ? /* @__PURE__ */ o.jsxs(o.Fragment, { children: [
180
198
  /* @__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: () => {
181
- be(!1);
182
- }, children: /* @__PURE__ */ o.jsx(qt, {}) }),
199
+ c(!1);
200
+ }, children: /* @__PURE__ */ o.jsx(ao, {}) }),
183
201
  /* @__PURE__ */ o.jsxs("div", { className: "color-legend-box p-2 bg-[rgba(240,240,240,0.7)] dark:bg-[rgba(30,30,30,0.7)]", style: {
184
202
  width: "175px"
185
203
  }, children: [
186
204
  /* @__PURE__ */ o.jsxs("div", { className: "flex gap-1 items-center", children: [
187
205
  /* @__PURE__ */ o.jsx("svg", { width: "136px", viewBox: "0 0 136 136", className: "shrink-0", children: /* @__PURE__ */ o.jsxs("g", { children: [
188
- h.map((t, r) => /* @__PURE__ */ o.jsx("g", { transform: `translate(0,${100 - r * 25})`, children: t.map((f, b) => /* @__PURE__ */ o.jsx("rect", { y: 1, x: b * 25 + 1, fill: f, width: 23, height: 23, strokeWidth: $ === f ? 2 : 0.25, style: {
206
+ h.map((t, r) => /* @__PURE__ */ o.jsx("g", { transform: `translate(0,${100 - r * 25})`, children: t.map((d, k) => /* @__PURE__ */ o.jsx("rect", { y: 1, x: k * 25 + 1, fill: d, width: 23, height: 23, strokeWidth: l === d ? 2 : 0.25, style: {
189
207
  cursor: "pointer"
190
208
  }, onMouseOver: () => {
191
- ke(f);
209
+ De(d);
192
210
  }, onMouseLeave: () => {
193
- ke(void 0);
194
- } }, b)) }, r)),
195
- /* @__PURE__ */ o.jsx("g", { transform: "translate(0,125)", children: d.map((t, r) => /* @__PURE__ */ o.jsx("text", { y: 10, x: (r + 1) * 25, fontSize: 10, textAnchor: "middle", children: typeof t == "string" || t < 1 ? t : bt(t, "NA") }, r)) }),
196
- Y.map((t, r) => /* @__PURE__ */ o.jsx("g", { transform: `translate(${Math.max(Math.min(d.length + 1, 5), 4) * 25 + 10},${100 - r * 25})`, children: /* @__PURE__ */ o.jsx("text", { x: 0, transform: "rotate(-90)", y: 0, fontSize: 10, textAnchor: "middle", children: typeof t == "string" || t < 1 ? t : bt(t, "NA") }) }, r))
211
+ De(void 0);
212
+ } }, k)) }, r)),
213
+ /* @__PURE__ */ o.jsx("g", { transform: "translate(0,125)", children: m.map((t, r) => /* @__PURE__ */ o.jsx("text", { y: 10, x: (r + 1) * 25, fontSize: 10, textAnchor: "middle", children: typeof t == "string" || t < 1 ? t : Bt(t, "NA") }, r)) }),
214
+ Z.map((t, r) => /* @__PURE__ */ o.jsx("g", { transform: `translate(${Math.max(Math.min(m.length + 1, 5), 4) * 25 + 10},${100 - r * 25})`, children: /* @__PURE__ */ o.jsx("text", { x: 0, transform: "rotate(-90)", y: 0, fontSize: 10, textAnchor: "middle", children: typeof t == "string" || t < 1 ? t : Bt(t, "NA") }) }, r))
197
215
  ] }) }),
198
- /* @__PURE__ */ o.jsx(vt, { marginBottom: "none", size: "xs", className: "leading-normal text-center shrink-0", style: {
216
+ /* @__PURE__ */ o.jsx(Ot, { marginBottom: "none", size: "xs", className: "leading-normal text-center shrink-0", style: {
199
217
  display: "-webkit-box",
200
218
  WebkitLineClamp: "1",
201
219
  WebkitBoxOrient: "vertical",
@@ -203,9 +221,9 @@ function io(n) {
203
221
  writingMode: "vertical-rl",
204
222
  height: "8.5rem",
205
223
  transform: "rotate(180deg)"
206
- }, children: q })
224
+ }, children: Q })
207
225
  ] }),
208
- /* @__PURE__ */ o.jsx(vt, { marginBottom: "none", size: "xs", className: "mt-1 leading-normal text-center", style: {
226
+ /* @__PURE__ */ o.jsx(Ot, { marginBottom: "none", size: "xs", className: "mt-1 leading-normal text-center", style: {
209
227
  display: "-webkit-box",
210
228
  WebkitLineClamp: "1",
211
229
  width: "8.5rem",
@@ -214,213 +232,228 @@ function io(n) {
214
232
  }, children: Pe })
215
233
  ] })
216
234
  ] }) : /* @__PURE__ */ o.jsx("button", { type: "button", className: "mb-0 border-0 bg-transparent p-0 self-start", onClick: () => {
217
- be(!0);
235
+ c(!0);
218
236
  }, 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" }) }) }),
219
- S === "button" && /* @__PURE__ */ o.jsxs("div", { className: "absolute left-4 top-4 flex flex-col zoom-buttons", children: [
220
- /* @__PURE__ */ o.jsx("button", { onClick: () => ie("in"), className: "leading-0 px-2 py-3.5 border text-primary-gray-700 border-primary-gray-400 bg-primary-gray-200 dark:border-primary-gray-550 dark:bg-primary-gray-600 dark:text-primary-gray-100", children: "+" }),
221
- /* @__PURE__ */ o.jsx("button", { onClick: () => ie("out"), className: "leading-0 px-2 py-3.5 border text-primary-gray-700 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: "–" })
237
+ B === "button" && /* @__PURE__ */ o.jsxs("div", { className: "absolute left-4 top-4 flex flex-col zoom-buttons", children: [
238
+ /* @__PURE__ */ o.jsx("button", { onClick: () => ce("in"), className: "leading-0 px-2 py-3.5 border text-primary-gray-700 border-primary-gray-400 bg-primary-gray-200 dark:border-primary-gray-550 dark:bg-primary-gray-600 dark:text-primary-gray-100", children: "+" }),
239
+ /* @__PURE__ */ o.jsx("button", { onClick: () => ce("out"), className: "leading-0 px-2 py-3.5 border text-primary-gray-700 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: "–" })
222
240
  ] })
223
241
  ] }),
224
- s && K && we && Ce ? /* @__PURE__ */ o.jsx(Yt, { data: s, body: K, xPos: we, yPos: Ce, backgroundStyle: _e?.tooltip, className: W?.tooltip }) : null,
225
- y && G !== void 0 ? /* @__PURE__ */ o.jsx(Zt, { body: y, data: G, setData: l, className: W?.modal }) : null
242
+ Y && oe && q && Ce ? /* @__PURE__ */ o.jsx(ro, { data: Y, body: oe, xPos: q, yPos: Ce, backgroundStyle: Te?.tooltip, className: T?.tooltip }) : null,
243
+ x && ne !== void 0 ? /* @__PURE__ */ o.jsx(so, { body: x, data: ne, setData: ie, className: T?.modal }) : null
226
244
  ] });
227
245
  }
228
- function Ro(n) {
229
- const e = Mt.c(121), {
230
- data: d,
231
- graphTitle: L,
246
+ function Ko(n) {
247
+ const e = $t.c(130), {
248
+ data: m,
249
+ graphTitle: F,
232
250
  mapData: Pe,
233
- colors: Y,
234
- sources: q,
251
+ colors: Z,
252
+ sources: Q,
235
253
  graphDescription: u,
236
254
  height: p,
237
255
  width: h,
238
- footNote: Be,
239
- xDomain: k,
240
- yDomain: _,
241
- xColorLegendTitle: J,
242
- yColorLegendTitle: pe,
243
- tooltip: K,
244
- scale: he,
245
- centerPoint: ue,
246
- padding: fe,
256
+ footNote: Le,
257
+ xDomain: C,
258
+ yDomain: M,
259
+ xColorLegendTitle: ee,
260
+ yColorLegendTitle: te,
261
+ tooltip: oe,
262
+ scale: ue,
263
+ centerPoint: ge,
264
+ padding: ye,
247
265
  mapBorderWidth: w,
248
- mapNoDataColor: Z,
249
- backgroundColor: N,
250
- mapBorderColor: Le,
251
- relativeHeight: y,
252
- onSeriesMouseOver: ge,
253
- isWorldMap: _e,
254
- zoomScaleExtend: W,
255
- zoomTranslateExtend: F,
256
- graphID: S,
257
- showColorScale: O,
258
- highlightedIds: M,
259
- onSeriesMouseClick: Q,
260
- mapProperty: ye,
261
- graphDownload: xe,
262
- dataDownload: T,
263
- showAntarctica: ve,
264
- language: x,
265
- minHeight: We,
266
- theme: be,
267
- ariaLabel: $,
268
- resetSelectionOnDoubleClick: ke,
269
- detailsOnClick: G,
270
- styles: l,
271
- classNames: s,
272
- mapProjection: ee,
273
- zoomInteraction: we,
274
- animate: te,
275
- dimmedOpacity: Ce,
276
- customLayers: H,
277
- timeline: D,
278
- collapseColorScaleByDefault: oe,
279
- zoomAndCenterByHighlightedIds: je,
280
- projectionRotate: R,
281
- rewindCoordinatesInMapData: V
282
- } = n, g = Pe === void 0 ? "https://raw.githubusercontent.com/UNDP-Data/dv-country-geojson/refs/heads/main/worldMap-v2.json" : Pe, I = Y === void 0 ? yt.light.bivariateColors.colors05x05 : Y, re = Be === 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." : Be, De = J === void 0 ? "X Color key" : J, Ne = pe === void 0 ? "Y Color key" : pe, z = he === void 0 ? 0.95 : he, Se = w === void 0 ? 0.5 : w, U = Z === void 0 ? yt.light.graphNoData : Z, Oe = N === void 0 ? !1 : N, Me = Le === void 0 ? yt.light.grays["gray-500"] : Le, ae = _e === void 0 ? !0 : _e;
283
- let ne;
284
- e[0] !== W ? (ne = W === void 0 ? [0.8, 6] : W, e[0] = W, e[1] = ne) : ne = e[1];
285
- const ie = ne, t = O === void 0 ? !0 : O;
286
- let r;
287
- e[2] !== M ? (r = M === void 0 ? [] : M, e[2] = M, e[3] = r) : r = e[3];
288
- const f = r, b = ye === void 0 ? "ISO3" : ye, m = xe === void 0 ? !1 : xe, C = T === void 0 ? !1 : T, v = ve === void 0 ? !1 : ve, Ie = x === void 0 ? "en" : x, E = We === void 0 ? 0 : We, ot = be === void 0 ? "light" : be, rt = ke === void 0 ? !0 : ke, at = ee === void 0 ? "naturalEarth" : ee, nt = we === void 0 ? "button" : we, Fe = te === void 0 ? !1 : te, it = Ce === void 0 ? 0.3 : Ce;
289
- let Te;
290
- e[4] !== H ? (Te = H === void 0 ? [] : H, e[4] = H, e[5] = Te) : Te = e[5];
291
- const st = Te;
292
- let $e;
293
- e[6] !== D ? ($e = D === void 0 ? {
266
+ mapNoDataColor: re,
267
+ backgroundColor: O,
268
+ mapBorderColor: Fe,
269
+ relativeHeight: x,
270
+ onSeriesMouseOver: ve,
271
+ isWorldMap: Te,
272
+ zoomScaleExtend: T,
273
+ zoomTranslateExtend: $,
274
+ graphID: B,
275
+ showColorScale: E,
276
+ highlightedIds: I,
277
+ onSeriesMouseClick: ae,
278
+ mapProperty: xe,
279
+ graphDownload: be,
280
+ dataDownload: H,
281
+ showAntarctica: U,
282
+ language: X,
283
+ minHeight: $e,
284
+ theme: He,
285
+ ariaLabel: v,
286
+ resetSelectionOnDoubleClick: Re,
287
+ detailsOnClick: ke,
288
+ styles: c,
289
+ classNames: l,
290
+ mapProjection: De,
291
+ zoomInteraction: ne,
292
+ animate: ie,
293
+ dimmedOpacity: Y,
294
+ customLayers: R,
295
+ timeline: q,
296
+ collapseColorScaleByDefault: J,
297
+ zoomAndCenterByHighlightedIds: Ce,
298
+ projectionRotate: G,
299
+ rewindCoordinatesInMapData: V,
300
+ mapOverlay: g
301
+ } = n, j = Pe === void 0 ? "https://raw.githubusercontent.com/UNDP-Data/dv-country-geojson/refs/heads/main/worldMap-v2.json" : Pe, S = Z === void 0 ? wt.light.bivariateColors.colors05x05 : Z, z = Le === 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." : Le, W = ee === void 0 ? "X Color key" : ee, we = te === void 0 ? "Y Color key" : te, je = ue === void 0 ? 0.95 : ue, Se = w === void 0 ? 0.5 : w, Ne = re === void 0 ? wt.light.graphNoData : re, _ = O === void 0 ? !1 : O, Me = Fe === void 0 ? wt.light.grays["gray-500"] : Fe, A = Te === void 0 ? !0 : Te;
302
+ let se;
303
+ e[0] !== T ? (se = T === void 0 ? [0.8, 6] : T, e[0] = T, e[1] = se) : se = e[1];
304
+ const Oe = se, Be = E === void 0 ? !0 : E;
305
+ let le;
306
+ e[2] !== I ? (le = I === void 0 ? [] : I, e[2] = I, e[3] = le) : le = e[3];
307
+ const ce = le, t = xe === void 0 ? "ISO3" : xe, r = be === void 0 ? !1 : be, d = H === void 0 ? !1 : H, k = U === void 0 ? !1 : U, f = X === void 0 ? "en" : X, y = $e === void 0 ? 0 : $e, b = He === void 0 ? "light" : He, Ee = Re === void 0 ? !0 : Re, ct = De === void 0 ? "naturalEarth" : De, dt = ne === void 0 ? "button" : ne, Ge = ie === void 0 ? !1 : ie, mt = Y === void 0 ? 0.3 : Y;
308
+ let Ve;
309
+ e[4] !== R ? (Ve = R === void 0 ? [] : R, e[4] = R, e[5] = Ve) : Ve = e[5];
310
+ const pt = Ve;
311
+ let Ue;
312
+ e[6] !== q ? (Ue = q === void 0 ? {
294
313
  enabled: !1,
295
314
  autoplay: !1,
296
315
  showOnlyActiveDate: !0
297
- } : D, e[6] = D, e[7] = $e) : $e = e[7];
298
- const a = $e, lt = je === void 0 ? !1 : je;
299
- let He;
300
- e[8] !== R ? (He = R === void 0 ? [0, 0] : R, e[8] = R, e[9] = He) : He = e[9];
301
- const ct = He, dt = V === void 0 ? !0 : V, [X, jt] = j(0), [ze, Dt] = j(0), [A, Nt] = j(a.autoplay);
302
- let Ee;
303
- if (e[10] !== d || e[11] !== a.dateFormat) {
304
- let c;
305
- e[13] !== a.dateFormat ? (c = (B) => Lt(`${B.date}`, a.dateFormat || "yyyy", /* @__PURE__ */ new Date()).getTime(), e[13] = a.dateFormat, e[14] = c) : c = e[14], Ee = [...new Set(d.filter(yo).map(c))], Ee.sort(go), e[10] = d, e[11] = a.dateFormat, e[12] = Ee;
316
+ } : q, e[6] = q, e[7] = Ue) : Ue = e[7];
317
+ const a = Ue, ht = Ce === void 0 ? !1 : Ce;
318
+ let Xe;
319
+ e[8] !== G ? (Xe = G === void 0 ? [0, 0] : G, e[8] = G, e[9] = Xe) : Xe = e[9];
320
+ const ft = Xe, ut = V === void 0 ? !0 : V, [K, _t] = D(0), [Ie, At] = D(0), [P, Pt] = D(a.autoplay);
321
+ let ze;
322
+ if (e[10] !== m || e[11] !== a.dateFormat) {
323
+ let i;
324
+ e[13] !== a.dateFormat ? (i = (N) => Ut(`${N.date}`, a.dateFormat || "yyyy", /* @__PURE__ */ new Date()).getTime(), e[13] = a.dateFormat, e[14] = i) : i = e[14], ze = [...new Set(m.filter(jo).map(i))], ze.sort(wo), e[10] = m, e[11] = a.dateFormat, e[12] = ze;
306
325
  } else
307
- Ee = e[12];
308
- const i = Ee, [P, mt] = j(a.autoplay ? 0 : i.length - 1), [se, St] = j(void 0), pt = Ae(null), xt = Ae(null);
309
- let Re, Ge;
310
- e[15] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (Re = () => {
311
- const c = new ResizeObserver((B) => {
312
- jt(B[0].target.clientWidth || 620), Dt(B[0].target.clientHeight || 480);
326
+ ze = e[12];
327
+ const s = ze, [L, gt] = D(a.autoplay ? 0 : s.length - 1), [de, Lt] = D(void 0), [yt, Ft] = D(void 0), vt = Ae(null), jt = Ae(null);
328
+ let Ye, qe;
329
+ e[15] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (Ye = () => {
330
+ const i = new ResizeObserver((N) => {
331
+ _t(N[0].target.clientWidth || 620), At(N[0].target.clientHeight || 480);
313
332
  });
314
- return pt.current && c.observe(pt.current), () => c.disconnect();
315
- }, Ge = [], e[15] = Re, e[16] = Ge) : (Re = e[15], Ge = e[16]), tt(Re, Ge);
316
- let Ve;
317
- e[17] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (Ve = (c) => {
318
- St(c);
319
- }, e[17] = Ve) : Ve = e[17];
320
- const Ue = zt(Ve);
321
- let Xe;
322
- e[18] !== g || e[19] !== Ue ? (Xe = () => {
323
- typeof g == "string" ? ro(g).then((B) => {
324
- Ue(B);
325
- }) : Ue(g);
326
- }, e[18] = g, e[19] = Ue, e[20] = Xe) : Xe = e[20];
327
- let Ye;
328
- e[21] !== g ? (Ye = [g], e[21] = g, e[22] = Ye) : Ye = e[22], tt(Xe, Ye);
329
- let qe, Je;
330
- e[23] !== A || e[24] !== a.speed || e[25] !== i ? (qe = () => {
331
- const c = setInterval(() => {
332
- mt((B) => B < i.length - 1 ? B + 1 : 0);
333
+ return vt.current && i.observe(vt.current), () => i.disconnect();
334
+ }, qe = [], e[15] = Ye, e[16] = qe) : (Ye = e[15], qe = e[16]), _e(Ye, qe);
335
+ let Je;
336
+ e[17] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (Je = (i) => {
337
+ Lt(i);
338
+ }, e[17] = Je) : Je = e[17];
339
+ const Ke = Nt(Je);
340
+ let Ze;
341
+ e[18] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (Ze = (i) => {
342
+ Ft(i);
343
+ }, e[18] = Ze) : Ze = e[18];
344
+ const We = Nt(Ze);
345
+ let Qe;
346
+ e[19] !== j || e[20] !== Ke ? (Qe = () => {
347
+ typeof j == "string" ? zt(j).then((N) => {
348
+ Ke(N);
349
+ }) : Ke(j);
350
+ }, e[19] = j, e[20] = Ke, e[21] = Qe) : Qe = e[21];
351
+ let et;
352
+ e[22] !== j ? (et = [j], e[22] = j, e[23] = et) : et = e[23], _e(Qe, et);
353
+ let tt;
354
+ e[24] !== g?.mapData || e[25] !== We ? (tt = () => {
355
+ g?.mapData || We(void 0), typeof g?.mapData == "string" ? zt(g?.mapData).then((N) => {
356
+ We(N);
357
+ }) : We(g?.mapData);
358
+ }, e[24] = g?.mapData, e[25] = We, e[26] = tt) : tt = e[26];
359
+ const xt = g?.mapData;
360
+ let ot;
361
+ e[27] !== xt ? (ot = [xt], e[27] = xt, e[28] = ot) : ot = e[28], _e(tt, ot);
362
+ let rt, at;
363
+ e[29] !== P || e[30] !== a.speed || e[31] !== s ? (rt = () => {
364
+ const i = setInterval(() => {
365
+ gt((N) => N < s.length - 1 ? N + 1 : 0);
333
366
  }, (a.speed || 2) * 1e3);
334
- return A || clearInterval(c), () => clearInterval(c);
335
- }, Je = [i, A, a.speed], e[23] = A, e[24] = a.speed, e[25] = i, e[26] = qe, e[27] = Je) : (qe = e[26], Je = e[27]), tt(qe, Je);
336
- const ht = a.dateFormat || "yyyy";
337
- let Ke;
338
- e[28] !== P || e[29] !== ht || e[30] !== a.showOnlyActiveDate || e[31] !== i ? (Ke = Et(i, P, a.showOnlyActiveDate, ht), e[28] = P, e[29] = ht, e[30] = a.showOnlyActiveDate, e[31] = i, e[32] = Ke) : Ke = e[32];
339
- const Ze = Ke;
340
- if (k && _ && (k.length !== I[0].length - 1 || _.length !== I.length - 1))
367
+ return P || clearInterval(i), () => clearInterval(i);
368
+ }, at = [s, P, a.speed], e[29] = P, e[30] = a.speed, e[31] = s, e[32] = rt, e[33] = at) : (rt = e[32], at = e[33]), _e(rt, at);
369
+ const bt = a.dateFormat || "yyyy";
370
+ let nt;
371
+ e[34] !== L || e[35] !== bt || e[36] !== a.showOnlyActiveDate || e[37] !== s ? (nt = Ht(s, L, a.showOnlyActiveDate, bt), e[34] = L, e[35] = bt, e[36] = a.showOnlyActiveDate, e[37] = s, e[38] = nt) : nt = e[38];
372
+ const it = nt;
373
+ if (C && M && (C.length !== S[0].length - 1 || M.length !== S.length - 1))
341
374
  return console.error("the xDomain and yDomain array length don't match to the color array length"), null;
342
- const ut = s?.graphContainer, ft = l?.graphContainer;
343
- let le;
344
- e[33] !== s?.description || e[34] !== s?.title || e[35] !== d || e[36] !== C || e[37] !== u || e[38] !== m || e[39] !== L || e[40] !== l?.description || e[41] !== l?.title || e[42] !== h ? (le = L || u || m || C ? /* @__PURE__ */ o.jsx(to, { styles: {
375
+ const kt = l?.graphContainer, Dt = c?.graphContainer;
376
+ let me;
377
+ e[39] !== l?.description || e[40] !== l?.title || e[41] !== m || e[42] !== d || e[43] !== u || e[44] !== r || e[45] !== F || e[46] !== c?.description || e[47] !== c?.title || e[48] !== h ? (me = F || u || r || d ? /* @__PURE__ */ o.jsx(mo, { styles: {
378
+ title: c?.title,
379
+ description: c?.description
380
+ }, classNames: {
345
381
  title: l?.title,
346
382
  description: l?.description
347
- }, classNames: {
348
- title: s?.title,
349
- description: s?.description
350
- }, graphTitle: L, graphDescription: u, width: h, graphDownload: m ? xt : void 0, dataDownload: C ? d.map(fo).filter(uo).length > 0 ? d.map(ho).filter(po) : d.filter(mo) : null }) : null, e[33] = s?.description, e[34] = s?.title, e[35] = d, e[36] = C, e[37] = u, e[38] = m, e[39] = L, e[40] = l?.description, e[41] = l?.title, e[42] = h, e[43] = le) : le = e[43];
351
- let ce;
352
- e[44] !== P || e[45] !== Ze || e[46] !== A || e[47] !== a.enabled || e[48] !== i ? (ce = a.enabled && i.length > 0 && Ze ? /* @__PURE__ */ o.jsxs("div", { className: "flex gap-6 items-center", dir: "ltr", children: [
383
+ }, graphTitle: F, graphDescription: u, width: h, graphDownload: r ? jt : void 0, dataDownload: d ? m.map(Co).filter(Do).length > 0 ? m.map(ko).filter(bo) : m.filter(xo) : null }) : null, e[39] = l?.description, e[40] = l?.title, e[41] = m, e[42] = d, e[43] = u, e[44] = r, e[45] = F, e[46] = c?.description, e[47] = c?.title, e[48] = h, e[49] = me) : me = e[49];
384
+ let pe;
385
+ e[50] !== L || e[51] !== it || e[52] !== P || e[53] !== a.enabled || e[54] !== s ? (pe = a.enabled && s.length > 0 && it ? /* @__PURE__ */ o.jsxs("div", { className: "flex gap-6 items-center", dir: "ltr", children: [
353
386
  /* @__PURE__ */ o.jsx("button", { type: "button", onClick: () => {
354
- Nt(!A);
355
- }, className: "p-0 border-0 cursor-pointer bg-transparent", "aria-label": A ? "Click to pause animation" : "Click to play animation", children: A ? /* @__PURE__ */ o.jsx(Jt, {}) : /* @__PURE__ */ o.jsx(Kt, {}) }),
356
- /* @__PURE__ */ o.jsx(At, { min: i[0], max: i[i.length - 1], marks: Ze, step: null, defaultValue: i[i.length - 1], value: i[P], onChangeComplete: (c) => {
357
- mt(i.indexOf(c));
358
- }, onChange: (c) => {
359
- mt(i.indexOf(c));
387
+ Pt(!P);
388
+ }, className: "p-0 border-0 cursor-pointer bg-transparent", "aria-label": P ? "Click to pause animation" : "Click to play animation", children: P ? /* @__PURE__ */ o.jsx(no, {}) : /* @__PURE__ */ o.jsx(io, {}) }),
389
+ /* @__PURE__ */ o.jsx(Rt, { min: s[0], max: s[s.length - 1], marks: it, step: null, defaultValue: s[s.length - 1], value: s[L], onChangeComplete: (i) => {
390
+ gt(s.indexOf(i));
391
+ }, onChange: (i) => {
392
+ gt(s.indexOf(i));
360
393
  }, "aria-label": "Time slider. Use arrow keys to adjust selected time period." })
361
- ] }) : null, e[44] = P, e[45] = Ze, e[46] = A, e[47] = a.enabled, e[48] = i, e[49] = ce) : ce = e[49];
362
- let de;
363
- e[50] !== Fe || e[51] !== ue || e[52] !== s || e[53] !== oe || e[54] !== I || e[55] !== st || e[56] !== d || e[57] !== G || e[58] !== it || e[59] !== p || e[60] !== f || e[61] !== P || e[62] !== ae || e[63] !== Me || e[64] !== Se || e[65] !== U || e[66] !== at || e[67] !== b || e[68] !== se || e[69] !== E || e[70] !== Q || e[71] !== ge || e[72] !== ct || e[73] !== y || e[74] !== rt || e[75] !== dt || e[76] !== z || e[77] !== v || e[78] !== t || e[79] !== l || e[80] !== ze || e[81] !== X || e[82] !== a.dateFormat || e[83] !== a.enabled || e[84] !== K || e[85] !== i || e[86] !== h || e[87] !== De || e[88] !== k || e[89] !== Ne || e[90] !== _ || e[91] !== lt || e[92] !== nt || e[93] !== ie || e[94] !== F ? (de = /* @__PURE__ */ o.jsx(ao, { ref: pt, children: X && ze && se ? /* @__PURE__ */ o.jsx(io, { data: d.filter((c) => a.enabled ? `${c.date}` === Bt(new Date(i[P]), a.dateFormat || "yyyy") : c), mapData: v ? se : {
364
- ...se,
365
- features: se.features.filter(co)
366
- }, xDomain: k || Ct(d.map(lo), I[0].length), yDomain: _ || Ct(d.map(so), I.length), width: X, height: ze, scale: z, centerPoint: ue, colors: I, xColorLegendTitle: De, yColorLegendTitle: Ne, mapBorderWidth: Se, mapNoDataColor: U, mapBorderColor: Me, tooltip: K, onSeriesMouseOver: ge, isWorldMap: ae, zoomScaleExtend: ie, zoomTranslateExtend: F, onSeriesMouseClick: Q, mapProperty: b, highlightedIds: f, resetSelectionOnDoubleClick: rt, styles: l, showColorScale: t, classNames: s, mapProjection: at || (ae ? "naturalEarth" : "mercator"), detailsOnClick: G, zoomInteraction: nt, animate: Fe === !0 ? {
394
+ ] }) : null, e[50] = L, e[51] = it, e[52] = P, e[53] = a.enabled, e[54] = s, e[55] = pe) : pe = e[55];
395
+ let he;
396
+ e[56] !== Ge || e[57] !== ge || e[58] !== l || e[59] !== J || e[60] !== S || e[61] !== pt || e[62] !== m || e[63] !== ke || e[64] !== mt || e[65] !== p || e[66] !== ce || e[67] !== L || e[68] !== A || e[69] !== Me || e[70] !== Se || e[71] !== Ne || e[72] !== g?.mapBorderColor || e[73] !== g?.mapBorderWidth || e[74] !== ct || e[75] !== t || e[76] !== de || e[77] !== y || e[78] !== ae || e[79] !== ve || e[80] !== yt || e[81] !== ft || e[82] !== x || e[83] !== Ee || e[84] !== ut || e[85] !== je || e[86] !== k || e[87] !== Be || e[88] !== c || e[89] !== Ie || e[90] !== K || e[91] !== a.dateFormat || e[92] !== a.enabled || e[93] !== oe || e[94] !== s || e[95] !== h || e[96] !== W || e[97] !== C || e[98] !== we || e[99] !== M || e[100] !== ht || e[101] !== dt || e[102] !== Oe || e[103] !== $ ? (he = /* @__PURE__ */ o.jsx(ho, { ref: vt, children: K && Ie && de ? /* @__PURE__ */ o.jsx(uo, { data: m.filter((i) => a.enabled ? `${i.date}` === Vt(new Date(s[L]), a.dateFormat || "yyyy") : i), mapData: k ? de : {
397
+ ...de,
398
+ features: de.features.filter(vo)
399
+ }, xDomain: C || Wt(m.map(yo), S[0].length), yDomain: M || Wt(m.map(go), S.length), width: K, height: Ie, scale: je, centerPoint: ge, colors: S, xColorLegendTitle: W, yColorLegendTitle: we, mapBorderWidth: Se, mapNoDataColor: Ne, mapBorderColor: Me, tooltip: oe, onSeriesMouseOver: ve, isWorldMap: A, zoomScaleExtend: Oe, zoomTranslateExtend: $, onSeriesMouseClick: ae, mapProperty: t, highlightedIds: ce, resetSelectionOnDoubleClick: Ee, styles: c, showColorScale: Be, classNames: l, mapProjection: ct || (A ? "naturalEarth" : "mercator"), detailsOnClick: ke, zoomInteraction: dt, overlayMapData: yt, overlayMapBorderColor: g?.mapBorderColor, overlayMapBorderWidth: g?.mapBorderWidth, animate: Ge === !0 ? {
367
400
  duration: 0.5,
368
401
  once: !0,
369
402
  amount: 0.5
370
- } : Fe || {
403
+ } : Ge || {
371
404
  duration: 0,
372
405
  once: !0,
373
406
  amount: 0
374
- }, dimmedOpacity: it, customLayers: st, collapseColorScaleByDefault: oe, zoomAndCenterByHighlightedIds: lt, projectionRotate: ct, rewindCoordinatesInMapData: dt }) : /* @__PURE__ */ o.jsx("div", { style: {
375
- height: `${Math.max(E, p || (y ? E ? (h || X) * y > E ? (h || X) * y : E : (h || X) * y : ze))}px`
376
- }, className: "flex items-center justify-center", children: /* @__PURE__ */ o.jsx(Pt, { "aria-label": "Loading graph" }) }) }), e[50] = Fe, e[51] = ue, e[52] = s, e[53] = oe, e[54] = I, e[55] = st, e[56] = d, e[57] = G, e[58] = it, e[59] = p, e[60] = f, e[61] = P, e[62] = ae, e[63] = Me, e[64] = Se, e[65] = U, e[66] = at, e[67] = b, e[68] = se, e[69] = E, e[70] = Q, e[71] = ge, e[72] = ct, e[73] = y, e[74] = rt, e[75] = dt, e[76] = z, e[77] = v, e[78] = t, e[79] = l, e[80] = ze, e[81] = X, e[82] = a.dateFormat, e[83] = a.enabled, e[84] = K, e[85] = i, e[86] = h, e[87] = De, e[88] = k, e[89] = Ne, e[90] = _, e[91] = lt, e[92] = nt, e[93] = ie, e[94] = F, e[95] = de) : de = e[95];
377
- let me;
378
- e[96] !== s?.footnote || e[97] !== s?.source || e[98] !== re || e[99] !== q || e[100] !== l?.footnote || e[101] !== l?.source || e[102] !== h ? (me = q || re ? /* @__PURE__ */ o.jsx(oo, { styles: {
407
+ }, dimmedOpacity: mt, customLayers: pt, collapseColorScaleByDefault: J, zoomAndCenterByHighlightedIds: ht, projectionRotate: ft, rewindCoordinatesInMapData: ut }) : /* @__PURE__ */ o.jsx("div", { style: {
408
+ height: `${Math.max(y, p || (x ? y ? (h || K) * x > y ? (h || K) * x : y : (h || K) * x : Ie))}px`
409
+ }, className: "flex items-center justify-center", children: /* @__PURE__ */ o.jsx(Gt, { "aria-label": "Loading graph" }) }) }), e[56] = Ge, e[57] = ge, e[58] = l, e[59] = J, e[60] = S, e[61] = pt, e[62] = m, e[63] = ke, e[64] = mt, e[65] = p, e[66] = ce, e[67] = L, e[68] = A, e[69] = Me, e[70] = Se, e[71] = Ne, e[72] = g?.mapBorderColor, e[73] = g?.mapBorderWidth, e[74] = ct, e[75] = t, e[76] = de, e[77] = y, e[78] = ae, e[79] = ve, e[80] = yt, e[81] = ft, e[82] = x, e[83] = Ee, e[84] = ut, e[85] = je, e[86] = k, e[87] = Be, e[88] = c, e[89] = Ie, e[90] = K, e[91] = a.dateFormat, e[92] = a.enabled, e[93] = oe, e[94] = s, e[95] = h, e[96] = W, e[97] = C, e[98] = we, e[99] = M, e[100] = ht, e[101] = dt, e[102] = Oe, e[103] = $, e[104] = he) : he = e[104];
410
+ let fe;
411
+ e[105] !== l?.footnote || e[106] !== l?.source || e[107] !== z || e[108] !== Q || e[109] !== c?.footnote || e[110] !== c?.source || e[111] !== h ? (fe = Q || z ? /* @__PURE__ */ o.jsx(po, { styles: {
412
+ footnote: c?.footnote,
413
+ source: c?.source
414
+ }, classNames: {
379
415
  footnote: l?.footnote,
380
416
  source: l?.source
381
- }, classNames: {
382
- footnote: s?.footnote,
383
- source: s?.source
384
- }, sources: q, footNote: re, width: h }) : null, e[96] = s?.footnote, e[97] = s?.source, e[98] = re, e[99] = q, e[100] = l?.footnote, e[101] = l?.source, e[102] = h, e[103] = me) : me = e[103];
385
- let Qe;
386
- return e[104] !== $ || e[105] !== Oe || e[106] !== S || e[107] !== p || e[108] !== Ie || e[109] !== E || e[110] !== fe || e[111] !== y || e[112] !== ut || e[113] !== ft || e[114] !== le || e[115] !== ce || e[116] !== de || e[117] !== me || e[118] !== ot || e[119] !== h ? (Qe = /* @__PURE__ */ o.jsxs(no, { className: ut, style: ft, id: S, ref: xt, "aria-label": $, backgroundColor: Oe, theme: ot, language: Ie, minHeight: E, width: h, height: p, relativeHeight: y, padding: fe, children: [
387
- le,
388
- ce,
389
- de,
390
- me
391
- ] }), e[104] = $, e[105] = Oe, e[106] = S, e[107] = p, e[108] = Ie, e[109] = E, e[110] = fe, e[111] = y, e[112] = ut, e[113] = ft, e[114] = le, e[115] = ce, e[116] = de, e[117] = me, e[118] = ot, e[119] = h, e[120] = Qe) : Qe = e[120], Qe;
417
+ }, sources: Q, footNote: z, width: h }) : null, e[105] = l?.footnote, e[106] = l?.source, e[107] = z, e[108] = Q, e[109] = c?.footnote, e[110] = c?.source, e[111] = h, e[112] = fe) : fe = e[112];
418
+ let st;
419
+ return e[113] !== v || e[114] !== _ || e[115] !== B || e[116] !== p || e[117] !== f || e[118] !== y || e[119] !== ye || e[120] !== x || e[121] !== kt || e[122] !== Dt || e[123] !== me || e[124] !== pe || e[125] !== he || e[126] !== fe || e[127] !== b || e[128] !== h ? (st = /* @__PURE__ */ o.jsxs(fo, { className: kt, style: Dt, id: B, ref: jt, "aria-label": v, backgroundColor: _, theme: b, language: f, minHeight: y, width: h, height: p, relativeHeight: x, padding: ye, children: [
420
+ me,
421
+ pe,
422
+ he,
423
+ fe
424
+ ] }), e[113] = v, e[114] = _, e[115] = B, e[116] = p, e[117] = f, e[118] = y, e[119] = ye, e[120] = x, e[121] = kt, e[122] = Dt, e[123] = me, e[124] = pe, e[125] = he, e[126] = fe, e[127] = b, e[128] = h, e[129] = st) : st = e[129], st;
392
425
  }
393
- function so(n) {
426
+ function go(n) {
394
427
  return n.y;
395
428
  }
396
- function lo(n) {
429
+ function yo(n) {
397
430
  return n.x;
398
431
  }
399
- function co(n) {
432
+ function vo(n) {
400
433
  return n.properties.NAME !== "Antarctica";
401
434
  }
402
- function mo(n) {
435
+ function xo(n) {
403
436
  return n !== void 0;
404
437
  }
405
- function po(n) {
438
+ function bo(n) {
406
439
  return n !== void 0;
407
440
  }
408
- function ho(n) {
441
+ function ko(n) {
409
442
  return n.data;
410
443
  }
411
- function uo(n) {
444
+ function Do(n) {
412
445
  return n !== void 0;
413
446
  }
414
- function fo(n) {
447
+ function Co(n) {
415
448
  return n.data;
416
449
  }
417
- function go(n, e) {
450
+ function wo(n, e) {
418
451
  return n - e;
419
452
  }
420
- function yo(n) {
453
+ function jo(n) {
421
454
  return n.date;
422
455
  }
423
456
  export {
424
- Ro as BiVariateChoroplethMap
457
+ Ko as BiVariateChoroplethMap
425
458
  };
426
459
  //# sourceMappingURL=BiVariateChoroplethMap.js.map