@burdenoff/microfe-labsofscience 2026.626.2 → 2026.628.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.
Files changed (172) hide show
  1. package/dist/index.js +4 -4
  2. package/dist/labsofscience/LabsOfScienceRoot.js +68 -124
  3. package/dist/labsofscience/LabsOfScienceRoot.js.map +1 -1
  4. package/dist/labsofscience/LabsOfScienceRoutes.js +61 -185
  5. package/dist/labsofscience/LabsOfScienceRoutes.js.map +1 -1
  6. package/dist/labsofscience/components/QueryStates.js +40 -0
  7. package/dist/labsofscience/components/QueryStates.js.map +1 -0
  8. package/dist/labsofscience/components/StatusBadge.js +40 -23
  9. package/dist/labsofscience/components/StatusBadge.js.map +1 -1
  10. package/dist/labsofscience/context/LabsOfScienceContext.js +22 -30
  11. package/dist/labsofscience/context/LabsOfScienceContext.js.map +1 -1
  12. package/dist/labsofscience/hooks/useLabsOfScienceApi.js +500 -172
  13. package/dist/labsofscience/hooks/useLabsOfScienceApi.js.map +1 -1
  14. package/dist/labsofscience/pages/OverviewPage.js +195 -0
  15. package/dist/labsofscience/pages/OverviewPage.js.map +1 -0
  16. package/dist/labsofscience/pages/datasets/DatasetDetailPage.js +162 -0
  17. package/dist/labsofscience/pages/datasets/DatasetDetailPage.js.map +1 -0
  18. package/dist/labsofscience/pages/datasets/DatasetFormDialog.js +137 -0
  19. package/dist/labsofscience/pages/datasets/DatasetFormDialog.js.map +1 -0
  20. package/dist/labsofscience/pages/datasets/DatasetsListPage.js +155 -0
  21. package/dist/labsofscience/pages/datasets/DatasetsListPage.js.map +1 -0
  22. package/dist/labsofscience/pages/experiments/ExperimentDetailPage.js +220 -0
  23. package/dist/labsofscience/pages/experiments/ExperimentDetailPage.js.map +1 -0
  24. package/dist/labsofscience/pages/experiments/ExperimentFormDialog.js +170 -0
  25. package/dist/labsofscience/pages/experiments/ExperimentFormDialog.js.map +1 -0
  26. package/dist/labsofscience/pages/experiments/ExperimentsListPage.js +134 -0
  27. package/dist/labsofscience/pages/experiments/ExperimentsListPage.js.map +1 -0
  28. package/dist/labsofscience/pages/experiments/RunDialogs.js +180 -0
  29. package/dist/labsofscience/pages/experiments/RunDialogs.js.map +1 -0
  30. package/dist/labsofscience/pages/instruments/InstrumentDetailPage.js +130 -0
  31. package/dist/labsofscience/pages/instruments/InstrumentDetailPage.js.map +1 -0
  32. package/dist/labsofscience/pages/instruments/InstrumentFormDialog.js +132 -0
  33. package/dist/labsofscience/pages/instruments/InstrumentFormDialog.js.map +1 -0
  34. package/dist/labsofscience/pages/instruments/InstrumentsListPage.js +126 -0
  35. package/dist/labsofscience/pages/instruments/InstrumentsListPage.js.map +1 -0
  36. package/dist/labsofscience/pages/inventory/AdjustInventoryDialog.js +89 -0
  37. package/dist/labsofscience/pages/inventory/AdjustInventoryDialog.js.map +1 -0
  38. package/dist/labsofscience/pages/inventory/InventoryDetailPage.js +138 -0
  39. package/dist/labsofscience/pages/inventory/InventoryDetailPage.js.map +1 -0
  40. package/dist/labsofscience/pages/inventory/InventoryFormDialog.js +211 -0
  41. package/dist/labsofscience/pages/inventory/InventoryFormDialog.js.map +1 -0
  42. package/dist/labsofscience/pages/inventory/InventoryListPage.js +178 -0
  43. package/dist/labsofscience/pages/inventory/InventoryListPage.js.map +1 -0
  44. package/dist/labsofscience/pages/notebook/NotebookEntryFormDialog.js +118 -0
  45. package/dist/labsofscience/pages/notebook/NotebookEntryFormDialog.js.map +1 -0
  46. package/dist/labsofscience/pages/notebook/NotebookListPage.js +144 -0
  47. package/dist/labsofscience/pages/notebook/NotebookListPage.js.map +1 -0
  48. package/dist/labsofscience/pages/pipelines/PipelineFormDialog.js +146 -0
  49. package/dist/labsofscience/pages/pipelines/PipelineFormDialog.js.map +1 -0
  50. package/dist/labsofscience/pages/pipelines/PipelinesPage.js +212 -0
  51. package/dist/labsofscience/pages/pipelines/PipelinesPage.js.map +1 -0
  52. package/dist/labsofscience/pages/pipelines/RunPipelineDialog.js +109 -0
  53. package/dist/labsofscience/pages/pipelines/RunPipelineDialog.js.map +1 -0
  54. package/dist/labsofscience/pages/projects/ProjectDetailPage.js +174 -0
  55. package/dist/labsofscience/pages/projects/ProjectDetailPage.js.map +1 -0
  56. package/dist/labsofscience/pages/projects/ProjectFormDialog.js +169 -0
  57. package/dist/labsofscience/pages/projects/ProjectFormDialog.js.map +1 -0
  58. package/dist/labsofscience/pages/projects/ProjectsListPage.js +141 -0
  59. package/dist/labsofscience/pages/projects/ProjectsListPage.js.map +1 -0
  60. package/dist/labsofscience/pages/protocols/ProtocolDetailPage.js +133 -0
  61. package/dist/labsofscience/pages/protocols/ProtocolDetailPage.js.map +1 -0
  62. package/dist/labsofscience/pages/protocols/ProtocolFormDialog.js +151 -0
  63. package/dist/labsofscience/pages/protocols/ProtocolFormDialog.js.map +1 -0
  64. package/dist/labsofscience/pages/protocols/ProtocolsListPage.js +140 -0
  65. package/dist/labsofscience/pages/protocols/ProtocolsListPage.js.map +1 -0
  66. package/dist/labsofscience/pages/shared/DetailComponents.js +64 -0
  67. package/dist/labsofscience/pages/shared/DetailComponents.js.map +1 -0
  68. package/dist/labsofscience/pages/shared/tags.js +16 -0
  69. package/dist/labsofscience/pages/shared/tags.js.map +1 -0
  70. package/dist/labsofscience/store/labsofscienceStore.js +6 -11
  71. package/dist/labsofscience/store/labsofscienceStore.js.map +1 -1
  72. package/dist/labsofscience/utils/formatters.js +28 -13
  73. package/dist/labsofscience/utils/formatters.js.map +1 -1
  74. package/package.json +1 -1
  75. package/dist/labsofscience/components/InvestmentCard.js +0 -98
  76. package/dist/labsofscience/components/InvestmentCard.js.map +0 -1
  77. package/dist/labsofscience/components/RatingDisplay.js +0 -35
  78. package/dist/labsofscience/components/RatingDisplay.js.map +0 -1
  79. package/dist/labsofscience/mocks/data.js +0 -1517
  80. package/dist/labsofscience/mocks/data.js.map +0 -1
  81. package/dist/labsofscience/mocks/users.js +0 -34
  82. package/dist/labsofscience/mocks/users.js.map +0 -1
  83. package/dist/labsofscience/pages/HomePage.js +0 -940
  84. package/dist/labsofscience/pages/HomePage.js.map +0 -1
  85. package/dist/labsofscience/pages/admin/AdminAnalyticsPage.js +0 -651
  86. package/dist/labsofscience/pages/admin/AdminAnalyticsPage.js.map +0 -1
  87. package/dist/labsofscience/pages/admin/AdminDashboard.js +0 -672
  88. package/dist/labsofscience/pages/admin/AdminDashboard.js.map +0 -1
  89. package/dist/labsofscience/pages/admin/AdminFinancialPage.js +0 -427
  90. package/dist/labsofscience/pages/admin/AdminFinancialPage.js.map +0 -1
  91. package/dist/labsofscience/pages/admin/AdminOrdersPage.js +0 -665
  92. package/dist/labsofscience/pages/admin/AdminOrdersPage.js.map +0 -1
  93. package/dist/labsofscience/pages/admin/AdminProfilePage.js +0 -261
  94. package/dist/labsofscience/pages/admin/AdminProfilePage.js.map +0 -1
  95. package/dist/labsofscience/pages/admin/AdminSettingsPage.js +0 -651
  96. package/dist/labsofscience/pages/admin/AdminSettingsPage.js.map +0 -1
  97. package/dist/labsofscience/pages/admin/CartManagementPage.js +0 -874
  98. package/dist/labsofscience/pages/admin/CartManagementPage.js.map +0 -1
  99. package/dist/labsofscience/pages/admin/UserManagementPage.js +0 -898
  100. package/dist/labsofscience/pages/admin/UserManagementPage.js.map +0 -1
  101. package/dist/labsofscience/pages/cart-owner/AnalyticsDashboard.js +0 -839
  102. package/dist/labsofscience/pages/cart-owner/AnalyticsDashboard.js.map +0 -1
  103. package/dist/labsofscience/pages/cart-owner/BusinessSettingsPage.js +0 -705
  104. package/dist/labsofscience/pages/cart-owner/BusinessSettingsPage.js.map +0 -1
  105. package/dist/labsofscience/pages/cart-owner/CartOwnerDashboard.js +0 -791
  106. package/dist/labsofscience/pages/cart-owner/CartOwnerDashboard.js.map +0 -1
  107. package/dist/labsofscience/pages/cart-owner/CartOwnerProfilePage.js +0 -891
  108. package/dist/labsofscience/pages/cart-owner/CartOwnerProfilePage.js.map +0 -1
  109. package/dist/labsofscience/pages/cart-owner/CartServiceConfigPage.js +0 -636
  110. package/dist/labsofscience/pages/cart-owner/CartServiceConfigPage.js.map +0 -1
  111. package/dist/labsofscience/pages/cart-owner/InventoryManagementPage.js +0 -911
  112. package/dist/labsofscience/pages/cart-owner/InventoryManagementPage.js.map +0 -1
  113. package/dist/labsofscience/pages/cart-owner/OrderManagementPage.js +0 -879
  114. package/dist/labsofscience/pages/cart-owner/OrderManagementPage.js.map +0 -1
  115. package/dist/labsofscience/pages/cart-owner/StaffManagementPage.js +0 -839
  116. package/dist/labsofscience/pages/cart-owner/StaffManagementPage.js.map +0 -1
  117. package/dist/labsofscience/pages/common/HelpSupportPage.js +0 -1324
  118. package/dist/labsofscience/pages/common/HelpSupportPage.js.map +0 -1
  119. package/dist/labsofscience/pages/common/NotificationCenterPage.js +0 -672
  120. package/dist/labsofscience/pages/common/NotificationCenterPage.js.map +0 -1
  121. package/dist/labsofscience/pages/common/SettingsPage.js +0 -973
  122. package/dist/labsofscience/pages/common/SettingsPage.js.map +0 -1
  123. package/dist/labsofscience/pages/customer/BookingDetailsPage.js +0 -637
  124. package/dist/labsofscience/pages/customer/BookingDetailsPage.js.map +0 -1
  125. package/dist/labsofscience/pages/customer/CartDetailPage.js +0 -653
  126. package/dist/labsofscience/pages/customer/CartDetailPage.js.map +0 -1
  127. package/dist/labsofscience/pages/customer/CartDiscoveryPage.js +0 -559
  128. package/dist/labsofscience/pages/customer/CartDiscoveryPage.js.map +0 -1
  129. package/dist/labsofscience/pages/customer/CheckoutPage.js +0 -530
  130. package/dist/labsofscience/pages/customer/CheckoutPage.js.map +0 -1
  131. package/dist/labsofscience/pages/customer/CustomerDashboard.js +0 -531
  132. package/dist/labsofscience/pages/customer/CustomerDashboard.js.map +0 -1
  133. package/dist/labsofscience/pages/customer/CustomerProfilePage.js +0 -658
  134. package/dist/labsofscience/pages/customer/CustomerProfilePage.js.map +0 -1
  135. package/dist/labsofscience/pages/customer/DirectServiceBookingPage.js +0 -633
  136. package/dist/labsofscience/pages/customer/DirectServiceBookingPage.js.map +0 -1
  137. package/dist/labsofscience/pages/customer/FavoritesPage.js +0 -484
  138. package/dist/labsofscience/pages/customer/FavoritesPage.js.map +0 -1
  139. package/dist/labsofscience/pages/customer/OrderHistoryPage.js +0 -445
  140. package/dist/labsofscience/pages/customer/OrderHistoryPage.js.map +0 -1
  141. package/dist/labsofscience/pages/customer/OrderTrackingPage.js +0 -425
  142. package/dist/labsofscience/pages/customer/OrderTrackingPage.js.map +0 -1
  143. package/dist/labsofscience/pages/customer/PaymentMethodsPage.js +0 -495
  144. package/dist/labsofscience/pages/customer/PaymentMethodsPage.js.map +0 -1
  145. package/dist/labsofscience/pages/customer/ReviewsPage.js +0 -613
  146. package/dist/labsofscience/pages/customer/ReviewsPage.js.map +0 -1
  147. package/dist/labsofscience/pages/customer/SavedAddressesPage.js +0 -450
  148. package/dist/labsofscience/pages/customer/SavedAddressesPage.js.map +0 -1
  149. package/dist/labsofscience/pages/investor/InvestmentDetailsPage.js +0 -881
  150. package/dist/labsofscience/pages/investor/InvestmentDetailsPage.js.map +0 -1
  151. package/dist/labsofscience/pages/investor/InvestmentOpportunitiesPage.js +0 -946
  152. package/dist/labsofscience/pages/investor/InvestmentOpportunitiesPage.js.map +0 -1
  153. package/dist/labsofscience/pages/investor/InvestorAnalyticsPage.js +0 -687
  154. package/dist/labsofscience/pages/investor/InvestorAnalyticsPage.js.map +0 -1
  155. package/dist/labsofscience/pages/investor/InvestorDashboard.js +0 -455
  156. package/dist/labsofscience/pages/investor/InvestorDashboard.js.map +0 -1
  157. package/dist/labsofscience/pages/investor/InvestorInvestmentsPage.js +0 -406
  158. package/dist/labsofscience/pages/investor/InvestorInvestmentsPage.js.map +0 -1
  159. package/dist/labsofscience/pages/investor/InvestorPortfolioPage.js +0 -575
  160. package/dist/labsofscience/pages/investor/InvestorPortfolioPage.js.map +0 -1
  161. package/dist/labsofscience/pages/investor/InvestorProfilePage.js +0 -1070
  162. package/dist/labsofscience/pages/investor/InvestorProfilePage.js.map +0 -1
  163. package/dist/labsofscience/pages/worker/TaskDetailsPage.js +0 -537
  164. package/dist/labsofscience/pages/worker/TaskDetailsPage.js.map +0 -1
  165. package/dist/labsofscience/pages/worker/WorkerDashboard.js +0 -665
  166. package/dist/labsofscience/pages/worker/WorkerDashboard.js.map +0 -1
  167. package/dist/labsofscience/pages/worker/WorkerOrdersPage.js +0 -681
  168. package/dist/labsofscience/pages/worker/WorkerOrdersPage.js.map +0 -1
  169. package/dist/labsofscience/pages/worker/WorkerProfilePage.js +0 -692
  170. package/dist/labsofscience/pages/worker/WorkerProfilePage.js.map +0 -1
  171. package/dist/labsofscience/pages/worker/WorkerSchedulePage.js +0 -588
  172. package/dist/labsofscience/pages/worker/WorkerSchedulePage.js.map +0 -1
