@burdenoff/microfe-theglobalfuel 2026.716.1 → 2026.720.2

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 (67) hide show
  1. package/dist/theglobalfuel/TheGlobalFuelRoutes.d.ts.map +1 -1
  2. package/dist/theglobalfuel/TheGlobalFuelRoutes.js +34 -22
  3. package/dist/theglobalfuel/TheGlobalFuelRoutes.js.map +1 -1
  4. package/dist/theglobalfuel/components/DataTable.js +1 -1
  5. package/dist/theglobalfuel/components/DataTable.js.map +1 -1
  6. package/dist/theglobalfuel/components/MiniBar.d.ts.map +1 -1
  7. package/dist/theglobalfuel/components/MiniBar.js +1 -1
  8. package/dist/theglobalfuel/components/MiniBar.js.map +1 -1
  9. package/dist/theglobalfuel/components/Tabs.js +1 -1
  10. package/dist/theglobalfuel/components/Tabs.js.map +1 -1
  11. package/dist/theglobalfuel/components/index.js +2 -0
  12. package/dist/theglobalfuel/components/viz/BarChart.js +83 -4
  13. package/dist/theglobalfuel/components/viz/BarChart.js.map +1 -0
  14. package/dist/theglobalfuel/components/viz/StatCard.js +60 -3
  15. package/dist/theglobalfuel/components/viz/StatCard.js.map +1 -0
  16. package/dist/theglobalfuel/hooks/useTheGlobalFuelApi.d.ts +10 -1
  17. package/dist/theglobalfuel/hooks/useTheGlobalFuelApi.d.ts.map +1 -1
  18. package/dist/theglobalfuel/hooks/useTheGlobalFuelApi.js +1 -1
  19. package/dist/theglobalfuel/hooks/useTheGlobalFuelApi.js.map +1 -1
  20. package/dist/theglobalfuel/pages/alerts/AlertsPage.d.ts +16 -0
  21. package/dist/theglobalfuel/pages/alerts/AlertsPage.d.ts.map +1 -0
  22. package/dist/theglobalfuel/pages/alerts/AlertsPage.js +295 -0
  23. package/dist/theglobalfuel/pages/alerts/AlertsPage.js.map +1 -0
  24. package/dist/theglobalfuel/pages/analytics/AnalyticsPage.d.ts +13 -0
  25. package/dist/theglobalfuel/pages/analytics/AnalyticsPage.d.ts.map +1 -0
  26. package/dist/theglobalfuel/pages/analytics/AnalyticsPage.js +358 -0
  27. package/dist/theglobalfuel/pages/analytics/AnalyticsPage.js.map +1 -0
  28. package/dist/theglobalfuel/pages/assets/AssetDetailPage.d.ts.map +1 -1
  29. package/dist/theglobalfuel/pages/assets/AssetDetailPage.js +386 -342
  30. package/dist/theglobalfuel/pages/assets/AssetDetailPage.js.map +1 -1
  31. package/dist/theglobalfuel/pages/assets/AssetsPage.d.ts.map +1 -1
  32. package/dist/theglobalfuel/pages/assets/AssetsPage.js +277 -199
  33. package/dist/theglobalfuel/pages/assets/AssetsPage.js.map +1 -1
  34. package/dist/theglobalfuel/pages/contracts/ContractsPage.js +1 -1
  35. package/dist/theglobalfuel/pages/contracts/ContractsPage.js.map +1 -1
  36. package/dist/theglobalfuel/pages/dashboard/DashboardPage.js +6 -6
  37. package/dist/theglobalfuel/pages/dashboard/DashboardPage.js.map +1 -1
  38. package/dist/theglobalfuel/pages/emissions/EmissionsPage.js +1 -1
  39. package/dist/theglobalfuel/pages/emissions/EmissionsPage.js.map +1 -1
  40. package/dist/theglobalfuel/pages/inventory/InventoryPage.js +1 -1
  41. package/dist/theglobalfuel/pages/inventory/InventoryPage.js.map +1 -1
  42. package/dist/theglobalfuel/pages/provenance/ProvenancePage.d.ts.map +1 -1
  43. package/dist/theglobalfuel/pages/provenance/ProvenancePage.js +372 -216
  44. package/dist/theglobalfuel/pages/provenance/ProvenancePage.js.map +1 -1
  45. package/dist/theglobalfuel/pages/reports/ReportsPage.d.ts +16 -0
  46. package/dist/theglobalfuel/pages/reports/ReportsPage.d.ts.map +1 -0
  47. package/dist/theglobalfuel/pages/reports/ReportsPage.js +578 -0
  48. package/dist/theglobalfuel/pages/reports/ReportsPage.js.map +1 -0
  49. package/dist/theglobalfuel/pages/shipments/ShipmentsPage.d.ts.map +1 -1
  50. package/dist/theglobalfuel/pages/shipments/ShipmentsPage.js +43 -12
  51. package/dist/theglobalfuel/pages/shipments/ShipmentsPage.js.map +1 -1
  52. package/dist/theglobalfuel/types/index.d.ts +37 -8
  53. package/dist/theglobalfuel/types/index.d.ts.map +1 -1
  54. package/dist/theglobalfuel/utils/csv.d.ts +16 -0
  55. package/dist/theglobalfuel/utils/csv.d.ts.map +1 -0
  56. package/dist/theglobalfuel/utils/csv.js +14 -0
  57. package/dist/theglobalfuel/utils/csv.js.map +1 -0
  58. package/dist/theglobalfuel/utils/index.d.ts +2 -0
  59. package/dist/theglobalfuel/utils/index.d.ts.map +1 -1
  60. package/dist/theglobalfuel/utils/pageContext.d.ts.map +1 -1
  61. package/dist/theglobalfuel/utils/pageContext.js +32 -0
  62. package/dist/theglobalfuel/utils/pageContext.js.map +1 -1
  63. package/dist/theglobalfuel/utils/provenance.d.ts +135 -0
  64. package/dist/theglobalfuel/utils/provenance.d.ts.map +1 -0
  65. package/dist/theglobalfuel/utils/provenance.js +57 -0
  66. package/dist/theglobalfuel/utils/provenance.js.map +1 -0
  67. package/package.json +1 -1
