@burdenoff/microfe-kadaikodi 2026.625.1 → 2026.626.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.
Files changed (91) hide show
  1. package/dist/kadaikodi/pages/HomePage.js +19 -14
  2. package/dist/kadaikodi/pages/HomePage.js.map +1 -1
  3. package/dist/kadaikodi/pages/admin/AdminAnalyticsPage.js +118 -83
  4. package/dist/kadaikodi/pages/admin/AdminAnalyticsPage.js.map +1 -1
  5. package/dist/kadaikodi/pages/admin/AdminDashboard.js +75 -46
  6. package/dist/kadaikodi/pages/admin/AdminDashboard.js.map +1 -1
  7. package/dist/kadaikodi/pages/admin/AdminFinancialPage.js +144 -128
  8. package/dist/kadaikodi/pages/admin/AdminFinancialPage.js.map +1 -1
  9. package/dist/kadaikodi/pages/admin/AdminOrdersPage.js +255 -237
  10. package/dist/kadaikodi/pages/admin/AdminOrdersPage.js.map +1 -1
  11. package/dist/kadaikodi/pages/admin/AdminProfilePage.js +129 -128
  12. package/dist/kadaikodi/pages/admin/AdminProfilePage.js.map +1 -1
  13. package/dist/kadaikodi/pages/admin/AdminSettingsPage.js +178 -150
  14. package/dist/kadaikodi/pages/admin/AdminSettingsPage.js.map +1 -1
  15. package/dist/kadaikodi/pages/admin/CartManagementPage.js +182 -159
  16. package/dist/kadaikodi/pages/admin/CartManagementPage.js.map +1 -1
  17. package/dist/kadaikodi/pages/admin/UserManagementPage.js +325 -303
  18. package/dist/kadaikodi/pages/admin/UserManagementPage.js.map +1 -1
  19. package/dist/kadaikodi/pages/cart-owner/AnalyticsDashboard.js +500 -469
  20. package/dist/kadaikodi/pages/cart-owner/AnalyticsDashboard.js.map +1 -1
  21. package/dist/kadaikodi/pages/cart-owner/BusinessSettingsPage.js +534 -503
  22. package/dist/kadaikodi/pages/cart-owner/BusinessSettingsPage.js.map +1 -1
  23. package/dist/kadaikodi/pages/cart-owner/CartOwnerDashboard.js +73 -48
  24. package/dist/kadaikodi/pages/cart-owner/CartOwnerDashboard.js.map +1 -1
  25. package/dist/kadaikodi/pages/cart-owner/CartOwnerProfilePage.js +103 -96
  26. package/dist/kadaikodi/pages/cart-owner/CartOwnerProfilePage.js.map +1 -1
  27. package/dist/kadaikodi/pages/cart-owner/CartServiceConfigPage.js +130 -129
  28. package/dist/kadaikodi/pages/cart-owner/CartServiceConfigPage.js.map +1 -1
  29. package/dist/kadaikodi/pages/cart-owner/InventoryManagementPage.js +673 -670
  30. package/dist/kadaikodi/pages/cart-owner/InventoryManagementPage.js.map +1 -1
  31. package/dist/kadaikodi/pages/cart-owner/OrderManagementPage.js +517 -514
  32. package/dist/kadaikodi/pages/cart-owner/OrderManagementPage.js.map +1 -1
  33. package/dist/kadaikodi/pages/cart-owner/StaffManagementPage.js +140 -125
  34. package/dist/kadaikodi/pages/cart-owner/StaffManagementPage.js.map +1 -1
  35. package/dist/kadaikodi/pages/common/HelpSupportPage.js +302 -311
  36. package/dist/kadaikodi/pages/common/HelpSupportPage.js.map +1 -1
  37. package/dist/kadaikodi/pages/common/NotificationCenterPage.js +102 -91
  38. package/dist/kadaikodi/pages/common/NotificationCenterPage.js.map +1 -1
  39. package/dist/kadaikodi/pages/common/SettingsPage.js +766 -734
  40. package/dist/kadaikodi/pages/common/SettingsPage.js.map +1 -1
  41. package/dist/kadaikodi/pages/customer/BookingDetailsPage.js +366 -356
  42. package/dist/kadaikodi/pages/customer/BookingDetailsPage.js.map +1 -1
  43. package/dist/kadaikodi/pages/customer/CartDetailPage.js +243 -213
  44. package/dist/kadaikodi/pages/customer/CartDetailPage.js.map +1 -1
  45. package/dist/kadaikodi/pages/customer/CartDiscoveryPage.js +200 -195
  46. package/dist/kadaikodi/pages/customer/CartDiscoveryPage.js.map +1 -1
  47. package/dist/kadaikodi/pages/customer/CheckoutPage.js +95 -89
  48. package/dist/kadaikodi/pages/customer/CheckoutPage.js.map +1 -1
  49. package/dist/kadaikodi/pages/customer/CustomerDashboard.js +430 -387
  50. package/dist/kadaikodi/pages/customer/CustomerDashboard.js.map +1 -1
  51. package/dist/kadaikodi/pages/customer/CustomerProfilePage.js +488 -478
  52. package/dist/kadaikodi/pages/customer/CustomerProfilePage.js.map +1 -1
  53. package/dist/kadaikodi/pages/customer/DirectServiceBookingPage.js +523 -512
  54. package/dist/kadaikodi/pages/customer/DirectServiceBookingPage.js.map +1 -1
  55. package/dist/kadaikodi/pages/customer/FavoritesPage.js +83 -75
  56. package/dist/kadaikodi/pages/customer/FavoritesPage.js.map +1 -1
  57. package/dist/kadaikodi/pages/customer/OrderHistoryPage.js +116 -108
  58. package/dist/kadaikodi/pages/customer/OrderHistoryPage.js.map +1 -1
  59. package/dist/kadaikodi/pages/customer/OrderTrackingPage.js +67 -61
  60. package/dist/kadaikodi/pages/customer/OrderTrackingPage.js.map +1 -1
  61. package/dist/kadaikodi/pages/customer/PaymentMethodsPage.js +90 -73
  62. package/dist/kadaikodi/pages/customer/PaymentMethodsPage.js.map +1 -1
  63. package/dist/kadaikodi/pages/customer/ReviewsPage.js +80 -72
  64. package/dist/kadaikodi/pages/customer/ReviewsPage.js.map +1 -1
  65. package/dist/kadaikodi/pages/customer/SavedAddressesPage.js +70 -53
  66. package/dist/kadaikodi/pages/customer/SavedAddressesPage.js.map +1 -1
  67. package/dist/kadaikodi/pages/investor/InvestmentDetailsPage.js +289 -255
  68. package/dist/kadaikodi/pages/investor/InvestmentDetailsPage.js.map +1 -1
  69. package/dist/kadaikodi/pages/investor/InvestmentOpportunitiesPage.js +92 -84
  70. package/dist/kadaikodi/pages/investor/InvestmentOpportunitiesPage.js.map +1 -1
  71. package/dist/kadaikodi/pages/investor/InvestorAnalyticsPage.js +63 -55
  72. package/dist/kadaikodi/pages/investor/InvestorAnalyticsPage.js.map +1 -1
  73. package/dist/kadaikodi/pages/investor/InvestorDashboard.js +339 -311
  74. package/dist/kadaikodi/pages/investor/InvestorDashboard.js.map +1 -1
  75. package/dist/kadaikodi/pages/investor/InvestorInvestmentsPage.js +40 -32
  76. package/dist/kadaikodi/pages/investor/InvestorInvestmentsPage.js.map +1 -1
  77. package/dist/kadaikodi/pages/investor/InvestorPortfolioPage.js +174 -150
  78. package/dist/kadaikodi/pages/investor/InvestorPortfolioPage.js.map +1 -1
  79. package/dist/kadaikodi/pages/investor/InvestorProfilePage.js +385 -381
  80. package/dist/kadaikodi/pages/investor/InvestorProfilePage.js.map +1 -1
  81. package/dist/kadaikodi/pages/worker/TaskDetailsPage.js +302 -273
  82. package/dist/kadaikodi/pages/worker/TaskDetailsPage.js.map +1 -1
  83. package/dist/kadaikodi/pages/worker/WorkerDashboard.js +87 -59
  84. package/dist/kadaikodi/pages/worker/WorkerDashboard.js.map +1 -1
  85. package/dist/kadaikodi/pages/worker/WorkerOrdersPage.js +82 -75
  86. package/dist/kadaikodi/pages/worker/WorkerOrdersPage.js.map +1 -1
  87. package/dist/kadaikodi/pages/worker/WorkerProfilePage.js +81 -77
  88. package/dist/kadaikodi/pages/worker/WorkerProfilePage.js.map +1 -1
  89. package/dist/kadaikodi/pages/worker/WorkerSchedulePage.js +78 -71
  90. package/dist/kadaikodi/pages/worker/WorkerSchedulePage.js.map +1 -1
  91. package/package.json +2 -2
@@ -1,13 +1,15 @@
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 { formatCurrency as r } from "../../utils/formatters.js";
5
- import { mockProducts as i } from "../../mocks/data.js";
4
+ import { EmptyState as r } from "../../components/EmptyState.js";
5
+ import { formatCurrency as i } from "../../utils/formatters.js";
6
+ import { mockProducts as ee } from "../../mocks/data.js";
6
7
  import { useMemo as a, useState as o } from "react";
7
- import { AlertCircle as ee, CheckCircle2 as te, Edit2 as ne, Package as s, Plus as c, Search as re, Trash2 as ie, Upload as ae, X as oe } from "lucide-react";
8
- import { Fragment as se, jsx as l, jsxs as u } from "react/jsx-runtime";
8
+ import { AlertCircle as te, CheckCircle2 as s, Edit2 as ne, Package as c, Plus as l, Search as u, Trash2 as d, Upload as re, X as ie } from "lucide-react";
9
+ import { Fragment as ae, jsx as f, jsxs as p } from "react/jsx-runtime";
10
+ import { EmphasisPanel as oe, PagePurpose as m } from "@burdenoff/fe-libs/ui";
9
11
  //#region src/kadaikodi/pages/cart-owner/InventoryManagementPage.tsx
