@burdenoff/microfe-coolandlovely 2026.625.2 → 2026.628.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (165) hide show
  1. package/dist/coolandlovely/CoolAndLovelyRoot.js +66 -122
  2. package/dist/coolandlovely/CoolAndLovelyRoot.js.map +1 -1
  3. package/dist/coolandlovely/CoolAndLovelyRoutes.js +87 -175
  4. package/dist/coolandlovely/CoolAndLovelyRoutes.js.map +1 -1
  5. package/dist/coolandlovely/components/Field.js +81 -0
  6. package/dist/coolandlovely/components/Field.js.map +1 -0
  7. package/dist/coolandlovely/components/StateViews.js +34 -0
  8. package/dist/coolandlovely/components/StateViews.js.map +1 -0
  9. package/dist/coolandlovely/components/StatusBadge.js +25 -22
  10. package/dist/coolandlovely/components/StatusBadge.js.map +1 -1
  11. package/dist/coolandlovely/components/TagList.js +21 -0
  12. package/dist/coolandlovely/components/TagList.js.map +1 -0
  13. package/dist/coolandlovely/components/Thumbnail.js +29 -0
  14. package/dist/coolandlovely/components/Thumbnail.js.map +1 -0
  15. package/dist/coolandlovely/context/CoolAndLovelyContext.js +10 -10
  16. package/dist/coolandlovely/context/CoolAndLovelyContext.js.map +1 -1
  17. package/dist/coolandlovely/hooks/index.js +1 -0
  18. package/dist/coolandlovely/hooks/useCoolAndLovelyApi.js +462 -169
  19. package/dist/coolandlovely/hooks/useCoolAndLovelyApi.js.map +1 -1
  20. package/dist/coolandlovely/pages/HomePage.js +251 -845
  21. package/dist/coolandlovely/pages/HomePage.js.map +1 -1
  22. package/dist/coolandlovely/pages/brands/BrandDetailPage.js +319 -0
  23. package/dist/coolandlovely/pages/brands/BrandDetailPage.js.map +1 -0
  24. package/dist/coolandlovely/pages/brands/BrandFormPage.js +190 -0
  25. package/dist/coolandlovely/pages/brands/BrandFormPage.js.map +1 -0
  26. package/dist/coolandlovely/pages/brands/BrandsListPage.js +158 -0
  27. package/dist/coolandlovely/pages/brands/BrandsListPage.js.map +1 -0
  28. package/dist/coolandlovely/pages/collaborations/CollaborationDetailPage.js +253 -0
  29. package/dist/coolandlovely/pages/collaborations/CollaborationDetailPage.js.map +1 -0
  30. package/dist/coolandlovely/pages/collaborations/CollaborationFormPage.js +206 -0
  31. package/dist/coolandlovely/pages/collaborations/CollaborationFormPage.js.map +1 -0
  32. package/dist/coolandlovely/pages/collaborations/CollaborationsListPage.js +129 -0
  33. package/dist/coolandlovely/pages/collaborations/CollaborationsListPage.js.map +1 -0
  34. package/dist/coolandlovely/pages/collections/CollectionDetailPage.js +217 -0
  35. package/dist/coolandlovely/pages/collections/CollectionDetailPage.js.map +1 -0
  36. package/dist/coolandlovely/pages/collections/CollectionFormPage.js +217 -0
  37. package/dist/coolandlovely/pages/collections/CollectionFormPage.js.map +1 -0
  38. package/dist/coolandlovely/pages/collections/CollectionsListPage.js +122 -0
  39. package/dist/coolandlovely/pages/collections/CollectionsListPage.js.map +1 -0
  40. package/dist/coolandlovely/pages/items/StyleItemDetailPage.js +230 -0
  41. package/dist/coolandlovely/pages/items/StyleItemDetailPage.js.map +1 -0
  42. package/dist/coolandlovely/pages/items/StyleItemFormPage.js +276 -0
  43. package/dist/coolandlovely/pages/items/StyleItemFormPage.js.map +1 -0
  44. package/dist/coolandlovely/pages/items/StyleItemsListPage.js +170 -0
  45. package/dist/coolandlovely/pages/items/StyleItemsListPage.js.map +1 -0
  46. package/dist/coolandlovely/pages/lookbooks/LookbookDetailPage.js +124 -0
  47. package/dist/coolandlovely/pages/lookbooks/LookbookDetailPage.js.map +1 -0
  48. package/dist/coolandlovely/pages/lookbooks/LookbooksListPage.js +156 -0
  49. package/dist/coolandlovely/pages/lookbooks/LookbooksListPage.js.map +1 -0
  50. package/dist/coolandlovely/pages/looks/LookDetailPage.js +238 -0
  51. package/dist/coolandlovely/pages/looks/LookDetailPage.js.map +1 -0
  52. package/dist/coolandlovely/pages/looks/LookFormPage.js +209 -0
  53. package/dist/coolandlovely/pages/looks/LookFormPage.js.map +1 -0
  54. package/dist/coolandlovely/pages/looks/LooksListPage.js +181 -0
  55. package/dist/coolandlovely/pages/looks/LooksListPage.js.map +1 -0
  56. package/dist/coolandlovely/pages/profile/StyleProfilePage.js +224 -0
  57. package/dist/coolandlovely/pages/profile/StyleProfilePage.js.map +1 -0
  58. package/dist/coolandlovely/pages/wardrobe/WardrobeFormPage.js +173 -0
  59. package/dist/coolandlovely/pages/wardrobe/WardrobeFormPage.js.map +1 -0
  60. package/dist/coolandlovely/pages/wardrobe/WardrobeListPage.js +172 -0
  61. package/dist/coolandlovely/pages/wardrobe/WardrobeListPage.js.map +1 -0
  62. package/dist/coolandlovely/store/coolandlovelyStore.js +2 -6
  63. package/dist/coolandlovely/store/coolandlovelyStore.js.map +1 -1
  64. package/dist/coolandlovely/utils/formatters.js +31 -23
  65. package/dist/coolandlovely/utils/formatters.js.map +1 -1
  66. package/dist/coolandlovely/utils/icons.js +34 -0
  67. package/dist/coolandlovely/utils/icons.js.map +1 -0
  68. package/dist/index.js +4 -4
  69. package/package.json +1 -1
  70. package/dist/coolandlovely/components/InvestmentCard.js +0 -98
  71. package/dist/coolandlovely/components/InvestmentCard.js.map +0 -1
  72. package/dist/coolandlovely/components/RatingDisplay.js +0 -35
  73. package/dist/coolandlovely/components/RatingDisplay.js.map +0 -1
  74. package/dist/coolandlovely/mocks/data.js +0 -1517
  75. package/dist/coolandlovely/mocks/data.js.map +0 -1
  76. package/dist/coolandlovely/mocks/users.js +0 -34
  77. package/dist/coolandlovely/mocks/users.js.map +0 -1
  78. package/dist/coolandlovely/pages/admin/AdminAnalyticsPage.js +0 -651
  79. package/dist/coolandlovely/pages/admin/AdminAnalyticsPage.js.map +0 -1
  80. package/dist/coolandlovely/pages/admin/AdminDashboard.js +0 -673
  81. package/dist/coolandlovely/pages/admin/AdminDashboard.js.map +0 -1
  82. package/dist/coolandlovely/pages/admin/AdminFinancialPage.js +0 -427
  83. package/dist/coolandlovely/pages/admin/AdminFinancialPage.js.map +0 -1
  84. package/dist/coolandlovely/pages/admin/AdminOrdersPage.js +0 -665
  85. package/dist/coolandlovely/pages/admin/AdminOrdersPage.js.map +0 -1
  86. package/dist/coolandlovely/pages/admin/AdminProfilePage.js +0 -264
  87. package/dist/coolandlovely/pages/admin/AdminProfilePage.js.map +0 -1
  88. package/dist/coolandlovely/pages/admin/AdminSettingsPage.js +0 -654
  89. package/dist/coolandlovely/pages/admin/AdminSettingsPage.js.map +0 -1
  90. package/dist/coolandlovely/pages/admin/CartManagementPage.js +0 -874
  91. package/dist/coolandlovely/pages/admin/CartManagementPage.js.map +0 -1
  92. package/dist/coolandlovely/pages/admin/UserManagementPage.js +0 -898
  93. package/dist/coolandlovely/pages/admin/UserManagementPage.js.map +0 -1
  94. package/dist/coolandlovely/pages/cart-owner/AnalyticsDashboard.js +0 -842
  95. package/dist/coolandlovely/pages/cart-owner/AnalyticsDashboard.js.map +0 -1
  96. package/dist/coolandlovely/pages/cart-owner/BusinessSettingsPage.js +0 -705
  97. package/dist/coolandlovely/pages/cart-owner/BusinessSettingsPage.js.map +0 -1
  98. package/dist/coolandlovely/pages/cart-owner/CartOwnerDashboard.js +0 -802
  99. package/dist/coolandlovely/pages/cart-owner/CartOwnerDashboard.js.map +0 -1
  100. package/dist/coolandlovely/pages/cart-owner/CartOwnerProfilePage.js +0 -891
  101. package/dist/coolandlovely/pages/cart-owner/CartOwnerProfilePage.js.map +0 -1
  102. package/dist/coolandlovely/pages/cart-owner/CartServiceConfigPage.js +0 -639
  103. package/dist/coolandlovely/pages/cart-owner/CartServiceConfigPage.js.map +0 -1
  104. package/dist/coolandlovely/pages/cart-owner/InventoryManagementPage.js +0 -914
  105. package/dist/coolandlovely/pages/cart-owner/InventoryManagementPage.js.map +0 -1
  106. package/dist/coolandlovely/pages/cart-owner/OrderManagementPage.js +0 -882
  107. package/dist/coolandlovely/pages/cart-owner/OrderManagementPage.js.map +0 -1
  108. package/dist/coolandlovely/pages/cart-owner/StaffManagementPage.js +0 -831
  109. package/dist/coolandlovely/pages/cart-owner/StaffManagementPage.js.map +0 -1
  110. package/dist/coolandlovely/pages/common/HelpSupportPage.js +0 -1325
  111. package/dist/coolandlovely/pages/common/HelpSupportPage.js.map +0 -1
  112. package/dist/coolandlovely/pages/common/NotificationCenterPage.js +0 -671
  113. package/dist/coolandlovely/pages/common/NotificationCenterPage.js.map +0 -1
  114. package/dist/coolandlovely/pages/common/SettingsPage.js +0 -973
  115. package/dist/coolandlovely/pages/common/SettingsPage.js.map +0 -1
  116. package/dist/coolandlovely/pages/customer/BookingDetailsPage.js +0 -630
  117. package/dist/coolandlovely/pages/customer/BookingDetailsPage.js.map +0 -1
  118. package/dist/coolandlovely/pages/customer/CartDetailPage.js +0 -623
  119. package/dist/coolandlovely/pages/customer/CartDetailPage.js.map +0 -1
  120. package/dist/coolandlovely/pages/customer/CartDiscoveryPage.js +0 -558
  121. package/dist/coolandlovely/pages/customer/CartDiscoveryPage.js.map +0 -1
  122. package/dist/coolandlovely/pages/customer/CheckoutPage.js +0 -529
  123. package/dist/coolandlovely/pages/customer/CheckoutPage.js.map +0 -1
  124. package/dist/coolandlovely/pages/customer/CustomerDashboard.js +0 -538
  125. package/dist/coolandlovely/pages/customer/CustomerDashboard.js.map +0 -1
  126. package/dist/coolandlovely/pages/customer/CustomerProfilePage.js +0 -658
  127. package/dist/coolandlovely/pages/customer/CustomerProfilePage.js.map +0 -1
  128. package/dist/coolandlovely/pages/customer/DirectServiceBookingPage.js +0 -632
  129. package/dist/coolandlovely/pages/customer/DirectServiceBookingPage.js.map +0 -1
  130. package/dist/coolandlovely/pages/customer/FavoritesPage.js +0 -487
  131. package/dist/coolandlovely/pages/customer/FavoritesPage.js.map +0 -1
  132. package/dist/coolandlovely/pages/customer/OrderHistoryPage.js +0 -447
  133. package/dist/coolandlovely/pages/customer/OrderHistoryPage.js.map +0 -1
  134. package/dist/coolandlovely/pages/customer/OrderTrackingPage.js +0 -425
  135. package/dist/coolandlovely/pages/customer/OrderTrackingPage.js.map +0 -1
  136. package/dist/coolandlovely/pages/customer/PaymentMethodsPage.js +0 -494
  137. package/dist/coolandlovely/pages/customer/PaymentMethodsPage.js.map +0 -1
  138. package/dist/coolandlovely/pages/customer/ReviewsPage.js +0 -616
  139. package/dist/coolandlovely/pages/customer/ReviewsPage.js.map +0 -1
  140. package/dist/coolandlovely/pages/customer/SavedAddressesPage.js +0 -449
  141. package/dist/coolandlovely/pages/customer/SavedAddressesPage.js.map +0 -1
  142. package/dist/coolandlovely/pages/investor/InvestmentDetailsPage.js +0 -887
  143. package/dist/coolandlovely/pages/investor/InvestmentDetailsPage.js.map +0 -1
  144. package/dist/coolandlovely/pages/investor/InvestmentOpportunitiesPage.js +0 -945
  145. package/dist/coolandlovely/pages/investor/InvestmentOpportunitiesPage.js.map +0 -1
  146. package/dist/coolandlovely/pages/investor/InvestorAnalyticsPage.js +0 -687
  147. package/dist/coolandlovely/pages/investor/InvestorAnalyticsPage.js.map +0 -1
  148. package/dist/coolandlovely/pages/investor/InvestorDashboard.js +0 -455
  149. package/dist/coolandlovely/pages/investor/InvestorDashboard.js.map +0 -1
  150. package/dist/coolandlovely/pages/investor/InvestorInvestmentsPage.js +0 -405
  151. package/dist/coolandlovely/pages/investor/InvestorInvestmentsPage.js.map +0 -1
  152. package/dist/coolandlovely/pages/investor/InvestorPortfolioPage.js +0 -602
  153. package/dist/coolandlovely/pages/investor/InvestorPortfolioPage.js.map +0 -1
  154. package/dist/coolandlovely/pages/investor/InvestorProfilePage.js +0 -1070
  155. package/dist/coolandlovely/pages/investor/InvestorProfilePage.js.map +0 -1
  156. package/dist/coolandlovely/pages/worker/TaskDetailsPage.js +0 -533
  157. package/dist/coolandlovely/pages/worker/TaskDetailsPage.js.map +0 -1
  158. package/dist/coolandlovely/pages/worker/WorkerDashboard.js +0 -671
  159. package/dist/coolandlovely/pages/worker/WorkerDashboard.js.map +0 -1
  160. package/dist/coolandlovely/pages/worker/WorkerOrdersPage.js +0 -680
  161. package/dist/coolandlovely/pages/worker/WorkerOrdersPage.js.map +0 -1
  162. package/dist/coolandlovely/pages/worker/WorkerProfilePage.js +0 -692
  163. package/dist/coolandlovely/pages/worker/WorkerProfilePage.js.map +0 -1
  164. package/dist/coolandlovely/pages/worker/WorkerSchedulePage.js +0 -583
  165. package/dist/coolandlovely/pages/worker/WorkerSchedulePage.js.map +0 -1
