@burdenoff/microfe-ecoimpacthub 2026.704.4 → 2026.704.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.
Files changed (47) hide show
  1. package/dist/ecoimpacthub/pages/DashboardPage.js +345 -189
  2. package/dist/ecoimpacthub/pages/DashboardPage.js.map +1 -1
  3. package/dist/ecoimpacthub/pages/_shared/ConservationBadge.js +58 -0
  4. package/dist/ecoimpacthub/pages/_shared/ConservationBadge.js.map +1 -0
  5. package/dist/ecoimpacthub/pages/_shared/EvidenceThumb.js +70 -0
  6. package/dist/ecoimpacthub/pages/_shared/EvidenceThumb.js.map +1 -0
  7. package/dist/ecoimpacthub/pages/_shared/MethodBadge.js +51 -0
  8. package/dist/ecoimpacthub/pages/_shared/MethodBadge.js.map +1 -0
  9. package/dist/ecoimpacthub/pages/_shared/TaxonChip.js +29 -0
  10. package/dist/ecoimpacthub/pages/_shared/TaxonChip.js.map +1 -0
  11. package/dist/ecoimpacthub/pages/badges.js +71 -0
  12. package/dist/ecoimpacthub/pages/badges.js.map +1 -0
  13. package/dist/ecoimpacthub/pages/carbon/CarbonPage.js +337 -300
  14. package/dist/ecoimpacthub/pages/carbon/CarbonPage.js.map +1 -1
  15. package/dist/ecoimpacthub/pages/carbonVisuals.js +89 -0
  16. package/dist/ecoimpacthub/pages/carbonVisuals.js.map +1 -0
  17. package/dist/ecoimpacthub/pages/habitat/HabitatProjectDetailPage.js +252 -218
  18. package/dist/ecoimpacthub/pages/habitat/HabitatProjectDetailPage.js.map +1 -1
  19. package/dist/ecoimpacthub/pages/habitat/HabitatProjectsPage.js +15 -12
  20. package/dist/ecoimpacthub/pages/habitat/HabitatProjectsPage.js.map +1 -1
  21. package/dist/ecoimpacthub/pages/habitat/LifecycleProgress.js +168 -0
  22. package/dist/ecoimpacthub/pages/habitat/LifecycleProgress.js.map +1 -0
  23. package/dist/ecoimpacthub/pages/monitoring/MonitoringPage.js +30 -17
  24. package/dist/ecoimpacthub/pages/monitoring/MonitoringPage.js.map +1 -1
  25. package/dist/ecoimpacthub/pages/observations/ObservationsPage.js +236 -219
  26. package/dist/ecoimpacthub/pages/observations/ObservationsPage.js.map +1 -1
  27. package/dist/ecoimpacthub/pages/reports/ReportDetailPage.js +248 -212
  28. package/dist/ecoimpacthub/pages/reports/ReportDetailPage.js.map +1 -1
  29. package/dist/ecoimpacthub/pages/reports/ReportsPage.js +119 -118
  30. package/dist/ecoimpacthub/pages/reports/ReportsPage.js.map +1 -1
  31. package/dist/ecoimpacthub/pages/sites/SiteDetailPage.js +498 -370
  32. package/dist/ecoimpacthub/pages/sites/SiteDetailPage.js.map +1 -1
  33. package/dist/ecoimpacthub/pages/sites/SitesPage.js +109 -99
  34. package/dist/ecoimpacthub/pages/sites/SitesPage.js.map +1 -1
  35. package/dist/ecoimpacthub/pages/sites/siteTypeVisuals.js +64 -0
  36. package/dist/ecoimpacthub/pages/sites/siteTypeVisuals.js.map +1 -0
  37. package/dist/ecoimpacthub/pages/species/SpeciesDetailPage.js +275 -259
  38. package/dist/ecoimpacthub/pages/species/SpeciesDetailPage.js.map +1 -1
  39. package/dist/ecoimpacthub/pages/species/SpeciesPage.js +235 -177
  40. package/dist/ecoimpacthub/pages/species/SpeciesPage.js.map +1 -1
  41. package/dist/node_modules/recharts/es6/cartesian/CartesianGrid.js +305 -0
  42. package/dist/node_modules/recharts/es6/cartesian/CartesianGrid.js.map +1 -0
  43. package/dist/node_modules/recharts/es6/context/chartLayoutContext.js +44 -33
  44. package/dist/node_modules/recharts/es6/context/chartLayoutContext.js.map +1 -1
  45. package/dist/node_modules/recharts/es6/util/ChartUtils.js +31 -23
  46. package/dist/node_modules/recharts/es6/util/ChartUtils.js.map +1 -1
  47. package/package.json +1 -1
@@ -3,60 +3,67 @@ import { Tooltip as t } from "../../node_modules/recharts/es6/component/Tooltip.
3
3
  import { ResponsiveContainer as n } from "../../node_modules/recharts/es6/component/ResponsiveContainer.js";
4
4
  import { Cell as r } from "../../node_modules/recharts/es6/component/Cell.js";
5
5
  import { LabelList as i } from "../../node_modules/recharts/es6/component/LabelList.js";
