@burdenoff/microfe-movethewheels 2026.1031.3 → 2026.1031.4

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 (58) hide show
  1. package/dist/MoveTheWheelsRoot.js +136 -127
  2. package/dist/MoveTheWheelsRoutes.js +140 -135
  3. package/dist/components/DocumentsCard.js +11 -11
  4. package/dist/components/ProofOfDeliveryCard.js +13 -13
  5. package/dist/components/ShipmentRiskDialog.js +24 -24
  6. package/dist/components/ShippingQuoteResults.js +46 -46
  7. package/dist/components/TrackingAlertList.js +17 -17
  8. package/dist/generated/tracking-quality-operations.d.ts +56 -0
  9. package/dist/hooks/useOrderDispatch.js +17 -17
  10. package/dist/movethewheels/pages/SettingsPage.d.ts +1 -0
  11. package/dist/movethewheels/providers/ModuleSettingsProvider.d.ts +17 -0
  12. package/dist/movethewheels/utils/formatters.d.ts +23 -3
  13. package/dist/movethewheels/utils/moduleSettings.d.ts +52 -0
  14. package/dist/node_modules/lucide-react/dist/esm/icons/bell.js +11 -0
  15. package/dist/node_modules/lucide-react/dist/esm/icons/key-round.js +14 -0
  16. package/dist/node_modules/lucide-react/dist/esm/icons/plug.js +22 -0
  17. package/dist/node_modules/lucide-react/dist/esm/icons/rotate-ccw.js +11 -0
  18. package/dist/node_modules/lucide-react/dist/esm/icons/settings.js +13 -0
  19. package/dist/pages/AnalyticsPage.js +27 -27
  20. package/dist/pages/CreateOrderPage.js +340 -317
  21. package/dist/pages/CustomerDetailsPage.js +246 -246
  22. package/dist/pages/CustomersPage.js +19 -19
  23. package/dist/pages/DashboardPage.js +24 -24
  24. package/dist/pages/DeliveryCapturePage.js +74 -74
  25. package/dist/pages/DriverDetailsPage.js +337 -337
  26. package/dist/pages/DriversPage.js +26 -26
  27. package/dist/pages/FinancePage.js +26 -26
  28. package/dist/pages/InventoryPage.js +28 -28
  29. package/dist/pages/LiveTrackingPage.js +108 -108
  30. package/dist/pages/MarketplacePage.js +44 -44
  31. package/dist/pages/OrderDetailsPage.js +306 -306
  32. package/dist/pages/OrdersListPage.js +27 -27
  33. package/dist/pages/ProductDetailsPage.js +89 -89
  34. package/dist/pages/ProductsPage.js +73 -73
  35. package/dist/pages/RouteDetailsPage.js +282 -285
  36. package/dist/pages/RoutesPage.js +78 -78
  37. package/dist/pages/SettingsPage.js +459 -0
  38. package/dist/pages/TrackingPage.js +41 -41
  39. package/dist/pages/VehicleDetailsPage.js +207 -207
  40. package/dist/pages/VehiclesPage.js +17 -16
  41. package/dist/pages/WarehouseDetailsPage.js +132 -132
  42. package/dist/providers/ModuleSettingsProvider.js +74 -0
  43. package/dist/utils/formatters.js +53 -26
  44. package/dist/utils/moduleSettings.js +132 -0
  45. package/package.json +3 -2
  46. package/src/generated/tracking-quality-operations.ts +62 -0
  47. package/src/movethewheels/MoveTheWheelsRoot.tsx +14 -3
  48. package/src/movethewheels/MoveTheWheelsRoutes.tsx +9 -0
  49. package/src/movethewheels/pages/CreateOrderPage.tsx +38 -6
  50. package/src/movethewheels/pages/ProductsPage.tsx +2 -2
  51. package/src/movethewheels/pages/RouteDetailsPage.tsx +3 -6
  52. package/src/movethewheels/pages/RoutesPage.tsx +2 -2
  53. package/src/movethewheels/pages/SettingsPage.tsx +516 -0
  54. package/src/movethewheels/pages/VehicleDetailsPage.tsx +4 -2
  55. package/src/movethewheels/pages/VehiclesPage.tsx +2 -1
  56. package/src/movethewheels/providers/ModuleSettingsProvider.tsx +133 -0
  57. package/src/movethewheels/utils/formatters.ts +69 -10
  58. package/src/movethewheels/utils/moduleSettings.ts +224 -0
@@ -10,25 +10,25 @@ import { Truck as c } from "../node_modules/lucide-react/dist/esm/icons/truck.js
10
10
  import { UserRound as l } from "../node_modules/lucide-react/dist/esm/icons/user-round.js";
11
11
  import { joinPath as u } from "../utils/navigation.js";
12
12
  import { useMoveTheWheels as d } from "../providers/MoveTheWheelsProvider.js";
13
- import { toApiVehicleStatus as f, useFleet as p, useVehicle as m, useVehicleDrivers as h } from "../hooks/useFleet.js";
14
- import { Avatar as g, AvatarFallback as _, Button as v, Card as y, CardContent as b, CardHeader as x, CardTitle as S, Input as C, Label as w, Progress as T, Select as E, SelectContent as D, SelectItem as O, SelectTrigger as k, SelectValue as A } from "../components/ui.js";
15
- import { ErrorState as j, LoadingState as M, PageLayout as N } from "../components/PageLayout.js";
16
- import { VEHICLE_STATUS_LABELS as P } from "../constants/index.js";
17
- import { StatusBadge as F, VehicleTypeBadge as I } from "../components/StatusBadge.js";
18
- import { FormError as L } from "../components/FormError.js";
19
- import { Notice as R, useNotice as z } from "../components/Notice.js";
20
- import { formatDate as B, getInitials as V } from "../utils/formatters.js";
21
- import { DocumentsCard as H } from "../components/DocumentsCard.js";
22
- import { useRefetchOnLeaveEdit as U } from "../hooks/useRefetchOnLeaveEdit.js";
23
- import { useRecordVehicleService as W } from "../hooks/useFleetIntelligence.js";
24
- import { VehicleServiceCard as ee } from "../components/VehicleServiceCard.js";
13
+ import { formatDate as f, formatWeight as p, getInitials as m } from "../utils/formatters.js";
14
+ import { toApiVehicleStatus as h, useFleet as g, useVehicle as _, useVehicleDrivers as v } from "../hooks/useFleet.js";
15
+ import { Avatar as y, AvatarFallback as b, Button as x, Card as S, CardContent as C, CardHeader as w, CardTitle as T, Input as E, Label as D, Progress as O, Select as k, SelectContent as A, SelectItem as j, SelectTrigger as M, SelectValue as N } from "../components/ui.js";
16
+ import { ErrorState as P, LoadingState as F, PageLayout as I } from "../components/PageLayout.js";
17
+ import { VEHICLE_STATUS_LABELS as L } from "../constants/index.js";
18
+ import { StatusBadge as R, VehicleTypeBadge as z } from "../components/StatusBadge.js";
19
+ import { FormError as B } from "../components/FormError.js";
20
+ import { Notice as V, useNotice as H } from "../components/Notice.js";
21
+ import { DocumentsCard as U } from "../components/DocumentsCard.js";
22
+ import { useRefetchOnLeaveEdit as W } from "../hooks/useRefetchOnLeaveEdit.js";
23
+ import { useRecordVehicleService as ee } from "../hooks/useFleetIntelligence.js";
24
+ import { VehicleServiceCard as te } from "../components/VehicleServiceCard.js";
25
25
  import { useEffect as G, useState as K } from "react";