@@ -1,633 +0,0 @@
1
- import { useLabsOfScience as e } from "../../context/LabsOfScienceContext.js";
2
- import { cn as t } from "../../utils/cn.js";
3
- import { PageLayout as n } from "../../components/PageLayout.js";
4
- import { EmptyState as r } from "../../components/EmptyState.js";
5
- import { formatCurrency as i } from "../../utils/formatters.js";
6
- import { getCartById as a } from "../../mocks/data.js";
7
- import { useMemo as o, useState as s } from "react";
8
- import { AlertCircle as c, ArrowLeft as l, ArrowRight as u, Calendar as d, CheckCircle2 as f, Clock as p, CreditCard as m, Home as h, Loader2 as g, MapPin as _, Navigation as v, Phone as y, Smartphone as b, Wallet as x } from "lucide-react";
9
- import { useParams as S } from "react-router-dom";
10
- import { Fragment as C, jsx as w, jsxs as T } from "react/jsx-runtime";
11
- import { EmphasisPanel as E, PagePurpose as D } from "@burdenoff/fe-libs/ui";
12
- //#region src/labsofscience/pages/customer/DirectServiceBookingPage.tsx
13
- var O = [
14
- "location",
15
- "details",
16
- "payment",
17
- "confirmation"
18
- ], k = {
19
- location: "Location",
20
- details: "Details",
21
- payment: "Payment",
22
- confirmation: "Confirmation"
23
- };
24
- function A() {
25
- let e = [], t = new Date((/* @__PURE__ */ new Date()).getTime() + 30 * 6e4);
26
- for (let n = 0; n < 8; n++) {
27
- let r = new Date(t.getTime() + n * 30 * 6e4), i = r.toTimeString().slice(0, 5), a = r.toLocaleTimeString([], {
28
- hour: "2-digit",
29
- minute: "2-digit"
30
- });
31
- e.push({
32
- value: i,
33
- label: a
34
- });
35
- }
36
- return e;
37
- }
38
- function j() {
39
- let { cartId: j } = S(), { navigateTo: M } = e(), N = o(() => j ? a(j) : void 0, [j]), [P, F] = s("location"), [I, L] = s(!1), [R, z] = s({
40
- address: "",
41
- landmark: "",
42
- instructions: "",
43
- phoneNumber: ""
44
- }), [B, V] = s({
45
- preferredTime: "",
46
- specialInstructions: "",
47
- isUrgent: !1
48
- }), [H, U] = s("upi"), [W, G] = s(null);
49
- if (!N) return /* @__PURE__ */ w(n, {
50
- title: "Cart Not Found",
51
- children: /* @__PURE__ */ w(r, {
52
- illustration: "empty-data",
53
- icon: /* @__PURE__ */ w(h, { className: "h-12 w-12" }),
54
- title: "Service not available",
55
- description: "Direct service is not available for this cart.",
56
- action: /* @__PURE__ */ w("button", {
57
- type: "button",
58
- onClick: () => M("/customer/carts"),
59
- className: "rounded-lg bg-foreground px-4 py-2 text-sm font-medium text-background hover:opacity-90 transition-opacity",
60
- children: "Browse Carts"
61
- })
62
- })
63
- });
64
- let K = A(), q = O.indexOf(P), J = () => {
65
- if (!navigator.geolocation) {
66
- alert("Geolocation is not supported by this browser.");
67
- return;
68
- }
69
- navigator.geolocation.getCurrentPosition(() => {
70
- z((e) => ({
71
- ...e,
72
- address: e.address || "Current location detected"
73
- })), alert("Location detected successfully!");
74
- }, () => {
75
- alert("Failed to get your location. Please enter address manually.");
76
- });
77
- }, Y = () => R.address.trim() ? R.phoneNumber.trim() ? !0 : (alert("Please enter your phone number."), !1) : (alert("Please enter your address."), !1), X = () => B.preferredTime ? !0 : (alert("Please select a preferred time slot."), !1), Z = () => {
78
- P === "location" && Y() ? F("details") : P === "details" && X() ? F("payment") : P === "payment" && $();
79
- }, Q = () => {
80
- P === "details" ? F("location") : P === "payment" && F("details");
81
- }, $ = () => {
82
- L(!0), setTimeout(() => {
83
- G({
84
- bookingId: `BK-${Date.now()}`,
85
- transactionId: `TXN-${Date.now()}`,
86
- estimatedArrival: new Date(Date.now() + 30 * 6e4).toISOString()
87
- }), F("confirmation"), L(!1);
88
- }, 1500);
89
- };
90
- return /* @__PURE__ */ T(n, {
91
- title: /* @__PURE__ */ T("div", {
92
- className: "flex items-center gap-3",
93
- children: [/* @__PURE__ */ w("button", {
94
- type: "button",
95
- onClick: () => M(`/customer/carts/${N.id}`),
96
- className: "rounded-md p-1 text-text-secondary hover:bg-accent hover:text-text-primary transition-colors",
97
- children: /* @__PURE__ */ w(l, { className: "h-5 w-5" })
98
- }), /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("span", { children: "Book Direct Service" }), /* @__PURE__ */ w("p", {
99
- className: "text-xs font-normal text-text-secondary",
100
- children: N.name
101
- })] })]
102
- }),
103
- children: [
104
- /* @__PURE__ */ w(D, {
105
- icon: /* @__PURE__ */ w(h, { className: "h-4 w-4" }),
106
- className: "mb-6",
107
- children: "Request a cart to come straight to your door instead of placing a pickup order. Tell us where and when you want the service, pick a payment method and pay a small advance to lock in the slot — you settle the balance when the cart arrives. Just follow the four steps below."
108
- }),
109
- /* @__PURE__ */ w("div", {
110
- className: "flex items-center justify-between mb-6 px-2",
111
- children: O.map((e, n) => {
112
- let r = n < q, i = e === P;
113
- return /* @__PURE__ */ T("div", {
114
- className: "flex items-center",
115
- children: [/* @__PURE__ */ T("div", {
116
- className: "flex flex-col items-center",
117
- children: [/* @__PURE__ */ w("div", {
118
- className: t("flex h-8 w-8 items-center justify-center rounded-full text-xs font-medium", r ? "bg-status-success-bg-subtle text-status-success-text" : i ? "bg-foreground text-background" : "bg-bg-sunken text-text-secondary"),
119
- children: r ? /* @__PURE__ */ w(f, { className: "h-4 w-4" }) : n + 1
120
- }), /* @__PURE__ */ w("span", {
121
- className: t("mt-1 text-[10px]", i ? "font-medium text-text-primary" : "text-text-secondary"),
122
- children: k[e]
123
- })]
124
- }), n < O.length - 1 && /* @__PURE__ */ w("div", { className: t("mx-2 h-0.5 w-8 sm:w-16", r ? "bg-status-success-bg-subtle" : "bg-border") })]
125
- }, e);
126
- })
127
- }),
128
- /* @__PURE__ */ T("div", {
129
- className: "grid grid-cols-1 lg:grid-cols-3 gap-6",
130
- children: [/* @__PURE__ */ T("div", {
131
- className: "lg:col-span-2",
132
- children: [
133
- P === "location" && /* @__PURE__ */ T("div", {
134
- className: "rounded-lg border border-border-seam bg-bg-surface p-5",
135
- children: [
136
- /* @__PURE__ */ T("h2", {
137
- className: "text-base font-semibold text-text-primary mb-1 flex items-center gap-2",
138
- children: [/* @__PURE__ */ w(_, { className: "h-4 w-4" }), "Service Location"]
139
- }),
140
- /* @__PURE__ */ w("p", {
141
- className: "text-xs text-text-secondary mb-5",
142
- children: "Where should the cart come?"
143
- }),
144
- /* @__PURE__ */ T("div", {
145
- className: "space-y-4",
146
- children: [
147
- /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ T("label", {
148
- className: "block text-sm font-medium text-text-primary mb-1.5",
149
- children: ["Your Address ", /* @__PURE__ */ w("span", {
150
- className: "text-status-error-text",
151
- children: "*"
152
- })]
153
- }), /* @__PURE__ */ T("div", {
154
- className: "flex gap-2",
155
- children: [/* @__PURE__ */ w("input", {
156
- type: "text",
157
- placeholder: "Enter your full address",
158
- value: R.address,
159
- onChange: (e) => z((t) => ({
160
- ...t,
161
- address: e.target.value
162
- })),
163
- className: "flex-1 rounded-lg border border-border-seam bg-bg-surface px-3 py-2 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
164
- }), /* @__PURE__ */ T("button", {
165
- type: "button",
166
- onClick: J,
167
- className: "flex items-center gap-1.5 rounded-lg border border-border-seam px-3 py-2 text-xs font-medium text-text-primary hover:bg-accent transition-colors whitespace-nowrap",
168
- children: [/* @__PURE__ */ w(v, { className: "h-3.5 w-3.5" }), "Use Current Location"]
169
- })]
170
- })] }),
171
- /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("label", {
172
- className: "block text-sm font-medium text-text-primary mb-1.5",
173
- children: "Nearby Landmark"
174
- }), /* @__PURE__ */ w("input", {
175
- type: "text",
176
- placeholder: "e.g., Near Metro Station, Opposite Mall",
177
- value: R.landmark,
178
- onChange: (e) => z((t) => ({
179
- ...t,
180
- landmark: e.target.value
181
- })),
182
- className: "w-full rounded-lg border border-border-seam bg-bg-surface px-3 py-2 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
183
- })] }),
184
- /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("label", {
185
- className: "block text-sm font-medium text-text-primary mb-1.5",
186
- children: "Instructions for Cart Owner"
187
- }), /* @__PURE__ */ w("textarea", {
188
- rows: 3,
189
- placeholder: "Any specific instructions to help us find you...",
190
- value: R.instructions,
191
- onChange: (e) => z((t) => ({
192
- ...t,
193
- instructions: e.target.value
194
- })),
195
- className: "w-full rounded-lg border border-border-seam bg-bg-surface px-3 py-2 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)] resize-none"
196
- })] }),
197
- /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ T("label", {
198
- className: "block text-sm font-medium text-text-primary mb-1.5",
199
- children: ["Phone Number ", /* @__PURE__ */ w("span", {
200
- className: "text-status-error-text",
201
- children: "*"
202
- })]
203
- }), /* @__PURE__ */ T("div", {
204
- className: "relative",
205
- children: [/* @__PURE__ */ w(y, { className: "absolute left-3 top-1/2 -translate-y-1/2 h-4 w-4 text-text-secondary" }), /* @__PURE__ */ w("input", {
206
- type: "tel",
207
- placeholder: "Enter your phone number",
208
- value: R.phoneNumber,
209
- onChange: (e) => z((t) => ({
210
- ...t,
211
- phoneNumber: e.target.value
212
- })),
213
- className: "w-full rounded-lg border border-border-seam bg-bg-surface py-2 pl-9 pr-3 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
214
- })]
215
- })] })
216
- ]
217
- })
218
- ]
219
- }),
220
- P === "details" && /* @__PURE__ */ T("div", {
221
- className: "rounded-lg border border-border-seam bg-bg-surface p-5",
222
- children: [
223
- /* @__PURE__ */ T("h2", {
224
- className: "text-base font-semibold text-text-primary mb-1 flex items-center gap-2",
225
- children: [/* @__PURE__ */ w(d, { className: "h-4 w-4" }), "Booking Details"]
226
- }),
227
- /* @__PURE__ */ w("p", {
228
- className: "text-xs text-text-secondary mb-5",
229
- children: "Choose your preferred timing"
230
- }),
231
- /* @__PURE__ */ T("div", {
232
- className: "space-y-4",
233
- children: [
234
- /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ T("label", {
235
- className: "block text-sm font-medium text-text-primary mb-1.5",
236
- children: ["Preferred Time Slot ", /* @__PURE__ */ w("span", {
237
- className: "text-status-error-text",
238
- children: "*"
239
- })]
240
- }), /* @__PURE__ */ w("div", {
241
- className: "grid grid-cols-4 gap-2",
242
- children: K.map((e) => /* @__PURE__ */ w("button", {
243
- type: "button",
244
- onClick: () => V((t) => ({
245
- ...t,
246
- preferredTime: e.value
247
- })),
248
- className: t("rounded-lg border py-2 px-2 text-xs font-medium transition-colors", B.preferredTime === e.value ? "border-foreground bg-accent text-text-primary" : "border-border-seam text-text-secondary hover:bg-accent hover:text-text-primary"),
249
- children: e.label
250
- }, e.value))
251
- })] }),
252
- /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("label", {
253
- className: "block text-sm font-medium text-text-primary mb-1.5",
254
- children: "Special Instructions"
255
- }), /* @__PURE__ */ w("textarea", {
256
- rows: 3,
257
- placeholder: "Any special requests or dietary preferences...",
258
- value: B.specialInstructions,
259
- onChange: (e) => V((t) => ({
260
- ...t,
261
- specialInstructions: e.target.value
262
- })),
263
- className: "w-full rounded-lg border border-border-seam bg-bg-surface px-3 py-2 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)] resize-none"
264
- })] }),
265
- /* @__PURE__ */ T("label", {
266
- className: "flex items-center gap-2 cursor-pointer",
267
- children: [/* @__PURE__ */ w("input", {
268
- type: "checkbox",
269
- checked: B.isUrgent,
270
- onChange: (e) => V((t) => ({
271
- ...t,
272
- isUrgent: e.target.checked
273
- })),
274
- className: "h-4 w-4 rounded border-border-seam"
275
- }), /* @__PURE__ */ w("span", {
276
- className: "text-sm text-text-secondary",
277
- children: "This is urgent (additional charges may apply)"
278
- })]
279
- })
280
- ]
281
- })
282
- ]
283
- }),
284
- P === "payment" && /* @__PURE__ */ T("div", {
285
- className: "rounded-lg border border-border-seam bg-bg-surface p-5",
286
- children: [
287
- /* @__PURE__ */ T("h2", {
288
- className: "text-base font-semibold text-text-primary mb-1 flex items-center gap-2",
289
- children: [/* @__PURE__ */ w(m, { className: "h-4 w-4" }), "Advance Payment"]
290
- }),
291
- /* @__PURE__ */ w("p", {
292
- className: "text-xs text-text-secondary mb-5",
293
- children: "Select your payment method"
294
- }),
295
- /* @__PURE__ */ T("div", {
296
- className: "space-y-4",
297
- children: [
298
- /* @__PURE__ */ T("div", {
299
- className: "flex items-start gap-2 rounded-lg border border-status-info-border bg-status-info-bg-subtle p-3",
300
- children: [/* @__PURE__ */ w(c, { className: "h-4 w-4 text-status-info-text shrink-0 mt-0.5" }), /* @__PURE__ */ T("p", {
301
- className: "text-xs text-status-info-text",
302
- children: [
303
- "You need to pay ",
304
- i(100, { minimumFractionDigits: 0 }),
305
- " ",
306
- "in advance to confirm your booking. Pay the remaining when the cart arrives."
307
- ]
308
- })]
309
- }),
310
- /* @__PURE__ */ w("div", {
311
- className: "grid grid-cols-1 sm:grid-cols-3 gap-3",
312
- children: [
313
- {
314
- value: "upi",
315
- label: "UPI",
316
- sub: "Instant payment",
317
- Icon: b
318
- },
319
- {
320
- value: "card",
321
- label: "Card",
322
- sub: "Secure payment",
323
- Icon: m
324
- },
325
- {
326
- value: "wallet",
327
- label: "Wallet",
328
- sub: "Quick payment",
329
- Icon: x
330
- }
331
- ].map(({ value: e, label: n, sub: r, Icon: i }) => /* @__PURE__ */ T("button", {
332
- type: "button",
333
- onClick: () => U(e),
334
- className: t("rounded-lg border p-3 text-center transition-colors", H === e ? "border-foreground bg-accent" : "border-border-seam hover:bg-accent"),
335
- children: [
336
- /* @__PURE__ */ w(i, { className: "mx-auto h-5 w-5 text-text-secondary mb-1" }),
337
- /* @__PURE__ */ w("p", {
338
- className: "text-sm font-medium text-text-primary",
339
- children: n
340
- }),
341
- /* @__PURE__ */ w("p", {
342
- className: "text-[10px] text-text-secondary",
343
- children: r
344
- })
345
- ]
346
- }, e))
347
- }),
348
- /* @__PURE__ */ T("div", {
349
- className: "rounded-lg bg-bg-sunken p-4",
350
- children: [/* @__PURE__ */ w("h3", {
351
- className: "text-sm font-medium text-text-primary mb-2",
352
- children: "Payment Summary"
353
- }), /* @__PURE__ */ T("div", {
354
- className: "space-y-2 text-sm",
355
- children: [
356
- /* @__PURE__ */ T("div", {
357
- className: "flex justify-between",
358
- children: [/* @__PURE__ */ w("span", {
359
- className: "text-text-secondary",
360
- children: "Advance Payment:"
361
- }), /* @__PURE__ */ w("span", {
362
- className: "text-text-primary",
363
- children: i(100, { minimumFractionDigits: 0 })
364
- })]
365
- }),
366
- /* @__PURE__ */ T("div", {
367
- className: "flex justify-between",
368
- children: [/* @__PURE__ */ w("span", {
369
- className: "text-text-secondary",
370
- children: "Service Fee:"
371
- }), /* @__PURE__ */ w("span", {
372
- className: "text-text-primary",
373
- children: i(50, { minimumFractionDigits: 0 })
374
- })]
375
- }),
376
- /* @__PURE__ */ T("div", {
377
- className: "flex justify-between text-text-secondary",
378
- children: [/* @__PURE__ */ w("span", { children: "Balance Payment (at arrival):" }), /* @__PURE__ */ w("span", { children: i(50, { minimumFractionDigits: 0 }) })]
379
- }),
380
- /* @__PURE__ */ T("div", {
381
- className: "flex justify-between border-t border-border-seam pt-2 font-semibold",
382
- children: [/* @__PURE__ */ w("span", {
383
- className: "text-text-primary",
384
- children: "Total Amount:"
385
- }), /* @__PURE__ */ w("span", {
386
- className: "text-text-primary",
387
- children: i(150, { minimumFractionDigits: 0 })
388
- })]
389
- })
390
- ]
391
- })]
392
- })
393
- ]
394
- })
395
- ]
396
- }),
397
- P === "confirmation" && W && /* @__PURE__ */ T("div", {
398
- className: "rounded-lg border border-border-seam bg-bg-surface p-5",
399
- children: [
400
- /* @__PURE__ */ T("div", {
401
- className: "text-center mb-6",
402
- children: [
403
- /* @__PURE__ */ w("div", {
404
- className: "mx-auto mb-3 flex h-14 w-14 items-center justify-center rounded-full bg-status-success-bg-subtle",
405
- children: /* @__PURE__ */ w(f, { className: "h-7 w-7 text-status-success-text" })
406
- }),
407
- /* @__PURE__ */ w("h2", {
408
- className: "text-lg font-semibold text-text-primary mb-1",
409
- children: "Booking Confirmed!"
410
- }),
411
- /* @__PURE__ */ w("p", {
412
- className: "text-sm text-text-secondary",
413
- children: "Your direct service booking has been confirmed and payment processed."
414
- })
415
- ]
416
- }),
417
- /* @__PURE__ */ T("div", {
418
- className: "rounded-lg bg-bg-sunken p-4 mb-4",
419
- children: [/* @__PURE__ */ w("h3", {
420
- className: "text-sm font-medium text-text-primary mb-3",
421
- children: "Booking Details"
422
- }), /* @__PURE__ */ T("div", {
423
- className: "grid grid-cols-1 sm:grid-cols-2 gap-3 text-sm",
424
- children: [
425
- /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("span", {
426
- className: "text-xs text-text-secondary",
427
- children: "Booking ID"
428
- }), /* @__PURE__ */ w("p", {
429
- className: "font-mono text-xs text-text-primary",
430
- children: W.bookingId
431
- })] }),
432
- /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("span", {
433
- className: "text-xs text-text-secondary",
434
- children: "Est. Arrival"
435
- }), /* @__PURE__ */ w("p", {
436
- className: "text-text-primary",
437
- children: new Date(W.estimatedArrival).toLocaleTimeString([], {
438
- hour: "2-digit",
439
- minute: "2-digit"
440
- })
441
- })] }),
442
- /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("span", {
443
- className: "text-xs text-text-secondary",
444
- children: "Location"
445
- }), /* @__PURE__ */ w("p", {
446
- className: "text-text-primary truncate",
447
- children: R.address
448
- })] }),
449
- /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("span", {
450
- className: "text-xs text-text-secondary",
451
- children: "Phone"
452
- }), /* @__PURE__ */ w("p", {
453
- className: "text-text-primary",
454
- children: R.phoneNumber
455
- })] })
456
- ]
457
- })]
458
- }),
459
- /* @__PURE__ */ T("div", {
460
- className: "rounded-lg border border-status-success-border bg-status-success-bg-subtle p-4 mb-4",
461
- children: [/* @__PURE__ */ T("h3", {
462
- className: "text-sm font-medium text-status-success-text mb-2 flex items-center gap-2",
463
- children: [/* @__PURE__ */ w(f, { className: "h-4 w-4" }), "Payment Processed"]
464
- }), /* @__PURE__ */ T("div", {
465
- className: "grid grid-cols-2 gap-3 text-sm",
466
- children: [
467
- /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("span", {
468
- className: "text-xs text-text-secondary",
469
- children: "Transaction ID"
470
- }), /* @__PURE__ */ w("p", {
471
- className: "font-mono text-xs text-text-primary",
472
- children: W.transactionId
473
- })] }),
474
- /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("span", {
475
- className: "text-xs text-text-secondary",
476
- children: "Advance Paid"
477
- }), /* @__PURE__ */ w("p", {
478
- className: "font-medium text-text-primary",
479
- children: i(100, { minimumFractionDigits: 0 })
480
- })] }),
481
- /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("span", {
482
- className: "text-xs text-text-secondary",
483
- children: "Method"
484
- }), /* @__PURE__ */ w("p", {
485
- className: "capitalize text-text-primary",
486
- children: H
487
- })] }),
488
- /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("span", {
489
- className: "text-xs text-text-secondary",
490
- children: "Status"
491
- }), /* @__PURE__ */ w("p", {
492
- className: "font-medium text-status-success-text",
493
- children: "Paid"
494
- })] })
495
- ]
496
- })]
497
- }),
498
- /* @__PURE__ */ T("div", {
499
- className: "rounded-lg border border-status-info-border bg-status-info-bg-subtle p-4 mb-6",
500
- children: [/* @__PURE__ */ w("h3", {
501
- className: "text-sm font-medium text-status-info-text mb-2",
502
- children: "Next Steps"
503
- }), /* @__PURE__ */ T("div", {
504
- className: "space-y-2 text-xs text-status-info-text",
505
- children: [
506
- /* @__PURE__ */ T("div", {
507
- className: "flex items-start gap-2",
508
- children: [/* @__PURE__ */ w(f, { className: "h-3.5 w-3.5 text-status-success-text mt-0.5 shrink-0" }), /* @__PURE__ */ T("span", { children: [
509
- "Payment confirmed -",
510
- " ",
511
- i(100, { minimumFractionDigits: 0 }),
512
- " paid"
513
- ] })]
514
- }),
515
- /* @__PURE__ */ T("div", {
516
- className: "flex items-start gap-2",
517
- children: [/* @__PURE__ */ w(p, { className: "h-3.5 w-3.5 mt-0.5 shrink-0" }), /* @__PURE__ */ T("span", { children: [
518
- "Cart will arrive around",
519
- " ",
520
- new Date(W.estimatedArrival).toLocaleTimeString([], {
521
- hour: "2-digit",
522
- minute: "2-digit"
523
- })
524
- ] })]
525
- }),
526
- /* @__PURE__ */ T("div", {
527
- className: "flex items-start gap-2",
528
- children: [/* @__PURE__ */ w(m, { className: "h-3.5 w-3.5 mt-0.5 shrink-0" }), /* @__PURE__ */ T("span", { children: [
529
- "Pay remaining ",
530
- i(50, { minimumFractionDigits: 0 }),
531
- " ",
532
- "when cart arrives"
533
- ] })]
534
- })
535
- ]
536
- })]
537
- }),
538
- /* @__PURE__ */ T("div", {
539
- className: "flex gap-3",
540
- children: [/* @__PURE__ */ w("button", {
541
- type: "button",
542
- onClick: () => M(`/customer/bookings/${W.bookingId}`),
543
- className: "flex-1 rounded-lg bg-foreground px-4 py-2.5 text-sm font-medium text-background hover:opacity-90 transition-opacity",
544
- children: "View Booking"
545
- }), /* @__PURE__ */ w("button", {
546
- type: "button",
547
- onClick: () => M("/customer/carts"),
548
- className: "flex-1 rounded-lg border border-border-seam px-4 py-2.5 text-sm font-medium text-text-primary hover:bg-accent transition-colors",
549
- children: "Browse More"
550
- })]
551
- })
552
- ]
553
- }),
554
- P !== "confirmation" && /* @__PURE__ */ T("div", {
555
- className: "flex justify-between mt-5",
556
- children: [/* @__PURE__ */ T("button", {
557
- type: "button",
558
- onClick: Q,
559
- disabled: P === "location",
560
- className: t("flex items-center gap-2 rounded-lg border border-border-seam px-4 py-2.5 text-sm font-medium text-text-primary transition-colors", P === "location" ? "opacity-40 cursor-not-allowed" : "hover:bg-accent"),
561
- children: [/* @__PURE__ */ w(l, { className: "h-4 w-4" }), "Previous"]
562
- }), /* @__PURE__ */ w("button", {
563
- type: "button",
564
- onClick: Z,
565
- disabled: I,
566
- className: t("flex items-center gap-2 rounded-lg bg-foreground px-4 py-2.5 text-sm font-medium text-background transition-opacity", I ? "opacity-60 cursor-not-allowed" : "hover:opacity-90"),
567
- children: I ? /* @__PURE__ */ T(C, { children: [/* @__PURE__ */ w(g, { className: "h-4 w-4 animate-spin" }), P === "payment" ? "Processing Payment..." : "Processing..."] }) : /* @__PURE__ */ T(C, { children: [P === "payment" ? "Confirm & Pay" : "Next", /* @__PURE__ */ w(u, { className: "h-4 w-4" })] })
568
- })]
569
- })
570
- ]
571
- }), /* @__PURE__ */ w("div", {
572
- className: "lg:col-span-1",
573
- children: /* @__PURE__ */ T(E, {
574
- className: "sticky top-6 p-5",
575
- children: [
576
- /* @__PURE__ */ w("h3", {
577
- className: "text-base font-semibold text-text-primary mb-4",
578
- children: "Service Summary"
579
- }),
580
- /* @__PURE__ */ T("div", {
581
- className: "flex items-center gap-3 mb-4",
582
- children: [/* @__PURE__ */ w("img", {
583
- src: N.image,
584
- alt: N.name,
585
- className: "h-12 w-12 rounded-lg object-cover"
586
- }), /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("p", {
587
- className: "text-sm font-medium text-text-primary",
588
- children: N.name
589
- }), /* @__PURE__ */ w("p", {
590
- className: "text-xs text-text-secondary",
591
- children: N.category
592
- })] })]
593
- }),
594
- /* @__PURE__ */ T("div", {
595
- className: "space-y-2 text-sm border-t border-border-seam pt-3",
596
- children: [/* @__PURE__ */ T("div", {
597
- className: "flex justify-between",
598
- children: [/* @__PURE__ */ w("span", {
599
- className: "text-text-secondary",
600
- children: "Service Fee:"
601
- }), /* @__PURE__ */ w("span", {
602
- className: "text-text-primary",
603
- children: i(50, { minimumFractionDigits: 0 })
604
- })]
605
- }), /* @__PURE__ */ T("div", {
606
- className: "flex justify-between",
607
- children: [/* @__PURE__ */ w("span", {
608
- className: "text-text-secondary",
609
- children: "Advance Payment:"
610
- }), /* @__PURE__ */ w("span", {
611
- className: "font-medium text-text-primary",
612
- children: i(100, { minimumFractionDigits: 0 })
613
- })]
614
- })]
615
- }),
616
- /* @__PURE__ */ T("div", {
617
- className: "flex items-center gap-2 mt-3 pt-3 border-t border-border-seam text-status-success-text",
618
- children: [/* @__PURE__ */ w(f, { className: "h-3.5 w-3.5" }), /* @__PURE__ */ w("span", {
619
- className: "text-xs",
620
- children: "Pay remaining amount at cart"
621
- })]
622
- })
623
- ]
624
- })
625
- })]
626
- })
627
- ]
628
- });
629
- }
630
- //#endregion
631
- export { j as DirectServiceBookingPage };
632
-
633
- //# sourceMappingURL=DirectServiceBookingPage.js.map