@burdenoff/microfe-atheletebridge 2026.624.1 → 2026.625.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/atheletebridge/components/EmptyState.js +18 -11
- package/dist/atheletebridge/components/EmptyState.js.map +1 -1
- package/dist/atheletebridge/components/InvestmentCard.js +7 -7
- package/dist/atheletebridge/components/InvestmentCard.js.map +1 -1
- package/dist/atheletebridge/components/MetricsCard.js +20 -14
- package/dist/atheletebridge/components/MetricsCard.js.map +1 -1
- package/dist/atheletebridge/components/PageLayout.js +30 -19
- package/dist/atheletebridge/components/PageLayout.js.map +1 -1
- package/dist/atheletebridge/pages/HomePage.js +210 -195
- package/dist/atheletebridge/pages/HomePage.js.map +1 -1
- package/dist/atheletebridge/pages/admin/AdminAnalyticsPage.js +90 -82
- package/dist/atheletebridge/pages/admin/AdminAnalyticsPage.js.map +1 -1
- package/dist/atheletebridge/pages/admin/AdminDashboard.js +76 -44
- package/dist/atheletebridge/pages/admin/AdminDashboard.js.map +1 -1
- package/dist/atheletebridge/pages/admin/AdminFinancialPage.js +63 -55
- package/dist/atheletebridge/pages/admin/AdminFinancialPage.js.map +1 -1
- package/dist/atheletebridge/pages/admin/AdminOrdersPage.js +244 -237
- package/dist/atheletebridge/pages/admin/AdminOrdersPage.js.map +1 -1
- package/dist/atheletebridge/pages/admin/AdminProfilePage.js +59 -57
- package/dist/atheletebridge/pages/admin/AdminProfilePage.js.map +1 -1
- package/dist/atheletebridge/pages/admin/AdminSettingsPage.js +110 -106
- package/dist/atheletebridge/pages/admin/AdminSettingsPage.js.map +1 -1
- package/dist/atheletebridge/pages/admin/CartManagementPage.js +166 -159
- package/dist/atheletebridge/pages/admin/CartManagementPage.js.map +1 -1
- package/dist/atheletebridge/pages/admin/UserManagementPage.js +310 -303
- package/dist/atheletebridge/pages/admin/UserManagementPage.js.map +1 -1
- package/dist/atheletebridge/pages/cart-owner/AnalyticsDashboard.js +86 -81
- package/dist/atheletebridge/pages/cart-owner/AnalyticsDashboard.js.map +1 -1
- package/dist/atheletebridge/pages/cart-owner/BusinessSettingsPage.js +170 -166
- package/dist/atheletebridge/pages/cart-owner/BusinessSettingsPage.js.map +1 -1
- package/dist/atheletebridge/pages/cart-owner/CartOwnerDashboard.js +141 -109
- package/dist/atheletebridge/pages/cart-owner/CartOwnerDashboard.js.map +1 -1
- package/dist/atheletebridge/pages/cart-owner/CartOwnerProfilePage.js +139 -134
- package/dist/atheletebridge/pages/cart-owner/CartOwnerProfilePage.js.map +1 -1
- package/dist/atheletebridge/pages/cart-owner/CartServiceConfigPage.js +109 -107
- package/dist/atheletebridge/pages/cart-owner/CartServiceConfigPage.js.map +1 -1
- package/dist/atheletebridge/pages/cart-owner/InventoryManagementPage.js +318 -318
- package/dist/atheletebridge/pages/cart-owner/InventoryManagementPage.js.map +1 -1
- package/dist/atheletebridge/pages/cart-owner/OrderManagementPage.js +262 -262
- package/dist/atheletebridge/pages/cart-owner/OrderManagementPage.js.map +1 -1
- package/dist/atheletebridge/pages/cart-owner/StaffManagementPage.js +170 -162
- package/dist/atheletebridge/pages/cart-owner/StaffManagementPage.js.map +1 -1
- package/dist/atheletebridge/pages/common/HelpSupportPage.js +292 -298
- package/dist/atheletebridge/pages/common/HelpSupportPage.js.map +1 -1
- package/dist/atheletebridge/pages/common/NotificationCenterPage.js +100 -91
- package/dist/atheletebridge/pages/common/NotificationCenterPage.js.map +1 -1
- package/dist/atheletebridge/pages/common/SettingsPage.js +742 -734
- package/dist/atheletebridge/pages/common/SettingsPage.js.map +1 -1
- package/dist/atheletebridge/pages/customer/BookingDetailsPage.js +365 -356
- package/dist/atheletebridge/pages/customer/BookingDetailsPage.js.map +1 -1
- package/dist/atheletebridge/pages/customer/CartDetailPage.js +277 -241
- package/dist/atheletebridge/pages/customer/CartDetailPage.js.map +1 -1
- package/dist/atheletebridge/pages/customer/CartDiscoveryPage.js +261 -250
- package/dist/atheletebridge/pages/customer/CartDiscoveryPage.js.map +1 -1
- package/dist/atheletebridge/pages/customer/CheckoutPage.js +93 -89
- package/dist/atheletebridge/pages/customer/CheckoutPage.js.map +1 -1
- package/dist/atheletebridge/pages/customer/CustomerDashboard.js +430 -387
- package/dist/atheletebridge/pages/customer/CustomerDashboard.js.map +1 -1
- package/dist/atheletebridge/pages/customer/CustomerProfilePage.js +526 -490
- package/dist/atheletebridge/pages/customer/CustomerProfilePage.js.map +1 -1
- package/dist/atheletebridge/pages/customer/DirectServiceBookingPage.js +524 -512
- package/dist/atheletebridge/pages/customer/DirectServiceBookingPage.js.map +1 -1
- package/dist/atheletebridge/pages/customer/FavoritesPage.js +84 -75
- package/dist/atheletebridge/pages/customer/FavoritesPage.js.map +1 -1
- package/dist/atheletebridge/pages/customer/OrderHistoryPage.js +117 -108
- package/dist/atheletebridge/pages/customer/OrderHistoryPage.js.map +1 -1
- package/dist/atheletebridge/pages/customer/OrderTrackingPage.js +66 -61
- package/dist/atheletebridge/pages/customer/OrderTrackingPage.js.map +1 -1
- package/dist/atheletebridge/pages/customer/PaymentMethodsPage.js +81 -75
- package/dist/atheletebridge/pages/customer/PaymentMethodsPage.js.map +1 -1
- package/dist/atheletebridge/pages/customer/ReviewsPage.js +81 -72
- package/dist/atheletebridge/pages/customer/ReviewsPage.js.map +1 -1
- package/dist/atheletebridge/pages/customer/SavedAddressesPage.js +63 -55
- package/dist/atheletebridge/pages/customer/SavedAddressesPage.js.map +1 -1
- package/dist/atheletebridge/pages/investor/InvestmentDetailsPage.js +93 -61
- package/dist/atheletebridge/pages/investor/InvestmentDetailsPage.js.map +1 -1
- package/dist/atheletebridge/pages/investor/InvestmentOpportunitiesPage.js +90 -84
- package/dist/atheletebridge/pages/investor/InvestmentOpportunitiesPage.js.map +1 -1
- package/dist/atheletebridge/pages/investor/InvestorAnalyticsPage.js +60 -55
- package/dist/atheletebridge/pages/investor/InvestorAnalyticsPage.js.map +1 -1
- package/dist/atheletebridge/pages/investor/InvestorDashboard.js +345 -311
- package/dist/atheletebridge/pages/investor/InvestorDashboard.js.map +1 -1
- package/dist/atheletebridge/pages/investor/InvestorInvestmentsPage.js +38 -32
- package/dist/atheletebridge/pages/investor/InvestorInvestmentsPage.js.map +1 -1
- package/dist/atheletebridge/pages/investor/InvestorPortfolioPage.js +75 -67
- package/dist/atheletebridge/pages/investor/InvestorPortfolioPage.js.map +1 -1
- package/dist/atheletebridge/pages/investor/InvestorProfilePage.js +385 -381
- package/dist/atheletebridge/pages/investor/InvestorProfilePage.js.map +1 -1
- package/dist/atheletebridge/pages/worker/TaskDetailsPage.js +353 -319
- package/dist/atheletebridge/pages/worker/TaskDetailsPage.js.map +1 -1
- package/dist/atheletebridge/pages/worker/WorkerDashboard.js +353 -318
- package/dist/atheletebridge/pages/worker/WorkerDashboard.js.map +1 -1
- package/dist/atheletebridge/pages/worker/WorkerOrdersPage.js +134 -128
- package/dist/atheletebridge/pages/worker/WorkerOrdersPage.js.map +1 -1
- package/dist/atheletebridge/pages/worker/WorkerProfilePage.js +81 -77
- package/dist/atheletebridge/pages/worker/WorkerProfilePage.js.map +1 -1
- package/dist/atheletebridge/pages/worker/WorkerSchedulePage.js +352 -342
- package/dist/atheletebridge/pages/worker/WorkerSchedulePage.js.map +1 -1
- package/package.json +3 -3
|
@@ -2,15 +2,16 @@ import { useAthleteBridge as e } from "../../context/AthleteBridgeContext.js";
|
|
|
2
2
|
import { cn as t } from "../../utils/cn.js";
|
|
3
3
|
import { PageLayout as n } from "../../components/PageLayout.js";
|
|
4
4
|
import { EmptyState as r } from "../../components/EmptyState.js";
|
|
5
|
-
import { useInvestmentOpportunities as i, useOfferings as
|
|
6
|
-
import { formatCurrency as
|
|
7
|
-
import { useMemo as
|
|
8
|
-
import { ArrowLeft as
|
|
9
|
-
import { useParams as
|
|
10
|
-
import { Fragment as
|
|
5
|
+
import { useInvestmentOpportunities as i, useOfferings as ee, useProviders as a } from "../../hooks/useAthleteBridgeApi.js";
|
|
6
|
+
import { formatCurrency as o, formatDistance as s, formatDuration as c } from "../../utils/formatters.js";
|
|
7
|
+
import { useMemo as l, useState as u } from "react";
|
|
8
|
+
import { ArrowLeft as d, Calendar as f, CheckCircle2 as p, Clock as m, Flame as h, Home as g, Leaf as _, MapPin as v, Minus as y, Plus as b, Search as x, ShoppingCart as S, Star as C, TrendingUp as te, X as w } from "lucide-react";
|
|
9
|
+
import { useParams as T } from "react-router-dom";
|
|
10
|
+
import { Fragment as E, jsx as D, jsxs as O } from "react/jsx-runtime";
|
|
11
|
+
import { EmphasisPanel as k, NextSteps as A, PagePurpose as j } from "@burdenoff/fe-libs/ui";
|
|
11
12
|
//#region src/atheletebridge/pages/customer/CartDetailPage.tsx
|
|
12
|
-
function
|
|
13
|
-
let { cartId:
|
|
13
|
+
function M() {
|
|
14
|
+
let { cartId: M } = T(), { navigateTo: N } = e(), { data: P = [], isLoading: ne } = a(), { data: F = [], isLoading: re } = ee(M), { data: I = [], isLoading: ie } = i(), L = l(() => P.find((e) => e.id === M), [P, M]), R = l(() => I.find((e) => e.cartId === M), [I, M]), [z, B] = u(""), [V, H] = u(""), [U, W] = u([]), [G, K] = u(!1), [q, J] = u(null), Y = l(() => F.map((e) => ({
|
|
14
15
|
id: e.id,
|
|
15
16
|
name: e.name,
|
|
16
17
|
price: e.price,
|
|
@@ -20,24 +21,24 @@ function A() {
|
|
|
20
21
|
isVeg: !0,
|
|
21
22
|
duration: e.durationMinutes,
|
|
22
23
|
serviceType: e.serviceType
|
|
23
|
-
})), [
|
|
24
|
-
let e =
|
|
25
|
-
if (
|
|
26
|
-
let t =
|
|
24
|
+
})), [F]), X = l(() => [...new Set(Y.map((e) => e.category))], [Y]), Z = l(() => {
|
|
25
|
+
let e = Y;
|
|
26
|
+
if (V && (e = e.filter((e) => e.category === V)), z.trim()) {
|
|
27
|
+
let t = z.toLowerCase();
|
|
27
28
|
e = e.filter((e) => e.name.toLowerCase().includes(t) || e.description.toLowerCase().includes(t));
|
|
28
29
|
}
|
|
29
30
|
return e;
|
|
30
31
|
}, [
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
]),
|
|
32
|
+
Y,
|
|
33
|
+
V,
|
|
34
|
+
z
|
|
35
|
+
]), ae = l(() => {
|
|
35
36
|
let e = {};
|
|
36
|
-
return
|
|
37
|
+
return Z.forEach((t) => {
|
|
37
38
|
e[t.category] || (e[t.category] = []), e[t.category].push(t);
|
|
38
39
|
}), e;
|
|
39
|
-
}, [
|
|
40
|
-
|
|
40
|
+
}, [Z]), oe = (e, t = 1, n) => {
|
|
41
|
+
W((r) => r.find((t) => t.productId === e.id) ? r.map((n) => n.productId === e.id ? {
|
|
41
42
|
...n,
|
|
42
43
|
quantity: n.quantity + t
|
|
43
44
|
} : n) : [...r, {
|
|
@@ -49,304 +50,338 @@ function A() {
|
|
|
49
50
|
specialInstructions: n
|
|
50
51
|
}]);
|
|
51
52
|
}, Q = (e, t) => {
|
|
52
|
-
|
|
53
|
+
W((n) => n.map((n) => n.productId === e ? {
|
|
53
54
|
...n,
|
|
54
55
|
quantity: Math.max(0, n.quantity + t)
|
|
55
56
|
} : n).filter((e) => e.quantity > 0));
|
|
56
57
|
}, $ = (e) => {
|
|
57
|
-
|
|
58
|
-
},
|
|
59
|
-
|
|
58
|
+
W((t) => t.filter((t) => t.productId !== e));
|
|
59
|
+
}, se = (e) => U.find((t) => t.productId === e)?.quantity ?? 0, ce = U.reduce((e, t) => e + t.price * t.quantity, 0), le = U.reduce((e, t) => e + t.quantity, 0), ue = (e) => {
|
|
60
|
+
J({
|
|
60
61
|
product: e,
|
|
61
62
|
quantity: 1,
|
|
62
63
|
specialInstructions: ""
|
|
63
|
-
}),
|
|
64
|
+
}), K(!0);
|
|
64
65
|
};
|
|
65
|
-
return
|
|
66
|
-
title: /* @__PURE__ */
|
|
66
|
+
return L ? /* @__PURE__ */ O(n, {
|
|
67
|
+
title: /* @__PURE__ */ O("div", {
|
|
67
68
|
className: "flex items-center gap-3",
|
|
68
69
|
children: [
|
|
69
|
-
/* @__PURE__ */
|
|
70
|
+
/* @__PURE__ */ D("button", {
|
|
70
71
|
type: "button",
|
|
71
|
-
onClick: () =>
|
|
72
|
+
onClick: () => N("/customer/carts"),
|
|
72
73
|
className: "rounded-md p-1 text-text-secondary hover:bg-accent hover:text-text-primary transition-colors",
|
|
73
|
-
children: /* @__PURE__ */
|
|
74
|
+
children: /* @__PURE__ */ D(d, { className: "h-5 w-5" })
|
|
74
75
|
}),
|
|
75
|
-
/* @__PURE__ */
|
|
76
|
+
/* @__PURE__ */ D("span", {
|
|
76
77
|
className: "truncate",
|
|
77
|
-
children:
|
|
78
|
+
children: L.name
|
|
78
79
|
}),
|
|
79
|
-
|
|
80
|
+
L.isVerified && /* @__PURE__ */ D(p, { className: "h-5 w-5 text-blue-500 shrink-0" })
|
|
80
81
|
]
|
|
81
82
|
}),
|
|
82
|
-
description:
|
|
83
|
+
description: L.category,
|
|
83
84
|
children: [
|
|
84
|
-
/* @__PURE__ */
|
|
85
|
-
className: "
|
|
86
|
-
children:
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
className: "
|
|
92
|
-
children: /* @__PURE__ */
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
className: "text-
|
|
107
|
-
|
|
108
|
-
"
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
85
|
+
/* @__PURE__ */ D(j, {
|
|
86
|
+
className: "mb-6",
|
|
87
|
+
children: "Everything this provider offers, in one place. Browse and search their offerings, customise items, add them to your order, then proceed to checkout. Use the operating hours and ratings to decide before you order."
|
|
88
|
+
}),
|
|
89
|
+
/* @__PURE__ */ D(k, {
|
|
90
|
+
className: "p-0 overflow-hidden",
|
|
91
|
+
children: /* @__PURE__ */ O("div", {
|
|
92
|
+
className: "relative h-48 rounded-lg bg-bg-sunken overflow-hidden",
|
|
93
|
+
children: [/* @__PURE__ */ D("img", {
|
|
94
|
+
src: L.image,
|
|
95
|
+
alt: L.name,
|
|
96
|
+
className: "h-full w-full object-cover"
|
|
97
|
+
}), /* @__PURE__ */ D("div", {
|
|
98
|
+
className: "absolute bottom-0 inset-x-0 bg-gradient-to-t from-black/60 to-transparent p-4",
|
|
99
|
+
children: /* @__PURE__ */ O("div", {
|
|
100
|
+
className: "flex items-center gap-3",
|
|
101
|
+
children: [/* @__PURE__ */ D("span", {
|
|
102
|
+
className: t("inline-flex items-center rounded-full px-2.5 py-0.5 text-xs font-medium", L.isOpen ? "bg-green-500/20 text-green-300" : "bg-red-500/20 text-red-300"),
|
|
103
|
+
children: L.isOpen ? "Open Now" : "Closed"
|
|
104
|
+
}), /* @__PURE__ */ O("div", {
|
|
105
|
+
className: "flex items-center gap-1 text-white text-sm",
|
|
106
|
+
children: [
|
|
107
|
+
/* @__PURE__ */ D(C, { className: "h-3.5 w-3.5 fill-yellow-400 text-yellow-400" }),
|
|
108
|
+
/* @__PURE__ */ D("span", {
|
|
109
|
+
className: "font-medium",
|
|
110
|
+
children: L.rating
|
|
111
|
+
}),
|
|
112
|
+
/* @__PURE__ */ O("span", {
|
|
113
|
+
className: "text-white/70",
|
|
114
|
+
children: [
|
|
115
|
+
"(",
|
|
116
|
+
L.totalRatings,
|
|
117
|
+
")"
|
|
118
|
+
]
|
|
119
|
+
})
|
|
120
|
+
]
|
|
121
|
+
})]
|
|
122
|
+
})
|
|
123
|
+
})]
|
|
124
|
+
})
|
|
117
125
|
}),
|
|
118
|
-
|
|
126
|
+
/* @__PURE__ */ D(A, {
|
|
127
|
+
className: "mt-6",
|
|
128
|
+
storageKey: "atheletebridge-cart-detail",
|
|
129
|
+
steps: [
|
|
130
|
+
{
|
|
131
|
+
id: "browse",
|
|
132
|
+
label: "Browse the offerings",
|
|
133
|
+
description: "Search or filter by category to find what you want.",
|
|
134
|
+
icon: /* @__PURE__ */ D(x, { className: "h-4 w-4" }),
|
|
135
|
+
onClick: () => {
|
|
136
|
+
document.getElementById("cart-offerings")?.scrollIntoView({ behavior: "smooth" });
|
|
137
|
+
}
|
|
138
|
+
},
|
|
139
|
+
{
|
|
140
|
+
id: "add",
|
|
141
|
+
label: "Add items to your order",
|
|
142
|
+
description: "Use the + control on any item to build your order.",
|
|
143
|
+
icon: /* @__PURE__ */ D(b, { className: "h-4 w-4" })
|
|
144
|
+
},
|
|
145
|
+
{
|
|
146
|
+
id: "checkout",
|
|
147
|
+
label: "Proceed to checkout",
|
|
148
|
+
description: "Review your order and place it when you are ready.",
|
|
149
|
+
icon: /* @__PURE__ */ D(S, { className: "h-4 w-4" }),
|
|
150
|
+
onClick: () => N("/customer/checkout")
|
|
151
|
+
}
|
|
152
|
+
]
|
|
153
|
+
}),
|
|
154
|
+
!L.isOpen && /* @__PURE__ */ D("div", {
|
|
119
155
|
className: "mt-4 rounded-lg border border-yellow-500/30 bg-yellow-500/10 p-3",
|
|
120
|
-
children: /* @__PURE__ */
|
|
156
|
+
children: /* @__PURE__ */ O("p", {
|
|
121
157
|
className: "text-sm text-yellow-700 dark:text-yellow-400",
|
|
122
|
-
children: [/* @__PURE__ */
|
|
158
|
+
children: [/* @__PURE__ */ D("strong", { children: "This cart is currently closed." }), " You can browse the offerings but orders are not being accepted."]
|
|
123
159
|
})
|
|
124
160
|
}),
|
|
125
|
-
/* @__PURE__ */
|
|
161
|
+
/* @__PURE__ */ O("div", {
|
|
126
162
|
className: "mt-4 grid grid-cols-1 gap-3 sm:grid-cols-3",
|
|
127
163
|
children: [
|
|
128
|
-
/* @__PURE__ */
|
|
164
|
+
/* @__PURE__ */ O("div", {
|
|
129
165
|
className: "rounded-lg border border-border-subtle bg-bg-surface p-3",
|
|
130
166
|
children: [
|
|
131
|
-
/* @__PURE__ */
|
|
167
|
+
/* @__PURE__ */ O("div", {
|
|
132
168
|
className: "flex items-center gap-2 text-text-secondary text-xs mb-1",
|
|
133
|
-
children: [/* @__PURE__ */
|
|
169
|
+
children: [/* @__PURE__ */ D(v, { className: "h-3.5 w-3.5" }), /* @__PURE__ */ D("span", {
|
|
134
170
|
className: "font-medium uppercase tracking-wider",
|
|
135
171
|
children: "Location"
|
|
136
172
|
})]
|
|
137
173
|
}),
|
|
138
|
-
/* @__PURE__ */
|
|
174
|
+
/* @__PURE__ */ D("p", {
|
|
139
175
|
className: "text-sm text-text-primary",
|
|
140
|
-
children:
|
|
176
|
+
children: L.location.address
|
|
141
177
|
}),
|
|
142
|
-
/* @__PURE__ */
|
|
178
|
+
/* @__PURE__ */ O("p", {
|
|
143
179
|
className: "text-xs text-text-secondary",
|
|
144
|
-
children: [
|
|
180
|
+
children: [s(L.distance), " away"]
|
|
145
181
|
})
|
|
146
182
|
]
|
|
147
183
|
}),
|
|
148
|
-
/* @__PURE__ */
|
|
184
|
+
/* @__PURE__ */ O("div", {
|
|
149
185
|
className: "rounded-lg border border-border-subtle bg-bg-surface p-3",
|
|
150
186
|
children: [
|
|
151
|
-
/* @__PURE__ */
|
|
187
|
+
/* @__PURE__ */ O("div", {
|
|
152
188
|
className: "flex items-center gap-2 text-text-secondary text-xs mb-1",
|
|
153
|
-
children: [/* @__PURE__ */
|
|
189
|
+
children: [/* @__PURE__ */ D(m, { className: "h-3.5 w-3.5" }), /* @__PURE__ */ D("span", {
|
|
154
190
|
className: "font-medium uppercase tracking-wider",
|
|
155
191
|
children: "Estimated Time"
|
|
156
192
|
})]
|
|
157
193
|
}),
|
|
158
|
-
/* @__PURE__ */
|
|
194
|
+
/* @__PURE__ */ D("p", {
|
|
159
195
|
className: "text-sm text-text-primary",
|
|
160
|
-
children:
|
|
196
|
+
children: c(L.estimatedTime)
|
|
161
197
|
}),
|
|
162
|
-
|
|
198
|
+
L.averageOrderValue && /* @__PURE__ */ O("p", {
|
|
163
199
|
className: "text-xs text-text-secondary",
|
|
164
|
-
children: ["Avg ",
|
|
200
|
+
children: ["Avg ", o(L.averageOrderValue, { minimumFractionDigits: 0 })]
|
|
165
201
|
})
|
|
166
202
|
]
|
|
167
203
|
}),
|
|
168
|
-
/* @__PURE__ */
|
|
204
|
+
/* @__PURE__ */ O("div", {
|
|
169
205
|
className: "rounded-lg border border-border-subtle bg-bg-surface p-3",
|
|
170
206
|
children: [
|
|
171
|
-
/* @__PURE__ */
|
|
207
|
+
/* @__PURE__ */ O("div", {
|
|
172
208
|
className: "flex items-center gap-2 text-text-secondary text-xs mb-1",
|
|
173
|
-
children: [/* @__PURE__ */
|
|
209
|
+
children: [/* @__PURE__ */ D(C, { className: "h-3.5 w-3.5" }), /* @__PURE__ */ D("span", {
|
|
174
210
|
className: "font-medium uppercase tracking-wider",
|
|
175
211
|
children: "Rating"
|
|
176
212
|
})]
|
|
177
213
|
}),
|
|
178
|
-
/* @__PURE__ */
|
|
214
|
+
/* @__PURE__ */ O("p", {
|
|
179
215
|
className: "text-sm text-text-primary",
|
|
180
|
-
children: [
|
|
216
|
+
children: [L.rating, " / 5.0"]
|
|
181
217
|
}),
|
|
182
|
-
/* @__PURE__ */
|
|
218
|
+
/* @__PURE__ */ O("p", {
|
|
183
219
|
className: "text-xs text-text-secondary",
|
|
184
|
-
children: [
|
|
220
|
+
children: [L.totalRatings, " reviews"]
|
|
185
221
|
})
|
|
186
222
|
]
|
|
187
223
|
})
|
|
188
224
|
]
|
|
189
225
|
}),
|
|
190
|
-
|
|
226
|
+
L.businessHours && Object.keys(L.businessHours).length > 0 && /* @__PURE__ */ O("section", {
|
|
191
227
|
className: "mt-6",
|
|
192
|
-
children: [/* @__PURE__ */
|
|
228
|
+
children: [/* @__PURE__ */ D("h2", {
|
|
193
229
|
className: "text-base font-semibold text-text-primary mb-2",
|
|
194
230
|
children: "Operating Hours"
|
|
195
|
-
}), /* @__PURE__ */
|
|
231
|
+
}), /* @__PURE__ */ D("div", {
|
|
196
232
|
className: "rounded-lg border border-border-subtle bg-bg-surface overflow-hidden",
|
|
197
|
-
children: Object.entries(
|
|
233
|
+
children: Object.entries(L.businessHours).map(([e, t]) => /* @__PURE__ */ O("div", {
|
|
198
234
|
className: "flex items-center justify-between px-4 py-2 border-b border-border-subtle last:border-b-0",
|
|
199
|
-
children: [/* @__PURE__ */
|
|
235
|
+
children: [/* @__PURE__ */ D("span", {
|
|
200
236
|
className: "text-sm font-medium text-text-primary capitalize",
|
|
201
237
|
children: e
|
|
202
|
-
}), t.isOpen ? /* @__PURE__ */
|
|
238
|
+
}), t.isOpen ? /* @__PURE__ */ O("span", {
|
|
203
239
|
className: "text-sm text-text-secondary",
|
|
204
240
|
children: [
|
|
205
241
|
t.open,
|
|
206
242
|
" - ",
|
|
207
243
|
t.close
|
|
208
244
|
]
|
|
209
|
-
}) : /* @__PURE__ */
|
|
245
|
+
}) : /* @__PURE__ */ D("span", {
|
|
210
246
|
className: "text-sm text-status-error-text",
|
|
211
247
|
children: "Closed"
|
|
212
248
|
})]
|
|
213
249
|
}, e))
|
|
214
250
|
})]
|
|
215
251
|
}),
|
|
216
|
-
/* @__PURE__ */
|
|
252
|
+
/* @__PURE__ */ O("div", {
|
|
217
253
|
className: "mt-6 grid grid-cols-1 gap-6 lg:grid-cols-3",
|
|
218
|
-
children: [/* @__PURE__ */
|
|
254
|
+
children: [/* @__PURE__ */ O("div", {
|
|
219
255
|
className: "lg:col-span-2",
|
|
220
256
|
children: [
|
|
221
|
-
/* @__PURE__ */
|
|
257
|
+
/* @__PURE__ */ O("div", {
|
|
222
258
|
className: "flex flex-col gap-3 sm:flex-row mb-4",
|
|
223
|
-
children: [/* @__PURE__ */
|
|
259
|
+
children: [/* @__PURE__ */ O("div", {
|
|
224
260
|
className: "relative flex-1",
|
|
225
|
-
children: [/* @__PURE__ */
|
|
261
|
+
children: [/* @__PURE__ */ D(x, { className: "absolute left-3 top-1/2 h-4 w-4 -translate-y-1/2 text-text-secondary" }), /* @__PURE__ */ D("input", {
|
|
226
262
|
type: "text",
|
|
227
263
|
placeholder: "Search offerings...",
|
|
228
|
-
value:
|
|
229
|
-
onChange: (e) =>
|
|
264
|
+
value: z,
|
|
265
|
+
onChange: (e) => B(e.target.value),
|
|
230
266
|
className: "w-full rounded-lg border border-border-subtle bg-bg-surface py-2 pl-10 pr-3 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
|
|
231
267
|
})]
|
|
232
|
-
}), /* @__PURE__ */
|
|
233
|
-
value:
|
|
234
|
-
onChange: (e) =>
|
|
268
|
+
}), /* @__PURE__ */ O("select", {
|
|
269
|
+
value: V,
|
|
270
|
+
onChange: (e) => H(e.target.value),
|
|
235
271
|
className: "rounded-lg border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]",
|
|
236
|
-
children: [/* @__PURE__ */
|
|
272
|
+
children: [/* @__PURE__ */ D("option", {
|
|
237
273
|
value: "",
|
|
238
274
|
children: "All Categories"
|
|
239
|
-
}),
|
|
275
|
+
}), X.map((e) => /* @__PURE__ */ D("option", {
|
|
240
276
|
value: e,
|
|
241
277
|
children: e
|
|
242
278
|
}, e))]
|
|
243
279
|
})]
|
|
244
280
|
}),
|
|
245
|
-
/* @__PURE__ */
|
|
281
|
+
/* @__PURE__ */ O("h2", {
|
|
282
|
+
id: "cart-offerings",
|
|
246
283
|
className: "text-lg font-semibold text-text-primary mb-3",
|
|
247
284
|
children: [
|
|
248
285
|
"Menu & Services (",
|
|
249
|
-
|
|
286
|
+
Z.length,
|
|
250
287
|
")"
|
|
251
288
|
]
|
|
252
289
|
}),
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
})]
|
|
259
|
-
}) : /* @__PURE__ */ O("div", {
|
|
290
|
+
Z.length === 0 ? /* @__PURE__ */ D(r, {
|
|
291
|
+
illustration: "empty-search",
|
|
292
|
+
title: "No offerings found",
|
|
293
|
+
description: "No items match your search. Try a different keyword or clear the category filter."
|
|
294
|
+
}) : /* @__PURE__ */ D("div", {
|
|
260
295
|
className: "space-y-6",
|
|
261
|
-
children: Object.entries(
|
|
296
|
+
children: Object.entries(ae).map(([e, n]) => /* @__PURE__ */ O("div", { children: [/* @__PURE__ */ D("h3", {
|
|
262
297
|
className: "text-sm font-semibold text-text-primary mb-2 px-1",
|
|
263
298
|
children: e
|
|
264
|
-
}), /* @__PURE__ */
|
|
299
|
+
}), /* @__PURE__ */ D("div", {
|
|
265
300
|
className: "space-y-2",
|
|
266
301
|
children: n.map((e) => {
|
|
267
|
-
let n =
|
|
268
|
-
return /* @__PURE__ */
|
|
302
|
+
let n = se(e.id);
|
|
303
|
+
return /* @__PURE__ */ O("div", {
|
|
269
304
|
className: "flex gap-4 rounded-lg border border-border-subtle bg-bg-surface p-4",
|
|
270
|
-
children: [/* @__PURE__ */
|
|
305
|
+
children: [/* @__PURE__ */ D("div", {
|
|
271
306
|
className: "h-20 w-20 shrink-0 rounded-md bg-bg-sunken overflow-hidden",
|
|
272
|
-
children: /* @__PURE__ */
|
|
307
|
+
children: /* @__PURE__ */ D("img", {
|
|
273
308
|
src: e.image,
|
|
274
309
|
alt: e.name,
|
|
275
310
|
className: "h-full w-full object-cover"
|
|
276
311
|
})
|
|
277
|
-
}), /* @__PURE__ */
|
|
312
|
+
}), /* @__PURE__ */ O("div", {
|
|
278
313
|
className: "flex-1 min-w-0",
|
|
279
314
|
children: [
|
|
280
|
-
/* @__PURE__ */
|
|
315
|
+
/* @__PURE__ */ O("div", {
|
|
281
316
|
className: "flex items-start justify-between gap-2",
|
|
282
|
-
children: [/* @__PURE__ */
|
|
317
|
+
children: [/* @__PURE__ */ O("div", { children: [/* @__PURE__ */ O("div", {
|
|
283
318
|
className: "flex items-center gap-2",
|
|
284
|
-
children: [/* @__PURE__ */
|
|
319
|
+
children: [/* @__PURE__ */ D("h4", {
|
|
285
320
|
className: "text-sm font-semibold text-text-primary",
|
|
286
321
|
children: e.name
|
|
287
|
-
}), e.isVeg && /* @__PURE__ */
|
|
288
|
-
}), /* @__PURE__ */
|
|
322
|
+
}), e.isVeg && /* @__PURE__ */ D(_, { className: "h-3.5 w-3.5 text-green-600 dark:text-green-400" })]
|
|
323
|
+
}), /* @__PURE__ */ D("p", {
|
|
289
324
|
className: "text-xs text-text-secondary mt-0.5",
|
|
290
325
|
children: e.category
|
|
291
|
-
})] }), /* @__PURE__ */
|
|
326
|
+
})] }), /* @__PURE__ */ D("span", {
|
|
292
327
|
className: "text-sm font-bold text-text-primary whitespace-nowrap",
|
|
293
|
-
children:
|
|
328
|
+
children: o(e.price, { minimumFractionDigits: 0 })
|
|
294
329
|
})]
|
|
295
330
|
}),
|
|
296
|
-
/* @__PURE__ */
|
|
331
|
+
/* @__PURE__ */ D("p", {
|
|
297
332
|
className: "mt-1 text-xs text-text-secondary line-clamp-2",
|
|
298
333
|
children: e.description
|
|
299
334
|
}),
|
|
300
|
-
/* @__PURE__ */
|
|
335
|
+
/* @__PURE__ */ O("div", {
|
|
301
336
|
className: "mt-2 flex flex-wrap items-center gap-2 text-[10px] text-text-secondary",
|
|
302
337
|
children: [
|
|
303
|
-
e.duration != null && e.duration > 0 && /* @__PURE__ */
|
|
338
|
+
e.duration != null && e.duration > 0 && /* @__PURE__ */ O("span", {
|
|
304
339
|
className: "flex items-center gap-0.5",
|
|
305
|
-
children: [/* @__PURE__ */
|
|
340
|
+
children: [/* @__PURE__ */ D(m, { className: "h-3 w-3" }), c(e.duration)]
|
|
306
341
|
}),
|
|
307
|
-
e.serviceType && /* @__PURE__ */
|
|
342
|
+
e.serviceType && /* @__PURE__ */ D("span", {
|
|
308
343
|
className: "rounded bg-bg-sunken px-1.5 py-0.5 capitalize",
|
|
309
344
|
children: e.serviceType
|
|
310
345
|
}),
|
|
311
|
-
e.spiceLevel && /* @__PURE__ */
|
|
346
|
+
e.spiceLevel && /* @__PURE__ */ O("span", {
|
|
312
347
|
className: "flex items-center gap-0.5 rounded bg-bg-sunken px-1.5 py-0.5 capitalize",
|
|
313
|
-
children: [/* @__PURE__ */
|
|
348
|
+
children: [/* @__PURE__ */ D(h, { className: "h-3 w-3" }), e.spiceLevel]
|
|
314
349
|
})
|
|
315
350
|
]
|
|
316
351
|
}),
|
|
317
|
-
/* @__PURE__ */
|
|
352
|
+
/* @__PURE__ */ D("div", {
|
|
318
353
|
className: "mt-2 flex justify-end",
|
|
319
|
-
children: n > 0 ? /* @__PURE__ */
|
|
354
|
+
children: n > 0 ? /* @__PURE__ */ O("div", {
|
|
320
355
|
className: "flex items-center gap-2",
|
|
321
356
|
children: [
|
|
322
|
-
/* @__PURE__ */
|
|
357
|
+
/* @__PURE__ */ D("button", {
|
|
323
358
|
type: "button",
|
|
324
359
|
onClick: () => Q(e.id, -1),
|
|
325
360
|
className: "flex h-7 w-7 items-center justify-center rounded-full bg-bg-sunken text-text-primary hover:bg-accent",
|
|
326
|
-
children: /* @__PURE__ */
|
|
361
|
+
children: /* @__PURE__ */ D(y, { className: "h-3.5 w-3.5" })
|
|
327
362
|
}),
|
|
328
|
-
/* @__PURE__ */
|
|
363
|
+
/* @__PURE__ */ D("span", {
|
|
329
364
|
className: "min-w-[2ch] text-center text-sm font-medium text-text-primary",
|
|
330
365
|
children: n
|
|
331
366
|
}),
|
|
332
|
-
/* @__PURE__ */
|
|
367
|
+
/* @__PURE__ */ D("button", {
|
|
333
368
|
type: "button",
|
|
334
369
|
onClick: () => Q(e.id, 1),
|
|
335
370
|
className: "flex h-7 w-7 items-center justify-center rounded-full bg-foreground text-background hover:opacity-90",
|
|
336
|
-
children: /* @__PURE__ */
|
|
371
|
+
children: /* @__PURE__ */ D(b, { className: "h-3.5 w-3.5" })
|
|
337
372
|
}),
|
|
338
|
-
/* @__PURE__ */
|
|
373
|
+
/* @__PURE__ */ D("button", {
|
|
339
374
|
type: "button",
|
|
340
375
|
onClick: () => $(e.id),
|
|
341
376
|
className: "ml-1 flex h-7 w-7 items-center justify-center rounded-full text-status-error-text hover:bg-status-error-bg/10",
|
|
342
|
-
children: /* @__PURE__ */
|
|
377
|
+
children: /* @__PURE__ */ D(w, { className: "h-3.5 w-3.5" })
|
|
343
378
|
})
|
|
344
379
|
]
|
|
345
|
-
}) : /* @__PURE__ */
|
|
380
|
+
}) : /* @__PURE__ */ D("button", {
|
|
346
381
|
type: "button",
|
|
347
|
-
disabled: !
|
|
348
|
-
onClick: () =>
|
|
349
|
-
className: t("rounded-lg px-4 py-1.5 text-xs font-medium transition-opacity",
|
|
382
|
+
disabled: !L.isOpen,
|
|
383
|
+
onClick: () => ue(e),
|
|
384
|
+
className: t("rounded-lg px-4 py-1.5 text-xs font-medium transition-opacity", L.isOpen ? "bg-foreground text-background hover:opacity-90" : "bg-bg-sunken text-text-secondary cursor-not-allowed"),
|
|
350
385
|
children: "Add"
|
|
351
386
|
})
|
|
352
387
|
})
|
|
@@ -357,143 +392,143 @@ function A() {
|
|
|
357
392
|
})] }, e))
|
|
358
393
|
})
|
|
359
394
|
]
|
|
360
|
-
}), /* @__PURE__ */
|
|
395
|
+
}), /* @__PURE__ */ O("div", {
|
|
361
396
|
className: "space-y-4",
|
|
362
397
|
children: [
|
|
363
|
-
/* @__PURE__ */
|
|
398
|
+
/* @__PURE__ */ O("div", {
|
|
364
399
|
className: "rounded-lg border border-border-subtle bg-bg-surface p-4 lg:sticky lg:top-6",
|
|
365
|
-
children: [/* @__PURE__ */
|
|
400
|
+
children: [/* @__PURE__ */ O("h3", {
|
|
366
401
|
className: "text-base font-semibold text-text-primary mb-3 flex items-center gap-2",
|
|
367
|
-
children: [/* @__PURE__ */
|
|
368
|
-
}),
|
|
402
|
+
children: [/* @__PURE__ */ D(S, { className: "h-4 w-4" }), "Your Order"]
|
|
403
|
+
}), U.length === 0 ? /* @__PURE__ */ O("div", {
|
|
369
404
|
className: "py-6 text-center",
|
|
370
|
-
children: [/* @__PURE__ */
|
|
405
|
+
children: [/* @__PURE__ */ D(S, { className: "mx-auto h-8 w-8 text-text-secondary/40" }), /* @__PURE__ */ D("p", {
|
|
371
406
|
className: "mt-2 text-sm text-text-secondary",
|
|
372
407
|
children: "Your cart is empty"
|
|
373
408
|
})]
|
|
374
|
-
}) : /* @__PURE__ */
|
|
409
|
+
}) : /* @__PURE__ */ O(E, { children: [/* @__PURE__ */ D("div", {
|
|
375
410
|
className: "space-y-2 max-h-64 overflow-y-auto mb-3",
|
|
376
|
-
children:
|
|
411
|
+
children: U.map((e) => /* @__PURE__ */ O("div", {
|
|
377
412
|
className: "flex items-center justify-between gap-2",
|
|
378
|
-
children: [/* @__PURE__ */
|
|
413
|
+
children: [/* @__PURE__ */ O("div", {
|
|
379
414
|
className: "flex-1 min-w-0",
|
|
380
|
-
children: [/* @__PURE__ */
|
|
415
|
+
children: [/* @__PURE__ */ D("p", {
|
|
381
416
|
className: "text-sm font-medium text-text-primary truncate",
|
|
382
417
|
children: e.name
|
|
383
|
-
}), /* @__PURE__ */
|
|
418
|
+
}), /* @__PURE__ */ O("p", {
|
|
384
419
|
className: "text-xs text-text-secondary",
|
|
385
420
|
children: [
|
|
386
|
-
|
|
421
|
+
o(e.price, { minimumFractionDigits: 0 }),
|
|
387
422
|
" x",
|
|
388
423
|
" ",
|
|
389
424
|
e.quantity
|
|
390
425
|
]
|
|
391
426
|
})]
|
|
392
|
-
}), /* @__PURE__ */
|
|
427
|
+
}), /* @__PURE__ */ O("div", {
|
|
393
428
|
className: "flex items-center gap-1",
|
|
394
429
|
children: [
|
|
395
|
-
/* @__PURE__ */
|
|
430
|
+
/* @__PURE__ */ D("button", {
|
|
396
431
|
type: "button",
|
|
397
432
|
onClick: () => Q(e.productId, -1),
|
|
398
433
|
className: "flex h-6 w-6 items-center justify-center rounded bg-bg-sunken text-text-primary text-xs",
|
|
399
434
|
children: "-"
|
|
400
435
|
}),
|
|
401
|
-
/* @__PURE__ */
|
|
436
|
+
/* @__PURE__ */ D("span", {
|
|
402
437
|
className: "min-w-[2ch] text-center text-xs font-medium",
|
|
403
438
|
children: e.quantity
|
|
404
439
|
}),
|
|
405
|
-
/* @__PURE__ */
|
|
440
|
+
/* @__PURE__ */ D("button", {
|
|
406
441
|
type: "button",
|
|
407
442
|
onClick: () => Q(e.productId, 1),
|
|
408
443
|
className: "flex h-6 w-6 items-center justify-center rounded bg-bg-sunken text-text-primary text-xs",
|
|
409
444
|
children: "+"
|
|
410
445
|
}),
|
|
411
|
-
/* @__PURE__ */
|
|
446
|
+
/* @__PURE__ */ D("button", {
|
|
412
447
|
type: "button",
|
|
413
448
|
onClick: () => $(e.productId),
|
|
414
449
|
className: "ml-1 text-status-error-text hover:text-status-error-text/80",
|
|
415
|
-
children: /* @__PURE__ */
|
|
450
|
+
children: /* @__PURE__ */ D(w, { className: "h-3.5 w-3.5" })
|
|
416
451
|
})
|
|
417
452
|
]
|
|
418
453
|
})]
|
|
419
454
|
}, e.id))
|
|
420
|
-
}), /* @__PURE__ */
|
|
455
|
+
}), /* @__PURE__ */ O("div", {
|
|
421
456
|
className: "border-t border-border-subtle pt-3",
|
|
422
|
-
children: [/* @__PURE__ */
|
|
457
|
+
children: [/* @__PURE__ */ O("div", {
|
|
423
458
|
className: "flex justify-between items-center mb-3",
|
|
424
|
-
children: [/* @__PURE__ */
|
|
459
|
+
children: [/* @__PURE__ */ O("span", {
|
|
425
460
|
className: "text-sm font-semibold text-text-primary",
|
|
426
|
-
children: ["Total: ",
|
|
427
|
-
}), /* @__PURE__ */
|
|
461
|
+
children: ["Total: ", o(ce, { minimumFractionDigits: 0 })]
|
|
462
|
+
}), /* @__PURE__ */ O("span", {
|
|
428
463
|
className: "text-xs text-text-secondary",
|
|
429
|
-
children: [
|
|
464
|
+
children: [le, " items"]
|
|
430
465
|
})]
|
|
431
|
-
}), /* @__PURE__ */
|
|
466
|
+
}), /* @__PURE__ */ D("button", {
|
|
432
467
|
type: "button",
|
|
433
|
-
onClick: () =>
|
|
468
|
+
onClick: () => N("/customer/checkout"),
|
|
434
469
|
className: "w-full rounded-lg bg-foreground py-2.5 text-sm font-medium text-background hover:opacity-90 transition-opacity",
|
|
435
470
|
children: "Proceed to Checkout"
|
|
436
471
|
})]
|
|
437
472
|
})] })]
|
|
438
473
|
}),
|
|
439
|
-
|
|
474
|
+
L.serviceTypes?.includes("direct_service") && /* @__PURE__ */ O("div", {
|
|
440
475
|
className: "rounded-lg border border-purple-500/30 bg-purple-500/10 p-4",
|
|
441
476
|
children: [
|
|
442
|
-
/* @__PURE__ */
|
|
477
|
+
/* @__PURE__ */ O("h3", {
|
|
443
478
|
className: "text-sm font-semibold text-text-primary flex items-center gap-2 mb-2",
|
|
444
|
-
children: [/* @__PURE__ */
|
|
479
|
+
children: [/* @__PURE__ */ D(g, { className: "h-4 w-4 text-purple-600 dark:text-purple-400" }), "Direct Service"]
|
|
445
480
|
}),
|
|
446
|
-
/* @__PURE__ */
|
|
481
|
+
/* @__PURE__ */ D("p", {
|
|
447
482
|
className: "text-xs text-text-secondary mb-3",
|
|
448
483
|
children: "Cart comes to your location!"
|
|
449
484
|
}),
|
|
450
|
-
/* @__PURE__ */
|
|
485
|
+
/* @__PURE__ */ D("button", {
|
|
451
486
|
type: "button",
|
|
452
|
-
onClick: () =>
|
|
487
|
+
onClick: () => N(`/customer/carts/${L.id}`),
|
|
453
488
|
className: "w-full rounded-lg bg-purple-600 py-2 text-xs font-medium text-white hover:bg-purple-700 transition-colors",
|
|
454
489
|
children: "Book Direct Service"
|
|
455
490
|
})
|
|
456
491
|
]
|
|
457
492
|
}),
|
|
458
|
-
|
|
493
|
+
L.serviceTypes?.includes("appointment") && /* @__PURE__ */ O("div", {
|
|
459
494
|
className: "rounded-lg border border-blue-500/30 bg-blue-500/10 p-4",
|
|
460
|
-
children: [/* @__PURE__ */
|
|
495
|
+
children: [/* @__PURE__ */ O("h3", {
|
|
461
496
|
className: "text-sm font-semibold text-text-primary flex items-center gap-2 mb-2",
|
|
462
|
-
children: [/* @__PURE__ */
|
|
463
|
-
}), /* @__PURE__ */
|
|
497
|
+
children: [/* @__PURE__ */ D(f, { className: "h-4 w-4 text-blue-600 dark:text-blue-400" }), "Appointments Available"]
|
|
498
|
+
}), /* @__PURE__ */ D("p", {
|
|
464
499
|
className: "text-xs text-text-secondary",
|
|
465
500
|
children: "This service provider accepts appointments. Contact them to schedule."
|
|
466
501
|
})]
|
|
467
502
|
}),
|
|
468
|
-
|
|
503
|
+
R && /* @__PURE__ */ O("div", {
|
|
469
504
|
className: "rounded-lg border border-green-500/30 bg-green-500/10 p-4",
|
|
470
505
|
children: [
|
|
471
|
-
/* @__PURE__ */
|
|
506
|
+
/* @__PURE__ */ O("h3", {
|
|
472
507
|
className: "text-sm font-semibold text-text-primary flex items-center gap-2 mb-2",
|
|
473
|
-
children: [/* @__PURE__ */
|
|
508
|
+
children: [/* @__PURE__ */ D(te, { className: "h-4 w-4 text-green-600 dark:text-green-400" }), "Investment Opportunity"]
|
|
474
509
|
}),
|
|
475
|
-
/* @__PURE__ */
|
|
510
|
+
/* @__PURE__ */ D("p", {
|
|
476
511
|
className: "text-xs text-text-secondary mb-2",
|
|
477
|
-
children:
|
|
512
|
+
children: R.description
|
|
478
513
|
}),
|
|
479
|
-
/* @__PURE__ */
|
|
514
|
+
/* @__PURE__ */ O("div", {
|
|
480
515
|
className: "space-y-1 text-xs text-text-secondary mb-3",
|
|
481
516
|
children: [
|
|
482
|
-
/* @__PURE__ */
|
|
483
|
-
/* @__PURE__ */
|
|
484
|
-
/* @__PURE__ */
|
|
517
|
+
/* @__PURE__ */ O("p", { children: ["Target: ", o(R.targetAmount, { minimumFractionDigits: 0 })] }),
|
|
518
|
+
/* @__PURE__ */ O("p", { children: ["Raised: ", o(R.raisedAmount, { minimumFractionDigits: 0 })] }),
|
|
519
|
+
/* @__PURE__ */ O("p", { children: [
|
|
485
520
|
"Expected Returns: ",
|
|
486
|
-
|
|
521
|
+
R.expectedReturns,
|
|
487
522
|
"%"
|
|
488
523
|
] }),
|
|
489
|
-
/* @__PURE__ */
|
|
524
|
+
/* @__PURE__ */ O("p", { children: [
|
|
490
525
|
"Min Investment:",
|
|
491
526
|
" ",
|
|
492
|
-
|
|
527
|
+
o(R.minimumInvestment, { minimumFractionDigits: 0 })
|
|
493
528
|
] })
|
|
494
529
|
]
|
|
495
530
|
}),
|
|
496
|
-
/* @__PURE__ */
|
|
531
|
+
/* @__PURE__ */ D("button", {
|
|
497
532
|
type: "button",
|
|
498
533
|
onClick: () => alert("Navigate to investor section to fund this business."),
|
|
499
534
|
className: "w-full rounded-lg bg-green-600 py-2 text-xs font-medium text-white hover:bg-green-700 transition-colors",
|
|
@@ -504,76 +539,76 @@ function A() {
|
|
|
504
539
|
]
|
|
505
540
|
})]
|
|
506
541
|
}),
|
|
507
|
-
|
|
542
|
+
G && q && /* @__PURE__ */ D("div", {
|
|
508
543
|
className: "fixed inset-0 z-50 flex items-center justify-center bg-black/50 p-4",
|
|
509
|
-
children: /* @__PURE__ */
|
|
544
|
+
children: /* @__PURE__ */ D("div", {
|
|
510
545
|
className: "w-full max-w-md max-h-[90vh] overflow-y-auto rounded-lg border border-border-subtle bg-bg-surface",
|
|
511
|
-
children: /* @__PURE__ */
|
|
546
|
+
children: /* @__PURE__ */ O("div", {
|
|
512
547
|
className: "p-5",
|
|
513
548
|
children: [
|
|
514
|
-
/* @__PURE__ */
|
|
549
|
+
/* @__PURE__ */ O("div", {
|
|
515
550
|
className: "flex items-center justify-between mb-4",
|
|
516
|
-
children: [/* @__PURE__ */
|
|
551
|
+
children: [/* @__PURE__ */ D("h3", {
|
|
517
552
|
className: "text-lg font-semibold text-text-primary",
|
|
518
|
-
children:
|
|
519
|
-
}), /* @__PURE__ */
|
|
553
|
+
children: q.product.name
|
|
554
|
+
}), /* @__PURE__ */ D("button", {
|
|
520
555
|
type: "button",
|
|
521
556
|
onClick: () => {
|
|
522
|
-
|
|
557
|
+
K(!1), J(null);
|
|
523
558
|
},
|
|
524
559
|
className: "rounded-md p-1 text-text-secondary hover:text-text-primary",
|
|
525
|
-
children: /* @__PURE__ */
|
|
560
|
+
children: /* @__PURE__ */ D(w, { className: "h-5 w-5" })
|
|
526
561
|
})]
|
|
527
562
|
}),
|
|
528
|
-
/* @__PURE__ */
|
|
563
|
+
/* @__PURE__ */ D("p", {
|
|
529
564
|
className: "text-sm text-text-secondary mb-4",
|
|
530
|
-
children:
|
|
565
|
+
children: q.product.description
|
|
531
566
|
}),
|
|
532
|
-
/* @__PURE__ */
|
|
567
|
+
/* @__PURE__ */ D("p", {
|
|
533
568
|
className: "text-lg font-bold text-text-primary mb-4",
|
|
534
|
-
children:
|
|
569
|
+
children: o(q.product.price, { minimumFractionDigits: 0 })
|
|
535
570
|
}),
|
|
536
|
-
/* @__PURE__ */
|
|
571
|
+
/* @__PURE__ */ O("div", {
|
|
537
572
|
className: "mb-4",
|
|
538
|
-
children: [/* @__PURE__ */
|
|
573
|
+
children: [/* @__PURE__ */ D("label", {
|
|
539
574
|
className: "block text-sm font-medium text-text-primary mb-2",
|
|
540
575
|
children: "Quantity"
|
|
541
|
-
}), /* @__PURE__ */
|
|
576
|
+
}), /* @__PURE__ */ O("div", {
|
|
542
577
|
className: "flex items-center gap-3",
|
|
543
578
|
children: [
|
|
544
|
-
/* @__PURE__ */
|
|
579
|
+
/* @__PURE__ */ D("button", {
|
|
545
580
|
type: "button",
|
|
546
|
-
onClick: () =>
|
|
581
|
+
onClick: () => J((e) => e && {
|
|
547
582
|
...e,
|
|
548
583
|
quantity: Math.max(1, e.quantity - 1)
|
|
549
584
|
}),
|
|
550
585
|
className: "flex h-8 w-8 items-center justify-center rounded-full bg-bg-sunken text-text-primary",
|
|
551
|
-
children: /* @__PURE__ */
|
|
586
|
+
children: /* @__PURE__ */ D(y, { className: "h-4 w-4" })
|
|
552
587
|
}),
|
|
553
|
-
/* @__PURE__ */
|
|
588
|
+
/* @__PURE__ */ D("span", {
|
|
554
589
|
className: "min-w-[2ch] text-center font-medium text-text-primary",
|
|
555
|
-
children:
|
|
590
|
+
children: q.quantity
|
|
556
591
|
}),
|
|
557
|
-
/* @__PURE__ */
|
|
592
|
+
/* @__PURE__ */ D("button", {
|
|
558
593
|
type: "button",
|
|
559
|
-
onClick: () =>
|
|
594
|
+
onClick: () => J((e) => e && {
|
|
560
595
|
...e,
|
|
561
596
|
quantity: e.quantity + 1
|
|
562
597
|
}),
|
|
563
598
|
className: "flex h-8 w-8 items-center justify-center rounded-full bg-bg-sunken text-text-primary",
|
|
564
|
-
children: /* @__PURE__ */
|
|
599
|
+
children: /* @__PURE__ */ D(b, { className: "h-4 w-4" })
|
|
565
600
|
})
|
|
566
601
|
]
|
|
567
602
|
})]
|
|
568
603
|
}),
|
|
569
|
-
/* @__PURE__ */
|
|
604
|
+
/* @__PURE__ */ O("div", {
|
|
570
605
|
className: "mb-4",
|
|
571
|
-
children: [/* @__PURE__ */
|
|
606
|
+
children: [/* @__PURE__ */ D("label", {
|
|
572
607
|
className: "block text-sm font-medium text-text-primary mb-2",
|
|
573
608
|
children: "Special Instructions"
|
|
574
|
-
}), /* @__PURE__ */
|
|
575
|
-
value:
|
|
576
|
-
onChange: (e) =>
|
|
609
|
+
}), /* @__PURE__ */ D("textarea", {
|
|
610
|
+
value: q.specialInstructions,
|
|
611
|
+
onChange: (e) => J((t) => t && {
|
|
577
612
|
...t,
|
|
578
613
|
specialInstructions: e.target.value
|
|
579
614
|
}),
|
|
@@ -582,16 +617,16 @@ function A() {
|
|
|
582
617
|
rows: 3
|
|
583
618
|
})]
|
|
584
619
|
}),
|
|
585
|
-
/* @__PURE__ */
|
|
620
|
+
/* @__PURE__ */ O("button", {
|
|
586
621
|
type: "button",
|
|
587
622
|
onClick: () => {
|
|
588
|
-
|
|
623
|
+
q && (oe(q.product, q.quantity, q.specialInstructions), K(!1), J(null), alert(`${q.product.name} added to cart`));
|
|
589
624
|
},
|
|
590
625
|
className: "w-full rounded-lg bg-foreground py-2.5 text-sm font-medium text-background hover:opacity-90 transition-opacity",
|
|
591
626
|
children: [
|
|
592
627
|
"Add to Cart -",
|
|
593
628
|
" ",
|
|
594
|
-
|
|
629
|
+
o(q.product.price * q.quantity, { minimumFractionDigits: 0 })
|
|
595
630
|
]
|
|
596
631
|
})
|
|
597
632
|
]
|
|
@@ -599,15 +634,16 @@ function A() {
|
|
|
599
634
|
})
|
|
600
635
|
})
|
|
601
636
|
]
|
|
602
|
-
}) : /* @__PURE__ */
|
|
637
|
+
}) : /* @__PURE__ */ D(n, {
|
|
603
638
|
title: "Cart Not Found",
|
|
604
|
-
children: /* @__PURE__ */
|
|
605
|
-
|
|
639
|
+
children: /* @__PURE__ */ D(r, {
|
|
640
|
+
illustration: "empty-generic",
|
|
641
|
+
icon: /* @__PURE__ */ D(S, { className: "h-12 w-12" }),
|
|
606
642
|
title: "Cart not found",
|
|
607
|
-
description: `No cart found with ID "${
|
|
608
|
-
action: /* @__PURE__ */
|
|
643
|
+
description: `No cart found with ID "${M}".`,
|
|
644
|
+
action: /* @__PURE__ */ D("button", {
|
|
609
645
|
type: "button",
|
|
610
|
-
onClick: () =>
|
|
646
|
+
onClick: () => N("/customer/carts"),
|
|
611
647
|
className: "rounded-lg bg-foreground px-4 py-2 text-sm font-medium text-background hover:opacity-90 transition-opacity",
|
|
612
648
|
children: "Browse Carts"
|
|
613
649
|
})
|
|
@@ -615,6 +651,6 @@ function A() {
|
|
|
615
651
|
});
|
|
616
652
|
}
|
|
617
653
|
//#endregion
|
|
618
|
-
export {
|
|
654
|
+
export { M as CartDetailPage };
|
|
619
655
|
|
|
620
656
|
//# sourceMappingURL=CartDetailPage.js.map
|