26
- import { useLocation as te, useParams as ne } from "react-router";
26
+ import { useLocation as ne, useParams as re } from "react-router";
27
27
  import { jsx as q, jsxs as J } from "react/jsx-runtime";
28
- import { useI18n as re } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
29
- import { EmphasisPanel as Y, NextSteps as ie, PagePurpose as X, ResponsiveDialog as Z, ResponsiveDialogContent as Q, ResponsiveDialogDescription as $, ResponsiveDialogFooter as ae, ResponsiveDialogHeader as oe, ResponsiveDialogTitle as se } from "@burdenoff/fe-libs/ui";
28
+ import { useI18n as ie } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
29
+ import { EmphasisPanel as Y, NextSteps as ae, PagePurpose as X, ResponsiveDialog as Z, ResponsiveDialogContent as Q, ResponsiveDialogDescription as $, ResponsiveDialogFooter as oe, ResponsiveDialogHeader as se, ResponsiveDialogTitle as ce } from "@burdenoff/fe-libs/ui";
30
30
  //#region src/movethewheels/pages/VehicleDetailsPage.tsx
31
- var ce = [
31
+ var le = [
32
32
  {
33
33
  value: "TRUCK",
34
34
  label: "Truck"
@@ -61,10 +61,10 @@ var ce = [
61
61
  value: "DRONE",
62
62
  label: "Drone"
63
63
  }
64
- ], le = Object.entries(P).map(([e, t]) => ({
64
+ ], ue = Object.entries(L).map(([e, t]) => ({
65
65
  value: e,
66
66
  label: t
67
- })), ue = [
67
+ })), de = [
68
68
  {
69
69
  value: "DIESEL",
70
70
  label: "Diesel"
@@ -85,7 +85,7 @@ var ce = [
85
85
  value: "HYBRID",
86
86
  label: "Hybrid"
87
87
  }
88
- ], de = [
88
+ ], fe = [
89
89
  {
90
90
  value: "owned",
91
91
  label: "Owned"
@@ -99,8 +99,8 @@ var ce = [
99
99
  label: "Rented"
100
100
  }
101
101
  ];
102
- function fe({ editId: t }) {
103
- let { basePath: n, navigate: r } = d(), { createVehicle: i, updateVehicle: o, deleteVehicle: l } = p(), { vehicle: h } = m(t), g = !!t, [_, T] = K({
102
+ function pe({ editId: t }) {
103
+ let { basePath: n, navigate: r } = d(), { createVehicle: i, updateVehicle: o, deleteVehicle: l } = g(), { vehicle: f } = _(t), p = !!t, [m, v] = K({
104
104
  vehicleNumber: "",
105
105
  type: "VAN",
106
106
  make: "",
@@ -114,46 +114,46 @@ function fe({ editId: t }) {
114
114
  capacityWeight: "",
115
115
  capacityVolume: "",
116
116
  capacityPallets: ""
117
- }), [j, M] = K(!1), [P, F] = K(null), [I, R] = K(!1), [z, B] = K(!1), [V, H] = K(null);
117
+ }), [y, b] = K(!1), [O, P] = K(null), [F, L] = K(!1), [R, z] = K(!1), [V, H] = K(null);
118
118
  G(() => {
119
- t && h && T({
120
- vehicleNumber: h.vehicleNumber ?? "",
121
- type: h.type ? h.type.toUpperCase() : "VAN",
122
- make: h.make ?? "",
123
- model: h.model ?? "",
124
- licensePlate: h.licensePlate ?? "",
125
- ownershipType: h.ownershipType ?? "",
126
- year: h.year ? String(h.year) : "",
127
- status: h.status,
128
- fuelType: h.fuelType ?? "",
129
- fuelEfficiencyLPer100Km: h.fuelEfficiencyLPer100Km === void 0 ? "" : String(h.fuelEfficiencyLPer100Km),
130
- capacityWeight: h.capacity.weight ? String(h.capacity.weight) : "",
131
- capacityVolume: h.capacity.volume ? String(h.capacity.volume) : "",
132
- capacityPallets: h.capacity.pallets ? String(h.capacity.pallets) : ""
119
+ t && f && v({
120
+ vehicleNumber: f.vehicleNumber ?? "",
121
+ type: f.type ? f.type.toUpperCase() : "VAN",
122
+ make: f.make ?? "",
123
+ model: f.model ?? "",
124
+ licensePlate: f.licensePlate ?? "",
125
+ ownershipType: f.ownershipType ?? "",
126
+ year: f.year ? String(f.year) : "",
127
+ status: f.status,
128
+ fuelType: f.fuelType ?? "",
129
+ fuelEfficiencyLPer100Km: f.fuelEfficiencyLPer100Km === void 0 ? "" : String(f.fuelEfficiencyLPer100Km),
130
+ capacityWeight: f.capacity.weight ? String(f.capacity.weight) : "",
131
+ capacityVolume: f.capacity.volume ? String(f.capacity.volume) : "",
132
+ capacityPallets: f.capacity.pallets ? String(f.capacity.pallets) : ""
133
133
  });
134
- }, [t, h]);
134
+ }, [t, f]);
135
135
  let U = () => r?.(u(n, "fleet/vehicles")), W = async (e) => {
136
- if (e.preventDefault(), !_.vehicleNumber.trim()) {
137
- F("Vehicle number is required.");
136
+ if (e.preventDefault(), !m.vehicleNumber.trim()) {
137
+ P("Vehicle number is required.");
138
138
  return;
139
139
  }
140
- M(!0), F(null);
140
+ b(!0), P(null);
141
141
  try {
142
142
  let e = {
143
- vehicleNumber: _.vehicleNumber.trim(),
144
- type: _.type,
145
- make: _.make.trim() || void 0,
146
- model: _.model.trim() || void 0,
147
- licensePlate: _.licensePlate.trim() || void 0,
148
- ownershipType: _.ownershipType || void 0,
149
- year: _.year ? Number(_.year) : void 0,
150
- status: f(_.status),
151
- fuelType: _.fuelType || void 0,
152
- fuelEfficiencyLPer100Km: _.fuelEfficiencyLPer100Km ? Number(_.fuelEfficiencyLPer100Km) : void 0,
153
- capacity: _.capacityWeight || _.capacityVolume || _.capacityPallets ? {
154
- weight: _.capacityWeight ? Number(_.capacityWeight) : void 0,
155
- volume: _.capacityVolume ? Number(_.capacityVolume) : void 0,
156
- pallets: _.capacityPallets ? Number(_.capacityPallets) : void 0
143
+ vehicleNumber: m.vehicleNumber.trim(),
144
+ type: m.type,
145
+ make: m.make.trim() || void 0,
146
+ model: m.model.trim() || void 0,
147
+ licensePlate: m.licensePlate.trim() || void 0,
148
+ ownershipType: m.ownershipType || void 0,
149
+ year: m.year ? Number(m.year) : void 0,
150
+ status: h(m.status),
151
+ fuelType: m.fuelType || void 0,
152
+ fuelEfficiencyLPer100Km: m.fuelEfficiencyLPer100Km ? Number(m.fuelEfficiencyLPer100Km) : void 0,
153
+ capacity: m.capacityWeight || m.capacityVolume || m.capacityPallets ? {
154
+ weight: m.capacityWeight ? Number(m.capacityWeight) : void 0,
155
+ volume: m.capacityVolume ? Number(m.capacityVolume) : void 0,
156
+ pallets: m.capacityPallets ? Number(m.capacityPallets) : void 0
157
157
  } : void 0
158
158
  };
159
159
  if (t) {
@@ -164,27 +164,27 @@ function fe({ editId: t }) {
164
164
  r?.(u(n, `fleet/vehicles/${t.id}`));
165
165
  }
166
166
  } catch (e) {
167
- console.error("Failed to create vehicle:", e), F(e instanceof Error ? e.message : "Failed to create vehicle. Please try again."), M(!1);
167
+ console.error("Failed to create vehicle:", e), P(e instanceof Error ? e.message : "Failed to create vehicle. Please try again."), b(!1);
168
168
  }
169
169
  };
170
- return /* @__PURE__ */ J(N, {
171
- title: g ? "Edit Vehicle" : "Add Vehicle",
170
+ return /* @__PURE__ */ J(I, {
171
+ title: p ? "Edit Vehicle" : "Add Vehicle",
172
172
  subtitle: "Register a new vehicle in your fleet",
173
173
  icon: /* @__PURE__ */ q(c, { size: 24 }),
174
174
  headerActions: /* @__PURE__ */ J("div", {
175
175
  className: "flex gap-2",
176
- children: [/* @__PURE__ */ J(v, {
176
+ children: [/* @__PURE__ */ J(x, {
177
177
  variant: "outline",
178
178
  onClick: U,
179
- disabled: j,
179
+ disabled: y,
180
180
  children: [/* @__PURE__ */ q(e, { size: 16 }), " Cancel"]
181
- }), /* @__PURE__ */ J(v, {
181
+ }), /* @__PURE__ */ J(x, {
182
182
  onClick: W,
183
- disabled: j,
183
+ disabled: y,
184
184
  children: [
185
185
  /* @__PURE__ */ q(a, { size: 16 }),
186
186
  " ",
187
- g ? j ? "Saving..." : "Save Changes" : j ? "Saving..." : "Add Vehicle"
187
+ p ? y ? "Saving..." : "Save Changes" : y ? "Saving..." : "Add Vehicle"
188
188
  ]
189
189
  })]
190
190
  }),
@@ -197,7 +197,7 @@ function fe({ editId: t }) {
197
197
  onSubmit: W,
198
198
  className: "max-w-2xl space-y-6",
199
199
  children: [
200
- /* @__PURE__ */ q(L, { message: P }),
200
+ /* @__PURE__ */ q(B, { message: O }),
201
201
  /* @__PURE__ */ J(Y, { children: [/* @__PURE__ */ q("h2", {
202
202
  className: "text-base font-semibold text-text-primary mb-4",
203
203
  children: "Vehicle Details"
@@ -208,16 +208,16 @@ function fe({ editId: t }) {
208
208
  className: "grid grid-cols-1 md:grid-cols-2 gap-4",
209
209
  children: [/* @__PURE__ */ J("div", {
210
210
  className: "space-y-2",
211
- children: [/* @__PURE__ */ J(w, {
211
+ children: [/* @__PURE__ */ J(D, {
212
212
  htmlFor: "vehicleNumber",
213
213
  children: ["Vehicle Number ", /* @__PURE__ */ q("span", {
214
214
  className: "text-status-error-text",
215
215
  children: "*"
216
216
  })]
217
- }), /* @__PURE__ */ q(C, {
217
+ }), /* @__PURE__ */ q(E, {
218
218
  id: "vehicleNumber",
219
- value: _.vehicleNumber,
220
- onChange: (e) => T((t) => ({
219
+ value: m.vehicleNumber,
220
+ onChange: (e) => v((t) => ({
221
221
  ...t,
222
222
  vehicleNumber: e.target.value
223
223
  })),
@@ -226,22 +226,22 @@ function fe({ editId: t }) {
226
226
  })]
227
227
  }), /* @__PURE__ */ J("div", {
228
228
  className: "space-y-2",
229
- children: [/* @__PURE__ */ J(w, {
229
+ children: [/* @__PURE__ */ J(D, {
230
230
  htmlFor: "type",
231
231
  children: ["Type ", /* @__PURE__ */ q("span", {
232
232
  className: "text-status-error-text",
233
233
  children: "*"
234
234
  })]
235
- }), /* @__PURE__ */ J(E, {
236
- value: _.type,
237
- onValueChange: (e) => T((t) => ({
235
+ }), /* @__PURE__ */ J(k, {
236
+ value: m.type,
237
+ onValueChange: (e) => v((t) => ({
238
238
  ...t,
239
239
  type: e
240
240
  })),
241
- children: [/* @__PURE__ */ q(k, {
241
+ children: [/* @__PURE__ */ q(M, {
242
242
  id: "type",
243
- children: /* @__PURE__ */ q(A, {})
244
- }), /* @__PURE__ */ q(D, { children: ce.map((e) => /* @__PURE__ */ q(O, {
243
+ children: /* @__PURE__ */ q(N, {})
244
+ }), /* @__PURE__ */ q(A, { children: le.map((e) => /* @__PURE__ */ q(j, {
245
245
  value: e.value,
246
246
  children: e.label
247
247
  }, e.value)) })]
@@ -253,13 +253,13 @@ function fe({ editId: t }) {
253
253
  children: [
254
254
  /* @__PURE__ */ J("div", {
255
255
  className: "space-y-2",
256
- children: [/* @__PURE__ */ q(w, {
256
+ children: [/* @__PURE__ */ q(D, {
257
257
  htmlFor: "make",
258
258
  children: "Make"
259
- }), /* @__PURE__ */ q(C, {
259
+ }), /* @__PURE__ */ q(E, {
260
260
  id: "make",
261
- value: _.make,
262
- onChange: (e) => T((t) => ({
261
+ value: m.make,
262
+ onChange: (e) => v((t) => ({
263
263
  ...t,
264
264
  make: e.target.value
265
265
  })),
@@ -268,13 +268,13 @@ function fe({ editId: t }) {
268
268
  }),
269
269
  /* @__PURE__ */ J("div", {
270
270
  className: "space-y-2",
271
- children: [/* @__PURE__ */ q(w, {
271
+ children: [/* @__PURE__ */ q(D, {
272
272
  htmlFor: "model",
273
273
  children: "Model"
274
- }), /* @__PURE__ */ q(C, {
274
+ }), /* @__PURE__ */ q(E, {
275
275
  id: "model",
276
- value: _.model,
277
- onChange: (e) => T((t) => ({
276
+ value: m.model,
277
+ onChange: (e) => v((t) => ({
278
278
  ...t,
279
279
  model: e.target.value
280
280
  })),
@@ -283,13 +283,13 @@ function fe({ editId: t }) {
283
283
  }),
284
284
  /* @__PURE__ */ J("div", {
285
285
  className: "space-y-2",
286
- children: [/* @__PURE__ */ q(w, {
286
+ children: [/* @__PURE__ */ q(D, {
287
287
  htmlFor: "licensePlate",
288
288
  children: "License Plate"
289
- }), /* @__PURE__ */ q(C, {
289
+ }), /* @__PURE__ */ q(E, {
290
290
  id: "licensePlate",
291
- value: _.licensePlate,
292
- onChange: (e) => T((t) => ({
291
+ value: m.licensePlate,
292
+ onChange: (e) => v((t) => ({
293
293
  ...t,
294
294
  licensePlate: e.target.value
295
295
  })),
@@ -303,19 +303,19 @@ function fe({ editId: t }) {
303
303
  children: [
304
304
  /* @__PURE__ */ J("div", {
305
305
  className: "space-y-2",
306
- children: [/* @__PURE__ */ q(w, {
306
+ children: [/* @__PURE__ */ q(D, {
307
307
  htmlFor: "ownershipType",
308
308
  children: "Ownership"
309
- }), /* @__PURE__ */ J(E, {
310
- value: _.ownershipType || void 0,
311
- onValueChange: (e) => T((t) => ({
309
+ }), /* @__PURE__ */ J(k, {
310
+ value: m.ownershipType || void 0,
311
+ onValueChange: (e) => v((t) => ({
312
312
  ...t,
313
313
  ownershipType: e
314
314
  })),
315
- children: [/* @__PURE__ */ q(k, {
315
+ children: [/* @__PURE__ */ q(M, {
316
316
  id: "ownershipType",
317
- children: /* @__PURE__ */ q(A, { placeholder: "Select ownership" })
318
- }), /* @__PURE__ */ q(D, { children: de.map((e) => /* @__PURE__ */ q(O, {
317
+ children: /* @__PURE__ */ q(N, { placeholder: "Select ownership" })
318
+ }), /* @__PURE__ */ q(A, { children: fe.map((e) => /* @__PURE__ */ q(j, {
319
319
  value: e.value,
320
320
  children: e.label
321
321
  }, e.value)) })]
@@ -323,16 +323,16 @@ function fe({ editId: t }) {
323
323
  }),
324
324
  /* @__PURE__ */ J("div", {
325
325
  className: "space-y-2",
326
- children: [/* @__PURE__ */ q(w, {
326
+ children: [/* @__PURE__ */ q(D, {
327
327
  htmlFor: "year",
328
328
  children: "Year"
329
- }), /* @__PURE__ */ q(C, {
329
+ }), /* @__PURE__ */ q(E, {
330
330
  id: "year",
331
331
  type: "number",
332
332
  min: 1980,
333
333
  max: (/* @__PURE__ */ new Date()).getFullYear() + 1,
334
- value: _.year,
335
- onChange: (e) => T((t) => ({
334
+ value: m.year,
335
+ onChange: (e) => v((t) => ({
336
336
  ...t,
337
337
  year: e.target.value
338
338
  })),
@@ -341,19 +341,19 @@ function fe({ editId: t }) {
341
341
  }),
342
342
  /* @__PURE__ */ J("div", {
343
343
  className: "space-y-2",
344
- children: [/* @__PURE__ */ q(w, {
344
+ children: [/* @__PURE__ */ q(D, {
345
345
  htmlFor: "vehicleStatus",
346
346
  children: "Status"
347
- }), /* @__PURE__ */ J(E, {
348
- value: _.status,
349
- onValueChange: (e) => T((t) => ({
347
+ }), /* @__PURE__ */ J(k, {
348
+ value: m.status,
349
+ onValueChange: (e) => v((t) => ({
350
350
  ...t,
351
351
  status: e
352
352
  })),
353
- children: [/* @__PURE__ */ q(k, {
353
+ children: [/* @__PURE__ */ q(M, {
354
354
  id: "vehicleStatus",
355
- children: /* @__PURE__ */ q(A, {})
356
- }), /* @__PURE__ */ q(D, { children: le.map((e) => /* @__PURE__ */ q(O, {
355
+ children: /* @__PURE__ */ q(N, {})
356
+ }), /* @__PURE__ */ q(A, { children: ue.map((e) => /* @__PURE__ */ q(j, {
357
357
  value: e.value,
358
358
  children: e.label
359
359
  }, e.value)) })]
@@ -365,38 +365,38 @@ function fe({ editId: t }) {
365
365
  className: "grid grid-cols-1 md:grid-cols-2 gap-4",
366
366
  children: [/* @__PURE__ */ J("div", {
367
367
  className: "space-y-2",
368
- children: [/* @__PURE__ */ q(w, {
368
+ children: [/* @__PURE__ */ q(D, {
369
369
  htmlFor: "fuelType",
370
370
  children: "Fuel Type"
371
- }), /* @__PURE__ */ J(E, {
372
- value: _.fuelType || void 0,
371
+ }), /* @__PURE__ */ J(k, {
372
+ value: m.fuelType || void 0,
373
373
  onValueChange: (e) => {
374
- let t = ue.find((t) => t.value === e)?.value;
375
- T((e) => ({
374
+ let t = de.find((t) => t.value === e)?.value;
375
+ v((e) => ({
376
376
  ...e,
377
377
  fuelType: t ?? ""
378
378
  }));
379
379
  },
380
- children: [/* @__PURE__ */ q(k, {
380
+ children: [/* @__PURE__ */ q(M, {
381
381
  id: "fuelType",
382
- children: /* @__PURE__ */ q(A, { placeholder: "Select fuel type" })
383
- }), /* @__PURE__ */ q(D, { children: ue.map((e) => /* @__PURE__ */ q(O, {
382
+ children: /* @__PURE__ */ q(N, { placeholder: "Select fuel type" })
383
+ }), /* @__PURE__ */ q(A, { children: de.map((e) => /* @__PURE__ */ q(j, {
384
384
  value: e.value,
385
385
  children: e.label
386
386
  }, e.value)) })]
387
387
  })]
388
388
  }), /* @__PURE__ */ J("div", {
389
389
  className: "space-y-2",
390
- children: [/* @__PURE__ */ q(w, {
390
+ children: [/* @__PURE__ */ q(D, {
391
391
  htmlFor: "fuelEfficiency",
392
392
  children: "Fuel Efficiency (L/100km)"
393
- }), /* @__PURE__ */ q(C, {
393
+ }), /* @__PURE__ */ q(E, {
394
394
  id: "fuelEfficiency",
395
395
  type: "number",
396
396
  min: 0,
397
397
  step: .1,
398
- value: _.fuelEfficiencyLPer100Km,
399
- onChange: (e) => T((t) => ({
398
+ value: m.fuelEfficiencyLPer100Km,
399
+ onChange: (e) => v((t) => ({
400
400
  ...t,
401
401
  fuelEfficiencyLPer100Km: e.target.value
402
402
  })),
@@ -409,15 +409,15 @@ function fe({ editId: t }) {
409
409
  children: [
410
410
  /* @__PURE__ */ J("div", {
411
411
  className: "space-y-2",
412
- children: [/* @__PURE__ */ q(w, {
412
+ children: [/* @__PURE__ */ q(D, {
413
413
  htmlFor: "capacityWeight",
414
414
  children: "Capacity — Weight (kg)"
415
- }), /* @__PURE__ */ q(C, {
415
+ }), /* @__PURE__ */ q(E, {
416
416
  id: "capacityWeight",
417
417
  type: "number",
418
418
  min: 0,
419
- value: _.capacityWeight,
420
- onChange: (e) => T((t) => ({
419
+ value: m.capacityWeight,
420
+ onChange: (e) => v((t) => ({
421
421
  ...t,
422
422
  capacityWeight: e.target.value
423
423
  })),
@@ -426,16 +426,16 @@ function fe({ editId: t }) {
426
426
  }),
427
427
  /* @__PURE__ */ J("div", {
428
428
  className: "space-y-2",
429
- children: [/* @__PURE__ */ q(w, {
429
+ children: [/* @__PURE__ */ q(D, {
430
430
  htmlFor: "capacityVolume",
431
431
  children: "Capacity — Volume (m³)"
432
- }), /* @__PURE__ */ q(C, {
432
+ }), /* @__PURE__ */ q(E, {
433
433
  id: "capacityVolume",
434
434
  type: "number",
435
435
  min: 0,
436
436
  step: .1,
437
- value: _.capacityVolume,
438
- onChange: (e) => T((t) => ({
437
+ value: m.capacityVolume,
438
+ onChange: (e) => v((t) => ({
439
439
  ...t,
440
440
  capacityVolume: e.target.value
441
441
  })),
@@ -444,15 +444,15 @@ function fe({ editId: t }) {
444
444
  }),
445
445
  /* @__PURE__ */ J("div", {
446
446
  className: "space-y-2",
447
- children: [/* @__PURE__ */ q(w, {
447
+ children: [/* @__PURE__ */ q(D, {
448
448
  htmlFor: "capacityPallets",
449
449
  children: "Capacity — Pallets"
450
- }), /* @__PURE__ */ q(C, {
450
+ }), /* @__PURE__ */ q(E, {
451
451
  id: "capacityPallets",
452
452
  type: "number",
453
453
  min: 0,
454
- value: _.capacityPallets,
455
- onChange: (e) => T((t) => ({
454
+ value: m.capacityPallets,
455
+ onChange: (e) => v((t) => ({
456
456
  ...t,
457
457
  capacityPallets: e.target.value
458
458
  })),
@@ -463,102 +463,102 @@ function fe({ editId: t }) {
463
463
  })
464
464
  ]
465
465
  })] }),
466
- g && /* @__PURE__ */ J(y, {
466
+ p && /* @__PURE__ */ J(S, {
467
467
  className: "border-status-error-border",
468
- children: [/* @__PURE__ */ q(x, { children: /* @__PURE__ */ J(S, {
468
+ children: [/* @__PURE__ */ q(w, { children: /* @__PURE__ */ J(T, {
469
469
  className: "flex items-center gap-2 text-status-error-text",
470
470
  children: [/* @__PURE__ */ q(s, { size: 18 }), " Delete Vehicle"]
471
- }) }), /* @__PURE__ */ J(b, { children: [/* @__PURE__ */ q("p", {
471
+ }) }), /* @__PURE__ */ J(C, { children: [/* @__PURE__ */ q("p", {
472
472
  className: "mb-3 text-sm text-text-secondary",
473
473
  children: "Removes this vehicle from the active fleet. It can no longer be assigned to drivers, orders, or routes. This cannot be undone from here."
474
- }), /* @__PURE__ */ J(v, {
474
+ }), /* @__PURE__ */ J(x, {
475
475
  type: "button",
476
476
  variant: "outline",
477
477
  className: "border-status-error-border text-status-error-text hover:bg-status-error-bg-subtle",
478
- onClick: () => R(!0),
478
+ onClick: () => L(!0),
479
479
  children: [/* @__PURE__ */ q(s, { size: 16 }), " Delete this vehicle"]
480
480
  })] })]
481
481
  })
482
482
  ]
483
483
  }),
484
484
  /* @__PURE__ */ q(Z, {
485
- open: I,
486
- onOpenChange: R,
485
+ open: F,
486
+ onOpenChange: L,
487
487
  children: /* @__PURE__ */ J(Q, { children: [
488
- /* @__PURE__ */ J(oe, { children: [/* @__PURE__ */ q(se, { children: "Delete this vehicle?" }), /* @__PURE__ */ J($, { children: [
488
+ /* @__PURE__ */ J(se, { children: [/* @__PURE__ */ q(ce, { children: "Delete this vehicle?" }), /* @__PURE__ */ J($, { children: [
489
489
  "This removes ",
490
- _.vehicleNumber || "this vehicle",
490
+ m.vehicleNumber || "this vehicle",
491
491
  " from the active fleet. It cannot be undone from here."
492
492
  ] })] }),
493
493
  /* @__PURE__ */ q("div", {
494
494
  className: "px-1",
495
- children: /* @__PURE__ */ q(L, { message: V })
495
+ children: /* @__PURE__ */ q(B, { message: V })
496
496
  }),
497
- /* @__PURE__ */ J(ae, { children: [/* @__PURE__ */ q(v, {
497
+ /* @__PURE__ */ J(oe, { children: [/* @__PURE__ */ q(x, {
498
498
  variant: "outline",
499
- onClick: () => R(!1),
500
- disabled: z,
499
+ onClick: () => L(!1),
500
+ disabled: R,
501
501
  children: "Cancel"
502
- }), /* @__PURE__ */ q(v, {
502
+ }), /* @__PURE__ */ q(x, {
503
503
  className: "bg-status-error-text text-text-inverse hover:opacity-90",
504
504
  onClick: async () => {
505
505
  if (t) {
506
- B(!0), H(null);
506
+ z(!0), H(null);
507
507
  try {
508
- await l(t), R(!1), r?.(u(n, "fleet/vehicles"));
508
+ await l(t), L(!1), r?.(u(n, "fleet/vehicles"));
509
509
  } catch (e) {
510
510
  H(e instanceof Error ? e.message : "Failed to delete vehicle.");
511
511
  } finally {
512
- B(!1);
512
+ z(!1);
513
513
  }
514
514
  }
515
515
  },
516
- disabled: z,
517
- children: z ? "Deleting..." : "Delete vehicle"
516
+ disabled: R,
517
+ children: R ? "Deleting..." : "Delete vehicle"
518
518
  })] })
519
519
  ] })
520
520
  })
521
521
  ]
522
522
  });
523
523
  }
524
- function pe() {
525
- let { vehicleId: a } = ne(), { basePath: s, navigate: f } = d(), { vehicle: p, isLoading: C, error: w, refetch: E } = m(a), D = W(), { message: O, notify: k } = z(), { t: A } = re(), P = (e, t) => {
526
- let n = A(e);
524
+ function me() {
525
+ let { vehicleId: a } = re(), { basePath: s, navigate: h } = d(), { vehicle: g, isLoading: E, error: D, refetch: k } = _(a), A = ee(), { message: j, notify: M } = H(), { t: N } = ie(), L = (e, t) => {
526
+ let n = N(e);
527
527
  return n === e ? t : n;
528
- }, L = te().pathname.endsWith("/edit");
529
- U(L, E);
530
- let { drivers: G, isLoading: K, error: Z } = h(L ? void 0 : a), Q = () => f?.(u(s, "fleet/vehicles")), $ = (e) => f?.(u(s, e));
531
- return a ? L ? /* @__PURE__ */ q(fe, { editId: a }) : C ? /* @__PURE__ */ q(M, { message: "Loading vehicle details..." }) : w || !p ? /* @__PURE__ */ q(j, {
528
+ }, B = ne().pathname.endsWith("/edit");
529
+ W(B, k);
530
+ let { drivers: G, isLoading: K, error: Z } = v(B ? void 0 : a), Q = () => h?.(u(s, "fleet/vehicles")), $ = (e) => h?.(u(s, e));
531
+ return a ? B ? /* @__PURE__ */ q(pe, { editId: a }) : E ? /* @__PURE__ */ q(F, { message: "Loading vehicle details..." }) : D || !g ? /* @__PURE__ */ q(P, {
532
532
  title: "Vehicle not found",
533
- onRetry: E
534
- }) : /* @__PURE__ */ J(N, {
535
- title: p.vehicleNumber,
536
- subtitle: `${p.make} ${p.model}${p.year ? ` (${p.year})` : ""}`,
533
+ onRetry: k
534
+ }) : /* @__PURE__ */ J(I, {
535
+ title: g.vehicleNumber,
536
+ subtitle: `${g.make} ${g.model}${g.year ? ` (${g.year})` : ""}`,
537
537
  icon: /* @__PURE__ */ q(c, { size: 24 }),
538
538
  headerActions: /* @__PURE__ */ J("div", {
539
539
  className: "flex gap-2",
540
- children: [/* @__PURE__ */ J(v, {
540
+ children: [/* @__PURE__ */ J(x, {
541
541
  variant: "outline",
542
542
  onClick: Q,
543
543
  children: [/* @__PURE__ */ q(e, { size: 16 }), " Back"]
544
- }), /* @__PURE__ */ J(v, {
545
- onClick: () => f?.(u(s, "fleet/vehicles/" + a + "/edit")),
544
+ }), /* @__PURE__ */ J(x, {
545
+ onClick: () => h?.(u(s, "fleet/vehicles/" + a + "/edit")),
546
546
  children: [/* @__PURE__ */ q(o, { size: 16 }), " Edit"]
547
547
  })]
548
548
  }),
549
549
  headerContent: /* @__PURE__ */ J("div", {
550
550
  className: "flex gap-2",
551
- children: [/* @__PURE__ */ q(F, {
552
- status: p.status,
551
+ children: [/* @__PURE__ */ q(R, {
552
+ status: g.status,
553
553
  type: "vehicle"
554
- }), /* @__PURE__ */ q(I, { type: p.type })]
554
+ }), /* @__PURE__ */ q(z, { type: g.type })]
555
555
  }),
556
556
  children: [
557
557
  /* @__PURE__ */ q(X, {
558
558
  icon: /* @__PURE__ */ q(c, { size: 18 }),
559
559
  children: "The full record for this vehicle — specs, capacity, fuel and mileage, who is driving it and where it is right now. Use it to confirm a vehicle is fuelled, crewed and the right size before dispatching it on a delivery."
560
560
  }),
561
- /* @__PURE__ */ q(ie, {
561
+ /* @__PURE__ */ q(ae, {
562
562
  storageKey: "movethewheels-vehicle-details",
563
563
  steps: [{
564
564
  id: "assign",
@@ -575,9 +575,9 @@ function pe() {
575
575
  onClick: () => G[0] ? $(`fleet/drivers/${G[0].id}`) : $("fleet/drivers")
576
576
  }]
577
577
  }),
578
- O && /* @__PURE__ */ q("div", {
578
+ j && /* @__PURE__ */ q("div", {
579
579
  className: "mb-2",
580
- children: /* @__PURE__ */ q(R, { message: O })
580
+ children: /* @__PURE__ */ q(V, { message: j })
581
581
  }),
582
582
  /* @__PURE__ */ J("div", {
583
583
  className: "grid grid-cols-1 lg:grid-cols-3 gap-6",
@@ -595,46 +595,46 @@ function pe() {
595
595
  children: "Type"
596
596
  }), /* @__PURE__ */ q("p", {
597
597
  className: "font-medium capitalize",
598
- children: p.type
598
+ children: g.type
599
599
  })] }),
600
600
  /* @__PURE__ */ J("div", { children: [/* @__PURE__ */ q("p", {
601
601
  className: "text-sm text-text-secondary",
602
602
  children: "Make"
603
603
  }), /* @__PURE__ */ q("p", {
604
604
  className: "font-medium",
605
- children: p.make || "—"
605
+ children: g.make || "—"
606
606
  })] }),
607
607
  /* @__PURE__ */ J("div", { children: [/* @__PURE__ */ q("p", {
608
608
  className: "text-sm text-text-secondary",
609
609
  children: "Model"
610
610
  }), /* @__PURE__ */ q("p", {
611
611
  className: "font-medium",
612
- children: p.model || "—"
612
+ children: g.model || "—"
613
613
  })] }),
614
614
  /* @__PURE__ */ J("div", { children: [/* @__PURE__ */ q("p", {
615
615
  className: "text-sm text-text-secondary",
616
616
  children: "Year"
617
617
  }), /* @__PURE__ */ q("p", {
618
618
  className: "font-medium",
619
- children: p.year ?? "—"
619
+ children: g.year ?? "—"
620
620
  })] }),
621
621
  /* @__PURE__ */ J("div", { children: [/* @__PURE__ */ q("p", {
622
622
  className: "text-sm text-text-secondary",
623
623
  children: "License Plate"
624
624
  }), /* @__PURE__ */ q("p", {
625
625
  className: "font-medium",
626
- children: p.licensePlate || "—"
626
+ children: g.licensePlate || "—"
627
627
  })] }),
628
628
  /* @__PURE__ */ J("div", { children: [/* @__PURE__ */ q("p", {
629
629
  className: "text-sm text-text-secondary",
630
630
  children: "Ownership"
631
631
  }), /* @__PURE__ */ q("p", {
632
632
  className: "font-medium capitalize",
633
- children: p.ownershipType || "—"
633
+ children: g.ownershipType || "—"
634
634
  })] })
635
635
  ]
636
636
  })] }),
637
- /* @__PURE__ */ J(y, { children: [/* @__PURE__ */ q(x, { children: /* @__PURE__ */ q(S, { children: "Capacity" }) }), /* @__PURE__ */ q(b, { children: /* @__PURE__ */ J("div", {
637
+ /* @__PURE__ */ J(S, { children: [/* @__PURE__ */ q(w, { children: /* @__PURE__ */ q(T, { children: "Capacity" }) }), /* @__PURE__ */ q(C, { children: /* @__PURE__ */ J("div", {
638
638
  className: "grid grid-cols-1 sm:grid-cols-3 gap-6",
639
639
  children: [
640
640
  /* @__PURE__ */ J("div", { children: [/* @__PURE__ */ q("p", {
@@ -642,49 +642,49 @@ function pe() {
642
642
  children: "Weight"
643
643
  }), /* @__PURE__ */ q("p", {
644
644
  className: "text-2xl font-bold",
645
- children: p.capacity.weight === void 0 ? "—" : `${p.capacity.weight} kg`
645
+ children: g.capacity.weight === void 0 ? "—" : p(g.capacity.weight)
646
646
  })] }),
647
647
  /* @__PURE__ */ J("div", { children: [/* @__PURE__ */ q("p", {
648
648
  className: "text-sm text-text-secondary",
649
649
  children: "Volume"
650
650
  }), /* @__PURE__ */ q("p", {
651
651
  className: "text-2xl font-bold",
652
- children: p.capacity.volume === void 0 ? "—" : `${p.capacity.volume} m³`
652
+ children: g.capacity.volume === void 0 ? "—" : `${g.capacity.volume} m³`
653
653
  })] }),
654
- p.capacity.pallets && /* @__PURE__ */ J("div", { children: [/* @__PURE__ */ q("p", {
654
+ g.capacity.pallets && /* @__PURE__ */ J("div", { children: [/* @__PURE__ */ q("p", {
655
655
  className: "text-sm text-text-secondary",
656
656
  children: "Pallets"
657
657
  }), /* @__PURE__ */ q("p", {
658
658
  className: "text-2xl font-bold",
659
- children: p.capacity.pallets
659
+ children: g.capacity.pallets
660
660
  })] })
661
661
  ]
662
662
  }) })] }),
663
- /* @__PURE__ */ q(H, {
663
+ /* @__PURE__ */ q(U, {
664
664
  entityType: "vehicle",
665
- entityId: p.id
665
+ entityId: g.id
666
666
  })
667
667
  ]
668
668
  }), /* @__PURE__ */ J("div", {
669
669
  className: "space-y-6",
670
670
  children: [
671
- /* @__PURE__ */ J(y, { children: [/* @__PURE__ */ q(x, { children: /* @__PURE__ */ J(S, {
671
+ /* @__PURE__ */ J(S, { children: [/* @__PURE__ */ q(w, { children: /* @__PURE__ */ J(T, {
672
672
  className: "flex items-center gap-2",
673
673
  children: [/* @__PURE__ */ q(t, { size: 18 }), " Fuel & Mileage"]
674
- }) }), /* @__PURE__ */ J(b, {
674
+ }) }), /* @__PURE__ */ J(C, {
675
675
  className: "space-y-4",
676
676
  children: [
677
- p.fuelLevel !== void 0 && /* @__PURE__ */ J("div", { children: [/* @__PURE__ */ J("div", {
677
+ g.fuelLevel !== void 0 && /* @__PURE__ */ J("div", { children: [/* @__PURE__ */ J("div", {
678
678
  className: "flex justify-between text-sm mb-2",
679
- children: [/* @__PURE__ */ q("span", { children: "Fuel Level" }), /* @__PURE__ */ J("span", { children: [p.fuelLevel, "%"] })]
680
- }), /* @__PURE__ */ q(T, { value: p.fuelLevel })] }),
681
- p.mileage !== void 0 && /* @__PURE__ */ J("div", { children: [/* @__PURE__ */ q("p", {
679
+ children: [/* @__PURE__ */ q("span", { children: "Fuel Level" }), /* @__PURE__ */ J("span", { children: [g.fuelLevel, "%"] })]
680
+ }), /* @__PURE__ */ q(O, { value: g.fuelLevel })] }),
681
+ g.mileage !== void 0 && /* @__PURE__ */ J("div", { children: [/* @__PURE__ */ q("p", {
682
682
  className: "text-sm text-text-secondary",
683
683
  children: "Total Mileage"
684
684
  }), /* @__PURE__ */ J("p", {
685
685
  className: "text-2xl font-bold",
686
686
  children: [
687
- p.mileage.toLocaleString(),
687
+ g.mileage.toLocaleString(),
688
688
  " ",
689
689
  /* @__PURE__ */ q("span", {
690
690
  className: "text-sm font-normal",
@@ -692,28 +692,28 @@ function pe() {
692
692
  })
693
693
  ]
694
694
  })] }),
695
- (p.fuelType || p.fuelEfficiencyLPer100Km !== void 0) && /* @__PURE__ */ J("div", {
695
+ (g.fuelType || g.fuelEfficiencyLPer100Km !== void 0) && /* @__PURE__ */ J("div", {
696
696
  className: "grid grid-cols-2 gap-4",
697
- children: [p.fuelType && /* @__PURE__ */ J("div", { children: [/* @__PURE__ */ q("p", {
697
+ children: [g.fuelType && /* @__PURE__ */ J("div", { children: [/* @__PURE__ */ q("p", {
698
698
  className: "text-sm text-text-secondary",
699
699
  children: "Fuel Type"
700
700
  }), /* @__PURE__ */ q("p", {
701
701
  className: "font-medium",
702
- children: p.fuelType
703
- })] }), p.fuelEfficiencyLPer100Km !== void 0 && /* @__PURE__ */ J("div", { children: [/* @__PURE__ */ q("p", {
702
+ children: g.fuelType
703
+ })] }), g.fuelEfficiencyLPer100Km !== void 0 && /* @__PURE__ */ J("div", { children: [/* @__PURE__ */ q("p", {
704
704
  className: "text-sm text-text-secondary",
705
705
  children: "Efficiency"
706
706
  }), /* @__PURE__ */ J("p", {
707
707
  className: "font-medium",
708
- children: [p.fuelEfficiencyLPer100Km, " L/100km"]
708
+ children: [g.fuelEfficiencyLPer100Km, " L/100km"]
709
709
  })] })]
710
710
  })
711
711
  ]
712
712
  })] }),
713
- /* @__PURE__ */ J(y, { children: [/* @__PURE__ */ q(x, { children: /* @__PURE__ */ J(S, {
713
+ /* @__PURE__ */ J(S, { children: [/* @__PURE__ */ q(w, { children: /* @__PURE__ */ J(T, {
714
714
  className: "flex items-center gap-2",
715
715
  children: [/* @__PURE__ */ q(l, { size: 18 }), " Assigned Driver"]
716
- }) }), /* @__PURE__ */ q(b, {
716
+ }) }), /* @__PURE__ */ q(C, {
717
717
  className: "space-y-4",
718
718
  children: K ? /* @__PURE__ */ q("p", {
719
719
  className: "text-sm text-text-secondary",
@@ -726,7 +726,7 @@ function pe() {
726
726
  children: [/* @__PURE__ */ q("p", {
727
727
  className: "text-sm text-text-secondary",
728
728
  children: "No driver is assigned to this vehicle yet."
729
- }), /* @__PURE__ */ q(v, {
729
+ }), /* @__PURE__ */ q(x, {
730
730
  variant: "outline",
731
731
  size: "sm",
732
732
  onClick: () => $("fleet/drivers"),
@@ -740,7 +740,7 @@ function pe() {
740
740
  onKeyDown: (t) => {
741
741
  (t.key === "Enter" || t.key === " ") && (t.preventDefault(), $(`fleet/drivers/${e.id}`));
742
742
  },
743
- children: [/* @__PURE__ */ q(g, { children: /* @__PURE__ */ q(_, { children: V(e.fullName) }) }), /* @__PURE__ */ J("div", {
743
+ children: [/* @__PURE__ */ q(y, { children: /* @__PURE__ */ q(b, { children: m(e.fullName) }) }), /* @__PURE__ */ J("div", {
744
744
  className: "min-w-0 space-y-1",
745
745
  children: [
746
746
  /* @__PURE__ */ q("p", {
@@ -751,7 +751,7 @@ function pe() {
751
751
  className: "text-xs text-text-secondary",
752
752
  children: e.employeeId
753
753
  }),
754
- /* @__PURE__ */ q(F, {
754
+ /* @__PURE__ */ q(R, {
755
755
  status: e.status,
756
756
  type: "driver",
757
757
  size: "sm"
@@ -776,28 +776,28 @@ function pe() {
776
776
  })]
777
777
  }, e.id))
778
778
  })] }),
779
- /* @__PURE__ */ q(ee, {
780
- vehicle: p,
781
- t: P,
779
+ /* @__PURE__ */ q(te, {
780
+ vehicle: g,
781
+ t: L,
782
782
  onRecord: async (e) => {
783
- await D(p.id, e), k(P("movethewheels.vehicles.service.saved", "Service recorded.")), E();
783
+ await A(g.id, e), M(L("movethewheels.vehicles.service.saved", "Service recorded.")), k();
784
784
  }
785
785
  }),
786
- p.currentLocation && /* @__PURE__ */ J(y, { children: [/* @__PURE__ */ q(x, { children: /* @__PURE__ */ J(S, {
786
+ g.currentLocation && /* @__PURE__ */ J(S, { children: [/* @__PURE__ */ q(w, { children: /* @__PURE__ */ J(T, {
787
787
  className: "flex items-center gap-2",
788
788
  children: [/* @__PURE__ */ q(r, { size: 18 }), " Current Location"]
789
- }) }), /* @__PURE__ */ J(b, { children: [/* @__PURE__ */ q("p", {
789
+ }) }), /* @__PURE__ */ J(C, { children: [/* @__PURE__ */ q("p", {
790
790
  className: "text-sm",
791
- children: p.currentLocation.address || "Location updating..."
791
+ children: g.currentLocation.address || "Location updating..."
792
792
  }), /* @__PURE__ */ q("p", {
793
793
  className: "text-xs text-text-secondary mt-1",
794
- children: p.currentLocation.timestamp ? `Updated ${B(p.currentLocation.timestamp, "relative")}` : "Update time not recorded"
794
+ children: g.currentLocation.timestamp ? `Updated ${f(g.currentLocation.timestamp, "relative")}` : "Update time not recorded"
795
795
  })] })] })
796
796
  ]
797
797
  })]
798
798
  })
799
799
  ]
800
- }) : /* @__PURE__ */ q(fe, {});
800
+ }) : /* @__PURE__ */ q(pe, {});
801
801
  }
802
802
  //#endregion
803
- export { pe as default };
803
+ export { me as default };