@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
|
@@ -1,22 +1,24 @@
|
|
|
1
1
|
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
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
4
|
+
import { EmptyState as r } from "../../components/EmptyState.js";
|
|
5
|
+
import { useDashboardStats as i, useOrders as a, useProviders as o } from "../../hooks/useAthleteBridgeApi.js";
|
|
6
|
+
import { formatCurrency as s } from "../../utils/formatters.js";
|
|
7
|
+
import { useCallback as c } from "react";
|
|
8
|
+
import { useI18n as l } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
|
|
9
|
+
import { ArrowRight as u, Clock as d, CreditCard as f, Heart as p, Lightbulb as m, MapPin as h, Navigation as g, Package as _, Search as v, Star as y, TrendingUp as b, User as x, Zap as S } from "lucide-react";
|
|
9
10
|
import { jsx as C, jsxs as w } from "react/jsx-runtime";
|
|
11
|
+
import { EmphasisPanel as T, NextSteps as E, PagePurpose as D } from "@burdenoff/fe-libs/ui";
|
|
10
12
|
//#region src/atheletebridge/pages/customer/CustomerDashboard.tsx
|
|
11
|
-
function
|
|
13
|
+
function O() {
|
|
12
14
|
let e = (/* @__PURE__ */ new Date()).getHours();
|
|
13
15
|
return e < 12 ? "Good morning" : e < 17 ? "Good afternoon" : "Good evening";
|
|
14
16
|
}
|
|
15
|
-
function
|
|
16
|
-
let { navigateTo:
|
|
17
|
-
let n =
|
|
17
|
+
function k() {
|
|
18
|
+
let { navigateTo: k, currentUser: A } = e(), { t: j } = l(), { data: M = [], isLoading: N } = a({ customerId: A?.id }), { data: P = [], isLoading: F } = o(), { data: I, isLoading: L } = i(), R = N || F || L, z = c((e, t) => {
|
|
19
|
+
let n = j(e);
|
|
18
20
|
return n === e ? t : n;
|
|
19
|
-
}, [
|
|
21
|
+
}, [j]), B = A?.firstName ?? A?.name ?? "Customer", V = [
|
|
20
22
|
{
|
|
21
23
|
id: "1",
|
|
22
24
|
type: "suggestion",
|
|
@@ -41,12 +43,12 @@ function E() {
|
|
|
41
43
|
confidence: 88,
|
|
42
44
|
action: "View Carts"
|
|
43
45
|
}
|
|
44
|
-
],
|
|
45
|
-
totalOrders:
|
|
46
|
-
totalSpent:
|
|
46
|
+
], H = M.slice(0, 3), U = P.slice(0, 3), W = {
|
|
47
|
+
totalOrders: M.length,
|
|
48
|
+
totalSpent: M.reduce((e, t) => e + t.total, 0),
|
|
47
49
|
favoriteCount: 6,
|
|
48
50
|
avgRating: 4.5
|
|
49
|
-
},
|
|
51
|
+
}, G = (e) => {
|
|
50
52
|
switch (e) {
|
|
51
53
|
case "delivered": return "bg-green-500/20 text-green-600 dark:text-green-400";
|
|
52
54
|
case "preparing": return "bg-yellow-500/20 text-yellow-600 dark:text-yellow-400";
|
|
@@ -55,14 +57,14 @@ function E() {
|
|
|
55
57
|
case "cancelled": return "bg-red-500/20 text-red-600 dark:text-red-400";
|
|
56
58
|
default: return "bg-bg-sunken text-text-secondary";
|
|
57
59
|
}
|
|
58
|
-
},
|
|
60
|
+
}, K = (e) => {
|
|
59
61
|
switch (e) {
|
|
60
|
-
case "suggestion": return /* @__PURE__ */ C(
|
|
62
|
+
case "suggestion": return /* @__PURE__ */ C(m, { className: "h-4 w-4" });
|
|
61
63
|
case "opportunity": return /* @__PURE__ */ C(b, { className: "h-4 w-4" });
|
|
62
64
|
case "trend": return /* @__PURE__ */ C(S, { className: "h-4 w-4" });
|
|
63
|
-
default: return /* @__PURE__ */ C(
|
|
65
|
+
default: return /* @__PURE__ */ C(m, { className: "h-4 w-4" });
|
|
64
66
|
}
|
|
65
|
-
},
|
|
67
|
+
}, q = (e) => {
|
|
66
68
|
switch (e) {
|
|
67
69
|
case "suggestion": return "bg-blue-500/10 text-blue-600 dark:text-blue-400 border-blue-500/20";
|
|
68
70
|
case "opportunity": return "bg-green-500/10 text-green-600 dark:text-green-400 border-green-500/20";
|
|
@@ -70,427 +72,468 @@ function E() {
|
|
|
70
72
|
default: return "bg-bg-sunken text-text-secondary border-border-subtle";
|
|
71
73
|
}
|
|
72
74
|
};
|
|
73
|
-
return
|
|
74
|
-
title:
|
|
75
|
+
return R ? /* @__PURE__ */ C(n, {
|
|
76
|
+
title: z("atheletebridge.customerDashboard.title", "Dashboard"),
|
|
75
77
|
children: /* @__PURE__ */ C("div", {
|
|
76
78
|
className: "flex items-center justify-center py-20",
|
|
77
79
|
children: /* @__PURE__ */ w("div", {
|
|
78
80
|
className: "text-center",
|
|
79
81
|
children: [/* @__PURE__ */ C("div", { className: "mx-auto mb-4 h-12 w-12 animate-spin rounded-full border-b-2 border-foreground" }), /* @__PURE__ */ C("p", {
|
|
80
82
|
className: "text-sm text-text-secondary",
|
|
81
|
-
children:
|
|
83
|
+
children: z("atheletebridge.customerDashboard.loading", "Loading your dashboard...")
|
|
82
84
|
})]
|
|
83
85
|
})
|
|
84
86
|
})
|
|
85
87
|
}) : /* @__PURE__ */ w(n, {
|
|
86
|
-
title:
|
|
87
|
-
description: `${
|
|
88
|
-
children: [
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
}),
|
|
123
|
-
/* @__PURE__ */ C("div", {
|
|
124
|
-
className: "rounded-lg border border-border-subtle bg-bg-surface p-4",
|
|
125
|
-
children: /* @__PURE__ */ w("div", {
|
|
126
|
-
className: "flex items-center gap-3",
|
|
127
|
-
children: [/* @__PURE__ */ C("div", {
|
|
128
|
-
className: "flex h-10 w-10 items-center justify-center rounded-lg bg-bg-sunken",
|
|
129
|
-
children: /* @__PURE__ */ C(f, { className: "h-5 w-5 text-text-secondary" })
|
|
130
|
-
}), /* @__PURE__ */ w("div", { children: [/* @__PURE__ */ C("p", {
|
|
131
|
-
className: "text-2xl font-bold text-text-primary",
|
|
132
|
-
children: V.favoriteCount
|
|
133
|
-
}), /* @__PURE__ */ C("p", {
|
|
134
|
-
className: "text-xs text-text-secondary",
|
|
135
|
-
children: I("atheletebridge.customerDashboard.favoriteCarts", "Favorite Carts")
|
|
136
|
-
})] })]
|
|
137
|
-
})
|
|
138
|
-
}),
|
|
139
|
-
/* @__PURE__ */ C("div", {
|
|
140
|
-
className: "rounded-lg border border-border-subtle bg-bg-surface p-4",
|
|
141
|
-
children: /* @__PURE__ */ w("div", {
|
|
142
|
-
className: "flex items-center gap-3",
|
|
143
|
-
children: [/* @__PURE__ */ C("div", {
|
|
144
|
-
className: "flex h-10 w-10 items-center justify-center rounded-lg bg-bg-sunken",
|
|
145
|
-
children: /* @__PURE__ */ C(y, { className: "h-5 w-5 text-text-secondary" })
|
|
146
|
-
}), /* @__PURE__ */ w("div", { children: [/* @__PURE__ */ C("p", {
|
|
147
|
-
className: "text-2xl font-bold text-text-primary",
|
|
148
|
-
children: V.avgRating.toFixed(1)
|
|
149
|
-
}), /* @__PURE__ */ C("p", {
|
|
150
|
-
className: "text-xs text-text-secondary",
|
|
151
|
-
children: I("atheletebridge.customerDashboard.avgRatingGiven", "Avg Rating Given")
|
|
152
|
-
})] })]
|
|
153
|
-
})
|
|
154
|
-
})
|
|
155
|
-
]
|
|
156
|
-
}), /* @__PURE__ */ w("div", {
|
|
157
|
-
className: "mt-8 grid grid-cols-1 gap-8 lg:grid-cols-3",
|
|
158
|
-
children: [/* @__PURE__ */ w("div", {
|
|
159
|
-
className: "lg:col-span-2 space-y-8",
|
|
88
|
+
title: z("atheletebridge.customerDashboard.welcomeBack", "Welcome Back!"),
|
|
89
|
+
description: `${O()}, ${B}`,
|
|
90
|
+
children: [
|
|
91
|
+
/* @__PURE__ */ C(D, {
|
|
92
|
+
className: "mb-6",
|
|
93
|
+
children: z("atheletebridge.customerDashboard.purpose", "Your home base as a customer: see how much you have ordered and spent, pick up where you left off with recent orders, and discover carts recommended near you. Start here to find a service and place your next order.")
|
|
94
|
+
}),
|
|
95
|
+
/* @__PURE__ */ C(E, {
|
|
96
|
+
className: "mb-6",
|
|
97
|
+
storageKey: "atheletebridge-customer-dashboard",
|
|
98
|
+
steps: [
|
|
99
|
+
{
|
|
100
|
+
id: "discover",
|
|
101
|
+
label: z("atheletebridge.customerDashboard.step.discover", "Discover carts near you"),
|
|
102
|
+
description: z("atheletebridge.customerDashboard.step.discoverDesc", "Browse open service providers around your location."),
|
|
103
|
+
icon: /* @__PURE__ */ C(v, { className: "h-4 w-4" }),
|
|
104
|
+
onClick: () => k("/customer/carts")
|
|
105
|
+
},
|
|
106
|
+
{
|
|
107
|
+
id: "address",
|
|
108
|
+
label: z("atheletebridge.customerDashboard.step.address", "Add a delivery address"),
|
|
109
|
+
description: z("atheletebridge.customerDashboard.step.addressDesc", "Save where you want orders delivered for faster checkout."),
|
|
110
|
+
icon: /* @__PURE__ */ C(h, { className: "h-4 w-4" }),
|
|
111
|
+
onClick: () => k("/customer/addresses")
|
|
112
|
+
},
|
|
113
|
+
{
|
|
114
|
+
id: "payment",
|
|
115
|
+
label: z("atheletebridge.customerDashboard.step.payment", "Set up a payment method"),
|
|
116
|
+
description: z("atheletebridge.customerDashboard.step.paymentDesc", "Add a card or wallet so you can check out in one tap."),
|
|
117
|
+
icon: /* @__PURE__ */ C(f, { className: "h-4 w-4" }),
|
|
118
|
+
onClick: () => k("/customer/payment-methods")
|
|
119
|
+
}
|
|
120
|
+
]
|
|
121
|
+
}),
|
|
122
|
+
W && /* @__PURE__ */ w("div", {
|
|
123
|
+
className: "grid grid-cols-1 gap-4 sm:grid-cols-2 lg:grid-cols-4",
|
|
160
124
|
children: [
|
|
161
|
-
/* @__PURE__ */
|
|
162
|
-
className: "
|
|
163
|
-
children:
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
125
|
+
/* @__PURE__ */ C("div", {
|
|
126
|
+
className: "rounded-lg border border-border-subtle bg-bg-surface p-4",
|
|
127
|
+
children: /* @__PURE__ */ w("div", {
|
|
128
|
+
className: "flex items-center gap-3",
|
|
129
|
+
children: [/* @__PURE__ */ C("div", {
|
|
130
|
+
className: "flex h-10 w-10 items-center justify-center rounded-lg bg-bg-sunken",
|
|
131
|
+
children: /* @__PURE__ */ C(_, { className: "h-5 w-5 text-text-secondary" })
|
|
132
|
+
}), /* @__PURE__ */ w("div", { children: [/* @__PURE__ */ C("p", {
|
|
133
|
+
className: "text-2xl font-bold text-text-primary",
|
|
134
|
+
children: W.totalOrders
|
|
135
|
+
}), /* @__PURE__ */ C("p", {
|
|
136
|
+
className: "text-xs text-text-secondary",
|
|
137
|
+
children: z("atheletebridge.customerDashboard.totalOrders", "Total Orders")
|
|
138
|
+
})] })]
|
|
139
|
+
})
|
|
140
|
+
}),
|
|
141
|
+
/* @__PURE__ */ C("div", {
|
|
142
|
+
className: "rounded-lg border border-border-subtle bg-bg-surface p-4",
|
|
143
|
+
children: /* @__PURE__ */ w("div", {
|
|
144
|
+
className: "flex items-center gap-3",
|
|
145
|
+
children: [/* @__PURE__ */ C("div", {
|
|
146
|
+
className: "flex h-10 w-10 items-center justify-center rounded-lg bg-bg-sunken",
|
|
147
|
+
children: /* @__PURE__ */ C(f, { className: "h-5 w-5 text-text-secondary" })
|
|
148
|
+
}), /* @__PURE__ */ w("div", { children: [/* @__PURE__ */ C("p", {
|
|
149
|
+
className: "text-2xl font-bold text-text-primary",
|
|
150
|
+
children: s(W.totalSpent, { minimumFractionDigits: 0 })
|
|
151
|
+
}), /* @__PURE__ */ C("p", {
|
|
152
|
+
className: "text-xs text-text-secondary",
|
|
153
|
+
children: z("atheletebridge.customerDashboard.totalSpent", "Total Spent")
|
|
154
|
+
})] })]
|
|
155
|
+
})
|
|
156
|
+
}),
|
|
157
|
+
/* @__PURE__ */ C("div", {
|
|
158
|
+
className: "rounded-lg border border-border-subtle bg-bg-surface p-4",
|
|
159
|
+
children: /* @__PURE__ */ w("div", {
|
|
160
|
+
className: "flex items-center gap-3",
|
|
161
|
+
children: [/* @__PURE__ */ C("div", {
|
|
162
|
+
className: "flex h-10 w-10 items-center justify-center rounded-lg bg-bg-sunken",
|
|
163
|
+
children: /* @__PURE__ */ C(p, { className: "h-5 w-5 text-text-secondary" })
|
|
164
|
+
}), /* @__PURE__ */ w("div", { children: [/* @__PURE__ */ C("p", {
|
|
165
|
+
className: "text-2xl font-bold text-text-primary",
|
|
166
|
+
children: W.favoriteCount
|
|
167
|
+
}), /* @__PURE__ */ C("p", {
|
|
168
|
+
className: "text-xs text-text-secondary",
|
|
169
|
+
children: z("atheletebridge.customerDashboard.favoriteCarts", "Favorite Carts")
|
|
170
|
+
})] })]
|
|
171
|
+
})
|
|
172
|
+
}),
|
|
173
|
+
/* @__PURE__ */ C("div", {
|
|
174
|
+
className: "rounded-lg border border-border-subtle bg-bg-surface p-4",
|
|
175
|
+
children: /* @__PURE__ */ w("div", {
|
|
176
|
+
className: "flex items-center gap-3",
|
|
177
|
+
children: [/* @__PURE__ */ C("div", {
|
|
178
|
+
className: "flex h-10 w-10 items-center justify-center rounded-lg bg-bg-sunken",
|
|
179
|
+
children: /* @__PURE__ */ C(y, { className: "h-5 w-5 text-text-secondary" })
|
|
180
|
+
}), /* @__PURE__ */ w("div", { children: [/* @__PURE__ */ C("p", {
|
|
181
|
+
className: "text-2xl font-bold text-text-primary",
|
|
182
|
+
children: W.avgRating.toFixed(1)
|
|
183
|
+
}), /* @__PURE__ */ C("p", {
|
|
184
|
+
className: "text-xs text-text-secondary",
|
|
185
|
+
children: z("atheletebridge.customerDashboard.avgRatingGiven", "Avg Rating Given")
|
|
186
|
+
})] })]
|
|
187
|
+
})
|
|
188
|
+
})
|
|
189
|
+
]
|
|
190
|
+
}),
|
|
191
|
+
/* @__PURE__ */ w("div", {
|
|
192
|
+
className: "mt-8 grid grid-cols-1 gap-8 lg:grid-cols-3",
|
|
193
|
+
children: [/* @__PURE__ */ w("div", {
|
|
194
|
+
className: "lg:col-span-2 space-y-8",
|
|
195
|
+
children: [
|
|
196
|
+
/* @__PURE__ */ w("section", { children: [/* @__PURE__ */ C("h2", {
|
|
197
|
+
className: "text-lg font-semibold text-text-primary mb-4",
|
|
198
|
+
children: z("atheletebridge.customerDashboard.quickActions", "Quick Actions")
|
|
199
|
+
}), /* @__PURE__ */ w("div", {
|
|
200
|
+
className: "grid grid-cols-1 gap-3 sm:grid-cols-3",
|
|
201
|
+
children: [
|
|
202
|
+
/* @__PURE__ */ w("button", {
|
|
203
|
+
type: "button",
|
|
204
|
+
onClick: () => k("/customer/carts"),
|
|
205
|
+
className: t("flex items-center gap-3 rounded-lg border border-border-subtle bg-bg-surface p-4 shadow-sm transition-colors text-left", "hover:bg-accent hover:shadow-md"),
|
|
206
|
+
children: [/* @__PURE__ */ C("div", {
|
|
207
|
+
className: "flex h-10 w-10 shrink-0 items-center justify-center rounded-lg bg-blue-500/10",
|
|
208
|
+
children: /* @__PURE__ */ C(v, { className: "h-5 w-5 text-blue-600 dark:text-blue-400" })
|
|
209
|
+
}), /* @__PURE__ */ w("div", {
|
|
210
|
+
className: "min-w-0",
|
|
211
|
+
children: [/* @__PURE__ */ C("p", {
|
|
212
|
+
className: "text-sm font-semibold text-text-primary",
|
|
213
|
+
children: z("atheletebridge.customerDashboard.discoverCarts", "Discover Carts")
|
|
214
|
+
}), /* @__PURE__ */ C("p", {
|
|
215
|
+
className: "text-xs text-text-secondary",
|
|
216
|
+
children: z("atheletebridge.customerDashboard.findNearbyCarts", "Find nearby carts")
|
|
217
|
+
})]
|
|
182
218
|
})]
|
|
183
|
-
})
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
219
|
+
}),
|
|
220
|
+
/* @__PURE__ */ w("button", {
|
|
221
|
+
type: "button",
|
|
222
|
+
onClick: () => k("/customer/orders"),
|
|
223
|
+
className: t("flex items-center gap-3 rounded-lg border border-border-subtle bg-bg-surface p-4 shadow-sm transition-colors text-left", "hover:bg-accent hover:shadow-md"),
|
|
224
|
+
children: [/* @__PURE__ */ C("div", {
|
|
225
|
+
className: "flex h-10 w-10 shrink-0 items-center justify-center rounded-lg bg-green-500/10",
|
|
226
|
+
children: /* @__PURE__ */ C(d, { className: "h-5 w-5 text-green-600 dark:text-green-400" })
|
|
227
|
+
}), /* @__PURE__ */ w("div", {
|
|
228
|
+
className: "min-w-0",
|
|
229
|
+
children: [/* @__PURE__ */ C("p", {
|
|
230
|
+
className: "text-sm font-semibold text-text-primary",
|
|
231
|
+
children: z("atheletebridge.customerDashboard.orderHistory", "Order History")
|
|
232
|
+
}), /* @__PURE__ */ C("p", {
|
|
233
|
+
className: "text-xs text-text-secondary",
|
|
234
|
+
children: z("atheletebridge.customerDashboard.viewPastOrders", "View past orders")
|
|
235
|
+
})]
|
|
200
236
|
})]
|
|
201
|
-
})
|
|
202
|
-
|
|
203
|
-
|
|
237
|
+
}),
|
|
238
|
+
/* @__PURE__ */ w("button", {
|
|
239
|
+
type: "button",
|
|
240
|
+
onClick: () => k("/customer/favorites"),
|
|
241
|
+
className: t("flex items-center gap-3 rounded-lg border border-border-subtle bg-bg-surface p-4 shadow-sm transition-colors text-left", "hover:bg-accent hover:shadow-md"),
|
|
242
|
+
children: [/* @__PURE__ */ C("div", {
|
|
243
|
+
className: "flex h-10 w-10 shrink-0 items-center justify-center rounded-lg bg-red-500/10",
|
|
244
|
+
children: /* @__PURE__ */ C(p, { className: "h-5 w-5 text-red-600 dark:text-red-400" })
|
|
245
|
+
}), /* @__PURE__ */ w("div", {
|
|
246
|
+
className: "min-w-0",
|
|
247
|
+
children: [/* @__PURE__ */ C("p", {
|
|
248
|
+
className: "text-sm font-semibold text-text-primary",
|
|
249
|
+
children: z("atheletebridge.customerDashboard.favorites", "Favorites")
|
|
250
|
+
}), /* @__PURE__ */ C("p", {
|
|
251
|
+
className: "text-xs text-text-secondary",
|
|
252
|
+
children: z("atheletebridge.customerDashboard.savedCarts", "Saved carts")
|
|
253
|
+
})]
|
|
254
|
+
})]
|
|
255
|
+
})
|
|
256
|
+
]
|
|
257
|
+
})] }),
|
|
258
|
+
/* @__PURE__ */ w("section", { children: [/* @__PURE__ */ w("div", {
|
|
259
|
+
className: "flex items-center justify-between mb-4",
|
|
260
|
+
children: [/* @__PURE__ */ C("h2", {
|
|
261
|
+
className: "text-lg font-semibold text-text-primary",
|
|
262
|
+
children: z("atheletebridge.customerDashboard.recentOrders", "Recent Orders")
|
|
263
|
+
}), /* @__PURE__ */ w("button", {
|
|
204
264
|
type: "button",
|
|
205
|
-
onClick: () =>
|
|
206
|
-
className:
|
|
207
|
-
children: [/* @__PURE__ */ C("
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
className: "
|
|
217
|
-
children:
|
|
265
|
+
onClick: () => k("/customer/orders"),
|
|
266
|
+
className: "flex items-center gap-1 text-sm font-medium text-text-secondary hover:text-text-primary transition-colors",
|
|
267
|
+
children: [z("atheletebridge.common.viewAll", "View All"), /* @__PURE__ */ C(u, { className: "h-4 w-4" })]
|
|
268
|
+
})]
|
|
269
|
+
}), H.length > 0 ? /* @__PURE__ */ C("div", {
|
|
270
|
+
className: "space-y-3",
|
|
271
|
+
children: H.map((e) => /* @__PURE__ */ C("div", {
|
|
272
|
+
className: "rounded-lg border border-border-subtle bg-bg-surface p-4",
|
|
273
|
+
children: /* @__PURE__ */ w("div", {
|
|
274
|
+
className: "flex flex-col sm:flex-row sm:items-start sm:justify-between gap-3",
|
|
275
|
+
children: [/* @__PURE__ */ w("div", {
|
|
276
|
+
className: "flex-1 min-w-0",
|
|
277
|
+
children: [
|
|
278
|
+
/* @__PURE__ */ w("div", {
|
|
279
|
+
className: "flex flex-wrap items-center gap-2 mb-1",
|
|
280
|
+
children: [/* @__PURE__ */ C("h3", {
|
|
281
|
+
className: "text-sm font-semibold text-text-primary",
|
|
282
|
+
children: e.cartName
|
|
283
|
+
}), /* @__PURE__ */ C("span", {
|
|
284
|
+
className: t("inline-flex items-center rounded-full px-2 py-0.5 text-xs font-medium capitalize", G(e.status)),
|
|
285
|
+
children: e.status.replace(/_/g, " ")
|
|
286
|
+
})]
|
|
287
|
+
}),
|
|
288
|
+
/* @__PURE__ */ C("p", {
|
|
289
|
+
className: "text-xs text-text-secondary mb-2 leading-relaxed",
|
|
290
|
+
children: e.items.map((e) => `${e.name} (${e.quantity})`).join(", ")
|
|
291
|
+
}),
|
|
292
|
+
/* @__PURE__ */ w("div", {
|
|
293
|
+
className: "flex flex-wrap items-center gap-3 text-xs text-text-secondary",
|
|
294
|
+
children: [
|
|
295
|
+
/* @__PURE__ */ C("span", {
|
|
296
|
+
className: "font-medium text-text-primary",
|
|
297
|
+
children: s(e.total, { minimumFractionDigits: 0 })
|
|
298
|
+
}),
|
|
299
|
+
/* @__PURE__ */ C("span", { children: new Date(e.orderDate).toLocaleDateString() }),
|
|
300
|
+
e.rating && /* @__PURE__ */ w("span", {
|
|
301
|
+
className: "flex items-center gap-1",
|
|
302
|
+
children: [/* @__PURE__ */ C(y, { className: "h-3 w-3 fill-yellow-400 text-yellow-400" }), e.rating]
|
|
303
|
+
})
|
|
304
|
+
]
|
|
305
|
+
})
|
|
306
|
+
]
|
|
307
|
+
}), /* @__PURE__ */ C("button", {
|
|
308
|
+
type: "button",
|
|
309
|
+
onClick: () => k(`/customer/orders/${e.id}`),
|
|
310
|
+
className: "rounded-lg border border-border-subtle px-3 py-1.5 text-xs font-medium text-text-primary hover:bg-accent transition-colors",
|
|
311
|
+
children: z("atheletebridge.customerDashboard.viewDetails", "View Details")
|
|
218
312
|
})]
|
|
219
|
-
})
|
|
313
|
+
})
|
|
314
|
+
}, e.id))
|
|
315
|
+
}) : /* @__PURE__ */ C("div", {
|
|
316
|
+
className: "rounded-lg border border-border-subtle bg-bg-surface",
|
|
317
|
+
children: /* @__PURE__ */ C(r, {
|
|
318
|
+
illustration: "empty-data",
|
|
319
|
+
title: z("atheletebridge.customerDashboard.noRecentOrders", "No recent orders"),
|
|
320
|
+
description: z("atheletebridge.customerDashboard.noRecentOrdersDesc", "Your orders will appear here once you place your first one. Discover a cart to get started."),
|
|
321
|
+
action: /* @__PURE__ */ w("button", {
|
|
322
|
+
type: "button",
|
|
323
|
+
onClick: () => k("/customer/carts"),
|
|
324
|
+
className: "inline-flex items-center gap-1.5 rounded-lg bg-action-primary-bg px-4 py-2 text-sm font-medium text-action-primary-text hover:bg-action-primary-bg/90 transition-colors",
|
|
325
|
+
children: [/* @__PURE__ */ C(v, { className: "h-4 w-4" }), z("atheletebridge.customerDashboard.discoverCarts", "Discover Carts")]
|
|
326
|
+
})
|
|
220
327
|
})
|
|
221
|
-
]
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
className: "
|
|
227
|
-
children:
|
|
228
|
-
|
|
229
|
-
type: "button",
|
|
230
|
-
onClick: () => E("/customer/orders"),
|
|
231
|
-
className: "flex items-center gap-1 text-sm font-medium text-text-secondary hover:text-text-primary transition-colors",
|
|
232
|
-
children: [I("atheletebridge.common.viewAll", "View All"), /* @__PURE__ */ C(l, { className: "h-4 w-4" })]
|
|
233
|
-
})]
|
|
234
|
-
}), z.length > 0 ? /* @__PURE__ */ C("div", {
|
|
235
|
-
className: "space-y-3",
|
|
236
|
-
children: z.map((e) => /* @__PURE__ */ C("div", {
|
|
237
|
-
className: "rounded-lg border border-border-subtle bg-bg-surface p-4",
|
|
238
|
-
children: /* @__PURE__ */ w("div", {
|
|
239
|
-
className: "flex flex-col sm:flex-row sm:items-start sm:justify-between gap-3",
|
|
328
|
+
})] }),
|
|
329
|
+
/* @__PURE__ */ w("section", { children: [/* @__PURE__ */ C("h2", {
|
|
330
|
+
className: "text-lg font-semibold text-text-primary mb-4",
|
|
331
|
+
children: z("atheletebridge.customerDashboard.recommendedForYou", "Recommended for You")
|
|
332
|
+
}), /* @__PURE__ */ C("div", {
|
|
333
|
+
className: "grid grid-cols-1 gap-4 sm:grid-cols-2",
|
|
334
|
+
children: U.map((e) => /* @__PURE__ */ w("div", {
|
|
335
|
+
className: "rounded-lg border border-border-subtle bg-bg-surface overflow-hidden shadow-sm hover:shadow-md transition-shadow",
|
|
240
336
|
children: [/* @__PURE__ */ w("div", {
|
|
241
|
-
className: "
|
|
337
|
+
className: "relative h-40",
|
|
338
|
+
children: [/* @__PURE__ */ C("img", {
|
|
339
|
+
src: e.image,
|
|
340
|
+
alt: e.name,
|
|
341
|
+
className: "h-full w-full object-cover"
|
|
342
|
+
}), /* @__PURE__ */ C("div", {
|
|
343
|
+
className: "absolute top-2 right-2",
|
|
344
|
+
children: /* @__PURE__ */ C("span", {
|
|
345
|
+
className: t("inline-flex items-center rounded-full px-2 py-0.5 text-xs font-medium", e.isOpen ? "bg-green-500/20 text-green-600 dark:text-green-400" : "bg-red-500/20 text-red-600 dark:text-red-400"),
|
|
346
|
+
children: e.isOpen ? z("atheletebridge.customerDashboard.open", "Open") : z("atheletebridge.customerDashboard.closed", "Closed")
|
|
347
|
+
})
|
|
348
|
+
})]
|
|
349
|
+
}), /* @__PURE__ */ w("div", {
|
|
350
|
+
className: "p-4",
|
|
242
351
|
children: [
|
|
243
352
|
/* @__PURE__ */ w("div", {
|
|
244
|
-
className: "flex
|
|
245
|
-
children: [/* @__PURE__ */
|
|
246
|
-
className: "
|
|
247
|
-
children:
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
353
|
+
className: "flex items-start justify-between mb-2",
|
|
354
|
+
children: [/* @__PURE__ */ w("div", {
|
|
355
|
+
className: "min-w-0 flex-1",
|
|
356
|
+
children: [/* @__PURE__ */ C("h3", {
|
|
357
|
+
className: "text-sm font-semibold text-text-primary",
|
|
358
|
+
children: e.name
|
|
359
|
+
}), /* @__PURE__ */ C("p", {
|
|
360
|
+
className: "text-xs text-text-secondary",
|
|
361
|
+
children: e.category
|
|
362
|
+
})]
|
|
363
|
+
}), /* @__PURE__ */ w("div", {
|
|
364
|
+
className: "flex items-center gap-1 text-xs",
|
|
365
|
+
children: [/* @__PURE__ */ C(y, { className: "h-3 w-3 fill-yellow-400 text-yellow-400" }), /* @__PURE__ */ C("span", {
|
|
366
|
+
className: "font-medium text-text-primary",
|
|
367
|
+
children: e.rating
|
|
368
|
+
})]
|
|
251
369
|
})]
|
|
252
370
|
}),
|
|
253
|
-
/* @__PURE__ */ C("p", {
|
|
254
|
-
className: "text-xs text-text-secondary mb-2 leading-relaxed",
|
|
255
|
-
children: e.items.map((e) => `${e.name} (${e.quantity})`).join(", ")
|
|
256
|
-
}),
|
|
257
371
|
/* @__PURE__ */ w("div", {
|
|
258
|
-
className: "flex
|
|
372
|
+
className: "flex items-center gap-3 text-xs text-text-secondary mb-3",
|
|
373
|
+
children: [/* @__PURE__ */ w("span", {
|
|
374
|
+
className: "flex items-center gap-1",
|
|
375
|
+
children: [
|
|
376
|
+
/* @__PURE__ */ C(h, { className: "h-3 w-3" }),
|
|
377
|
+
e.distance,
|
|
378
|
+
"km away"
|
|
379
|
+
]
|
|
380
|
+
}), /* @__PURE__ */ w("span", {
|
|
381
|
+
className: "flex items-center gap-1",
|
|
382
|
+
children: [
|
|
383
|
+
/* @__PURE__ */ C(d, { className: "h-3 w-3" }),
|
|
384
|
+
e.estimatedTime,
|
|
385
|
+
" mins"
|
|
386
|
+
]
|
|
387
|
+
})]
|
|
388
|
+
}),
|
|
389
|
+
/* @__PURE__ */ C("button", {
|
|
390
|
+
type: "button",
|
|
391
|
+
disabled: !e.isOpen,
|
|
392
|
+
onClick: () => e.isOpen && k(`/customer/carts/${e.id}`),
|
|
393
|
+
className: t("w-full rounded-lg py-2 text-sm font-medium transition-opacity", e.isOpen ? "bg-foreground text-background hover:opacity-90" : "bg-bg-sunken text-text-secondary cursor-not-allowed"),
|
|
394
|
+
children: e.isOpen ? z("atheletebridge.customerDashboard.viewMenu", "View Menu") : z("atheletebridge.customerDashboard.currentlyClosed", "Currently Closed")
|
|
395
|
+
})
|
|
396
|
+
]
|
|
397
|
+
})]
|
|
398
|
+
}, e.id))
|
|
399
|
+
})] })
|
|
400
|
+
]
|
|
401
|
+
}), /* @__PURE__ */ w("div", {
|
|
402
|
+
className: "space-y-6",
|
|
403
|
+
children: [
|
|
404
|
+
/* @__PURE__ */ w(T, {
|
|
405
|
+
className: "p-5",
|
|
406
|
+
children: [/* @__PURE__ */ C("h3", {
|
|
407
|
+
className: "text-base font-semibold text-text-primary mb-4",
|
|
408
|
+
children: z("atheletebridge.customerDashboard.personalizedRecommendations", "Personalized Recommendations")
|
|
409
|
+
}), /* @__PURE__ */ C("div", {
|
|
410
|
+
className: "space-y-3",
|
|
411
|
+
children: V.map((e) => /* @__PURE__ */ C("div", {
|
|
412
|
+
className: t("rounded-lg border p-3", q(e.type)),
|
|
413
|
+
children: /* @__PURE__ */ w("div", {
|
|
414
|
+
className: "flex items-start gap-2",
|
|
415
|
+
children: [/* @__PURE__ */ C("div", {
|
|
416
|
+
className: "mt-0.5 shrink-0",
|
|
417
|
+
children: K(e.type)
|
|
418
|
+
}), /* @__PURE__ */ w("div", {
|
|
419
|
+
className: "flex-1 min-w-0",
|
|
259
420
|
children: [
|
|
260
|
-
/* @__PURE__ */
|
|
261
|
-
className: "
|
|
262
|
-
children:
|
|
421
|
+
/* @__PURE__ */ w("div", {
|
|
422
|
+
className: "flex items-center justify-between gap-2",
|
|
423
|
+
children: [/* @__PURE__ */ C("p", {
|
|
424
|
+
className: "text-xs font-semibold",
|
|
425
|
+
children: e.title
|
|
426
|
+
}), /* @__PURE__ */ w("span", {
|
|
427
|
+
className: "text-[10px] opacity-70",
|
|
428
|
+
children: [e.confidence, "%"]
|
|
429
|
+
})]
|
|
263
430
|
}),
|
|
264
|
-
/* @__PURE__ */ C("
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
431
|
+
/* @__PURE__ */ C("p", {
|
|
432
|
+
className: "mt-1 text-xs opacity-80 leading-relaxed",
|
|
433
|
+
children: e.description
|
|
434
|
+
}),
|
|
435
|
+
/* @__PURE__ */ C("button", {
|
|
436
|
+
type: "button",
|
|
437
|
+
onClick: () => k("/customer/carts"),
|
|
438
|
+
className: "mt-2 text-[10px] font-semibold underline underline-offset-2",
|
|
439
|
+
children: e.action
|
|
268
440
|
})
|
|
269
441
|
]
|
|
270
|
-
})
|
|
271
|
-
]
|
|
272
|
-
}), /* @__PURE__ */ C("button", {
|
|
273
|
-
type: "button",
|
|
274
|
-
onClick: () => E(`/customer/orders/${e.id}`),
|
|
275
|
-
className: "rounded-lg border border-border-subtle px-3 py-1.5 text-xs font-medium text-text-primary hover:bg-accent transition-colors",
|
|
276
|
-
children: I("atheletebridge.customerDashboard.viewDetails", "View Details")
|
|
277
|
-
})]
|
|
278
|
-
})
|
|
279
|
-
}, e.id))
|
|
280
|
-
}) : /* @__PURE__ */ w("div", {
|
|
281
|
-
className: "rounded-lg border border-border-subtle bg-bg-surface p-8 text-center",
|
|
282
|
-
children: [/* @__PURE__ */ C(v, { className: "mx-auto h-10 w-10 text-text-secondary/50" }), /* @__PURE__ */ C("p", {
|
|
283
|
-
className: "mt-3 text-sm text-text-secondary",
|
|
284
|
-
children: I("atheletebridge.customerDashboard.noRecentOrders", "No recent orders")
|
|
285
|
-
})]
|
|
286
|
-
})] }),
|
|
287
|
-
/* @__PURE__ */ w("section", { children: [/* @__PURE__ */ C("h2", {
|
|
288
|
-
className: "text-lg font-semibold text-text-primary mb-4",
|
|
289
|
-
children: I("atheletebridge.customerDashboard.recommendedForYou", "Recommended for You")
|
|
290
|
-
}), /* @__PURE__ */ C("div", {
|
|
291
|
-
className: "grid grid-cols-1 gap-4 sm:grid-cols-2",
|
|
292
|
-
children: B.map((e) => /* @__PURE__ */ w("div", {
|
|
293
|
-
className: "rounded-lg border border-border-subtle bg-bg-surface overflow-hidden shadow-sm hover:shadow-md transition-shadow",
|
|
294
|
-
children: [/* @__PURE__ */ w("div", {
|
|
295
|
-
className: "relative h-40",
|
|
296
|
-
children: [/* @__PURE__ */ C("img", {
|
|
297
|
-
src: e.image,
|
|
298
|
-
alt: e.name,
|
|
299
|
-
className: "h-full w-full object-cover"
|
|
300
|
-
}), /* @__PURE__ */ C("div", {
|
|
301
|
-
className: "absolute top-2 right-2",
|
|
302
|
-
children: /* @__PURE__ */ C("span", {
|
|
303
|
-
className: t("inline-flex items-center rounded-full px-2 py-0.5 text-xs font-medium", e.isOpen ? "bg-green-500/20 text-green-600 dark:text-green-400" : "bg-red-500/20 text-red-600 dark:text-red-400"),
|
|
304
|
-
children: e.isOpen ? I("atheletebridge.customerDashboard.open", "Open") : I("atheletebridge.customerDashboard.closed", "Closed")
|
|
442
|
+
})]
|
|
305
443
|
})
|
|
306
|
-
})
|
|
444
|
+
}, e.id))
|
|
445
|
+
})]
|
|
446
|
+
}),
|
|
447
|
+
/* @__PURE__ */ w("div", {
|
|
448
|
+
className: "rounded-lg border border-border-subtle bg-bg-surface p-5",
|
|
449
|
+
children: [/* @__PURE__ */ C("h3", {
|
|
450
|
+
className: "text-base font-semibold text-text-primary mb-3",
|
|
451
|
+
children: z("atheletebridge.customerDashboard.quickLinks", "Quick Links")
|
|
307
452
|
}), /* @__PURE__ */ w("div", {
|
|
308
|
-
className: "
|
|
453
|
+
className: "space-y-2",
|
|
309
454
|
children: [
|
|
310
|
-
/* @__PURE__ */ w("
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
className: "text-sm font-semibold text-text-primary",
|
|
316
|
-
children: e.name
|
|
317
|
-
}), /* @__PURE__ */ C("p", {
|
|
318
|
-
className: "text-xs text-text-secondary",
|
|
319
|
-
children: e.category
|
|
320
|
-
})]
|
|
321
|
-
}), /* @__PURE__ */ w("div", {
|
|
322
|
-
className: "flex items-center gap-1 text-xs",
|
|
323
|
-
children: [/* @__PURE__ */ C(y, { className: "h-3 w-3 fill-yellow-400 text-yellow-400" }), /* @__PURE__ */ C("span", {
|
|
324
|
-
className: "font-medium text-text-primary",
|
|
325
|
-
children: e.rating
|
|
326
|
-
})]
|
|
327
|
-
})]
|
|
455
|
+
/* @__PURE__ */ w("button", {
|
|
456
|
+
type: "button",
|
|
457
|
+
onClick: () => k("/customer/profile"),
|
|
458
|
+
className: "flex w-full items-center gap-2 rounded-lg border border-border-subtle px-3 py-2.5 text-sm text-text-primary hover:bg-accent transition-colors text-left",
|
|
459
|
+
children: [/* @__PURE__ */ C(x, { className: "h-4 w-4 text-text-secondary" }), z("atheletebridge.customerDashboard.profileSettings", "Profile Settings")]
|
|
328
460
|
}),
|
|
329
|
-
/* @__PURE__ */ w("
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
/* @__PURE__ */ C(m, { className: "h-3 w-3" }),
|
|
335
|
-
e.distance,
|
|
336
|
-
"km away"
|
|
337
|
-
]
|
|
338
|
-
}), /* @__PURE__ */ w("span", {
|
|
339
|
-
className: "flex items-center gap-1",
|
|
340
|
-
children: [
|
|
341
|
-
/* @__PURE__ */ C(u, { className: "h-3 w-3" }),
|
|
342
|
-
e.estimatedTime,
|
|
343
|
-
" mins"
|
|
344
|
-
]
|
|
345
|
-
})]
|
|
461
|
+
/* @__PURE__ */ w("button", {
|
|
462
|
+
type: "button",
|
|
463
|
+
onClick: () => k("/customer/addresses"),
|
|
464
|
+
className: "flex w-full items-center gap-2 rounded-lg border border-border-subtle px-3 py-2.5 text-sm text-text-primary hover:bg-accent transition-colors text-left",
|
|
465
|
+
children: [/* @__PURE__ */ C(h, { className: "h-4 w-4 text-text-secondary" }), z("atheletebridge.customerDashboard.savedAddresses", "Saved Addresses")]
|
|
346
466
|
}),
|
|
347
|
-
/* @__PURE__ */
|
|
467
|
+
/* @__PURE__ */ w("button", {
|
|
348
468
|
type: "button",
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
children: e.isOpen ? I("atheletebridge.customerDashboard.viewMenu", "View Menu") : I("atheletebridge.customerDashboard.currentlyClosed", "Currently Closed")
|
|
469
|
+
onClick: () => k("/customer/payment-methods"),
|
|
470
|
+
className: "flex w-full items-center gap-2 rounded-lg border border-border-subtle px-3 py-2.5 text-sm text-text-primary hover:bg-accent transition-colors text-left",
|
|
471
|
+
children: [/* @__PURE__ */ C(f, { className: "h-4 w-4 text-text-secondary" }), z("atheletebridge.customerDashboard.paymentMethods", "Payment Methods")]
|
|
353
472
|
})
|
|
354
473
|
]
|
|
355
474
|
})]
|
|
356
|
-
},
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
}), /* @__PURE__ */ C("div", {
|
|
368
|
-
className: "space-y-3",
|
|
369
|
-
children: R.map((e) => /* @__PURE__ */ C("div", {
|
|
370
|
-
className: t("rounded-lg border p-3", W(e.type)),
|
|
371
|
-
children: /* @__PURE__ */ w("div", {
|
|
372
|
-
className: "flex items-start gap-2",
|
|
373
|
-
children: [/* @__PURE__ */ C("div", {
|
|
374
|
-
className: "mt-0.5 shrink-0",
|
|
375
|
-
children: U(e.type)
|
|
376
|
-
}), /* @__PURE__ */ w("div", {
|
|
475
|
+
}),
|
|
476
|
+
/* @__PURE__ */ w("div", {
|
|
477
|
+
className: "rounded-lg border border-border-subtle bg-bg-surface p-5",
|
|
478
|
+
children: [
|
|
479
|
+
/* @__PURE__ */ C("h3", {
|
|
480
|
+
className: "text-base font-semibold text-text-primary mb-3",
|
|
481
|
+
children: z("atheletebridge.customerDashboard.currentLocation", "Current Location")
|
|
482
|
+
}),
|
|
483
|
+
/* @__PURE__ */ w("div", {
|
|
484
|
+
className: "flex items-start gap-3",
|
|
485
|
+
children: [/* @__PURE__ */ C(g, { className: "h-4 w-4 text-blue-500 mt-0.5 shrink-0" }), /* @__PURE__ */ w("div", {
|
|
377
486
|
className: "flex-1 min-w-0",
|
|
378
487
|
children: [
|
|
379
|
-
/* @__PURE__ */
|
|
380
|
-
className: "
|
|
381
|
-
children:
|
|
382
|
-
className: "text-xs font-semibold",
|
|
383
|
-
children: e.title
|
|
384
|
-
}), /* @__PURE__ */ w("span", {
|
|
385
|
-
className: "text-[10px] opacity-70",
|
|
386
|
-
children: [e.confidence, "%"]
|
|
387
|
-
})]
|
|
488
|
+
/* @__PURE__ */ C("p", {
|
|
489
|
+
className: "text-sm font-medium text-text-primary",
|
|
490
|
+
children: "Koramangala"
|
|
388
491
|
}),
|
|
389
492
|
/* @__PURE__ */ C("p", {
|
|
390
|
-
className: "
|
|
391
|
-
children:
|
|
493
|
+
className: "text-xs text-text-secondary",
|
|
494
|
+
children: "80 Feet Road, 6th Block"
|
|
392
495
|
}),
|
|
393
|
-
/* @__PURE__ */ C("
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
className: "mt-2 text-[10px] font-semibold underline underline-offset-2",
|
|
397
|
-
children: e.action
|
|
496
|
+
/* @__PURE__ */ C("p", {
|
|
497
|
+
className: "text-xs text-text-secondary",
|
|
498
|
+
children: "Bangalore, Karnataka"
|
|
398
499
|
})
|
|
399
500
|
]
|
|
400
501
|
})]
|
|
502
|
+
}),
|
|
503
|
+
/* @__PURE__ */ C("button", {
|
|
504
|
+
type: "button",
|
|
505
|
+
onClick: () => k("/customer/addresses"),
|
|
506
|
+
className: "mt-3 w-full rounded-lg border border-border-subtle px-3 py-2 text-xs font-medium text-text-primary hover:bg-accent transition-colors",
|
|
507
|
+
children: z("atheletebridge.customerDashboard.updateLocation", "Update Location")
|
|
401
508
|
})
|
|
402
|
-
|
|
403
|
-
})
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
className: "rounded-lg border border-border-subtle bg-bg-surface p-5",
|
|
407
|
-
children: [/* @__PURE__ */ C("h3", {
|
|
408
|
-
className: "text-base font-semibold text-text-primary mb-3",
|
|
409
|
-
children: I("atheletebridge.customerDashboard.quickLinks", "Quick Links")
|
|
410
|
-
}), /* @__PURE__ */ w("div", {
|
|
411
|
-
className: "space-y-2",
|
|
509
|
+
]
|
|
510
|
+
}),
|
|
511
|
+
/* @__PURE__ */ w("div", {
|
|
512
|
+
className: "rounded-lg bg-gradient-to-r from-blue-500/10 to-purple-500/10 border border-blue-500/20 p-5",
|
|
412
513
|
children: [
|
|
413
|
-
/* @__PURE__ */
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
className: "flex w-full items-center gap-2 rounded-lg border border-border-subtle px-3 py-2.5 text-sm text-text-primary hover:bg-accent transition-colors text-left",
|
|
417
|
-
children: [/* @__PURE__ */ C(x, { className: "h-4 w-4 text-text-secondary" }), I("atheletebridge.customerDashboard.profileSettings", "Profile Settings")]
|
|
514
|
+
/* @__PURE__ */ C("h3", {
|
|
515
|
+
className: "text-base font-semibold text-text-primary mb-2",
|
|
516
|
+
children: z("atheletebridge.customerDashboard.specialOffers", "Special Offers")
|
|
418
517
|
}),
|
|
419
|
-
/* @__PURE__ */
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
className: "flex w-full items-center gap-2 rounded-lg border border-border-subtle px-3 py-2.5 text-sm text-text-primary hover:bg-accent transition-colors text-left",
|
|
423
|
-
children: [/* @__PURE__ */ C(m, { className: "h-4 w-4 text-text-secondary" }), I("atheletebridge.customerDashboard.savedAddresses", "Saved Addresses")]
|
|
518
|
+
/* @__PURE__ */ C("p", {
|
|
519
|
+
className: "text-xs text-text-secondary mb-3 leading-relaxed",
|
|
520
|
+
children: z("atheletebridge.customerDashboard.specialOffersDescription", "Get 25% off on your next order from featured carts")
|
|
424
521
|
}),
|
|
425
|
-
/* @__PURE__ */
|
|
522
|
+
/* @__PURE__ */ C("button", {
|
|
426
523
|
type: "button",
|
|
427
|
-
onClick: () =>
|
|
428
|
-
className: "
|
|
429
|
-
children:
|
|
524
|
+
onClick: () => k("/customer/carts"),
|
|
525
|
+
className: "w-full rounded-lg bg-foreground px-3 py-2 text-sm font-medium text-background hover:opacity-90 transition-opacity",
|
|
526
|
+
children: z("atheletebridge.customerDashboard.viewOffers", "View Offers")
|
|
430
527
|
})
|
|
431
528
|
]
|
|
432
|
-
})
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
/* @__PURE__ */ C("h3", {
|
|
438
|
-
className: "text-base font-semibold text-text-primary mb-3",
|
|
439
|
-
children: I("atheletebridge.customerDashboard.currentLocation", "Current Location")
|
|
440
|
-
}),
|
|
441
|
-
/* @__PURE__ */ w("div", {
|
|
442
|
-
className: "flex items-start gap-3",
|
|
443
|
-
children: [/* @__PURE__ */ C(h, { className: "h-4 w-4 text-blue-500 mt-0.5 shrink-0" }), /* @__PURE__ */ w("div", {
|
|
444
|
-
className: "flex-1 min-w-0",
|
|
445
|
-
children: [
|
|
446
|
-
/* @__PURE__ */ C("p", {
|
|
447
|
-
className: "text-sm font-medium text-text-primary",
|
|
448
|
-
children: "Koramangala"
|
|
449
|
-
}),
|
|
450
|
-
/* @__PURE__ */ C("p", {
|
|
451
|
-
className: "text-xs text-text-secondary",
|
|
452
|
-
children: "80 Feet Road, 6th Block"
|
|
453
|
-
}),
|
|
454
|
-
/* @__PURE__ */ C("p", {
|
|
455
|
-
className: "text-xs text-text-secondary",
|
|
456
|
-
children: "Bangalore, Karnataka"
|
|
457
|
-
})
|
|
458
|
-
]
|
|
459
|
-
})]
|
|
460
|
-
}),
|
|
461
|
-
/* @__PURE__ */ C("button", {
|
|
462
|
-
type: "button",
|
|
463
|
-
onClick: () => E("/customer/addresses"),
|
|
464
|
-
className: "mt-3 w-full rounded-lg border border-border-subtle px-3 py-2 text-xs font-medium text-text-primary hover:bg-accent transition-colors",
|
|
465
|
-
children: I("atheletebridge.customerDashboard.updateLocation", "Update Location")
|
|
466
|
-
})
|
|
467
|
-
]
|
|
468
|
-
}),
|
|
469
|
-
/* @__PURE__ */ w("div", {
|
|
470
|
-
className: "rounded-lg bg-gradient-to-r from-blue-500/10 to-purple-500/10 border border-blue-500/20 p-5",
|
|
471
|
-
children: [
|
|
472
|
-
/* @__PURE__ */ C("h3", {
|
|
473
|
-
className: "text-base font-semibold text-text-primary mb-2",
|
|
474
|
-
children: I("atheletebridge.customerDashboard.specialOffers", "Special Offers")
|
|
475
|
-
}),
|
|
476
|
-
/* @__PURE__ */ C("p", {
|
|
477
|
-
className: "text-xs text-text-secondary mb-3 leading-relaxed",
|
|
478
|
-
children: I("atheletebridge.customerDashboard.specialOffersDescription", "Get 25% off on your next order from featured carts")
|
|
479
|
-
}),
|
|
480
|
-
/* @__PURE__ */ C("button", {
|
|
481
|
-
type: "button",
|
|
482
|
-
onClick: () => E("/customer/carts"),
|
|
483
|
-
className: "w-full rounded-lg bg-foreground px-3 py-2 text-sm font-medium text-background hover:opacity-90 transition-opacity",
|
|
484
|
-
children: I("atheletebridge.customerDashboard.viewOffers", "View Offers")
|
|
485
|
-
})
|
|
486
|
-
]
|
|
487
|
-
})
|
|
488
|
-
]
|
|
489
|
-
})]
|
|
490
|
-
})]
|
|
529
|
+
})
|
|
530
|
+
]
|
|
531
|
+
})]
|
|
532
|
+
})
|
|
533
|
+
]
|
|
491
534
|
});
|
|
492
535
|
}
|
|
493
536
|
//#endregion
|
|
494
|
-
export {
|
|
537
|
+
export { k as CustomerDashboard };
|
|
495
538
|
|
|
496
539
|
//# sourceMappingURL=CustomerDashboard.js.map
|