@burdenoff/microfe-kadaikodi 2026.626.2 → 2026.704.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/kadaikodi/hooks/useKadaikodiApi.js +209 -105
- package/dist/kadaikodi/hooks/useKadaikodiApi.js.map +1 -1
- package/dist/kadaikodi/pages/HomePage.js +4 -4
- package/dist/kadaikodi/pages/HomePage.js.map +1 -1
- package/dist/kadaikodi/pages/admin/AdminDashboard.js +1 -1
- package/dist/kadaikodi/pages/admin/AdminDashboard.js.map +1 -1
- package/dist/kadaikodi/pages/admin/AdminOrdersPage.js +1 -1
- package/dist/kadaikodi/pages/admin/AdminOrdersPage.js.map +1 -1
- package/dist/kadaikodi/pages/admin/CartManagementPage.js +279 -333
- package/dist/kadaikodi/pages/admin/CartManagementPage.js.map +1 -1
- package/dist/kadaikodi/pages/admin/UserManagementPage.js +299 -372
- package/dist/kadaikodi/pages/admin/UserManagementPage.js.map +1 -1
- package/dist/kadaikodi/pages/cart-owner/AnalyticsDashboard.js +214 -214
- package/dist/kadaikodi/pages/cart-owner/AnalyticsDashboard.js.map +1 -1
- package/dist/kadaikodi/pages/cart-owner/CartOwnerDashboard.js +226 -230
- package/dist/kadaikodi/pages/cart-owner/CartOwnerDashboard.js.map +1 -1
- package/dist/kadaikodi/pages/cart-owner/CartOwnerProfilePage.js +255 -256
- package/dist/kadaikodi/pages/cart-owner/CartOwnerProfilePage.js.map +1 -1
- package/dist/kadaikodi/pages/cart-owner/InventoryManagementPage.js +275 -278
- package/dist/kadaikodi/pages/cart-owner/InventoryManagementPage.js.map +1 -1
- package/dist/kadaikodi/pages/cart-owner/OrderManagementPage.js +228 -446
- package/dist/kadaikodi/pages/cart-owner/OrderManagementPage.js.map +1 -1
- package/dist/kadaikodi/pages/common/NotificationCenterPage.js +1 -1
- package/dist/kadaikodi/pages/common/NotificationCenterPage.js.map +1 -1
- package/dist/kadaikodi/pages/common/SettingsPage.js +34 -46
- package/dist/kadaikodi/pages/common/SettingsPage.js.map +1 -1
- package/dist/kadaikodi/pages/customer/BookingDetailsPage.js +193 -447
- package/dist/kadaikodi/pages/customer/BookingDetailsPage.js.map +1 -1
- package/dist/kadaikodi/pages/customer/CartDetailPage.js +6 -6
- package/dist/kadaikodi/pages/customer/CartDetailPage.js.map +1 -1
- package/dist/kadaikodi/pages/customer/CartDiscoveryPage.js +2 -2
- package/dist/kadaikodi/pages/customer/CartDiscoveryPage.js.map +1 -1
- package/dist/kadaikodi/pages/customer/DirectServiceBookingPage.js +255 -215
- package/dist/kadaikodi/pages/customer/DirectServiceBookingPage.js.map +1 -1
- package/dist/kadaikodi/pages/customer/FavoritesPage.js +141 -178
- package/dist/kadaikodi/pages/customer/FavoritesPage.js.map +1 -1
- package/dist/kadaikodi/pages/customer/OrderTrackingPage.js +155 -161
- package/dist/kadaikodi/pages/customer/OrderTrackingPage.js.map +1 -1
- package/dist/kadaikodi/pages/customer/ReviewsPage.js +14 -140
- package/dist/kadaikodi/pages/customer/ReviewsPage.js.map +1 -1
- package/dist/kadaikodi/pages/investor/InvestmentOpportunitiesPage.js +304 -458
- package/dist/kadaikodi/pages/investor/InvestmentOpportunitiesPage.js.map +1 -1
- package/dist/kadaikodi/pages/investor/InvestorDashboard.js +1 -1
- package/dist/kadaikodi/pages/investor/InvestorDashboard.js.map +1 -1
- package/dist/kadaikodi/pages/investor/InvestorInvestmentsPage.js +2 -2
- package/dist/kadaikodi/pages/investor/InvestorInvestmentsPage.js.map +1 -1
- package/dist/kadaikodi/pages/investor/InvestorProfilePage.js +361 -361
- package/dist/kadaikodi/pages/investor/InvestorProfilePage.js.map +1 -1
- package/dist/kadaikodi/pages/worker/TaskDetailsPage.js +226 -220
- package/dist/kadaikodi/pages/worker/TaskDetailsPage.js.map +1 -1
- package/dist/kadaikodi/pages/worker/WorkerDashboard.js +15 -15
- package/dist/kadaikodi/pages/worker/WorkerDashboard.js.map +1 -1
- package/dist/kadaikodi/pages/worker/WorkerOrdersPage.js +2 -2
- package/dist/kadaikodi/pages/worker/WorkerOrdersPage.js.map +1 -1
- package/dist/kadaikodi/pages/worker/WorkerProfilePage.js +252 -253
- package/dist/kadaikodi/pages/worker/WorkerProfilePage.js.map +1 -1
- package/dist/kadaikodi/pages/worker/WorkerSchedulePage.js +3 -3
- package/dist/kadaikodi/pages/worker/WorkerSchedulePage.js.map +1 -1
- package/package.json +1 -1
- package/dist/kadaikodi/mocks/data.js +0 -1517
- package/dist/kadaikodi/mocks/data.js.map +0 -1
- package/dist/kadaikodi/mocks/users.js +0 -34
- package/dist/kadaikodi/mocks/users.js.map +0 -1
|
@@ -1,23 +1,14 @@
|
|
|
1
1
|
import { useKadaikodi as e } from "../../context/KadaikodiContext.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 { useState as
|
|
7
|
-
import { Activity as
|
|
8
|
-
import { jsx as
|
|
9
|
-
import { EmphasisPanel as
|
|
4
|
+
import { useAdminAnalytics as r, useDashboardStats as i } from "../../hooks/useKadaikodiApi.js";
|
|
5
|
+
import { formatCurrency as a } from "../../utils/formatters.js";
|
|
6
|
+
import { useState as o } from "react";
|
|
7
|
+
import { Activity as s, AlertCircle as c, ArrowRight as l, BarChart3 as u, Bell as d, CheckCircle as f, ChevronRight as p, Clock as m, Edit as h, Eye as g, Flame as _, IndianRupee as v, MapPin as y, Package as b, Plus as x, Settings as S, ShoppingCart as C, Star as w, TrendingDown as T, TrendingUp as E, UserCheck as D, Users as O } from "lucide-react";
|
|
8
|
+
import { Fragment as k, jsx as A, jsxs as j } from "react/jsx-runtime";
|
|
9
|
+
import { EmphasisPanel as M, NextSteps as N, PagePurpose as P } from "@burdenoff/fe-libs/ui";
|
|
10
10
|
//#region src/kadaikodi/pages/cart-owner/CartOwnerDashboard.tsx
|
|
11
|
-
var
|
|
12
|
-
totalRevenue: 45230,
|
|
13
|
-
dailyRevenue: 1850,
|
|
14
|
-
ordersToday: 23,
|
|
15
|
-
totalOrders: 1247,
|
|
16
|
-
activeOfferings: 68,
|
|
17
|
-
averageOrderValue: 80,
|
|
18
|
-
customerCount: 342,
|
|
19
|
-
rating: 4.2
|
|
20
|
-
}, P = [
|
|
11
|
+
var F = [
|
|
21
12
|
{
|
|
22
13
|
id: "ORD-001",
|
|
23
14
|
customerName: "Rahul Sharma",
|
|
@@ -62,7 +53,7 @@ var N = {
|
|
|
62
53
|
timestamp: "2 mins ago",
|
|
63
54
|
priority: "urgent"
|
|
64
55
|
}
|
|
65
|
-
],
|
|
56
|
+
], I = [
|
|
66
57
|
{
|
|
67
58
|
name: "Masala Dosa",
|
|
68
59
|
quantity: 245,
|
|
@@ -88,7 +79,7 @@ var N = {
|
|
|
88
79
|
quantity: 98,
|
|
89
80
|
revenue: 8820
|
|
90
81
|
}
|
|
91
|
-
],
|
|
82
|
+
], L = [
|
|
92
83
|
{
|
|
93
84
|
name: "Ramesh Kumar",
|
|
94
85
|
role: "Chef",
|
|
@@ -109,7 +100,7 @@ var N = {
|
|
|
109
100
|
role: "Manager",
|
|
110
101
|
status: "active"
|
|
111
102
|
}
|
|
112
|
-
],
|
|
103
|
+
], R = [
|
|
113
104
|
{
|
|
114
105
|
id: "1",
|
|
115
106
|
message: "New order #ORD-004 received",
|
|
@@ -140,7 +131,7 @@ var N = {
|
|
|
140
131
|
type: "warning",
|
|
141
132
|
time: "1 hr ago"
|
|
142
133
|
}
|
|
143
|
-
],
|
|
134
|
+
], z = () => {
|
|
144
135
|
let e = (/* @__PURE__ */ new Date()).getHours();
|
|
145
136
|
return e < 12 ? "Good Morning" : e < 17 ? "Good Afternoon" : "Good Evening";
|
|
146
137
|
}, B = {
|
|
@@ -158,159 +149,164 @@ var N = {
|
|
|
158
149
|
warning: "text-status-warning-text",
|
|
159
150
|
success: "text-status-success-text"
|
|
160
151
|
}, U = () => {
|
|
161
|
-
let { navigateTo:
|
|
152
|
+
let { navigateTo: U, currentUser: W } = e(), { data: G } = r(), { data: K } = i(), q = {
|
|
153
|
+
totalRevenue: K?.totalRevenue ?? 0,
|
|
154
|
+
dailyRevenue: 0,
|
|
155
|
+
ordersToday: 0,
|
|
156
|
+
totalOrders: K?.totalOrders ?? 0,
|
|
157
|
+
activeOfferings: 0,
|
|
158
|
+
averageOrderValue: 0,
|
|
159
|
+
customerCount: K?.activeCustomers ?? 0,
|
|
160
|
+
rating: K?.avgRating ?? 0
|
|
161
|
+
}, J = (G?.orderTrends ?? []).slice(0, 7), Y = W?.firstName ?? W?.name?.split(" ")[0] ?? "", [X, Z] = o(F), [Q, $] = o({
|
|
162
162
|
isOpen: !0,
|
|
163
163
|
currentLocation: "Koramangala 5th Block, Near BDA Complex",
|
|
164
164
|
lastUpdate: (/* @__PURE__ */ new Date()).toLocaleTimeString(),
|
|
165
165
|
operatingHours: "9:00 AM - 9:00 PM"
|
|
166
|
-
}),
|
|
167
|
-
|
|
166
|
+
}), ee = (e) => {
|
|
167
|
+
Z((t) => t.map((t) => t.id === e ? {
|
|
168
168
|
...t,
|
|
169
169
|
status: "preparing"
|
|
170
170
|
} : t));
|
|
171
|
-
},
|
|
172
|
-
|
|
171
|
+
}, te = (e) => {
|
|
172
|
+
Z((t) => t.map((t) => t.id === e ? {
|
|
173
173
|
...t,
|
|
174
174
|
status: "ready"
|
|
175
175
|
} : t));
|
|
176
176
|
};
|
|
177
|
-
return /* @__PURE__ */
|
|
178
|
-
title: /* @__PURE__ */
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
className: "text-text-secondary font-normal",
|
|
183
|
-
children: "Rajesh"
|
|
184
|
-
})
|
|
185
|
-
] }),
|
|
177
|
+
return /* @__PURE__ */ A(n, {
|
|
178
|
+
title: /* @__PURE__ */ j("span", { children: [z(), Y && /* @__PURE__ */ j(k, { children: [", ", /* @__PURE__ */ A("span", {
|
|
179
|
+
className: "text-text-secondary font-normal",
|
|
180
|
+
children: Y
|
|
181
|
+
})] })] }),
|
|
186
182
|
description: "Manage your service provider operations",
|
|
187
|
-
actions: /* @__PURE__ */
|
|
183
|
+
actions: /* @__PURE__ */ j("button", {
|
|
188
184
|
type: "button",
|
|
189
|
-
onClick: () =>
|
|
185
|
+
onClick: () => U("/cart-owner/orders"),
|
|
190
186
|
className: "inline-flex items-center gap-2 rounded-md bg-accent px-4 py-2 text-sm font-medium text-text-primary hover:bg-accent/80 transition-colors",
|
|
191
|
-
children: ["View All Orders", /* @__PURE__ */
|
|
187
|
+
children: ["View All Orders", /* @__PURE__ */ A(l, { className: "h-4 w-4" })]
|
|
192
188
|
}),
|
|
193
|
-
children: /* @__PURE__ */
|
|
189
|
+
children: /* @__PURE__ */ j("div", {
|
|
194
190
|
className: "space-y-6",
|
|
195
191
|
children: [
|
|
196
|
-
/* @__PURE__ */
|
|
197
|
-
/* @__PURE__ */
|
|
192
|
+
/* @__PURE__ */ A(P, { children: "Run your mobile cart business from one screen — flip your service open or closed, watch today's revenue and orders roll in, and jump to your menu, staff, or order queue. Open your service and set up your offerings to start taking orders." }),
|
|
193
|
+
/* @__PURE__ */ A(N, {
|
|
198
194
|
storageKey: "kadaikodi-cartowner-dashboard",
|
|
199
195
|
steps: [
|
|
200
196
|
{
|
|
201
197
|
id: "offerings",
|
|
202
198
|
label: "Set up your offerings",
|
|
203
199
|
description: "Add the dishes and items customers can order from your cart.",
|
|
204
|
-
onClick: () =>
|
|
200
|
+
onClick: () => U("/cart-owner/inventory")
|
|
205
201
|
},
|
|
206
202
|
{
|
|
207
203
|
id: "service-config",
|
|
208
204
|
label: "Configure service & hours",
|
|
209
205
|
description: "Define your operating hours, location and service area.",
|
|
210
|
-
onClick: () =>
|
|
206
|
+
onClick: () => U("/cart-owner/service-config")
|
|
211
207
|
},
|
|
212
208
|
{
|
|
213
209
|
id: "orders",
|
|
214
210
|
label: "Manage incoming orders",
|
|
215
211
|
description: "Accept, prepare and fulfil customer orders in real time.",
|
|
216
|
-
onClick: () =>
|
|
212
|
+
onClick: () => U("/cart-owner/orders")
|
|
217
213
|
}
|
|
218
214
|
]
|
|
219
215
|
}),
|
|
220
|
-
/* @__PURE__ */
|
|
221
|
-
className: t("p-4 rounded-lg border-l-4",
|
|
222
|
-
children: /* @__PURE__ */
|
|
216
|
+
/* @__PURE__ */ A("div", {
|
|
217
|
+
className: t("p-4 rounded-lg border-l-4", Q.isOpen ? "border-status-success-text bg-status-success-bg-subtle" : "border-status-error-text bg-status-error-bg-subtle"),
|
|
218
|
+
children: /* @__PURE__ */ j("div", {
|
|
223
219
|
className: "flex flex-col lg:flex-row lg:items-center lg:justify-between gap-4",
|
|
224
|
-
children: [/* @__PURE__ */
|
|
220
|
+
children: [/* @__PURE__ */ j("div", {
|
|
225
221
|
className: "flex items-start gap-3",
|
|
226
|
-
children: [/* @__PURE__ */
|
|
222
|
+
children: [/* @__PURE__ */ A("div", { className: t("w-3 h-3 rounded-full mt-1 shrink-0", Q.isOpen ? "bg-status-success-text" : "bg-status-error-text") }), /* @__PURE__ */ j("div", { children: [/* @__PURE__ */ j("h3", {
|
|
227
223
|
className: "font-semibold text-text-primary text-sm",
|
|
228
|
-
children: ["Service Status: ",
|
|
229
|
-
}), /* @__PURE__ */
|
|
224
|
+
children: ["Service Status: ", Q.isOpen ? "Open" : "Closed"]
|
|
225
|
+
}), /* @__PURE__ */ j("div", {
|
|
230
226
|
className: "flex flex-col sm:flex-row sm:items-center gap-2 sm:gap-4 mt-1 text-xs text-text-secondary",
|
|
231
|
-
children: [/* @__PURE__ */
|
|
227
|
+
children: [/* @__PURE__ */ j("span", {
|
|
232
228
|
className: "flex items-center gap-1",
|
|
233
|
-
children: [/* @__PURE__ */
|
|
234
|
-
}), /* @__PURE__ */
|
|
229
|
+
children: [/* @__PURE__ */ A(y, { className: "h-3 w-3 shrink-0" }), Q.currentLocation]
|
|
230
|
+
}), /* @__PURE__ */ j("span", {
|
|
235
231
|
className: "flex items-center gap-1",
|
|
236
|
-
children: [/* @__PURE__ */
|
|
232
|
+
children: [/* @__PURE__ */ A(m, { className: "h-3 w-3 shrink-0" }), Q.operatingHours]
|
|
237
233
|
})]
|
|
238
234
|
})] })]
|
|
239
|
-
}), /* @__PURE__ */
|
|
235
|
+
}), /* @__PURE__ */ j("div", {
|
|
240
236
|
className: "flex gap-2",
|
|
241
|
-
children: [/* @__PURE__ */
|
|
237
|
+
children: [/* @__PURE__ */ j("button", {
|
|
242
238
|
type: "button",
|
|
243
|
-
onClick: () =>
|
|
239
|
+
onClick: () => U("/cart-owner/settings"),
|
|
244
240
|
className: "inline-flex items-center gap-1 rounded-md border border-border-subtle px-3 py-1.5 text-xs font-medium text-text-primary hover:bg-bg-sunken transition-colors",
|
|
245
|
-
children: [/* @__PURE__ */
|
|
246
|
-
}), /* @__PURE__ */
|
|
241
|
+
children: [/* @__PURE__ */ A(y, { className: "h-3 w-3" }), "Update Location"]
|
|
242
|
+
}), /* @__PURE__ */ A("button", {
|
|
247
243
|
type: "button",
|
|
248
244
|
onClick: () => {
|
|
249
|
-
|
|
245
|
+
$((e) => e && {
|
|
250
246
|
...e,
|
|
251
247
|
isOpen: !e.isOpen
|
|
252
248
|
});
|
|
253
249
|
},
|
|
254
|
-
className: t("inline-flex items-center gap-1 rounded-md px-3 py-1.5 text-xs font-medium transition-colors",
|
|
255
|
-
children:
|
|
250
|
+
className: t("inline-flex items-center gap-1 rounded-md px-3 py-1.5 text-xs font-medium transition-colors", Q.isOpen ? "bg-status-error-bg-subtle text-status-error-text hover:bg-status-error-bg-subtle" : "bg-status-success-bg-subtle text-status-success-text hover:bg-status-success-bg-subtle"),
|
|
251
|
+
children: Q.isOpen ? "Close Service" : "Open Service"
|
|
256
252
|
})]
|
|
257
253
|
})]
|
|
258
254
|
})
|
|
259
255
|
}),
|
|
260
|
-
/* @__PURE__ */
|
|
256
|
+
/* @__PURE__ */ j(M, { children: [/* @__PURE__ */ A("h2", {
|
|
261
257
|
className: "text-base font-semibold text-text-primary mb-3",
|
|
262
258
|
children: "Today's Performance"
|
|
263
|
-
}), /* @__PURE__ */
|
|
259
|
+
}), /* @__PURE__ */ A("div", {
|
|
264
260
|
className: "grid grid-cols-1 gap-4 sm:grid-cols-2 lg:grid-cols-4",
|
|
265
261
|
children: [
|
|
266
262
|
{
|
|
267
263
|
label: "Daily Revenue",
|
|
268
|
-
value:
|
|
269
|
-
icon:
|
|
264
|
+
value: a(q.dailyRevenue, { minimumFractionDigits: 0 }),
|
|
265
|
+
icon: v,
|
|
270
266
|
trend: "+15.2% vs yesterday",
|
|
271
267
|
trendUp: !0
|
|
272
268
|
},
|
|
273
269
|
{
|
|
274
270
|
label: "Orders Today",
|
|
275
|
-
value: String(
|
|
276
|
-
icon:
|
|
271
|
+
value: String(q.ordersToday),
|
|
272
|
+
icon: C,
|
|
277
273
|
trend: "+8.5% vs yesterday",
|
|
278
274
|
trendUp: !0
|
|
279
275
|
},
|
|
280
276
|
{
|
|
281
277
|
label: "Avg Order Value",
|
|
282
|
-
value:
|
|
283
|
-
icon:
|
|
278
|
+
value: a(q.averageOrderValue, { minimumFractionDigits: 0 }),
|
|
279
|
+
icon: E,
|
|
284
280
|
trend: "+3.2% vs last week",
|
|
285
281
|
trendUp: !0
|
|
286
282
|
},
|
|
287
283
|
{
|
|
288
284
|
label: "Service Rating",
|
|
289
|
-
value:
|
|
290
|
-
icon:
|
|
285
|
+
value: q.rating.toFixed(1),
|
|
286
|
+
icon: w,
|
|
291
287
|
trend: "Based on 342 reviews",
|
|
292
288
|
trendUp: !0
|
|
293
289
|
}
|
|
294
290
|
].map((e) => {
|
|
295
291
|
let t = e.icon;
|
|
296
|
-
return /* @__PURE__ */
|
|
292
|
+
return /* @__PURE__ */ j("div", {
|
|
297
293
|
className: "rounded-lg border border-border-subtle bg-bg-surface p-5 shadow-sm",
|
|
298
294
|
children: [
|
|
299
|
-
/* @__PURE__ */
|
|
295
|
+
/* @__PURE__ */ j("div", {
|
|
300
296
|
className: "flex items-center justify-between",
|
|
301
|
-
children: [/* @__PURE__ */
|
|
297
|
+
children: [/* @__PURE__ */ A("div", {
|
|
302
298
|
className: "rounded-md bg-accent p-2",
|
|
303
|
-
children: /* @__PURE__ */
|
|
304
|
-
}), /* @__PURE__ */
|
|
299
|
+
children: /* @__PURE__ */ A(t, { className: "h-5 w-5 text-text-secondary" })
|
|
300
|
+
}), /* @__PURE__ */ j("div", {
|
|
305
301
|
className: "flex items-center gap-1 text-xs text-text-secondary",
|
|
306
|
-
children: [e.trendUp ? /* @__PURE__ */
|
|
302
|
+
children: [e.trendUp ? /* @__PURE__ */ A(E, { className: "h-3 w-3 text-status-success-text" }) : /* @__PURE__ */ A(T, { className: "h-3 w-3 text-status-error-text" }), /* @__PURE__ */ A("span", { children: e.trend })]
|
|
307
303
|
})]
|
|
308
304
|
}),
|
|
309
|
-
/* @__PURE__ */
|
|
305
|
+
/* @__PURE__ */ A("p", {
|
|
310
306
|
className: "mt-3 text-2xl font-bold text-text-primary",
|
|
311
307
|
children: e.value
|
|
312
308
|
}),
|
|
313
|
-
/* @__PURE__ */
|
|
309
|
+
/* @__PURE__ */ A("p", {
|
|
314
310
|
className: "mt-1 text-sm text-text-secondary",
|
|
315
311
|
children: e.label
|
|
316
312
|
})
|
|
@@ -318,182 +314,182 @@ var N = {
|
|
|
318
314
|
}, e.label);
|
|
319
315
|
})
|
|
320
316
|
})] }),
|
|
321
|
-
/* @__PURE__ */
|
|
317
|
+
/* @__PURE__ */ j("div", {
|
|
322
318
|
className: "grid grid-cols-1 gap-6 lg:grid-cols-3",
|
|
323
|
-
children: [/* @__PURE__ */
|
|
319
|
+
children: [/* @__PURE__ */ j("div", {
|
|
324
320
|
className: "lg:col-span-2 space-y-6",
|
|
325
321
|
children: [
|
|
326
|
-
/* @__PURE__ */
|
|
322
|
+
/* @__PURE__ */ j("div", { children: [/* @__PURE__ */ A("h3", {
|
|
327
323
|
className: "text-base font-semibold mb-3 text-text-primary",
|
|
328
324
|
children: "Quick Actions"
|
|
329
|
-
}), /* @__PURE__ */
|
|
325
|
+
}), /* @__PURE__ */ A("div", {
|
|
330
326
|
className: "grid grid-cols-2 sm:grid-cols-3 lg:grid-cols-5 gap-3",
|
|
331
327
|
children: [
|
|
332
328
|
{
|
|
333
329
|
label: "Service Config",
|
|
334
|
-
icon:
|
|
330
|
+
icon: S,
|
|
335
331
|
color: "bg-status-warning-bg-subtle text-status-warning-text",
|
|
336
332
|
path: "/cart-owner/service-config"
|
|
337
333
|
},
|
|
338
334
|
{
|
|
339
335
|
label: "Manage Offerings",
|
|
340
|
-
icon:
|
|
336
|
+
icon: b,
|
|
341
337
|
color: "bg-[var(--color-accent-soft)] text-text-primary",
|
|
342
338
|
path: "/cart-owner/inventory"
|
|
343
339
|
},
|
|
344
340
|
{
|
|
345
341
|
label: "View Orders",
|
|
346
|
-
icon:
|
|
342
|
+
icon: C,
|
|
347
343
|
color: "bg-status-success-bg-subtle text-status-success-text",
|
|
348
344
|
path: "/cart-owner/orders"
|
|
349
345
|
},
|
|
350
346
|
{
|
|
351
347
|
label: "Analytics",
|
|
352
|
-
icon:
|
|
348
|
+
icon: u,
|
|
353
349
|
color: "bg-accent-purple-subtle text-text-primary",
|
|
354
350
|
path: "/cart-owner/analytics"
|
|
355
351
|
},
|
|
356
352
|
{
|
|
357
353
|
label: "Staff",
|
|
358
|
-
icon:
|
|
354
|
+
icon: D,
|
|
359
355
|
color: "bg-accent-purple-subtle text-text-primary",
|
|
360
356
|
path: "/cart-owner/staff"
|
|
361
357
|
}
|
|
362
358
|
].map((e) => {
|
|
363
359
|
let n = e.icon;
|
|
364
|
-
return /* @__PURE__ */
|
|
360
|
+
return /* @__PURE__ */ j("button", {
|
|
365
361
|
type: "button",
|
|
366
|
-
onClick: () =>
|
|
362
|
+
onClick: () => U(e.path),
|
|
367
363
|
className: t("flex flex-col items-center gap-2 rounded-lg p-4 transition-colors hover:opacity-80", e.color),
|
|
368
|
-
children: [/* @__PURE__ */
|
|
364
|
+
children: [/* @__PURE__ */ A(n, { className: "h-5 w-5" }), /* @__PURE__ */ A("span", {
|
|
369
365
|
className: "text-xs font-medium text-center",
|
|
370
366
|
children: e.label
|
|
371
367
|
})]
|
|
372
368
|
}, e.label);
|
|
373
369
|
})
|
|
374
370
|
})] }),
|
|
375
|
-
/* @__PURE__ */
|
|
371
|
+
/* @__PURE__ */ j("div", { children: [/* @__PURE__ */ j("div", {
|
|
376
372
|
className: "flex items-center justify-between mb-3",
|
|
377
|
-
children: [/* @__PURE__ */
|
|
373
|
+
children: [/* @__PURE__ */ A("h3", {
|
|
378
374
|
className: "text-base font-semibold text-text-primary",
|
|
379
375
|
children: "Recent Orders"
|
|
380
|
-
}), /* @__PURE__ */
|
|
376
|
+
}), /* @__PURE__ */ A("button", {
|
|
381
377
|
type: "button",
|
|
382
|
-
onClick: () =>
|
|
378
|
+
onClick: () => U("/cart-owner/orders"),
|
|
383
379
|
className: "text-xs text-text-secondary hover:text-text-primary transition-colors",
|
|
384
380
|
children: "View All Orders"
|
|
385
381
|
})]
|
|
386
|
-
}), /* @__PURE__ */
|
|
382
|
+
}), /* @__PURE__ */ A("div", {
|
|
387
383
|
className: "space-y-3",
|
|
388
|
-
children:
|
|
384
|
+
children: X.map((e) => /* @__PURE__ */ A("div", {
|
|
389
385
|
className: "rounded-lg border border-border-subtle bg-bg-surface p-4 shadow-sm",
|
|
390
|
-
children: /* @__PURE__ */
|
|
386
|
+
children: /* @__PURE__ */ j("div", {
|
|
391
387
|
className: "flex flex-col lg:flex-row lg:items-start lg:justify-between gap-3",
|
|
392
|
-
children: [/* @__PURE__ */
|
|
388
|
+
children: [/* @__PURE__ */ j("div", {
|
|
393
389
|
className: "flex-1 min-w-0",
|
|
394
390
|
children: [
|
|
395
|
-
/* @__PURE__ */
|
|
391
|
+
/* @__PURE__ */ j("div", {
|
|
396
392
|
className: "flex flex-wrap items-center gap-2 mb-1",
|
|
397
393
|
children: [
|
|
398
|
-
/* @__PURE__ */
|
|
394
|
+
/* @__PURE__ */ j("h4", {
|
|
399
395
|
className: "font-semibold text-text-primary text-sm",
|
|
400
396
|
children: ["#", e.id]
|
|
401
397
|
}),
|
|
402
|
-
/* @__PURE__ */
|
|
398
|
+
/* @__PURE__ */ A("span", {
|
|
403
399
|
className: t("inline-flex items-center rounded-full px-2 py-0.5 text-xs font-medium capitalize", B[e.status] || "bg-bg-sunken text-text-secondary"),
|
|
404
400
|
children: e.status
|
|
405
401
|
}),
|
|
406
|
-
e.priority === "urgent" && /* @__PURE__ */
|
|
402
|
+
e.priority === "urgent" && /* @__PURE__ */ A(c, { className: "h-4 w-4 text-status-error-text" })
|
|
407
403
|
]
|
|
408
404
|
}),
|
|
409
|
-
/* @__PURE__ */
|
|
405
|
+
/* @__PURE__ */ j("p", {
|
|
410
406
|
className: "text-xs text-text-secondary mb-1",
|
|
411
407
|
children: ["Customer: ", e.customerName]
|
|
412
408
|
}),
|
|
413
|
-
/* @__PURE__ */
|
|
409
|
+
/* @__PURE__ */ j("p", {
|
|
414
410
|
className: "text-xs text-text-secondary mb-1 truncate",
|
|
415
411
|
children: ["Items: ", e.items.join(", ")]
|
|
416
412
|
}),
|
|
417
|
-
/* @__PURE__ */
|
|
413
|
+
/* @__PURE__ */ j("div", {
|
|
418
414
|
className: "flex flex-wrap items-center gap-3 text-xs text-text-secondary",
|
|
419
|
-
children: [/* @__PURE__ */
|
|
415
|
+
children: [/* @__PURE__ */ A("span", {
|
|
420
416
|
className: "font-semibold text-text-primary",
|
|
421
|
-
children:
|
|
422
|
-
}), /* @__PURE__ */
|
|
417
|
+
children: a(e.total, { minimumFractionDigits: 0 })
|
|
418
|
+
}), /* @__PURE__ */ j("span", {
|
|
423
419
|
className: "flex items-center gap-1",
|
|
424
|
-
children: [/* @__PURE__ */
|
|
420
|
+
children: [/* @__PURE__ */ A(m, { className: "h-3 w-3" }), e.timestamp]
|
|
425
421
|
})]
|
|
426
422
|
})
|
|
427
423
|
]
|
|
428
|
-
}), /* @__PURE__ */
|
|
424
|
+
}), /* @__PURE__ */ j("div", {
|
|
429
425
|
className: "flex gap-2",
|
|
430
426
|
children: [
|
|
431
|
-
/* @__PURE__ */
|
|
427
|
+
/* @__PURE__ */ j("button", {
|
|
432
428
|
type: "button",
|
|
433
|
-
onClick: () =>
|
|
429
|
+
onClick: () => U("/cart-owner/orders"),
|
|
434
430
|
className: "inline-flex items-center gap-1 rounded-md border border-border-subtle px-3 py-1.5 text-xs font-medium text-text-primary hover:bg-bg-sunken transition-colors",
|
|
435
|
-
children: [/* @__PURE__ */
|
|
431
|
+
children: [/* @__PURE__ */ A(g, { className: "h-3 w-3" }), "View"]
|
|
436
432
|
}),
|
|
437
|
-
e.status === "pending" && /* @__PURE__ */
|
|
433
|
+
e.status === "pending" && /* @__PURE__ */ j("button", {
|
|
438
434
|
type: "button",
|
|
439
|
-
onClick: () =>
|
|
435
|
+
onClick: () => ee(e.id),
|
|
440
436
|
className: "inline-flex items-center gap-1 rounded-md bg-status-success-bg-subtle px-3 py-1.5 text-xs font-medium text-status-success-text hover:bg-status-success-bg-subtle transition-colors",
|
|
441
|
-
children: [/* @__PURE__ */
|
|
437
|
+
children: [/* @__PURE__ */ A(f, { className: "h-3 w-3" }), "Accept"]
|
|
442
438
|
}),
|
|
443
|
-
e.status === "preparing" && /* @__PURE__ */
|
|
439
|
+
e.status === "preparing" && /* @__PURE__ */ j("button", {
|
|
444
440
|
type: "button",
|
|
445
|
-
onClick: () =>
|
|
441
|
+
onClick: () => te(e.id),
|
|
446
442
|
className: "inline-flex items-center gap-1 rounded-md bg-[var(--color-accent-soft)] px-3 py-1.5 text-xs font-medium text-text-primary hover:bg-[var(--color-accent-soft)] transition-colors",
|
|
447
|
-
children: [/* @__PURE__ */
|
|
443
|
+
children: [/* @__PURE__ */ A(f, { className: "h-3 w-3" }), "Mark Ready"]
|
|
448
444
|
})
|
|
449
445
|
]
|
|
450
446
|
})]
|
|
451
447
|
})
|
|
452
448
|
}, e.id))
|
|
453
449
|
})] }),
|
|
454
|
-
/* @__PURE__ */
|
|
450
|
+
/* @__PURE__ */ j("div", {
|
|
455
451
|
className: "rounded-lg border border-border-subtle bg-bg-surface shadow-sm",
|
|
456
|
-
children: [/* @__PURE__ */
|
|
452
|
+
children: [/* @__PURE__ */ j("div", {
|
|
457
453
|
className: "flex items-center justify-between border-b border-border-subtle px-5 py-4",
|
|
458
|
-
children: [/* @__PURE__ */
|
|
454
|
+
children: [/* @__PURE__ */ A("h3", {
|
|
459
455
|
className: "text-base font-semibold text-text-primary",
|
|
460
456
|
children: "Revenue (Last 7 Days)"
|
|
461
|
-
}), /* @__PURE__ */
|
|
457
|
+
}), /* @__PURE__ */ A("button", {
|
|
462
458
|
type: "button",
|
|
463
|
-
onClick: () =>
|
|
459
|
+
onClick: () => U("/cart-owner/analytics"),
|
|
464
460
|
className: "text-xs text-text-secondary hover:text-text-primary transition-colors",
|
|
465
461
|
children: "View Analytics"
|
|
466
462
|
})]
|
|
467
|
-
}), /* @__PURE__ */
|
|
463
|
+
}), /* @__PURE__ */ A("div", {
|
|
468
464
|
className: "overflow-x-auto",
|
|
469
|
-
children: /* @__PURE__ */
|
|
465
|
+
children: /* @__PURE__ */ j("table", {
|
|
470
466
|
className: "w-full text-sm",
|
|
471
|
-
children: [/* @__PURE__ */
|
|
467
|
+
children: [/* @__PURE__ */ A("thead", { children: /* @__PURE__ */ j("tr", {
|
|
472
468
|
className: "border-b border-border-subtle",
|
|
473
469
|
children: [
|
|
474
|
-
/* @__PURE__ */
|
|
470
|
+
/* @__PURE__ */ A("th", {
|
|
475
471
|
className: "px-5 py-3 text-left font-medium text-text-secondary",
|
|
476
472
|
children: "Date"
|
|
477
473
|
}),
|
|
478
|
-
/* @__PURE__ */
|
|
474
|
+
/* @__PURE__ */ A("th", {
|
|
479
475
|
className: "px-5 py-3 text-right font-medium text-text-secondary",
|
|
480
476
|
children: "Orders"
|
|
481
477
|
}),
|
|
482
|
-
/* @__PURE__ */
|
|
478
|
+
/* @__PURE__ */ A("th", {
|
|
483
479
|
className: "px-5 py-3 text-right font-medium text-text-secondary",
|
|
484
480
|
children: "Revenue"
|
|
485
481
|
}),
|
|
486
|
-
/* @__PURE__ */
|
|
482
|
+
/* @__PURE__ */ A("th", {
|
|
487
483
|
className: "px-5 py-3 text-left font-medium text-text-secondary",
|
|
488
484
|
children: "Trend"
|
|
489
485
|
})
|
|
490
486
|
]
|
|
491
|
-
}) }), /* @__PURE__ */
|
|
492
|
-
let n = Math.max(...
|
|
493
|
-
return /* @__PURE__ */
|
|
487
|
+
}) }), /* @__PURE__ */ A("tbody", { children: J.map((e, t) => {
|
|
488
|
+
let n = Math.max(...J.map((e) => e.revenue)), r = e.revenue / n * 100;
|
|
489
|
+
return /* @__PURE__ */ j("tr", {
|
|
494
490
|
className: "border-b border-border-subtle last:border-0",
|
|
495
491
|
children: [
|
|
496
|
-
/* @__PURE__ */
|
|
492
|
+
/* @__PURE__ */ A("td", {
|
|
497
493
|
className: "px-5 py-3 text-text-primary text-xs",
|
|
498
494
|
children: new Date(e.date).toLocaleDateString("en-IN", {
|
|
499
495
|
day: "2-digit",
|
|
@@ -501,21 +497,21 @@ var N = {
|
|
|
501
497
|
weekday: "short"
|
|
502
498
|
})
|
|
503
499
|
}),
|
|
504
|
-
/* @__PURE__ */
|
|
500
|
+
/* @__PURE__ */ A("td", {
|
|
505
501
|
className: "px-5 py-3 text-right text-text-primary",
|
|
506
502
|
children: e.orders
|
|
507
503
|
}),
|
|
508
|
-
/* @__PURE__ */
|
|
504
|
+
/* @__PURE__ */ A("td", {
|
|
509
505
|
className: "px-5 py-3 text-right font-medium text-text-primary",
|
|
510
|
-
children:
|
|
506
|
+
children: a(e.revenue, { minimumFractionDigits: 0 })
|
|
511
507
|
}),
|
|
512
|
-
/* @__PURE__ */
|
|
508
|
+
/* @__PURE__ */ A("td", {
|
|
513
509
|
className: "px-5 py-3 w-40",
|
|
514
|
-
children: /* @__PURE__ */
|
|
510
|
+
children: /* @__PURE__ */ A("div", {
|
|
515
511
|
className: "h-4 rounded bg-bg-sunken overflow-hidden",
|
|
516
|
-
children: /* @__PURE__ */
|
|
512
|
+
children: /* @__PURE__ */ A("div", {
|
|
517
513
|
className: "h-full rounded bg-[var(--color-accent-soft)]",
|
|
518
|
-
style: { width: `${
|
|
514
|
+
style: { width: `${r}%` }
|
|
519
515
|
})
|
|
520
516
|
})
|
|
521
517
|
})
|
|
@@ -525,40 +521,40 @@ var N = {
|
|
|
525
521
|
})
|
|
526
522
|
})]
|
|
527
523
|
}),
|
|
528
|
-
/* @__PURE__ */
|
|
524
|
+
/* @__PURE__ */ j("div", {
|
|
529
525
|
className: "rounded-lg border border-border-subtle bg-bg-surface p-5 shadow-sm",
|
|
530
|
-
children: [/* @__PURE__ */
|
|
526
|
+
children: [/* @__PURE__ */ A("h3", {
|
|
531
527
|
className: "text-base font-semibold text-text-primary mb-4",
|
|
532
528
|
children: "This Month Summary"
|
|
533
|
-
}), /* @__PURE__ */
|
|
529
|
+
}), /* @__PURE__ */ j("div", {
|
|
534
530
|
className: "grid grid-cols-1 sm:grid-cols-3 gap-4",
|
|
535
531
|
children: [
|
|
536
|
-
/* @__PURE__ */
|
|
532
|
+
/* @__PURE__ */ j("div", {
|
|
537
533
|
className: "text-center p-3 rounded-lg bg-bg-sunken/50",
|
|
538
|
-
children: [/* @__PURE__ */
|
|
534
|
+
children: [/* @__PURE__ */ A("div", {
|
|
539
535
|
className: "text-xl font-bold text-text-primary",
|
|
540
|
-
children:
|
|
541
|
-
}), /* @__PURE__ */
|
|
536
|
+
children: a(q.totalRevenue, { minimumFractionDigits: 0 })
|
|
537
|
+
}), /* @__PURE__ */ A("div", {
|
|
542
538
|
className: "text-xs text-text-secondary mt-1",
|
|
543
539
|
children: "Total Revenue"
|
|
544
540
|
})]
|
|
545
541
|
}),
|
|
546
|
-
/* @__PURE__ */
|
|
542
|
+
/* @__PURE__ */ j("div", {
|
|
547
543
|
className: "text-center p-3 rounded-lg bg-bg-sunken/50",
|
|
548
|
-
children: [/* @__PURE__ */
|
|
544
|
+
children: [/* @__PURE__ */ A("div", {
|
|
549
545
|
className: "text-xl font-bold text-text-primary",
|
|
550
|
-
children:
|
|
551
|
-
}), /* @__PURE__ */
|
|
546
|
+
children: q.totalOrders
|
|
547
|
+
}), /* @__PURE__ */ A("div", {
|
|
552
548
|
className: "text-xs text-text-secondary mt-1",
|
|
553
549
|
children: "Total Orders"
|
|
554
550
|
})]
|
|
555
551
|
}),
|
|
556
|
-
/* @__PURE__ */
|
|
552
|
+
/* @__PURE__ */ j("div", {
|
|
557
553
|
className: "text-center p-3 rounded-lg bg-bg-sunken/50",
|
|
558
|
-
children: [/* @__PURE__ */
|
|
554
|
+
children: [/* @__PURE__ */ A("div", {
|
|
559
555
|
className: "text-xl font-bold text-text-primary",
|
|
560
|
-
children:
|
|
561
|
-
}), /* @__PURE__ */
|
|
556
|
+
children: q.customerCount
|
|
557
|
+
}), /* @__PURE__ */ A("div", {
|
|
562
558
|
className: "text-xs text-text-secondary mt-1",
|
|
563
559
|
children: "Unique Customers"
|
|
564
560
|
})]
|
|
@@ -567,30 +563,30 @@ var N = {
|
|
|
567
563
|
})]
|
|
568
564
|
})
|
|
569
565
|
]
|
|
570
|
-
}), /* @__PURE__ */
|
|
566
|
+
}), /* @__PURE__ */ j("div", {
|
|
571
567
|
className: "space-y-6",
|
|
572
568
|
children: [
|
|
573
|
-
/* @__PURE__ */
|
|
569
|
+
/* @__PURE__ */ j("div", {
|
|
574
570
|
className: "rounded-lg border border-border-subtle bg-bg-surface p-5 shadow-sm",
|
|
575
|
-
children: [/* @__PURE__ */
|
|
571
|
+
children: [/* @__PURE__ */ j("div", {
|
|
576
572
|
className: "flex items-center justify-between mb-4",
|
|
577
|
-
children: [/* @__PURE__ */
|
|
573
|
+
children: [/* @__PURE__ */ j("h3", {
|
|
578
574
|
className: "text-base font-semibold text-text-primary flex items-center gap-2",
|
|
579
|
-
children: [/* @__PURE__ */
|
|
580
|
-
}), /* @__PURE__ */
|
|
575
|
+
children: [/* @__PURE__ */ A(d, { className: "h-4 w-4" }), "Notifications"]
|
|
576
|
+
}), /* @__PURE__ */ A("span", {
|
|
581
577
|
className: "inline-flex items-center justify-center rounded-full bg-status-error-text text-white text-[10px] font-bold h-5 w-5",
|
|
582
|
-
children:
|
|
578
|
+
children: R.length
|
|
583
579
|
})]
|
|
584
|
-
}), /* @__PURE__ */
|
|
580
|
+
}), /* @__PURE__ */ A("div", {
|
|
585
581
|
className: "space-y-3",
|
|
586
|
-
children:
|
|
582
|
+
children: R.map((e) => /* @__PURE__ */ j("div", {
|
|
587
583
|
className: "flex items-start gap-2",
|
|
588
|
-
children: [/* @__PURE__ */
|
|
584
|
+
children: [/* @__PURE__ */ A(s, { className: t("h-4 w-4 mt-0.5 shrink-0", H[e.type]) }), /* @__PURE__ */ j("div", {
|
|
589
585
|
className: "min-w-0",
|
|
590
|
-
children: [/* @__PURE__ */
|
|
586
|
+
children: [/* @__PURE__ */ A("p", {
|
|
591
587
|
className: "text-xs text-text-primary leading-tight",
|
|
592
588
|
children: e.message
|
|
593
|
-
}), /* @__PURE__ */
|
|
589
|
+
}), /* @__PURE__ */ A("p", {
|
|
594
590
|
className: "text-[10px] text-text-secondary mt-0.5",
|
|
595
591
|
children: e.time
|
|
596
592
|
})]
|
|
@@ -598,173 +594,173 @@ var N = {
|
|
|
598
594
|
}, e.id))
|
|
599
595
|
})]
|
|
600
596
|
}),
|
|
601
|
-
/* @__PURE__ */
|
|
597
|
+
/* @__PURE__ */ j("div", {
|
|
602
598
|
className: "rounded-lg border border-border-subtle bg-bg-surface p-5 shadow-sm",
|
|
603
|
-
children: [/* @__PURE__ */
|
|
599
|
+
children: [/* @__PURE__ */ j("h3", {
|
|
604
600
|
className: "text-base font-semibold text-text-primary mb-4 flex items-center gap-2",
|
|
605
|
-
children: [/* @__PURE__ */
|
|
606
|
-
}), /* @__PURE__ */
|
|
601
|
+
children: [/* @__PURE__ */ A(_, { className: "h-4 w-4 text-status-warning-text" }), "Top Selling Items"]
|
|
602
|
+
}), /* @__PURE__ */ A("div", {
|
|
607
603
|
className: "space-y-3",
|
|
608
|
-
children:
|
|
604
|
+
children: I.map((e, t) => /* @__PURE__ */ j("div", {
|
|
609
605
|
className: "flex items-center justify-between",
|
|
610
|
-
children: [/* @__PURE__ */
|
|
606
|
+
children: [/* @__PURE__ */ j("div", {
|
|
611
607
|
className: "flex items-center gap-2 min-w-0",
|
|
612
|
-
children: [/* @__PURE__ */
|
|
608
|
+
children: [/* @__PURE__ */ A("span", {
|
|
613
609
|
className: "text-sm font-bold text-text-secondary w-5",
|
|
614
610
|
children: t + 1
|
|
615
|
-
}), /* @__PURE__ */
|
|
611
|
+
}), /* @__PURE__ */ j("div", {
|
|
616
612
|
className: "min-w-0",
|
|
617
|
-
children: [/* @__PURE__ */
|
|
613
|
+
children: [/* @__PURE__ */ A("p", {
|
|
618
614
|
className: "text-xs font-medium text-text-primary truncate",
|
|
619
615
|
children: e.name
|
|
620
|
-
}), /* @__PURE__ */
|
|
616
|
+
}), /* @__PURE__ */ j("p", {
|
|
621
617
|
className: "text-[10px] text-text-secondary",
|
|
622
618
|
children: [e.quantity, " sold"]
|
|
623
619
|
})]
|
|
624
620
|
})]
|
|
625
|
-
}), /* @__PURE__ */
|
|
621
|
+
}), /* @__PURE__ */ A("span", {
|
|
626
622
|
className: "text-xs font-semibold text-text-primary",
|
|
627
|
-
children:
|
|
623
|
+
children: a(e.revenue, { minimumFractionDigits: 0 })
|
|
628
624
|
})]
|
|
629
625
|
}, e.name))
|
|
630
626
|
})]
|
|
631
627
|
}),
|
|
632
|
-
/* @__PURE__ */
|
|
628
|
+
/* @__PURE__ */ j("div", {
|
|
633
629
|
className: "rounded-lg border border-border-subtle bg-bg-surface p-5 shadow-sm",
|
|
634
|
-
children: [/* @__PURE__ */
|
|
630
|
+
children: [/* @__PURE__ */ j("div", {
|
|
635
631
|
className: "flex items-center justify-between mb-4",
|
|
636
|
-
children: [/* @__PURE__ */
|
|
632
|
+
children: [/* @__PURE__ */ j("h3", {
|
|
637
633
|
className: "text-base font-semibold text-text-primary flex items-center gap-2",
|
|
638
|
-
children: [/* @__PURE__ */ O
|
|
639
|
-
}), /* @__PURE__ */
|
|
634
|
+
children: [/* @__PURE__ */ A(O, { className: "h-4 w-4" }), "Staff Overview"]
|
|
635
|
+
}), /* @__PURE__ */ A("button", {
|
|
640
636
|
type: "button",
|
|
641
|
-
onClick: () =>
|
|
637
|
+
onClick: () => U("/cart-owner/staff"),
|
|
642
638
|
className: "text-xs text-text-secondary hover:text-text-primary transition-colors",
|
|
643
639
|
children: "Manage"
|
|
644
640
|
})]
|
|
645
|
-
}), /* @__PURE__ */
|
|
641
|
+
}), /* @__PURE__ */ A("div", {
|
|
646
642
|
className: "space-y-3",
|
|
647
|
-
children:
|
|
643
|
+
children: L.map((e) => /* @__PURE__ */ j("div", {
|
|
648
644
|
className: "flex items-center justify-between",
|
|
649
|
-
children: [/* @__PURE__ */
|
|
645
|
+
children: [/* @__PURE__ */ j("div", {
|
|
650
646
|
className: "flex items-center gap-2",
|
|
651
|
-
children: [/* @__PURE__ */
|
|
647
|
+
children: [/* @__PURE__ */ A("div", { className: t("w-2 h-2 rounded-full", V[e.status]) }), /* @__PURE__ */ j("div", { children: [/* @__PURE__ */ A("p", {
|
|
652
648
|
className: "text-xs font-medium text-text-primary",
|
|
653
649
|
children: e.name
|
|
654
|
-
}), /* @__PURE__ */
|
|
650
|
+
}), /* @__PURE__ */ A("p", {
|
|
655
651
|
className: "text-[10px] text-text-secondary",
|
|
656
652
|
children: e.role
|
|
657
653
|
})] })]
|
|
658
|
-
}), /* @__PURE__ */
|
|
654
|
+
}), /* @__PURE__ */ A("span", {
|
|
659
655
|
className: "text-[10px] capitalize text-text-secondary",
|
|
660
656
|
children: e.status.replace("-", " ")
|
|
661
657
|
})]
|
|
662
658
|
}, e.name))
|
|
663
659
|
})]
|
|
664
660
|
}),
|
|
665
|
-
/* @__PURE__ */
|
|
661
|
+
/* @__PURE__ */ j("div", {
|
|
666
662
|
className: "rounded-lg border border-border-subtle bg-bg-surface p-5 shadow-sm",
|
|
667
|
-
children: [/* @__PURE__ */
|
|
663
|
+
children: [/* @__PURE__ */ A("h3", {
|
|
668
664
|
className: "text-base font-semibold text-text-primary mb-4",
|
|
669
665
|
children: "Quick Stats"
|
|
670
|
-
}), /* @__PURE__ */
|
|
666
|
+
}), /* @__PURE__ */ j("div", {
|
|
671
667
|
className: "space-y-3",
|
|
672
668
|
children: [
|
|
673
|
-
/* @__PURE__ */
|
|
669
|
+
/* @__PURE__ */ j("div", {
|
|
674
670
|
className: "flex items-center justify-between",
|
|
675
|
-
children: [/* @__PURE__ */
|
|
671
|
+
children: [/* @__PURE__ */ A("span", {
|
|
676
672
|
className: "text-xs text-text-secondary",
|
|
677
673
|
children: "Active Offerings"
|
|
678
|
-
}), /* @__PURE__ */
|
|
674
|
+
}), /* @__PURE__ */ A("span", {
|
|
679
675
|
className: "text-sm font-semibold text-text-primary",
|
|
680
|
-
children:
|
|
676
|
+
children: q.activeOfferings
|
|
681
677
|
})]
|
|
682
678
|
}),
|
|
683
|
-
/* @__PURE__ */
|
|
679
|
+
/* @__PURE__ */ j("div", {
|
|
684
680
|
className: "flex items-center justify-between",
|
|
685
|
-
children: [/* @__PURE__ */
|
|
681
|
+
children: [/* @__PURE__ */ A("span", {
|
|
686
682
|
className: "text-xs text-text-secondary",
|
|
687
683
|
children: "Customer Rating"
|
|
688
|
-
}), /* @__PURE__ */
|
|
684
|
+
}), /* @__PURE__ */ j("span", {
|
|
689
685
|
className: "text-sm font-semibold text-text-primary flex items-center gap-1",
|
|
690
|
-
children: [/* @__PURE__ */
|
|
686
|
+
children: [/* @__PURE__ */ A(w, { className: "h-3 w-3 text-status-warning-text fill-status-warning-text" }), q.rating]
|
|
691
687
|
})]
|
|
692
688
|
}),
|
|
693
|
-
/* @__PURE__ */
|
|
689
|
+
/* @__PURE__ */ j("div", {
|
|
694
690
|
className: "flex items-center justify-between",
|
|
695
|
-
children: [/* @__PURE__ */
|
|
691
|
+
children: [/* @__PURE__ */ A("span", {
|
|
696
692
|
className: "text-xs text-text-secondary",
|
|
697
693
|
children: "Total Customers"
|
|
698
|
-
}), /* @__PURE__ */
|
|
694
|
+
}), /* @__PURE__ */ A("span", {
|
|
699
695
|
className: "text-sm font-semibold text-text-primary",
|
|
700
|
-
children:
|
|
696
|
+
children: q.customerCount
|
|
701
697
|
})]
|
|
702
698
|
})
|
|
703
699
|
]
|
|
704
700
|
})]
|
|
705
701
|
}),
|
|
706
|
-
/* @__PURE__ */
|
|
702
|
+
/* @__PURE__ */ j("div", {
|
|
707
703
|
className: "rounded-lg border border-border-subtle bg-bg-surface p-5 shadow-sm",
|
|
708
|
-
children: [/* @__PURE__ */
|
|
704
|
+
children: [/* @__PURE__ */ A("h3", {
|
|
709
705
|
className: "text-base font-semibold text-text-primary mb-3",
|
|
710
706
|
children: "Business Settings"
|
|
711
|
-
}), /* @__PURE__ */
|
|
707
|
+
}), /* @__PURE__ */ A("div", {
|
|
712
708
|
className: "space-y-2",
|
|
713
709
|
children: [
|
|
714
710
|
{
|
|
715
711
|
label: "Service Settings",
|
|
716
|
-
icon:
|
|
712
|
+
icon: S,
|
|
717
713
|
path: "/cart-owner/settings"
|
|
718
714
|
},
|
|
719
715
|
{
|
|
720
716
|
label: "Business Profile",
|
|
721
|
-
icon:
|
|
717
|
+
icon: h,
|
|
722
718
|
path: "/cart-owner/profile"
|
|
723
719
|
},
|
|
724
720
|
{
|
|
725
721
|
label: "Add Offerings",
|
|
726
|
-
icon:
|
|
722
|
+
icon: x,
|
|
727
723
|
path: "/cart-owner/inventory"
|
|
728
724
|
}
|
|
729
725
|
].map((e) => {
|
|
730
726
|
let t = e.icon;
|
|
731
|
-
return /* @__PURE__ */
|
|
727
|
+
return /* @__PURE__ */ j("button", {
|
|
732
728
|
type: "button",
|
|
733
|
-
onClick: () =>
|
|
729
|
+
onClick: () => U(e.path),
|
|
734
730
|
className: "w-full flex items-center justify-between rounded-md border border-border-subtle px-3 py-2 text-xs font-medium text-text-primary hover:bg-bg-sunken transition-colors",
|
|
735
|
-
children: [/* @__PURE__ */
|
|
731
|
+
children: [/* @__PURE__ */ j("span", {
|
|
736
732
|
className: "flex items-center gap-2",
|
|
737
|
-
children: [/* @__PURE__ */
|
|
738
|
-
}), /* @__PURE__ */
|
|
733
|
+
children: [/* @__PURE__ */ A(t, { className: "h-3.5 w-3.5" }), e.label]
|
|
734
|
+
}), /* @__PURE__ */ A(p, { className: "h-3 w-3 text-text-secondary" })]
|
|
739
735
|
}, e.label);
|
|
740
736
|
})
|
|
741
737
|
})]
|
|
742
738
|
}),
|
|
743
|
-
/* @__PURE__ */
|
|
739
|
+
/* @__PURE__ */ j("div", {
|
|
744
740
|
className: "rounded-lg border border-border-subtle bg-bg-surface p-5 shadow-sm",
|
|
745
|
-
children: [/* @__PURE__ */
|
|
741
|
+
children: [/* @__PURE__ */ A("h3", {
|
|
746
742
|
className: "text-base font-semibold text-text-primary mb-3",
|
|
747
743
|
children: "Recent Activity"
|
|
748
|
-
}), /* @__PURE__ */
|
|
744
|
+
}), /* @__PURE__ */ j("div", {
|
|
749
745
|
className: "space-y-2 text-xs",
|
|
750
746
|
children: [
|
|
751
|
-
/* @__PURE__ */
|
|
747
|
+
/* @__PURE__ */ j("div", {
|
|
752
748
|
className: "flex items-center gap-2",
|
|
753
|
-
children: [/* @__PURE__ */
|
|
749
|
+
children: [/* @__PURE__ */ A(s, { className: "h-3.5 w-3.5 text-status-success-text" }), /* @__PURE__ */ A("span", {
|
|
754
750
|
className: "text-text-secondary",
|
|
755
751
|
children: "Order #ORD-003 delivered"
|
|
756
752
|
})]
|
|
757
753
|
}),
|
|
758
|
-
/* @__PURE__ */
|
|
754
|
+
/* @__PURE__ */ j("div", {
|
|
759
755
|
className: "flex items-center gap-2",
|
|
760
|
-
children: [/* @__PURE__ */
|
|
756
|
+
children: [/* @__PURE__ */ A(s, { className: "h-3.5 w-3.5 text-text-primary" }), /* @__PURE__ */ A("span", {
|
|
761
757
|
className: "text-text-secondary",
|
|
762
758
|
children: "Inventory updated"
|
|
763
759
|
})]
|
|
764
760
|
}),
|
|
765
|
-
/* @__PURE__ */
|
|
761
|
+
/* @__PURE__ */ j("div", {
|
|
766
762
|
className: "flex items-center gap-2",
|
|
767
|
-
children: [/* @__PURE__ */
|
|
763
|
+
children: [/* @__PURE__ */ A(s, { className: "h-3.5 w-3.5 text-status-warning-text" }), /* @__PURE__ */ A("span", {
|
|
768
764
|
className: "text-text-secondary",
|
|
769
765
|
children: "New customer review"
|
|
770
766
|
})]
|