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