@burdenoff/microfe-kadaikodi 2026.704.4 → 2026.704.5

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 (126) hide show
  1. package/dist/kadaikodi/KadaikodiRoutes.js +30 -26
  2. package/dist/kadaikodi/KadaikodiRoutes.js.map +1 -1
  3. package/dist/kadaikodi/components/viz/AllocationBar.js +68 -0
  4. package/dist/kadaikodi/components/viz/AllocationBar.js.map +1 -0
  5. package/dist/kadaikodi/components/viz/AreaChart.js +102 -0
  6. package/dist/kadaikodi/components/viz/AreaChart.js.map +1 -0
  7. package/dist/kadaikodi/components/viz/AvatarStack.js +36 -0
  8. package/dist/kadaikodi/components/viz/AvatarStack.js.map +1 -0
  9. package/dist/kadaikodi/components/viz/BarChart.js +83 -0
  10. package/dist/kadaikodi/components/viz/BarChart.js.map +1 -0
  11. package/dist/kadaikodi/components/viz/CertificateCard.js +4 -0
  12. package/dist/kadaikodi/components/viz/DonutChart.js +109 -0
  13. package/dist/kadaikodi/components/viz/DonutChart.js.map +1 -0
  14. package/dist/kadaikodi/components/viz/HBarFunnel.js +54 -0
  15. package/dist/kadaikodi/components/viz/HBarFunnel.js.map +1 -0
  16. package/dist/kadaikodi/components/viz/Heatmap.js +3 -0
  17. package/dist/kadaikodi/components/viz/KanbanBoard.js +50 -0
  18. package/dist/kadaikodi/components/viz/KanbanBoard.js.map +1 -0
  19. package/dist/kadaikodi/components/viz/LineChart.js +4 -0
  20. package/dist/kadaikodi/components/viz/OrgTree.js +2 -0
  21. package/dist/kadaikodi/components/viz/PathSteps.js +3 -0
  22. package/dist/kadaikodi/components/viz/ProgressRing.js +68 -0
  23. package/dist/kadaikodi/components/viz/ProgressRing.js.map +1 -0
  24. package/dist/kadaikodi/components/viz/RatingStars.js +51 -0
  25. package/dist/kadaikodi/components/viz/RatingStars.js.map +1 -0
  26. package/dist/kadaikodi/components/viz/SegmentedTabs.js +69 -0
  27. package/dist/kadaikodi/components/viz/SegmentedTabs.js.map +1 -0
  28. package/dist/kadaikodi/components/viz/SkillBar.js +3 -0
  29. package/dist/kadaikodi/components/viz/Sparkline.js +74 -0
  30. package/dist/kadaikodi/components/viz/Sparkline.js.map +1 -0
  31. package/dist/kadaikodi/components/viz/StatCard.js +60 -0
  32. package/dist/kadaikodi/components/viz/StatCard.js.map +1 -0
  33. package/dist/kadaikodi/components/viz/StepProgress.js +64 -0
  34. package/dist/kadaikodi/components/viz/StepProgress.js.map +1 -0
  35. package/dist/kadaikodi/components/viz/Timeline.js +66 -0
  36. package/dist/kadaikodi/components/viz/Timeline.js.map +1 -0
  37. package/dist/kadaikodi/components/viz/index.js +23 -0
  38. package/dist/kadaikodi/components/viz/lib/Avatar.js +30 -0
  39. package/dist/kadaikodi/components/viz/lib/Avatar.js.map +1 -0
  40. package/dist/kadaikodi/components/viz/lib/CartesianFrame.js +119 -0
  41. package/dist/kadaikodi/components/viz/lib/CartesianFrame.js.map +1 -0
  42. package/dist/kadaikodi/components/viz/lib/ResponsiveSvg.js +35 -0
  43. package/dist/kadaikodi/components/viz/lib/ResponsiveSvg.js.map +1 -0
  44. package/dist/kadaikodi/components/viz/lib/format.js +21 -0
  45. package/dist/kadaikodi/components/viz/lib/format.js.map +1 -0
  46. package/dist/kadaikodi/components/viz/lib/geometry.js +61 -0
  47. package/dist/kadaikodi/components/viz/lib/geometry.js.map +1 -0
  48. package/dist/kadaikodi/components/viz/lib/hooks.js +39 -0
  49. package/dist/kadaikodi/components/viz/lib/hooks.js.map +1 -0
  50. package/dist/kadaikodi/components/viz/lib/palette.js +27 -0
  51. package/dist/kadaikodi/components/viz/lib/palette.js.map +1 -0
  52. package/dist/kadaikodi/hooks/useKadaikodiApi.js +18 -10
  53. package/dist/kadaikodi/hooks/useKadaikodiApi.js.map +1 -1
  54. package/dist/kadaikodi/pages/HomePage.js +373 -631
  55. package/dist/kadaikodi/pages/HomePage.js.map +1 -1
  56. package/dist/kadaikodi/pages/admin/AdminAnalyticsPage.js +304 -169
  57. package/dist/kadaikodi/pages/admin/AdminAnalyticsPage.js.map +1 -1
  58. package/dist/kadaikodi/pages/admin/AdminDashboard.js +255 -271
  59. package/dist/kadaikodi/pages/admin/AdminDashboard.js.map +1 -1
  60. package/dist/kadaikodi/pages/admin/AdminFinancialPage.js +185 -125
  61. package/dist/kadaikodi/pages/admin/AdminFinancialPage.js.map +1 -1
  62. package/dist/kadaikodi/pages/admin/AdminOrdersPage.js +141 -102
  63. package/dist/kadaikodi/pages/admin/AdminOrdersPage.js.map +1 -1
  64. package/dist/kadaikodi/pages/admin/CartManagementPage.js +558 -718
  65. package/dist/kadaikodi/pages/admin/CartManagementPage.js.map +1 -1
  66. package/dist/kadaikodi/pages/admin/UserManagementPage.js.map +1 -1
  67. package/dist/kadaikodi/pages/cart-owner/AnalyticsDashboard.js +142 -55
  68. package/dist/kadaikodi/pages/cart-owner/AnalyticsDashboard.js.map +1 -1
  69. package/dist/kadaikodi/pages/cart-owner/CartOwnerDashboard.js +129 -164
  70. package/dist/kadaikodi/pages/cart-owner/CartOwnerDashboard.js.map +1 -1
  71. package/dist/kadaikodi/pages/cart-owner/InventoryManagementPage.js +379 -361
  72. package/dist/kadaikodi/pages/cart-owner/InventoryManagementPage.js.map +1 -1
  73. package/dist/kadaikodi/pages/cart-owner/InvestmentListingPage.js +266 -166
  74. package/dist/kadaikodi/pages/cart-owner/InvestmentListingPage.js.map +1 -1
  75. package/dist/kadaikodi/pages/cart-owner/MerchantOnboardingPage.js +373 -0
  76. package/dist/kadaikodi/pages/cart-owner/MerchantOnboardingPage.js.map +1 -0
  77. package/dist/kadaikodi/pages/cart-owner/OrderManagementPage.js +288 -161
  78. package/dist/kadaikodi/pages/cart-owner/OrderManagementPage.js.map +1 -1
  79. package/dist/kadaikodi/pages/cart-owner/StaffManagementPage.js +180 -181
  80. package/dist/kadaikodi/pages/cart-owner/StaffManagementPage.js.map +1 -1
  81. package/dist/kadaikodi/pages/common/HelpSupportPage.js.map +1 -1
  82. package/dist/kadaikodi/pages/common/SettingsPage.js.map +1 -1
  83. package/dist/kadaikodi/pages/customer/BookingDetailsPage.js +17 -34
  84. package/dist/kadaikodi/pages/customer/BookingDetailsPage.js.map +1 -1
  85. package/dist/kadaikodi/pages/customer/CartDetailPage.js +405 -248
  86. package/dist/kadaikodi/pages/customer/CartDetailPage.js.map +1 -1
  87. package/dist/kadaikodi/pages/customer/CartDiscoveryPage.js +258 -232
  88. package/dist/kadaikodi/pages/customer/CartDiscoveryPage.js.map +1 -1
  89. package/dist/kadaikodi/pages/customer/CheckoutPage.js +254 -205
  90. package/dist/kadaikodi/pages/customer/CheckoutPage.js.map +1 -1
  91. package/dist/kadaikodi/pages/customer/DirectServiceBookingPage.js +270 -230
  92. package/dist/kadaikodi/pages/customer/DirectServiceBookingPage.js.map +1 -1
  93. package/dist/kadaikodi/pages/customer/FavoritesPage.js +149 -412
  94. package/dist/kadaikodi/pages/customer/FavoritesPage.js.map +1 -1
  95. package/dist/kadaikodi/pages/customer/OrderHistoryPage.js +173 -134
  96. package/dist/kadaikodi/pages/customer/OrderHistoryPage.js.map +1 -1
  97. package/dist/kadaikodi/pages/customer/OrderTrackingPage.js +176 -175
  98. package/dist/kadaikodi/pages/customer/OrderTrackingPage.js.map +1 -1
  99. package/dist/kadaikodi/pages/customer/ReviewsPage.js +295 -438
  100. package/dist/kadaikodi/pages/customer/ReviewsPage.js.map +1 -1
  101. package/dist/kadaikodi/pages/customer/shared.js +181 -0
  102. package/dist/kadaikodi/pages/customer/shared.js.map +1 -0
  103. package/dist/kadaikodi/pages/investor/InvestmentDetailsPage.js +438 -311
  104. package/dist/kadaikodi/pages/investor/InvestmentDetailsPage.js.map +1 -1
  105. package/dist/kadaikodi/pages/investor/InvestmentOpportunitiesPage.js +320 -293
  106. package/dist/kadaikodi/pages/investor/InvestmentOpportunitiesPage.js.map +1 -1
  107. package/dist/kadaikodi/pages/investor/InvestorAnalyticsPage.js +159 -91
  108. package/dist/kadaikodi/pages/investor/InvestorAnalyticsPage.js.map +1 -1
  109. package/dist/kadaikodi/pages/investor/InvestorDashboard.js +137 -107
  110. package/dist/kadaikodi/pages/investor/InvestorDashboard.js.map +1 -1
  111. package/dist/kadaikodi/pages/investor/InvestorInvestmentsPage.js +157 -135
  112. package/dist/kadaikodi/pages/investor/InvestorInvestmentsPage.js.map +1 -1
  113. package/dist/kadaikodi/pages/investor/InvestorPortfolioPage.js +280 -206
  114. package/dist/kadaikodi/pages/investor/InvestorPortfolioPage.js.map +1 -1
  115. package/dist/kadaikodi/pages/investor/InvestorProfilePage.js.map +1 -1
  116. package/dist/kadaikodi/pages/worker/TaskDetailsPage.js +424 -448
  117. package/dist/kadaikodi/pages/worker/TaskDetailsPage.js.map +1 -1
  118. package/dist/kadaikodi/pages/worker/WorkerDashboard.js +328 -445
  119. package/dist/kadaikodi/pages/worker/WorkerDashboard.js.map +1 -1
  120. package/dist/kadaikodi/pages/worker/WorkerOrdersPage.js +141 -164
  121. package/dist/kadaikodi/pages/worker/WorkerOrdersPage.js.map +1 -1
  122. package/dist/kadaikodi/pages/worker/WorkerProfilePage.js +300 -296
  123. package/dist/kadaikodi/pages/worker/WorkerProfilePage.js.map +1 -1
  124. package/dist/kadaikodi/pages/worker/WorkerSchedulePage.js +284 -309
  125. package/dist/kadaikodi/pages/worker/WorkerSchedulePage.js.map +1 -1
  126. package/package.json +1 -1
