@burdenoff/microfe-movethewheels 2026.624.1 → 2026.626.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{AIAssistantPage-BrHX2lQn.js → AIAssistantPage-AvsMbunM.js} +39 -33
- package/dist/{AnalyticsPage-DI6Wcaw5.js → AnalyticsPage-CCLfHgQZ.js} +44 -33
- package/dist/CreateOrderPage-CjlnEtk3.js +510 -0
- package/dist/CustomerDetailsPage-I6cdDHUi.js +265 -0
- package/dist/CustomersPage-CGGfD4ki.js +163 -0
- package/dist/{DashboardPage-3ZOnwg1a.js → DashboardPage-D2HRqwg9.js} +122 -111
- package/dist/DataTable-CD9ZhpLB.js +249 -0
- package/dist/DriverDetailsPage-rg_pGNuP.js +330 -0
- package/dist/DriversPage-DKiynISH.js +167 -0
- package/dist/FinancePage-Vg8WPs38.js +158 -0
- package/dist/{FleetPage-CPS7r4J3.js → FleetPage-DddXt8r8.js} +124 -85
- package/dist/ImportExportPage-BW6qO3kc.js +248 -0
- package/dist/InventoryPage-rMGuaJN-.js +222 -0
- package/dist/LiveTrackingPage-DQ1q4Id3.js +375 -0
- package/dist/MarketplacePage-DKrXAv62.js +219 -0
- package/dist/MetricCard-B7yMyvMX.js +146 -0
- package/dist/OrderDetailsPage-CFASgsYX.js +431 -0
- package/dist/OrdersListPage-BHeT8S5o.js +309 -0
- package/dist/{PageLayout-xDTiBTDS.js → PageLayout-D3N8MCTm.js} +213 -195
- package/dist/ProductDetailsPage-CFGcbaHo.js +195 -0
- package/dist/ProductsPage--xEpbQ8A.js +171 -0
- package/dist/{ReportsPage-B8OyWGzl.js → ReportsPage-Bb7_90rK.js} +57 -49
- package/dist/RouteDetailsPage-CVtDVb1N.js +282 -0
- package/dist/RoutesPage-s57PtgcQ.js +163 -0
- package/dist/SettingsPage-BYNCBOpN.js +298 -0
- package/dist/{StatusBadge-C--7NhoW.js → StatusBadge-CijYQXtb.js} +5 -2
- package/dist/{TrackingPage-BldUm_g7.js → TrackingPage-CcRc_dva.js} +88 -83
- package/dist/VehicleDetailsPage-3YDMPsPs.js +220 -0
- package/dist/VehiclesPage-UlxPWP9K.js +167 -0
- package/dist/WarehouseDetailsPage-Db7KeN-d.js +238 -0
- package/dist/WarehousesPage-CuTO-OPp.js +164 -0
- package/dist/{arrow-left-Bk5GsGNk.js → arrow-left-CBpZKkpq.js} +1 -1
- package/dist/{box-BAMv2-7M.js → box-CAaiElsb.js} +1 -1
- package/dist/{chart-column-CAfkf4o6.js → chart-column-D1Ym15-S.js} +1 -1
- package/dist/{chevron-right-Czrt_Qew.js → chevron-right-BIFGi0UA.js} +1 -1
- package/dist/{circle-alert-CEuV9Pij.js → circle-alert-DjmNo5_L.js} +1 -1
- package/dist/{circle-check-big-Cx8aO6B-.js → circle-check-big-CjuPVo3_.js} +1 -1
- package/dist/{clock-Be95bq7_.js → clock-BjkdnddD.js} +1 -1
- package/dist/{dollar-sign-kJqItPli.js → dollar-sign-IB4O0wuQ.js} +1 -1
- package/dist/{download-caab0D3V.js → download-Dpa9vqoG.js} +1 -1
- package/dist/{file-text-b1qhrJn1.js → file-text-C8Uioy11.js} +1 -1
- package/dist/{filter-BWmLTZB-.js → filter-Da5OZaHI.js} +1 -1
- package/dist/index.js +16 -16
- package/dist/{map-CS2aFgyO.js → map-_Per4sT9.js} +1 -1
- package/dist/{map-pin-96FeqL7H.js → map-pin-BSaf5IDL.js} +1 -1
- package/dist/{navigation-i6UXEjTC.js → navigation-DaTbrhw2.js} +1 -1
- package/dist/{package-KhSi3xaT.js → package-BE7U0wQE.js} +1 -1
- package/dist/{phone-B-h3tbsr.js → phone-DV4StZiA.js} +1 -1
- package/dist/{plus-D2BYAzMn.js → plus-Dl1rLeJR.js} +1 -1
- package/dist/{refresh-cw-D5Sy01s-.js → refresh-cw-CWfERAit.js} +1 -1
- package/dist/{route-CBDXuwH9.js → route-Dp9JiN_E.js} +1 -1
- package/dist/{save-CMc7h-Vi.js → save-XH8vydOn.js} +1 -1
- package/dist/{search-DVrUQbOg.js → search-OxoIiL_C.js} +1 -1
- package/dist/{settings-BwzIRYv3.js → settings-3Rw5NwFF.js} +1 -1
- package/dist/{square-pen-DmW36Bau.js → square-pen-hLIbFQFV.js} +1 -1
- package/dist/{star-Cv2MzxZL.js → star-YsVV3MNQ.js} +1 -1
- package/dist/{store-CLH957vl.js → store-RCBl7HB-.js} +1 -1
- package/dist/{trending-up-l8M0BO_w.js → trending-up-C-85AwGT.js} +1 -1
- package/dist/{triangle-alert-BI45s6bH.js → triangle-alert-BOhfGgmh.js} +1 -1
- package/dist/{truck-DX3lNQkz.js → truck-CtDjNFbi.js} +1 -1
- package/dist/{user-D8EY1uvt.js → user-Dz5TJZFs.js} +1 -1
- package/dist/{users-CfG0J8wP.js → users-g2N0eL-Z.js} +1 -1
- package/dist/{warehouse-Dt_bAr82.js → warehouse-D3WWDeTX.js} +1 -1
- package/dist/{wrench-C50eI_Iy.js → wrench-CmxY1n4I.js} +1 -1
- package/package.json +2 -2
- package/src/movethewheels/components/DataTable.tsx +41 -6
- package/src/movethewheels/components/MetricCard.tsx +51 -20
- package/src/movethewheels/components/PageLayout.tsx +60 -5
- package/src/movethewheels/components/StatusBadge.tsx +2 -1
- package/src/movethewheels/pages/AIAssistantPage.tsx +11 -3
- package/src/movethewheels/pages/AnalyticsPage.tsx +31 -25
- package/src/movethewheels/pages/CreateOrderPage.tsx +56 -17
- package/src/movethewheels/pages/CustomerDetailsPage.tsx +63 -38
- package/src/movethewheels/pages/CustomersPage.tsx +51 -12
- package/src/movethewheels/pages/DashboardPage.tsx +62 -48
- package/src/movethewheels/pages/DriverDetailsPage.tsx +57 -26
- package/src/movethewheels/pages/DriversPage.tsx +45 -12
- package/src/movethewheels/pages/FinancePage.tsx +45 -41
- package/src/movethewheels/pages/FleetPage.tsx +82 -34
- package/src/movethewheels/pages/ImportExportPage.tsx +46 -29
- package/src/movethewheels/pages/InventoryPage.tsx +37 -33
- package/src/movethewheels/pages/LiveTrackingPage.tsx +58 -20
- package/src/movethewheels/pages/MarketplacePage.tsx +37 -3
- package/src/movethewheels/pages/OrderDetailsPage.tsx +74 -46
- package/src/movethewheels/pages/OrdersListPage.tsx +81 -14
- package/src/movethewheels/pages/ProductDetailsPage.tsx +36 -11
- package/src/movethewheels/pages/ProductsPage.tsx +41 -12
- package/src/movethewheels/pages/ReportsPage.tsx +23 -19
- package/src/movethewheels/pages/RouteDetailsPage.tsx +71 -31
- package/src/movethewheels/pages/RoutesPage.tsx +48 -9
- package/src/movethewheels/pages/SettingsPage.tsx +68 -26
- package/src/movethewheels/pages/TrackingPage.tsx +52 -49
- package/src/movethewheels/pages/VehicleDetailsPage.tsx +49 -24
- package/src/movethewheels/pages/VehiclesPage.tsx +41 -15
- package/src/movethewheels/pages/WarehouseDetailsPage.tsx +55 -30
- package/src/movethewheels/pages/WarehousesPage.tsx +46 -9
- package/dist/CreateOrderPage-DfkSi6JF.js +0 -471
- package/dist/CustomerDetailsPage-DzAIu_tH.js +0 -239
- package/dist/CustomersPage-d21ixOYa.js +0 -119
- package/dist/DataTable-CZGz3SJu.js +0 -239
- package/dist/DriverDetailsPage-YuZSlPSV.js +0 -297
- package/dist/DriversPage-BOhqEBTv.js +0 -127
- package/dist/FinancePage-CnjUNXOb.js +0 -154
- package/dist/ImportExportPage-zNjs7xsV.js +0 -232
- package/dist/InventoryPage-C9g5d3SW.js +0 -223
- package/dist/LiveTrackingPage-DoBvtdBG.js +0 -332
- package/dist/MarketplacePage-BEj5hcBF.js +0 -192
- package/dist/MetricCard-DeHVeVwl.js +0 -135
- package/dist/OrderDetailsPage-D-9lDZYU.js +0 -398
- package/dist/OrdersListPage-CJzHbgY3.js +0 -257
- package/dist/ProductDetailsPage-3rKtzXpy.js +0 -168
- package/dist/ProductsPage-B0P_wjBJ.js +0 -131
- package/dist/RouteDetailsPage-DGjKTUMj.js +0 -240
- package/dist/RoutesPage-CpopY8xN.js +0 -116
- package/dist/SettingsPage-BvXSa3gi.js +0 -247
- package/dist/VehicleDetailsPage-Dqv--MVW.js +0 -194
- package/dist/VehiclesPage-CCBHRDHu.js +0 -127
- package/dist/WarehouseDetailsPage-ZObC_c7W.js +0 -215
- package/dist/WarehousesPage-CpgZEVW9.js +0 -121
|
@@ -1,62 +1,67 @@
|
|
|
1
|
-
import { A as e, d as t, f as n, g as r, h as i, i as a, t as o, u as s } from "./PageLayout-
|
|
2
|
-
import { t as c } from "./circle-alert-
|
|
3
|
-
import { t as l } from "./circle-check-big-
|
|
4
|
-
import { t as u } from "./clock-
|
|
5
|
-
import { t as d } from "./map-pin-
|
|
6
|
-
import { t as f } from "./package-
|
|
7
|
-
import { t as p } from "./search-
|
|
8
|
-
import { t as m } from "./truck-
|
|
1
|
+
import { A as e, d as t, f as n, g as r, h as i, i as a, t as o, u as s } from "./PageLayout-D3N8MCTm.js";
|
|
2
|
+
import { t as c } from "./circle-alert-DjmNo5_L.js";
|
|
3
|
+
import { t as l } from "./circle-check-big-CjuPVo3_.js";
|
|
4
|
+
import { t as u } from "./clock-BjkdnddD.js";
|
|
5
|
+
import { t as d } from "./map-pin-BSaf5IDL.js";
|
|
6
|
+
import { t as f } from "./package-BE7U0wQE.js";
|
|
7
|
+
import { t as p } from "./search-OxoIiL_C.js";
|
|
8
|
+
import { t as m } from "./truck-CtDjNFbi.js";
|
|
9
9
|
import { r as h } from "./graphqlClient-CdJyR_ed.js";
|
|
10
10
|
import { i as g } from "./useTracking-De2KIUNu.js";
|
|
11
|
-
import { r as _ } from "./StatusBadge-
|
|
11
|
+
import { r as _ } from "./StatusBadge-CijYQXtb.js";
|
|
12
12
|
import { r as v, t as y } from "./formatters-_vJlC-47.js";
|
|
13
13
|
import { t as b } from "./navigation-BgnOfsVd.js";
|
|
14
14
|
import { useState as x } from "react";
|
|
15
15
|
import { useSearchParams as S } from "react-router-dom";
|
|
16
16
|
import { jsx as C, jsxs as w } from "react/jsx-runtime";
|
|
17
|
-
import {
|
|
17
|
+
import { EmphasisPanel as T, PagePurpose as E } from "@burdenoff/fe-libs/ui";
|
|
18
|
+
import { useI18n as D } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
|
|
18
19
|
//#region src/movethewheels/pages/TrackingPage.tsx
|
|
19
|
-
function
|
|
20
|
-
let { t:
|
|
21
|
-
let n =
|
|
20
|
+
function O() {
|
|
21
|
+
let { t: O } = D(), k = (e, t) => {
|
|
22
|
+
let n = O(e);
|
|
22
23
|
return n === e ? t : n;
|
|
23
|
-
}, { basePath:
|
|
24
|
-
e.preventDefault(),
|
|
25
|
-
},
|
|
26
|
-
|
|
24
|
+
}, { basePath: A, navigate: j } = h(), [M] = S(), N = M.get("order") || "", [P, F] = x(N), [I, L] = x(N), { tracking: R, order: z, isLoading: B, error: V } = g(I || void 0), H = (e) => {
|
|
25
|
+
e.preventDefault(), L(P);
|
|
26
|
+
}, U = (e) => {
|
|
27
|
+
j && j(b(A, e));
|
|
27
28
|
};
|
|
28
29
|
return /* @__PURE__ */ w(a, {
|
|
29
|
-
title:
|
|
30
|
-
subtitle:
|
|
30
|
+
title: k("movethewheels.tracking.title", "Track Shipment"),
|
|
31
|
+
subtitle: k("movethewheels.tracking.subtitle", "Enter a tracking number or order ID to track your shipment"),
|
|
31
32
|
icon: /* @__PURE__ */ C(d, { size: 24 }),
|
|
32
33
|
headerActions: /* @__PURE__ */ w(s, {
|
|
33
34
|
variant: "outline",
|
|
34
|
-
onClick: () =>
|
|
35
|
-
children: [/* @__PURE__ */ C(d, { size: 16 }),
|
|
35
|
+
onClick: () => U("tracking/live"),
|
|
36
|
+
children: [/* @__PURE__ */ C(d, { size: 16 }), k("movethewheels.tracking.actions.liveMapView", "Live Map View")]
|
|
36
37
|
}),
|
|
37
38
|
children: [
|
|
39
|
+
/* @__PURE__ */ C(E, {
|
|
40
|
+
icon: /* @__PURE__ */ C(d, { size: 18 }),
|
|
41
|
+
children: k("movethewheels.tracking.purpose", "Look up any single shipment by its tracking number or order ID to see exactly where it is, its progress through pickup and delivery, the current location and any alerts — the same view you can share with a customer.")
|
|
42
|
+
}),
|
|
38
43
|
/* @__PURE__ */ C(t, { children: /* @__PURE__ */ C(n, {
|
|
39
44
|
className: "p-6",
|
|
40
45
|
children: /* @__PURE__ */ w("form", {
|
|
41
|
-
onSubmit:
|
|
46
|
+
onSubmit: H,
|
|
42
47
|
className: "flex gap-4",
|
|
43
48
|
children: [/* @__PURE__ */ w("div", {
|
|
44
49
|
className: "flex-1 relative",
|
|
45
50
|
children: [/* @__PURE__ */ C(p, { className: "absolute left-3 top-1/2 -translate-y-1/2 w-5 h-5 text-text-secondary" }), /* @__PURE__ */ C(e, {
|
|
46
|
-
value:
|
|
47
|
-
onChange: (e) =>
|
|
48
|
-
placeholder:
|
|
51
|
+
value: P,
|
|
52
|
+
onChange: (e) => F(e.target.value),
|
|
53
|
+
placeholder: k("movethewheels.tracking.search.placeholder", "Enter tracking number or order ID (e.g., order-1 or TRK123456789)"),
|
|
49
54
|
className: "pl-10 h-12 text-lg"
|
|
50
55
|
})]
|
|
51
56
|
}), /* @__PURE__ */ C(s, {
|
|
52
57
|
type: "submit",
|
|
53
58
|
size: "lg",
|
|
54
|
-
disabled: !
|
|
55
|
-
children:
|
|
59
|
+
disabled: !P || B,
|
|
60
|
+
children: B ? k("movethewheels.tracking.search.searching", "Searching...") : k("movethewheels.tracking.search.track", "Track")
|
|
56
61
|
})]
|
|
57
62
|
})
|
|
58
63
|
}) }),
|
|
59
|
-
|
|
64
|
+
V && /* @__PURE__ */ C(t, {
|
|
60
65
|
className: "border-status-error-border",
|
|
61
66
|
children: /* @__PURE__ */ C(n, {
|
|
62
67
|
className: "p-6",
|
|
@@ -64,78 +69,78 @@ function E() {
|
|
|
64
69
|
className: "flex items-center gap-4",
|
|
65
70
|
children: [/* @__PURE__ */ C(c, { className: "w-8 h-8 text-status-error-text" }), /* @__PURE__ */ w("div", { children: [/* @__PURE__ */ C("p", {
|
|
66
71
|
className: "font-medium text-status-error-text",
|
|
67
|
-
children:
|
|
72
|
+
children: k("movethewheels.tracking.error.title", "Unable to find shipment")
|
|
68
73
|
}), /* @__PURE__ */ C("p", {
|
|
69
74
|
className: "text-sm text-text-secondary",
|
|
70
|
-
children:
|
|
75
|
+
children: k("movethewheels.tracking.error.description", "Please check the tracking number and try again")
|
|
71
76
|
})] })]
|
|
72
77
|
})
|
|
73
78
|
})
|
|
74
79
|
}),
|
|
75
|
-
!
|
|
76
|
-
|
|
77
|
-
title:
|
|
78
|
-
description:
|
|
80
|
+
!I && !V && /* @__PURE__ */ C(o, {
|
|
81
|
+
illustration: "onboarding",
|
|
82
|
+
title: k("movethewheels.tracking.empty.title", "Enter a tracking number"),
|
|
83
|
+
description: k("movethewheels.tracking.empty.description", "Use your tracking number or order ID to see the current status of your shipment")
|
|
79
84
|
}),
|
|
80
|
-
|
|
85
|
+
z && R && /* @__PURE__ */ w("div", {
|
|
81
86
|
className: "grid grid-cols-1 lg:grid-cols-3 gap-6",
|
|
82
87
|
children: [/* @__PURE__ */ w("div", {
|
|
83
88
|
className: "lg:col-span-2 space-y-6",
|
|
84
89
|
children: [
|
|
85
|
-
/* @__PURE__ */ w(
|
|
86
|
-
className: "flex items-center justify-between",
|
|
87
|
-
children: [/* @__PURE__ */ w(
|
|
88
|
-
className: "flex items-center gap-2",
|
|
90
|
+
/* @__PURE__ */ w(T, { children: [/* @__PURE__ */ w("div", {
|
|
91
|
+
className: "flex items-center justify-between mb-4",
|
|
92
|
+
children: [/* @__PURE__ */ w("h2", {
|
|
93
|
+
className: "flex items-center gap-2 text-base font-semibold text-text-primary",
|
|
89
94
|
children: [
|
|
90
95
|
/* @__PURE__ */ C(f, { size: 20 }),
|
|
91
|
-
|
|
96
|
+
k("movethewheels.tracking.orderLabel", "Order"),
|
|
92
97
|
" ",
|
|
93
|
-
|
|
98
|
+
z.orderNumber
|
|
94
99
|
]
|
|
95
100
|
}), /* @__PURE__ */ C(_, {
|
|
96
|
-
status:
|
|
101
|
+
status: z.status,
|
|
97
102
|
type: "order"
|
|
98
103
|
})]
|
|
99
|
-
})
|
|
104
|
+
}), /* @__PURE__ */ w("div", {
|
|
100
105
|
className: "grid grid-cols-2 md:grid-cols-4 gap-4",
|
|
101
106
|
children: [
|
|
102
107
|
/* @__PURE__ */ w("div", { children: [/* @__PURE__ */ C("p", {
|
|
103
108
|
className: "text-sm text-text-secondary",
|
|
104
|
-
children:
|
|
109
|
+
children: k("movethewheels.tracking.details.trackingNumber", "Tracking Number")
|
|
105
110
|
}), /* @__PURE__ */ C("p", {
|
|
106
111
|
className: "font-mono font-medium",
|
|
107
|
-
children:
|
|
112
|
+
children: z.trackingNumber
|
|
108
113
|
})] }),
|
|
109
114
|
/* @__PURE__ */ w("div", { children: [/* @__PURE__ */ C("p", {
|
|
110
115
|
className: "text-sm text-text-secondary",
|
|
111
|
-
children:
|
|
116
|
+
children: k("movethewheels.tracking.details.estimatedDelivery", "Estimated Delivery")
|
|
112
117
|
}), /* @__PURE__ */ C("p", {
|
|
113
118
|
className: "font-medium",
|
|
114
|
-
children:
|
|
119
|
+
children: R.estimatedArrival ? v(R.estimatedArrival, "full") : z.scheduledDelivery ? v(z.scheduledDelivery, "full") : k("movethewheels.tracking.details.tbd", "TBD")
|
|
115
120
|
})] }),
|
|
116
121
|
/* @__PURE__ */ w("div", { children: [/* @__PURE__ */ C("p", {
|
|
117
122
|
className: "text-sm text-text-secondary",
|
|
118
|
-
children:
|
|
123
|
+
children: k("movethewheels.tracking.details.items", "Items")
|
|
119
124
|
}), /* @__PURE__ */ w("p", {
|
|
120
125
|
className: "font-medium",
|
|
121
126
|
children: [
|
|
122
|
-
|
|
127
|
+
z.items.length,
|
|
123
128
|
" ",
|
|
124
|
-
|
|
129
|
+
k("movethewheels.tracking.details.itemsSuffix", "items")
|
|
125
130
|
]
|
|
126
131
|
})] }),
|
|
127
132
|
/* @__PURE__ */ w("div", { children: [/* @__PURE__ */ C("p", {
|
|
128
133
|
className: "text-sm text-text-secondary",
|
|
129
|
-
children:
|
|
134
|
+
children: k("movethewheels.tracking.details.lastUpdated", "Last Updated")
|
|
130
135
|
}), /* @__PURE__ */ C("p", {
|
|
131
136
|
className: "font-medium",
|
|
132
|
-
children: v(
|
|
137
|
+
children: v(R.lastUpdated, "relative")
|
|
133
138
|
})] })
|
|
134
139
|
]
|
|
135
|
-
})
|
|
140
|
+
})] }),
|
|
136
141
|
/* @__PURE__ */ w(t, { children: [/* @__PURE__ */ C(i, { children: /* @__PURE__ */ w(r, {
|
|
137
142
|
className: "flex items-center gap-2",
|
|
138
|
-
children: [/* @__PURE__ */ C(u, { size: 18 }),
|
|
143
|
+
children: [/* @__PURE__ */ C(u, { size: 18 }), k("movethewheels.tracking.progress.title", "Shipment Progress")]
|
|
139
144
|
}) }), /* @__PURE__ */ w(n, { children: [/* @__PURE__ */ C("div", {
|
|
140
145
|
className: "relative",
|
|
141
146
|
children: /* @__PURE__ */ C("div", {
|
|
@@ -143,22 +148,22 @@ function E() {
|
|
|
143
148
|
children: [
|
|
144
149
|
{
|
|
145
150
|
status: "confirmed",
|
|
146
|
-
label:
|
|
151
|
+
label: k("movethewheels.tracking.progress.confirmed", "Confirmed"),
|
|
147
152
|
icon: l
|
|
148
153
|
},
|
|
149
154
|
{
|
|
150
155
|
status: "picked_up",
|
|
151
|
-
label:
|
|
156
|
+
label: k("movethewheels.tracking.progress.pickedUp", "Picked Up"),
|
|
152
157
|
icon: f
|
|
153
158
|
},
|
|
154
159
|
{
|
|
155
160
|
status: "in_transit",
|
|
156
|
-
label:
|
|
161
|
+
label: k("movethewheels.tracking.progress.inTransit", "In Transit"),
|
|
157
162
|
icon: m
|
|
158
163
|
},
|
|
159
164
|
{
|
|
160
165
|
status: "delivered",
|
|
161
|
-
label:
|
|
166
|
+
label: k("movethewheels.tracking.progress.delivered", "Delivered"),
|
|
162
167
|
icon: d
|
|
163
168
|
}
|
|
164
169
|
].map((e, t) => {
|
|
@@ -170,7 +175,7 @@ function E() {
|
|
|
170
175
|
"in_transit",
|
|
171
176
|
"out_for_delivery",
|
|
172
177
|
"delivered"
|
|
173
|
-
], r = n.indexOf(
|
|
178
|
+
], r = n.indexOf(z.status), i = n.indexOf(e.status) <= r, a = e.status === z.status || z.status === "out_for_delivery" && e.status === "in_transit";
|
|
174
179
|
return /* @__PURE__ */ w("div", {
|
|
175
180
|
className: "flex flex-col items-center flex-1",
|
|
176
181
|
children: [
|
|
@@ -195,11 +200,11 @@ function E() {
|
|
|
195
200
|
})
|
|
196
201
|
}), /* @__PURE__ */ C("div", {
|
|
197
202
|
className: "mt-8 space-y-4",
|
|
198
|
-
children:
|
|
203
|
+
children: z.timeline.slice().reverse().map((e, t) => /* @__PURE__ */ w("div", {
|
|
199
204
|
className: "flex gap-4",
|
|
200
205
|
children: [/* @__PURE__ */ w("div", {
|
|
201
206
|
className: "relative",
|
|
202
|
-
children: [/* @__PURE__ */ C("div", { className: `w-3 h-3 rounded-full ${t === 0 ? "bg-action-primary-bg" : "bg-bg-sunken"}` }), t <
|
|
207
|
+
children: [/* @__PURE__ */ C("div", { className: `w-3 h-3 rounded-full ${t === 0 ? "bg-action-primary-bg" : "bg-bg-sunken"}` }), t < z.timeline.length - 1 && /* @__PURE__ */ C("div", { className: "absolute top-3 left-1.5 w-px h-8 -ml-px bg-border" })]
|
|
203
208
|
}), /* @__PURE__ */ w("div", {
|
|
204
209
|
className: "flex-1 pb-4",
|
|
205
210
|
children: [
|
|
@@ -229,12 +234,12 @@ function E() {
|
|
|
229
234
|
})]
|
|
230
235
|
}, t))
|
|
231
236
|
})] })] }),
|
|
232
|
-
|
|
237
|
+
R.alerts && R.alerts.length > 0 && /* @__PURE__ */ w(t, { children: [/* @__PURE__ */ C(i, { children: /* @__PURE__ */ w(r, {
|
|
233
238
|
className: "flex items-center gap-2",
|
|
234
|
-
children: [/* @__PURE__ */ C(c, { size: 18 }),
|
|
239
|
+
children: [/* @__PURE__ */ C(c, { size: 18 }), k("movethewheels.tracking.alerts.title", "Alerts")]
|
|
235
240
|
}) }), /* @__PURE__ */ C(n, { children: /* @__PURE__ */ C("div", {
|
|
236
241
|
className: "space-y-3",
|
|
237
|
-
children:
|
|
242
|
+
children: R.alerts.map((e) => /* @__PURE__ */ w("div", {
|
|
238
243
|
className: `flex items-start gap-3 p-3 rounded-lg ${e.severity === "critical" ? "bg-red-50 dark:bg-red-900/20" : e.severity === "high" ? "bg-orange-50 dark:bg-orange-900/20" : "bg-yellow-50 dark:bg-yellow-900/20"}`,
|
|
239
244
|
children: [/* @__PURE__ */ C(c, {
|
|
240
245
|
size: 16,
|
|
@@ -244,7 +249,7 @@ function E() {
|
|
|
244
249
|
children: e.message
|
|
245
250
|
}), /* @__PURE__ */ w("p", {
|
|
246
251
|
className: "text-xs text-text-secondary",
|
|
247
|
-
children: [v(e.timestamp, "relative"), e.resolvedAt && ` - ${
|
|
252
|
+
children: [v(e.timestamp, "relative"), e.resolvedAt && ` - ${k("movethewheels.tracking.alerts.resolved", "Resolved")}`]
|
|
248
253
|
})] })]
|
|
249
254
|
}, e.id))
|
|
250
255
|
}) })] })
|
|
@@ -254,7 +259,7 @@ function E() {
|
|
|
254
259
|
children: [
|
|
255
260
|
/* @__PURE__ */ w(t, { children: [/* @__PURE__ */ C(i, { children: /* @__PURE__ */ w(r, {
|
|
256
261
|
className: "flex items-center gap-2",
|
|
257
|
-
children: [/* @__PURE__ */ C(d, { size: 18 }),
|
|
262
|
+
children: [/* @__PURE__ */ C(d, { size: 18 }), k("movethewheels.tracking.location.title", "Current Location")]
|
|
258
263
|
}) }), /* @__PURE__ */ w(n, { children: [
|
|
259
264
|
/* @__PURE__ */ C("div", {
|
|
260
265
|
className: "aspect-video bg-bg-sunken rounded-lg flex items-center justify-center mb-4",
|
|
@@ -265,58 +270,58 @@ function E() {
|
|
|
265
270
|
className: "mx-auto mb-2"
|
|
266
271
|
}), /* @__PURE__ */ C("p", {
|
|
267
272
|
className: "text-sm",
|
|
268
|
-
children:
|
|
273
|
+
children: k("movethewheels.tracking.location.mapView", "Map View")
|
|
269
274
|
})]
|
|
270
275
|
})
|
|
271
276
|
}),
|
|
272
277
|
/* @__PURE__ */ C("p", {
|
|
273
278
|
className: "text-sm",
|
|
274
|
-
children:
|
|
279
|
+
children: R.currentLocation.address || k("movethewheels.tracking.location.updating", "Location updating...")
|
|
275
280
|
}),
|
|
276
281
|
/* @__PURE__ */ w("p", {
|
|
277
282
|
className: "text-xs text-text-secondary mt-1",
|
|
278
283
|
children: [
|
|
279
|
-
|
|
284
|
+
k("movethewheels.tracking.location.updated", "Updated"),
|
|
280
285
|
" ",
|
|
281
|
-
v(
|
|
286
|
+
v(R.currentLocation.timestamp || /* @__PURE__ */ new Date(), "relative")
|
|
282
287
|
]
|
|
283
288
|
})
|
|
284
289
|
] })] }),
|
|
285
|
-
/* @__PURE__ */ w(t, { children: [/* @__PURE__ */ C(i, { children: /* @__PURE__ */ C(r, { children:
|
|
290
|
+
/* @__PURE__ */ w(t, { children: [/* @__PURE__ */ C(i, { children: /* @__PURE__ */ C(r, { children: k("movethewheels.tracking.deliveryAddress.title", "Delivery Address") }) }), /* @__PURE__ */ w(n, { children: [/* @__PURE__ */ C("p", {
|
|
286
291
|
className: "text-sm",
|
|
287
|
-
children:
|
|
292
|
+
children: z.customerInfo.name
|
|
288
293
|
}), /* @__PURE__ */ C("p", {
|
|
289
294
|
className: "text-sm text-text-secondary mt-2",
|
|
290
|
-
children: y(
|
|
295
|
+
children: y(z.deliveryAddress)
|
|
291
296
|
})] })] }),
|
|
292
297
|
/* @__PURE__ */ C(t, { children: /* @__PURE__ */ w(n, {
|
|
293
298
|
className: "p-4 space-y-2",
|
|
294
299
|
children: [/* @__PURE__ */ C(s, {
|
|
295
300
|
variant: "outline",
|
|
296
301
|
className: "w-full",
|
|
297
|
-
onClick: () =>
|
|
298
|
-
children:
|
|
302
|
+
onClick: () => U(`orders/${z.id}`),
|
|
303
|
+
children: k("movethewheels.tracking.actions.viewOrderDetails", "View Order Details")
|
|
299
304
|
}), /* @__PURE__ */ C(s, {
|
|
300
305
|
variant: "outline",
|
|
301
306
|
className: "w-full",
|
|
302
|
-
children:
|
|
307
|
+
children: k("movethewheels.tracking.actions.contactDriver", "Contact Driver")
|
|
303
308
|
})]
|
|
304
309
|
}) })
|
|
305
310
|
]
|
|
306
311
|
})]
|
|
307
312
|
}),
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
title:
|
|
311
|
-
description: `${
|
|
313
|
+
I && !z && !B && !V && /* @__PURE__ */ C(o, {
|
|
314
|
+
illustration: "empty-search",
|
|
315
|
+
title: k("movethewheels.tracking.notFound.title", "Shipment not found"),
|
|
316
|
+
description: `${k("movethewheels.tracking.notFound.descriptionPrefix", "No shipment found with tracking number")} "${I}"`,
|
|
312
317
|
action: /* @__PURE__ */ C(s, {
|
|
313
318
|
variant: "outline",
|
|
314
|
-
onClick: () =>
|
|
315
|
-
children:
|
|
319
|
+
onClick: () => F(""),
|
|
320
|
+
children: k("movethewheels.tracking.notFound.tryAnother", "Try another number")
|
|
316
321
|
})
|
|
317
322
|
})
|
|
318
323
|
]
|
|
319
324
|
});
|
|
320
325
|
}
|
|
321
326
|
//#endregion
|
|
322
|
-
export {
|
|
327
|
+
export { O as default };
|
|
@@ -0,0 +1,220 @@
|
|
|
1
|
+
import { M as e, d as t, f as n, g as r, h as i, i as a, l as o, n as s, r as c, u as l } from "./PageLayout-D3N8MCTm.js";
|
|
2
|
+
import { t as u } from "./arrow-left-CBpZKkpq.js";
|
|
3
|
+
import { t as d } from "./file-text-C8Uioy11.js";
|
|
4
|
+
import { n as f, t as p } from "./wrench-CmxY1n4I.js";
|
|
5
|
+
import { t as m } from "./map-pin-BSaf5IDL.js";
|
|
6
|
+
import { t as h } from "./square-pen-hLIbFQFV.js";
|
|
7
|
+
import { t as g } from "./truck-CtDjNFbi.js";
|
|
8
|
+
import { r as _ } from "./graphqlClient-CdJyR_ed.js";
|
|
9
|
+
import { a as v } from "./useFleet-BdETplNE.js";
|
|
10
|
+
import { a as y, r as b } from "./StatusBadge-CijYQXtb.js";
|
|
11
|
+
import { r as x } from "./formatters-_vJlC-47.js";
|
|
12
|
+
import { t as S } from "./navigation-BgnOfsVd.js";
|
|
13
|
+
import { useParams as C } from "react-router-dom";
|
|
14
|
+
import { jsx as w, jsxs as T } from "react/jsx-runtime";
|
|
15
|
+
import { EmphasisPanel as E, NextSteps as D, PagePurpose as O } from "@burdenoff/fe-libs/ui";
|
|
16
|
+
//#region src/movethewheels/pages/VehicleDetailsPage.tsx
|
|
17
|
+
function k() {
|
|
18
|
+
let { vehicleId: k } = C(), { basePath: A, navigate: j } = _(), { vehicle: M, isLoading: N, error: P, refetch: F } = v(k), I = () => j?.(S(A, "fleet/vehicles")), L = (e) => j?.(S(A, e));
|
|
19
|
+
return N ? /* @__PURE__ */ w(c, { message: "Loading vehicle details..." }) : P || !M ? /* @__PURE__ */ w(s, {
|
|
20
|
+
title: "Vehicle not found",
|
|
21
|
+
onRetry: F
|
|
22
|
+
}) : /* @__PURE__ */ T(a, {
|
|
23
|
+
title: M.vehicleNumber,
|
|
24
|
+
subtitle: `${M.make} ${M.model} (${M.year})`,
|
|
25
|
+
icon: /* @__PURE__ */ w(g, { size: 24 }),
|
|
26
|
+
headerActions: /* @__PURE__ */ T("div", {
|
|
27
|
+
className: "flex gap-2",
|
|
28
|
+
children: [/* @__PURE__ */ T(l, {
|
|
29
|
+
variant: "outline",
|
|
30
|
+
onClick: I,
|
|
31
|
+
children: [/* @__PURE__ */ w(u, { size: 16 }), " Back"]
|
|
32
|
+
}), /* @__PURE__ */ T(l, { children: [/* @__PURE__ */ w(h, { size: 16 }), " Edit"] })]
|
|
33
|
+
}),
|
|
34
|
+
headerContent: /* @__PURE__ */ T("div", {
|
|
35
|
+
className: "flex gap-2",
|
|
36
|
+
children: [/* @__PURE__ */ w(b, {
|
|
37
|
+
status: M.status,
|
|
38
|
+
type: "vehicle"
|
|
39
|
+
}), /* @__PURE__ */ w(y, { type: M.type })]
|
|
40
|
+
}),
|
|
41
|
+
children: [
|
|
42
|
+
/* @__PURE__ */ w(O, {
|
|
43
|
+
icon: /* @__PURE__ */ w(g, { size: 18 }),
|
|
44
|
+
children: "The full record for this vehicle — specs, capacity, fuel and mileage, maintenance schedule and current location. Use it to confirm a vehicle is fuelled, serviced and the right size before dispatching it on a delivery."
|
|
45
|
+
}),
|
|
46
|
+
/* @__PURE__ */ w(D, {
|
|
47
|
+
storageKey: "movethewheels-vehicle-details",
|
|
48
|
+
steps: [{
|
|
49
|
+
id: "assign",
|
|
50
|
+
label: "Assign to a delivery",
|
|
51
|
+
description: "Put this vehicle on an order that fits its capacity.",
|
|
52
|
+
icon: /* @__PURE__ */ w(m, { size: 16 }),
|
|
53
|
+
onClick: () => L("orders")
|
|
54
|
+
}, {
|
|
55
|
+
id: "maintenance",
|
|
56
|
+
label: "Schedule maintenance",
|
|
57
|
+
description: "Keep it road-ready and compliant.",
|
|
58
|
+
icon: /* @__PURE__ */ w(p, { size: 16 }),
|
|
59
|
+
onClick: () => {}
|
|
60
|
+
}]
|
|
61
|
+
}),
|
|
62
|
+
/* @__PURE__ */ T("div", {
|
|
63
|
+
className: "grid grid-cols-1 lg:grid-cols-3 gap-6",
|
|
64
|
+
children: [/* @__PURE__ */ T("div", {
|
|
65
|
+
className: "lg:col-span-2 space-y-6",
|
|
66
|
+
children: [
|
|
67
|
+
/* @__PURE__ */ T(E, { children: [/* @__PURE__ */ w("h2", {
|
|
68
|
+
className: "text-base font-semibold text-text-primary mb-4",
|
|
69
|
+
children: "Vehicle Information"
|
|
70
|
+
}), /* @__PURE__ */ T("div", {
|
|
71
|
+
className: "grid grid-cols-2 md:grid-cols-4 gap-6",
|
|
72
|
+
children: [
|
|
73
|
+
/* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("p", {
|
|
74
|
+
className: "text-sm text-text-secondary",
|
|
75
|
+
children: "Type"
|
|
76
|
+
}), /* @__PURE__ */ w("p", {
|
|
77
|
+
className: "font-medium capitalize",
|
|
78
|
+
children: M.type
|
|
79
|
+
})] }),
|
|
80
|
+
/* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("p", {
|
|
81
|
+
className: "text-sm text-text-secondary",
|
|
82
|
+
children: "Make"
|
|
83
|
+
}), /* @__PURE__ */ w("p", {
|
|
84
|
+
className: "font-medium",
|
|
85
|
+
children: M.make
|
|
86
|
+
})] }),
|
|
87
|
+
/* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("p", {
|
|
88
|
+
className: "text-sm text-text-secondary",
|
|
89
|
+
children: "Model"
|
|
90
|
+
}), /* @__PURE__ */ w("p", {
|
|
91
|
+
className: "font-medium",
|
|
92
|
+
children: M.model
|
|
93
|
+
})] }),
|
|
94
|
+
/* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("p", {
|
|
95
|
+
className: "text-sm text-text-secondary",
|
|
96
|
+
children: "Year"
|
|
97
|
+
}), /* @__PURE__ */ w("p", {
|
|
98
|
+
className: "font-medium",
|
|
99
|
+
children: M.year
|
|
100
|
+
})] })
|
|
101
|
+
]
|
|
102
|
+
})] }),
|
|
103
|
+
/* @__PURE__ */ T(t, { children: [/* @__PURE__ */ w(i, { children: /* @__PURE__ */ w(r, { children: "Capacity" }) }), /* @__PURE__ */ w(n, { children: /* @__PURE__ */ T("div", {
|
|
104
|
+
className: "grid grid-cols-3 gap-6",
|
|
105
|
+
children: [
|
|
106
|
+
/* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("p", {
|
|
107
|
+
className: "text-sm text-text-secondary",
|
|
108
|
+
children: "Weight"
|
|
109
|
+
}), /* @__PURE__ */ T("p", {
|
|
110
|
+
className: "text-2xl font-bold",
|
|
111
|
+
children: [M.capacity.weight, /* @__PURE__ */ w("span", {
|
|
112
|
+
className: "text-sm font-normal",
|
|
113
|
+
children: " kg"
|
|
114
|
+
})]
|
|
115
|
+
})] }),
|
|
116
|
+
/* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("p", {
|
|
117
|
+
className: "text-sm text-text-secondary",
|
|
118
|
+
children: "Volume"
|
|
119
|
+
}), /* @__PURE__ */ T("p", {
|
|
120
|
+
className: "text-2xl font-bold",
|
|
121
|
+
children: [M.capacity.volume, /* @__PURE__ */ w("span", {
|
|
122
|
+
className: "text-sm font-normal",
|
|
123
|
+
children: " m³"
|
|
124
|
+
})]
|
|
125
|
+
})] }),
|
|
126
|
+
M.capacity.pallets && /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("p", {
|
|
127
|
+
className: "text-sm text-text-secondary",
|
|
128
|
+
children: "Pallets"
|
|
129
|
+
}), /* @__PURE__ */ w("p", {
|
|
130
|
+
className: "text-2xl font-bold",
|
|
131
|
+
children: M.capacity.pallets
|
|
132
|
+
})] })
|
|
133
|
+
]
|
|
134
|
+
}) })] }),
|
|
135
|
+
/* @__PURE__ */ T(t, { children: [/* @__PURE__ */ w(i, { children: /* @__PURE__ */ T(r, {
|
|
136
|
+
className: "flex items-center gap-2",
|
|
137
|
+
children: [/* @__PURE__ */ w(d, { size: 18 }), " Documents"]
|
|
138
|
+
}) }), /* @__PURE__ */ w(n, { children: M.documents.length > 0 ? /* @__PURE__ */ w("div", {
|
|
139
|
+
className: "space-y-3",
|
|
140
|
+
children: M.documents.map((e) => /* @__PURE__ */ T("div", {
|
|
141
|
+
className: "flex items-center justify-between p-3 border rounded-lg",
|
|
142
|
+
children: [/* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("p", {
|
|
143
|
+
className: "font-medium capitalize",
|
|
144
|
+
children: e.type.replace("_", " ")
|
|
145
|
+
}), /* @__PURE__ */ T("p", {
|
|
146
|
+
className: "text-sm text-text-secondary",
|
|
147
|
+
children: ["Expires: ", x(e.expiryDate)]
|
|
148
|
+
})] }), /* @__PURE__ */ w(o, {
|
|
149
|
+
variant: e.verified ? "default" : "secondary",
|
|
150
|
+
children: e.verified ? "Verified" : "Pending"
|
|
151
|
+
})]
|
|
152
|
+
}, e.id))
|
|
153
|
+
}) : /* @__PURE__ */ w("p", {
|
|
154
|
+
className: "text-text-secondary text-center py-4",
|
|
155
|
+
children: "No documents uploaded"
|
|
156
|
+
}) })] })
|
|
157
|
+
]
|
|
158
|
+
}), /* @__PURE__ */ T("div", {
|
|
159
|
+
className: "space-y-6",
|
|
160
|
+
children: [
|
|
161
|
+
/* @__PURE__ */ T(t, { children: [/* @__PURE__ */ w(i, { children: /* @__PURE__ */ T(r, {
|
|
162
|
+
className: "flex items-center gap-2",
|
|
163
|
+
children: [/* @__PURE__ */ w(f, { size: 18 }), " Fuel & Mileage"]
|
|
164
|
+
}) }), /* @__PURE__ */ T(n, {
|
|
165
|
+
className: "space-y-4",
|
|
166
|
+
children: [M.fuelLevel !== void 0 && /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ T("div", {
|
|
167
|
+
className: "flex justify-between text-sm mb-2",
|
|
168
|
+
children: [/* @__PURE__ */ w("span", { children: "Fuel Level" }), /* @__PURE__ */ T("span", { children: [M.fuelLevel, "%"] })]
|
|
169
|
+
}), /* @__PURE__ */ w(e, { value: M.fuelLevel })] }), M.mileage !== void 0 && /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("p", {
|
|
170
|
+
className: "text-sm text-text-secondary",
|
|
171
|
+
children: "Total Mileage"
|
|
172
|
+
}), /* @__PURE__ */ T("p", {
|
|
173
|
+
className: "text-2xl font-bold",
|
|
174
|
+
children: [
|
|
175
|
+
M.mileage.toLocaleString(),
|
|
176
|
+
" ",
|
|
177
|
+
/* @__PURE__ */ w("span", {
|
|
178
|
+
className: "text-sm font-normal",
|
|
179
|
+
children: "miles"
|
|
180
|
+
})
|
|
181
|
+
]
|
|
182
|
+
})] })]
|
|
183
|
+
})] }),
|
|
184
|
+
/* @__PURE__ */ T(t, { children: [/* @__PURE__ */ w(i, { children: /* @__PURE__ */ T(r, {
|
|
185
|
+
className: "flex items-center gap-2",
|
|
186
|
+
children: [/* @__PURE__ */ w(p, { size: 18 }), " Maintenance"]
|
|
187
|
+
}) }), /* @__PURE__ */ T(n, {
|
|
188
|
+
className: "space-y-3",
|
|
189
|
+
children: [/* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("p", {
|
|
190
|
+
className: "text-sm text-text-secondary",
|
|
191
|
+
children: "Last Maintenance"
|
|
192
|
+
}), /* @__PURE__ */ w("p", {
|
|
193
|
+
className: "font-medium",
|
|
194
|
+
children: M.lastMaintenance ? x(M.lastMaintenance) : "N/A"
|
|
195
|
+
})] }), /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("p", {
|
|
196
|
+
className: "text-sm text-text-secondary",
|
|
197
|
+
children: "Next Scheduled"
|
|
198
|
+
}), /* @__PURE__ */ w("p", {
|
|
199
|
+
className: "font-medium",
|
|
200
|
+
children: M.nextMaintenance ? x(M.nextMaintenance) : "N/A"
|
|
201
|
+
})] })]
|
|
202
|
+
})] }),
|
|
203
|
+
M.currentLocation && /* @__PURE__ */ T(t, { children: [/* @__PURE__ */ w(i, { children: /* @__PURE__ */ T(r, {
|
|
204
|
+
className: "flex items-center gap-2",
|
|
205
|
+
children: [/* @__PURE__ */ w(m, { size: 18 }), " Current Location"]
|
|
206
|
+
}) }), /* @__PURE__ */ T(n, { children: [/* @__PURE__ */ w("p", {
|
|
207
|
+
className: "text-sm",
|
|
208
|
+
children: M.currentLocation.address || "Location updating..."
|
|
209
|
+
}), /* @__PURE__ */ T("p", {
|
|
210
|
+
className: "text-xs text-text-secondary mt-1",
|
|
211
|
+
children: ["Updated ", x(M.currentLocation.timestamp || /* @__PURE__ */ new Date(), "relative")]
|
|
212
|
+
})] })] })
|
|
213
|
+
]
|
|
214
|
+
})]
|
|
215
|
+
})
|
|
216
|
+
]
|
|
217
|
+
});
|
|
218
|
+
}
|
|
219
|
+
//#endregion
|
|
220
|
+
export { k as default };
|