6
- import { Bar as ee } from "../../node_modules/recharts/es6/cartesian/Bar.js";
7
- import { XAxis as a } from "../../node_modules/recharts/es6/cartesian/XAxis.js";
8
- import { YAxis as o } from "../../node_modules/recharts/es6/cartesian/YAxis.js";
9
- import { BarChart as s } from "../../node_modules/recharts/es6/chart/BarChart.js";
6
+ import { Bar as a } from "../../node_modules/recharts/es6/cartesian/Bar.js";
7
+ import { CartesianGrid as o } from "../../node_modules/recharts/es6/cartesian/CartesianGrid.js";
8
+ import { XAxis as s } from "../../node_modules/recharts/es6/cartesian/XAxis.js";
9
+ import { YAxis as ee } from "../../node_modules/recharts/es6/cartesian/YAxis.js";
10
+ import { BarChart as te } from "../../node_modules/recharts/es6/chart/BarChart.js";
10
11
  import { PageLayout as c } from "../components/PageLayout.js";
11
12
  import { MetricsCard as l } from "../components/MetricsCard.js";
12
- import { formatCo2e as u, formatEnumLabel as te, formatNumber as d, formatRelativeTime as f } from "../utils/formatters.js";
13
- import { StatusBadge as p } from "../components/StatusBadge.js";
14
- import { MiniBar as m } from "../components/MiniBar.js";
15
- import { LoadingView as h, Section as g } from "../components/StateViews.js";
16
- import { EmptyState as _ } from "../components/EmptyState.js";
13
+ import { formatCo2e as u, formatEnumLabel as d, formatNumber as f, formatPercent as p, formatRelativeTime as m } from "../utils/formatters.js";
14
+ import { StatusBadge as h } from "../components/StatusBadge.js";
15
+ import { MiniBar as g } from "../components/MiniBar.js";
16
+ import { LoadingView as ne, Section as _ } from "../components/StateViews.js";
17
+ import { EmptyState as v } from "../components/EmptyState.js";
18
+ import { Meter as re, SCOPE_HUE as y, ScopeLegend as ie, ScopeSplitBar as b } from "./carbonVisuals.js";
17
19
  import "../context/index.js";
18
- import { useEcoCarbonTotals as v, useEcoHabitatProjects as y, useEcoMeasurements as b, useEcoObservations as x, useEcoSensors as S, useEcoSites as C, useEcoSpecies as w } from "../hooks/useEcoImpactHubApi.js";
20
+ import { useEcoCarbonTotals as x, useEcoHabitatProjects as ae, useEcoMeasurements as oe, useEcoObservations as S, useEcoSensors as C, useEcoSites as w, useEcoSpecies as se } from "../hooks/useEcoImpactHubApi.js";
19
21
  import "../hooks/index.js";
20
- import { useMemo as ne } from "react";
21
- import { ArrowRight as T, Binoculars as re, Factory as E, MapPin as ie, PawPrint as ae, Radio as D, ShieldCheck as O, Trees as k, TriangleAlert as A } from "lucide-react";
22
- import { jsx as j, jsxs as M } from "react/jsx-runtime";
23
- import { GlassCard as N } from "@burdenoff/fe-libs/ui";
22
+ import { useMemo as ce } from "react";
23
+ import { ArrowRight as T, Binoculars as E, Factory as D, MapPin as le, PawPrint as ue, Radio as de, ShieldCheck as fe, Trees as pe, TriangleAlert as O } from "lucide-react";
24
+ import { Fragment as k, jsx as A, jsxs as j } from "react/jsx-runtime";
25
+ import { GlassCard as M } from "@burdenoff/fe-libs/ui";
24
26
  //#region src/ecoimpacthub/pages/DashboardPage.tsx