@@ -3,393 +3,441 @@ import { cn as t } from "../../utils/cn.js";
3
3
  import { PageLayout as n } from "../../components/PageLayout.js";
4
4
  import { useOrders as r, usePlaceOrder as i } from "../../hooks/useKadaikodiApi.js";
5
5
  import { formatCurrency as a } from "../../utils/formatters.js";
6
- import { useMemo as o, useState as s } from "react";
7
- import { AlertCircle as c, ArrowLeft as l, Banknote as u, CheckCircle2 as d, CreditCard as f, Heart as p, Loader2 as m, MapPin as h, ShoppingBag as g, Smartphone as _, Wallet as v } from "lucide-react";
8
- import { jsx as y, jsxs as b } from "react/jsx-runtime";
9
- import { GlassCard as x, PagePurpose as S } from "@burdenoff/fe-libs/ui";
6
+ import { SegmentedTabs as o } from "../../components/viz/SegmentedTabs.js";
7
+ import "../../components/viz/index.js";
8
+ import { ProviderImage as s } from "./shared.js";
9
+ import { useMemo as c, useState as l } from "react";
10
+ import { AlertCircle as u, ArrowLeft as d, Banknote as f, CheckCircle2 as p, CreditCard as m, Heart as h, Loader2 as g, MapPin as _, ShoppingBag as v, Smartphone as y, Wallet as b } from "lucide-react";
11
+ import { jsx as x, jsxs as S } from "react/jsx-runtime";
12
+ import { GlassCard as C, PagePurpose as w } from "@burdenoff/fe-libs/ui";
10
13
  //#region src/kadaikodi/pages/customer/CheckoutPage.tsx
