@burdenoff/microfe-coolandlovely 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/coolandlovely/components/EmptyState.js +17 -21
- package/dist/coolandlovely/components/EmptyState.js.map +1 -1
- package/dist/coolandlovely/components/InvestmentCard.js +25 -23
- package/dist/coolandlovely/components/InvestmentCard.js.map +1 -1
- package/dist/coolandlovely/components/MetricsCard.js +18 -12
- package/dist/coolandlovely/components/MetricsCard.js.map +1 -1
- package/dist/coolandlovely/components/PageLayout.js +38 -19
- package/dist/coolandlovely/components/PageLayout.js.map +1 -1
- package/dist/coolandlovely/components/RatingDisplay.js +3 -3
- package/dist/coolandlovely/components/RatingDisplay.js.map +1 -1
- package/dist/coolandlovely/components/StatusBadge.js +36 -16
- package/dist/coolandlovely/components/StatusBadge.js.map +1 -1
- package/dist/coolandlovely/pages/HomePage.js +219 -204
- package/dist/coolandlovely/pages/HomePage.js.map +1 -1
- package/dist/coolandlovely/pages/admin/AdminAnalyticsPage.js +98 -92
- package/dist/coolandlovely/pages/admin/AdminAnalyticsPage.js.map +1 -1
- package/dist/coolandlovely/pages/admin/AdminDashboard.js +111 -77
- package/dist/coolandlovely/pages/admin/AdminDashboard.js.map +1 -1
- package/dist/coolandlovely/pages/admin/AdminFinancialPage.js +49 -43
- package/dist/coolandlovely/pages/admin/AdminFinancialPage.js.map +1 -1
- package/dist/coolandlovely/pages/admin/AdminOrdersPage.js +234 -229
- package/dist/coolandlovely/pages/admin/AdminOrdersPage.js.map +1 -1
- package/dist/coolandlovely/pages/admin/AdminProfilePage.js +67 -62
- package/dist/coolandlovely/pages/admin/AdminProfilePage.js.map +1 -1
- package/dist/coolandlovely/pages/admin/AdminSettingsPage.js +235 -230
- package/dist/coolandlovely/pages/admin/AdminSettingsPage.js.map +1 -1
- package/dist/coolandlovely/pages/admin/CartManagementPage.js +291 -286
- package/dist/coolandlovely/pages/admin/CartManagementPage.js.map +1 -1
- package/dist/coolandlovely/pages/admin/UserManagementPage.js +287 -282
- package/dist/coolandlovely/pages/admin/UserManagementPage.js.map +1 -1
- package/dist/coolandlovely/pages/cart-owner/AnalyticsDashboard.js +108 -100
- package/dist/coolandlovely/pages/cart-owner/AnalyticsDashboard.js.map +1 -1
- package/dist/coolandlovely/pages/cart-owner/BusinessSettingsPage.js +260 -255
- package/dist/coolandlovely/pages/cart-owner/BusinessSettingsPage.js.map +1 -1
- package/dist/coolandlovely/pages/cart-owner/CartOwnerDashboard.js +596 -554
- package/dist/coolandlovely/pages/cart-owner/CartOwnerDashboard.js.map +1 -1
- package/dist/coolandlovely/pages/cart-owner/CartOwnerProfilePage.js +187 -182
- package/dist/coolandlovely/pages/cart-owner/CartOwnerProfilePage.js.map +1 -1
- package/dist/coolandlovely/pages/cart-owner/CartServiceConfigPage.js +229 -221
- package/dist/coolandlovely/pages/cart-owner/CartServiceConfigPage.js.map +1 -1
- package/dist/coolandlovely/pages/cart-owner/InventoryManagementPage.js +675 -674
- package/dist/coolandlovely/pages/cart-owner/InventoryManagementPage.js.map +1 -1
- package/dist/coolandlovely/pages/cart-owner/OrderManagementPage.js +525 -524
- package/dist/coolandlovely/pages/cart-owner/OrderManagementPage.js.map +1 -1
- package/dist/coolandlovely/pages/cart-owner/StaffManagementPage.js +264 -266
- package/dist/coolandlovely/pages/cart-owner/StaffManagementPage.js.map +1 -1
- package/dist/coolandlovely/pages/common/HelpSupportPage.js +137 -137
- package/dist/coolandlovely/pages/common/HelpSupportPage.js.map +1 -1
- package/dist/coolandlovely/pages/common/NotificationCenterPage.js +81 -75
- package/dist/coolandlovely/pages/common/NotificationCenterPage.js.map +1 -1
- package/dist/coolandlovely/pages/common/SettingsPage.js +745 -736
- package/dist/coolandlovely/pages/common/SettingsPage.js.map +1 -1
- package/dist/coolandlovely/pages/customer/BookingDetailsPage.js +394 -357
- package/dist/coolandlovely/pages/customer/BookingDetailsPage.js.map +1 -1
- package/dist/coolandlovely/pages/customer/CartDetailPage.js +189 -186
- package/dist/coolandlovely/pages/customer/CartDetailPage.js.map +1 -1
- package/dist/coolandlovely/pages/customer/CartDiscoveryPage.js +222 -211
- package/dist/coolandlovely/pages/customer/CartDiscoveryPage.js.map +1 -1
- package/dist/coolandlovely/pages/customer/CheckoutPage.js +219 -222
- package/dist/coolandlovely/pages/customer/CheckoutPage.js.map +1 -1
- package/dist/coolandlovely/pages/customer/CustomerDashboard.js +446 -404
- package/dist/coolandlovely/pages/customer/CustomerDashboard.js.map +1 -1
- package/dist/coolandlovely/pages/customer/CustomerProfilePage.js +525 -488
- package/dist/coolandlovely/pages/customer/CustomerProfilePage.js.map +1 -1
- package/dist/coolandlovely/pages/customer/DirectServiceBookingPage.js +522 -513
- package/dist/coolandlovely/pages/customer/DirectServiceBookingPage.js.map +1 -1
- package/dist/coolandlovely/pages/customer/FavoritesPage.js +94 -84
- package/dist/coolandlovely/pages/customer/FavoritesPage.js.map +1 -1
- package/dist/coolandlovely/pages/customer/OrderHistoryPage.js +121 -112
- package/dist/coolandlovely/pages/customer/OrderHistoryPage.js.map +1 -1
- package/dist/coolandlovely/pages/customer/OrderTrackingPage.js +312 -275
- package/dist/coolandlovely/pages/customer/OrderTrackingPage.js.map +1 -1
- package/dist/coolandlovely/pages/customer/PaymentMethodsPage.js +90 -84
- package/dist/coolandlovely/pages/customer/PaymentMethodsPage.js.map +1 -1
- package/dist/coolandlovely/pages/customer/ReviewsPage.js +99 -89
- package/dist/coolandlovely/pages/customer/ReviewsPage.js.map +1 -1
- package/dist/coolandlovely/pages/customer/SavedAddressesPage.js +74 -68
- package/dist/coolandlovely/pages/customer/SavedAddressesPage.js.map +1 -1
- package/dist/coolandlovely/pages/investor/InvestmentDetailsPage.js +317 -279
- package/dist/coolandlovely/pages/investor/InvestmentDetailsPage.js.map +1 -1
- package/dist/coolandlovely/pages/investor/InvestmentOpportunitiesPage.js +249 -243
- package/dist/coolandlovely/pages/investor/InvestmentOpportunitiesPage.js.map +1 -1
- package/dist/coolandlovely/pages/investor/InvestorAnalyticsPage.js +87 -81
- package/dist/coolandlovely/pages/investor/InvestorAnalyticsPage.js.map +1 -1
- package/dist/coolandlovely/pages/investor/InvestorDashboard.js +359 -323
- package/dist/coolandlovely/pages/investor/InvestorDashboard.js.map +1 -1
- package/dist/coolandlovely/pages/investor/InvestorInvestmentsPage.js +115 -109
- package/dist/coolandlovely/pages/investor/InvestorInvestmentsPage.js.map +1 -1
- package/dist/coolandlovely/pages/investor/InvestorPortfolioPage.js +179 -146
- package/dist/coolandlovely/pages/investor/InvestorPortfolioPage.js.map +1 -1
- package/dist/coolandlovely/pages/investor/InvestorProfilePage.js +397 -392
- package/dist/coolandlovely/pages/investor/InvestorProfilePage.js.map +1 -1
- package/dist/coolandlovely/pages/worker/TaskDetailsPage.js +364 -327
- package/dist/coolandlovely/pages/worker/TaskDetailsPage.js.map +1 -1
- package/dist/coolandlovely/pages/worker/WorkerDashboard.js +580 -543
- package/dist/coolandlovely/pages/worker/WorkerDashboard.js.map +1 -1
- package/dist/coolandlovely/pages/worker/WorkerOrdersPage.js +114 -109
- package/dist/coolandlovely/pages/worker/WorkerOrdersPage.js.map +1 -1
- package/dist/coolandlovely/pages/worker/WorkerProfilePage.js +115 -110
- package/dist/coolandlovely/pages/worker/WorkerProfilePage.js.map +1 -1
- package/dist/coolandlovely/pages/worker/WorkerSchedulePage.js +100 -95
- package/dist/coolandlovely/pages/worker/WorkerSchedulePage.js.map +1 -1
- package/package.json +3 -3
|
@@ -6,13 +6,14 @@ import { formatCurrency as i } from "../../utils/formatters.js";
|
|
|
6
6
|
import { useEffect as a, useState as o } from "react";
|
|
7
7
|
import { Award as s, BarChart3 as c, IndianRupee as l, Loader2 as u, ShoppingBag as d, Star as f, Timer as p, Users as m, Zap as h } from "lucide-react";
|
|
8
8
|
import { jsx as g, jsxs as _ } from "react/jsx-runtime";
|
|
9
|
+
import { EmphasisPanel as v, PagePurpose as y } from "@burdenoff/fe-libs/ui";
|
|
9
10
|
//#region src/coolandlovely/pages/admin/AdminAnalyticsPage.tsx
|
|
10
|
-
function
|
|
11
|
-
let { currentUser:
|
|
11
|
+
function b() {
|
|
12
|
+
let { currentUser: b } = e(), [x, S] = o(null), [C, w] = o(!0), [T, E] = o("month"), [D, O] = o("overview");
|
|
12
13
|
a(() => {
|
|
13
|
-
|
|
14
|
+
w(!0);
|
|
14
15
|
let e = setTimeout(() => {
|
|
15
|
-
|
|
16
|
+
S({
|
|
16
17
|
revenue: {
|
|
17
18
|
total: 125e5,
|
|
18
19
|
growth: 15.2,
|
|
@@ -114,12 +115,12 @@ function v() {
|
|
|
114
115
|
revenue: 189e4
|
|
115
116
|
}
|
|
116
117
|
] }
|
|
117
|
-
}),
|
|
118
|
+
}), w(!1);
|
|
118
119
|
}, 800);
|
|
119
120
|
return () => clearTimeout(e);
|
|
120
|
-
}, [
|
|
121
|
-
let
|
|
122
|
-
if (
|
|
121
|
+
}, [T]);
|
|
122
|
+
let k = (e) => e >= 1e7 ? `₹${(e / 1e7).toFixed(1)}Cr` : e >= 1e5 ? `₹${(e / 1e5).toFixed(1)}L` : i(e, { minimumFractionDigits: 0 }), A = (e) => e === 0 ? /* @__PURE__ */ g(s, { className: "h-5 w-5 text-status-warning-text" }) : e === 1 ? /* @__PURE__ */ g(s, { className: "h-5 w-5 text-text-secondary" }) : e === 2 ? /* @__PURE__ */ g(s, { className: "h-5 w-5 text-status-warning-text" }) : /* @__PURE__ */ g(c, { className: "h-5 w-5 text-text-secondary" });
|
|
123
|
+
if (C || !x) return /* @__PURE__ */ g(n, {
|
|
123
124
|
title: "Platform Analytics",
|
|
124
125
|
description: "Loading analytics...",
|
|
125
126
|
children: /* @__PURE__ */ _("div", {
|
|
@@ -130,7 +131,7 @@ function v() {
|
|
|
130
131
|
})]
|
|
131
132
|
})
|
|
132
133
|
});
|
|
133
|
-
let
|
|
134
|
+
let j = [
|
|
134
135
|
{
|
|
135
136
|
key: "overview",
|
|
136
137
|
label: "Overview",
|
|
@@ -156,11 +157,16 @@ function v() {
|
|
|
156
157
|
title: "Platform Analytics",
|
|
157
158
|
description: "Comprehensive platform metrics and trends",
|
|
158
159
|
children: [
|
|
160
|
+
/* @__PURE__ */ g(y, {
|
|
161
|
+
className: "mb-6",
|
|
162
|
+
icon: /* @__PURE__ */ g(c, { className: "h-4 w-4" }),
|
|
163
|
+
children: "The numbers behind the whole marketplace. Track revenue, orders, users and active carts over any period, drill into revenue, user and performance breakdowns, and spot top performers — so platform decisions are grounded in data, not guesswork."
|
|
164
|
+
}),
|
|
159
165
|
/* @__PURE__ */ _("div", {
|
|
160
166
|
className: "flex flex-col sm:flex-row sm:items-center sm:justify-between gap-4 mb-6",
|
|
161
167
|
children: [/* @__PURE__ */ _("select", {
|
|
162
|
-
value:
|
|
163
|
-
onChange: (e) =>
|
|
168
|
+
value: T,
|
|
169
|
+
onChange: (e) => E(e.target.value),
|
|
164
170
|
className: "rounded-lg border border-border-subtle bg-bg-surface py-2 px-3 text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)] w-fit",
|
|
165
171
|
children: [
|
|
166
172
|
/* @__PURE__ */ g("option", {
|
|
@@ -189,35 +195,35 @@ function v() {
|
|
|
189
195
|
children: ["Last updated: ", (/* @__PURE__ */ new Date()).toLocaleString("en-IN")]
|
|
190
196
|
})]
|
|
191
197
|
}),
|
|
192
|
-
/* @__PURE__ */ _(
|
|
193
|
-
className: "grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-4 gap-4 mb-8",
|
|
198
|
+
/* @__PURE__ */ _(v, {
|
|
199
|
+
className: "grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-4 gap-4 mb-8 p-4",
|
|
194
200
|
children: [
|
|
195
201
|
/* @__PURE__ */ g(r, {
|
|
196
202
|
icon: /* @__PURE__ */ g(l, { className: "h-5 w-5" }),
|
|
197
|
-
value:
|
|
203
|
+
value: k(x.revenue.total),
|
|
198
204
|
label: "Total Revenue",
|
|
199
205
|
trend: "up",
|
|
200
|
-
trendValue: `+${
|
|
206
|
+
trendValue: `+${x.revenue.growth}%`
|
|
201
207
|
}),
|
|
202
208
|
/* @__PURE__ */ g(r, {
|
|
203
209
|
icon: /* @__PURE__ */ g(d, { className: "h-5 w-5" }),
|
|
204
|
-
value:
|
|
210
|
+
value: x.orders.total.toLocaleString("en-IN"),
|
|
205
211
|
label: "Total Orders",
|
|
206
212
|
trend: "up",
|
|
207
|
-
trendValue: `+${
|
|
213
|
+
trendValue: `+${x.orders.growth}%`
|
|
208
214
|
}),
|
|
209
215
|
/* @__PURE__ */ g(r, {
|
|
210
216
|
icon: /* @__PURE__ */ g(m, { className: "h-5 w-5" }),
|
|
211
|
-
value:
|
|
217
|
+
value: x.users.active.toLocaleString("en-IN"),
|
|
212
218
|
label: "Active Users",
|
|
213
219
|
trend: "up",
|
|
214
|
-
trendValue: `+${
|
|
220
|
+
trendValue: `+${x.users.growth}%`
|
|
215
221
|
}),
|
|
216
222
|
/* @__PURE__ */ g(r, {
|
|
217
223
|
icon: /* @__PURE__ */ g(c, { className: "h-5 w-5" }),
|
|
218
|
-
value:
|
|
224
|
+
value: x.carts.active.toLocaleString("en-IN"),
|
|
219
225
|
label: "Active Carts",
|
|
220
|
-
trendValue: `${
|
|
226
|
+
trendValue: `${x.carts.pending} pending`
|
|
221
227
|
})
|
|
222
228
|
]
|
|
223
229
|
}),
|
|
@@ -227,12 +233,12 @@ function v() {
|
|
|
227
233
|
className: "border-b border-border-subtle",
|
|
228
234
|
children: /* @__PURE__ */ g("nav", {
|
|
229
235
|
className: "flex -mb-px overflow-x-auto",
|
|
230
|
-
children:
|
|
236
|
+
children: j.map((e) => {
|
|
231
237
|
let n = e.icon;
|
|
232
238
|
return /* @__PURE__ */ _("button", {
|
|
233
239
|
type: "button",
|
|
234
|
-
onClick: () =>
|
|
235
|
-
className: t("flex items-center gap-2 py-3 px-4 sm:px-6 text-sm font-medium whitespace-nowrap border-b-2 transition-colors",
|
|
240
|
+
onClick: () => O(e.key),
|
|
241
|
+
className: t("flex items-center gap-2 py-3 px-4 sm:px-6 text-sm font-medium whitespace-nowrap border-b-2 transition-colors", D === e.key ? "border-primary text-primary" : "border-transparent text-text-secondary hover:text-text-primary"),
|
|
236
242
|
children: [/* @__PURE__ */ g(n, { className: "h-4 w-4" }), /* @__PURE__ */ g("span", {
|
|
237
243
|
className: "hidden sm:inline",
|
|
238
244
|
children: e.label
|
|
@@ -243,7 +249,7 @@ function v() {
|
|
|
243
249
|
}), /* @__PURE__ */ _("div", {
|
|
244
250
|
className: "p-4 sm:p-6",
|
|
245
251
|
children: [
|
|
246
|
-
|
|
252
|
+
D === "overview" && /* @__PURE__ */ _("div", {
|
|
247
253
|
className: "space-y-8",
|
|
248
254
|
children: [/* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("h3", {
|
|
249
255
|
className: "text-lg font-semibold text-text-primary mb-4",
|
|
@@ -252,53 +258,53 @@ function v() {
|
|
|
252
258
|
className: "grid grid-cols-1 sm:grid-cols-3 gap-4",
|
|
253
259
|
children: [
|
|
254
260
|
/* @__PURE__ */ _("div", {
|
|
255
|
-
className: "rounded-lg border border-
|
|
261
|
+
className: "rounded-lg border border-status-success-border/30 bg-status-success-bg-subtle/10 p-4",
|
|
256
262
|
children: [
|
|
257
263
|
/* @__PURE__ */ g("p", {
|
|
258
|
-
className: "text-sm text-
|
|
264
|
+
className: "text-sm text-status-success-text",
|
|
259
265
|
children: "Completed Orders"
|
|
260
266
|
}),
|
|
261
267
|
/* @__PURE__ */ g("p", {
|
|
262
|
-
className: "text-2xl font-bold text-
|
|
263
|
-
children:
|
|
268
|
+
className: "text-2xl font-bold text-status-success-text",
|
|
269
|
+
children: x.orders.completed.toLocaleString("en-IN")
|
|
264
270
|
}),
|
|
265
271
|
/* @__PURE__ */ _("p", {
|
|
266
|
-
className: "text-sm text-
|
|
267
|
-
children: [(
|
|
272
|
+
className: "text-sm text-status-success-text",
|
|
273
|
+
children: [(x.orders.completed / x.orders.total * 100).toFixed(1), "% of total"]
|
|
268
274
|
})
|
|
269
275
|
]
|
|
270
276
|
}),
|
|
271
277
|
/* @__PURE__ */ _("div", {
|
|
272
|
-
className: "rounded-lg border border-
|
|
278
|
+
className: "rounded-lg border border-status-warning-border/30 bg-status-warning-bg-subtle/10 p-4",
|
|
273
279
|
children: [
|
|
274
280
|
/* @__PURE__ */ g("p", {
|
|
275
|
-
className: "text-sm text-
|
|
281
|
+
className: "text-sm text-status-warning-text",
|
|
276
282
|
children: "Pending Orders"
|
|
277
283
|
}),
|
|
278
284
|
/* @__PURE__ */ g("p", {
|
|
279
|
-
className: "text-2xl font-bold text-
|
|
280
|
-
children:
|
|
285
|
+
className: "text-2xl font-bold text-status-warning-text",
|
|
286
|
+
children: x.orders.pending.toLocaleString("en-IN")
|
|
281
287
|
}),
|
|
282
288
|
/* @__PURE__ */ _("p", {
|
|
283
|
-
className: "text-sm text-
|
|
284
|
-
children: [(
|
|
289
|
+
className: "text-sm text-status-warning-text",
|
|
290
|
+
children: [(x.orders.pending / x.orders.total * 100).toFixed(1), "% of total"]
|
|
285
291
|
})
|
|
286
292
|
]
|
|
287
293
|
}),
|
|
288
294
|
/* @__PURE__ */ _("div", {
|
|
289
|
-
className: "rounded-lg border border-
|
|
295
|
+
className: "rounded-lg border border-status-error-border/30 bg-status-error-bg-subtle/10 p-4",
|
|
290
296
|
children: [
|
|
291
297
|
/* @__PURE__ */ g("p", {
|
|
292
|
-
className: "text-sm text-
|
|
298
|
+
className: "text-sm text-status-error-text",
|
|
293
299
|
children: "Cancelled Orders"
|
|
294
300
|
}),
|
|
295
301
|
/* @__PURE__ */ g("p", {
|
|
296
|
-
className: "text-2xl font-bold text-
|
|
297
|
-
children:
|
|
302
|
+
className: "text-2xl font-bold text-status-error-text",
|
|
303
|
+
children: x.orders.cancelled.toLocaleString("en-IN")
|
|
298
304
|
}),
|
|
299
305
|
/* @__PURE__ */ _("p", {
|
|
300
|
-
className: "text-sm text-
|
|
301
|
-
children: [(
|
|
306
|
+
className: "text-sm text-status-error-text",
|
|
307
|
+
children: [(x.orders.cancelled / x.orders.total * 100).toFixed(1), "% of total"]
|
|
302
308
|
})
|
|
303
309
|
]
|
|
304
310
|
})
|
|
@@ -332,14 +338,14 @@ function v() {
|
|
|
332
338
|
]
|
|
333
339
|
}) }), /* @__PURE__ */ g("tbody", {
|
|
334
340
|
className: "divide-y divide-border",
|
|
335
|
-
children:
|
|
341
|
+
children: x.carts.topPerforming.map((e, t) => /* @__PURE__ */ _("tr", {
|
|
336
342
|
className: "hover:bg-accent/50 transition-colors",
|
|
337
343
|
children: [
|
|
338
344
|
/* @__PURE__ */ g("td", {
|
|
339
345
|
className: "px-4 py-3",
|
|
340
346
|
children: /* @__PURE__ */ _("div", {
|
|
341
347
|
className: "flex items-center gap-2",
|
|
342
|
-
children: [
|
|
348
|
+
children: [A(t), /* @__PURE__ */ g("span", {
|
|
343
349
|
className: "text-sm font-medium text-text-primary",
|
|
344
350
|
children: e.name
|
|
345
351
|
})]
|
|
@@ -347,7 +353,7 @@ function v() {
|
|
|
347
353
|
}),
|
|
348
354
|
/* @__PURE__ */ g("td", {
|
|
349
355
|
className: "px-4 py-3 text-sm text-right font-medium text-text-primary",
|
|
350
|
-
children:
|
|
356
|
+
children: k(e.revenue)
|
|
351
357
|
}),
|
|
352
358
|
/* @__PURE__ */ g("td", {
|
|
353
359
|
className: "px-4 py-3 text-sm text-right text-text-primary",
|
|
@@ -357,7 +363,7 @@ function v() {
|
|
|
357
363
|
className: "px-4 py-3 text-sm text-right text-text-primary",
|
|
358
364
|
children: /* @__PURE__ */ _("span", {
|
|
359
365
|
className: "flex items-center justify-end gap-1",
|
|
360
|
-
children: [/* @__PURE__ */ g(f, { className: "h-3.5 w-3.5 fill-
|
|
366
|
+
children: [/* @__PURE__ */ g(f, { className: "h-3.5 w-3.5 fill-status-warning-text text-status-warning-text" }), e.rating]
|
|
361
367
|
})
|
|
362
368
|
})
|
|
363
369
|
]
|
|
@@ -366,19 +372,19 @@ function v() {
|
|
|
366
372
|
})
|
|
367
373
|
})] })]
|
|
368
374
|
}),
|
|
369
|
-
|
|
375
|
+
D === "revenue" && /* @__PURE__ */ _("div", {
|
|
370
376
|
className: "space-y-8",
|
|
371
377
|
children: [/* @__PURE__ */ _("div", {
|
|
372
378
|
className: "grid grid-cols-1 md:grid-cols-3 gap-4",
|
|
373
379
|
children: [
|
|
374
380
|
/* @__PURE__ */ _("div", {
|
|
375
|
-
className: "rounded-lg border border-blue-
|
|
381
|
+
className: "rounded-lg border border-accent-blue-subtle/30 bg-accent-blue-subtle/10 p-6",
|
|
376
382
|
children: [/* @__PURE__ */ g("h4", {
|
|
377
|
-
className: "text-sm font-medium text-
|
|
383
|
+
className: "text-sm font-medium text-accent-blue mb-2",
|
|
378
384
|
children: "This Month"
|
|
379
385
|
}), /* @__PURE__ */ g("p", {
|
|
380
|
-
className: "text-2xl font-bold text-
|
|
381
|
-
children:
|
|
386
|
+
className: "text-2xl font-bold text-accent-blue",
|
|
387
|
+
children: k(x.revenue.thisMonth)
|
|
382
388
|
})]
|
|
383
389
|
}),
|
|
384
390
|
/* @__PURE__ */ _("div", {
|
|
@@ -388,17 +394,17 @@ function v() {
|
|
|
388
394
|
children: "Last Month"
|
|
389
395
|
}), /* @__PURE__ */ g("p", {
|
|
390
396
|
className: "text-2xl font-bold text-text-primary",
|
|
391
|
-
children:
|
|
397
|
+
children: k(x.revenue.lastMonth)
|
|
392
398
|
})]
|
|
393
399
|
}),
|
|
394
400
|
/* @__PURE__ */ _("div", {
|
|
395
|
-
className: "rounded-lg border border-
|
|
401
|
+
className: "rounded-lg border border-status-success-border/30 bg-status-success-bg-subtle/10 p-6",
|
|
396
402
|
children: [/* @__PURE__ */ g("h4", {
|
|
397
|
-
className: "text-sm font-medium text-
|
|
403
|
+
className: "text-sm font-medium text-status-success-text mb-2",
|
|
398
404
|
children: "Average Order Value"
|
|
399
405
|
}), /* @__PURE__ */ _("p", {
|
|
400
|
-
className: "text-2xl font-bold text-
|
|
401
|
-
children: ["₹",
|
|
406
|
+
className: "text-2xl font-bold text-status-success-text",
|
|
407
|
+
children: ["₹", x.orders.averageOrderValue]
|
|
402
408
|
})]
|
|
403
409
|
})
|
|
404
410
|
]
|
|
@@ -407,11 +413,11 @@ function v() {
|
|
|
407
413
|
children: "Revenue by City"
|
|
408
414
|
}), /* @__PURE__ */ g("div", {
|
|
409
415
|
className: "space-y-3",
|
|
410
|
-
children:
|
|
416
|
+
children: x.geography.topCities.map((e, t) => /* @__PURE__ */ _("div", {
|
|
411
417
|
className: "flex items-center justify-between p-4 rounded-lg border border-border-subtle bg-bg-sunken/30",
|
|
412
418
|
children: [/* @__PURE__ */ _("div", {
|
|
413
419
|
className: "flex items-center gap-3",
|
|
414
|
-
children: [
|
|
420
|
+
children: [A(t), /* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("p", {
|
|
415
421
|
className: "font-medium text-text-primary",
|
|
416
422
|
children: e.city
|
|
417
423
|
}), /* @__PURE__ */ _("p", {
|
|
@@ -422,38 +428,38 @@ function v() {
|
|
|
422
428
|
className: "text-right",
|
|
423
429
|
children: [/* @__PURE__ */ g("p", {
|
|
424
430
|
className: "font-bold text-text-primary",
|
|
425
|
-
children:
|
|
431
|
+
children: k(e.revenue)
|
|
426
432
|
}), /* @__PURE__ */ _("p", {
|
|
427
433
|
className: "text-sm text-text-secondary",
|
|
428
|
-
children: [(e.revenue /
|
|
434
|
+
children: [(e.revenue / x.revenue.total * 100).toFixed(1), "%"]
|
|
429
435
|
})]
|
|
430
436
|
})]
|
|
431
437
|
}, e.city))
|
|
432
438
|
})] })]
|
|
433
439
|
}),
|
|
434
|
-
|
|
440
|
+
D === "users" && /* @__PURE__ */ _("div", {
|
|
435
441
|
className: "space-y-8",
|
|
436
442
|
children: [/* @__PURE__ */ g("div", {
|
|
437
443
|
className: "grid grid-cols-1 md:grid-cols-4 gap-4",
|
|
438
444
|
children: [
|
|
439
445
|
{
|
|
440
446
|
label: "Customers",
|
|
441
|
-
value:
|
|
447
|
+
value: x.users.customers,
|
|
442
448
|
color: "blue"
|
|
443
449
|
},
|
|
444
450
|
{
|
|
445
451
|
label: "Cart Owners",
|
|
446
|
-
value:
|
|
452
|
+
value: x.users.cartOwners,
|
|
447
453
|
color: "green"
|
|
448
454
|
},
|
|
449
455
|
{
|
|
450
456
|
label: "Workers",
|
|
451
|
-
value:
|
|
457
|
+
value: x.users.workers,
|
|
452
458
|
color: "yellow"
|
|
453
459
|
},
|
|
454
460
|
{
|
|
455
461
|
label: "Investors",
|
|
456
|
-
value:
|
|
462
|
+
value: x.users.investors,
|
|
457
463
|
color: "purple"
|
|
458
464
|
}
|
|
459
465
|
].map((e) => /* @__PURE__ */ _("div", {
|
|
@@ -469,7 +475,7 @@ function v() {
|
|
|
469
475
|
}),
|
|
470
476
|
/* @__PURE__ */ _("p", {
|
|
471
477
|
className: t("text-sm", `text-${e.color}-600/80 dark:text-${e.color}-400/80`),
|
|
472
|
-
children: [(e.value /
|
|
478
|
+
children: [(e.value / x.users.total * 100).toFixed(1), "%"]
|
|
473
479
|
})
|
|
474
480
|
]
|
|
475
481
|
}, e.label))
|
|
@@ -484,26 +490,26 @@ function v() {
|
|
|
484
490
|
className: "text-sm text-text-secondary mb-2",
|
|
485
491
|
children: "New Users This Month"
|
|
486
492
|
}), /* @__PURE__ */ g("p", {
|
|
487
|
-
className: "text-3xl font-bold text-
|
|
488
|
-
children:
|
|
493
|
+
className: "text-3xl font-bold text-accent-blue",
|
|
494
|
+
children: x.users.newThisMonth
|
|
489
495
|
})] }), /* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("p", {
|
|
490
496
|
className: "text-sm text-text-secondary mb-2",
|
|
491
497
|
children: "Active Users Rate"
|
|
492
498
|
}), /* @__PURE__ */ _("p", {
|
|
493
|
-
className: "text-3xl font-bold text-
|
|
494
|
-
children: [(
|
|
499
|
+
className: "text-3xl font-bold text-status-success-text",
|
|
500
|
+
children: [(x.users.active / x.users.total * 100).toFixed(1), "%"]
|
|
495
501
|
})] })]
|
|
496
502
|
})]
|
|
497
503
|
})]
|
|
498
504
|
}),
|
|
499
|
-
|
|
505
|
+
D === "performance" && /* @__PURE__ */ _("div", {
|
|
500
506
|
className: "space-y-8",
|
|
501
507
|
children: [
|
|
502
508
|
/* @__PURE__ */ _("div", {
|
|
503
509
|
className: "grid grid-cols-1 md:grid-cols-3 gap-6",
|
|
504
510
|
children: [
|
|
505
511
|
/* @__PURE__ */ _("div", {
|
|
506
|
-
className: "rounded-lg border border-border-
|
|
512
|
+
className: "rounded-lg border border-border-seam bg-bg-surface p-6 bg-gloss-card shadow-pop",
|
|
507
513
|
children: [
|
|
508
514
|
/* @__PURE__ */ _("div", {
|
|
509
515
|
className: "flex items-center gap-2 mb-2",
|
|
@@ -514,7 +520,7 @@ function v() {
|
|
|
514
520
|
}),
|
|
515
521
|
/* @__PURE__ */ _("p", {
|
|
516
522
|
className: "text-3xl font-bold text-text-primary",
|
|
517
|
-
children: [
|
|
523
|
+
children: [x.performance.averageDeliveryTime, " min"]
|
|
518
524
|
}),
|
|
519
525
|
/* @__PURE__ */ g("p", {
|
|
520
526
|
className: "text-sm text-text-secondary mt-1",
|
|
@@ -523,7 +529,7 @@ function v() {
|
|
|
523
529
|
]
|
|
524
530
|
}),
|
|
525
531
|
/* @__PURE__ */ _("div", {
|
|
526
|
-
className: "rounded-lg border border-border-
|
|
532
|
+
className: "rounded-lg border border-border-seam bg-bg-surface p-6 bg-gloss-card shadow-pop",
|
|
527
533
|
children: [
|
|
528
534
|
/* @__PURE__ */ _("div", {
|
|
529
535
|
className: "flex items-center gap-2 mb-2",
|
|
@@ -534,7 +540,7 @@ function v() {
|
|
|
534
540
|
}),
|
|
535
541
|
/* @__PURE__ */ _("p", {
|
|
536
542
|
className: "text-3xl font-bold text-text-primary flex items-center gap-1",
|
|
537
|
-
children: [/* @__PURE__ */ g(f, { className: "h-6 w-6 fill-
|
|
543
|
+
children: [/* @__PURE__ */ g(f, { className: "h-6 w-6 fill-status-warning-text text-status-warning-text" }), x.performance.customerSatisfaction]
|
|
538
544
|
}),
|
|
539
545
|
/* @__PURE__ */ g("p", {
|
|
540
546
|
className: "text-sm text-text-secondary mt-1",
|
|
@@ -543,7 +549,7 @@ function v() {
|
|
|
543
549
|
]
|
|
544
550
|
}),
|
|
545
551
|
/* @__PURE__ */ _("div", {
|
|
546
|
-
className: "rounded-lg border border-border-
|
|
552
|
+
className: "rounded-lg border border-border-seam bg-bg-surface p-6 bg-gloss-card shadow-pop",
|
|
547
553
|
children: [
|
|
548
554
|
/* @__PURE__ */ _("div", {
|
|
549
555
|
className: "flex items-center gap-2 mb-2",
|
|
@@ -554,7 +560,7 @@ function v() {
|
|
|
554
560
|
}),
|
|
555
561
|
/* @__PURE__ */ _("p", {
|
|
556
562
|
className: "text-3xl font-bold text-text-primary",
|
|
557
|
-
children: [
|
|
563
|
+
children: [x.performance.platformFee, "%"]
|
|
558
564
|
}),
|
|
559
565
|
/* @__PURE__ */ g("p", {
|
|
560
566
|
className: "text-sm text-text-secondary mt-1",
|
|
@@ -578,39 +584,39 @@ function v() {
|
|
|
578
584
|
className: "text-sm text-text-secondary mb-2",
|
|
579
585
|
children: "Operating Costs"
|
|
580
586
|
}), /* @__PURE__ */ g("p", {
|
|
581
|
-
className: "text-2xl font-bold text-
|
|
582
|
-
children:
|
|
587
|
+
className: "text-2xl font-bold text-status-error-text",
|
|
588
|
+
children: k(x.performance.operatingCosts)
|
|
583
589
|
})] }),
|
|
584
590
|
/* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("p", {
|
|
585
591
|
className: "text-sm text-text-secondary mb-2",
|
|
586
592
|
children: "Total Revenue"
|
|
587
593
|
}), /* @__PURE__ */ g("p", {
|
|
588
|
-
className: "text-2xl font-bold text-
|
|
589
|
-
children:
|
|
594
|
+
className: "text-2xl font-bold text-accent-blue",
|
|
595
|
+
children: k(x.revenue.total)
|
|
590
596
|
})] }),
|
|
591
597
|
/* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("p", {
|
|
592
598
|
className: "text-sm text-text-secondary mb-2",
|
|
593
599
|
children: "Net Profit"
|
|
594
600
|
}), /* @__PURE__ */ g("p", {
|
|
595
|
-
className: "text-2xl font-bold text-
|
|
596
|
-
children:
|
|
601
|
+
className: "text-2xl font-bold text-status-success-text",
|
|
602
|
+
children: k(x.performance.netProfit)
|
|
597
603
|
})] })
|
|
598
604
|
]
|
|
599
605
|
}),
|
|
600
606
|
/* @__PURE__ */ _("div", {
|
|
601
|
-
className: "mt-4 rounded-lg border border-border-
|
|
607
|
+
className: "mt-4 rounded-lg border border-border-seam bg-bg-surface p-4 bg-gloss-card shadow-pop",
|
|
602
608
|
children: [/* @__PURE__ */ g("p", {
|
|
603
609
|
className: "text-sm text-text-secondary",
|
|
604
610
|
children: "Profit Margin"
|
|
605
611
|
}), /* @__PURE__ */ _("p", {
|
|
606
612
|
className: "text-xl font-bold text-text-primary",
|
|
607
|
-
children: [(
|
|
613
|
+
children: [(x.performance.netProfit / x.revenue.total * 100).toFixed(1), "%"]
|
|
608
614
|
})]
|
|
609
615
|
})
|
|
610
616
|
]
|
|
611
617
|
}),
|
|
612
618
|
/* @__PURE__ */ _("div", {
|
|
613
|
-
className: "rounded-lg border border-border-
|
|
619
|
+
className: "rounded-lg border border-border-seam bg-bg-surface p-6 bg-gloss-card shadow-pop",
|
|
614
620
|
children: [/* @__PURE__ */ g("h3", {
|
|
615
621
|
className: "text-lg font-semibold text-text-primary mb-4",
|
|
616
622
|
children: "Today's Performance"
|
|
@@ -620,14 +626,14 @@ function v() {
|
|
|
620
626
|
className: "text-sm text-text-secondary mb-2",
|
|
621
627
|
children: "Orders Today"
|
|
622
628
|
}), /* @__PURE__ */ g("p", {
|
|
623
|
-
className: "text-3xl font-bold text-
|
|
624
|
-
children:
|
|
629
|
+
className: "text-3xl font-bold text-accent-blue",
|
|
630
|
+
children: x.orders.ordersToday
|
|
625
631
|
})] }), /* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("p", {
|
|
626
632
|
className: "text-sm text-text-secondary mb-2",
|
|
627
633
|
children: "Estimated Revenue"
|
|
628
634
|
}), /* @__PURE__ */ g("p", {
|
|
629
|
-
className: "text-3xl font-bold text-
|
|
630
|
-
children:
|
|
635
|
+
className: "text-3xl font-bold text-status-success-text",
|
|
636
|
+
children: k(x.orders.ordersToday * x.orders.averageOrderValue)
|
|
631
637
|
})] })]
|
|
632
638
|
})]
|
|
633
639
|
})
|
|
@@ -640,6 +646,6 @@ function v() {
|
|
|
640
646
|
});
|
|
641
647
|
}
|
|
642
648
|
//#endregion
|
|
643
|
-
export {
|
|
649
|
+
export { b as AdminAnalyticsPage };
|
|
644
650
|
|
|
645
651
|
//# sourceMappingURL=AdminAnalyticsPage.js.map
|