@@ -0,0 +1,578 @@
1
+ import { cn as e } from "../../utils/cn.js";
2
+ import { PageLayout as t } from "../../components/PageLayout.js";
3
+ import { formatDate as n, formatEnumLabel as r, formatNumber as i } from "../../utils/formatters.js";
4
+ import { StatusBadge as a } from "../../components/StatusBadge.js";
5
+ import { DataTable as o } from "../../components/DataTable.js";
6
+ import { ErrorView as s, LoadingView as c } from "../../components/StateViews.js";
7
+ import { EmptyState as l } from "../../components/EmptyState.js";
8
+ import { useTheAssets as u, useTheComplianceCerts as d, useTheContracts as f, useTheEmissionRecords as p, useTheInventoryLots as m, useTheProductionRecords as h, useTheShipments as g } from "../../hooks/useTheGlobalFuelApi.js";
9
+ import { useNotify as _ } from "../../hooks/useNotify.js";
10
+ import { useThePageView as v } from "../../hooks/useThePageView.js";
11
+ import { useTheTranslation as y } from "../../hooks/useTheTranslation.js";
12
+ import "../../hooks/index.js";
13
+ import { toCsv as b } from "../../utils/csv.js";
14
+ import { downloadTextFile as x } from "../../utils/provenance.js";
15
+ import "../../components/index.js";
16
+ import { useMemo as S, useState as C } from "react";
17
+ import { Download as w, FileSpreadsheet as T, Table2 as E } from "lucide-react";
18
+ import { jsx as D, jsxs as O } from "react/jsx-runtime";
19
+ import { Button as k, GlassCard as A } from "@burdenoff/fe-libs/ui";
20
+ //#region src/theglobalfuel/pages/reports/ReportsPage.tsx
21
+ var j = { limit: 200 }, M = 8;
22
+ function N(e) {
23
+ let t = e.columns.map((e) => ({
24
+ key: e.header,
25
+ header: e.header,
26
+ hideOnMobile: e.hideOnMobile,
27
+ render: (t) => e.render?.(t) ?? String(e.value(t) ?? "—")
28
+ }));
29
+ return {
30
+ id: e.id,
31
+ title: e.title,
32
+ description: e.description,
33
+ filename: e.filename,
34
+ rowCount: e.rows.length,
35
+ columnCount: e.columns.length,
36
+ preview: /* @__PURE__ */ D(o, {
37
+ columns: t,
38
+ rows: e.rows.slice(0, M),
39
+ rowKey: e.rowKey
40
+ }),
41
+ toCsvString: () => b(e.columns.map((e) => ({
42
+ header: e.header,
43
+ value: e.value
44
+ })), e.rows)
45
+ };
46
+ }
47
+ function P() {
48
+ v("reports");
49
+ let o = y(), b = _(), P = u({ pagination: j }), F = h({ pagination: j }), I = p({ pagination: j }), L = d(void 0, void 0, void 0, j), R = f({ pagination: j }), z = g(void 0, void 0, j), B = m({ pagination: j }), V = [
50
+ P,
51
+ F,
52
+ I,
53
+ L,
54
+ R,
55
+ z,
56
+ B
57
+ ], H = V.some((e) => e.isLoading), U = V.every((e) => e.isError), W = S(() => {
58
+ let e = /* @__PURE__ */ new Map();
59
+ for (let t of P.data?.items ?? []) e.set(t.id, t.name);
60
+ return e;
61
+ }, [P.data]), G = S(() => {
62
+ let e = /* @__PURE__ */ new Map();
63
+ for (let t of R.data?.items ?? []) e.set(t.id, t.reference);
64
+ return e;
65
+ }, [R.data]), K = S(() => [
66
+ N({
67
+ id: "production",
68
+ title: "Production register",
69
+ description: "Every measured production volume with its asset, reporting period, grade, downtime and measurement source.",
70
+ filename: "theglobalfuel-production-register.csv",
71
+ rows: F.data?.items ?? [],
72
+ rowKey: (e) => e.id,
73
+ columns: [
74
+ {
75
+ header: "Asset",
76
+ value: (e) => W.get(e.assetId) ?? e.assetId
77
+ },
78
+ {
79
+ header: "Period start",
80
+ value: (e) => e.periodStart,
81
+ render: (e) => n(e.periodStart)
82
+ },
83
+ {
84
+ header: "Period end",
85
+ value: (e) => e.periodEnd,
86
+ render: (e) => n(e.periodEnd)
87
+ },
88
+ {
89
+ header: "Volume",
90
+ value: (e) => e.volume,
91
+ render: (e) => /* @__PURE__ */ D("span", {
92
+ className: "tabular-nums",
93
+ children: i(e.volume)
94
+ })
95
+ },
96
+ {
97
+ header: "Unit",
98
+ value: (e) => e.unit,
99
+ render: (e) => r(e.unit)
100
+ },
101
+ {
102
+ header: "Grade",
103
+ value: (e) => e.grade ?? "",
104
+ hideOnMobile: !0
105
+ },
106
+ {
107
+ header: "Downtime (h)",
108
+ value: (e) => e.downtimeHours,
109
+ hideOnMobile: !0
110
+ },
111
+ {
112
+ header: "Source",
113
+ value: (e) => e.source ?? "",
114
+ hideOnMobile: !0
115
+ }
116
+ ]
117
+ }),
118
+ N({
119
+ id: "emissions",
120
+ title: "GHG emissions register",
121
+ description: "Emission records by GHG-Protocol scope with methodology and third-party verification state — the basis for an ESG disclosure.",
122
+ filename: "theglobalfuel-emissions-register.csv",
123
+ rows: I.data?.items ?? [],
124
+ rowKey: (e) => e.id,
125
+ columns: [
126
+ {
127
+ header: "Asset",
128
+ value: (e) => e.assetId ? W.get(e.assetId) ?? e.assetId : ""
129
+ },
130
+ {
131
+ header: "Scope",
132
+ value: (e) => e.scope,
133
+ render: (e) => /* @__PURE__ */ D(a, { status: e.scope })
134
+ },
135
+ {
136
+ header: "Period start",
137
+ value: (e) => e.periodStart,
138
+ render: (e) => n(e.periodStart)
139
+ },
140
+ {
141
+ header: "Period end",
142
+ value: (e) => e.periodEnd,
143
+ render: (e) => n(e.periodEnd)
144
+ },
145
+ {
146
+ header: "tCO2e",
147
+ value: (e) => e.co2eTonnes,
148
+ render: (e) => /* @__PURE__ */ D("span", {
149
+ className: "tabular-nums",
150
+ children: i(e.co2eTonnes)
151
+ })
152
+ },
153
+ {
154
+ header: "Source",
155
+ value: (e) => e.source ?? "",
156
+ hideOnMobile: !0
157
+ },
158
+ {
159
+ header: "Methodology",
160
+ value: (e) => e.methodology ?? "",
161
+ hideOnMobile: !0
162
+ },
163
+ {
164
+ header: "Verified",
165
+ value: (e) => e.verified ? "yes" : "no",
166
+ render: (e) => e.verified ? "Verified" : "Unverified"
167
+ }
168
+ ]
169
+ }),
170
+ N({
171
+ id: "compliance",
172
+ title: "Compliance & permits register",
173
+ description: "Every certification, permit and licence with issuing authority, certificate number and expiry — the audit pack index.",
174
+ filename: "theglobalfuel-compliance-register.csv",
175
+ rows: L.data?.items ?? [],
176
+ rowKey: (e) => e.id,
177
+ columns: [
178
+ {
179
+ header: "Title",
180
+ value: (e) => e.title
181
+ },
182
+ {
183
+ header: "Category",
184
+ value: (e) => e.category,
185
+ render: (e) => r(e.category)
186
+ },
187
+ {
188
+ header: "Status",
189
+ value: (e) => e.status,
190
+ render: (e) => /* @__PURE__ */ D(a, { status: e.status })
191
+ },
192
+ {
193
+ header: "Authority",
194
+ value: (e) => e.authority ?? "",
195
+ hideOnMobile: !0
196
+ },
197
+ {
198
+ header: "Certificate no.",
199
+ value: (e) => e.certNumber ?? "",
200
+ hideOnMobile: !0
201
+ },
202
+ {
203
+ header: "Issued",
204
+ value: (e) => e.issuedAt ?? "",
205
+ render: (e) => n(e.issuedAt)
206
+ },
207
+ {
208
+ header: "Expires",
209
+ value: (e) => e.expiresAt ?? "",
210
+ render: (e) => n(e.expiresAt)
211
+ },
212
+ {
213
+ header: "Asset",
214
+ value: (e) => e.assetId ? W.get(e.assetId) ?? e.assetId : ""
215
+ }
216
+ ]
217
+ }),
218
+ N({
219
+ id: "contracts",
220
+ title: "Offtake contract position",
221
+ description: "Contracted against delivered volume per offtake contract, with pricing basis and counterparty.",
222
+ filename: "theglobalfuel-contract-position.csv",
223
+ rows: R.data?.items ?? [],
224
+ rowKey: (e) => e.id,
225
+ columns: [
226
+ {
227
+ header: "Reference",
228
+ value: (e) => e.reference
229
+ },
230
+ {
231
+ header: "Counterparty",
232
+ value: (e) => e.counterparty
233
+ },
234
+ {
235
+ header: "Side",
236
+ value: (e) => e.side,
237
+ render: (e) => /* @__PURE__ */ D(a, { status: e.side })
238
+ },
239
+ {
240
+ header: "Status",
241
+ value: (e) => e.status,
242
+ render: (e) => /* @__PURE__ */ D(a, { status: e.status })
243
+ },
244
+ {
245
+ header: "Contracted",
246
+ value: (e) => e.contractedVolume,
247
+ render: (e) => /* @__PURE__ */ D("span", {
248
+ className: "tabular-nums",
249
+ children: i(e.contractedVolume)
250
+ })
251
+ },
252
+ {
253
+ header: "Delivered",
254
+ value: (e) => e.deliveredVolume,
255
+ render: (e) => /* @__PURE__ */ D("span", {
256
+ className: "tabular-nums",
257
+ children: i(e.deliveredVolume)
258
+ })
259
+ },
260
+ {
261
+ header: "Unit",
262
+ value: (e) => e.unit,
263
+ hideOnMobile: !0
264
+ },
265
+ {
266
+ header: "Pricing basis",
267
+ value: (e) => e.pricingBasis,
268
+ hideOnMobile: !0
269
+ },
270
+ {
271
+ header: "Currency",
272
+ value: (e) => e.currency,
273
+ hideOnMobile: !0
274
+ }
275
+ ]
276
+ }),
277
+ N({
278
+ id: "shipments",
279
+ title: "Shipment & movement log",
280
+ description: "Physical movements against contracts, with carrier, tracking number, route and delivery timestamps.",
281
+ filename: "theglobalfuel-shipment-log.csv",
282
+ rows: z.data?.items ?? [],
283
+ rowKey: (e) => e.id,
284
+ columns: [
285
+ {
286
+ header: "Reference",
287
+ value: (e) => e.reference
288
+ },
289
+ {
290
+ header: "Contract",
291
+ value: (e) => G.get(e.contractId) ?? e.contractId
292
+ },
293
+ {
294
+ header: "Status",
295
+ value: (e) => e.status,
296
+ render: (e) => /* @__PURE__ */ D(a, { status: e.status })
297
+ },
298
+ {
299
+ header: "Mode",
300
+ value: (e) => e.mode,
301
+ render: (e) => r(e.mode)
302
+ },
303
+ {
304
+ header: "Volume",
305
+ value: (e) => e.volume,
306
+ render: (e) => /* @__PURE__ */ D("span", {
307
+ className: "tabular-nums",
308
+ children: i(e.volume)
309
+ })
310
+ },
311
+ {
312
+ header: "Carrier",
313
+ value: (e) => e.carrier ?? "",
314
+ hideOnMobile: !0
315
+ },
316
+ {
317
+ header: "Tracking ID",
318
+ value: (e) => e.trackingId ?? "",
319
+ hideOnMobile: !0
320
+ },
321
+ {
322
+ header: "Origin",
323
+ value: (e) => e.origin ?? "",
324
+ hideOnMobile: !0
325
+ },
326
+ {
327
+ header: "Destination",
328
+ value: (e) => e.destination ?? "",
329
+ hideOnMobile: !0
330
+ },
331
+ {
332
+ header: "Delivered",
333
+ value: (e) => e.deliveredAt ?? "",
334
+ render: (e) => n(e.deliveredAt)
335
+ }
336
+ ]
337
+ }),
338
+ N({
339
+ id: "inventory",
340
+ title: "Inventory valuation",
341
+ description: "Held commodity lots by location and status, with recorded unit value and currency.",
342
+ filename: "theglobalfuel-inventory-valuation.csv",
343
+ rows: B.data?.items ?? [],
344
+ rowKey: (e) => e.id,
345
+ columns: [
346
+ {
347
+ header: "Lot code",
348
+ value: (e) => e.lotCode
349
+ },
350
+ {
351
+ header: "Commodity",
352
+ value: (e) => e.commodity,
353
+ render: (e) => r(e.commodity)
354
+ },
355
+ {
356
+ header: "Status",
357
+ value: (e) => e.status,
358
+ render: (e) => /* @__PURE__ */ D(a, { status: e.status })
359
+ },
360
+ {
361
+ header: "Quantity",
362
+ value: (e) => e.quantity,
363
+ render: (e) => /* @__PURE__ */ D("span", {
364
+ className: "tabular-nums",
365
+ children: i(e.quantity)
366
+ })
367
+ },
368
+ {
369
+ header: "Unit",
370
+ value: (e) => e.unit,
371
+ hideOnMobile: !0
372
+ },
373
+ {
374
+ header: "Unit value",
375
+ value: (e) => e.unitValue,
376
+ hideOnMobile: !0
377
+ },
378
+ {
379
+ header: "Currency",
380
+ value: (e) => e.currency,
381
+ hideOnMobile: !0
382
+ },
383
+ {
384
+ header: "Location",
385
+ value: (e) => e.location ?? "",
386
+ hideOnMobile: !0
387
+ },
388
+ {
389
+ header: "Asset",
390
+ value: (e) => e.assetId ? W.get(e.assetId) ?? e.assetId : ""
391
+ }
392
+ ]
393
+ }),
394
+ N({
395
+ id: "assets",
396
+ title: "Asset register",
397
+ description: "Every registered asset with commodity, lifecycle status, capacity, working interest and geology attributes.",
398
+ filename: "theglobalfuel-asset-register.csv",
399
+ rows: P.data?.items ?? [],
400
+ rowKey: (e) => e.id,
401
+ columns: [
402
+ {
403
+ header: "Name",
404
+ value: (e) => e.name
405
+ },
406
+ {
407
+ header: "Code",
408
+ value: (e) => e.code ?? "",
409
+ hideOnMobile: !0
410
+ },
411
+ {
412
+ header: "Commodity",
413
+ value: (e) => e.commodity,
414
+ render: (e) => r(e.commodity)
415
+ },
416
+ {
417
+ header: "Kind",
418
+ value: (e) => e.kind,
419
+ render: (e) => r(e.kind),
420
+ hideOnMobile: !0
421
+ },
422
+ {
423
+ header: "Status",
424
+ value: (e) => e.status,
425
+ render: (e) => /* @__PURE__ */ D(a, { status: e.status })
426
+ },
427
+ {
428
+ header: "Location",
429
+ value: (e) => e.location ?? ""
430
+ },
431
+ {
432
+ header: "Capacity/day",
433
+ value: (e) => e.capacityPerDay,
434
+ hideOnMobile: !0
435
+ },
436
+ {
437
+ header: "Capacity unit",
438
+ value: (e) => e.capacityUnit,
439
+ hideOnMobile: !0
440
+ },
441
+ {
442
+ header: "Working interest %",
443
+ value: (e) => e.workingInterestPct,
444
+ hideOnMobile: !0
445
+ },
446
+ {
447
+ header: "Discovered",
448
+ value: (e) => e.discoveryAt ?? "",
449
+ hideOnMobile: !0
450
+ },
451
+ {
452
+ header: "Area (km2)",
453
+ value: (e) => e.area ?? "",
454
+ hideOnMobile: !0
455
+ },
456
+ {
457
+ header: "Reservoir type",
458
+ value: (e) => e.reservoirType ?? "",
459
+ hideOnMobile: !0
460
+ },
461
+ {
462
+ header: "Water depth (m)",
463
+ value: (e) => e.waterDepth ?? "",
464
+ hideOnMobile: !0
465
+ }
466
+ ]
467
+ })
468
+ ], [
469
+ P.data,
470
+ F.data,
471
+ I.data,
472
+ L.data,
473
+ R.data,
474
+ z.data,
475
+ B.data,
476
+ W,
477
+ G
478
+ ]), [q, J] = C("production"), Y = K.find((e) => e.id === q) ?? K[0], X = (e) => {
479
+ if (e.rowCount === 0) {
480
+ b.error("This report has no rows to export yet.");
481
+ return;
482
+ }
483
+ x(e.filename, "text/csv", e.toCsvString()) ? b.success(`${e.title} exported (${i(e.rowCount)} rows)`) : b.error("This browser can't download the export.");
484
+ }, Z = o("theglobalfuel.pages.reports.description", "Generate operational, commercial and ESG extracts from your live records."), Q = o("theglobalfuel.pages.reports.title", "Reports");
485
+ return H ? /* @__PURE__ */ D(t, {
486
+ title: Q,
487
+ description: Z,
488
+ dataTour: "theglobalfuel-reports-page",
489
+ children: /* @__PURE__ */ D(c, { label: "Loading report sources…" })
490
+ }) : U ? /* @__PURE__ */ D(t, {
491
+ title: Q,
492
+ description: Z,
493
+ dataTour: "theglobalfuel-reports-page",
494
+ children: /* @__PURE__ */ D(s, {
495
+ message: "Couldn't load the records these reports are built from.",
496
+ onRetry: () => V.forEach((e) => void e.refetch())
497
+ })
498
+ }) : Y ? /* @__PURE__ */ D(t, {
499
+ title: Q,
500
+ description: Z,
501
+ dataTour: "theglobalfuel-reports-page",
502
+ children: /* @__PURE__ */ O("div", {
503
+ className: "grid grid-cols-1 gap-6 lg:grid-cols-[320px_1fr]",
504
+ children: [/* @__PURE__ */ D("div", {
505
+ className: "flex flex-col gap-3",
506
+ children: K.map((t) => {
507
+ let n = t.id === Y.id;
508
+ return /* @__PURE__ */ O("button", {
509
+ type: "button",
510
+ onClick: () => J(t.id),
511
+ "aria-pressed": n,
512
+ className: e("rounded-xl border p-4 text-left transition-colors", n ? "border-action-primary-bg bg-[var(--color-accent-soft)]" : "border-border-seam bg-bg-surface hover:bg-bg-sunken"),
513
+ children: [/* @__PURE__ */ O("div", {
514
+ className: "flex items-start justify-between gap-3",
515
+ children: [/* @__PURE__ */ D("p", {
516
+ className: "text-sm font-semibold text-text-primary",
517
+ children: t.title
518
+ }), /* @__PURE__ */ D("span", {
519
+ className: "shrink-0 rounded-full bg-bg-sunken px-2 py-0.5 text-xs tabular-nums text-text-secondary",
520
+ children: i(t.rowCount)
521
+ })]
522
+ }), /* @__PURE__ */ D("p", {
523
+ className: "mt-1 text-xs text-text-secondary",
524
+ children: t.description
525
+ })]
526
+ }, t.id);
527
+ })
528
+ }), /* @__PURE__ */ O(A, {
529
+ treatment: "glass",
530
+ className: "flex flex-col p-5",
531
+ children: [/* @__PURE__ */ O("div", {
532
+ className: "mb-4 flex flex-col gap-3 sm:flex-row sm:items-start sm:justify-between",
533
+ children: [/* @__PURE__ */ O("div", {
534
+ className: "min-w-0",
535
+ children: [/* @__PURE__ */ O("h2", {
536
+ className: "flex items-center gap-2 text-base font-semibold text-text-primary",
537
+ children: [/* @__PURE__ */ D(E, { className: "h-4 w-4 text-text-secondary" }), Y.title]
538
+ }), /* @__PURE__ */ O("p", {
539
+ className: "mt-1 text-xs text-text-tertiary",
540
+ children: [
541
+ i(Y.rowCount),
542
+ " row",
543
+ Y.rowCount === 1 ? "" : "s",
544
+ " · ",
545
+ Y.columnCount,
546
+ " columns · showing the first ",
547
+ Math.min(M, Y.rowCount),
548
+ " below. The download contains every row."
549
+ ]
550
+ })]
551
+ }), /* @__PURE__ */ O(k, {
552
+ size: "sm",
553
+ onClick: () => X(Y),
554
+ disabled: Y.rowCount === 0,
555
+ children: [/* @__PURE__ */ D(w, { className: "mr-2 h-4 w-4" }), "Download CSV"]
556
+ })]
557
+ }), Y.rowCount > 0 ? Y.preview : /* @__PURE__ */ D("div", {
558
+ className: "rounded-xl border border-dashed border-border-seam py-12 text-center text-sm text-text-secondary",
559
+ children: "No records yet for this report."
560
+ })]
561
+ })]
562
+ })
563
+ }) : /* @__PURE__ */ D(t, {
564
+ title: Q,
565
+ description: Z,
566
+ dataTour: "theglobalfuel-reports-page",
567
+ children: /* @__PURE__ */ D(l, {
568
+ illustration: "empty-data",
569
+ icon: /* @__PURE__ */ D(T, { className: "h-10 w-10" }),
570
+ title: "No reports available",
571
+ description: "Reports are generated from your asset, production, contract, shipment and ESG records."
572
+ })
573
+ });
574
+ }
575
+ //#endregion
576
+ export { P as ReportsPage };
577
+
578
+ //# sourceMappingURL=ReportsPage.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ReportsPage.js","names":[],"sources":["../../../../src/theglobalfuel/pages/reports/ReportsPage.tsx"],"sourcesContent":["/**\n * Reports — generate and download operational / ESG / commercial extracts.\n * @module theglobalfuel/pages/reports\n *\n * A catalogue of report definitions over the live `the*` records. Each report\n * declares its own columns and row source; the page renders a live preview\n * (first rows + real row count) and downloads the full extract as CSV.\n *\n * This is deliberately a client-side extract rather than a server-side report\n * job: every row is data the caller is already authorized to read through the\n * gateway, the volumes are page-sized, and it means a report can never drift\n * from what the product UI shows. Anything needing scheduling, retention or\n * cross-workspace scope belongs in a backend reporting service, not here.\n */\n\nimport { useMemo, useState, type ReactNode } from 'react';\nimport { FileSpreadsheet, Download, Table2 } from 'lucide-react';\nimport { Button, GlassCard } from '@burdenoff/fe-libs/ui';\nimport {\n PageLayout,\n LoadingView,\n ErrorView,\n EmptyState,\n StatusBadge,\n DataTable,\n type Column,\n} from '../../components';\nimport {\n useTheAssets,\n useTheProductionRecords,\n useTheEmissionRecords,\n useTheComplianceCerts,\n useTheContracts,\n useTheShipments,\n useTheInventoryLots,\n useThePageView,\n useTheTranslation,\n useNotify,\n} from '../../hooks';\nimport { cn } from '../../utils/cn';\nimport { formatNumber, formatDate, formatEnumLabel, toCsv, downloadTextFile } from '../../utils';\n\nconst PAGE: { limit: number } = { limit: 200 };\nconst PREVIEW_ROWS = 8;\n\n/** A column in a report: a header, a CSV value and an optional cell renderer. */\ninterface ReportColumn<T> {\n header: string;\n value: (row: T) => unknown;\n render?: (row: T) => ReactNode;\n hideOnMobile?: boolean;\n}\n\n/**\n * A report, with its row type already closed over. Holding the preview node and\n * the CSV serializer as pre-bound closures (rather than exposing `rows` and\n * `columns` generically) lets a heterogeneous catalogue live in one array with\n * no type erasure and no casts.\n */\ninterface ReportDefinition {\n id: string;\n title: string;\n description: string;\n filename: string;\n rowCount: number;\n columnCount: number;\n /** Rendered preview of the first PREVIEW_ROWS rows. */\n preview: ReactNode;\n /** Full-extract CSV for every row, not just the previewed ones. */\n toCsvString: () => string;\n}\n\nfunction defineReport<T>(spec: {\n id: string;\n title: string;\n description: string;\n filename: string;\n rows: readonly T[];\n columns: readonly ReportColumn<T>[];\n rowKey: (row: T) => string;\n}): ReportDefinition {\n const previewColumns: Column<T>[] = spec.columns.map((c) => ({\n key: c.header,\n header: c.header,\n hideOnMobile: c.hideOnMobile,\n render: (row: T) => c.render?.(row) ?? String(c.value(row) ?? '\\u2014'),\n }));\n\n return {\n id: spec.id,\n title: spec.title,\n description: spec.description,\n filename: spec.filename,\n rowCount: spec.rows.length,\n columnCount: spec.columns.length,\n preview: (\n <DataTable\n columns={previewColumns}\n rows={spec.rows.slice(0, PREVIEW_ROWS)}\n rowKey={spec.rowKey}\n />\n ),\n toCsvString: () =>\n toCsv(\n spec.columns.map((c) => ({ header: c.header, value: c.value })),\n spec.rows\n ),\n };\n}\n\nexport function ReportsPage() {\n useThePageView('reports');\n const t = useTheTranslation();\n const notify = useNotify();\n\n const assets = useTheAssets({ pagination: PAGE });\n const production = useTheProductionRecords({ pagination: PAGE });\n const emissions = useTheEmissionRecords({ pagination: PAGE });\n const compliance = useTheComplianceCerts(undefined, undefined, undefined, PAGE);\n const contracts = useTheContracts({ pagination: PAGE });\n const shipments = useTheShipments(undefined, undefined, PAGE);\n const inventory = useTheInventoryLots({ pagination: PAGE });\n\n const sources = [assets, production, emissions, compliance, contracts, shipments, inventory];\n const isLoading = sources.some((s) => s.isLoading);\n const isError = sources.every((s) => s.isError);\n\n const assetName = useMemo(() => {\n const map = new Map<string, string>();\n for (const a of assets.data?.items ?? []) map.set(a.id, a.name);\n return map;\n }, [assets.data]);\n\n const contractRef = useMemo(() => {\n const map = new Map<string, string>();\n for (const c of contracts.data?.items ?? []) map.set(c.id, c.reference);\n return map;\n }, [contracts.data]);\n\n const reports = useMemo<ReportDefinition[]>(\n () => [\n defineReport({\n id: 'production',\n title: 'Production register',\n description:\n 'Every measured production volume with its asset, reporting period, grade, downtime and measurement source.',\n filename: 'theglobalfuel-production-register.csv',\n rows: production.data?.items ?? [],\n rowKey: (r) => r.id,\n columns: [\n { header: 'Asset', value: (r) => assetName.get(r.assetId) ?? r.assetId },\n {\n header: 'Period start',\n value: (r) => r.periodStart,\n render: (r) => formatDate(r.periodStart),\n },\n {\n header: 'Period end',\n value: (r) => r.periodEnd,\n render: (r) => formatDate(r.periodEnd),\n },\n {\n header: 'Volume',\n value: (r) => r.volume,\n render: (r) => <span className=\"tabular-nums\">{formatNumber(r.volume)}</span>,\n },\n { header: 'Unit', value: (r) => r.unit, render: (r) => formatEnumLabel(r.unit) },\n { header: 'Grade', value: (r) => r.grade ?? '', hideOnMobile: true },\n { header: 'Downtime (h)', value: (r) => r.downtimeHours, hideOnMobile: true },\n { header: 'Source', value: (r) => r.source ?? '', hideOnMobile: true },\n ],\n }),\n defineReport({\n id: 'emissions',\n title: 'GHG emissions register',\n description:\n 'Emission records by GHG-Protocol scope with methodology and third-party verification state — the basis for an ESG disclosure.',\n filename: 'theglobalfuel-emissions-register.csv',\n rows: emissions.data?.items ?? [],\n rowKey: (r) => r.id,\n columns: [\n {\n header: 'Asset',\n value: (r) => (r.assetId ? (assetName.get(r.assetId) ?? r.assetId) : ''),\n },\n {\n header: 'Scope',\n value: (r) => r.scope,\n render: (r) => <StatusBadge status={r.scope} />,\n },\n {\n header: 'Period start',\n value: (r) => r.periodStart,\n render: (r) => formatDate(r.periodStart),\n },\n {\n header: 'Period end',\n value: (r) => r.periodEnd,\n render: (r) => formatDate(r.periodEnd),\n },\n {\n header: 'tCO2e',\n value: (r) => r.co2eTonnes,\n render: (r) => <span className=\"tabular-nums\">{formatNumber(r.co2eTonnes)}</span>,\n },\n { header: 'Source', value: (r) => r.source ?? '', hideOnMobile: true },\n { header: 'Methodology', value: (r) => r.methodology ?? '', hideOnMobile: true },\n {\n header: 'Verified',\n value: (r) => (r.verified ? 'yes' : 'no'),\n render: (r) => (r.verified ? 'Verified' : 'Unverified'),\n },\n ],\n }),\n defineReport({\n id: 'compliance',\n title: 'Compliance & permits register',\n description:\n 'Every certification, permit and licence with issuing authority, certificate number and expiry — the audit pack index.',\n filename: 'theglobalfuel-compliance-register.csv',\n rows: compliance.data?.items ?? [],\n rowKey: (r) => r.id,\n columns: [\n { header: 'Title', value: (r) => r.title },\n {\n header: 'Category',\n value: (r) => r.category,\n render: (r) => formatEnumLabel(r.category),\n },\n {\n header: 'Status',\n value: (r) => r.status,\n render: (r) => <StatusBadge status={r.status} />,\n },\n { header: 'Authority', value: (r) => r.authority ?? '', hideOnMobile: true },\n { header: 'Certificate no.', value: (r) => r.certNumber ?? '', hideOnMobile: true },\n {\n header: 'Issued',\n value: (r) => r.issuedAt ?? '',\n render: (r) => formatDate(r.issuedAt),\n },\n {\n header: 'Expires',\n value: (r) => r.expiresAt ?? '',\n render: (r) => formatDate(r.expiresAt),\n },\n {\n header: 'Asset',\n value: (r) => (r.assetId ? (assetName.get(r.assetId) ?? r.assetId) : ''),\n },\n ],\n }),\n defineReport({\n id: 'contracts',\n title: 'Offtake contract position',\n description:\n 'Contracted against delivered volume per offtake contract, with pricing basis and counterparty.',\n filename: 'theglobalfuel-contract-position.csv',\n rows: contracts.data?.items ?? [],\n rowKey: (r) => r.id,\n columns: [\n { header: 'Reference', value: (r) => r.reference },\n { header: 'Counterparty', value: (r) => r.counterparty },\n { header: 'Side', value: (r) => r.side, render: (r) => <StatusBadge status={r.side} /> },\n {\n header: 'Status',\n value: (r) => r.status,\n render: (r) => <StatusBadge status={r.status} />,\n },\n {\n header: 'Contracted',\n value: (r) => r.contractedVolume,\n render: (r) => <span className=\"tabular-nums\">{formatNumber(r.contractedVolume)}</span>,\n },\n {\n header: 'Delivered',\n value: (r) => r.deliveredVolume,\n render: (r) => <span className=\"tabular-nums\">{formatNumber(r.deliveredVolume)}</span>,\n },\n { header: 'Unit', value: (r) => r.unit, hideOnMobile: true },\n { header: 'Pricing basis', value: (r) => r.pricingBasis, hideOnMobile: true },\n { header: 'Currency', value: (r) => r.currency, hideOnMobile: true },\n ],\n }),\n defineReport({\n id: 'shipments',\n title: 'Shipment & movement log',\n description:\n 'Physical movements against contracts, with carrier, tracking number, route and delivery timestamps.',\n filename: 'theglobalfuel-shipment-log.csv',\n rows: shipments.data?.items ?? [],\n rowKey: (r) => r.id,\n columns: [\n { header: 'Reference', value: (r) => r.reference },\n { header: 'Contract', value: (r) => contractRef.get(r.contractId) ?? r.contractId },\n {\n header: 'Status',\n value: (r) => r.status,\n render: (r) => <StatusBadge status={r.status} />,\n },\n { header: 'Mode', value: (r) => r.mode, render: (r) => formatEnumLabel(r.mode) },\n {\n header: 'Volume',\n value: (r) => r.volume,\n render: (r) => <span className=\"tabular-nums\">{formatNumber(r.volume)}</span>,\n },\n { header: 'Carrier', value: (r) => r.carrier ?? '', hideOnMobile: true },\n { header: 'Tracking ID', value: (r) => r.trackingId ?? '', hideOnMobile: true },\n { header: 'Origin', value: (r) => r.origin ?? '', hideOnMobile: true },\n { header: 'Destination', value: (r) => r.destination ?? '', hideOnMobile: true },\n {\n header: 'Delivered',\n value: (r) => r.deliveredAt ?? '',\n render: (r) => formatDate(r.deliveredAt),\n },\n ],\n }),\n defineReport({\n id: 'inventory',\n title: 'Inventory valuation',\n description:\n 'Held commodity lots by location and status, with recorded unit value and currency.',\n filename: 'theglobalfuel-inventory-valuation.csv',\n rows: inventory.data?.items ?? [],\n rowKey: (r) => r.id,\n columns: [\n { header: 'Lot code', value: (r) => r.lotCode },\n {\n header: 'Commodity',\n value: (r) => r.commodity,\n render: (r) => formatEnumLabel(r.commodity),\n },\n {\n header: 'Status',\n value: (r) => r.status,\n render: (r) => <StatusBadge status={r.status} />,\n },\n {\n header: 'Quantity',\n value: (r) => r.quantity,\n render: (r) => <span className=\"tabular-nums\">{formatNumber(r.quantity)}</span>,\n },\n { header: 'Unit', value: (r) => r.unit, hideOnMobile: true },\n { header: 'Unit value', value: (r) => r.unitValue, hideOnMobile: true },\n { header: 'Currency', value: (r) => r.currency, hideOnMobile: true },\n { header: 'Location', value: (r) => r.location ?? '', hideOnMobile: true },\n {\n header: 'Asset',\n value: (r) => (r.assetId ? (assetName.get(r.assetId) ?? r.assetId) : ''),\n },\n ],\n }),\n defineReport({\n id: 'assets',\n title: 'Asset register',\n description:\n 'Every registered asset with commodity, lifecycle status, capacity, working interest and geology attributes.',\n filename: 'theglobalfuel-asset-register.csv',\n rows: assets.data?.items ?? [],\n rowKey: (r) => r.id,\n columns: [\n { header: 'Name', value: (r) => r.name },\n { header: 'Code', value: (r) => r.code ?? '', hideOnMobile: true },\n {\n header: 'Commodity',\n value: (r) => r.commodity,\n render: (r) => formatEnumLabel(r.commodity),\n },\n {\n header: 'Kind',\n value: (r) => r.kind,\n render: (r) => formatEnumLabel(r.kind),\n hideOnMobile: true,\n },\n {\n header: 'Status',\n value: (r) => r.status,\n render: (r) => <StatusBadge status={r.status} />,\n },\n { header: 'Location', value: (r) => r.location ?? '' },\n { header: 'Capacity/day', value: (r) => r.capacityPerDay, hideOnMobile: true },\n { header: 'Capacity unit', value: (r) => r.capacityUnit, hideOnMobile: true },\n { header: 'Working interest %', value: (r) => r.workingInterestPct, hideOnMobile: true },\n { header: 'Discovered', value: (r) => r.discoveryAt ?? '', hideOnMobile: true },\n { header: 'Area (km2)', value: (r) => r.area ?? '', hideOnMobile: true },\n { header: 'Reservoir type', value: (r) => r.reservoirType ?? '', hideOnMobile: true },\n { header: 'Water depth (m)', value: (r) => r.waterDepth ?? '', hideOnMobile: true },\n ],\n }),\n ],\n [\n assets.data,\n production.data,\n emissions.data,\n compliance.data,\n contracts.data,\n shipments.data,\n inventory.data,\n assetName,\n contractRef,\n ]\n );\n\n const [selectedId, setSelectedId] = useState<string>('production');\n const selected = reports.find((r) => r.id === selectedId) ?? reports[0];\n\n const handleDownload = (report: ReportDefinition) => {\n if (report.rowCount === 0) {\n notify.error('This report has no rows to export yet.');\n return;\n }\n const ok = downloadTextFile(report.filename, 'text/csv', report.toCsvString());\n if (ok) notify.success(`${report.title} exported (${formatNumber(report.rowCount)} rows)`);\n else notify.error(\"This browser can't download the export.\");\n };\n\n const description = t(\n 'theglobalfuel.pages.reports.description',\n 'Generate operational, commercial and ESG extracts from your live records.'\n );\n const pageTitle = t('theglobalfuel.pages.reports.title', 'Reports');\n\n if (isLoading) {\n return (\n <PageLayout title={pageTitle} description={description} dataTour=\"theglobalfuel-reports-page\">\n <LoadingView label=\"Loading report sources…\" />\n </PageLayout>\n );\n }\n\n if (isError) {\n return (\n <PageLayout title={pageTitle} description={description} dataTour=\"theglobalfuel-reports-page\">\n <ErrorView\n message=\"Couldn't load the records these reports are built from.\"\n onRetry={() => sources.forEach((s) => void s.refetch())}\n />\n </PageLayout>\n );\n }\n\n if (!selected) {\n return (\n <PageLayout title={pageTitle} description={description} dataTour=\"theglobalfuel-reports-page\">\n <EmptyState\n illustration=\"empty-data\"\n icon={<FileSpreadsheet className=\"h-10 w-10\" />}\n title=\"No reports available\"\n description=\"Reports are generated from your asset, production, contract, shipment and ESG records.\"\n />\n </PageLayout>\n );\n }\n\n return (\n <PageLayout title={pageTitle} description={description} dataTour=\"theglobalfuel-reports-page\">\n <div className=\"grid grid-cols-1 gap-6 lg:grid-cols-[320px_1fr]\">\n {/* Report catalogue */}\n <div className=\"flex flex-col gap-3\">\n {reports.map((report) => {\n const active = report.id === selected.id;\n return (\n <button\n key={report.id}\n type=\"button\"\n onClick={() => setSelectedId(report.id)}\n aria-pressed={active}\n className={cn(\n 'rounded-xl border p-4 text-left transition-colors',\n active\n ? 'border-action-primary-bg bg-[var(--color-accent-soft)]'\n : 'border-border-seam bg-bg-surface hover:bg-bg-sunken'\n )}\n >\n <div className=\"flex items-start justify-between gap-3\">\n <p className=\"text-sm font-semibold text-text-primary\">{report.title}</p>\n <span className=\"shrink-0 rounded-full bg-bg-sunken px-2 py-0.5 text-xs tabular-nums text-text-secondary\">\n {formatNumber(report.rowCount)}\n </span>\n </div>\n <p className=\"mt-1 text-xs text-text-secondary\">{report.description}</p>\n </button>\n );\n })}\n </div>\n\n {/* Preview + download */}\n <GlassCard treatment=\"glass\" className=\"flex flex-col p-5\">\n <div className=\"mb-4 flex flex-col gap-3 sm:flex-row sm:items-start sm:justify-between\">\n <div className=\"min-w-0\">\n <h2 className=\"flex items-center gap-2 text-base font-semibold text-text-primary\">\n <Table2 className=\"h-4 w-4 text-text-secondary\" />\n {selected.title}\n </h2>\n <p className=\"mt-1 text-xs text-text-tertiary\">\n {formatNumber(selected.rowCount)} row\n {selected.rowCount === 1 ? '' : 's'} · {selected.columnCount} columns · showing the\n first {Math.min(PREVIEW_ROWS, selected.rowCount)} below. The download contains every\n row.\n </p>\n </div>\n <Button\n size=\"sm\"\n onClick={() => handleDownload(selected)}\n disabled={selected.rowCount === 0}\n >\n <Download className=\"mr-2 h-4 w-4\" />\n Download CSV\n </Button>\n </div>\n\n {selected.rowCount > 0 ? (\n selected.preview\n ) : (\n <div className=\"rounded-xl border border-dashed border-border-seam py-12 text-center text-sm text-text-secondary\">\n No records yet for this report.\n </div>\n )}\n </GlassCard>\n </div>\n </PageLayout>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AA0CA,IAAM,IAA0B,EAAE,OAAO,KAAK,EACxC,IAAe;AA6BrB,SAAS,EAAgB,GAQJ;CACnB,IAAM,IAA8B,EAAK,QAAQ,KAAK,OAAO;EAC3D,KAAK,EAAE;EACP,QAAQ,EAAE;EACV,cAAc,EAAE;EAChB,SAAS,MAAW,EAAE,SAAS,EAA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AU,aAAc,CAAA;GAC/C,OAAM;GACN,aAAY;GACZ,CAAA;EACS,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"ShipmentsPage.d.ts","sourceRoot":"","sources":["../../../../src/theglobalfuel/pages/shipments/ShipmentsPage.tsx"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AA6KH,wBAAgB,aAAa,gCAiqB5B"}
1
+ {"version":3,"file":"ShipmentsPage.d.ts","sourceRoot":"","sources":["../../../../src/theglobalfuel/pages/shipments/ShipmentsPage.tsx"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AA+KH,wBAAgB,aAAa,gCAwrB5B"}