@@ -1,842 +0,0 @@
1
- import { useCoolAndLovely as e } from "../../context/CoolAndLovelyContext.js";
2
- import { cn as t } from "../../utils/cn.js";
3
- import { PageLayout as n } from "../../components/PageLayout.js";
4
- import { formatCurrency as r } from "../../utils/formatters.js";
5
- import { mockAdminAnalytics as i } from "../../mocks/data.js";
6
- import { useState as a } from "react";
7
- import { ArrowDownRight as o, ArrowUpRight as s, BarChart3 as c, CalendarDays as l, Clock as u, Download as d, IndianRupee as f, Percent as p, ShoppingCart as m, Star as h, Target as g, ThumbsUp as _, TrendingUp as v, Users as y } from "lucide-react";
8
- import { Fragment as b, jsx as x, jsxs as S } from "react/jsx-runtime";
9
- import { EmphasisPanel as C, PagePurpose as w } from "@burdenoff/fe-libs/ui";
10
- //#region src/coolandlovely/pages/cart-owner/AnalyticsDashboard.tsx
11
- var T = {
12
- revenue: {
13
- today: 12450,
14
- week: 87150,
15
- month: 348600,
16
- year: 4183200,
17
- growth: {
18
- daily: 12.5,
19
- weekly: 8.3,
20
- monthly: 15.2
21
- }
22
- },
23
- orders: {
24
- total: 156,
25
- pending: 3,
26
- completed: 145,
27
- cancelled: 8,
28
- averageValue: 285,
29
- averagePreparationTime: 18,
30
- popularTimes: [
31
- {
32
- hour: 8,
33
- orders: 12
34
- },
35
- {
36
- hour: 9,
37
- orders: 15
38
- },
39
- {
40
- hour: 10,
41
- orders: 18
42
- },
43
- {
44
- hour: 11,
45
- orders: 22
46
- },
47
- {
48
- hour: 12,
49
- orders: 28
50
- },
51
- {
52
- hour: 13,
53
- orders: 32
54
- },
55
- {
56
- hour: 14,
57
- orders: 16
58
- },
59
- {
60
- hour: 15,
61
- orders: 12
62
- },
63
- {
64
- hour: 16,
65
- orders: 14
66
- },
67
- {
68
- hour: 17,
69
- orders: 18
70
- },
71
- {
72
- hour: 18,
73
- orders: 20
74
- },
75
- {
76
- hour: 19,
77
- orders: 25
78
- },
79
- {
80
- hour: 20,
81
- orders: 22
82
- },
83
- {
84
- hour: 21,
85
- orders: 15
86
- }
87
- ]
88
- },
89
- offerings: {
90
- topSelling: [
91
- {
92
- id: "1",
93
- name: "Masala Dosa",
94
- quantity: 245,
95
- revenue: 19600,
96
- category: "Food & Beverage"
97
- },
98
- {
99
- id: "2",
100
- name: "Haircut Service",
101
- quantity: 89,
102
- revenue: 11340,
103
- category: "Personal Care & Beauty"
104
- },
105
- {
106
- id: "3",
107
- name: "Filter Coffee",
108
- quantity: 312,
109
- revenue: 9360,
110
- category: "Food & Beverage"
111
- },
112
- {
113
- id: "4",
114
- name: "Mobile Repair",
115
- quantity: 67,
116
- revenue: 6680,
117
- category: "Repair & Maintenance"
118
- },
119
- {
120
- id: "5",
121
- name: "Pongal",
122
- quantity: 98,
123
- revenue: 5880,
124
- category: "Food & Beverage"
125
- }
126
- ],
127
- leastSelling: [
128
- {
129
- id: "6",
130
- name: "Bisi Bele Bath",
131
- quantity: 12,
132
- revenue: 1440,
133
- category: "Food & Beverage"
134
- },
135
- {
136
- id: "7",
137
- name: "Cleaning Service",
138
- quantity: 8,
139
- revenue: 640,
140
- category: "Home Services"
141
- },
142
- {
143
- id: "8",
144
- name: "Kosambari",
145
- quantity: 15,
146
- revenue: 450,
147
- category: "Food & Beverage"
148
- }
149
- ],
150
- categories: [
151
- {
152
- category: "Food & Beverage",
153
- revenue: 45e3,
154
- orders: 450
155
- },
156
- {
157
- category: "Personal Care & Beauty",
158
- revenue: 25e3,
159
- orders: 180
160
- },
161
- {
162
- category: "Repair & Maintenance",
163
- revenue: 15e3,
164
- orders: 120
165
- },
166
- {
167
- category: "Home Services",
168
- revenue: 8e3,
169
- orders: 80
170
- }
171
- ]
172
- },
173
- customers: {
174
- total: 342,
175
- new: 45,
176
- returning: 297,
177
- topCustomers: [
178
- {
179
- id: "1",
180
- name: "Rahul Sharma",
181
- orders: 23,
182
- totalSpent: 6555
183
- },
184
- {
185
- id: "2",
186
- name: "Priya Patel",
187
- orders: 19,
188
- totalSpent: 5415
189
- },
190
- {
191
- id: "3",
192
- name: "Amit Kumar",
193
- orders: 17,
194
- totalSpent: 4845
195
- },
196
- {
197
- id: "4",
198
- name: "Sneha Reddy",
199
- orders: 15,
200
- totalSpent: 4275
201
- },
202
- {
203
- id: "5",
204
- name: "Vijay Singh",
205
- orders: 14,
206
- totalSpent: 3990
207
- }
208
- ],
209
- satisfaction: {
210
- rating: 4.6,
211
- reviews: 89,
212
- positiveReviews: 78
213
- }
214
- },
215
- performance: {
216
- acceptanceRate: 94,
217
- cancellationRate: 6,
218
- onTimeDeliveryRate: 88,
219
- averageRating: 4.6,
220
- peakHours: [
221
- {
222
- hour: "12-1 PM",
223
- orders: 32
224
- },
225
- {
226
- hour: "1-2 PM",
227
- orders: 28
228
- },
229
- {
230
- hour: "7-8 PM",
231
- orders: 25
232
- },
233
- {
234
- hour: "8-9 PM",
235
- orders: 22
236
- }
237
- ],
238
- peakDays: [
239
- {
240
- day: "Sunday",
241
- orders: 45
242
- },
243
- {
244
- day: "Saturday",
245
- orders: 42
246
- },
247
- {
248
- day: "Friday",
249
- orders: 38
250
- }
251
- ]
252
- }
253
- }, E = () => {
254
- let { navigateTo: E } = e(), [D, O] = a("week"), k = Math.max(...T.orders.popularTimes.map((e) => e.orders)), A = Math.max(...T.offerings.categories.map((e) => e.revenue)), j = Math.max(...T.performance.peakHours.map((e) => e.orders)), M = Math.max(...T.performance.peakDays.map((e) => e.orders)), N = (e) => `${e > 0 ? "+" : ""}${e}%`;
255
- return /* @__PURE__ */ S(n, {
256
- title: "Analytics Dashboard",
257
- description: "Business performance insights and data",
258
- actions: /* @__PURE__ */ S("div", {
259
- className: "flex items-center gap-2",
260
- children: [/* @__PURE__ */ S("select", {
261
- value: D,
262
- onChange: (e) => O(e.target.value),
263
- className: "rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary",
264
- children: [
265
- /* @__PURE__ */ x("option", {
266
- value: "today",
267
- children: "Today"
268
- }),
269
- /* @__PURE__ */ x("option", {
270
- value: "week",
271
- children: "This Week"
272
- }),
273
- /* @__PURE__ */ x("option", {
274
- value: "month",
275
- children: "This Month"
276
- }),
277
- /* @__PURE__ */ x("option", {
278
- value: "year",
279
- children: "This Year"
280
- })
281
- ]
282
- }), /* @__PURE__ */ S("button", {
283
- type: "button",
284
- onClick: () => alert("Export feature coming soon!"),
285
- className: "inline-flex items-center gap-1.5 rounded-md border border-border-subtle px-3 py-2 text-sm text-text-primary hover:bg-bg-sunken transition-colors",
286
- children: [/* @__PURE__ */ x(d, { className: "h-4 w-4" }), "Export"]
287
- })]
288
- }),
289
- children: [/* @__PURE__ */ x(w, {
290
- className: "mb-6",
291
- icon: /* @__PURE__ */ x(c, { className: "h-4 w-4" }),
292
- children: "See how your business is actually doing. Track revenue across day, week, month and year, understand your order patterns and busiest times, and export the numbers — turning raw sales into decisions about staffing, stock and hours."
293
- }), /* @__PURE__ */ S("div", {
294
- className: "space-y-6",
295
- children: [
296
- /* @__PURE__ */ S(C, {
297
- className: "p-5",
298
- children: [/* @__PURE__ */ x("h2", {
299
- className: "text-base font-semibold text-text-primary mb-3",
300
- children: "Revenue Overview"
301
- }), /* @__PURE__ */ x("div", {
302
- className: "grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-4 gap-4",
303
- children: [
304
- {
305
- label: "Today's Revenue",
306
- value: T.revenue.today,
307
- growth: T.revenue.growth.daily
308
- },
309
- {
310
- label: "This Week",
311
- value: T.revenue.week,
312
- growth: T.revenue.growth.weekly
313
- },
314
- {
315
- label: "This Month",
316
- value: T.revenue.month,
317
- growth: T.revenue.growth.monthly
318
- },
319
- {
320
- label: "This Year",
321
- value: T.revenue.year,
322
- growth: null
323
- }
324
- ].map((e) => /* @__PURE__ */ S("div", {
325
- className: "rounded-lg border border-border-seam bg-bg-surface p-5 bg-gloss-card shadow-pop",
326
- children: [
327
- /* @__PURE__ */ S("div", {
328
- className: "flex items-center justify-between",
329
- children: [/* @__PURE__ */ x("div", {
330
- className: "rounded-md bg-accent p-2",
331
- children: /* @__PURE__ */ x(f, { className: "h-5 w-5 text-text-secondary" })
332
- }), e.growth !== null && /* @__PURE__ */ S("div", {
333
- className: t("flex items-center gap-1 text-xs font-medium", e.growth >= 0 ? "text-status-success-text" : "text-status-error-text"),
334
- children: [e.growth >= 0 ? /* @__PURE__ */ x(s, { className: "h-3.5 w-3.5" }) : /* @__PURE__ */ x(o, { className: "h-3.5 w-3.5" }), N(e.growth)]
335
- })]
336
- }),
337
- /* @__PURE__ */ x("p", {
338
- className: "mt-3 text-2xl font-bold text-text-primary",
339
- children: r(e.value, { minimumFractionDigits: 0 })
340
- }),
341
- /* @__PURE__ */ x("p", {
342
- className: "mt-1 text-sm text-text-secondary",
343
- children: e.label
344
- })
345
- ]
346
- }, e.label))
347
- })]
348
- }),
349
- /* @__PURE__ */ S("div", {
350
- className: "grid grid-cols-1 lg:grid-cols-2 gap-6",
351
- children: [/* @__PURE__ */ S("div", {
352
- className: "rounded-lg border border-border-subtle bg-bg-surface shadow-sm",
353
- children: [/* @__PURE__ */ x("div", {
354
- className: "border-b border-border-subtle px-5 py-4",
355
- children: /* @__PURE__ */ S("h2", {
356
- className: "text-base font-semibold text-text-primary flex items-center gap-2",
357
- children: [/* @__PURE__ */ x(m, { className: "h-4 w-4 text-text-secondary" }), "Order Statistics"]
358
- })
359
- }), /* @__PURE__ */ S("div", {
360
- className: "p-5",
361
- children: [/* @__PURE__ */ S("div", {
362
- className: "grid grid-cols-2 gap-4 mb-5",
363
- children: [
364
- /* @__PURE__ */ S("div", { children: [/* @__PURE__ */ x("p", {
365
- className: "text-xs text-text-secondary",
366
- children: "Total Orders"
367
- }), /* @__PURE__ */ x("p", {
368
- className: "text-2xl font-bold text-text-primary",
369
- children: T.orders.total
370
- })] }),
371
- /* @__PURE__ */ S("div", { children: [/* @__PURE__ */ x("p", {
372
- className: "text-xs text-text-secondary",
373
- children: "Avg. Order Value"
374
- }), /* @__PURE__ */ x("p", {
375
- className: "text-2xl font-bold text-text-primary",
376
- children: r(T.orders.averageValue, { minimumFractionDigits: 0 })
377
- })] }),
378
- /* @__PURE__ */ S("div", { children: [/* @__PURE__ */ x("p", {
379
- className: "text-xs text-text-secondary",
380
- children: "Completed"
381
- }), /* @__PURE__ */ x("p", {
382
- className: "text-xl font-bold text-status-success-text",
383
- children: T.orders.completed
384
- })] }),
385
- /* @__PURE__ */ S("div", { children: [/* @__PURE__ */ x("p", {
386
- className: "text-xs text-text-secondary",
387
- children: "Cancelled"
388
- }), /* @__PURE__ */ x("p", {
389
- className: "text-xl font-bold text-status-error-text",
390
- children: T.orders.cancelled
391
- })] })
392
- ]
393
- }), /* @__PURE__ */ S("div", { children: [/* @__PURE__ */ x("p", {
394
- className: "text-xs text-text-secondary mb-1",
395
- children: "Avg. Preparation Time"
396
- }), /* @__PURE__ */ S("p", {
397
- className: "text-sm font-medium text-text-primary",
398
- children: [T.orders.averagePreparationTime, " minutes"]
399
- })] })]
400
- })]
401
- }), /* @__PURE__ */ S("div", {
402
- className: "rounded-lg border border-border-subtle bg-bg-surface shadow-sm",
403
- children: [/* @__PURE__ */ x("div", {
404
- className: "border-b border-border-subtle px-5 py-4",
405
- children: /* @__PURE__ */ S("h2", {
406
- className: "text-base font-semibold text-text-primary flex items-center gap-2",
407
- children: [/* @__PURE__ */ x(u, { className: "h-4 w-4 text-text-secondary" }), "Popular Times"]
408
- })
409
- }), /* @__PURE__ */ x("div", {
410
- className: "p-5 space-y-2",
411
- children: T.orders.popularTimes.map((e) => {
412
- let n = e.orders / k * 100;
413
- return /* @__PURE__ */ S("div", { children: [/* @__PURE__ */ S("div", {
414
- className: "flex items-center justify-between text-xs mb-0.5",
415
- children: [/* @__PURE__ */ x("span", {
416
- className: "text-text-primary w-14",
417
- children: `${e.hour}:00`
418
- }), /* @__PURE__ */ S("span", {
419
- className: "text-text-secondary",
420
- children: [e.orders, " orders"]
421
- })]
422
- }), /* @__PURE__ */ x("div", {
423
- className: "h-2 rounded-full bg-bg-sunken overflow-hidden",
424
- children: /* @__PURE__ */ x("div", {
425
- className: t("h-full rounded-full transition-all", e.orders > 25 ? "bg-status-error-bg-subtle/60" : e.orders > 18 ? "bg-status-warning-bg-subtle/60" : "bg-status-success-bg-subtle/60"),
426
- style: { width: `${n}%` }
427
- })
428
- })] }, e.hour);
429
- })
430
- })]
431
- })]
432
- }),
433
- /* @__PURE__ */ S("section", { children: [/* @__PURE__ */ x("h2", {
434
- className: "text-base font-semibold text-text-primary mb-3",
435
- children: "Performance Metrics"
436
- }), /* @__PURE__ */ x("div", {
437
- className: "grid grid-cols-2 lg:grid-cols-4 gap-4",
438
- children: [
439
- {
440
- label: "Acceptance Rate",
441
- value: `${T.performance.acceptanceRate}%`,
442
- icon: g,
443
- color: "text-status-success-text"
444
- },
445
- {
446
- label: "Cancellation Rate",
447
- value: `${T.performance.cancellationRate}%`,
448
- icon: p,
449
- color: "text-status-error-text"
450
- },
451
- {
452
- label: "On-Time Delivery",
453
- value: `${T.performance.onTimeDeliveryRate}%`,
454
- icon: u,
455
- color: "text-accent-blue"
456
- },
457
- {
458
- label: "Average Rating",
459
- value: `${T.performance.averageRating}`,
460
- icon: h,
461
- color: "text-status-warning-text"
462
- }
463
- ].map((e) => {
464
- let n = e.icon;
465
- return /* @__PURE__ */ S("div", {
466
- className: "rounded-lg border border-border-seam bg-bg-surface p-5 bg-gloss-card shadow-pop",
467
- children: [/* @__PURE__ */ S("div", {
468
- className: "flex items-center gap-2 mb-2",
469
- children: [/* @__PURE__ */ x(n, { className: t("h-5 w-5", e.color) }), /* @__PURE__ */ x("span", {
470
- className: "text-xs text-text-secondary",
471
- children: e.label
472
- })]
473
- }), /* @__PURE__ */ x("p", {
474
- className: t("text-2xl font-bold", e.color),
475
- children: e.value
476
- })]
477
- }, e.label);
478
- })
479
- })] }),
480
- /* @__PURE__ */ S("div", {
481
- className: "grid grid-cols-1 lg:grid-cols-2 gap-6",
482
- children: [/* @__PURE__ */ S("div", {
483
- className: "rounded-lg border border-border-subtle bg-bg-surface shadow-sm",
484
- children: [
485
- /* @__PURE__ */ x("div", {
486
- className: "border-b border-border-subtle px-5 py-4",
487
- children: /* @__PURE__ */ S("h2", {
488
- className: "text-base font-semibold text-text-primary flex items-center gap-2",
489
- children: [/* @__PURE__ */ x(v, { className: "h-4 w-4 text-text-secondary" }), "Top Selling Offerings"]
490
- })
491
- }),
492
- /* @__PURE__ */ x("div", {
493
- className: "divide-y divide-border",
494
- children: T.offerings.topSelling.map((e, t) => /* @__PURE__ */ S("div", {
495
- className: "flex items-center justify-between px-5 py-3",
496
- children: [/* @__PURE__ */ S("div", {
497
- className: "flex items-center gap-3",
498
- children: [/* @__PURE__ */ x("span", {
499
- className: "flex h-6 w-6 items-center justify-center rounded-full bg-bg-sunken text-xs font-medium text-text-secondary",
500
- children: t + 1
501
- }), /* @__PURE__ */ S("div", { children: [/* @__PURE__ */ x("p", {
502
- className: "text-sm font-medium text-text-primary",
503
- children: e.name
504
- }), /* @__PURE__ */ S("p", {
505
- className: "text-xs text-text-secondary",
506
- children: [
507
- e.category,
508
- " | ",
509
- e.quantity,
510
- " sold"
511
- ]
512
- })] })]
513
- }), /* @__PURE__ */ x("span", {
514
- className: "text-sm font-medium text-text-primary",
515
- children: r(e.revenue, { minimumFractionDigits: 0 })
516
- })]
517
- }, e.id))
518
- }),
519
- /* @__PURE__ */ S("div", {
520
- className: "border-t border-border-subtle px-5 py-3",
521
- children: [/* @__PURE__ */ x("p", {
522
- className: "text-xs font-medium text-text-secondary mb-2",
523
- children: "Least Selling"
524
- }), T.offerings.leastSelling.map((e) => /* @__PURE__ */ S("div", {
525
- className: "flex items-center justify-between py-1.5",
526
- children: [/* @__PURE__ */ x("span", {
527
- className: "text-xs text-text-secondary",
528
- children: e.name
529
- }), /* @__PURE__ */ S("span", {
530
- className: "text-xs text-text-secondary",
531
- children: [
532
- e.quantity,
533
- " sold |",
534
- " ",
535
- r(e.revenue, { minimumFractionDigits: 0 })
536
- ]
537
- })]
538
- }, e.id))]
539
- })
540
- ]
541
- }), /* @__PURE__ */ S("div", {
542
- className: "rounded-lg border border-border-subtle bg-bg-surface shadow-sm",
543
- children: [/* @__PURE__ */ x("div", {
544
- className: "border-b border-border-subtle px-5 py-4",
545
- children: /* @__PURE__ */ S("h2", {
546
- className: "text-base font-semibold text-text-primary flex items-center gap-2",
547
- children: [/* @__PURE__ */ x(c, { className: "h-4 w-4 text-text-secondary" }), "Category Performance"]
548
- })
549
- }), /* @__PURE__ */ x("div", {
550
- className: "p-5 space-y-4",
551
- children: T.offerings.categories.map((e) => {
552
- let t = e.revenue / A * 100;
553
- return /* @__PURE__ */ S("div", { children: [/* @__PURE__ */ S("div", {
554
- className: "flex items-center justify-between text-sm mb-1",
555
- children: [/* @__PURE__ */ x("span", {
556
- className: "text-text-primary",
557
- children: e.category
558
- }), /* @__PURE__ */ S("span", {
559
- className: "text-text-secondary",
560
- children: [
561
- r(e.revenue, { minimumFractionDigits: 0 }),
562
- " (",
563
- e.orders,
564
- " ",
565
- "orders)"
566
- ]
567
- })]
568
- }), /* @__PURE__ */ x("div", {
569
- className: "h-2.5 rounded-full bg-bg-sunken overflow-hidden",
570
- children: /* @__PURE__ */ x("div", {
571
- className: "h-full rounded-full bg-accent-blue-subtle/60",
572
- style: { width: `${t}%` }
573
- })
574
- })] }, e.category);
575
- })
576
- })]
577
- })]
578
- }),
579
- /* @__PURE__ */ S("div", {
580
- className: "grid grid-cols-1 lg:grid-cols-3 gap-6",
581
- children: [/* @__PURE__ */ S("div", {
582
- className: "lg:col-span-2 rounded-lg border border-border-subtle bg-bg-surface shadow-sm",
583
- children: [/* @__PURE__ */ x("div", {
584
- className: "border-b border-border-subtle px-5 py-4",
585
- children: /* @__PURE__ */ S("h2", {
586
- className: "text-base font-semibold text-text-primary flex items-center gap-2",
587
- children: [/* @__PURE__ */ x(y, { className: "h-4 w-4 text-text-secondary" }), "Customer Overview"]
588
- })
589
- }), /* @__PURE__ */ S("div", {
590
- className: "p-5",
591
- children: [
592
- /* @__PURE__ */ S("div", {
593
- className: "grid grid-cols-2 sm:grid-cols-4 gap-4 mb-5",
594
- children: [
595
- /* @__PURE__ */ S("div", { children: [/* @__PURE__ */ x("p", {
596
- className: "text-xs text-text-secondary",
597
- children: "Total Customers"
598
- }), /* @__PURE__ */ x("p", {
599
- className: "text-xl font-bold text-text-primary",
600
- children: T.customers.total
601
- })] }),
602
- /* @__PURE__ */ S("div", { children: [/* @__PURE__ */ x("p", {
603
- className: "text-xs text-text-secondary",
604
- children: "New This Month"
605
- }), /* @__PURE__ */ x("p", {
606
- className: "text-xl font-bold text-accent-blue",
607
- children: T.customers.new
608
- })] }),
609
- /* @__PURE__ */ S("div", { children: [/* @__PURE__ */ x("p", {
610
- className: "text-xs text-text-secondary",
611
- children: "Returning"
612
- }), /* @__PURE__ */ x("p", {
613
- className: "text-xl font-bold text-status-success-text",
614
- children: T.customers.returning
615
- })] }),
616
- /* @__PURE__ */ S("div", { children: [/* @__PURE__ */ x("p", {
617
- className: "text-xs text-text-secondary",
618
- children: "Satisfaction"
619
- }), /* @__PURE__ */ S("p", {
620
- className: "text-xl font-bold text-status-warning-text flex items-center gap-1",
621
- children: [/* @__PURE__ */ x(h, { className: "h-4 w-4 fill-status-warning-text text-status-warning-text" }), T.customers.satisfaction.rating]
622
- })] })
623
- ]
624
- }),
625
- /* @__PURE__ */ x("p", {
626
- className: "text-sm font-medium text-text-primary mb-2",
627
- children: "Top Customers"
628
- }),
629
- /* @__PURE__ */ x("div", {
630
- className: "overflow-x-auto",
631
- children: /* @__PURE__ */ S("table", {
632
- className: "w-full text-sm",
633
- children: [/* @__PURE__ */ x("thead", { children: /* @__PURE__ */ S("tr", {
634
- className: "border-b border-border-subtle",
635
- children: [
636
- /* @__PURE__ */ x("th", {
637
- className: "py-2 text-left font-medium text-text-secondary",
638
- children: "#"
639
- }),
640
- /* @__PURE__ */ x("th", {
641
- className: "py-2 text-left font-medium text-text-secondary",
642
- children: "Customer"
643
- }),
644
- /* @__PURE__ */ x("th", {
645
- className: "py-2 text-right font-medium text-text-secondary",
646
- children: "Orders"
647
- }),
648
- /* @__PURE__ */ x("th", {
649
- className: "py-2 text-right font-medium text-text-secondary",
650
- children: "Total Spent"
651
- })
652
- ]
653
- }) }), /* @__PURE__ */ x("tbody", { children: T.customers.topCustomers.map((e, t) => /* @__PURE__ */ S("tr", {
654
- className: "border-b border-border-subtle last:border-0",
655
- children: [
656
- /* @__PURE__ */ x("td", {
657
- className: "py-2.5 text-text-secondary",
658
- children: t + 1
659
- }),
660
- /* @__PURE__ */ x("td", {
661
- className: "py-2.5 font-medium text-text-primary",
662
- children: e.name
663
- }),
664
- /* @__PURE__ */ x("td", {
665
- className: "py-2.5 text-right text-text-primary",
666
- children: e.orders
667
- }),
668
- /* @__PURE__ */ x("td", {
669
- className: "py-2.5 text-right font-medium text-text-primary",
670
- children: r(e.totalSpent, { minimumFractionDigits: 0 })
671
- })
672
- ]
673
- }, e.id)) })]
674
- })
675
- }),
676
- /* @__PURE__ */ x("div", {
677
- className: "mt-4 flex items-center gap-4 text-sm",
678
- children: /* @__PURE__ */ S("div", {
679
- className: "flex items-center gap-1.5",
680
- children: [/* @__PURE__ */ x(_, { className: "h-4 w-4 text-status-success-text" }), /* @__PURE__ */ S("span", {
681
- className: "text-text-secondary",
682
- children: [
683
- T.customers.satisfaction.positiveReviews,
684
- "/",
685
- T.customers.satisfaction.reviews,
686
- " positive reviews"
687
- ]
688
- })]
689
- })
690
- })
691
- ]
692
- })]
693
- }), /* @__PURE__ */ S("div", {
694
- className: "space-y-6",
695
- children: [/* @__PURE__ */ S("div", {
696
- className: "rounded-lg border border-border-subtle bg-bg-surface shadow-sm",
697
- children: [/* @__PURE__ */ x("div", {
698
- className: "border-b border-border-subtle px-5 py-4",
699
- children: /* @__PURE__ */ S("h2", {
700
- className: "text-base font-semibold text-text-primary flex items-center gap-2",
701
- children: [/* @__PURE__ */ x(u, { className: "h-4 w-4 text-text-secondary" }), "Peak Hours"]
702
- })
703
- }), /* @__PURE__ */ x("div", {
704
- className: "p-5 space-y-3",
705
- children: T.performance.peakHours.map((e) => {
706
- let n = e.orders / j * 100;
707
- return /* @__PURE__ */ S("div", { children: [/* @__PURE__ */ S("div", {
708
- className: "flex items-center justify-between text-xs mb-1",
709
- children: [/* @__PURE__ */ x("span", {
710
- className: "text-text-primary",
711
- children: e.hour
712
- }), /* @__PURE__ */ S("span", {
713
- className: "text-text-secondary",
714
- children: [e.orders, " orders"]
715
- })]
716
- }), /* @__PURE__ */ x("div", {
717
- className: "h-2 rounded-full bg-bg-sunken overflow-hidden",
718
- children: /* @__PURE__ */ x("div", {
719
- className: t("h-full rounded-full", e.orders > 28 ? "bg-status-error-bg-subtle/60" : e.orders > 22 ? "bg-status-warning-bg-subtle/60" : "bg-status-success-bg-subtle/60"),
720
- style: { width: `${n}%` }
721
- })
722
- })] }, e.hour);
723
- })
724
- })]
725
- }), /* @__PURE__ */ S("div", {
726
- className: "rounded-lg border border-border-subtle bg-bg-surface shadow-sm",
727
- children: [/* @__PURE__ */ x("div", {
728
- className: "border-b border-border-subtle px-5 py-4",
729
- children: /* @__PURE__ */ S("h2", {
730
- className: "text-base font-semibold text-text-primary flex items-center gap-2",
731
- children: [/* @__PURE__ */ x(l, { className: "h-4 w-4 text-text-secondary" }), "Peak Days"]
732
- })
733
- }), /* @__PURE__ */ x("div", {
734
- className: "p-5 space-y-3",
735
- children: T.performance.peakDays.map((e) => {
736
- let t = e.orders / M * 100;
737
- return /* @__PURE__ */ S("div", { children: [/* @__PURE__ */ S("div", {
738
- className: "flex items-center justify-between text-xs mb-1",
739
- children: [/* @__PURE__ */ x("span", {
740
- className: "text-text-primary",
741
- children: e.day
742
- }), /* @__PURE__ */ S("span", {
743
- className: "text-text-secondary",
744
- children: [e.orders, " orders"]
745
- })]
746
- }), /* @__PURE__ */ x("div", {
747
- className: "h-2 rounded-full bg-bg-sunken overflow-hidden",
748
- children: /* @__PURE__ */ x("div", {
749
- className: "h-full rounded-full bg-accent-blue-subtle/60",
750
- style: { width: `${t}%` }
751
- })
752
- })] }, e.day);
753
- })
754
- })]
755
- })]
756
- })]
757
- }),
758
- /* @__PURE__ */ S("div", {
759
- className: "rounded-lg border border-border-subtle bg-bg-surface shadow-sm",
760
- children: [/* @__PURE__ */ x("div", {
761
- className: "border-b border-border-subtle px-5 py-4",
762
- children: /* @__PURE__ */ S("h2", {
763
- className: "text-base font-semibold text-text-primary flex items-center gap-2",
764
- children: [/* @__PURE__ */ x(v, { className: "h-4 w-4 text-text-secondary" }), "Daily Order Trends"]
765
- })
766
- }), /* @__PURE__ */ x("div", {
767
- className: "overflow-x-auto",
768
- children: /* @__PURE__ */ S("table", {
769
- className: "w-full text-sm",
770
- children: [/* @__PURE__ */ x("thead", { children: /* @__PURE__ */ S("tr", {
771
- className: "border-b border-border-subtle",
772
- children: [
773
- /* @__PURE__ */ x("th", {
774
- className: "px-5 py-2.5 text-left font-medium text-text-secondary",
775
- children: "Date"
776
- }),
777
- /* @__PURE__ */ x("th", {
778
- className: "px-5 py-2.5 text-right font-medium text-text-secondary",
779
- children: "Orders"
780
- }),
781
- /* @__PURE__ */ x("th", {
782
- className: "px-5 py-2.5 text-right font-medium text-text-secondary",
783
- children: "Revenue"
784
- })
785
- ]
786
- }) }), /* @__PURE__ */ x("tbody", { children: i.orderTrends.map((e) => /* @__PURE__ */ S("tr", {
787
- className: "border-b border-border-subtle last:border-0",
788
- children: [
789
- /* @__PURE__ */ x("td", {
790
- className: "px-5 py-2.5 text-text-primary",
791
- children: new Date(e.date).toLocaleDateString("en-IN", {
792
- day: "2-digit",
793
- month: "short"
794
- })
795
- }),
796
- /* @__PURE__ */ x("td", {
797
- className: "px-5 py-2.5 text-right text-text-primary",
798
- children: e.orders
799
- }),
800
- /* @__PURE__ */ x("td", {
801
- className: "px-5 py-2.5 text-right font-medium text-text-primary",
802
- children: r(e.revenue, { minimumFractionDigits: 0 })
803
- })
804
- ]
805
- }, e.date)) })]
806
- })
807
- })]
808
- }),
809
- /* @__PURE__ */ S("div", {
810
- className: "rounded-lg border border-border-subtle bg-bg-surface shadow-sm",
811
- children: [/* @__PURE__ */ x("div", {
812
- className: "border-b border-border-subtle px-5 py-4",
813
- children: /* @__PURE__ */ S("h2", {
814
- className: "text-base font-semibold text-text-primary flex items-center gap-2",
815
- children: [/* @__PURE__ */ x(y, { className: "h-4 w-4 text-text-secondary" }), "Monthly Customer Growth"]
816
- })
817
- }), /* @__PURE__ */ S("div", {
818
- className: "p-5",
819
- children: [/* @__PURE__ */ x("div", {
820
- className: "flex items-end gap-1.5 h-20",
821
- children: i.customerGrowth.map((e) => {
822
- let t = Math.max(...i.customerGrowth.map((e) => e.newCustomers));
823
- return /* @__PURE__ */ x("div", {
824
- className: "flex-1 rounded-t bg-accent-blue-subtle/40 hover:bg-accent-blue-subtle/60 transition-colors cursor-default",
825
- style: { height: `${e.newCustomers / t * 100}%` },
826
- title: `${e.month}: ${e.newCustomers} new customers`
827
- }, e.month);
828
- })
829
- }), /* @__PURE__ */ x("div", {
830
- className: "flex justify-between mt-2 text-xs text-text-secondary",
831
- children: i.customerGrowth.length > 0 && /* @__PURE__ */ S(b, { children: [/* @__PURE__ */ x("span", { children: i.customerGrowth[0].month }), /* @__PURE__ */ x("span", { children: i.customerGrowth[i.customerGrowth.length - 1].month })] })
832
- })]
833
- })]
834
- })
835
- ]
836
- })]
837
- });
838
- };
839
- //#endregion
840
- export { E as AnalyticsDashboard };
841
-
842
- //# sourceMappingURL=AnalyticsDashboard.js.map