@undp/data-viz 2.0.3 → 2.0.5

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,272 +1,312 @@
1
- import { j as a, m as rt, c as at } from "./index-CHPV5EwG-Curnpaqc.js";
2
- import { useState as A, useRef as Xe, useEffect as E, useCallback as st, useEffectEvent as it } from "react";
3
- import { w as nt } from "./Spinner-D7rnnwnA.js";
4
- import lt from "react-globe.gl";
5
- import { i as ct } from "./index-Bwrro8-q.js";
6
- import * as H from "three";
7
- import { l as dt } from "./Modal-DGcuAHyK.js";
8
- import { j as Ye } from "./Typography-PxtFcnJb.js";
9
- import { T as pt } from "./Tooltip-CwWUegPB.js";
10
- import { n as ht } from "./numberFormattingFunction-14YCbkN2.js";
11
- import { X as mt } from "./index-D491FEn1.js";
12
- import { s as ut } from "./string2HTML-DhG75NqA.js";
13
- import { g as gt } from "./getCentroidCoordinates-D7r34N4w.js";
14
- import { o as ft } from "./ordinal-P77xw8aL.js";
15
- import { t as yt } from "./threshold-Bgr20hik.js";
16
- import { GraphHeader as vt } from "./GraphHeader.js";
17
- import { GraphFooter as bt } from "./GraphFooter.js";
18
- import { f as xt } from "./fetchAndParseData-BpqkBPQL.js";
19
- import { Colors as K } from "./Colors.js";
20
- import { g as wt } from "./getUniqValue-BKHCm3zE.js";
21
- import { g as Ct } from "./getJenks-BbngDoBQ.js";
22
- import { a as St, G as kt } from "./GraphContainer-CRqzdKu2.js";
23
- function Dt(t) {
1
+ import { j as i, m as lt, c as ct } from "./index-CHPV5EwG-Curnpaqc.js";
2
+ import { useState as U, useRef as Qe, useEffect as H, useCallback as dt, useEffectEvent as pt } from "react";
3
+ import { w as ht } from "./Spinner-D7rnnwnA.js";
4
+ import mt from "react-globe.gl";
5
+ import { i as ut } from "./index-Bwrro8-q.js";
6
+ import * as W from "three";
7
+ import { l as gt } from "./Modal-DGcuAHyK.js";
8
+ import { j as et } from "./Typography-PxtFcnJb.js";
9
+ import { g as ft } from "./_commonjsHelpers-ByX85dGu.js";
10
+ import { T as vt } from "./Tooltip-CwWUegPB.js";
11
+ import { n as yt } from "./numberFormattingFunction-14YCbkN2.js";
12
+ import { X as bt } from "./index-D491FEn1.js";
13
+ import { s as xt } from "./string2HTML-DhG75NqA.js";
14
+ import { g as wt } from "./getCentroidCoordinates-D7r34N4w.js";
15
+ import { o as Ct } from "./ordinal-P77xw8aL.js";
16
+ import { t as Dt } from "./threshold-Bgr20hik.js";
17
+ import { GraphHeader as St } from "./GraphHeader.js";
18
+ import { GraphFooter as jt } from "./GraphFooter.js";
19
+ import { f as Nt } from "./fetchAndParseData-BpqkBPQL.js";
20
+ import { Colors as te } from "./Colors.js";
21
+ import { g as kt } from "./getUniqValue-BKHCm3zE.js";
22
+ import { g as Rt } from "./getJenks-BbngDoBQ.js";
23
+ import { a as Lt, G as Ot } from "./GraphContainer-CRqzdKu2.js";
24
+ var Ke, tt;
25
+ function Tt() {
26
+ if (tt) return Ke;
27
+ tt = 1;
28
+ var t = function(o) {
29
+ return o.charAt(0) === "#" ? o.slice(1) : o;
30
+ }, e = function(o) {
31
+ var n = o.length === 3 || o.length === 4, f = n ? "".concat(o.slice(0, 1)).concat(o.slice(0, 1)) : o.slice(0, 2), s = n ? "".concat(o.slice(1, 2)).concat(o.slice(1, 2)) : o.slice(2, 4), w = n ? "".concat(o.slice(2, 3)).concat(o.slice(2, 3)) : o.slice(4, 6), M = (n ? "".concat(o.slice(3, 4)).concat(o.slice(3, 4)) : o.slice(6, 8)) || "ff";
32
+ return {
33
+ r: f,
34
+ g: s,
35
+ b: w,
36
+ a: M
37
+ };
38
+ }, d = function(o) {
39
+ return parseInt(o, 16);
40
+ }, b = function(o) {
41
+ var n = o.r, f = o.g, s = o.b, w = o.a;
42
+ return {
43
+ r: d(n),
44
+ g: d(f),
45
+ b: d(s),
46
+ a: +(d(w) / 255).toFixed(2)
47
+ };
48
+ }, x = function(o) {
49
+ return !isNaN(parseFloat(o)) && isFinite(o);
50
+ }, D = function(o, n) {
51
+ var f = o.r, s = o.g, w = o.b, M = o.a, P = x(n) ? n : M;
52
+ return "rgba(".concat(f, ", ").concat(s, ", ").concat(w, ", ").concat(P, ")");
53
+ }, g = function(o, n) {
54
+ var f = t(o), s = e(f), w = b(s);
55
+ return D(w, n);
56
+ };
57
+ return Ke = g, Ke;
58
+ }
59
+ var Mt = Tt();
60
+ const ot = /* @__PURE__ */ ft(Mt);
61
+ function Pt(t) {
24
62
  let e;
25
63
  switch (t.type) {
26
64
  case "ambient":
27
- e = new H.AmbientLight(t.color, t.intensity);
65
+ e = new W.AmbientLight(t.color, t.intensity);
28
66
  break;
29
67
  case "directional":
30
- e = new H.DirectionalLight(t.color, t.intensity), t.position && (t.position === "camera" ? e.position.set(0, 0, 0) : e.position.set(t.position.x, t.position.y, t.position.z)), (t.target || t.position === "camera") && e.target.position.set(t.target?.x || 0, t.target?.y || 0, t.target?.z === void 0 ? -1 : t.target.z), t.castShadow && (e.castShadow = !0, t.shadow && (e.shadow.mapSize.width = t.shadow.mapSize.width, e.shadow.mapSize.height = t.shadow.mapSize.height, e.shadow.camera.near = t.shadow.camera.near, e.shadow.camera.far = t.shadow.camera.far));
68
+ e = new W.DirectionalLight(t.color, t.intensity), t.position && (t.position === "camera" ? e.position.set(0, 0, 0) : e.position.set(t.position.x, t.position.y, t.position.z)), (t.target || t.position === "camera") && e.target.position.set(t.target?.x || 0, t.target?.y || 0, t.target?.z === void 0 ? -1 : t.target.z), t.castShadow && (e.castShadow = !0, t.shadow && (e.shadow.mapSize.width = t.shadow.mapSize.width, e.shadow.mapSize.height = t.shadow.mapSize.height, e.shadow.camera.near = t.shadow.camera.near, e.shadow.camera.far = t.shadow.camera.far));
31
69
  break;
32
70
  case "point":
33
- e = new H.PointLight(t.color, t.intensity, t.distance || 0, t.decay || 2), t.position && (t.position === "camera" ? e.position.set(0, 0, 0) : e.position.set(t.position.x, t.position.y, t.position.z));
71
+ e = new W.PointLight(t.color, t.intensity, t.distance || 0, t.decay || 2), t.position && (t.position === "camera" ? e.position.set(0, 0, 0) : e.position.set(t.position.x, t.position.y, t.position.z));
34
72
  break;
35
73
  case "spot":
36
- e = new H.SpotLight(t.color, t.intensity, t.distance || 0, t.angle || Math.PI / 3, t.penumbra || 0, t.decay || 2), t.position && (t.position === "camera" ? e.position.set(0, 0, 0) : e.position.set(t.position.x, t.position.y, t.position.z)), (t.target || t.position === "camera") && e.target.position.set(t.target?.x || 0, t.target?.y || 0, t.target?.z || 0), t.castShadow && (e.castShadow = !0, t.shadow && (e.shadow.mapSize.width = t.shadow.mapSize.width, e.shadow.mapSize.height = t.shadow.mapSize.height, e.shadow.camera.near = t.shadow.camera.near, e.shadow.camera.far = t.shadow.camera.far));
74
+ e = new W.SpotLight(t.color, t.intensity, t.distance || 0, t.angle || Math.PI / 3, t.penumbra || 0, t.decay || 2), t.position && (t.position === "camera" ? e.position.set(0, 0, 0) : e.position.set(t.position.x, t.position.y, t.position.z)), (t.target || t.position === "camera") && e.target.position.set(t.target?.x || 0, t.target?.y || 0, t.target?.z || 0), t.castShadow && (e.castShadow = !0, t.shadow && (e.shadow.mapSize.width = t.shadow.mapSize.width, e.shadow.mapSize.height = t.shadow.mapSize.height, e.shadow.camera.near = t.shadow.camera.near, e.shadow.camera.far = t.shadow.camera.far));
37
75
  break;
38
76
  default:
39
77
  throw new Error("Unknown light type");
40
78
  }
41
79
  return e;
42
80
  }
43
- function jt(t) {
81
+ function zt(t) {
44
82
  const {
45
83
  width: e,
46
- autoRotate: c,
47
- data: v,
48
- enableZoom: b,
49
- categorical: C,
84
+ autoRotate: d,
85
+ data: b,
86
+ enableZoom: x,
87
+ categorical: D,
50
88
  colorDomain: g,
51
- colors: d,
52
- globeMaterial: L,
53
- height: m,
54
- polygonData: B,
55
- mapProperty: n,
56
- mapBorderColor: Q,
57
- atmosphereColor: ye,
58
- tooltip: F,
59
- styles: ve,
60
- classNames: ee,
61
- mapNoDataColor: te,
62
- colorLegendTitle: u,
63
- showColorScale: oe,
64
- hoverStrokeColor: re,
65
- detailsOnClick: S,
66
- onSeriesMouseClick: I,
89
+ colors: l,
90
+ globeMaterial: o,
91
+ height: n,
92
+ polygonData: f,
93
+ mapProperty: s,
94
+ mapBorderColor: w,
95
+ atmosphereColor: M,
96
+ tooltip: P,
97
+ styles: ye,
98
+ classNames: oe,
99
+ mapNoDataColor: re,
100
+ colorLegendTitle: C,
101
+ showColorScale: ae,
102
+ hoverStrokeColor: ie,
103
+ detailsOnClick: k,
104
+ onSeriesMouseClick: _,
67
105
  onSeriesMouseOver: be,
68
106
  resetSelectionOnDoubleClick: xe,
69
- highlightedIds: ae,
70
- scale: O,
71
- globeOffset: p,
72
- polygonAltitude: h,
73
- centerLng: _,
74
- centerLat: U,
107
+ highlightedIds: z,
108
+ scale: E,
109
+ globeOffset: m,
110
+ polygonAltitude: u,
111
+ centerLng: V,
112
+ centerLat: Z,
75
113
  atmosphereAltitude: se,
76
- globeCurvatureResolution: W,
77
- fogSettings: M,
78
- lights: P,
79
- highlightedAltitude: ie,
80
- selectedId: f,
81
- collapseColorScaleByDefault: q
82
- } = t, [V, Z] = A(!1), i = Xe(void 0), [k, D] = A(void 0), [we, ne] = A(q === void 0 ? !(e < 680) : !q), [le, ce] = A({
114
+ globeCurvatureResolution: J,
115
+ fogSettings: A,
116
+ lights: B,
117
+ highlightedAltitude: ne,
118
+ selectedId: v,
119
+ collapseColorScaleByDefault: X,
120
+ dimmedOpacity: F
121
+ } = t, [q, we] = U(!1), p = Qe(void 0), [R, L] = U(void 0), [Ce, le] = U(X === void 0 ? !(e < 680) : !X), [ce, de] = U({
83
122
  x: 0,
84
123
  y: 0
85
- }), [x, de] = A(void 0), $ = C ? ft().domain(g).range(d) : yt().domain(g).range(d);
86
- E(() => {
87
- i.current && (i.current.controls().enableZoom = b);
88
- }, [b]), E(() => {
89
- i.current && (x || f ? i.current.controls().autoRotate = !1 : (i.current.controls().autoRotate = c !== 0, i.current.controls().autoRotateSpeed = c));
90
- }, [x, f, c]), E(() => {
91
- if (i.current && f) {
92
- const o = B.find((y) => y.properties[n] === f), [r, s] = gt(o);
93
- i.current.pointOfView({
94
- lat: s,
95
- lng: r,
96
- altitude: O
124
+ }), [S, pe] = U(void 0), Y = D ? Ct().domain(g).range(l) : Dt().domain(g).range(l);
125
+ H(() => {
126
+ p.current && (p.current.controls().enableZoom = x);
127
+ }, [x]), H(() => {
128
+ p.current && (S || v ? p.current.controls().autoRotate = !1 : (p.current.controls().autoRotate = d !== 0, p.current.controls().autoRotateSpeed = d));
129
+ }, [S, v, d]), H(() => {
130
+ if (p.current && v) {
131
+ const r = f.find((y) => y.properties[s] === v), [a, c] = wt(r);
132
+ p.current.pointOfView({
133
+ lat: c,
134
+ lng: a,
135
+ altitude: E
97
136
  }, 1e3);
98
137
  }
99
- }, [f, O, B, n]), E(() => {
100
- const o = i.current?.renderer().domElement;
101
- if (!o) return;
102
- const r = (s) => {
103
- ce({
104
- x: s.clientX,
105
- y: s.clientY
138
+ }, [v, E, f, s]), H(() => {
139
+ const r = p.current?.renderer().domElement;
140
+ if (!r) return;
141
+ const a = (c) => {
142
+ de({
143
+ x: c.clientX,
144
+ y: c.clientY
106
145
  });
107
146
  };
108
- return o.addEventListener("mousemove", r), () => o.removeEventListener("mousemove", r);
109
- }, []), E(() => {
110
- i.current && i.current.pointOfView({
111
- lat: U,
112
- lng: _,
113
- altitude: O
147
+ return r.addEventListener("mousemove", a), () => r.removeEventListener("mousemove", a);
148
+ }, []), H(() => {
149
+ p.current && p.current.pointOfView({
150
+ lat: Z,
151
+ lng: V,
152
+ altitude: E
114
153
  }, 1e3);
115
- }, [O, _, U]);
116
- const w = L || new H.MeshBasicMaterial({
154
+ }, [E, V, Z]);
155
+ const j = o || new W.MeshBasicMaterial({
117
156
  color: "#FFF"
118
- }), z = st(() => {
119
- if (!i.current) return;
120
- const o = i.current.scene(), r = i.current.camera();
121
- let s = [];
122
- o.traverse((l) => {
123
- l instanceof H.Light && s.push(l);
124
- }), s = [...s, ...r.children], s.forEach((l) => l.parent?.remove(l)), P.map((l) => Dt(l)).forEach((l, T) => {
125
- P[T].type !== "ambient" && P[T].position === "camera" ? (r.add(l), P[T].type !== "point" && r.add(l.target)) : o.add(l);
126
- }), M && (o.fog = new H.Fog(M.color, M.near, M.far));
127
- }, [P, M]), j = () => {
128
- Z(!0), z();
157
+ }), G = dt(() => {
158
+ if (!p.current) return;
159
+ const r = p.current.scene(), a = p.current.camera();
160
+ let c = [];
161
+ r.traverse((h) => {
162
+ h instanceof W.Light && c.push(h);
163
+ }), c = [...c, ...a.children], c.forEach((h) => h.parent?.remove(h)), B.map((h) => Pt(h)).forEach((h, N) => {
164
+ B[N].type !== "ambient" && B[N].position === "camera" ? (a.add(h), B[N].type !== "point" && a.add(h.target)) : r.add(h);
165
+ }), A && (r.fog = new W.Fog(A.color, A.near, A.far));
166
+ }, [B, A]), O = () => {
167
+ we(!0), G();
129
168
  };
130
- return E(() => {
131
- V && z();
132
- }, [V, z]), /* @__PURE__ */ a.jsxs("div", { className: "relative", children: [
133
- /* @__PURE__ */ a.jsx(lt, { ref: i, height: m, width: e, globeOffset: p, lineHoverPrecision: 0, polygonsData: B, polygonAltitude: (o) => ae.includes(o?.properties?.[n]) || o?.properties?.[n] === f ? ie * (o?.properties?.[n] === f ? 2 : 1) : o?.properties?.[n] === x?.id || o?.properties?.[n] === k?.id ? ie : h, polygonCapColor: (o) => {
134
- const r = o?.properties?.[n], s = v.find((y) => y.id === r)?.x;
135
- return s != null ? $(s) : te;
136
- }, polygonSideColor: (o) => {
137
- const r = o?.properties?.[n], s = v.find((l) => l.id === r)?.x, y = s != null ? $(s) : te;
138
- return ae.includes(o?.properties?.[n]) || o?.properties?.[n] === f ? y : "rgba(100,100,100,0)";
139
- }, polygonStrokeColor: (o) => o?.properties?.[n] === x?.id ? re : Q, onGlobeClick: () => {
140
- D(void 0);
141
- }, onPolygonClick: (o) => {
142
- const r = o?.properties?.[n] ? v.find((s) => s.id === o?.properties?.[n]) : void 0;
143
- (I || S) && (ct(k, r) && xe && r ? (D(void 0), I?.(void 0)) : (D(r), I?.(r)));
144
- }, onPolygonHover: (o) => {
145
- const r = o?.properties?.[n] ? v.find((s) => s.id === o?.properties?.[n]) : void 0;
146
- de(r), be?.(r);
147
- }, atmosphereColor: ye, atmosphereAltitude: se, globeCurvatureResolution: W, globeMaterial: w, backgroundColor: "rgba(0, 0, 0, 0)", polygonsTransitionDuration: 100, onGlobeReady: () => {
148
- if (i.current) {
149
- i.current.pointOfView({
150
- lat: U,
151
- lng: _
169
+ return H(() => {
170
+ q && G();
171
+ }, [q, G]), /* @__PURE__ */ i.jsxs("div", { className: "relative", children: [
172
+ /* @__PURE__ */ i.jsx(mt, { ref: p, height: n, width: e, globeOffset: m, lineHoverPrecision: 0, polygonsData: f, polygonAltitude: (r) => z.includes(r?.properties?.[s]) || r?.properties?.[s] === v || r?.properties?.[s] === S?.id || r?.properties?.[s] === R?.id ? ne : u, polygonCapColor: (r) => {
173
+ const a = v ? r?.properties?.[s] === v ? 1 : F : z.length !== 0 ? z.includes(r?.properties?.[s]) ? 1 : F : 1, c = r?.properties?.[s], y = b.find((N) => N.id === c)?.x, h = y != null ? Y(y) : re;
174
+ return ot(h, `${a}`);
175
+ }, polygonSideColor: (r) => {
176
+ const a = r?.properties?.[s], c = b.find((N) => N.id === a)?.x, y = v ? r?.properties?.[s] === v ? 1 : F : z.length !== 0 ? z.includes(r?.properties?.[s]) ? 1 : F : 1, h = c != null ? Y(c) : re;
177
+ return ot(h, `${y}`);
178
+ }, polygonStrokeColor: (r) => r?.properties?.[s] === S?.id ? ie : w, onGlobeClick: () => {
179
+ L(void 0);
180
+ }, onPolygonClick: (r) => {
181
+ const a = r?.properties?.[s] ? b.find((c) => c.id === r?.properties?.[s]) : void 0;
182
+ (_ || k) && (ut(R, a) && xe && a ? (L(void 0), _?.(void 0)) : (L(a), _?.(a)));
183
+ }, onPolygonHover: (r) => {
184
+ const a = r?.properties?.[s] ? b.find((c) => c.id === r?.properties?.[s]) : void 0;
185
+ pe(a), be?.(a);
186
+ }, atmosphereColor: M, atmosphereAltitude: se, globeCurvatureResolution: J, globeMaterial: j, backgroundColor: "rgba(0, 0, 0, 0)", polygonsTransitionDuration: 100, onGlobeReady: () => {
187
+ if (p.current) {
188
+ p.current.pointOfView({
189
+ lat: Z,
190
+ lng: V
152
191
  });
153
- const o = i.current.scene();
192
+ const r = p.current.scene();
154
193
  setTimeout(() => {
155
- (o.children[3]?.children[0]?.children[4]?.children || []).forEach((y) => {
156
- const l = y.children[1];
157
- l.renderOrder = 2;
194
+ (r.children[3]?.children[0]?.children[4]?.children || []).forEach((y) => {
195
+ const h = y.children[1];
196
+ h.renderOrder = 2;
158
197
  });
159
198
  }, 300);
160
- const r = i.current.camera();
161
- o.add(r), j();
199
+ const a = p.current.camera();
200
+ r.add(a), O();
162
201
  }
163
202
  } }),
164
- oe === !1 ? null : /* @__PURE__ */ a.jsx("div", { className: rt("absolute left-4 bottom-4 map-color-legend", ee?.colorLegend), children: we ? /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
165
- /* @__PURE__ */ a.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: () => {
166
- ne(!1);
167
- }, children: /* @__PURE__ */ a.jsx(mt, {}) }),
168
- /* @__PURE__ */ a.jsxs("div", { className: "color-legend-box p-2 bg-[rgba(240,240,240,0.7)] dark:bg-[rgba(30,30,30,0.7)]", style: {
169
- width: C ? void 0 : "340px"
203
+ ae === !1 ? null : /* @__PURE__ */ i.jsx("div", { className: lt("absolute left-4 bottom-4 map-color-legend", oe?.colorLegend), children: Ce ? /* @__PURE__ */ i.jsxs(i.Fragment, { children: [
204
+ /* @__PURE__ */ i.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: () => {
205
+ le(!1);
206
+ }, children: /* @__PURE__ */ i.jsx(bt, {}) }),
207
+ /* @__PURE__ */ i.jsxs("div", { className: "color-legend-box p-2 bg-[rgba(240,240,240,0.7)] dark:bg-[rgba(30,30,30,0.7)]", style: {
208
+ width: D ? void 0 : "340px"
170
209
  }, children: [
171
- u && u !== "" ? /* @__PURE__ */ a.jsx(Ye, { size: "xs", marginBottom: "xs", className: "p-0 leading-normal overflow-hidden text-primary-gray-700 dark:text-primary-gray-300", style: {
210
+ C && C !== "" ? /* @__PURE__ */ i.jsx(et, { size: "xs", marginBottom: "xs", className: "p-0 leading-normal overflow-hidden text-primary-gray-700 dark:text-primary-gray-300", style: {
172
211
  display: "-webkit-box",
173
212
  WebkitLineClamp: "1",
174
213
  WebkitBoxOrient: "vertical"
175
- }, children: u }) : null,
176
- C ? /* @__PURE__ */ a.jsx("div", { className: "flex flex-col gap-3", children: g.map((o, r) => /* @__PURE__ */ a.jsxs("div", { className: "flex gap-2 items-center", children: [
177
- /* @__PURE__ */ a.jsx("div", { className: "w-2 h-2 rounded-full", style: {
178
- backgroundColor: d[r % d.length]
214
+ }, children: C }) : null,
215
+ D ? /* @__PURE__ */ i.jsx("div", { className: "flex flex-col gap-3", children: g.map((r, a) => /* @__PURE__ */ i.jsxs("div", { className: "flex gap-2 items-center", children: [
216
+ /* @__PURE__ */ i.jsx("div", { className: "w-2 h-2 rounded-full", style: {
217
+ backgroundColor: l[a % l.length]
179
218
  } }),
180
- /* @__PURE__ */ a.jsx(Ye, { size: "sm", marginBottom: "none", leading: "none", children: o })
181
- ] }, r)) }) : /* @__PURE__ */ a.jsx("svg", { width: "100%", viewBox: "0 0 320 30", direction: "ltr", children: /* @__PURE__ */ a.jsxs("g", { children: [
182
- g.map((o, r) => /* @__PURE__ */ a.jsxs("g", { className: "cursor-pointer", children: [
183
- /* @__PURE__ */ a.jsx("rect", { x: r * 320 / d.length + 1, y: 1, width: 320 / d.length - 2, height: 8, style: {
184
- fill: d[r],
185
- stroke: d[r]
219
+ /* @__PURE__ */ i.jsx(et, { size: "sm", marginBottom: "none", leading: "none", children: r })
220
+ ] }, a)) }) : /* @__PURE__ */ i.jsx("svg", { width: "100%", viewBox: "0 0 320 30", direction: "ltr", children: /* @__PURE__ */ i.jsxs("g", { children: [
221
+ g.map((r, a) => /* @__PURE__ */ i.jsxs("g", { className: "cursor-pointer", children: [
222
+ /* @__PURE__ */ i.jsx("rect", { x: a * 320 / l.length + 1, y: 1, width: 320 / l.length - 2, height: 8, style: {
223
+ fill: l[a],
224
+ stroke: l[a]
186
225
  } }),
187
- /* @__PURE__ */ a.jsx("text", { x: (r + 1) * 320 / d.length, y: 25, className: "fill-primary-gray-700 dark:fill-primary-gray-300 text-xs", style: {
226
+ /* @__PURE__ */ i.jsx("text", { x: (a + 1) * 320 / l.length, y: 25, className: "fill-primary-gray-700 dark:fill-primary-gray-300 text-xs", style: {
188
227
  textAnchor: "middle"
189
- }, children: ht(o, "NA") })
190
- ] }, r)),
191
- /* @__PURE__ */ a.jsx("g", { children: /* @__PURE__ */ a.jsx("rect", { x: g.length * 320 / d.length + 1, y: 1, width: 320 / d.length - 2, height: 8, style: {
192
- fill: d[g.length],
193
- stroke: d[g.length]
228
+ }, children: yt(r, "NA") })
229
+ ] }, a)),
230
+ /* @__PURE__ */ i.jsx("g", { children: /* @__PURE__ */ i.jsx("rect", { x: g.length * 320 / l.length + 1, y: 1, width: 320 / l.length - 2, height: 8, style: {
231
+ fill: l[g.length],
232
+ stroke: l[g.length]
194
233
  } }) })
195
234
  ] }) })
196
235
  ] })
197
- ] }) : /* @__PURE__ */ a.jsx("button", { type: "button", className: "mb-0 border-0 bg-transparent p-0 self-start", onClick: () => {
198
- ne(!0);
199
- }, children: /* @__PURE__ */ a.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" }) }) }),
200
- x && F ? /* @__PURE__ */ a.jsx(pt, { data: x, body: F, xPos: le.x, yPos: le.y, backgroundStyle: ve?.tooltip, className: ee?.tooltip }) : null,
201
- S && k !== void 0 ? /* @__PURE__ */ a.jsx(dt, { open: k !== void 0, onClose: () => {
202
- D(void 0);
203
- }, children: /* @__PURE__ */ a.jsx("div", { className: "graph-modal-content m-0", dangerouslySetInnerHTML: typeof S == "string" ? {
204
- __html: ut(S, k)
205
- } : void 0, children: typeof S == "function" ? S(k) : null }) }) : null
236
+ ] }) : /* @__PURE__ */ i.jsx("button", { type: "button", className: "mb-0 border-0 bg-transparent p-0 self-start", onClick: () => {
237
+ le(!0);
238
+ }, children: /* @__PURE__ */ i.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" }) }) }),
239
+ S && P ? /* @__PURE__ */ i.jsx(vt, { data: S, body: P, xPos: ce.x, yPos: ce.y, backgroundStyle: ye?.tooltip, className: oe?.tooltip }) : null,
240
+ k && R !== void 0 ? /* @__PURE__ */ i.jsx(gt, { open: R !== void 0, onClose: () => {
241
+ L(void 0);
242
+ }, children: /* @__PURE__ */ i.jsx("div", { className: "graph-modal-content m-0", dangerouslySetInnerHTML: typeof k == "string" ? {
243
+ __html: xt(k, R)
244
+ } : void 0, children: typeof k == "function" ? k(R) : null }) }) : null
206
245
  ] });
207
246
  }
208
- function to(t) {
209
- const e = at.c(96), {
210
- data: c,
211
- mapData: v,
212
- graphTitle: b,
213
- colors: C,
247
+ function po(t) {
248
+ const e = ct.c(97), {
249
+ data: d,
250
+ mapData: b,
251
+ graphTitle: x,
252
+ colors: D,
214
253
  sources: g,
215
- graphDescription: d,
216
- height: L,
217
- width: m,
218
- footNote: B,
219
- colorDomain: n,
220
- colorLegendTitle: Q,
221
- scaleType: ye,
222
- padding: F,
223
- mapNoDataColor: ve,
224
- backgroundColor: ee,
225
- mapBorderColor: te,
226
- relativeHeight: u,
227
- tooltip: oe,
228
- graphID: re,
229
- mapProperty: S,
230
- dataDownload: I,
254
+ graphDescription: l,
255
+ height: o,
256
+ width: n,
257
+ footNote: f,
258
+ colorDomain: s,
259
+ colorLegendTitle: w,
260
+ scaleType: M,
261
+ padding: P,
262
+ mapNoDataColor: ye,
263
+ backgroundColor: oe,
264
+ mapBorderColor: re,
265
+ relativeHeight: C,
266
+ tooltip: ae,
267
+ graphID: ie,
268
+ mapProperty: k,
269
+ dataDownload: _,
231
270
  language: be,
232
271
  minHeight: xe,
233
- theme: ae,
234
- ariaLabel: O,
235
- styles: p,
236
- classNames: h,
237
- autoRotate: _,
238
- enableZoom: U,
272
+ theme: z,
273
+ ariaLabel: E,
274
+ styles: m,
275
+ classNames: u,
276
+ autoRotate: V,
277
+ enableZoom: Z,
239
278
  globeMaterial: se,
240
- centerPoint: W,
241
- atmosphereColor: M,
242
- showColorScale: P,
243
- resetSelectionOnDoubleClick: ie,
244
- detailsOnClick: f,
245
- onSeriesMouseOver: q,
246
- onSeriesMouseClick: V,
247
- highlightedIds: Z,
248
- highlightedAltitude: i,
249
- scale: k,
250
- globeOffset: D,
251
- polygonAltitude: we,
252
- globeCurvatureResolution: ne,
253
- atmosphereAltitude: le,
254
- fogSettings: ce,
255
- lights: x,
256
- selectedId: de,
257
- collapseColorScaleByDefault: $
258
- } = t, w = v === void 0 ? "https://raw.githubusercontent.com/UNDP-Data/dv-country-geojson/refs/heads/main/worldMap-simplified.json" : v, z = B === 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." : B, j = ye === void 0 ? "threshold" : ye, o = ve === void 0 ? K.light.graphNoData : ve, r = ee === void 0 ? !1 : ee, s = te === void 0 ? K.light.grays["gray-500"] : te, y = S === void 0 ? "ISO3" : S, l = I === void 0 ? !1 : I, T = be === void 0 ? "en" : be, N = xe === void 0 ? 0 : xe, R = ae === void 0 ? "light" : ae, pe = _ === void 0 ? !0 : _, Ae = U === void 0 ? !0 : U;
259
- let Ce;
260
- e[0] !== W ? (Ce = W === void 0 ? [0, 0] : W, e[0] = W, e[1] = Ce) : Ce = e[1];
261
- const Se = Ce, Te = M === void 0 ? "#999" : M, Ge = P === void 0 ? !0 : P, He = ie === void 0 ? !0 : ie;
262
- let ke;
263
- e[2] !== Z ? (ke = Z === void 0 ? [] : Z, e[2] = Z, e[3] = ke) : ke = e[3];
264
- const Be = ke, Fe = i === void 0 ? 0.1 : i, Ie = k === void 0 ? 1 : k;
279
+ centerPoint: J,
280
+ atmosphereColor: A,
281
+ showColorScale: B,
282
+ resetSelectionOnDoubleClick: ne,
283
+ detailsOnClick: v,
284
+ onSeriesMouseOver: X,
285
+ onSeriesMouseClick: F,
286
+ highlightedIds: q,
287
+ highlightedAltitude: we,
288
+ dimmedOpacity: p,
289
+ scale: R,
290
+ globeOffset: L,
291
+ polygonAltitude: Ce,
292
+ globeCurvatureResolution: le,
293
+ atmosphereAltitude: ce,
294
+ fogSettings: de,
295
+ lights: S,
296
+ selectedId: pe,
297
+ collapseColorScaleByDefault: Y
298
+ } = t, j = b === void 0 ? "https://raw.githubusercontent.com/UNDP-Data/dv-country-geojson/refs/heads/main/worldMap-simplified.json" : b, G = 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, O = M === void 0 ? "threshold" : M, r = ye === void 0 ? te.light.graphNoData : ye, a = oe === void 0 ? !1 : oe, c = re === void 0 ? te.light.grays["gray-500"] : re, y = k === void 0 ? "ISO3" : k, h = _ === void 0 ? !1 : _, N = be === void 0 ? "en" : be, T = xe === void 0 ? 0 : xe, I = z === void 0 ? "light" : z, he = V === void 0 ? !0 : V, Ae = Z === void 0 ? !0 : Z;
265
299
  let De;
266
- e[4] !== D ? (De = D === void 0 ? [0, 0] : D, e[4] = D, e[5] = De) : De = e[5];
267
- const _e = De, Ue = we === void 0 ? 0.01 : we, We = ne === void 0 ? 4 : ne, qe = le === void 0 ? 0.15 : le;
300
+ e[0] !== J ? (De = J === void 0 ? [0, 0] : J, e[0] = J, e[1] = De) : De = e[1];
301
+ const Se = De, Be = A === void 0 ? "#999" : A, Fe = B === void 0 ? !0 : B, Ge = ne === void 0 ? !0 : ne;
268
302
  let je;
269
- e[6] !== x ? (je = x === void 0 ? [{
303
+ e[2] !== q ? (je = q === void 0 ? [] : q, e[2] = q, e[3] = je) : je = e[3];
304
+ const Ie = je, He = we === void 0 ? 0.1 : we, Ue = p === void 0 ? 0.3 : p, qe = R === void 0 ? 1 : R;
305
+ let Ne;
306
+ e[4] !== L ? (Ne = L === void 0 ? [0, 0] : L, e[4] = L, e[5] = Ne) : Ne = e[5];
307
+ const $e = Ne, We = Ce === void 0 ? 0.01 : Ce, _e = le === void 0 ? 4 : le, Ve = ce === void 0 ? 0.15 : ce;
308
+ let ke;
309
+ e[6] !== S ? (ke = S === void 0 ? [{
270
310
  type: "ambient",
271
311
  color: 4210752,
272
312
  intensity: 0.4
@@ -279,106 +319,106 @@ function to(t) {
279
319
  y: 10,
280
320
  z: 5
281
321
  }
282
- }] : x, e[6] = x, e[7] = je) : je = e[7];
283
- const Ve = je, [Ne, Ke] = A(void 0), [G, Qe] = A(0), [he, et] = A(0), Ze = Xe(null), tt = Xe(null);
322
+ }] : S, e[6] = S, e[7] = ke) : ke = e[7];
323
+ const Ze = ke, [Re, rt] = U(void 0), [$, at] = U(0), [me, it] = U(0), Je = Qe(null), st = Qe(null);
284
324
  let Le, Oe;
285
325
  e[8] === Symbol.for("react.memo_cache_sentinel") ? (Le = () => {
286
- const ge = new ResizeObserver((fe) => {
287
- Qe(fe[0].target.clientWidth || 620), et(fe[0].target.clientHeight || 480);
326
+ const fe = new ResizeObserver((ve) => {
327
+ at(ve[0].target.clientWidth || 620), it(ve[0].target.clientHeight || 480);
288
328
  });
289
- return Ze.current && ge.observe(Ze.current), () => ge.disconnect();
290
- }, Oe = [], e[8] = Le, e[9] = Oe) : (Le = e[8], Oe = e[9]), E(Le, Oe);
329
+ return Je.current && fe.observe(Je.current), () => fe.disconnect();
330
+ }, Oe = [], e[8] = Le, e[9] = Oe) : (Le = e[8], Oe = e[9]), H(Le, Oe);
331
+ let Te;
332
+ e[10] === Symbol.for("react.memo_cache_sentinel") ? (Te = (fe) => {
333
+ rt(fe);
334
+ }, e[10] = Te) : Te = e[10];
335
+ const ue = pt(Te);
291
336
  let Me;
292
- e[10] === Symbol.for("react.memo_cache_sentinel") ? (Me = (ge) => {
293
- Ke(ge);
294
- }, e[10] = Me) : Me = e[10];
295
- const me = it(Me);
296
- let Pe;
297
- e[11] !== w || e[12] !== me ? (Pe = () => {
298
- typeof w == "string" ? xt(w).then((fe) => {
299
- if (w === "https://raw.githubusercontent.com/UNDP-Data/dv-country-geojson/refs/heads/main/worldMap-simplified.json") {
300
- const ot = fe.features.map(Rt);
301
- me(ot);
337
+ e[11] !== j || e[12] !== ue ? (Me = () => {
338
+ typeof j == "string" ? Nt(j).then((ve) => {
339
+ if (j === "https://raw.githubusercontent.com/UNDP-Data/dv-country-geojson/refs/heads/main/worldMap-simplified.json") {
340
+ const nt = ve.features.map(Ht);
341
+ ue(nt);
302
342
  } else
303
- me(fe.features);
304
- }) : me(w.features);
305
- }, e[11] = w, e[12] = me, e[13] = Pe) : Pe = e[13];
343
+ ue(ve.features);
344
+ }) : ue(j.features);
345
+ }, e[11] = j, e[12] = ue, e[13] = Me) : Me = e[13];
346
+ let Pe;
347
+ e[14] !== j ? (Pe = [j], e[14] = j, e[15] = Pe) : Pe = e[15], H(Me, Pe);
306
348
  let ze;
307
- e[14] !== w ? (ze = [w], e[14] = w, e[15] = ze) : ze = e[15], E(Pe, ze);
308
- let Re;
309
- e[16] !== n || e[17] !== C?.length || e[18] !== c || e[19] !== j ? (Re = n || (j === "categorical" ? wt(c, "x") : Ct(c.map(zt), C?.length || 4)), e[16] = n, e[17] = C?.length, e[18] = c, e[19] = j, e[20] = Re) : Re = e[20];
310
- const ue = Re, $e = h?.graphContainer, Je = p?.graphContainer;
311
- let J;
312
- e[21] !== h?.description || e[22] !== h?.title || e[23] !== c || e[24] !== l || e[25] !== d || e[26] !== b || e[27] !== p?.description || e[28] !== p?.title || e[29] !== m ? (J = b || d || l ? /* @__PURE__ */ a.jsx(vt, { styles: {
313
- title: p?.title,
314
- description: p?.description
349
+ e[16] !== s || e[17] !== D?.length || e[18] !== d || e[19] !== O ? (ze = s || (O === "categorical" ? kt(d, "x") : Rt(d.map(It), D?.length || 4)), e[16] = s, e[17] = D?.length, e[18] = d, e[19] = O, e[20] = ze) : ze = e[20];
350
+ const ge = ze, Xe = u?.graphContainer, Ye = m?.graphContainer;
351
+ let K;
352
+ e[21] !== u?.description || e[22] !== u?.title || e[23] !== d || e[24] !== h || e[25] !== l || e[26] !== x || e[27] !== m?.description || e[28] !== m?.title || e[29] !== n ? (K = x || l || h ? /* @__PURE__ */ i.jsx(St, { styles: {
353
+ title: m?.title,
354
+ description: m?.description
315
355
  }, classNames: {
316
- title: h?.title,
317
- description: h?.description
318
- }, graphTitle: b, graphDescription: d, width: m, graphDownload: void 0, dataDownload: l ? c.map(Pt).filter(Mt).length > 0 ? c.map(Ot).filter(Lt) : c.filter(Nt) : null }) : null, e[21] = h?.description, e[22] = h?.title, e[23] = c, e[24] = l, e[25] = d, e[26] = b, e[27] = p?.description, e[28] = p?.title, e[29] = m, e[30] = J) : J = e[30];
319
- let X;
320
- e[31] !== qe || e[32] !== Te || e[33] !== pe || e[34] !== Se || e[35] !== h || e[36] !== $ || e[37] !== Q || e[38] !== C || e[39] !== c || e[40] !== f || e[41] !== ue || e[42] !== Ae || e[43] !== ce || e[44] !== We || e[45] !== se || e[46] !== _e || e[47] !== L || e[48] !== Fe || e[49] !== Be || e[50] !== Ve || e[51] !== s || e[52] !== o || e[53] !== y || e[54] !== Ne || e[55] !== N || e[56] !== V || e[57] !== q || e[58] !== Ue || e[59] !== u || e[60] !== He || e[61] !== Ie || e[62] !== j || e[63] !== de || e[64] !== Ge || e[65] !== p || e[66] !== he || e[67] !== G || e[68] !== R || e[69] !== oe || e[70] !== m ? (X = /* @__PURE__ */ a.jsx(St, { ref: Ze, children: G && he && Ne ? /* @__PURE__ */ a.jsx(jt, { data: c, globeOffset: _e, polygonData: Ne, colorDomain: ue, width: G, height: he, colors: C || (j === "categorical" ? K[R].sequentialColors[`neutralColorsx0${ue.length}`] : K[R].sequentialColors[`neutralColorsx0${ue.length + 1}`]), mapNoDataColor: o, categorical: j === "categorical", mapBorderColor: s, tooltip: oe, mapProperty: y, styles: p, classNames: h, autoRotate: pe === !0 ? 1.5 : pe === !1 ? 0 : pe, enableZoom: Ae, globeMaterial: se, atmosphereColor: Te, colorLegendTitle: Q, showColorScale: Ge, hoverStrokeColor: R === "light" ? K.light.grays["gray-700"] : K.light.grays["gray-300"], highlightedIds: Be, resetSelectionOnDoubleClick: He, detailsOnClick: f, onSeriesMouseOver: q, onSeriesMouseClick: V, scale: Ie, polygonAltitude: Ue, centerLat: Se[0], centerLng: Se[1], atmosphereAltitude: qe, globeCurvatureResolution: We, fogSettings: ce, lights: Ve, highlightedAltitude: Fe, selectedId: de, collapseColorScaleByDefault: $ }) : /* @__PURE__ */ a.jsx("div", { style: {
321
- height: `${Math.max(N, L || (u ? N ? (m || G) * u > N ? (m || G) * u : N : (m || G) * u : he))}px`
322
- }, className: "flex items-center justify-center", children: /* @__PURE__ */ a.jsx(nt, { "aria-label": "Loading graph" }) }) }), e[31] = qe, e[32] = Te, e[33] = pe, e[34] = Se, e[35] = h, e[36] = $, e[37] = Q, e[38] = C, e[39] = c, e[40] = f, e[41] = ue, e[42] = Ae, e[43] = ce, e[44] = We, e[45] = se, e[46] = _e, e[47] = L, e[48] = Fe, e[49] = Be, e[50] = Ve, e[51] = s, e[52] = o, e[53] = y, e[54] = Ne, e[55] = N, e[56] = V, e[57] = q, e[58] = Ue, e[59] = u, e[60] = He, e[61] = Ie, e[62] = j, e[63] = de, e[64] = Ge, e[65] = p, e[66] = he, e[67] = G, e[68] = R, e[69] = oe, e[70] = m, e[71] = X) : X = e[71];
323
- let Y;
324
- e[72] !== h?.footnote || e[73] !== h?.source || e[74] !== z || e[75] !== g || e[76] !== p?.footnote || e[77] !== p?.source || e[78] !== m ? (Y = g || z ? /* @__PURE__ */ a.jsx(bt, { styles: {
325
- footnote: p?.footnote,
326
- source: p?.source
356
+ title: u?.title,
357
+ description: u?.description
358
+ }, graphTitle: x, graphDescription: l, width: n, graphDownload: void 0, dataDownload: h ? d.map(Gt).filter(Ft).length > 0 ? d.map(Bt).filter(At) : d.filter(Et) : null }) : null, e[21] = u?.description, e[22] = u?.title, e[23] = d, e[24] = h, e[25] = l, e[26] = x, e[27] = m?.description, e[28] = m?.title, e[29] = n, e[30] = K) : K = e[30];
359
+ let Q;
360
+ e[31] !== Ve || e[32] !== Be || e[33] !== he || e[34] !== Se || e[35] !== u || e[36] !== Y || e[37] !== w || e[38] !== D || e[39] !== d || e[40] !== v || e[41] !== Ue || e[42] !== ge || e[43] !== Ae || e[44] !== de || e[45] !== _e || e[46] !== se || e[47] !== $e || e[48] !== o || e[49] !== He || e[50] !== Ie || e[51] !== Ze || e[52] !== c || e[53] !== r || e[54] !== y || e[55] !== Re || e[56] !== T || e[57] !== F || e[58] !== X || e[59] !== We || e[60] !== C || e[61] !== Ge || e[62] !== qe || e[63] !== O || e[64] !== pe || e[65] !== Fe || e[66] !== m || e[67] !== me || e[68] !== $ || e[69] !== I || e[70] !== ae || e[71] !== n ? (Q = /* @__PURE__ */ i.jsx(Lt, { ref: Je, children: $ && me && Re ? /* @__PURE__ */ i.jsx(zt, { data: d, globeOffset: $e, polygonData: Re, colorDomain: ge, width: $, height: me, colors: D || (O === "categorical" ? te[I].sequentialColors[`neutralColorsx0${ge.length}`] : te[I].sequentialColors[`neutralColorsx0${ge.length + 1}`]), mapNoDataColor: r, categorical: O === "categorical", mapBorderColor: c, tooltip: ae, mapProperty: y, styles: m, classNames: u, autoRotate: he === !0 ? 1.5 : he === !1 ? 0 : he, enableZoom: Ae, globeMaterial: se, atmosphereColor: Be, colorLegendTitle: w, showColorScale: Fe, hoverStrokeColor: I === "light" ? te.light.grays["gray-700"] : te.light.grays["gray-300"], highlightedIds: Ie, resetSelectionOnDoubleClick: Ge, detailsOnClick: v, onSeriesMouseOver: X, onSeriesMouseClick: F, scale: qe, polygonAltitude: We, centerLat: Se[0], centerLng: Se[1], atmosphereAltitude: Ve, globeCurvatureResolution: _e, fogSettings: de, lights: Ze, highlightedAltitude: He, selectedId: pe, collapseColorScaleByDefault: Y, dimmedOpacity: Ue }) : /* @__PURE__ */ i.jsx("div", { style: {
361
+ height: `${Math.max(T, o || (C ? T ? (n || $) * C > T ? (n || $) * C : T : (n || $) * C : me))}px`
362
+ }, className: "flex items-center justify-center", children: /* @__PURE__ */ i.jsx(ht, { "aria-label": "Loading graph" }) }) }), e[31] = Ve, e[32] = Be, e[33] = he, e[34] = Se, e[35] = u, e[36] = Y, e[37] = w, e[38] = D, e[39] = d, e[40] = v, e[41] = Ue, e[42] = ge, e[43] = Ae, e[44] = de, e[45] = _e, e[46] = se, e[47] = $e, e[48] = o, e[49] = He, e[50] = Ie, e[51] = Ze, e[52] = c, e[53] = r, e[54] = y, e[55] = Re, e[56] = T, e[57] = F, e[58] = X, e[59] = We, e[60] = C, e[61] = Ge, e[62] = qe, e[63] = O, e[64] = pe, e[65] = Fe, e[66] = m, e[67] = me, e[68] = $, e[69] = I, e[70] = ae, e[71] = n, e[72] = Q) : Q = e[72];
363
+ let ee;
364
+ e[73] !== u?.footnote || e[74] !== u?.source || e[75] !== G || e[76] !== g || e[77] !== m?.footnote || e[78] !== m?.source || e[79] !== n ? (ee = g || G ? /* @__PURE__ */ i.jsx(jt, { styles: {
365
+ footnote: m?.footnote,
366
+ source: m?.source
327
367
  }, classNames: {
328
- footnote: h?.footnote,
329
- source: h?.source
330
- }, sources: g, footNote: z, width: m }) : null, e[72] = h?.footnote, e[73] = h?.source, e[74] = z, e[75] = g, e[76] = p?.footnote, e[77] = p?.source, e[78] = m, e[79] = Y) : Y = e[79];
368
+ footnote: u?.footnote,
369
+ source: u?.source
370
+ }, sources: g, footNote: G, width: n }) : null, e[73] = u?.footnote, e[74] = u?.source, e[75] = G, e[76] = g, e[77] = m?.footnote, e[78] = m?.source, e[79] = n, e[80] = ee) : ee = e[80];
331
371
  let Ee;
332
- return e[80] !== O || e[81] !== r || e[82] !== re || e[83] !== L || e[84] !== T || e[85] !== N || e[86] !== F || e[87] !== u || e[88] !== $e || e[89] !== Je || e[90] !== J || e[91] !== X || e[92] !== Y || e[93] !== R || e[94] !== m ? (Ee = /* @__PURE__ */ a.jsxs(kt, { className: $e, style: Je, id: re, ref: tt, "aria-label": O, backgroundColor: r, theme: R, language: T, minHeight: N, width: m, height: L, relativeHeight: u, padding: F, children: [
333
- J,
334
- X,
335
- Y
336
- ] }), e[80] = O, e[81] = r, e[82] = re, e[83] = L, e[84] = T, e[85] = N, e[86] = F, e[87] = u, e[88] = $e, e[89] = Je, e[90] = J, e[91] = X, e[92] = Y, e[93] = R, e[94] = m, e[95] = Ee) : Ee = e[95], Ee;
372
+ return e[81] !== E || e[82] !== a || e[83] !== ie || e[84] !== o || e[85] !== N || e[86] !== T || e[87] !== P || e[88] !== C || e[89] !== Xe || e[90] !== Ye || e[91] !== K || e[92] !== Q || e[93] !== ee || e[94] !== I || e[95] !== n ? (Ee = /* @__PURE__ */ i.jsxs(Ot, { className: Xe, style: Ye, id: ie, ref: st, "aria-label": E, backgroundColor: a, theme: I, language: N, minHeight: T, width: n, height: o, relativeHeight: C, padding: P, children: [
373
+ K,
374
+ Q,
375
+ ee
376
+ ] }), e[81] = E, e[82] = a, e[83] = ie, e[84] = o, e[85] = N, e[86] = T, e[87] = P, e[88] = C, e[89] = Xe, e[90] = Ye, e[91] = K, e[92] = Q, e[93] = ee, e[94] = I, e[95] = n, e[96] = Ee) : Ee = e[96], Ee;
337
377
  }
338
- function Nt(t) {
378
+ function Et(t) {
339
379
  return t !== void 0;
340
380
  }
341
- function Lt(t) {
381
+ function At(t) {
342
382
  return t !== void 0;
343
383
  }
344
- function Ot(t) {
384
+ function Bt(t) {
345
385
  return t.data;
346
386
  }
347
- function Mt(t) {
387
+ function Ft(t) {
348
388
  return t !== void 0;
349
389
  }
350
- function Pt(t) {
390
+ function Gt(t) {
351
391
  return t.data;
352
392
  }
353
- function zt(t) {
393
+ function It(t) {
354
394
  return t.x;
355
395
  }
356
- function Rt(t) {
396
+ function Ht(t) {
357
397
  if (t.geometry.type === "Polygon") {
358
- const v = [...t.geometry.coordinates[0]].reverse(), b = {
398
+ const b = [...t.geometry.coordinates[0]].reverse(), x = {
359
399
  ...t.geometry,
360
- coordinates: [v]
400
+ coordinates: [b]
361
401
  };
362
402
  return {
363
403
  ...t,
364
- geometry: b
404
+ geometry: x
365
405
  };
366
406
  }
367
407
  const e = [];
368
- t.geometry.coordinates.forEach((v) => {
369
- const b = [...v[0]].reverse();
370
- e.push([b]);
408
+ t.geometry.coordinates.forEach((b) => {
409
+ const x = [...b[0]].reverse();
410
+ e.push([x]);
371
411
  });
372
- const c = {
412
+ const d = {
373
413
  ...t.geometry,
374
414
  coordinates: e
375
415
  };
376
416
  return {
377
417
  ...t,
378
- geometry: c
418
+ geometry: d
379
419
  };
380
420
  }
381
421
  export {
382
- to as ThreeDGlobe
422
+ po as ThreeDGlobe
383
423
  };
384
424
  //# sourceMappingURL=ThreeDGlobe.js.map