10
- var d = [
12
+ var h = [
11
13
  "Service",
12
14
  "Repair",
13
15
  "Beauty",
@@ -16,7 +18,7 @@ var d = [
16
18
  "Health",
17
19
  "Wellness",
18
20
  "Education"
19
- ], f = (e) => d.some((t) => e.includes(t)), p = (e) => e === "Food & Beverage", m = [
21
+ ], g = (e) => h.some((t) => e.includes(t)), _ = (e) => e === "Food & Beverage", v = [
20
22
  10,
21
23
  25,
22
24
  0,
@@ -37,18 +39,18 @@ var d = [
37
39
  22,
38
40
  0,
39
41
  45
40
- ], h = () => i.slice(0, 20).map((e, t) => ({
42
+ ], se = () => ee.slice(0, 20).map((e, t) => ({
41
43
  id: e.id,
42
44
  name: e.name,
43
45
  description: e.description ?? `${e.name} - quality offering from ${e.cartName}`,
44
46
  price: e.price,
45
47
  originalPrice: t % 4 == 0 ? Math.round(e.price * 1.2) : void 0,
46
48
  category: e.category,
47
- stock: m[t] ?? 10,
49
+ stock: v[t] ?? 10,
48
50
  isAvailable: t !== 2 && t !== 9 && t !== 18,
49
51
  cartName: e.cartName,
50
52
  preparationTime: 15,
51
- calories: p(e.category) ? Math.floor(Math.random() * 400) + 100 : 0,
53
+ calories: _(e.category) ? Math.floor(Math.random() * 400) + 100 : 0,
52
54
  isVegetarian: t % 3 == 0,
53
55
  isVegan: t % 5 == 0,
54
56
  isGlutenFree: t % 7 == 0,
@@ -63,16 +65,16 @@ var d = [
63
65
  "trending",
64
66
  "new"
65
67
  ].slice(0, t % 3 + 1),
66
- allergens: p(e.category) ? ["nuts", "dairy"].slice(0, t % 2 + 1) : [],
67
- duration: f(e.category) ? 30 + t * 5 : 0,
68
- serviceType: f(e.category) ? [
68
+ allergens: _(e.category) ? ["nuts", "dairy"].slice(0, t % 2 + 1) : [],
69
+ duration: g(e.category) ? 30 + t * 5 : 0,
70
+ serviceType: g(e.category) ? [
69
71
  "instant",
70
72
  "appointment",
71
73
  "recurring",
72
74
  "consultation"
73
75
  ][t % 4] : "",
74
- requirements: f(e.category) ? ["advance booking"] : []
75
- })), g = {
76
+ requirements: g(e.category) ? ["advance booking"] : []
77
+ })), y = {
76
78
  name: "",
77
79
  description: "",
78
80
  category: "",
@@ -91,14 +93,14 @@ var d = [
91
93
  duration: 30,
92
94
  serviceType: "instant",
93
95
  requirements: []
94
- }, _ = () => {
95
- let { navigateTo: i } = e(), [d, m] = o(h), [_, v] = o(""), [y, b] = o(""), [x, S] = o(""), [C, w] = o("name"), [ce, le] = o(!1), [ue, T] = o(!1), [E, D] = o(null), [O, k] = o(g), [A, j] = o(""), [M, N] = o(""), [P, F] = o(""), [I, L] = o(null), R = a(() => [...new Set(d.map((e) => e.category))].sort(), [d]), z = a(() => {
96
- let e = [...d];
97
- if (_) {
98
- let t = _.toLowerCase();
96
+ }, b = () => {
97
+ let { navigateTo: ee } = e(), [h, v] = o(se), [b, x] = o(""), [S, C] = o(""), [w, T] = o(""), [E, D] = o("name"), [ce, le] = o(!1), [O, k] = o(!1), [A, j] = o(null), [M, N] = o(y), [P, F] = o(""), [I, L] = o(""), [R, z] = o(""), [B, V] = o(null), H = a(() => [...new Set(h.map((e) => e.category))].sort(), [h]), U = a(() => {
98
+ let e = [...h];
99
+ if (b) {
100
+ let t = b.toLowerCase();
99
101
  e = e.filter((e) => e.name.toLowerCase().includes(t) || e.description.toLowerCase().includes(t) || e.category.toLowerCase().includes(t) || e.tags.some((e) => e.toLowerCase().includes(t)));
100
102
  }
101
- switch (y && (e = e.filter((e) => e.category === y)), x === "available" ? e = e.filter((e) => e.isAvailable) : x === "unavailable" && (e = e.filter((e) => !e.isAvailable)), C) {
103
+ switch (S && (e = e.filter((e) => e.category === S)), w === "available" ? e = e.filter((e) => e.isAvailable) : w === "unavailable" && (e = e.filter((e) => !e.isAvailable)), E) {
102
104
  case "name":
103
105
  e.sort((e, t) => e.name.localeCompare(t.name));
104
106
  break;
@@ -114,23 +116,23 @@ var d = [
114
116
  }
115
117
  return e;
116
118
  }, [
117
- d,
118
- _,
119
- y,
120
- x,
121
- C
122
- ]), B = d.length, V = d.filter((e) => e.isAvailable).length, H = d.filter((e) => !f(e.category) && e.stock === 0).length, U = d.filter((e) => !f(e.category) && e.stock > 0 && e.stock < 10).length, W = (e, t) => {
123
- L({
119
+ h,
120
+ b,
121
+ S,
122
+ w,
123
+ E
124
+ ]), ue = h.length, de = h.filter((e) => e.isAvailable).length, fe = h.filter((e) => !g(e.category) && e.stock === 0).length, pe = h.filter((e) => !g(e.category) && e.stock > 0 && e.stock < 10).length, W = (e, t) => {
125
+ V({
124
126
  text: e,
125
127
  type: t
126
- }), setTimeout(() => L(null), 3e3);
128
+ }), setTimeout(() => V(null), 3e3);
127
129
  }, G = () => {
128
- D(null), k({
129
- ...g,
130
- category: R[0] || ""
131
- }), j(""), N(""), F(""), T(!0);
130
+ j(null), N({
131
+ ...y,
132
+ category: H[0] || ""
133
+ }), F(""), L(""), z(""), k(!0);
132
134
  }, K = (e) => {
133
- D(e), k({
135
+ j(e), N({
134
136
  name: e.name,
135
137
  description: e.description,
136
138
  category: e.category,
@@ -149,16 +151,16 @@ var d = [
149
151
  duration: e.duration,
150
152
  serviceType: e.serviceType,
151
153
  requirements: e.requirements
152
- }), j(e.tags.join(", ")), N(e.allergens.join(", ")), F(e.requirements.join(", ")), T(!0);
153
- }, de = () => {
154
- if (!O.name || !O.description || !O.category || O.price <= 0) {
154
+ }), F(e.tags.join(", ")), L(e.allergens.join(", ")), z(e.requirements.join(", ")), k(!0);
155
+ }, me = () => {
156
+ if (!M.name || !M.description || !M.category || M.price <= 0) {
155
157
  W("Please fill all required fields (name, description, category, price > 0)", "error");
156
158
  return;
157
159
  }
158
- let e = A.split(",").map((e) => e.trim()).filter(Boolean), t = M.split(",").map((e) => e.trim()).filter(Boolean), n = P.split(",").map((e) => e.trim()).filter(Boolean), r = f(O.category) ? "Service" : "Product";
159
- if (E) m((r) => r.map((r) => r.id === E.id ? {
160
+ let e = P.split(",").map((e) => e.trim()).filter(Boolean), t = I.split(",").map((e) => e.trim()).filter(Boolean), n = R.split(",").map((e) => e.trim()).filter(Boolean), r = g(M.category) ? "Service" : "Product";
161
+ if (A) v((r) => r.map((r) => r.id === A.id ? {
160
162
  ...r,
161
- ...O,
163
+ ...M,
162
164
  tags: e,
163
165
  allergens: t,
164
166
  requirements: n
@@ -166,33 +168,33 @@ var d = [
166
168
  else {
167
169
  let i = {
168
170
  id: `item-${Date.now()}`,
169
- ...O,
171
+ ...M,
170
172
  tags: e,
171
173
  allergens: t,
172
174
  requirements: n,
173
175
  cartName: "Dosa Express"
174
176
  };
175
- m((e) => [i, ...e]), W(`${r} added successfully`, "success");
177
+ v((e) => [i, ...e]), W(`${r} added successfully`, "success");
176
178
  }
177
- T(!1);
179
+ k(!1);
178
180
  }, q = (e) => {
179
- confirm("Are you sure you want to delete this offering?") && (m((t) => t.filter((t) => t.id !== e)), W("Offering deleted successfully", "success"));
181
+ confirm("Are you sure you want to delete this offering?") && (v((t) => t.filter((t) => t.id !== e)), W("Offering deleted successfully", "success"));
180
182
  }, J = (e, t) => {
181
- m((n) => n.map((n) => n.id === e ? {
183
+ v((n) => n.map((n) => n.id === e ? {
182
184
  ...n,
183
185
  isAvailable: t
184
186
  } : n)), W(`Offering ${t ? "enabled" : "disabled"} successfully`, "success");
185
187
  }, Y = (e) => {
186
- let t = e === "enable", n = d.filter((e) => e.isAvailable !== t).length;
188
+ let t = e === "enable", n = h.filter((e) => e.isAvailable !== t).length;
187
189
  if (n === 0) {
188
190
  W(`No offerings to ${e}`, "error");
189
191
  return;
190
192
  }
191
- m((e) => e.map((e) => ({
193
+ v((e) => e.map((e) => ({
192
194
  ...e,
193
195
  isAvailable: t
194
196
  }))), W(`${n} offerings ${e}d successfully`, "success");
195
- }, X = (e) => f(e.category) ? {
197
+ }, X = (e) => g(e.category) ? {
196
198
  color: "text-status-success-text",
197
199
  label: "Available"
198
200
  } : e.stock === 0 ? {
@@ -204,710 +206,711 @@ var d = [
204
206
  } : {
205
207
  color: "text-status-success-text",
206
208
  label: `In Stock (${e.stock})`
207
- }, Z = O.category ? f(O.category) : !1, fe = O.category ? p(O.category) : !1, Q = !Z && fe, $ = O.name && O.description && O.category && O.price > 0 && (!Z || O.duration && O.duration > 0) && (Z || O.stock >= 0);
208
- return /* @__PURE__ */ u(n, {
209
+ }, Z = M.category ? g(M.category) : !1, he = M.category ? _(M.category) : !1, Q = !Z && he, $ = M.name && M.description && M.category && M.price > 0 && (!Z || M.duration && M.duration > 0) && (Z || M.stock >= 0);
210
+ return /* @__PURE__ */ p(n, {
209
211
  title: "Offerings Management",
210
212
  description: "Manage your products and services",
211
- actions: /* @__PURE__ */ u("button", {
213
+ actions: /* @__PURE__ */ p("button", {
212
214
  type: "button",
213
215
  onClick: G,
214
216
  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",
215
- children: [/* @__PURE__ */ l(c, { className: "h-4 w-4" }), "Add Item"]
217
+ children: [/* @__PURE__ */ f(l, { className: "h-4 w-4" }), "Add Item"]
216
218
  }),
217
- children: [/* @__PURE__ */ u("div", {
218
- className: "space-y-4",
219
- children: [
220
- I && /* @__PURE__ */ u("div", {
221
- className: t("flex items-center gap-2 rounded-lg border p-3", I.type === "success" ? "border-status-success-text/30 bg-status-success-bg-subtle" : "border-status-error-text/30 bg-status-error-bg-subtle"),
222
- children: [I.type === "success" ? /* @__PURE__ */ l(te, { className: "h-4 w-4 text-status-success-text" }) : /* @__PURE__ */ l(ee, { className: "h-4 w-4 text-status-error-text" }), /* @__PURE__ */ l("span", {
223
- className: t("text-sm font-medium", I.type === "success" ? "text-status-success-text" : "text-status-error-text"),
224
- children: I.text
225
- })]
226
- }),
227
- /* @__PURE__ */ u("div", {
228
- className: "grid grid-cols-2 lg:grid-cols-4 gap-3",
229
- children: [
230
- /* @__PURE__ */ u("div", {
231
- className: "rounded-lg border border-border-subtle bg-bg-surface p-4 shadow-sm",
232
- children: [/* @__PURE__ */ l("p", {
233
- className: "text-xs text-text-secondary",
234
- children: "Total Items"
235
- }), /* @__PURE__ */ l("p", {
236
- className: "text-2xl font-bold text-text-primary",
237
- children: B
238
- })]
239
- }),
240
- /* @__PURE__ */ u("div", {
241
- className: "rounded-lg border border-border-subtle bg-bg-surface p-4 shadow-sm",
242
- children: [/* @__PURE__ */ l("p", {
243
- className: "text-xs text-text-secondary",
244
- children: "Available"
245
- }), /* @__PURE__ */ l("p", {
246
- className: "text-2xl font-bold text-status-success-text",
247
- children: V
248
- })]
249
- }),
250
- /* @__PURE__ */ u("div", {
251
- className: "rounded-lg border border-border-subtle bg-bg-surface p-4 shadow-sm",
252
- children: [/* @__PURE__ */ l("p", {
253
- className: "text-xs text-text-secondary",
254
- children: "Out of Stock"
255
- }), /* @__PURE__ */ l("p", {
256
- className: "text-2xl font-bold text-status-error-text",
257
- children: H
258
- })]
259
- }),
260
- /* @__PURE__ */ u("div", {
261
- className: "rounded-lg border border-border-subtle bg-bg-surface p-4 shadow-sm",
262
- children: [/* @__PURE__ */ l("p", {
263
- className: "text-xs text-text-secondary",
264
- children: "Low Stock"
265
- }), /* @__PURE__ */ l("p", {
266
- className: "text-2xl font-bold text-status-warning-text",
267
- children: U
268
- })]
269
- })
270
- ]
271
- }),
272
- /* @__PURE__ */ u("div", {
273
- className: "rounded-lg border border-border-subtle bg-bg-surface p-4 shadow-sm space-y-4",
274
- children: [/* @__PURE__ */ u("div", {
275
- className: "flex flex-col lg:flex-row lg:items-center lg:justify-between gap-3",
276
- children: [/* @__PURE__ */ u("div", {
277
- className: "flex flex-wrap gap-2",
278
- children: [
279
- /* @__PURE__ */ u("button", {
280
- type: "button",
281
- onClick: G,
282
- className: "inline-flex items-center gap-1.5 rounded-md bg-accent px-3 py-2 text-sm font-medium text-text-primary hover:bg-accent/80 transition-colors",
283
- children: [/* @__PURE__ */ l(c, { className: "h-4 w-4" }), "Add Item"]
284
- }),
285
- /* @__PURE__ */ l("button", {
286
- type: "button",
287
- onClick: () => Y("enable"),
288
- className: "rounded-md border border-border-subtle px-3 py-2 text-sm text-text-primary hover:bg-bg-sunken transition-colors",
289
- children: "Enable All"
290
- }),
291
- /* @__PURE__ */ l("button", {
292
- type: "button",
293
- onClick: () => Y("disable"),
294
- className: "rounded-md border border-border-subtle px-3 py-2 text-sm text-text-primary hover:bg-bg-sunken transition-colors",
295
- children: "Disable All"
296
- })
297
- ]
298
- }), /* @__PURE__ */ u("button", {
299
- type: "button",
300
- onClick: () => alert("Import/Export feature coming soon!"),
301
- 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",
302
- children: [/* @__PURE__ */ l(ae, { className: "h-4 w-4" }), "Import/Export"]
219
+ children: [
220
+ /* @__PURE__ */ f(m, {
221
+ className: "mb-6",
222
+ children: "The menu and stock control room for your cart. Use this page to add and edit the products and services you offer, set prices and availability, and keep stock levels accurate so customers never order something you can't fulfil. Watch the out-of-stock and low-stock counts and restock before they cost you sales."
223
+ }),
224
+ /* @__PURE__ */ p("div", {
225
+ className: "space-y-4",
226
+ children: [
227
+ B && /* @__PURE__ */ p("div", {
228
+ className: t("flex items-center gap-2 rounded-lg border p-3", B.type === "success" ? "border-status-success-text/30 bg-status-success-bg-subtle" : "border-status-error-text/30 bg-status-error-bg-subtle"),
229
+ children: [B.type === "success" ? /* @__PURE__ */ f(s, { className: "h-4 w-4 text-status-success-text" }) : /* @__PURE__ */ f(te, { className: "h-4 w-4 text-status-error-text" }), /* @__PURE__ */ f("span", {
230
+ className: t("text-sm font-medium", B.type === "success" ? "text-status-success-text" : "text-status-error-text"),
231
+ children: B.text
303
232
  })]
304
- }), /* @__PURE__ */ u("div", {
305
- className: "grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-4 gap-3",
233
+ }),
234
+ /* @__PURE__ */ p(oe, { children: [/* @__PURE__ */ f("h2", {
235
+ className: "mb-4 text-base font-semibold text-text-primary",
236
+ children: "Stock at a Glance"
237
+ }), /* @__PURE__ */ p("div", {
238
+ className: "grid grid-cols-2 lg:grid-cols-4 gap-3",
306
239
  children: [
307
- /* @__PURE__ */ u("div", {
308
- className: "relative sm:col-span-2 lg:col-span-1",
309
- children: [/* @__PURE__ */ l(re, { className: "absolute left-3 top-1/2 h-4 w-4 -translate-y-1/2 text-text-secondary" }), /* @__PURE__ */ l("input", {
310
- type: "text",
311
- placeholder: "Search offerings...",
312
- value: _,
313
- onChange: (e) => v(e.target.value),
314
- className: "w-full rounded-md border border-border-subtle bg-bg-surface pl-10 pr-4 py-2 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
240
+ /* @__PURE__ */ p("div", {
241
+ className: "rounded-lg border border-border-subtle bg-bg-surface p-4 shadow-sm",
242
+ children: [/* @__PURE__ */ f("p", {
243
+ className: "text-xs text-text-secondary",
244
+ children: "Total Items"
245
+ }), /* @__PURE__ */ f("p", {
246
+ className: "text-2xl font-bold text-text-primary",
247
+ children: ue
315
248
  })]
316
249
  }),
317
- /* @__PURE__ */ u("select", {
318
- value: y,
319
- onChange: (e) => b(e.target.value),
320
- className: "rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary",
321
- children: [/* @__PURE__ */ l("option", {
322
- value: "",
323
- children: "All Categories"
324
- }), R.map((e) => /* @__PURE__ */ l("option", {
325
- value: e,
326
- children: e
327
- }, e))]
250
+ /* @__PURE__ */ p("div", {
251
+ className: "rounded-lg border border-border-subtle bg-bg-surface p-4 shadow-sm",
252
+ children: [/* @__PURE__ */ f("p", {
253
+ className: "text-xs text-text-secondary",
254
+ children: "Available"
255
+ }), /* @__PURE__ */ f("p", {
256
+ className: "text-2xl font-bold text-status-success-text",
257
+ children: de
258
+ })]
328
259
  }),
329
- /* @__PURE__ */ u("select", {
330
- value: x,
331
- onChange: (e) => S(e.target.value),
332
- className: "rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary",
333
- children: [
334
- /* @__PURE__ */ l("option", {
335
- value: "",
336
- children: "All Status"
337
- }),
338
- /* @__PURE__ */ l("option", {
339
- value: "available",
340
- children: "Available"
341
- }),
342
- /* @__PURE__ */ l("option", {
343
- value: "unavailable",
344
- children: "Unavailable"
345
- })
346
- ]
260
+ /* @__PURE__ */ p("div", {
261
+ className: "rounded-lg border border-border-subtle bg-bg-surface p-4 shadow-sm",
262
+ children: [/* @__PURE__ */ f("p", {
263
+ className: "text-xs text-text-secondary",
264
+ children: "Out of Stock"
265
+ }), /* @__PURE__ */ f("p", {
266
+ className: "text-2xl font-bold text-status-error-text",
267
+ children: fe
268
+ })]
347
269
  }),
348
- /* @__PURE__ */ u("select", {
349
- value: C,
350
- onChange: (e) => w(e.target.value),
351
- className: "rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary",
270
+ /* @__PURE__ */ p("div", {
271
+ className: "rounded-lg border border-border-subtle bg-bg-surface p-4 shadow-sm",
272
+ children: [/* @__PURE__ */ f("p", {
273
+ className: "text-xs text-text-secondary",
274
+ children: "Low Stock"
275
+ }), /* @__PURE__ */ f("p", {
276
+ className: "text-2xl font-bold text-status-warning-text",
277
+ children: pe
278
+ })]
279
+ })
280
+ ]
281
+ })] }),
282
+ /* @__PURE__ */ p("div", {
283
+ className: "rounded-lg border border-border-subtle bg-bg-surface p-4 shadow-sm space-y-4",
284
+ children: [/* @__PURE__ */ p("div", {
285
+ className: "flex flex-col lg:flex-row lg:items-center lg:justify-between gap-3",
286
+ children: [/* @__PURE__ */ p("div", {
287
+ className: "flex flex-wrap gap-2",
352
288
  children: [
353
- /* @__PURE__ */ l("option", {
354
- value: "name",
355
- children: "Name A-Z"
356
- }),
357
- /* @__PURE__ */ l("option", {
358
- value: "price_low",
359
- children: "Price: Low to High"
289
+ /* @__PURE__ */ p("button", {
290
+ type: "button",
291
+ onClick: G,
292
+ className: "inline-flex items-center gap-1.5 rounded-md bg-accent px-3 py-2 text-sm font-medium text-text-primary hover:bg-accent/80 transition-colors",
293
+ children: [/* @__PURE__ */ f(l, { className: "h-4 w-4" }), "Add Item"]
360
294
  }),
361
- /* @__PURE__ */ l("option", {
362
- value: "price_high",
363
- children: "Price: High to Low"
295
+ /* @__PURE__ */ f("button", {
296
+ type: "button",
297
+ onClick: () => Y("enable"),
298
+ className: "rounded-md border border-border-subtle px-3 py-2 text-sm text-text-primary hover:bg-bg-sunken transition-colors",
299
+ children: "Enable All"
364
300
  }),
365
- /* @__PURE__ */ l("option", {
366
- value: "stock",
367
- children: "Stock: Low to High"
301
+ /* @__PURE__ */ f("button", {
302
+ type: "button",
303
+ onClick: () => Y("disable"),
304
+ className: "rounded-md border border-border-subtle px-3 py-2 text-sm text-text-primary hover:bg-bg-sunken transition-colors",
305
+ children: "Disable All"
368
306
  })
369
307
  ]
370
- })
371
- ]
372
- })]
373
- }),
374
- z.length === 0 ? /* @__PURE__ */ u("div", {
375
- className: "rounded-lg border border-border-subtle bg-bg-surface p-12 text-center shadow-sm",
376
- children: [
377
- /* @__PURE__ */ l(s, { className: "h-12 w-12 text-text-secondary opacity-40 mx-auto mb-3" }),
378
- /* @__PURE__ */ l("h3", {
379
- className: "text-lg font-semibold text-text-primary mb-2",
380
- children: "No Items Found"
381
- }),
382
- /* @__PURE__ */ l("p", {
383
- className: "text-sm text-text-secondary mb-4",
384
- children: _ || y || x ? "No items match your current filters. Try adjusting your search criteria." : "You haven't added any items yet. Start building your offerings!"
385
- }),
386
- /* @__PURE__ */ u("div", {
308
+ }), /* @__PURE__ */ p("button", {
309
+ type: "button",
310
+ onClick: () => alert("Import/Export feature coming soon!"),
311
+ 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",
312
+ children: [/* @__PURE__ */ f(re, { className: "h-4 w-4" }), "Import/Export"]
313
+ })]
314
+ }), /* @__PURE__ */ p("div", {
315
+ className: "grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-4 gap-3",
316
+ children: [
317
+ /* @__PURE__ */ p("div", {
318
+ className: "relative sm:col-span-2 lg:col-span-1",
319
+ children: [/* @__PURE__ */ f(u, { className: "absolute left-3 top-1/2 h-4 w-4 -translate-y-1/2 text-text-secondary" }), /* @__PURE__ */ f("input", {
320
+ type: "text",
321
+ placeholder: "Search offerings...",
322
+ value: b,
323
+ onChange: (e) => x(e.target.value),
324
+ className: "w-full rounded-md border border-border-subtle bg-bg-surface pl-10 pr-4 py-2 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
325
+ })]
326
+ }),
327
+ /* @__PURE__ */ p("select", {
328
+ value: S,
329
+ onChange: (e) => C(e.target.value),
330
+ className: "rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary",
331
+ children: [/* @__PURE__ */ f("option", {
332
+ value: "",
333
+ children: "All Categories"
334
+ }), H.map((e) => /* @__PURE__ */ f("option", {
335
+ value: e,
336
+ children: e
337
+ }, e))]
338
+ }),
339
+ /* @__PURE__ */ p("select", {
340
+ value: w,
341
+ onChange: (e) => T(e.target.value),
342
+ className: "rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary",
343
+ children: [
344
+ /* @__PURE__ */ f("option", {
345
+ value: "",
346
+ children: "All Status"
347
+ }),
348
+ /* @__PURE__ */ f("option", {
349
+ value: "available",
350
+ children: "Available"
351
+ }),
352
+ /* @__PURE__ */ f("option", {
353
+ value: "unavailable",
354
+ children: "Unavailable"
355
+ })
356
+ ]
357
+ }),
358
+ /* @__PURE__ */ p("select", {
359
+ value: E,
360
+ onChange: (e) => D(e.target.value),
361
+ className: "rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary",
362
+ children: [
363
+ /* @__PURE__ */ f("option", {
364
+ value: "name",
365
+ children: "Name A-Z"
366
+ }),
367
+ /* @__PURE__ */ f("option", {
368
+ value: "price_low",
369
+ children: "Price: Low to High"
370
+ }),
371
+ /* @__PURE__ */ f("option", {
372
+ value: "price_high",
373
+ children: "Price: High to Low"
374
+ }),
375
+ /* @__PURE__ */ f("option", {
376
+ value: "stock",
377
+ children: "Stock: Low to High"
378
+ })
379
+ ]
380
+ })
381
+ ]
382
+ })]
383
+ }),
384
+ U.length === 0 ? /* @__PURE__ */ f(r, {
385
+ illustration: b || S || w ? "empty-search" : "empty-files",
386
+ title: "No items found",
387
+ description: b || S || w ? "No items match your current filters. Try adjusting your search criteria." : "You haven't added any items yet. Start building your offerings so customers can order from you.",
388
+ action: /* @__PURE__ */ p("div", {
387
389
  className: "flex flex-wrap justify-center gap-3",
388
- children: [/* @__PURE__ */ u("button", {
390
+ children: [/* @__PURE__ */ p("button", {
389
391
  type: "button",
390
392
  onClick: G,
391
393
  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",
392
- children: [/* @__PURE__ */ l(c, { className: "h-4 w-4" }), "Add Your First Item"]
393
- }), (_ || y || x) && /* @__PURE__ */ l("button", {
394
+ children: [/* @__PURE__ */ f(l, { className: "h-4 w-4" }), "Add Your First Item"]
395
+ }), (b || S || w) && /* @__PURE__ */ f("button", {
394
396
  type: "button",
395
397
  onClick: () => {
396
- v(""), b(""), S(""), w("name");
398
+ x(""), C(""), T(""), D("name");
397
399
  },
398
400
  className: "rounded-md border border-border-subtle px-4 py-2 text-sm text-text-primary hover:bg-bg-sunken",
399
401
  children: "Clear Filters"
400
402
  })]
401
403
  })
402
- ]
403
- }) : /* @__PURE__ */ u(se, { children: [/* @__PURE__ */ l("div", {
404
- className: "hidden lg:block rounded-lg border border-border-subtle bg-bg-surface shadow-sm overflow-hidden",
405
- children: /* @__PURE__ */ l("div", {
406
- className: "overflow-x-auto",
407
- children: /* @__PURE__ */ u("table", {
408
- className: "w-full text-sm",
409
- children: [/* @__PURE__ */ l("thead", { children: /* @__PURE__ */ u("tr", {
410
- className: "border-b border-border-subtle bg-bg-sunken/50",
411
- children: [
412
- /* @__PURE__ */ l("th", {
413
- className: "px-5 py-3 text-left font-medium text-text-secondary",
414
- children: "Item"
415
- }),
416
- /* @__PURE__ */ l("th", {
417
- className: "px-5 py-3 text-left font-medium text-text-secondary",
418
- children: "Category"
419
- }),
420
- /* @__PURE__ */ l("th", {
421
- className: "px-5 py-3 text-right font-medium text-text-secondary",
422
- children: "Price"
423
- }),
424
- /* @__PURE__ */ l("th", {
425
- className: "px-5 py-3 text-left font-medium text-text-secondary",
426
- children: "Stock/Status"
427
- }),
428
- /* @__PURE__ */ l("th", {
429
- className: "px-5 py-3 text-center font-medium text-text-secondary",
430
- children: "Available"
431
- }),
432
- /* @__PURE__ */ l("th", {
433
- className: "px-5 py-3 text-right font-medium text-text-secondary",
434
- children: "Actions"
435
- })
436
- ]
437
- }) }), /* @__PURE__ */ l("tbody", { children: z.map((e) => {
438
- let n = X(e);
439
- return /* @__PURE__ */ u("tr", {
440
- className: "border-b border-border-subtle last:border-0 hover:bg-bg-sunken/30 transition-colors",
404
+ }) : /* @__PURE__ */ p(ae, { children: [/* @__PURE__ */ f("div", {
405
+ className: "hidden lg:block rounded-lg border border-border-subtle bg-bg-surface shadow-sm overflow-hidden",
406
+ children: /* @__PURE__ */ f("div", {
407
+ className: "overflow-x-auto",
408
+ children: /* @__PURE__ */ p("table", {
409
+ className: "w-full text-sm",
410
+ children: [/* @__PURE__ */ f("thead", { children: /* @__PURE__ */ p("tr", {
411
+ className: "border-b border-border-subtle bg-bg-sunken/50",
441
412
  children: [
442
- /* @__PURE__ */ l("td", {
443
- className: "px-5 py-3",
444
- children: /* @__PURE__ */ u("div", {
445
- className: "flex items-center gap-3",
446
- children: [/* @__PURE__ */ l("div", {
447
- className: "flex h-10 w-10 items-center justify-center rounded-md bg-bg-sunken",
448
- children: /* @__PURE__ */ l(s, { className: "h-4 w-4 text-text-secondary" })
449
- }), /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("p", {
450
- className: "font-medium text-text-primary",
451
- children: e.name
452
- }), /* @__PURE__ */ u("p", {
453
- className: "text-xs text-text-secondary line-clamp-1",
454
- children: [e.description.slice(0, 50), "..."]
455
- })] })]
456
- })
413
+ /* @__PURE__ */ f("th", {
414
+ className: "px-5 py-3 text-left font-medium text-text-secondary",
415
+ children: "Item"
457
416
  }),
458
- /* @__PURE__ */ l("td", {
459
- className: "px-5 py-3",
460
- children: /* @__PURE__ */ l("span", {
461
- className: "inline-flex rounded-full bg-bg-sunken px-2.5 py-0.5 text-xs font-medium text-text-secondary",
462
- children: e.category
463
- })
417
+ /* @__PURE__ */ f("th", {
418
+ className: "px-5 py-3 text-left font-medium text-text-secondary",
419
+ children: "Category"
464
420
  }),
465
- /* @__PURE__ */ u("td", {
466
- className: "px-5 py-3 text-right",
467
- children: [/* @__PURE__ */ l("p", {
468
- className: "font-medium text-text-primary",
469
- children: r(e.price, { minimumFractionDigits: 0 })
470
- }), e.originalPrice && /* @__PURE__ */ l("p", {
471
- className: "text-xs text-text-secondary line-through",
472
- children: r(e.originalPrice, { minimumFractionDigits: 0 })
473
- })]
421
+ /* @__PURE__ */ f("th", {
422
+ className: "px-5 py-3 text-right font-medium text-text-secondary",
423
+ children: "Price"
474
424
  }),
475
- /* @__PURE__ */ l("td", {
476
- className: "px-5 py-3",
477
- children: /* @__PURE__ */ l("span", {
478
- className: t("text-sm font-medium", n.color),
479
- children: n.label
480
- })
425
+ /* @__PURE__ */ f("th", {
426
+ className: "px-5 py-3 text-left font-medium text-text-secondary",
427
+ children: "Stock/Status"
481
428
  }),
482
- /* @__PURE__ */ l("td", {
483
- className: "px-5 py-3 text-center",
484
- children: /* @__PURE__ */ l("button", {
485
- type: "button",
486
- onClick: () => J(e.id, !e.isAvailable),
487
- className: t("h-6 w-11 rounded-full transition-colors relative inline-block", e.isAvailable ? "bg-action-primary-bg" : "bg-muted-foreground/30"),
488
- children: /* @__PURE__ */ l("div", { className: t("absolute top-0.5 h-5 w-5 rounded-full bg-white transition-transform", e.isAvailable ? "translate-x-5" : "translate-x-0.5") })
489
- })
429
+ /* @__PURE__ */ f("th", {
430
+ className: "px-5 py-3 text-center font-medium text-text-secondary",
431
+ children: "Available"
490
432
  }),
491
- /* @__PURE__ */ l("td", {
492
- className: "px-5 py-3",
493
- children: /* @__PURE__ */ u("div", {
494
- className: "flex items-center justify-end gap-1",
495
- children: [/* @__PURE__ */ l("button", {
496
- type: "button",
497
- onClick: () => K(e),
498
- className: "rounded p-1.5 text-text-secondary hover:bg-bg-sunken hover:text-text-primary transition-colors",
499
- title: "Edit",
500
- children: /* @__PURE__ */ l(ne, { className: "h-4 w-4" })
501
- }), /* @__PURE__ */ l("button", {
502
- type: "button",
503
- onClick: () => q(e.id),
504
- className: "rounded p-1.5 text-text-secondary hover:bg-status-error-bg-subtle hover:text-status-error-text transition-colors",
505
- title: "Delete",
506
- children: /* @__PURE__ */ l(ie, { className: "h-4 w-4" })
507
- })]
508
- })
433
+ /* @__PURE__ */ f("th", {
434
+ className: "px-5 py-3 text-right font-medium text-text-secondary",
435
+ children: "Actions"
509
436
  })
510
437
  ]
511
- }, e.id);
512
- }) })]
513
- })
514
- })
515
- }), /* @__PURE__ */ l("div", {
516
- className: "lg:hidden space-y-3",
517
- children: z.map((e) => {
518
- let n = X(e);
519
- return /* @__PURE__ */ l("div", {
520
- className: "rounded-lg border border-border-subtle bg-bg-surface p-4 shadow-sm",
521
- children: /* @__PURE__ */ u("div", {
522
- className: "flex items-start gap-3",
523
- children: [/* @__PURE__ */ l("div", {
524
- className: "flex h-14 w-14 items-center justify-center rounded-md bg-bg-sunken shrink-0",
525
- children: /* @__PURE__ */ l(s, { className: "h-6 w-6 text-text-secondary" })
526
- }), /* @__PURE__ */ u("div", {
527
- className: "flex-1 min-w-0",
528
- children: [
529
- /* @__PURE__ */ u("div", {
530
- className: "flex items-start justify-between mb-1",
531
- children: [/* @__PURE__ */ u("div", {
532
- className: "flex-1",
533
- children: [/* @__PURE__ */ l("h3", {
534
- className: "text-sm font-medium text-text-primary line-clamp-1",
535
- children: e.name
536
- }), /* @__PURE__ */ l("p", {
537
- className: "text-xs text-text-secondary mt-0.5 line-clamp-2",
538
- children: e.description
539
- })]
540
- }), /* @__PURE__ */ l("button", {
541
- type: "button",
542
- onClick: () => J(e.id, !e.isAvailable),
543
- className: t("h-5 w-9 rounded-full transition-colors relative ml-2 shrink-0", e.isAvailable ? "bg-action-primary-bg" : "bg-muted-foreground/30"),
544
- children: /* @__PURE__ */ l("div", { className: t("absolute top-0.5 h-4 w-4 rounded-full bg-white transition-transform", e.isAvailable ? "translate-x-4" : "translate-x-0.5") })
545
- })]
546
- }),
547
- /* @__PURE__ */ u("div", {
548
- className: "flex flex-wrap items-center gap-2 mt-2 text-xs",
549
- children: [/* @__PURE__ */ l("span", {
550
- className: "px-2 py-0.5 rounded-full bg-bg-sunken text-text-secondary",
551
- children: e.category
552
- }), /* @__PURE__ */ l("span", {
553
- className: t("font-medium", n.color),
554
- children: n.label
555
- })]
556
- }),
557
- /* @__PURE__ */ u("div", {
558
- className: "flex items-center justify-between mt-3",
559
- children: [/* @__PURE__ */ u("div", {
560
- className: "flex items-center gap-2",
561
- children: [/* @__PURE__ */ l("span", {
562
- className: "font-semibold text-text-primary",
563
- children: r(e.price, { minimumFractionDigits: 0 })
564
- }), e.originalPrice && /* @__PURE__ */ l("span", {
438
+ }) }), /* @__PURE__ */ f("tbody", { children: U.map((e) => {
439
+ let n = X(e);
440
+ return /* @__PURE__ */ p("tr", {
441
+ className: "border-b border-border-subtle last:border-0 hover:bg-bg-sunken/30 transition-colors",
442
+ children: [
443
+ /* @__PURE__ */ f("td", {
444
+ className: "px-5 py-3",
445
+ children: /* @__PURE__ */ p("div", {
446
+ className: "flex items-center gap-3",
447
+ children: [/* @__PURE__ */ f("div", {
448
+ className: "flex h-10 w-10 items-center justify-center rounded-md bg-bg-sunken",
449
+ children: /* @__PURE__ */ f(c, { className: "h-4 w-4 text-text-secondary" })
450
+ }), /* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("p", {
451
+ className: "font-medium text-text-primary",
452
+ children: e.name
453
+ }), /* @__PURE__ */ p("p", {
454
+ className: "text-xs text-text-secondary line-clamp-1",
455
+ children: [e.description.slice(0, 50), "..."]
456
+ })] })]
457
+ })
458
+ }),
459
+ /* @__PURE__ */ f("td", {
460
+ className: "px-5 py-3",
461
+ children: /* @__PURE__ */ f("span", {
462
+ className: "inline-flex rounded-full bg-bg-sunken px-2.5 py-0.5 text-xs font-medium text-text-secondary",
463
+ children: e.category
464
+ })
465
+ }),
466
+ /* @__PURE__ */ p("td", {
467
+ className: "px-5 py-3 text-right",
468
+ children: [/* @__PURE__ */ f("p", {
469
+ className: "font-medium text-text-primary",
470
+ children: i(e.price, { minimumFractionDigits: 0 })
471
+ }), e.originalPrice && /* @__PURE__ */ f("p", {
565
472
  className: "text-xs text-text-secondary line-through",
566
- children: r(e.originalPrice, { minimumFractionDigits: 0 })
473
+ children: i(e.originalPrice, { minimumFractionDigits: 0 })
567
474
  })]
568
- }), /* @__PURE__ */ u("div", {
569
- className: "flex gap-1",
570
- children: [/* @__PURE__ */ l("button", {
475
+ }),
476
+ /* @__PURE__ */ f("td", {
477
+ className: "px-5 py-3",
478
+ children: /* @__PURE__ */ f("span", {
479
+ className: t("text-sm font-medium", n.color),
480
+ children: n.label
481
+ })
482
+ }),
483
+ /* @__PURE__ */ f("td", {
484
+ className: "px-5 py-3 text-center",
485
+ children: /* @__PURE__ */ f("button", {
571
486
  type: "button",
572
- onClick: () => K(e),
573
- className: "rounded px-2 py-1 text-xs border border-border-subtle text-text-primary hover:bg-bg-sunken",
574
- children: "Edit"
575
- }), /* @__PURE__ */ l("button", {
487
+ onClick: () => J(e.id, !e.isAvailable),
488
+ className: t("h-6 w-11 rounded-full transition-colors relative inline-block", e.isAvailable ? "bg-action-primary-bg" : "bg-muted-foreground/30"),
489
+ children: /* @__PURE__ */ f("div", { className: t("absolute top-0.5 h-5 w-5 rounded-full bg-white transition-transform", e.isAvailable ? "translate-x-5" : "translate-x-0.5") })
490
+ })
491
+ }),
492
+ /* @__PURE__ */ f("td", {
493
+ className: "px-5 py-3",
494
+ children: /* @__PURE__ */ p("div", {
495
+ className: "flex items-center justify-end gap-1",
496
+ children: [/* @__PURE__ */ f("button", {
497
+ type: "button",
498
+ onClick: () => K(e),
499
+ className: "rounded p-1.5 text-text-secondary hover:bg-bg-sunken hover:text-text-primary transition-colors",
500
+ title: "Edit",
501
+ children: /* @__PURE__ */ f(ne, { className: "h-4 w-4" })
502
+ }), /* @__PURE__ */ f("button", {
503
+ type: "button",
504
+ onClick: () => q(e.id),
505
+ className: "rounded p-1.5 text-text-secondary hover:bg-status-error-bg-subtle hover:text-status-error-text transition-colors",
506
+ title: "Delete",
507
+ children: /* @__PURE__ */ f(d, { className: "h-4 w-4" })
508
+ })]
509
+ })
510
+ })
511
+ ]
512
+ }, e.id);
513
+ }) })]
514
+ })
515
+ })
516
+ }), /* @__PURE__ */ f("div", {
517
+ className: "lg:hidden space-y-3",
518
+ children: U.map((e) => {
519
+ let n = X(e);
520
+ return /* @__PURE__ */ f("div", {
521
+ className: "rounded-lg border border-border-subtle bg-bg-surface p-4 shadow-sm",
522
+ children: /* @__PURE__ */ p("div", {
523
+ className: "flex items-start gap-3",
524
+ children: [/* @__PURE__ */ f("div", {
525
+ className: "flex h-14 w-14 items-center justify-center rounded-md bg-bg-sunken shrink-0",
526
+ children: /* @__PURE__ */ f(c, { className: "h-6 w-6 text-text-secondary" })
527
+ }), /* @__PURE__ */ p("div", {
528
+ className: "flex-1 min-w-0",
529
+ children: [
530
+ /* @__PURE__ */ p("div", {
531
+ className: "flex items-start justify-between mb-1",
532
+ children: [/* @__PURE__ */ p("div", {
533
+ className: "flex-1",
534
+ children: [/* @__PURE__ */ f("h3", {
535
+ className: "text-sm font-medium text-text-primary line-clamp-1",
536
+ children: e.name
537
+ }), /* @__PURE__ */ f("p", {
538
+ className: "text-xs text-text-secondary mt-0.5 line-clamp-2",
539
+ children: e.description
540
+ })]
541
+ }), /* @__PURE__ */ f("button", {
576
542
  type: "button",
577
- onClick: () => q(e.id),
578
- className: "rounded px-2 py-1 text-xs border border-border-subtle text-status-error-text hover:bg-status-error-bg-subtle",
579
- children: "Delete"
543
+ onClick: () => J(e.id, !e.isAvailable),
544
+ className: t("h-5 w-9 rounded-full transition-colors relative ml-2 shrink-0", e.isAvailable ? "bg-action-primary-bg" : "bg-muted-foreground/30"),
545
+ children: /* @__PURE__ */ f("div", { className: t("absolute top-0.5 h-4 w-4 rounded-full bg-white transition-transform", e.isAvailable ? "translate-x-4" : "translate-x-0.5") })
580
546
  })]
581
- })]
582
- })
547
+ }),
548
+ /* @__PURE__ */ p("div", {
549
+ className: "flex flex-wrap items-center gap-2 mt-2 text-xs",
550
+ children: [/* @__PURE__ */ f("span", {
551
+ className: "px-2 py-0.5 rounded-full bg-bg-sunken text-text-secondary",
552
+ children: e.category
553
+ }), /* @__PURE__ */ f("span", {
554
+ className: t("font-medium", n.color),
555
+ children: n.label
556
+ })]
557
+ }),
558
+ /* @__PURE__ */ p("div", {
559
+ className: "flex items-center justify-between mt-3",
560
+ children: [/* @__PURE__ */ p("div", {
561
+ className: "flex items-center gap-2",
562
+ children: [/* @__PURE__ */ f("span", {
563
+ className: "font-semibold text-text-primary",
564
+ children: i(e.price, { minimumFractionDigits: 0 })
565
+ }), e.originalPrice && /* @__PURE__ */ f("span", {
566
+ className: "text-xs text-text-secondary line-through",
567
+ children: i(e.originalPrice, { minimumFractionDigits: 0 })
568
+ })]
569
+ }), /* @__PURE__ */ p("div", {
570
+ className: "flex gap-1",
571
+ children: [/* @__PURE__ */ f("button", {
572
+ type: "button",
573
+ onClick: () => K(e),
574
+ className: "rounded px-2 py-1 text-xs border border-border-subtle text-text-primary hover:bg-bg-sunken",
575
+ children: "Edit"
576
+ }), /* @__PURE__ */ f("button", {
577
+ type: "button",
578
+ onClick: () => q(e.id),
579
+ className: "rounded px-2 py-1 text-xs border border-border-subtle text-status-error-text hover:bg-status-error-bg-subtle",
580
+ children: "Delete"
581
+ })]
582
+ })]
583
+ })
584
+ ]
585
+ })]
586
+ })
587
+ }, e.id);
588
+ })
589
+ })] })
590
+ ]
591
+ }),
592
+ O && /* @__PURE__ */ f("div", {
593
+ className: "fixed inset-0 z-50 flex items-center justify-center bg-black/50 p-4",
594
+ children: /* @__PURE__ */ f("div", {
595
+ className: "w-full max-w-2xl max-h-[90vh] overflow-y-auto rounded-lg border border-border-subtle bg-bg-surface shadow-xl",
596
+ children: /* @__PURE__ */ p("div", {
597
+ className: "p-6",
598
+ children: [
599
+ /* @__PURE__ */ p("div", {
600
+ className: "flex items-center justify-between mb-4",
601
+ children: [/* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("h3", {
602
+ className: "text-lg font-semibold text-text-primary",
603
+ children: A ? "Edit Item" : "Add New Item"
604
+ }), M.category && /* @__PURE__ */ p("p", {
605
+ className: "text-sm text-text-secondary mt-0.5",
606
+ children: [
607
+ "Type: ",
608
+ Z ? "Service" : "Product",
609
+ " | Category: ",
610
+ M.category
583
611
  ]
612
+ })] }), /* @__PURE__ */ f("button", {
613
+ type: "button",
614
+ onClick: () => k(!1),
615
+ className: "rounded p-1.5 text-text-secondary hover:text-text-primary hover:bg-bg-sunken transition-colors",
616
+ children: /* @__PURE__ */ f(ie, { className: "h-5 w-5" })
584
617
  })]
585
- })
586
- }, e.id);
587
- })
588
- })] })
589
- ]
590
- }), ue && /* @__PURE__ */ l("div", {
591
- className: "fixed inset-0 z-50 flex items-center justify-center bg-black/50 p-4",
592
- children: /* @__PURE__ */ l("div", {
593
- className: "w-full max-w-2xl max-h-[90vh] overflow-y-auto rounded-lg border border-border-subtle bg-bg-surface shadow-xl",
594
- children: /* @__PURE__ */ u("div", {
595
- className: "p-6",
596
- children: [
597
- /* @__PURE__ */ u("div", {
598
- className: "flex items-center justify-between mb-4",
599
- children: [/* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("h3", {
600
- className: "text-lg font-semibold text-text-primary",
601
- children: E ? "Edit Item" : "Add New Item"
602
- }), O.category && /* @__PURE__ */ u("p", {
603
- className: "text-sm text-text-secondary mt-0.5",
618
+ }),
619
+ /* @__PURE__ */ p("div", {
620
+ className: "space-y-4",
604
621
  children: [
605
- "Type: ",
606
- Z ? "Service" : "Product",
607
- " | Category: ",
608
- O.category
609
- ]
610
- })] }), /* @__PURE__ */ l("button", {
611
- type: "button",
612
- onClick: () => T(!1),
613
- className: "rounded p-1.5 text-text-secondary hover:text-text-primary hover:bg-bg-sunken transition-colors",
614
- children: /* @__PURE__ */ l(oe, { className: "h-5 w-5" })
615
- })]
616
- }),
617
- /* @__PURE__ */ u("div", {
618
- className: "space-y-4",
619
- children: [
620
- /* @__PURE__ */ u("div", {
621
- className: "grid grid-cols-1 sm:grid-cols-2 gap-4",
622
- children: [/* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
623
- className: "block text-sm font-medium text-text-primary mb-1",
624
- children: "Item Name *"
625
- }), /* @__PURE__ */ l("input", {
626
- type: "text",
627
- value: O.name,
628
- onChange: (e) => k((t) => ({
629
- ...t,
630
- name: e.target.value
631
- })),
632
- className: "w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary placeholder:text-text-secondary",
633
- placeholder: "Enter item name"
634
- })] }), /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
635
- className: "block text-sm font-medium text-text-primary mb-1",
636
- children: "Category *"
637
- }), /* @__PURE__ */ u("select", {
638
- value: O.category,
639
- onChange: (e) => k((t) => ({
640
- ...t,
641
- category: e.target.value
642
- })),
643
- className: "w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary",
644
- children: [/* @__PURE__ */ l("option", {
645
- value: "",
646
- children: "Select category"
647
- }), R.map((e) => /* @__PURE__ */ l("option", {
648
- value: e,
649
- children: e
650
- }, e))]
651
- })] })]
652
- }),
653
- /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
654
- className: "block text-sm font-medium text-text-primary mb-1",
655
- children: "Description *"
656
- }), /* @__PURE__ */ l("textarea", {
657
- value: O.description,
658
- onChange: (e) => k((t) => ({
659
- ...t,
660
- description: e.target.value
661
- })),
662
- rows: 3,
663
- className: "w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary placeholder:text-text-secondary resize-none",
664
- placeholder: "Describe the offering..."
665
- })] }),
666
- /* @__PURE__ */ u("div", {
667
- className: "grid grid-cols-1 sm:grid-cols-2 gap-4",
668
- children: [/* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
669
- className: "block text-sm font-medium text-text-primary mb-1",
670
- children: "Price *"
671
- }), /* @__PURE__ */ l("input", {
672
- type: "number",
673
- value: O.price,
674
- onChange: (e) => k((t) => ({
675
- ...t,
676
- price: parseInt(e.target.value) || 0
677
- })),
678
- className: "w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary"
679
- })] }), /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
622
+ /* @__PURE__ */ p("div", {
623
+ className: "grid grid-cols-1 sm:grid-cols-2 gap-4",
624
+ children: [/* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("label", {
625
+ className: "block text-sm font-medium text-text-primary mb-1",
626
+ children: "Item Name *"
627
+ }), /* @__PURE__ */ f("input", {
628
+ type: "text",
629
+ value: M.name,
630
+ onChange: (e) => N((t) => ({
631
+ ...t,
632
+ name: e.target.value
633
+ })),
634
+ className: "w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary placeholder:text-text-secondary",
635
+ placeholder: "Enter item name"
636
+ })] }), /* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("label", {
637
+ className: "block text-sm font-medium text-text-primary mb-1",
638
+ children: "Category *"
639
+ }), /* @__PURE__ */ p("select", {
640
+ value: M.category,
641
+ onChange: (e) => N((t) => ({
642
+ ...t,
643
+ category: e.target.value
644
+ })),
645
+ className: "w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary",
646
+ children: [/* @__PURE__ */ f("option", {
647
+ value: "",
648
+ children: "Select category"
649
+ }), H.map((e) => /* @__PURE__ */ f("option", {
650
+ value: e,
651
+ children: e
652
+ }, e))]
653
+ })] })]
654
+ }),
655
+ /* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("label", {
680
656
  className: "block text-sm font-medium text-text-primary mb-1",
681
- children: "Original Price"
682
- }), /* @__PURE__ */ l("input", {
683
- type: "number",
684
- value: O.originalPrice ?? "",
685
- onChange: (e) => k((t) => ({
657
+ children: "Description *"
658
+ }), /* @__PURE__ */ f("textarea", {
659
+ value: M.description,
660
+ onChange: (e) => N((t) => ({
686
661
  ...t,
687
- originalPrice: e.target.value ? parseInt(e.target.value) : void 0
662
+ description: e.target.value
688
663
  })),
689
- className: "w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary",
690
- placeholder: "Optional"
691
- })] })]
692
- }),
693
- !Z && /* @__PURE__ */ u("div", {
694
- className: "grid grid-cols-1 sm:grid-cols-3 gap-4",
695
- children: [
696
- /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
664
+ rows: 3,
665
+ className: "w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary placeholder:text-text-secondary resize-none",
666
+ placeholder: "Describe the offering..."
667
+ })] }),
668
+ /* @__PURE__ */ p("div", {
669
+ className: "grid grid-cols-1 sm:grid-cols-2 gap-4",
670
+ children: [/* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("label", {
697
671
  className: "block text-sm font-medium text-text-primary mb-1",
698
- children: "Stock Quantity *"
699
- }), /* @__PURE__ */ l("input", {
672
+ children: "Price *"
673
+ }), /* @__PURE__ */ f("input", {
700
674
  type: "number",
701
- value: O.stock,
702
- onChange: (e) => k((t) => ({
675
+ value: M.price,
676
+ onChange: (e) => N((t) => ({
703
677
  ...t,
704
- stock: parseInt(e.target.value) || 0
678
+ price: parseInt(e.target.value) || 0
705
679
  })),
706
680
  className: "w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary"
707
- })] }),
708
- /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
681
+ })] }), /* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("label", {
709
682
  className: "block text-sm font-medium text-text-primary mb-1",
710
- children: "Preparation Time (min)"
711
- }), /* @__PURE__ */ l("input", {
683
+ children: "Original Price"
684
+ }), /* @__PURE__ */ f("input", {
712
685
  type: "number",
713
- value: O.preparationTime,
714
- onChange: (e) => k((t) => ({
686
+ value: M.originalPrice ?? "",
687
+ onChange: (e) => N((t) => ({
715
688
  ...t,
716
- preparationTime: parseInt(e.target.value) || 0
689
+ originalPrice: e.target.value ? parseInt(e.target.value) : void 0
690
+ })),
691
+ className: "w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary",
692
+ placeholder: "Optional"
693
+ })] })]
694
+ }),
695
+ !Z && /* @__PURE__ */ p("div", {
696
+ className: "grid grid-cols-1 sm:grid-cols-3 gap-4",
697
+ children: [
698
+ /* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("label", {
699
+ className: "block text-sm font-medium text-text-primary mb-1",
700
+ children: "Stock Quantity *"
701
+ }), /* @__PURE__ */ f("input", {
702
+ type: "number",
703
+ value: M.stock,
704
+ onChange: (e) => N((t) => ({
705
+ ...t,
706
+ stock: parseInt(e.target.value) || 0
707
+ })),
708
+ className: "w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary"
709
+ })] }),
710
+ /* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("label", {
711
+ className: "block text-sm font-medium text-text-primary mb-1",
712
+ children: "Preparation Time (min)"
713
+ }), /* @__PURE__ */ f("input", {
714
+ type: "number",
715
+ value: M.preparationTime,
716
+ onChange: (e) => N((t) => ({
717
+ ...t,
718
+ preparationTime: parseInt(e.target.value) || 0
719
+ })),
720
+ className: "w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary"
721
+ })] }),
722
+ Q && /* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("label", {
723
+ className: "block text-sm font-medium text-text-primary mb-1",
724
+ children: "Calories"
725
+ }), /* @__PURE__ */ f("input", {
726
+ type: "number",
727
+ value: M.calories,
728
+ onChange: (e) => N((t) => ({
729
+ ...t,
730
+ calories: parseInt(e.target.value) || 0
731
+ })),
732
+ className: "w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary"
733
+ })] })
734
+ ]
735
+ }),
736
+ Z && /* @__PURE__ */ p("div", {
737
+ className: "grid grid-cols-1 sm:grid-cols-2 gap-4",
738
+ children: [/* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("label", {
739
+ className: "block text-sm font-medium text-text-primary mb-1",
740
+ children: "Service Duration (min) *"
741
+ }), /* @__PURE__ */ f("input", {
742
+ type: "number",
743
+ value: M.duration,
744
+ onChange: (e) => N((t) => ({
745
+ ...t,
746
+ duration: parseInt(e.target.value) || 30
717
747
  })),
718
748
  className: "w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary"
719
- })] }),
720
- Q && /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
749
+ })] }), /* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("label", {
721
750
  className: "block text-sm font-medium text-text-primary mb-1",
722
- children: "Calories"
723
- }), /* @__PURE__ */ l("input", {
751
+ children: "Setup Time (min)"
752
+ }), /* @__PURE__ */ f("input", {
724
753
  type: "number",
725
- value: O.calories,
726
- onChange: (e) => k((t) => ({
754
+ value: M.preparationTime,
755
+ onChange: (e) => N((t) => ({
727
756
  ...t,
728
- calories: parseInt(e.target.value) || 0
757
+ preparationTime: parseInt(e.target.value) || 0
729
758
  })),
730
759
  className: "w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary"
731
- })] })
732
- ]
733
- }),
734
- Z && /* @__PURE__ */ u("div", {
735
- className: "grid grid-cols-1 sm:grid-cols-2 gap-4",
736
- children: [/* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
737
- className: "block text-sm font-medium text-text-primary mb-1",
738
- children: "Service Duration (min) *"
739
- }), /* @__PURE__ */ l("input", {
740
- type: "number",
741
- value: O.duration,
742
- onChange: (e) => k((t) => ({
743
- ...t,
744
- duration: parseInt(e.target.value) || 30
745
- })),
746
- className: "w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary"
747
- })] }), /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
748
- className: "block text-sm font-medium text-text-primary mb-1",
749
- children: "Setup Time (min)"
750
- }), /* @__PURE__ */ l("input", {
751
- type: "number",
752
- value: O.preparationTime,
753
- onChange: (e) => k((t) => ({
754
- ...t,
755
- preparationTime: parseInt(e.target.value) || 0
756
- })),
757
- className: "w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary"
758
- })] })]
759
- }),
760
- Q && /* @__PURE__ */ u("div", {
761
- className: "grid grid-cols-1 sm:grid-cols-2 gap-4",
762
- children: [/* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
760
+ })] })]
761
+ }),
762
+ Q && /* @__PURE__ */ p("div", {
763
+ className: "grid grid-cols-1 sm:grid-cols-2 gap-4",
764
+ children: [/* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("label", {
765
+ className: "block text-sm font-medium text-text-primary mb-1",
766
+ children: "Spice Level"
767
+ }), /* @__PURE__ */ p("select", {
768
+ value: M.spiceLevel,
769
+ onChange: (e) => N((t) => ({
770
+ ...t,
771
+ spiceLevel: e.target.value
772
+ })),
773
+ className: "w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary",
774
+ children: [
775
+ /* @__PURE__ */ f("option", {
776
+ value: "none",
777
+ children: "None"
778
+ }),
779
+ /* @__PURE__ */ f("option", {
780
+ value: "mild",
781
+ children: "Mild"
782
+ }),
783
+ /* @__PURE__ */ f("option", {
784
+ value: "medium",
785
+ children: "Medium"
786
+ }),
787
+ /* @__PURE__ */ f("option", {
788
+ value: "spicy",
789
+ children: "Spicy"
790
+ }),
791
+ /* @__PURE__ */ f("option", {
792
+ value: "very-spicy",
793
+ children: "Very Spicy"
794
+ })
795
+ ]
796
+ })] }), /* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("label", {
797
+ className: "block text-sm font-medium text-text-primary mb-2",
798
+ children: "Dietary Options"
799
+ }), /* @__PURE__ */ f("div", {
800
+ className: "space-y-2",
801
+ children: [
802
+ "isVegetarian",
803
+ "isVegan",
804
+ "isGlutenFree"
805
+ ].map((e) => /* @__PURE__ */ p("label", {
806
+ className: "flex items-center gap-2 text-sm text-text-primary",
807
+ children: [/* @__PURE__ */ f("input", {
808
+ type: "checkbox",
809
+ checked: M[e],
810
+ onChange: (t) => N((n) => ({
811
+ ...n,
812
+ [e]: t.target.checked
813
+ })),
814
+ className: "rounded border-border-subtle"
815
+ }), e === "isVegetarian" ? "Vegetarian" : e === "isVegan" ? "Vegan" : "Gluten Free"]
816
+ }, e))
817
+ })] })]
818
+ }),
819
+ Z && /* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("label", {
763
820
  className: "block text-sm font-medium text-text-primary mb-1",
764
- children: "Spice Level"
765
- }), /* @__PURE__ */ u("select", {
766
- value: O.spiceLevel,
767
- onChange: (e) => k((t) => ({
821
+ children: "Service Type *"
822
+ }), /* @__PURE__ */ p("select", {
823
+ value: M.serviceType,
824
+ onChange: (e) => N((t) => ({
768
825
  ...t,
769
- spiceLevel: e.target.value
826
+ serviceType: e.target.value
770
827
  })),
771
- className: "w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary",
828
+ className: "w-full sm:w-64 rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary",
772
829
  children: [
773
- /* @__PURE__ */ l("option", {
774
- value: "none",
775
- children: "None"
776
- }),
777
- /* @__PURE__ */ l("option", {
778
- value: "mild",
779
- children: "Mild"
830
+ /* @__PURE__ */ f("option", {
831
+ value: "instant",
832
+ children: "Instant Service"
780
833
  }),
781
- /* @__PURE__ */ l("option", {
782
- value: "medium",
783
- children: "Medium"
834
+ /* @__PURE__ */ f("option", {
835
+ value: "appointment",
836
+ children: "Appointment Based"
784
837
  }),
785
- /* @__PURE__ */ l("option", {
786
- value: "spicy",
787
- children: "Spicy"
838
+ /* @__PURE__ */ f("option", {
839
+ value: "recurring",
840
+ children: "Recurring Service"
788
841
  }),
789
- /* @__PURE__ */ l("option", {
790
- value: "very-spicy",
791
- children: "Very Spicy"
842
+ /* @__PURE__ */ f("option", {
843
+ value: "consultation",
844
+ children: "Consultation"
792
845
  })
793
846
  ]
794
- })] }), /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
795
- className: "block text-sm font-medium text-text-primary mb-2",
796
- children: "Dietary Options"
797
- }), /* @__PURE__ */ l("div", {
798
- className: "space-y-2",
799
- children: [
800
- "isVegetarian",
801
- "isVegan",
802
- "isGlutenFree"
803
- ].map((e) => /* @__PURE__ */ u("label", {
804
- className: "flex items-center gap-2 text-sm text-text-primary",
805
- children: [/* @__PURE__ */ l("input", {
806
- type: "checkbox",
807
- checked: O[e],
808
- onChange: (t) => k((n) => ({
809
- ...n,
810
- [e]: t.target.checked
811
- })),
812
- className: "rounded border-border-subtle"
813
- }), e === "isVegetarian" ? "Vegetarian" : e === "isVegan" ? "Vegan" : "Gluten Free"]
814
- }, e))
815
- })] })]
816
- }),
817
- Z && /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
818
- className: "block text-sm font-medium text-text-primary mb-1",
819
- children: "Service Type *"
820
- }), /* @__PURE__ */ u("select", {
821
- value: O.serviceType,
822
- onChange: (e) => k((t) => ({
823
- ...t,
824
- serviceType: e.target.value
825
- })),
826
- className: "w-full sm:w-64 rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary",
827
- children: [
828
- /* @__PURE__ */ l("option", {
829
- value: "instant",
830
- children: "Instant Service"
831
- }),
832
- /* @__PURE__ */ l("option", {
833
- value: "appointment",
834
- children: "Appointment Based"
847
+ })] }),
848
+ /* @__PURE__ */ p("div", { children: [
849
+ /* @__PURE__ */ f("label", {
850
+ className: "block text-sm font-medium text-text-primary mb-1",
851
+ children: "Tags (comma separated)"
835
852
  }),
836
- /* @__PURE__ */ l("option", {
837
- value: "recurring",
838
- children: "Recurring Service"
853
+ /* @__PURE__ */ f("input", {
854
+ type: "text",
855
+ value: P,
856
+ onChange: (e) => F(e.target.value),
857
+ placeholder: Z ? "professional, certified, quick" : "popular, spicy, traditional",
858
+ className: "w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary placeholder:text-text-secondary"
839
859
  }),
840
- /* @__PURE__ */ l("option", {
841
- value: "consultation",
842
- children: "Consultation"
860
+ /* @__PURE__ */ p("p", {
861
+ className: "text-xs text-text-secondary mt-1",
862
+ children: [
863
+ P.split(",").map((e) => e.trim()).filter(Boolean).length,
864
+ " ",
865
+ "tags"
866
+ ]
843
867
  })
844
- ]
845
- })] }),
846
- /* @__PURE__ */ u("div", { children: [
847
- /* @__PURE__ */ l("label", {
868
+ ] }),
869
+ Q && /* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("label", {
848
870
  className: "block text-sm font-medium text-text-primary mb-1",
849
- children: "Tags (comma separated)"
850
- }),
851
- /* @__PURE__ */ l("input", {
871
+ children: "Allergens (comma separated)"
872
+ }), /* @__PURE__ */ f("input", {
852
873
  type: "text",
853
- value: A,
854
- onChange: (e) => j(e.target.value),
855
- placeholder: Z ? "professional, certified, quick" : "popular, spicy, traditional",
874
+ value: I,
875
+ onChange: (e) => L(e.target.value),
876
+ placeholder: "nuts, dairy, gluten, soy",
856
877
  className: "w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary placeholder:text-text-secondary"
857
- }),
858
- /* @__PURE__ */ u("p", {
859
- className: "text-xs text-text-secondary mt-1",
860
- children: [
861
- A.split(",").map((e) => e.trim()).filter(Boolean).length,
862
- " ",
863
- "tags"
864
- ]
865
- })
866
- ] }),
867
- Q && /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
868
- className: "block text-sm font-medium text-text-primary mb-1",
869
- children: "Allergens (comma separated)"
870
- }), /* @__PURE__ */ l("input", {
871
- type: "text",
872
- value: M,
873
- onChange: (e) => N(e.target.value),
874
- placeholder: "nuts, dairy, gluten, soy",
875
- className: "w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary placeholder:text-text-secondary"
876
- })] }),
877
- Z && /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
878
- className: "block text-sm font-medium text-text-primary mb-1",
879
- children: "Service Requirements (comma separated)"
880
- }), /* @__PURE__ */ l("input", {
881
- type: "text",
882
- value: P,
883
- onChange: (e) => F(e.target.value),
884
- placeholder: "advance booking, payment required, tools provided",
885
- className: "w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary placeholder:text-text-secondary"
886
- })] })
887
- ]
888
- }),
889
- /* @__PURE__ */ u("div", {
890
- className: "flex gap-3 mt-6",
891
- children: [/* @__PURE__ */ l("button", {
892
- type: "button",
893
- onClick: () => T(!1),
894
- className: "flex-1 rounded-md border border-border-subtle px-4 py-2 text-sm font-medium text-text-primary hover:bg-bg-sunken transition-colors",
895
- children: "Cancel"
896
- }), /* @__PURE__ */ l("button", {
897
- type: "button",
898
- onClick: de,
899
- disabled: !$,
900
- className: t("flex-1 rounded-md px-4 py-2 text-sm font-medium transition-colors", $ ? "bg-accent text-text-primary hover:bg-accent/80" : "bg-bg-sunken text-text-secondary cursor-not-allowed"),
901
- children: E ? "Update Item" : "Add Item"
902
- })]
903
- })
904
- ]
878
+ })] }),
879
+ Z && /* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("label", {
880
+ className: "block text-sm font-medium text-text-primary mb-1",
881
+ children: "Service Requirements (comma separated)"
882
+ }), /* @__PURE__ */ f("input", {
883
+ type: "text",
884
+ value: R,
885
+ onChange: (e) => z(e.target.value),
886
+ placeholder: "advance booking, payment required, tools provided",
887
+ className: "w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary placeholder:text-text-secondary"
888
+ })] })
889
+ ]
890
+ }),
891
+ /* @__PURE__ */ p("div", {
892
+ className: "flex gap-3 mt-6",
893
+ children: [/* @__PURE__ */ f("button", {
894
+ type: "button",
895
+ onClick: () => k(!1),
896
+ className: "flex-1 rounded-md border border-border-subtle px-4 py-2 text-sm font-medium text-text-primary hover:bg-bg-sunken transition-colors",
897
+ children: "Cancel"
898
+ }), /* @__PURE__ */ f("button", {
899
+ type: "button",
900
+ onClick: me,
901
+ disabled: !$,
902
+ className: t("flex-1 rounded-md px-4 py-2 text-sm font-medium transition-colors", $ ? "bg-accent text-text-primary hover:bg-accent/80" : "bg-bg-sunken text-text-secondary cursor-not-allowed"),
903
+ children: A ? "Update Item" : "Add Item"
904
+ })]
905
+ })
906
+ ]
907
+ })
905
908
  })
906
909
  })
907
- })]
910
+ ]
908
911
  });
909
912
  };
910
913
  //#endregion
911
- export { _ as InventoryManagementPage };
914
+ export { b as InventoryManagementPage };
912
915
 
913
916
  //# sourceMappingURL=InventoryManagementPage.js.map