11
- var C = [
14
+ var T = [
12
15
  {
13
16
  id: "cash",
14
17
  label: "Cash on Delivery",
15
- icon: u,
18
+ icon: f,
16
19
  description: "Pay when you receive"
17
20
  },
18
21
  {
19
22
  id: "card",
20
23
  label: "Credit / Debit Card",
21
- icon: f,
24
+ icon: m,
22
25
  description: "Visa, Mastercard, RuPay"
23
26
  },
24
27
  {
25
28
  id: "upi",
26
29
  label: "UPI",
27
- icon: _,
30
+ icon: y,
28
31
  description: "Google Pay, PhonePe, Paytm"
29
32
  },
30
33
  {
31
34
  id: "wallet",
32
35
  label: "Digital Wallet",
33
- icon: v,
36
+ icon: b,
34
37
  description: "Kadaikodi Wallet Balance"
35
38
  }
36
- ], w = [
39
+ ], E = [
37
40
  0,
38
41
  10,
39
42
  20,
40
43
  30
41
44
  ];
42
- function T() {
43
- let { navigateTo: u, currentUser: _ } = e(), { data: v = [], isLoading: T } = r({ customerId: _?.id }), E = i(), D = o(() => v.find((e) => e.status === "pending") || v[0], [v]), [O, k] = s({
45
+ function D() {
46
+ let { navigateTo: f, currentUser: y } = e(), { data: b = [], isLoading: D } = r({ customerId: y?.id }), O = i(), k = c(() => b.find((e) => e.status === "pending") || b[0], [b]), [A, j] = l({
44
47
  addressLine1: "",
45
48
  addressLine2: "",
46
49
  city: "",
47
50
  state: "",
48
51
  pincode: ""
49
- }), [A, j] = s("cash"), [M, N] = s({
52
+ }), [M, N] = l("delivery"), [P, F] = l("cash"), [I, L] = l({
50
53
  cardNumber: "",
51
54
  expiryDate: "",
52
55
  cvv: "",
53
56
  upiId: ""
54
- }), [P, F] = s(0), [I, L] = s(""), [R, z] = s(""), [B, V] = s(!1), H = o(() => {
55
- if (!D) return {
57
+ }), [R, z] = l(0), [B, V] = l(""), [H, U] = l(""), [W, G] = l(!1), K = c(() => {
58
+ if (!k) return {
56
59
  subtotal: 0,
57
60
  deliveryFee: 0,
58
61
  tax: 0,
59
62
  total: 0
60
63
  };
61
- let e = D.subtotal, t = D.deliveryFee, n = D.taxes, r = D.discount ?? 0;
64
+ let e = k.subtotal, t = M === "delivery" ? k.deliveryFee : 0, n = k.taxes, r = k.discount ?? 0;
62
65
  return {
63
66
  subtotal: e,
64
67
  deliveryFee: t,
65
68
  tax: n,
66
69
  discount: r,
67
- total: e + t + n + P - r
70
+ total: e + t + n + R - r
68
71
  };
69
- }, [D, P]), U = o(() => D ? D.items.reduce((e, t) => e + t.quantity, 0) : 0, [D]), W = (e, t) => {
70
- k((n) => ({
72
+ }, [
73
+ k,
74
+ R,
75
+ M
76
+ ]), q = c(() => k ? k.items.reduce((e, t) => e + t.quantity, 0) : 0, [k]), J = (e, t) => {
77
+ j((n) => ({
71
78
  ...n,
72
79
  [e]: t
73
80
  }));
74
- }, G = (e, t) => {
75
- N((n) => ({
81
+ }, Y = (e, t) => {
82
+ L((n) => ({
76
83
  ...n,
77
84
  [e]: t
78
85
  }));
79
- }, K = () => {
80
- if (!O.addressLine1.trim()) return alert("Please enter delivery address"), !1;
81
- if (!O.pincode.trim() || O.pincode.length !== 6) return alert("Please enter a valid 6-digit pincode"), !1;
82
- if (A === "card") {
83
- if (!M.cardNumber || M.cardNumber.length < 16) return alert("Please enter a valid 16-digit card number"), !1;
84
- if (!M.expiryDate) return alert("Please enter card expiry date"), !1;
85
- if (!M.cvv || M.cvv.length < 3) return alert("Please enter a valid 3-digit CVV"), !1;
86
+ }, X = () => {
87
+ if (M === "delivery") {
88
+ if (!A.addressLine1.trim()) return alert("Please enter delivery address"), !1;
89
+ if (!A.pincode.trim() || A.pincode.length !== 6) return alert("Please enter a valid 6-digit pincode"), !1;
90
+ }
91
+ if (P === "card") {
92
+ if (!I.cardNumber || I.cardNumber.length < 16) return alert("Please enter a valid 16-digit card number"), !1;
93
+ if (!I.expiryDate) return alert("Please enter card expiry date"), !1;
94
+ if (!I.cvv || I.cvv.length < 3) return alert("Please enter a valid 3-digit CVV"), !1;
86
95
  }
87
- return A === "upi" && !M.upiId.trim() ? (alert("Please enter UPI ID"), !1) : A === "wallet" ? (alert("Digital wallet integration is coming soon. Please choose another payment method."), !1) : !0;
96
+ return P === "upi" && !I.upiId.trim() ? (alert("Please enter UPI ID"), !1) : P === "wallet" ? (alert("Digital wallet integration is coming soon. Please choose another payment method."), !1) : !0;
88
97
  };
89
- return T ? /* @__PURE__ */ y(n, {
98
+ return D ? /* @__PURE__ */ x(n, {
90
99
  title: "Checkout",
91
- children: /* @__PURE__ */ y("div", {
100
+ children: /* @__PURE__ */ x("div", {
92
101
  className: "flex h-[60vh] items-center justify-center",
93
- children: /* @__PURE__ */ y(m, { className: "h-8 w-8 animate-spin text-primary" })
102
+ children: /* @__PURE__ */ x(g, { className: "h-8 w-8 animate-spin text-primary" })
94
103
  })
95
- }) : D ? /* @__PURE__ */ b(n, {
96
- title: /* @__PURE__ */ b("div", {
104
+ }) : k ? /* @__PURE__ */ S(n, {
105
+ title: /* @__PURE__ */ S("div", {
97
106
  className: "flex items-center gap-3",
98
- children: [/* @__PURE__ */ y("button", {
107
+ children: [/* @__PURE__ */ x("button", {
99
108
  type: "button",
100
- onClick: () => u("/customer/discover"),
109
+ onClick: () => f("/customer/discover"),
101
110
  className: "rounded-md p-1 text-text-secondary hover:bg-accent hover:text-text-primary transition-colors",
102
- children: /* @__PURE__ */ y(l, { className: "h-5 w-5" })
103
- }), /* @__PURE__ */ y("span", { children: "Checkout" })]
111
+ children: /* @__PURE__ */ x(d, { className: "h-5 w-5" })
112
+ }), /* @__PURE__ */ x("span", { children: "Checkout" })]
104
113
  }),
105
114
  description: "Review your order and complete payment",
106
- children: [/* @__PURE__ */ y(S, {
115
+ children: [/* @__PURE__ */ x(w, {
107
116
  className: "mb-6",
108
117
  children: "The last step before your food is on its way — confirm where it's going, pick how you'd like to pay, add a tip or special instructions, and review the total. Everything checks out? Place your order from the summary on the right."
109
- }), /* @__PURE__ */ b("div", {
118
+ }), /* @__PURE__ */ S("div", {
110
119
  className: "grid grid-cols-1 gap-6 lg:grid-cols-3",
111
- children: [/* @__PURE__ */ b("div", {
120
+ children: [/* @__PURE__ */ S("div", {
112
121
  className: "lg:col-span-2 space-y-6",
113
122
  children: [
114
- /* @__PURE__ */ b("section", {
123
+ /* @__PURE__ */ S("section", {
115
124
  className: "rounded-lg border border-border-subtle bg-bg-surface p-5",
116
- children: [/* @__PURE__ */ b("h2", {
125
+ children: [
126
+ /* @__PURE__ */ x("h2", {
127
+ className: "text-base font-semibold text-text-primary mb-4",
128
+ children: "Fulfilment"
129
+ }),
130
+ /* @__PURE__ */ x(o, {
131
+ fill: !0,
132
+ "aria-label": "Fulfilment method",
133
+ tabs: [
134
+ {
135
+ id: "delivery",
136
+ label: "Delivery"
137
+ },
138
+ {
139
+ id: "pickup",
140
+ label: "Pickup"
141
+ },
142
+ {
143
+ id: "on_location",
144
+ label: "On-location"
145
+ }
146
+ ],
147
+ value: M,
148
+ onChange: (e) => N(e)
149
+ }),
150
+ /* @__PURE__ */ x("p", {
151
+ className: "mt-3 text-xs text-text-secondary",
152
+ children: M === "delivery" ? "A delivery partner brings your order to the address below." : M === "pickup" ? "Collect your order from the cart — no delivery fee." : "The cart serves you at your location — no delivery fee."
153
+ })
154
+ ]
155
+ }),
156
+ M === "delivery" && /* @__PURE__ */ S("section", {
157
+ className: "rounded-lg border border-border-subtle bg-bg-surface p-5",
158
+ children: [/* @__PURE__ */ S("h2", {
117
159
  className: "text-base font-semibold text-text-primary mb-4 flex items-center gap-2",
118
- children: [/* @__PURE__ */ y(h, { className: "h-4 w-4 text-text-secondary" }), "Delivery Address"]
119
- }), /* @__PURE__ */ b("div", {
160
+ children: [/* @__PURE__ */ x(_, { className: "h-4 w-4 text-text-secondary" }), "Delivery Address"]
161
+ }), /* @__PURE__ */ S("div", {
120
162
  className: "space-y-4",
121
163
  children: [
122
- /* @__PURE__ */ b("div", { children: [/* @__PURE__ */ b("label", {
164
+ /* @__PURE__ */ S("div", { children: [/* @__PURE__ */ S("label", {
123
165
  className: "block text-sm font-medium text-text-primary mb-1.5",
124
- children: ["Address Line 1 ", /* @__PURE__ */ y("span", {
166
+ children: ["Address Line 1 ", /* @__PURE__ */ x("span", {
125
167
  className: "text-status-error-text",
126
168
  children: "*"
127
169
  })]
128
- }), /* @__PURE__ */ y("input", {
170
+ }), /* @__PURE__ */ x("input", {
129
171
  type: "text",
130
172
  placeholder: "Building, Street, Area",
131
- value: O.addressLine1,
132
- onChange: (e) => W("addressLine1", e.target.value),
173
+ value: A.addressLine1,
174
+ onChange: (e) => J("addressLine1", e.target.value),
133
175
  className: "w-full rounded-lg border border-border-subtle bg-bg-surface px-3 py-2.5 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
134
176
  })] }),
135
- /* @__PURE__ */ b("div", { children: [/* @__PURE__ */ y("label", {
177
+ /* @__PURE__ */ S("div", { children: [/* @__PURE__ */ x("label", {
136
178
  className: "block text-sm font-medium text-text-primary mb-1.5",
137
179
  children: "Address Line 2"
138
- }), /* @__PURE__ */ y("input", {
180
+ }), /* @__PURE__ */ x("input", {
139
181
  type: "text",
140
182
  placeholder: "Apartment, Suite, Floor (Optional)",
141
- value: O.addressLine2,
142
- onChange: (e) => W("addressLine2", e.target.value),
183
+ value: A.addressLine2,
184
+ onChange: (e) => J("addressLine2", e.target.value),
143
185
  className: "w-full rounded-lg border border-border-subtle bg-bg-surface px-3 py-2.5 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
144
186
  })] }),
145
- /* @__PURE__ */ b("div", {
187
+ /* @__PURE__ */ S("div", {
146
188
  className: "grid grid-cols-1 sm:grid-cols-2 gap-4",
147
- children: [/* @__PURE__ */ b("div", { children: [/* @__PURE__ */ b("label", {
189
+ children: [/* @__PURE__ */ S("div", { children: [/* @__PURE__ */ S("label", {
148
190
  className: "block text-sm font-medium text-text-primary mb-1.5",
149
- children: ["City ", /* @__PURE__ */ y("span", {
191
+ children: ["City ", /* @__PURE__ */ x("span", {
150
192
  className: "text-status-error-text",
151
193
  children: "*"
152
194
  })]
153
- }), /* @__PURE__ */ y("input", {
195
+ }), /* @__PURE__ */ x("input", {
154
196
  type: "text",
155
197
  placeholder: "City",
156
- value: O.city,
157
- onChange: (e) => W("city", e.target.value),
198
+ value: A.city,
199
+ onChange: (e) => J("city", e.target.value),
158
200
  className: "w-full rounded-lg border border-border-subtle bg-bg-surface px-3 py-2.5 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
159
- })] }), /* @__PURE__ */ b("div", { children: [/* @__PURE__ */ b("label", {
201
+ })] }), /* @__PURE__ */ S("div", { children: [/* @__PURE__ */ S("label", {
160
202
  className: "block text-sm font-medium text-text-primary mb-1.5",
161
- children: ["State ", /* @__PURE__ */ y("span", {
203
+ children: ["State ", /* @__PURE__ */ x("span", {
162
204
  className: "text-status-error-text",
163
205
  children: "*"
164
206
  })]
165
- }), /* @__PURE__ */ y("input", {
207
+ }), /* @__PURE__ */ x("input", {
166
208
  type: "text",
167
209
  placeholder: "State",
168
- value: O.state,
169
- onChange: (e) => W("state", e.target.value),
210
+ value: A.state,
211
+ onChange: (e) => J("state", e.target.value),
170
212
  className: "w-full rounded-lg border border-border-subtle bg-bg-surface px-3 py-2.5 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
171
213
  })] })]
172
214
  }),
173
- /* @__PURE__ */ b("div", { children: [/* @__PURE__ */ b("label", {
215
+ /* @__PURE__ */ S("div", { children: [/* @__PURE__ */ S("label", {
174
216
  className: "block text-sm font-medium text-text-primary mb-1.5",
175
- children: ["Pincode ", /* @__PURE__ */ y("span", {
217
+ children: ["Pincode ", /* @__PURE__ */ x("span", {
176
218
  className: "text-status-error-text",
177
219
  children: "*"
178
220
  })]
179
- }), /* @__PURE__ */ y("input", {
221
+ }), /* @__PURE__ */ x("input", {
180
222
  type: "text",
181
223
  placeholder: "560001",
182
224
  maxLength: 6,
183
- value: O.pincode,
184
- onChange: (e) => W("pincode", e.target.value.replace(/\D/g, "")),
225
+ value: A.pincode,
226
+ onChange: (e) => J("pincode", e.target.value.replace(/\D/g, "")),
185
227
  className: "w-full rounded-lg border border-border-subtle bg-bg-surface px-3 py-2.5 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
186
228
  })] })
187
229
  ]
188
230
  })]
189
231
  }),
190
- /* @__PURE__ */ b("section", {
232
+ /* @__PURE__ */ S("section", {
191
233
  className: "rounded-lg border border-border-subtle bg-bg-surface p-5",
192
234
  children: [
193
- /* @__PURE__ */ b("h2", {
235
+ /* @__PURE__ */ S("h2", {
194
236
  className: "text-base font-semibold text-text-primary mb-4 flex items-center gap-2",
195
- children: [/* @__PURE__ */ y(f, { className: "h-4 w-4 text-text-secondary" }), "Payment Method"]
237
+ children: [/* @__PURE__ */ x(m, { className: "h-4 w-4 text-text-secondary" }), "Payment Method"]
196
238
  }),
197
- /* @__PURE__ */ y("div", {
239
+ /* @__PURE__ */ x("div", {
198
240
  className: "space-y-2",
199
- children: C.map((e) => {
241
+ children: T.map((e) => {
200
242
  let n = e.icon;
201
- return /* @__PURE__ */ b("button", {
243
+ return /* @__PURE__ */ S("button", {
202
244
  type: "button",
203
- onClick: () => j(e.id),
204
- className: t("flex w-full items-center gap-4 rounded-lg border p-3 transition-colors text-left", A === e.id ? "border-foreground bg-accent" : "border-border-subtle bg-bg-surface hover:bg-accent"),
245
+ onClick: () => F(e.id),
246
+ className: t("flex w-full items-center gap-4 rounded-lg border p-3 transition-colors text-left", P === e.id ? "border-foreground bg-accent" : "border-border-subtle bg-bg-surface hover:bg-accent"),
205
247
  children: [
206
- /* @__PURE__ */ y("div", {
248
+ /* @__PURE__ */ x("div", {
207
249
  className: "flex h-9 w-9 shrink-0 items-center justify-center rounded-md bg-bg-sunken",
208
- children: /* @__PURE__ */ y(n, { className: "h-4 w-4 text-text-secondary" })
250
+ children: /* @__PURE__ */ x(n, { className: "h-4 w-4 text-text-secondary" })
209
251
  }),
210
- /* @__PURE__ */ b("div", {
252
+ /* @__PURE__ */ S("div", {
211
253
  className: "flex-1 min-w-0",
212
- children: [/* @__PURE__ */ y("p", {
254
+ children: [/* @__PURE__ */ x("p", {
213
255
  className: "text-sm font-medium text-text-primary",
214
256
  children: e.label
215
- }), /* @__PURE__ */ y("p", {
257
+ }), /* @__PURE__ */ x("p", {
216
258
  className: "text-xs text-text-secondary",
217
259
  children: e.description
218
260
  })]
219
261
  }),
220
- A === e.id && /* @__PURE__ */ y(d, { className: "h-5 w-5 text-text-primary shrink-0" })
262
+ P === e.id && /* @__PURE__ */ x(p, { className: "h-5 w-5 text-text-primary shrink-0" })
221
263
  ]
222
264
  }, e.id);
223
265
  })
224
266
  }),
225
- A === "card" && /* @__PURE__ */ b("div", {
267
+ P === "card" && /* @__PURE__ */ S("div", {
226
268
  className: "mt-4 space-y-4 border-t border-border-subtle pt-4",
227
- children: [/* @__PURE__ */ b("div", { children: [/* @__PURE__ */ b("label", {
269
+ children: [/* @__PURE__ */ S("div", { children: [/* @__PURE__ */ S("label", {
228
270
  className: "block text-sm font-medium text-text-primary mb-1.5",
229
- children: ["Card Number ", /* @__PURE__ */ y("span", {
271
+ children: ["Card Number ", /* @__PURE__ */ x("span", {
230
272
  className: "text-status-error-text",
231
273
  children: "*"
232
274
  })]
233
- }), /* @__PURE__ */ y("input", {
275
+ }), /* @__PURE__ */ x("input", {
234
276
  type: "text",
235
277
  placeholder: "1234 5678 9012 3456",
236
278
  maxLength: 16,
237
- value: M.cardNumber,
238
- onChange: (e) => G("cardNumber", e.target.value.replace(/\D/g, "")),
279
+ value: I.cardNumber,
280
+ onChange: (e) => Y("cardNumber", e.target.value.replace(/\D/g, "")),
239
281
  className: "w-full rounded-lg border border-border-subtle bg-bg-surface px-3 py-2.5 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
240
- })] }), /* @__PURE__ */ b("div", {
282
+ })] }), /* @__PURE__ */ S("div", {
241
283
  className: "grid grid-cols-1 sm:grid-cols-2 gap-4",
242
- children: [/* @__PURE__ */ b("div", { children: [/* @__PURE__ */ b("label", {
284
+ children: [/* @__PURE__ */ S("div", { children: [/* @__PURE__ */ S("label", {
243
285
  className: "block text-sm font-medium text-text-primary mb-1.5",
244
- children: ["Expiry Date ", /* @__PURE__ */ y("span", {
286
+ children: ["Expiry Date ", /* @__PURE__ */ x("span", {
245
287
  className: "text-status-error-text",
246
288
  children: "*"
247
289
  })]
248
- }), /* @__PURE__ */ y("input", {
290
+ }), /* @__PURE__ */ x("input", {
249
291
  type: "text",
250
292
  placeholder: "MM/YY",
251
293
  maxLength: 5,
252
- value: M.expiryDate,
294
+ value: I.expiryDate,
253
295
  onChange: (e) => {
254
296
  let t = e.target.value.replace(/\D/g, "");
255
- t.length >= 2 && (t = t.slice(0, 2) + "/" + t.slice(2, 4)), G("expiryDate", t);
297
+ t.length >= 2 && (t = t.slice(0, 2) + "/" + t.slice(2, 4)), Y("expiryDate", t);
256
298
  },
257
299
  className: "w-full rounded-lg border border-border-subtle bg-bg-surface px-3 py-2.5 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
258
- })] }), /* @__PURE__ */ b("div", { children: [/* @__PURE__ */ b("label", {
300
+ })] }), /* @__PURE__ */ S("div", { children: [/* @__PURE__ */ S("label", {
259
301
  className: "block text-sm font-medium text-text-primary mb-1.5",
260
- children: ["CVV ", /* @__PURE__ */ y("span", {
302
+ children: ["CVV ", /* @__PURE__ */ x("span", {
261
303
  className: "text-status-error-text",
262
304
  children: "*"
263
305
  })]
264
- }), /* @__PURE__ */ y("input", {
306
+ }), /* @__PURE__ */ x("input", {
265
307
  type: "text",
266
308
  placeholder: "123",
267
309
  maxLength: 3,
268
- value: M.cvv,
269
- onChange: (e) => G("cvv", e.target.value.replace(/\D/g, "")),
310
+ value: I.cvv,
311
+ onChange: (e) => Y("cvv", e.target.value.replace(/\D/g, "")),
270
312
  className: "w-full rounded-lg border border-border-subtle bg-bg-surface px-3 py-2.5 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
271
313
  })] })]
272
314
  })]
273
315
  }),
274
- A === "upi" && /* @__PURE__ */ b("div", {
316
+ P === "upi" && /* @__PURE__ */ S("div", {
275
317
  className: "mt-4 border-t border-border-subtle pt-4",
276
- children: [/* @__PURE__ */ b("label", {
318
+ children: [/* @__PURE__ */ S("label", {
277
319
  className: "block text-sm font-medium text-text-primary mb-1.5",
278
- children: ["UPI ID ", /* @__PURE__ */ y("span", {
320
+ children: ["UPI ID ", /* @__PURE__ */ x("span", {
279
321
  className: "text-status-error-text",
280
322
  children: "*"
281
323
  })]
282
- }), /* @__PURE__ */ y("input", {
324
+ }), /* @__PURE__ */ x("input", {
283
325
  type: "text",
284
326
  placeholder: "user@paytm",
285
- value: M.upiId,
286
- onChange: (e) => G("upiId", e.target.value),
327
+ value: I.upiId,
328
+ onChange: (e) => Y("upiId", e.target.value),
287
329
  className: "w-full rounded-lg border border-border-subtle bg-bg-surface px-3 py-2.5 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
288
330
  })]
289
331
  }),
290
- A === "wallet" && /* @__PURE__ */ b("div", {
332
+ P === "wallet" && /* @__PURE__ */ S("div", {
291
333
  className: "mt-4 flex items-start gap-3 rounded-lg bg-[var(--color-accent-soft)] p-4 border border-border-focus/20",
292
- children: [/* @__PURE__ */ y(c, { className: "h-4 w-4 text-text-primary mt-0.5 shrink-0" }), /* @__PURE__ */ y("p", {
334
+ children: [/* @__PURE__ */ x(u, { className: "h-4 w-4 text-text-primary mt-0.5 shrink-0" }), /* @__PURE__ */ x("p", {
293
335
  className: "text-sm text-text-primary",
294
336
  children: "Digital wallet integration coming soon. Please choose another payment method."
295
337
  })]
296
338
  })
297
339
  ]
298
340
  }),
299
- /* @__PURE__ */ b("section", {
341
+ /* @__PURE__ */ S("section", {
300
342
  className: "rounded-lg border border-border-subtle bg-bg-surface p-5",
301
- children: [/* @__PURE__ */ b("h2", {
343
+ children: [/* @__PURE__ */ S("h2", {
302
344
  className: "text-base font-semibold text-text-primary mb-4 flex items-center gap-2",
303
- children: [/* @__PURE__ */ y(p, { className: "h-4 w-4 text-text-secondary" }), "Additional Options"]
304
- }), /* @__PURE__ */ b("div", {
345
+ children: [/* @__PURE__ */ x(h, { className: "h-4 w-4 text-text-secondary" }), "Additional Options"]
346
+ }), /* @__PURE__ */ S("div", {
305
347
  className: "space-y-5",
306
- children: [/* @__PURE__ */ b("div", { children: [
307
- /* @__PURE__ */ y("label", {
348
+ children: [/* @__PURE__ */ S("div", { children: [
349
+ /* @__PURE__ */ x("label", {
308
350
  className: "block text-sm font-medium text-text-primary mb-2",
309
351
  children: "Tip for delivery partner"
310
352
  }),
311
- /* @__PURE__ */ y("div", {
353
+ /* @__PURE__ */ x("div", {
312
354
  className: "flex flex-wrap gap-2 mb-3",
313
- children: w.map((e) => /* @__PURE__ */ y("button", {
355
+ children: E.map((e) => /* @__PURE__ */ x("button", {
314
356
  type: "button",
315
357
  onClick: () => {
316
- F(e), L("");
358
+ z(e), V("");
317
359
  },
318
- className: t("flex-1 min-w-[64px] rounded-lg px-3 py-2.5 text-sm font-medium transition-colors", P === e && I === "" ? "bg-foreground text-background" : "bg-bg-sunken text-text-secondary hover:bg-accent hover:text-text-primary"),
360
+ className: t("flex-1 min-w-[64px] rounded-lg px-3 py-2.5 text-sm font-medium transition-colors", R === e && B === "" ? "bg-foreground text-background" : "bg-bg-sunken text-text-secondary hover:bg-accent hover:text-text-primary"),
319
361
  children: e === 0 ? "No Tip" : `₹${e}`
320
362
  }, e))
321
363
  }),
322
- /* @__PURE__ */ y("input", {
364
+ /* @__PURE__ */ x("input", {
323
365
  type: "number",
324
366
  placeholder: "Custom tip amount",
325
- value: I,
367
+ value: B,
326
368
  onChange: (e) => {
327
369
  let t = e.target.value;
328
- L(t), F(parseInt(t) || 0);
370
+ V(t), z(parseInt(t) || 0);
329
371
  },
330
372
  className: "w-full rounded-lg border border-border-subtle bg-bg-surface px-3 py-2.5 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
331
373
  })
332
- ] }), /* @__PURE__ */ b("div", { children: [/* @__PURE__ */ y("label", {
374
+ ] }), /* @__PURE__ */ S("div", { children: [/* @__PURE__ */ x("label", {
333
375
  className: "block text-sm font-medium text-text-primary mb-2",
334
376
  children: "Special Instructions"
335
- }), /* @__PURE__ */ y("textarea", {
377
+ }), /* @__PURE__ */ x("textarea", {
336
378
  rows: 3,
337
379
  placeholder: "Any special requests for your order...",
338
- value: R,
339
- onChange: (e) => z(e.target.value),
380
+ value: H,
381
+ onChange: (e) => U(e.target.value),
340
382
  className: "w-full rounded-lg border border-border-subtle bg-bg-surface px-3 py-2.5 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)] resize-none"
341
383
  })] })]
342
384
  })]
343
385
  })
344
386
  ]
345
- }), /* @__PURE__ */ y("div", {
387
+ }), /* @__PURE__ */ x("div", {
346
388
  className: "lg:col-span-1",
347
- children: /* @__PURE__ */ b(x, {
389
+ children: /* @__PURE__ */ S(C, {
348
390
  treatment: "glass",
349
391
  glow: !0,
350
392
  className: "sticky top-6 p-5",
351
393
  children: [
352
- /* @__PURE__ */ y("h2", {
394
+ /* @__PURE__ */ x("h2", {
353
395
  className: "text-base font-semibold text-text-primary mb-4",
354
396
  children: "Order Summary"
355
397
  }),
356
- /* @__PURE__ */ b("div", {
398
+ /* @__PURE__ */ S("div", {
357
399
  className: "flex items-center gap-3 mb-4 pb-4 border-b border-border-subtle",
358
- children: [/* @__PURE__ */ y("div", {
400
+ children: [/* @__PURE__ */ x("div", {
359
401
  className: "h-12 w-12 rounded-md bg-bg-sunken overflow-hidden",
360
- children: /* @__PURE__ */ y("img", {
361
- src: D.cartImage,
362
- alt: D.cartName,
363
- className: "h-full w-full object-cover"
402
+ children: /* @__PURE__ */ x(s, {
403
+ src: k.cartImage,
404
+ alt: k.cartName,
405
+ seed: k.cartName
364
406
  })
365
- }), /* @__PURE__ */ b("div", { children: [/* @__PURE__ */ y("p", {
366
- className: "text-sm font-medium text-text-primary",
367
- children: D.cartName
368
- }), /* @__PURE__ */ b("p", {
369
- className: "text-xs text-text-secondary",
370
- children: [
371
- D.items.length,
372
- " item",
373
- D.items.length === 1 ? "" : "s"
374
- ]
375
- })] })]
407
+ }), /* @__PURE__ */ S("div", {
408
+ className: "min-w-0",
409
+ children: [/* @__PURE__ */ x("p", {
410
+ className: "text-sm font-medium text-text-primary truncate",
411
+ children: k.cartName
412
+ }), /* @__PURE__ */ S("p", {
413
+ className: "text-xs text-text-secondary capitalize",
414
+ children: [
415
+ k.items.length,
416
+ " item",
417
+ k.items.length === 1 ? "" : "s",
418
+ " ·",
419
+ " ",
420
+ M.replace("_", "-")
421
+ ]
422
+ })]
423
+ })]
376
424
  }),
377
- /* @__PURE__ */ y("div", {
425
+ /* @__PURE__ */ x("div", {
378
426
  className: "space-y-2 mb-4",
379
- children: D.items.map((e) => /* @__PURE__ */ b("div", {
427
+ children: k.items.map((e) => /* @__PURE__ */ S("div", {
380
428
  className: "flex justify-between items-start",
381
- children: [/* @__PURE__ */ b("div", {
429
+ children: [/* @__PURE__ */ S("div", {
382
430
  className: "flex-1 min-w-0",
383
431
  children: [
384
- /* @__PURE__ */ y("p", {
432
+ /* @__PURE__ */ x("p", {
385
433
  className: "text-sm text-text-primary",
386
434
  children: e.name
387
435
  }),
388
- e.customizations && e.customizations.length > 0 && /* @__PURE__ */ y("p", {
436
+ e.customizations && e.customizations.length > 0 && /* @__PURE__ */ x("p", {
389
437
  className: "text-xs text-text-secondary mt-0.5",
390
438
  children: e.customizations.join(", ")
391
439
  }),
392
- /* @__PURE__ */ b("p", {
440
+ /* @__PURE__ */ S("p", {
393
441
  className: "text-xs text-text-secondary",
394
442
  children: [
395
443
  a(e.price, { minimumFractionDigits: 0 }),
@@ -398,111 +446,112 @@ function T() {
398
446
  ]
399
447
  })
400
448
  ]
401
- }), /* @__PURE__ */ y("span", {
449
+ }), /* @__PURE__ */ x("span", {
402
450
  className: "text-sm font-medium text-text-primary",
403
451
  children: a(e.price * e.quantity, { minimumFractionDigits: 0 })
404
452
  })]
405
453
  }, e.id))
406
454
  }),
407
- /* @__PURE__ */ b("div", {
455
+ /* @__PURE__ */ S("div", {
408
456
  className: "border-t border-border-subtle pt-4 space-y-2.5 text-sm",
409
457
  children: [
410
- /* @__PURE__ */ b("div", {
458
+ /* @__PURE__ */ S("div", {
411
459
  className: "flex justify-between",
412
- children: [/* @__PURE__ */ b("span", {
460
+ children: [/* @__PURE__ */ S("span", {
413
461
  className: "text-text-secondary",
414
462
  children: [
415
463
  "Subtotal (",
416
- U,
464
+ q,
417
465
  " items)"
418
466
  ]
419
- }), /* @__PURE__ */ y("span", {
467
+ }), /* @__PURE__ */ x("span", {
420
468
  className: "text-text-primary",
421
- children: a(H.subtotal, { minimumFractionDigits: 0 })
469
+ children: a(K.subtotal, { minimumFractionDigits: 0 })
422
470
  })]
423
471
  }),
424
- /* @__PURE__ */ b("div", {
472
+ /* @__PURE__ */ S("div", {
425
473
  className: "flex justify-between",
426
- children: [/* @__PURE__ */ y("span", {
474
+ children: [/* @__PURE__ */ x("span", {
427
475
  className: "text-text-secondary",
428
476
  children: "Delivery Fee"
429
- }), /* @__PURE__ */ y("span", {
477
+ }), /* @__PURE__ */ x("span", {
430
478
  className: "text-text-primary",
431
- children: H.deliveryFee === 0 ? "FREE" : a(H.deliveryFee, { minimumFractionDigits: 0 })
479
+ children: K.deliveryFee === 0 ? "FREE" : a(K.deliveryFee, { minimumFractionDigits: 0 })
432
480
  })]
433
481
  }),
434
- /* @__PURE__ */ b("div", {
482
+ /* @__PURE__ */ S("div", {
435
483
  className: "flex justify-between",
436
- children: [/* @__PURE__ */ y("span", {
484
+ children: [/* @__PURE__ */ x("span", {
437
485
  className: "text-text-secondary",
438
486
  children: "Tax"
439
- }), /* @__PURE__ */ y("span", {
487
+ }), /* @__PURE__ */ x("span", {
440
488
  className: "text-text-primary",
441
- children: a(H.tax, { minimumFractionDigits: 0 })
489
+ children: a(K.tax, { minimumFractionDigits: 0 })
442
490
  })]
443
491
  }),
444
- P > 0 && /* @__PURE__ */ b("div", {
492
+ R > 0 && /* @__PURE__ */ S("div", {
445
493
  className: "flex justify-between",
446
- children: [/* @__PURE__ */ y("span", {
494
+ children: [/* @__PURE__ */ x("span", {
447
495
  className: "text-text-secondary",
448
496
  children: "Tip"
449
- }), /* @__PURE__ */ y("span", {
497
+ }), /* @__PURE__ */ x("span", {
450
498
  className: "text-text-primary",
451
- children: a(P, { minimumFractionDigits: 0 })
499
+ children: a(R, { minimumFractionDigits: 0 })
452
500
  })]
453
501
  }),
454
- H.discount && H.discount > 0 && /* @__PURE__ */ b("div", {
502
+ K.discount && K.discount > 0 && /* @__PURE__ */ S("div", {
455
503
  className: "flex justify-between",
456
- children: [/* @__PURE__ */ y("span", {
504
+ children: [/* @__PURE__ */ x("span", {
457
505
  className: "text-status-success-text",
458
506
  children: "Discount"
459
- }), /* @__PURE__ */ b("span", {
507
+ }), /* @__PURE__ */ S("span", {
460
508
  className: "text-status-success-text",
461
- children: ["-", a(H.discount, { minimumFractionDigits: 0 })]
509
+ children: ["-", a(K.discount, { minimumFractionDigits: 0 })]
462
510
  })]
463
511
  })
464
512
  ]
465
513
  }),
466
- /* @__PURE__ */ b("div", {
514
+ /* @__PURE__ */ S("div", {
467
515
  className: "mt-4 flex justify-between border-t border-border-subtle pt-4",
468
- children: [/* @__PURE__ */ y("span", {
516
+ children: [/* @__PURE__ */ x("span", {
469
517
  className: "text-base font-semibold text-text-primary",
470
518
  children: "Total"
471
- }), /* @__PURE__ */ y("span", {
519
+ }), /* @__PURE__ */ x("span", {
472
520
  className: "text-base font-bold text-text-primary",
473
- children: a(H.total, { minimumFractionDigits: 0 })
521
+ children: a(K.total, { minimumFractionDigits: 0 })
474
522
  })]
475
523
  }),
476
- /* @__PURE__ */ b("button", {
524
+ /* @__PURE__ */ S("button", {
477
525
  type: "button",
478
526
  onClick: async () => {
479
- if (!(!K() || !D)) try {
480
- let e = await E.mutateAsync({
481
- providerId: D.cartId,
482
- customerId: _?.id,
483
- items: D.items.map((e) => ({
527
+ if (!(!X() || !k)) try {
528
+ let e = await O.mutateAsync({
529
+ providerId: k.cartId,
530
+ customerId: y?.id,
531
+ fulfillmentType: M,
532
+ items: k.items.map((e) => ({
484
533
  offeringId: e.id,
485
534
  quantity: e.quantity,
486
535
  customizations: e.customizations
487
536
  })),
488
- deliveryAddress: `${O.addressLine1}, ${O.addressLine2}, ${O.city}, ${O.state} - ${O.pincode}`,
489
- paymentMethod: A.toUpperCase(),
490
- notes: R,
491
- deliveryFee: H.deliveryFee,
492
- tax: H.tax,
493
- tip: P,
494
- total: H.total
537
+ deliveryAddress: M === "delivery" ? `${A.addressLine1}, ${A.addressLine2}, ${A.city}, ${A.state} - ${A.pincode}` : void 0,
538
+ paymentMethod: P.toUpperCase(),
539
+ notes: H,
540
+ deliveryFee: K.deliveryFee,
541
+ tax: K.tax,
542
+ tip: R,
543
+ total: K.total
495
544
  });
496
- alert("Order placed successfully!"), u(`/customer/orders/${e.id}/track`);
545
+ alert("Order placed successfully!"), f(`/customer/orders/${e.id}/track`);
497
546
  } catch {
498
547
  alert("Failed to place order. Please try again.");
499
548
  }
500
549
  },
501
- disabled: E.isPending,
502
- className: t("mt-6 flex w-full items-center justify-center gap-2 rounded-lg py-3 text-sm font-medium transition-opacity", "bg-foreground text-background", E.isPending ? "opacity-60 cursor-not-allowed" : "hover:opacity-90"),
503
- children: [E.isPending ? /* @__PURE__ */ y(m, { className: "h-4 w-4 animate-spin" }) : /* @__PURE__ */ y(g, { className: "h-4 w-4" }), E.isPending ? "Placing Order..." : `Place Order - ${a(H.total, { minimumFractionDigits: 0 })}`]
550
+ disabled: O.isPending,
551
+ className: t("mt-6 flex w-full items-center justify-center gap-2 rounded-lg py-3 text-sm font-medium transition-opacity", "bg-foreground text-background", O.isPending ? "opacity-60 cursor-not-allowed" : "hover:opacity-90"),
552
+ children: [O.isPending ? /* @__PURE__ */ x(g, { className: "h-4 w-4 animate-spin" }) : /* @__PURE__ */ x(v, { className: "h-4 w-4" }), O.isPending ? "Placing Order..." : `Place Order - ${a(K.total, { minimumFractionDigits: 0 })}`]
504
553
  }),
505
- /* @__PURE__ */ y("p", {
554
+ /* @__PURE__ */ x("p", {
506
555
  className: "mt-3 text-center text-xs text-text-secondary",
507
556
  children: "By placing this order, you agree to our Terms of Service and Privacy Policy"
508
557
  })
@@ -510,23 +559,23 @@ function T() {
510
559
  })
511
560
  })]
512
561
  })]
513
- }) : /* @__PURE__ */ y(n, {
562
+ }) : /* @__PURE__ */ x(n, {
514
563
  title: "Checkout",
515
- children: /* @__PURE__ */ b("div", {
564
+ children: /* @__PURE__ */ S("div", {
516
565
  className: "flex flex-col items-center justify-center py-16 text-center",
517
566
  children: [
518
- /* @__PURE__ */ y(g, { className: "h-16 w-16 text-text-secondary/40 mb-4" }),
519
- /* @__PURE__ */ y("h3", {
567
+ /* @__PURE__ */ x(v, { className: "h-16 w-16 text-text-secondary/40 mb-4" }),
568
+ /* @__PURE__ */ x("h3", {
520
569
  className: "text-lg font-semibold text-text-primary mb-2",
521
570
  children: "Your cart is empty"
522
571
  }),
523
- /* @__PURE__ */ y("p", {
572
+ /* @__PURE__ */ x("p", {
524
573
  className: "text-sm text-text-secondary mb-6",
525
574
  children: "Add some items to proceed with checkout"
526
575
  }),
527
- /* @__PURE__ */ y("button", {
576
+ /* @__PURE__ */ x("button", {
528
577
  type: "button",
529
- onClick: () => u("/customer/discover"),
578
+ onClick: () => f("/customer/discover"),
530
579
  className: "rounded-lg bg-foreground px-6 py-3 text-sm font-medium text-background hover:opacity-90 transition-opacity",
531
580
  children: "Browse Carts"
532
581
  })
@@ -535,6 +584,6 @@ function T() {
535
584
  });
536
585
  }
537
586
  //#endregion
538
- export { T as CheckoutPage };
587
+ export { D as CheckoutPage };
539
588
 
540
589
  //# sourceMappingURL=CheckoutPage.js.map