25
- var P = new Set([
27
+ var N = new Set([
26
28
  "PLANNED",
27
29
  "IN_PROGRESS",
28
30
  "MONITORING"
29
- ]), F = {
30
- SCOPE_1: "var(--color-status-error-text)",
31
- SCOPE_2: "var(--color-status-warning-text)",
32
- SCOPE_3: "var(--color-accent)"
31
+ ]), P = {
32
+ LEAST_CONCERN: "var(--color-status-success-text)",
33
+ NEAR_THREATENED: "var(--color-accent-teal)",
34
+ VULNERABLE: "var(--color-status-warning-text)",
35
+ ENDANGERED: "var(--color-status-error-text)",
36
+ CRITICALLY_ENDANGERED: "var(--color-status-error-text)",
37
+ EXTINCT_IN_WILD: "var(--color-text-tertiary)",
38
+ DATA_DEFICIENT: "var(--color-text-tertiary)",
39
+ NOT_EVALUATED: "var(--color-text-tertiary)"
33
40
  };
34
- function I() {
35
- let { navigateTo: I, currentUser: L } = e(), R = C({ pagination: {
41
+ function F() {
42
+ let { navigateTo: F, currentUser: I } = e(), L = w({ pagination: {
36
43
  limit: 100,
37
44
  offset: 0
38
- } }), z = w({ pagination: {
45
+ } }), R = se({ pagination: {
39
46
  limit: 100,
40
47
  offset: 0
41
- } }), B = y(), V = v(), H = b({
48
+ } }), z = ae(), B = x(), V = oe({
42
49
  breachesOnly: !0,
43
50
  pagination: {
44
51
  limit: 6,
45
52
  offset: 0
46
53
  }
47
- }), U = x({ pagination: {
54
+ }), me = S({ pagination: {
48
55
  limit: 6,
49
56
  offset: 0
50
- } }), W = S(), G = R.data?.items ?? [], K = z.data?.items ?? [], q = B.data ?? [], J = W.data ?? [], oe = G.filter((e) => e.status === "ACTIVE").length, se = K.filter((e) => e.isPriority).length, Y = K.filter((e) => [
57
+ } }), he = C(), H = L.data?.items ?? [], U = R.data?.items ?? [], W = z.data ?? [], G = he.data ?? [], K = H.filter((e) => e.status === "ACTIVE").length, ge = U.filter((e) => e.isPriority).length, q = U.filter((e) => [
51
58
  "VULNERABLE",
52
59
  "ENDANGERED",
53
60
  "CRITICALLY_ENDANGERED"
54
- ].includes(e.conservationStatus)).length, ce = q.filter((e) => P.has(e.status)).length, le = J.filter((e) => e.status === "ONLINE").length, X = J.filter((e) => [
61
+ ].includes(e.conservationStatus)).length, J = W.filter((e) => N.has(e.status)).length, Y = G.filter((e) => e.status === "ONLINE").length, X = G.filter((e) => [
55
62
  "OFFLINE",
56
63
  "DEGRADED",
57
64
  "MAINTENANCE"
58
- ].includes(e.status)).length, Z = ne(() => {
59
- let e = V.data;
65
+ ].includes(e.status)).length, Z = ce(() => {
66
+ let e = B.data;
60
67
  return e ? [
61
68
  {
62
69
  scope: "SCOPE_1",
@@ -74,128 +81,231 @@ function I() {
74
81
  kg: e.scope3
75
82
  }
76
83
  ] : [];
77
- }, [V.data]);
78
- if (R.isLoading && z.isLoading && B.isLoading && V.isLoading) return /* @__PURE__ */ j(c, {
84
+ }, [B.data]);
85
+ if (L.isLoading && R.isLoading && z.isLoading && B.isLoading) return /* @__PURE__ */ A(c, {
79
86
  title: "EcoImpactHub",
80
87
  titleGradient: !0,
81
88
  aurora: !0,
82
- children: /* @__PURE__ */ j(h, { label: "Loading your impact overview…" })
89
+ children: /* @__PURE__ */ A(ne, { label: "Loading your impact overview…" })
83
90
  });
84
- let ue = L?.firstName || L?.name || "there", Q = H.data?.items ?? [], $ = U.data?.items ?? [];
85
- return /* @__PURE__ */ M(c, {
91
+ let _e = I?.firstName || I?.name || "there", Q = V.data?.items ?? [], $ = me.data?.items ?? [];
92
+ return /* @__PURE__ */ j(c, {
86
93
  title: "EcoImpactHub",
87
94
  titleGradient: !0,
88
95
  aurora: !0,
89
- description: `Welcome back, ${ue} — your environment, conservation & sustainability control room.`,
96
+ description: `Welcome back, ${_e} — your environment, conservation & sustainability control room.`,
90
97
  children: [
91
- /* @__PURE__ */ M("div", {
98
+ /* @__PURE__ */ j("div", {
92
99
  className: "grid grid-cols-1 gap-4 sm:grid-cols-2 lg:grid-cols-3 xl:grid-cols-6",
93
100
  children: [
94
- /* @__PURE__ */ j(l, {
95
- icon: /* @__PURE__ */ j(ie, { className: "h-5 w-5" }),
96
- value: R.data?.pageInfo?.hasMore ? `${G.length}+` : d(G.length),
101
+ /* @__PURE__ */ A(l, {
102
+ icon: /* @__PURE__ */ A(le, { className: "h-5 w-5" }),
103
+ value: L.data?.pageInfo?.hasMore ? `${H.length}+` : f(H.length),
97
104
  label: "Monitored sites",
98
- footer: /* @__PURE__ */ M("p", {
99
- className: "text-xs text-text-tertiary",
100
- children: [oe, " active"]
105
+ footer: /* @__PURE__ */ j("div", {
106
+ className: "space-y-2",
107
+ children: [/* @__PURE__ */ A(g, {
108
+ value: H.length ? K / H.length * 100 : 0,
109
+ height: 4,
110
+ barClassName: "bg-action-primary-bg"
111
+ }), /* @__PURE__ */ j("p", {
112
+ className: "text-xs text-text-tertiary",
113
+ children: [/* @__PURE__ */ A("span", {
114
+ className: "tabular-nums text-text-secondary",
115
+ children: K
116
+ }), " active"]
117
+ })]
101
118
  })
102
119
  }),
103
- /* @__PURE__ */ j(l, {
104
- icon: /* @__PURE__ */ j(ae, { className: "h-5 w-5" }),
105
- value: z.data?.pageInfo?.hasMore ? `${K.length}+` : d(K.length),
120
+ /* @__PURE__ */ A(l, {
121
+ icon: /* @__PURE__ */ A(ue, { className: "h-5 w-5" }),
122
+ value: R.data?.pageInfo?.hasMore ? `${U.length}+` : f(U.length),
106
123
  label: "Species tracked",
107
- accent: Y > 0 ? "warning" : void 0,
108
- footer: /* @__PURE__ */ M("p", {
109
- className: "text-xs text-text-tertiary",
110
- children: [
111
- se,
112
- " priority · ",
113
- Y,
114
- " threatened"
115
- ]
124
+ accent: q > 0 ? "warning" : void 0,
125
+ footer: /* @__PURE__ */ j("div", {
126
+ className: "space-y-2",
127
+ children: [/* @__PURE__ */ A(g, {
128
+ value: U.length ? q / U.length * 100 : 0,
129
+ height: 4,
130
+ barClassName: "bg-status-warning-text"
131
+ }), /* @__PURE__ */ j("p", {
132
+ className: "text-xs text-text-tertiary",
133
+ children: [
134
+ /* @__PURE__ */ A("span", {
135
+ className: "tabular-nums text-text-secondary",
136
+ children: ge
137
+ }),
138
+ " priority ·",
139
+ " ",
140
+ /* @__PURE__ */ A("span", {
141
+ className: "tabular-nums text-text-secondary",
142
+ children: q
143
+ }),
144
+ " threatened"
145
+ ]
146
+ })]
116
147
  })
117
148
  }),
118
- /* @__PURE__ */ j(l, {
119
- icon: /* @__PURE__ */ j(k, { className: "h-5 w-5" }),
120
- value: d(ce),
149
+ /* @__PURE__ */ A(l, {
150
+ icon: /* @__PURE__ */ A(pe, { className: "h-5 w-5" }),
151
+ value: f(J),
121
152
  label: "Active habitat projects",
122
- footer: /* @__PURE__ */ M("p", {
123
- className: "text-xs text-text-tertiary",
124
- children: [d(q.length), " total"]
153
+ footer: /* @__PURE__ */ j("div", {
154
+ className: "space-y-2",
155
+ children: [/* @__PURE__ */ A(g, {
156
+ value: W.length ? J / W.length * 100 : 0,
157
+ height: 4,
158
+ barClassName: "bg-action-primary-bg"
159
+ }), /* @__PURE__ */ j("p", {
160
+ className: "text-xs text-text-tertiary",
161
+ children: [
162
+ /* @__PURE__ */ A("span", {
163
+ className: "tabular-nums text-text-secondary",
164
+ children: f(W.length)
165
+ }),
166
+ " ",
167
+ "total"
168
+ ]
169
+ })]
125
170
  })
126
171
  }),
127
- /* @__PURE__ */ j(l, {
128
- icon: /* @__PURE__ */ j(E, { className: "h-5 w-5" }),
129
- value: V.data ? u(V.data.total) : "—",
172
+ /* @__PURE__ */ A(l, {
173
+ icon: /* @__PURE__ */ A(D, { className: "h-5 w-5" }),
174
+ value: B.data ? u(B.data.total) : "—",
130
175
  label: "Total footprint",
131
- featured: !0
176
+ featured: !0,
177
+ footer: B.data && B.data.total > 0 ? /* @__PURE__ */ j("div", {
178
+ className: "space-y-2",
179
+ children: [/* @__PURE__ */ A(b, {
180
+ scope1: B.data.scope1,
181
+ scope2: B.data.scope2,
182
+ scope3: B.data.scope3,
183
+ height: 6
184
+ }), /* @__PURE__ */ A("p", {
185
+ className: "text-xs text-text-tertiary",
186
+ children: "Scope 1 · 2 · 3 split"
187
+ })]
188
+ }) : void 0
132
189
  }),
133
- /* @__PURE__ */ j(l, {
134
- icon: /* @__PURE__ */ j(D, { className: "h-5 w-5" }),
135
- value: d(le),
190
+ /* @__PURE__ */ A(l, {
191
+ icon: /* @__PURE__ */ A(de, { className: "h-5 w-5" }),
192
+ value: f(Y),
136
193
  label: "Sensors online",
137
194
  accent: X > 0 ? "warning" : "success",
138
- footer: /* @__PURE__ */ M("p", {
139
- className: "text-xs text-text-tertiary",
140
- children: [X, " need attention"]
195
+ footer: /* @__PURE__ */ j("div", {
196
+ className: "space-y-2",
197
+ children: [/* @__PURE__ */ A(g, {
198
+ value: G.length ? Y / G.length * 100 : 0,
199
+ height: 4,
200
+ barClassName: "bg-status-success-text"
201
+ }), /* @__PURE__ */ j("p", {
202
+ className: "text-xs text-text-tertiary",
203
+ children: [/* @__PURE__ */ A("span", {
204
+ className: "tabular-nums text-text-secondary",
205
+ children: X
206
+ }), " need attention"]
207
+ })]
141
208
  })
142
209
  }),
143
- /* @__PURE__ */ j(l, {
144
- icon: /* @__PURE__ */ j(A, { className: "h-5 w-5" }),
145
- value: H.data?.pageInfo?.hasMore ? `${Q.length}+` : d(Q.length),
210
+ /* @__PURE__ */ A(l, {
211
+ icon: /* @__PURE__ */ A(O, { className: "h-5 w-5" }),
212
+ value: V.data?.pageInfo?.hasMore ? `${Q.length}+` : f(Q.length),
146
213
  label: "Open breaches",
147
- accent: Q.length > 0 ? "error" : "success"
214
+ accent: Q.length > 0 ? "error" : "success",
215
+ footer: /* @__PURE__ */ A("p", {
216
+ className: Q.length > 0 ? "text-xs font-medium text-status-error-text" : "text-xs text-text-tertiary",
217
+ children: Q.length > 0 ? "Needs attention" : "All parameters in range"
218
+ })
148
219
  })
149
220
  ]
150
221
  }),
151
- /* @__PURE__ */ M("div", {
222
+ /* @__PURE__ */ j("div", {
152
223
  className: "mt-6 grid grid-cols-1 gap-6 lg:grid-cols-3",
153
- children: [/* @__PURE__ */ M(N, {
224
+ children: [/* @__PURE__ */ j(M, {
154
225
  treatment: "glass",
155
226
  className: "p-6 lg:col-span-2",
156
- children: [/* @__PURE__ */ M("div", {
157
- className: "mb-4 flex items-center justify-between",
158
- children: [/* @__PURE__ */ M("div", { children: [/* @__PURE__ */ j("h2", {
227
+ children: [/* @__PURE__ */ j("div", {
228
+ className: "mb-4 flex flex-wrap items-start justify-between gap-3",
229
+ children: [/* @__PURE__ */ j("div", { children: [/* @__PURE__ */ A("h2", {
159
230
  className: "text-base font-semibold text-text-primary",
160
231
  children: "Carbon footprint by scope"
161
- }), /* @__PURE__ */ j("p", {
232
+ }), /* @__PURE__ */ A("p", {
162
233
  className: "mt-0.5 text-sm text-text-secondary",
163
234
  children: "GHG Protocol Scope 1 / 2 / 3 emissions (CO₂e)."
164
- })] }), /* @__PURE__ */ M("button", {
165
- type: "button",
166
- onClick: () => I("carbon"),
167
- className: "inline-flex items-center gap-1 text-sm font-medium text-accent hover:underline",
168
- children: ["Ledger ", /* @__PURE__ */ j(T, { className: "h-4 w-4" })]
235
+ })] }), /* @__PURE__ */ j("div", {
236
+ className: "flex items-center gap-4",
237
+ children: [B.data && B.data.total > 0 && /* @__PURE__ */ j("div", {
238
+ className: "text-right",
239
+ children: [/* @__PURE__ */ A("p", {
240
+ className: "text-lg font-semibold tabular-nums text-text-primary",
241
+ children: u(B.data.total)
242
+ }), /* @__PURE__ */ A("p", {
243
+ className: "text-xs text-text-tertiary",
244
+ children: "total"
245
+ })]
246
+ }), /* @__PURE__ */ j("button", {
247
+ type: "button",
248
+ onClick: () => F("carbon"),
249
+ className: "inline-flex items-center gap-1 text-sm font-medium text-accent hover:underline",
250
+ children: ["Ledger ", /* @__PURE__ */ A(T, { className: "h-4 w-4" })]
251
+ })]
169
252
  })]
170
- }), Z.every((e) => e.kg === 0) ? /* @__PURE__ */ j(_, {
253
+ }), Z.every((e) => e.kg === 0) ? /* @__PURE__ */ A(v, {
171
254
  illustration: "empty-data",
172
- icon: /* @__PURE__ */ j(E, { className: "h-10 w-10" }),
255
+ icon: /* @__PURE__ */ A(D, { className: "h-10 w-10" }),
173
256
  title: "No carbon entries yet",
174
257
  description: "Record activity in the carbon ledger to see your Scope 1–3 footprint here."
175
- }) : /* @__PURE__ */ j("div", {
258
+ }) : /* @__PURE__ */ j(k, { children: [/* @__PURE__ */ A("div", {
176
259
  className: "h-56",
177
- children: /* @__PURE__ */ j(n, {
260
+ children: /* @__PURE__ */ A(n, {
178
261
  width: "100%",
179
262
  height: "100%",
180
- children: /* @__PURE__ */ M(s, {
263
+ children: /* @__PURE__ */ j(te, {
181
264
  data: Z,
182
265
  margin: {
183
- top: 16,
266
+ top: 20,
184
267
  right: 8,
185
268
  left: 8,
186
269
  bottom: 0
187
270
  },
188
271
  children: [
189
- /* @__PURE__ */ j(a, {
272
+ /* @__PURE__ */ A("defs", { children: Z.map((e) => /* @__PURE__ */ j("linearGradient", {
273
+ id: `ecoScopeGrad-${e.scope}`,
274
+ x1: "0",
275
+ y1: "0",
276
+ x2: "0",
277
+ y2: "1",
278
+ children: [/* @__PURE__ */ A("stop", {
279
+ offset: "0%",
280
+ style: {
281
+ stopColor: y[e.scope],
282
+ stopOpacity: 1
283
+ }
284
+ }), /* @__PURE__ */ A("stop", {
285
+ offset: "100%",
286
+ style: {
287
+ stopColor: y[e.scope],
288
+ stopOpacity: .55
289
+ }
290
+ })]
291
+ }, e.scope)) }),
292
+ /* @__PURE__ */ A(o, {
293
+ vertical: !1,
294
+ stroke: "var(--color-border-seam)",
295
+ strokeOpacity: .6,
296
+ strokeDasharray: "3 4"
297
+ }),
298
+ /* @__PURE__ */ A(s, {
190
299
  dataKey: "label",
191
300
  tick: {
192
301
  fill: "var(--color-text-secondary)",
193
302
  fontSize: 12
194
303
  },
195
304
  axisLine: { stroke: "var(--color-border-seam)" },
196
- tickLine: !1
305
+ tickLine: !1,
306
+ dy: 4
197
307
  }),
198
- /* @__PURE__ */ j(o, {
308
+ /* @__PURE__ */ A(ee, {
199
309
  tick: {
200
310
  fill: "var(--color-text-tertiary)",
201
311
  fontSize: 11
@@ -205,7 +315,7 @@ function I() {
205
315
  width: 48,
206
316
  tickFormatter: (e) => e >= 1e3 ? `${Math.round(e / 1e3)}t` : `${e}`
207
317
  }),
208
- /* @__PURE__ */ j(t, {
318
+ /* @__PURE__ */ A(t, {
209
319
  cursor: {
210
320
  fill: "var(--color-bg-sunken)",
211
321
  opacity: .4
@@ -218,149 +328,195 @@ function I() {
218
328
  },
219
329
  formatter: (e) => [u(e), "Emissions"]
220
330
  }),
221
- /* @__PURE__ */ M(ee, {
331
+ /* @__PURE__ */ j(a, {
222
332
  dataKey: "kg",
223
333
  radius: [
224
- 6,
225
- 6,
226
- 0,
227
- 0
334
+ 8,
335
+ 8,
336
+ 2,
337
+ 2
228
338
  ],
229
- maxBarSize: 80,
230
- children: [Z.map((e) => /* @__PURE__ */ j(r, { fill: F[e.scope] }, e.scope)), /* @__PURE__ */ j(i, {
339
+ maxBarSize: 72,
340
+ children: [Z.map((e) => /* @__PURE__ */ A(r, { fill: `url(#ecoScopeGrad-${e.scope})` }, e.scope)), /* @__PURE__ */ A(i, {
231
341
  dataKey: "kg",
232
342
  position: "top",
233
343
  formatter: (e) => e > 0 ? u(e) : "",
234
344
  style: {
235
345
  fill: "var(--color-text-secondary)",
236
- fontSize: 11
346
+ fontSize: 11,
347
+ fontWeight: 600
237
348
  }
238
349
  })]
239
350
  })
240
351
  ]
241
352
  })
242
353
  })
243
- })]
244
- }), /* @__PURE__ */ M(N, {
354
+ }), /* @__PURE__ */ A(ie, {
355
+ data: Z,
356
+ className: "mt-4 border-t border-border-seam pt-4"
357
+ })] })]
358
+ }), /* @__PURE__ */ j(M, {
245
359
  treatment: "glass",
246
360
  className: "p-6",
247
- children: [/* @__PURE__ */ M("div", {
248
- className: "mb-4 flex items-center justify-between",
249
- children: [/* @__PURE__ */ j("h2", {
250
- className: "text-base font-semibold text-text-primary",
251
- children: "Recent breaches"
252
- }), /* @__PURE__ */ M("button", {
361
+ children: [/* @__PURE__ */ j("div", {
362
+ className: "mb-4 flex items-center justify-between gap-3",
363
+ children: [/* @__PURE__ */ j("div", {
364
+ className: "flex items-center gap-2",
365
+ children: [/* @__PURE__ */ A("h2", {
366
+ className: "text-base font-semibold text-text-primary",
367
+ children: "Recent breaches"
368
+ }), Q.length > 0 && /* @__PURE__ */ A("span", {
369
+ className: "rounded-full bg-status-error-bg-subtle px-2 py-0.5 text-xs font-medium tabular-nums text-status-error-text",
370
+ children: V.data?.pageInfo?.hasMore ? `${Q.length}+` : Q.length
371
+ })]
372
+ }), /* @__PURE__ */ j("button", {
253
373
  type: "button",
254
- onClick: () => I("monitoring"),
374
+ onClick: () => F("monitoring"),
255
375
  className: "inline-flex items-center gap-1 text-sm font-medium text-accent hover:underline",
256
- children: ["Monitoring ", /* @__PURE__ */ j(T, { className: "h-4 w-4" })]
376
+ children: ["Monitoring ", /* @__PURE__ */ A(T, { className: "h-4 w-4" })]
257
377
  })]
258
- }), Q.length === 0 ? /* @__PURE__ */ M("div", {
259
- className: "flex flex-col items-center justify-center py-8 text-center",
260
- children: [/* @__PURE__ */ j(O, { className: "h-10 w-10 text-status-success-text opacity-70" }), /* @__PURE__ */ j("p", {
261
- className: "mt-3 text-sm text-text-secondary",
262
- children: "No threshold breaches — all parameters within range."
263
- })]
264
- }) : /* @__PURE__ */ j("ul", {
265
- className: "space-y-3",
266
- children: Q.map((e) => /* @__PURE__ */ M("li", {
267
- className: "flex items-start justify-between gap-3",
268
- children: [/* @__PURE__ */ M("div", {
269
- className: "min-w-0",
270
- children: [/* @__PURE__ */ j("p", {
271
- className: "truncate text-sm font-medium text-text-primary",
272
- children: e.parameter
273
- }), /* @__PURE__ */ M("p", {
274
- className: "text-xs text-text-tertiary",
275
- children: [
276
- d(e.value),
277
- " ",
278
- e.unit,
279
- " · ",
280
- f(e.recordedAt)
281
- ]
378
+ }), Q.length === 0 ? /* @__PURE__ */ j("div", {
379
+ className: "flex flex-col items-center justify-center rounded-xl border border-dashed border-border-seam py-10 text-center",
380
+ children: [
381
+ /* @__PURE__ */ A("span", {
382
+ className: "flex size-12 items-center justify-center rounded-full bg-status-success-bg-subtle",
383
+ children: /* @__PURE__ */ A(fe, { className: "h-6 w-6 text-status-success-text" })
384
+ }),
385
+ /* @__PURE__ */ A("p", {
386
+ className: "mt-3 text-sm font-medium text-text-primary",
387
+ children: "All parameters in range"
388
+ }),
389
+ /* @__PURE__ */ A("p", {
390
+ className: "mt-1 text-xs text-text-tertiary",
391
+ children: "No open threshold breaches."
392
+ })
393
+ ]
394
+ }) : /* @__PURE__ */ A("ul", {
395
+ className: "space-y-2.5",
396
+ children: Q.map((e) => /* @__PURE__ */ j("li", {
397
+ className: "flex items-start justify-between gap-3 rounded-xl bg-bg-sunken/50 p-3",
398
+ children: [/* @__PURE__ */ j("div", {
399
+ className: "flex min-w-0 items-start gap-2.5",
400
+ children: [/* @__PURE__ */ A("span", {
401
+ "aria-hidden": "true",
402
+ className: "mt-1.5 size-2 shrink-0 rounded-full bg-status-error-text motion-safe:animate-vc-glow-pulse"
403
+ }), /* @__PURE__ */ j("div", {
404
+ className: "min-w-0",
405
+ children: [/* @__PURE__ */ A("p", {
406
+ className: "truncate text-sm font-medium text-text-primary",
407
+ children: e.parameter
408
+ }), /* @__PURE__ */ j("p", {
409
+ className: "text-xs text-text-tertiary",
410
+ children: [
411
+ /* @__PURE__ */ j("span", {
412
+ className: "tabular-nums",
413
+ children: [
414
+ f(e.value),
415
+ " ",
416
+ e.unit
417
+ ]
418
+ }),
419
+ " ",
420
+ "· ",
421
+ m(e.recordedAt)
422
+ ]
423
+ })]
282
424
  })]
283
- }), /* @__PURE__ */ j(p, { status: "BREACH" })]
425
+ }), /* @__PURE__ */ A(h, { status: "BREACH" })]
284
426
  }, e.id))
285
427
  })]
286
428
  })]
287
429
  }),
288
- /* @__PURE__ */ j(g, {
430
+ /* @__PURE__ */ A(_, {
289
431
  title: "Recent field observations",
290
432
  description: "Latest wildlife & biodiversity sightings recorded across your sites.",
291
- action: /* @__PURE__ */ M("button", {
433
+ action: /* @__PURE__ */ j("button", {
292
434
  type: "button",
293
- onClick: () => I("observations"),
435
+ onClick: () => F("observations"),
294
436
  className: "inline-flex items-center gap-1 text-sm font-medium text-accent hover:underline",
295
- children: ["All observations ", /* @__PURE__ */ j(T, { className: "h-4 w-4" })]
437
+ children: ["All observations ", /* @__PURE__ */ A(T, { className: "h-4 w-4" })]
296
438
  }),
297
- children: $.length === 0 ? /* @__PURE__ */ j(_, {
439
+ children: $.length === 0 ? /* @__PURE__ */ A(v, {
298
440
  illustration: "empty-data",
299
- icon: /* @__PURE__ */ j(re, { className: "h-10 w-10" }),
441
+ icon: /* @__PURE__ */ A(E, { className: "h-10 w-10" }),
300
442
  title: "No observations yet",
301
443
  description: "Record your first field observation to build your biodiversity dataset."
302
- }) : /* @__PURE__ */ j("div", {
444
+ }) : /* @__PURE__ */ A("div", {
303
445
  className: "grid grid-cols-1 gap-4 sm:grid-cols-2 lg:grid-cols-3",
304
- children: $.map((e) => /* @__PURE__ */ M(N, {
446
+ children: $.map((e) => /* @__PURE__ */ j(M, {
305
447
  treatment: "plain",
306
- className: "p-4",
307
- children: [/* @__PURE__ */ M("div", {
448
+ className: "p-4 transition-shadow hover:shadow-float",
449
+ children: [/* @__PURE__ */ j("div", {
308
450
  className: "flex items-start justify-between gap-2",
309
- children: [/* @__PURE__ */ M("div", {
310
- className: "min-w-0",
311
- children: [/* @__PURE__ */ j("p", {
312
- className: "truncate text-sm font-semibold text-text-primary",
313
- children: e.species?.commonName ?? "Unknown species"
314
- }), e.species?.scientificName && /* @__PURE__ */ j("p", {
315
- className: "truncate text-xs italic text-text-tertiary",
316
- children: e.species.scientificName
451
+ children: [/* @__PURE__ */ j("div", {
452
+ className: "flex min-w-0 items-start gap-2.5",
453
+ children: [/* @__PURE__ */ A("span", {
454
+ className: "mt-0.5 flex size-8 shrink-0 items-center justify-center rounded-lg bg-[var(--color-accent-soft)] text-accent",
455
+ children: /* @__PURE__ */ A(E, { className: "h-4 w-4" })
456
+ }), /* @__PURE__ */ j("div", {
457
+ className: "min-w-0",
458
+ children: [/* @__PURE__ */ A("p", {
459
+ className: "truncate text-sm font-semibold text-text-primary",
460
+ children: e.species?.commonName ?? "Unknown species"
461
+ }), e.species?.scientificName && /* @__PURE__ */ A("p", {
462
+ className: "truncate text-xs italic text-text-tertiary",
463
+ children: e.species.scientificName
464
+ })]
317
465
  })]
318
- }), /* @__PURE__ */ M("span", {
319
- className: "shrink-0 rounded-full bg-bg-sunken px-2 py-0.5 text-xs tabular-nums text-text-secondary",
320
- children: ["×", d(e.count)]
321
- })]
322
- }), /* @__PURE__ */ M("div", {
323
- className: "mt-3 flex items-center justify-between",
324
- children: [/* @__PURE__ */ j("span", {
325
- className: "text-xs text-text-tertiary",
326
- children: te(e.method)
327
466
  }), /* @__PURE__ */ j("span", {
467
+ className: "shrink-0 rounded-full bg-[var(--color-accent-soft)] px-2 py-0.5 text-xs font-medium tabular-nums text-text-primary",
468
+ children: ["×", f(e.count)]
469
+ })]
470
+ }), /* @__PURE__ */ j("div", {
471
+ className: "mt-3 flex items-center justify-between border-t border-border-seam/70 pt-2.5",
472
+ children: [/* @__PURE__ */ A("span", {
473
+ className: "rounded-full bg-bg-sunken px-2 py-0.5 text-xs text-text-secondary",
474
+ children: d(e.method)
475
+ }), /* @__PURE__ */ A("span", {
328
476
  className: "text-xs text-text-tertiary",
329
- children: f(e.observedAt)
477
+ children: m(e.observedAt)
330
478
  })]
331
479
  })]
332
480
  }, e.id))
333
481
  })
334
482
  }),
335
- K.length > 0 && /* @__PURE__ */ j(g, {
483
+ U.length > 0 && /* @__PURE__ */ A(_, {
336
484
  title: "Conservation status",
337
485
  description: "Distribution of tracked species by IUCN-style status.",
338
- children: /* @__PURE__ */ j(N, {
486
+ children: /* @__PURE__ */ A(M, {
339
487
  treatment: "plain",
340
488
  className: "p-6",
341
- children: /* @__PURE__ */ j("div", {
342
- className: "space-y-3",
489
+ children: /* @__PURE__ */ A("div", {
490
+ className: "space-y-3.5",
343
491
  children: (() => {
344
492
  let e = /* @__PURE__ */ new Map();
345
- for (let t of K) e.set(t.conservationStatus, (e.get(t.conservationStatus) ?? 0) + 1);
346
- let t = K.length;
347
- return [...e.entries()].sort((e, t) => t[1] - e[1]).map(([e, n]) => /* @__PURE__ */ M("div", {
348
- className: "flex items-center gap-4",
349
- children: [
350
- /* @__PURE__ */ j("div", {
351
- className: "w-48 shrink-0",
352
- children: /* @__PURE__ */ j(p, { status: e })
353
- }),
354
- /* @__PURE__ */ j(m, {
355
- value: n / t * 100,
356
- className: "flex-1"
357
- }),
358
- /* @__PURE__ */ j("span", {
359
- className: "w-10 shrink-0 text-right text-sm tabular-nums text-text-secondary",
360
- children: n
361
- })
362
- ]
363
- }, e));
493
+ for (let t of U) e.set(t.conservationStatus, (e.get(t.conservationStatus) ?? 0) + 1);
494
+ let t = U.length;
495
+ return [...e.entries()].sort((e, t) => t[1] - e[1]).map(([e, n]) => {
496
+ let r = n / t * 100, i = P[e] ?? "var(--color-text-tertiary)";
497
+ return /* @__PURE__ */ j("div", {
498
+ className: "flex items-center gap-3 sm:gap-4",
499
+ children: [
500
+ /* @__PURE__ */ A("div", {
501
+ className: "w-36 shrink-0 sm:w-48",
502
+ children: /* @__PURE__ */ A(h, { status: e })
503
+ }),
504
+ /* @__PURE__ */ A(re, {
505
+ value: r,
506
+ color: i,
507
+ className: "flex-1"
508
+ }),
509
+ /* @__PURE__ */ A("span", {
510
+ className: "w-9 shrink-0 text-right text-sm font-medium tabular-nums text-text-primary",
511
+ children: n
512
+ }),
513
+ /* @__PURE__ */ A("span", {
514
+ className: "hidden w-12 shrink-0 text-right text-xs tabular-nums text-text-tertiary sm:inline",
515
+ children: p(r)
516
+ })
517
+ ]
518
+ }, e);
519
+ });
364
520
  })()
365
521
  })
366
522
  })
@@ -369,6 +525,6 @@ function I() {
369
525
  });
370
526
  }
371
527
  //#endregion
372
- export { I as DashboardPage };
528
+ export { F as DashboardPage };
373
529
 
374
530
  //# sourceMappingURL=DashboardPage.js.map