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