@carlonicora/nextjs-jsonapi 3.24.0 → 3.24.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (92) hide show
  1. package/dist/{BlockNoteEditor-PTD2V4CH.js → BlockNoteEditor-35D4R7HJ.js} +21 -21
  2. package/dist/{BlockNoteEditor-PTD2V4CH.js.map → BlockNoteEditor-35D4R7HJ.js.map} +1 -1
  3. package/dist/{BlockNoteEditor-Q2WEDMKJ.mjs → BlockNoteEditor-65HR6ULV.mjs} +6 -6
  4. package/dist/{BlockNoteViewer-WO6GTDSI.mjs → BlockNoteViewer-KDKGUIG5.mjs} +4 -4
  5. package/dist/{BlockNoteViewer-WOXEJ6RM.js → BlockNoteViewer-QDXDVYEM.js} +5 -5
  6. package/dist/{BlockNoteViewer-WOXEJ6RM.js.map → BlockNoteViewer-QDXDVYEM.js.map} +1 -1
  7. package/dist/JsonApiRequest-G625QAH5.js +26 -0
  8. package/dist/{JsonApiRequest-E4PZPH3N.js.map → JsonApiRequest-G625QAH5.js.map} +1 -1
  9. package/dist/{JsonApiRequest-7AEQWMLJ.mjs → JsonApiRequest-RRMNV7YE.mjs} +2 -2
  10. package/dist/billing/index.d.mts +57 -2
  11. package/dist/billing/index.d.ts +57 -2
  12. package/dist/billing/index.js +408 -403
  13. package/dist/billing/index.js.map +1 -1
  14. package/dist/billing/index.mjs +10 -5
  15. package/dist/{chunk-3YJF7QY4.js → chunk-2XCUAHQT.js} +834 -834
  16. package/dist/{chunk-3YJF7QY4.js.map → chunk-2XCUAHQT.js.map} +1 -1
  17. package/dist/{chunk-3D2MCVRZ.js → chunk-3AR4KA5D.js} +13 -13
  18. package/dist/{chunk-3D2MCVRZ.js.map → chunk-3AR4KA5D.js.map} +1 -1
  19. package/dist/{chunk-GJHKOG5L.mjs → chunk-4O7R2Z2O.mjs} +10 -10
  20. package/dist/chunk-4O7R2Z2O.mjs.map +1 -0
  21. package/dist/{chunk-IOLU4ASD.js → chunk-5TRFNKJS.js} +3 -2
  22. package/dist/chunk-5TRFNKJS.js.map +1 -0
  23. package/dist/{chunk-2O3SFHQ7.mjs → chunk-IBVKPLHT.mjs} +14 -8
  24. package/dist/chunk-IBVKPLHT.mjs.map +1 -0
  25. package/dist/{chunk-IBS6NI7D.js → chunk-JTPRJNT2.js} +3 -2
  26. package/dist/chunk-JTPRJNT2.js.map +1 -0
  27. package/dist/{chunk-C7C7VY4F.mjs → chunk-PI56A4DG.mjs} +3 -2
  28. package/dist/{chunk-C7C7VY4F.mjs.map → chunk-PI56A4DG.mjs.map} +1 -1
  29. package/dist/{chunk-IEJYBQ6J.mjs → chunk-SJLXPHK5.mjs} +3 -2
  30. package/dist/{chunk-IEJYBQ6J.mjs.map → chunk-SJLXPHK5.mjs.map} +1 -1
  31. package/dist/{chunk-BMVA2IM5.mjs → chunk-T76WLDE5.mjs} +3 -3
  32. package/dist/{chunk-IV4DTYXN.js → chunk-U7QVISQS.js} +46 -40
  33. package/dist/chunk-U7QVISQS.js.map +1 -0
  34. package/dist/{chunk-LU7DJ4QF.js → chunk-YXRVPEEJ.js} +3 -3
  35. package/dist/{chunk-LU7DJ4QF.js.map → chunk-YXRVPEEJ.js.map} +1 -1
  36. package/dist/{chunk-HAI7G6MD.mjs → chunk-ZJI5ZZW5.mjs} +3 -3
  37. package/dist/client/index.js +6 -6
  38. package/dist/client/index.mjs +5 -5
  39. package/dist/components/index.js +6 -6
  40. package/dist/components/index.mjs +5 -5
  41. package/dist/contexts/index.js +6 -6
  42. package/dist/contexts/index.mjs +5 -5
  43. package/dist/core/index.d.mts +2 -2
  44. package/dist/core/index.d.ts +2 -2
  45. package/dist/core/index.js +4 -4
  46. package/dist/core/index.mjs +3 -3
  47. package/dist/features/help/index.js +39 -39
  48. package/dist/features/help/index.mjs +5 -5
  49. package/dist/features/tokenusage/index.js +103 -103
  50. package/dist/features/tokenusage/index.mjs +5 -5
  51. package/dist/index.d.mts +1 -1
  52. package/dist/index.d.ts +1 -1
  53. package/dist/index.js +5 -5
  54. package/dist/index.mjs +4 -4
  55. package/dist/{request-FYMQK5CX.mjs → request-5RLK2AM3.mjs} +2 -2
  56. package/dist/request-EUGTI3BE.js +9 -0
  57. package/dist/{request-ZYY6RI5X.js.map → request-EUGTI3BE.js.map} +1 -1
  58. package/dist/{request-6VYDNP5T.mjs → request-FXF63NSQ.mjs} +2 -2
  59. package/dist/request-ZTX6I63X.js +8 -0
  60. package/dist/request-ZTX6I63X.js.map +1 -0
  61. package/dist/{s3.service-DJHqEZAp.d.ts → s3.service-Bqr-fQmi.d.ts} +1 -0
  62. package/dist/{s3.service-DaRFLnrX.d.mts → s3.service-Buiy1ncj.d.mts} +1 -0
  63. package/dist/server/index.d.mts +1 -1
  64. package/dist/server/index.d.ts +1 -1
  65. package/dist/server/index.js +21 -21
  66. package/dist/server/index.mjs +4 -4
  67. package/package.json +1 -1
  68. package/src/client/__tests__/request.test.ts +29 -0
  69. package/src/client/request.ts +5 -1
  70. package/src/features/billing/stripe-customer/data/stripe-customer.service.ts +5 -0
  71. package/src/features/billing/stripe-subscription/components/index.ts +1 -0
  72. package/src/features/notification/contexts/NotificationContext.tsx +5 -2
  73. package/src/features/notification/contexts/__tests__/NotificationContext.spec.tsx +32 -0
  74. package/src/features/notification/data/notification.service.ts +6 -1
  75. package/src/server/__tests__/request.test.ts +17 -0
  76. package/src/server/request.ts +5 -1
  77. package/dist/JsonApiRequest-E4PZPH3N.js +0 -26
  78. package/dist/chunk-2O3SFHQ7.mjs.map +0 -1
  79. package/dist/chunk-GJHKOG5L.mjs.map +0 -1
  80. package/dist/chunk-IBS6NI7D.js.map +0 -1
  81. package/dist/chunk-IOLU4ASD.js.map +0 -1
  82. package/dist/chunk-IV4DTYXN.js.map +0 -1
  83. package/dist/request-UR7VPG3G.js +0 -8
  84. package/dist/request-UR7VPG3G.js.map +0 -1
  85. package/dist/request-ZYY6RI5X.js +0 -9
  86. /package/dist/{BlockNoteEditor-Q2WEDMKJ.mjs.map → BlockNoteEditor-65HR6ULV.mjs.map} +0 -0
  87. /package/dist/{BlockNoteViewer-WO6GTDSI.mjs.map → BlockNoteViewer-KDKGUIG5.mjs.map} +0 -0
  88. /package/dist/{JsonApiRequest-7AEQWMLJ.mjs.map → JsonApiRequest-RRMNV7YE.mjs.map} +0 -0
  89. /package/dist/{chunk-BMVA2IM5.mjs.map → chunk-T76WLDE5.mjs.map} +0 -0
  90. /package/dist/{chunk-HAI7G6MD.mjs.map → chunk-ZJI5ZZW5.mjs.map} +0 -0
  91. /package/dist/{request-6VYDNP5T.mjs.map → request-5RLK2AM3.mjs.map} +0 -0
  92. /package/dist/{request-FYMQK5CX.mjs.map → request-FXF63NSQ.mjs.map} +0 -0
@@ -62,12 +62,12 @@
62
62
 
63
63
 
64
64
 
65
- var _chunk3YJF7QY4js = require('../chunk-3YJF7QY4.js');
65
+ var _chunk2XCUAHQTjs = require('../chunk-2XCUAHQT.js');
66
66
 
67
67
 
68
68
 
69
69
 
70
- var _chunk3D2MCVRZjs = require('../chunk-3D2MCVRZ.js');
70
+ var _chunk3AR4KA5Djs = require('../chunk-3AR4KA5D.js');
71
71
 
72
72
 
73
73
 
@@ -81,10 +81,10 @@ var _chunk3D2MCVRZjs = require('../chunk-3D2MCVRZ.js');
81
81
 
82
82
 
83
83
 
84
- var _chunkIV4DTYXNjs = require('../chunk-IV4DTYXN.js');
84
+ var _chunkU7QVISQSjs = require('../chunk-U7QVISQS.js');
85
85
  require('../chunk-LXKSUWAV.js');
86
- require('../chunk-IBS6NI7D.js');
87
- require('../chunk-LU7DJ4QF.js');
86
+ require('../chunk-JTPRJNT2.js');
87
+ require('../chunk-YXRVPEEJ.js');
88
88
  require('../chunk-3EPNHTMH.js');
89
89
 
90
90
 
@@ -132,41 +132,41 @@ function SubscriptionSummaryCard({
132
132
  onManageClick
133
133
  }) {
134
134
  if (loading) {
135
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.Card, { children: [
136
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
137
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardTitle, { children: "Subscriptions" }),
135
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.Card, { children: [
136
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
137
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardTitle, { children: "Subscriptions" }),
138
138
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.CreditCard, { className: "h-4 w-4 text-muted-foreground" })
139
139
  ] }),
140
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.CardContent, { children: [
141
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Skeleton, { className: "h-6 w-32 mb-2" }),
142
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Skeleton, { className: "h-4 w-24 mb-1" }),
143
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Skeleton, { className: "h-4 w-40" })
140
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.CardContent, { children: [
141
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Skeleton, { className: "h-6 w-32 mb-2" }),
142
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Skeleton, { className: "h-4 w-24 mb-1" }),
143
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Skeleton, { className: "h-4 w-40" })
144
144
  ] })
145
145
  ] });
146
146
  }
147
147
  if (error) {
148
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.Card, { children: [
149
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
150
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardTitle, { children: "Subscriptions" }),
148
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.Card, { children: [
149
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
150
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardTitle, { children: "Subscriptions" }),
151
151
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.CreditCard, { className: "h-4 w-4 text-muted-foreground" })
152
152
  ] }),
153
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardContent, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-destructive text-xs/relaxed", children: error }) })
153
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardContent, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-destructive text-xs/relaxed", children: error }) })
154
154
  ] });
155
155
  }
156
156
  const activeSubscriptions = subscriptions.filter(
157
157
  (sub) => sub.status === "active" /* ACTIVE */ || sub.status === "trialing" /* TRIALING */
158
158
  );
159
159
  const primarySubscription = activeSubscriptions[0];
160
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.Card, { className: "cursor-pointer hover:bg-accent/50 transition-colors", onClick: onManageClick, children: [
161
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
162
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardTitle, { children: "Subscriptions" }),
160
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.Card, { className: "cursor-pointer hover:bg-accent/50 transition-colors", onClick: onManageClick, children: [
161
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
162
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardTitle, { children: "Subscriptions" }),
163
163
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.CreditCard, { className: "h-4 w-4 text-muted-foreground" })
164
164
  ] }),
165
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardContent, { children: subscriptions.length === 0 ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2", children: [
165
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardContent, { children: subscriptions.length === 0 ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2", children: [
166
166
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-xl font-bold text-muted-foreground", children: "No active plan" }),
167
167
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-xs text-muted-foreground", children: "Subscribe to get started" }),
168
168
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
169
- _chunk3YJF7QY4js.Button,
169
+ _chunk2XCUAHQTjs.Button,
170
170
  {
171
171
  variant: "outline",
172
172
  size: "sm",
@@ -185,7 +185,7 @@ function SubscriptionSummaryCard({
185
185
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center gap-2", children: [
186
186
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-xl font-bold", children: formatPlanName(primarySubscription) }),
187
187
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
188
- _chunk3YJF7QY4js.Badge,
188
+ _chunk2XCUAHQTjs.Badge,
189
189
  {
190
190
  variant: primarySubscription.cancelAtPeriodEnd ? "secondary" : getStatusBadgeVariant(primarySubscription.status),
191
191
  children: primarySubscription.cancelAtPeriodEnd ? "Canceling" : primarySubscription.status
@@ -227,37 +227,37 @@ function PaymentMethodSummaryCard({
227
227
  onManageClick
228
228
  }) {
229
229
  if (loading) {
230
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.Card, { children: [
231
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
232
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardTitle, { children: "Payment Method" }),
230
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.Card, { children: [
231
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
232
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardTitle, { children: "Payment Method" }),
233
233
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.Wallet, { className: "h-4 w-4 text-muted-foreground" })
234
234
  ] }),
235
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.CardContent, { children: [
236
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Skeleton, { className: "h-6 w-32 mb-2" }),
237
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Skeleton, { className: "h-4 w-24" })
235
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.CardContent, { children: [
236
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Skeleton, { className: "h-6 w-32 mb-2" }),
237
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Skeleton, { className: "h-4 w-24" })
238
238
  ] })
239
239
  ] });
240
240
  }
241
241
  if (error) {
242
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.Card, { children: [
243
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
244
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardTitle, { children: "Payment Method" }),
242
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.Card, { children: [
243
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
244
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardTitle, { children: "Payment Method" }),
245
245
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.Wallet, { className: "h-4 w-4 text-muted-foreground" })
246
246
  ] }),
247
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardContent, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-destructive text-xs/relaxed", children: error }) })
247
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardContent, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-destructive text-xs/relaxed", children: error }) })
248
248
  ] });
249
249
  }
250
250
  const defaultMethod = paymentMethods.find((pm) => pm.id === defaultPaymentMethodId) || paymentMethods[0];
251
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.Card, { className: "cursor-pointer hover:bg-accent/50 transition-colors", onClick: onManageClick, children: [
252
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
253
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardTitle, { children: "Payment Method" }),
251
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.Card, { className: "cursor-pointer hover:bg-accent/50 transition-colors", onClick: onManageClick, children: [
252
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
253
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardTitle, { children: "Payment Method" }),
254
254
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.Wallet, { className: "h-4 w-4 text-muted-foreground" })
255
255
  ] }),
256
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardContent, { children: paymentMethods.length === 0 ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2", children: [
256
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardContent, { children: paymentMethods.length === 0 ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2", children: [
257
257
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-xl font-bold text-muted-foreground", children: "No payment method" }),
258
258
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-xs text-muted-foreground", children: "Add a card to enable subscriptions" }),
259
259
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
260
- _chunk3YJF7QY4js.Button,
260
+ _chunk2XCUAHQTjs.Button,
261
261
  {
262
262
  variant: "outline",
263
263
  size: "sm",
@@ -321,7 +321,7 @@ function CustomerInfoCard({ customer, loading, error }) {
321
321
  e.stopPropagation();
322
322
  setPortalLoading(true);
323
323
  try {
324
- const { url } = await _chunkIV4DTYXNjs.StripeCustomerService.createPortalSession();
324
+ const { url } = await _chunkU7QVISQSjs.StripeCustomerService.createPortalSession();
325
325
  window.open(url, "_blank");
326
326
  } catch (err) {
327
327
  console.error("[CustomerInfoCard] Failed to create portal session:", err);
@@ -330,52 +330,52 @@ function CustomerInfoCard({ customer, loading, error }) {
330
330
  }
331
331
  }, "handlePortalClick");
332
332
  if (loading) {
333
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.Card, { children: [
334
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
335
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardTitle, { children: "Billing Account" }),
333
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.Card, { children: [
334
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
335
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardTitle, { children: "Billing Account" }),
336
336
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.User, { className: "h-4 w-4 text-muted-foreground" })
337
337
  ] }),
338
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.CardContent, { children: [
339
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Skeleton, { className: "h-6 w-32 mb-2" }),
340
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Skeleton, { className: "h-4 w-48 mb-1" }),
341
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Skeleton, { className: "h-4 w-24" })
338
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.CardContent, { children: [
339
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Skeleton, { className: "h-6 w-32 mb-2" }),
340
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Skeleton, { className: "h-4 w-48 mb-1" }),
341
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Skeleton, { className: "h-4 w-24" })
342
342
  ] })
343
343
  ] });
344
344
  }
345
345
  if (error) {
346
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.Card, { children: [
347
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
348
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardTitle, { children: "Billing Account" }),
346
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.Card, { children: [
347
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
348
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardTitle, { children: "Billing Account" }),
349
349
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.User, { className: "h-4 w-4 text-muted-foreground" })
350
350
  ] }),
351
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardContent, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-destructive text-xs/relaxed", children: error }) })
351
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardContent, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-destructive text-xs/relaxed", children: error }) })
352
352
  ] });
353
353
  }
354
354
  if (!customer) {
355
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.Card, { children: [
356
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
357
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardTitle, { children: "Billing Account" }),
355
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.Card, { children: [
356
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
357
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardTitle, { children: "Billing Account" }),
358
358
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.User, { className: "h-4 w-4 text-muted-foreground" })
359
359
  ] }),
360
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.CardContent, { children: [
360
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.CardContent, { children: [
361
361
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-xl font-bold text-muted-foreground", children: "Not set up" }),
362
362
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-xs text-muted-foreground", children: "Billing account will be created when you subscribe" })
363
363
  ] })
364
364
  ] });
365
365
  }
366
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.Card, { children: [
367
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
368
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardTitle, { children: "Billing Account" }),
366
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.Card, { children: [
367
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
368
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardTitle, { children: "Billing Account" }),
369
369
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.User, { className: "h-4 w-4 text-muted-foreground" })
370
370
  ] }),
371
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardContent, { children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2", children: [
371
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardContent, { children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2", children: [
372
372
  customer.name && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-xl font-bold", children: customer.name }),
373
373
  customer.email && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-sm text-muted-foreground", children: customer.email }),
374
374
  customer.balance !== void 0 && customer.balance !== 0 && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "p", { className: "text-sm", children: [
375
375
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-muted-foreground", children: "Credit Balance: " }),
376
376
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: customer.balance < 0 ? "text-success" : "text-destructive", children: formatBalance(customer.balance, customer.currency) })
377
377
  ] }),
378
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.Button, { variant: "outline", size: "sm", className: "mt-2", onClick: handlePortalClick, disabled: portalLoading, children: [
378
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.Button, { variant: "outline", size: "sm", className: "mt-2", onClick: handlePortalClick, disabled: portalLoading, children: [
379
379
  portalLoading ? "Loading..." : "Manage in Stripe Portal",
380
380
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.ExternalLink, { className: "h-4 w-4 ms-1" })
381
381
  ] })
@@ -419,42 +419,42 @@ function formatAmount(amount, currency) {
419
419
  _chunk7QVYU63Ejs.__name.call(void 0, formatAmount, "formatAmount");
420
420
  function InvoicesSummaryCard({ invoices, loading, error, onViewAllClick }) {
421
421
  if (loading) {
422
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.Card, { children: [
423
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
424
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardTitle, { children: "Recent Invoices" }),
422
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.Card, { children: [
423
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
424
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardTitle, { children: "Recent Invoices" }),
425
425
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.ReceiptIcon, { className: "h-4 w-4 text-muted-foreground" })
426
426
  ] }),
427
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.CardContent, { children: [
428
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Skeleton, { className: "h-6 w-24 mb-2" }),
429
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Skeleton, { className: "h-4 w-32 mb-1" }),
430
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Skeleton, { className: "h-4 w-20" })
427
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.CardContent, { children: [
428
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Skeleton, { className: "h-6 w-24 mb-2" }),
429
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Skeleton, { className: "h-4 w-32 mb-1" }),
430
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Skeleton, { className: "h-4 w-20" })
431
431
  ] })
432
432
  ] });
433
433
  }
434
434
  if (error) {
435
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.Card, { children: [
436
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
437
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardTitle, { children: "Recent Invoices" }),
435
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.Card, { children: [
436
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
437
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardTitle, { children: "Recent Invoices" }),
438
438
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.ReceiptIcon, { className: "h-4 w-4 text-muted-foreground" })
439
439
  ] }),
440
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardContent, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-destructive text-xs/relaxed", children: error }) })
440
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardContent, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-destructive text-xs/relaxed", children: error }) })
441
441
  ] });
442
442
  }
443
443
  const latestInvoice = invoices[0];
444
444
  const paidInvoices = invoices.filter((inv) => inv.status === "paid" /* PAID */);
445
445
  const openInvoices = invoices.filter((inv) => inv.status === "open" /* OPEN */);
446
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.Card, { className: "cursor-pointer hover:bg-accent/50 transition-colors", onClick: onViewAllClick, children: [
447
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
448
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardTitle, { children: "Recent Invoices" }),
446
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.Card, { className: "cursor-pointer hover:bg-accent/50 transition-colors", onClick: onViewAllClick, children: [
447
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
448
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardTitle, { children: "Recent Invoices" }),
449
449
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.ReceiptIcon, { className: "h-4 w-4 text-muted-foreground" })
450
450
  ] }),
451
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardContent, { children: invoices.length === 0 ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2", children: [
451
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardContent, { children: invoices.length === 0 ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2", children: [
452
452
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-xl font-bold text-muted-foreground", children: "No invoices yet" }),
453
453
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-xs text-muted-foreground", children: "Invoices will appear after your first billing cycle" })
454
454
  ] }) : latestInvoice ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2", children: [
455
455
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center gap-2", children: [
456
456
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-xl font-bold", children: formatAmount(latestInvoice.total, latestInvoice.currency) }),
457
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Badge, { variant: getStatusBadgeVariant2(latestInvoice.status), children: latestInvoice.status })
457
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Badge, { variant: getStatusBadgeVariant2(latestInvoice.status), children: latestInvoice.status })
458
458
  ] }),
459
459
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-sm text-muted-foreground", children: latestInvoice.stripeInvoiceNumber || `Invoice from ${formatDate2(latestInvoice.periodStart)}` }),
460
460
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center gap-4 text-xs text-muted-foreground", children: [
@@ -494,24 +494,24 @@ function BillingUsageSummaryCard({
494
494
  onViewDetailsClick
495
495
  }) {
496
496
  if (loading) {
497
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.Card, { children: [
498
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
499
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardTitle, { children: "Usage This Month" }),
497
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.Card, { children: [
498
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
499
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardTitle, { children: "Usage This Month" }),
500
500
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.Activity, { className: "h-4 w-4 text-muted-foreground" })
501
501
  ] }),
502
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.CardContent, { children: [
503
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Skeleton, { className: "h-6 w-24 mb-2" }),
504
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Skeleton, { className: "h-4 w-32" })
502
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.CardContent, { children: [
503
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Skeleton, { className: "h-6 w-24 mb-2" }),
504
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Skeleton, { className: "h-4 w-32" })
505
505
  ] })
506
506
  ] });
507
507
  }
508
508
  if (error) {
509
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.Card, { children: [
510
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
511
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardTitle, { children: "Usage This Month" }),
509
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.Card, { children: [
510
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
511
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardTitle, { children: "Usage This Month" }),
512
512
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.Activity, { className: "h-4 w-4 text-muted-foreground" })
513
513
  ] }),
514
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardContent, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-destructive text-xs/relaxed", children: error }) })
514
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardContent, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-destructive text-xs/relaxed", children: error }) })
515
515
  ] });
516
516
  }
517
517
  const totalUsage = Object.values(summaries).reduce((acc, summary) => {
@@ -519,12 +519,12 @@ function BillingUsageSummaryCard({
519
519
  }, 0);
520
520
  const primaryMeter = meters.find((m) => _optionalChain([summaries, 'access', _17 => _17[m.id], 'optionalAccess', _18 => _18.aggregatedValue]));
521
521
  const primarySummary = primaryMeter ? summaries[primaryMeter.id] : null;
522
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.Card, { className: "cursor-pointer hover:bg-accent/50 transition-colors", onClick: onViewDetailsClick, children: [
523
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
524
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardTitle, { children: "Usage This Month" }),
522
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.Card, { className: "cursor-pointer hover:bg-accent/50 transition-colors", onClick: onViewDetailsClick, children: [
523
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
524
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardTitle, { children: "Usage This Month" }),
525
525
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.Activity, { className: "h-4 w-4 text-muted-foreground" })
526
526
  ] }),
527
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardContent, { children: meters.length === 0 ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2", children: [
527
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardContent, { children: meters.length === 0 ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2", children: [
528
528
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-xl font-bold text-muted-foreground", children: "No meters" }),
529
529
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-xs text-muted-foreground", children: "No usage meters are configured" })
530
530
  ] }) : /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2", children: [
@@ -576,7 +576,7 @@ function PaymentMethodForm({ onSuccess, onCancel, isLoading = false }) {
576
576
  const fetchSetupIntent = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
577
577
  setLoading(true);
578
578
  try {
579
- const intent = await _chunkIV4DTYXNjs.StripeCustomerService.createSetupIntent();
579
+ const intent = await _chunkU7QVISQSjs.StripeCustomerService.createSetupIntent();
580
580
  setSetupIntent(intent);
581
581
  } catch (err) {
582
582
  console.error("[PaymentMethodForm] Failed to create setup intent:", err);
@@ -614,7 +614,7 @@ function PaymentMethodForm({ onSuccess, onCancel, isLoading = false }) {
614
614
  return;
615
615
  }
616
616
  if (setAsDefault && _optionalChain([confirmedSetupIntent, 'optionalAccess', _19 => _19.payment_method])) {
617
- await _chunkIV4DTYXNjs.StripeCustomerService.setDefaultPaymentMethod({
617
+ await _chunkU7QVISQSjs.StripeCustomerService.setDefaultPaymentMethod({
618
618
  paymentMethodId: typeof confirmedSetupIntent.payment_method === "string" ? confirmedSetupIntent.payment_method : confirmedSetupIntent.payment_method.id
619
619
  });
620
620
  }
@@ -630,7 +630,7 @@ function PaymentMethodForm({ onSuccess, onCancel, isLoading = false }) {
630
630
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "flex items-center justify-center py-8", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-muted-foreground", children: "Loading payment form..." }) });
631
631
  }
632
632
  if (!setupIntent && error) {
633
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Alert, { variant: "destructive", className: "bg-red-50 border-red-200", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.AlertDescription, { children: error }) });
633
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Alert, { variant: "destructive", className: "bg-red-50 border-red-200", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.AlertDescription, { children: error }) });
634
634
  }
635
635
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "form", { onSubmit: handleSubmit, className: "flex flex-col gap-y-4", children: [
636
636
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rounded-md border border-gray-300 p-3", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
@@ -653,13 +653,13 @@ function PaymentMethodForm({ onSuccess, onCancel, isLoading = false }) {
653
653
  }
654
654
  ) }),
655
655
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center gap-x-2", children: [
656
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Checkbox, { id: "setAsDefault", checked: setAsDefault, onCheckedChange: (checked) => setSetAsDefault(!!checked) }),
657
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Label, { htmlFor: "setAsDefault", className: "cursor-pointer font-normal", children: "Set as default payment method" })
656
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Checkbox, { id: "setAsDefault", checked: setAsDefault, onCheckedChange: (checked) => setSetAsDefault(!!checked) }),
657
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Label, { htmlFor: "setAsDefault", className: "cursor-pointer font-normal", children: "Set as default payment method" })
658
658
  ] }),
659
- error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Alert, { variant: "destructive", className: "bg-red-50 border-red-200", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.AlertDescription, { children: error }) }),
659
+ error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Alert, { variant: "destructive", className: "bg-red-50 border-red-200", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.AlertDescription, { children: error }) }),
660
660
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex justify-end gap-x-2", children: [
661
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Button, { type: "button", variant: "outline", onClick: onCancel, disabled: isSubmitting || isLoading, children: "Cancel" }),
662
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Button, { type: "submit", disabled: !stripe || isSubmitting || isLoading, children: isSubmitting ? "Processing..." : "Add Card" })
661
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Button, { type: "button", variant: "outline", onClick: onCancel, disabled: isSubmitting || isLoading, children: "Cancel" }),
662
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Button, { type: "submit", disabled: !stripe || isSubmitting || isLoading, children: isSubmitting ? "Processing..." : "Add Card" })
663
663
  ] })
664
664
  ] });
665
665
  }
@@ -675,10 +675,10 @@ function PaymentMethodEditor({ open, onOpenChange, onSuccess }) {
675
675
  const handleCancel = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, () => {
676
676
  onOpenChange(false);
677
677
  }, "handleCancel");
678
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Dialog, { open, onOpenChange, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.DialogContent, { className: "max-w-md", children: [
679
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.DialogHeader, { children: [
680
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.DialogTitle, { children: "Add Payment Method" }),
681
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.DialogDescription, { children: "Add a new payment method to your account. Your card information is securely processed by Stripe." })
678
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Dialog, { open, onOpenChange, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.DialogContent, { className: "max-w-md", children: [
679
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.DialogHeader, { children: [
680
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.DialogTitle, { children: "Add Payment Method" }),
681
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.DialogDescription, { children: "Add a new payment method to your account. Your card information is securely processed by Stripe." })
682
682
  ] }),
683
683
  open && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, PaymentMethodForm, { onSuccess: handleSuccess, onCancel: handleCancel })
684
684
  ] }) });
@@ -702,7 +702,7 @@ function PaymentMethodCard({ paymentMethod, onUpdate }) {
702
702
  _react.useEffect.call(void 0, () => {
703
703
  const loadCustomer = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
704
704
  try {
705
- const fetchedCustomer = await _chunkIV4DTYXNjs.StripeCustomerService.getCustomer();
705
+ const fetchedCustomer = await _chunkU7QVISQSjs.StripeCustomerService.getCustomer();
706
706
  setCustomer(fetchedCustomer);
707
707
  } catch (error) {
708
708
  console.error("[PaymentMethodCard] Failed to load customer:", error);
@@ -719,7 +719,7 @@ function PaymentMethodCard({ paymentMethod, onUpdate }) {
719
719
  const handleSetDefault = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
720
720
  setLoading(true);
721
721
  try {
722
- await _chunkIV4DTYXNjs.StripeCustomerService.setDefaultPaymentMethod({ paymentMethodId: paymentMethod.id });
722
+ await _chunkU7QVISQSjs.StripeCustomerService.setDefaultPaymentMethod({ paymentMethodId: paymentMethod.id });
723
723
  onUpdate();
724
724
  } catch (error) {
725
725
  console.error("[PaymentMethodCard] Failed to set as default:", error);
@@ -730,7 +730,7 @@ function PaymentMethodCard({ paymentMethod, onUpdate }) {
730
730
  const handleRemove = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
731
731
  setLoading(true);
732
732
  try {
733
- await _chunkIV4DTYXNjs.StripeCustomerService.removePaymentMethod({ paymentMethodId: paymentMethod.id });
733
+ await _chunkU7QVISQSjs.StripeCustomerService.removePaymentMethod({ paymentMethodId: paymentMethod.id });
734
734
  setShowRemoveDialog(false);
735
735
  onUpdate();
736
736
  } catch (error) {
@@ -739,16 +739,16 @@ function PaymentMethodCard({ paymentMethod, onUpdate }) {
739
739
  }
740
740
  }, "handleRemove");
741
741
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
742
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.Card, { className: "relative", children: [
743
- isDefault && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Badge, { variant: "softGreen", className: "absolute end-2 top-2", children: "Default" }),
744
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.CardHeader, { className: "flex flex-row items-center justify-between pb-2", children: [
742
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.Card, { className: "relative", children: [
743
+ isDefault && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Badge, { variant: "softGreen", className: "absolute end-2 top-2", children: "Default" }),
744
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.CardHeader, { className: "flex flex-row items-center justify-between pb-2", children: [
745
745
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center gap-x-2", children: [
746
746
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-2xl", children: brandIcon }),
747
747
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-sm font-medium capitalize", children: brand })
748
748
  ] }),
749
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.DropdownMenu, { children: [
750
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.DropdownMenuTrigger, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
751
- _chunk3YJF7QY4js.Button,
749
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.DropdownMenu, { children: [
750
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.DropdownMenuTrigger, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
751
+ _chunk2XCUAHQTjs.Button,
752
752
  {
753
753
  render: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", {}),
754
754
  nativeButton: false,
@@ -759,10 +759,10 @@ function PaymentMethodCard({ paymentMethod, onUpdate }) {
759
759
  children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.MoreVertical, { className: "h-4 w-4" })
760
760
  }
761
761
  ) }),
762
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.DropdownMenuContent, { align: "end", children: [
763
- !isDefault && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.DropdownMenuItem, { onClick: handleSetDefault, disabled: loading, children: "Set as Default" }),
762
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.DropdownMenuContent, { align: "end", children: [
763
+ !isDefault && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.DropdownMenuItem, { onClick: handleSetDefault, disabled: loading, children: "Set as Default" }),
764
764
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
765
- _chunk3YJF7QY4js.DropdownMenuItem,
765
+ _chunk2XCUAHQTjs.DropdownMenuItem,
766
766
  {
767
767
  onClick: () => setShowRemoveDialog(true),
768
768
  disabled: loading,
@@ -773,7 +773,7 @@ function PaymentMethodCard({ paymentMethod, onUpdate }) {
773
773
  ] })
774
774
  ] })
775
775
  ] }),
776
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardContent, { children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex flex-col gap-y-1", children: [
776
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardContent, { children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex flex-col gap-y-1", children: [
777
777
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "p", { className: "text-lg font-semibold", children: [
778
778
  "\u2022\u2022\u2022\u2022 ",
779
779
  last4
@@ -786,17 +786,17 @@ function PaymentMethodCard({ paymentMethod, onUpdate }) {
786
786
  ] })
787
787
  ] }) })
788
788
  ] }),
789
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.AlertDialog, { open: showRemoveDialog, onOpenChange: setShowRemoveDialog, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.AlertDialogContent, { children: [
790
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.AlertDialogHeader, { children: [
791
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.AlertDialogTitle, { children: "Remove Payment Method" }),
792
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.AlertDialogDescription, { children: [
789
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.AlertDialog, { open: showRemoveDialog, onOpenChange: setShowRemoveDialog, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.AlertDialogContent, { children: [
790
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.AlertDialogHeader, { children: [
791
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.AlertDialogTitle, { children: "Remove Payment Method" }),
792
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.AlertDialogDescription, { children: [
793
793
  "Are you sure you want to remove this payment method? This action cannot be undone.",
794
794
  isDefault && " This is your default payment method."
795
795
  ] })
796
796
  ] }),
797
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.AlertDialogFooter, { children: [
798
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.AlertDialogCancel, { disabled: loading, children: "Cancel" }),
799
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.AlertDialogAction, { onClick: handleRemove, disabled: loading, className: "bg-red-600 hover:bg-red-700", children: loading ? "Removing..." : "Remove" })
797
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.AlertDialogFooter, { children: [
798
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.AlertDialogCancel, { disabled: loading, children: "Cancel" }),
799
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.AlertDialogAction, { onClick: handleRemove, disabled: loading, className: "bg-red-600 hover:bg-red-700", children: loading ? "Removing..." : "Remove" })
800
800
  ] })
801
801
  ] }) })
802
802
  ] });
@@ -819,7 +819,7 @@ function PaymentMethodsContainer() {
819
819
  const loadPaymentMethods = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
820
820
  setLoading(true);
821
821
  try {
822
- const fetchedPaymentMethods = await _chunkIV4DTYXNjs.StripeCustomerService.listPaymentMethods();
822
+ const fetchedPaymentMethods = await _chunkU7QVISQSjs.StripeCustomerService.listPaymentMethods();
823
823
  setPaymentMethods(fetchedPaymentMethods);
824
824
  } catch (error) {
825
825
  console.error("[PaymentMethodsContainer] Failed to load payment methods:", error);
@@ -839,14 +839,14 @@ function PaymentMethodsContainer() {
839
839
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.CreditCard, { className: "h-8 w-8" }),
840
840
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h1", { className: "text-primary text-3xl font-semibold", children: "Payment Methods" })
841
841
  ] }),
842
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Button, { onClick: () => setShowAddPaymentMethod(true), children: "Add Payment Method" })
842
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Button, { onClick: () => setShowAddPaymentMethod(true), children: "Add Payment Method" })
843
843
  ] }),
844
844
  paymentMethods.length === 0 && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex flex-col items-center justify-center gap-y-4 rounded-lg border-2 border-dashed border-gray-300 bg-muted/50 p-12", children: [
845
845
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.CreditCard, { className: "h-16 w-16 text-muted-foreground" }),
846
846
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "text-center", children: [
847
847
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h3", { className: "mb-2 text-sm font-medium", children: "No payment methods" }),
848
848
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "mb-4 text-muted-foreground", children: "Add a payment method to enable subscriptions and secure checkout." }),
849
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Button, { onClick: () => setShowAddPaymentMethod(true), children: "Add Your First Card" })
849
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Button, { onClick: () => setShowAddPaymentMethod(true), children: "Add Your First Card" })
850
850
  ] })
851
851
  ] }),
852
852
  paymentMethods.length > 0 && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, PaymentMethodsList, { paymentMethods, onUpdate: loadPaymentMethods }),
@@ -914,7 +914,7 @@ var statusConfig = {
914
914
  };
915
915
  function InvoiceStatusBadge({ status }) {
916
916
  const config = statusConfig[status] || statusConfig["draft" /* DRAFT */];
917
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Badge, { variant: config.variant, children: config.label });
917
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Badge, { variant: config.variant, children: config.label });
918
918
  }
919
919
  _chunk7QVYU63Ejs.__name.call(void 0, InvoiceStatusBadge, "InvoiceStatusBadge");
920
920
 
@@ -945,13 +945,13 @@ function InvoiceDetails({
945
945
  return invoice.stripeInvoiceId.slice(-8);
946
946
  }, "getInvoiceNumber");
947
947
  const productName = _optionalChain([invoice, 'access', _29 => _29.subscription, 'optionalAccess', _30 => _30.price, 'optionalAccess', _31 => _31.product, 'optionalAccess', _32 => _32.name]) || "Subscription";
948
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Dialog, { open, onOpenChange, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.DialogContent, { className: "max-w-2xl", children: [
949
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.DialogHeader, { children: [
950
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.DialogTitle, { children: [
948
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Dialog, { open, onOpenChange, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.DialogContent, { className: "max-w-2xl", children: [
949
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.DialogHeader, { children: [
950
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.DialogTitle, { children: [
951
951
  "Invoice ",
952
952
  getInvoiceNumber()
953
953
  ] }),
954
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.DialogDescription, { children: formatDate3(invoice.periodStart) })
954
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.DialogDescription, { children: formatDate3(invoice.periodStart) })
955
955
  ] }),
956
956
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-6", children: [
957
957
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center gap-x-3", children: [
@@ -989,42 +989,42 @@ function InvoiceDetails({
989
989
  ] }) }),
990
990
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "tbody", { children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "tr", { className: "border-t", children: [
991
991
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "td", { className: "p-3", children: productName }),
992
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "td", { className: "p-3 text-end", children: _chunk3YJF7QY4js.formatCurrency.call(void 0, invoice.subtotal, invoice.currency) })
992
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "td", { className: "p-3 text-end", children: _chunk2XCUAHQTjs.formatCurrency.call(void 0, invoice.subtotal, invoice.currency) })
993
993
  ] }) })
994
994
  ] }) })
995
995
  ] }),
996
996
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2 border-t pt-4", children: [
997
997
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex justify-between", children: [
998
998
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-muted-foreground text-xs", children: "Subtotal:" }),
999
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-sm", children: _chunk3YJF7QY4js.formatCurrency.call(void 0, invoice.subtotal, invoice.currency) })
999
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-sm", children: _chunk2XCUAHQTjs.formatCurrency.call(void 0, invoice.subtotal, invoice.currency) })
1000
1000
  ] }),
1001
1001
  invoice.tax !== void 0 && invoice.tax > 0 && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex justify-between", children: [
1002
1002
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-muted-foreground text-xs", children: "Tax:" }),
1003
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-sm", children: _chunk3YJF7QY4js.formatCurrency.call(void 0, invoice.tax, invoice.currency) })
1003
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-sm", children: _chunk2XCUAHQTjs.formatCurrency.call(void 0, invoice.tax, invoice.currency) })
1004
1004
  ] }),
1005
1005
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex justify-between text-lg font-semibold border-t pt-2", children: [
1006
1006
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: "Total:" }),
1007
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: _chunk3YJF7QY4js.formatCurrency.call(void 0, invoice.total, invoice.currency) })
1007
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: _chunk2XCUAHQTjs.formatCurrency.call(void 0, invoice.total, invoice.currency) })
1008
1008
  ] }),
1009
1009
  invoice.amountPaid > 0 && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex justify-between", children: [
1010
1010
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-muted-foreground text-xs", children: "Amount Paid:" }),
1011
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-sm text-success", children: _chunk3YJF7QY4js.formatCurrency.call(void 0, invoice.amountPaid, invoice.currency) })
1011
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-sm text-success", children: _chunk2XCUAHQTjs.formatCurrency.call(void 0, invoice.amountPaid, invoice.currency) })
1012
1012
  ] }),
1013
1013
  invoice.amountRemaining > 0 && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex justify-between", children: [
1014
1014
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-muted-foreground text-xs", children: "Amount Due:" }),
1015
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-sm text-destructive", children: _chunk3YJF7QY4js.formatCurrency.call(void 0, invoice.amountRemaining, invoice.currency) })
1015
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-sm text-destructive", children: _chunk2XCUAHQTjs.formatCurrency.call(void 0, invoice.amountRemaining, invoice.currency) })
1016
1016
  ] })
1017
1017
  ] }),
1018
1018
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex flex-wrap gap-2 pt-4 border-t", children: [
1019
- invoice.stripePdfUrl && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.Button, { variant: "outline", onClick: handleDownloadPDF, children: [
1019
+ invoice.stripePdfUrl && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.Button, { variant: "outline", onClick: handleDownloadPDF, children: [
1020
1020
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.Download, { className: "me-2 h-4 w-4" }),
1021
1021
  "Download PDF"
1022
1022
  ] }),
1023
- invoice.status === "open" /* OPEN */ && invoice.attempted && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.Button, { variant: "default", onClick: handleRetryPayment, children: [
1023
+ invoice.status === "open" /* OPEN */ && invoice.attempted && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.Button, { variant: "default", onClick: handleRetryPayment, children: [
1024
1024
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.RefreshCw, { className: "me-2 h-4 w-4" }),
1025
1025
  "Retry Payment"
1026
1026
  ] }),
1027
- invoice.stripeHostedInvoiceUrl && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.Button, { variant: "outline", onClick: handleViewInStripe, children: [
1027
+ invoice.stripeHostedInvoiceUrl && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.Button, { variant: "outline", onClick: handleViewInStripe, children: [
1028
1028
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.ExternalLink, { className: "me-2 h-4 w-4" }),
1029
1029
  "View in Stripe"
1030
1030
  ] })
@@ -1048,30 +1048,30 @@ function InvoicesList({ invoices, onInvoicesChange }) {
1048
1048
  return invoice.stripeInvoiceId.slice(-8);
1049
1049
  }, "getInvoiceNumber");
1050
1050
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
1051
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "border rounded-lg overflow-clip", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.Table, { children: [
1052
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableHeader, { className: "bg-muted", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.TableRow, { children: [
1053
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableHead, { children: "Invoice #" }),
1054
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableHead, { children: "Date" }),
1055
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableHead, { children: "Status" }),
1056
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableHead, { className: "text-end", children: "Amount" }),
1057
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableHead, { children: "Period" })
1051
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "border rounded-lg overflow-clip", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.Table, { children: [
1052
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableHeader, { className: "bg-muted", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.TableRow, { children: [
1053
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableHead, { children: "Invoice #" }),
1054
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableHead, { children: "Date" }),
1055
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableHead, { children: "Status" }),
1056
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableHead, { className: "text-end", children: "Amount" }),
1057
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableHead, { children: "Period" })
1058
1058
  ] }) }),
1059
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableBody, { children: invoices.map((invoice) => {
1059
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableBody, { children: invoices.map((invoice) => {
1060
1060
  const invoiceNumber = getInvoiceNumber(invoice);
1061
1061
  const date = formatDate3(invoice.periodStart);
1062
- const amount = _chunk3YJF7QY4js.formatCurrency.call(void 0, invoice.total, invoice.currency);
1062
+ const amount = _chunk2XCUAHQTjs.formatCurrency.call(void 0, invoice.total, invoice.currency);
1063
1063
  const period = `${formatDate3(invoice.periodStart)} - ${formatDate3(invoice.periodEnd)}`;
1064
1064
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
1065
- _chunk3YJF7QY4js.TableRow,
1065
+ _chunk2XCUAHQTjs.TableRow,
1066
1066
  {
1067
1067
  onClick: () => handleRowClick(invoice),
1068
1068
  className: "cursor-pointer hover:bg-muted/50",
1069
1069
  children: [
1070
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableCell, { className: "font-medium", children: invoiceNumber }),
1071
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableCell, { className: "text-muted-foreground text-xs", children: date }),
1072
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableCell, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, InvoiceStatusBadge, { status: invoice.status }) }),
1073
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableCell, { className: "text-end font-medium", children: amount }),
1074
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableCell, { className: "text-muted-foreground text-xs", children: period })
1070
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableCell, { className: "font-medium", children: invoiceNumber }),
1071
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableCell, { className: "text-muted-foreground text-xs", children: date }),
1072
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableCell, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, InvoiceStatusBadge, { status: invoice.status }) }),
1073
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableCell, { className: "text-end font-medium", children: amount }),
1074
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableCell, { className: "text-muted-foreground text-xs", children: period })
1075
1075
  ]
1076
1076
  },
1077
1077
  invoice.id
@@ -1104,7 +1104,7 @@ function InvoicesContainer() {
1104
1104
  setLoading(true);
1105
1105
  try {
1106
1106
  const params = statusFilter !== "all" ? { status: statusFilter } : void 0;
1107
- const data = await _chunkIV4DTYXNjs.StripeInvoiceService.listInvoices(params);
1107
+ const data = await _chunkU7QVISQSjs.StripeInvoiceService.listInvoices(params);
1108
1108
  setInvoices(data);
1109
1109
  } catch (error) {
1110
1110
  console.error("[InvoicesContainer] Failed to load invoices:", error);
@@ -1120,12 +1120,12 @@ function InvoicesContainer() {
1120
1120
  setStatusFilter(value);
1121
1121
  }, "handleFilterChange");
1122
1122
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-4", children: [
1123
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Tabs, { value: statusFilter, onValueChange: handleFilterChange, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.TabsList, { children: [
1124
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TabsTrigger, { value: "all", children: "All" }),
1125
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TabsTrigger, { value: "paid" /* PAID */, children: "Paid" }),
1126
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TabsTrigger, { value: "open" /* OPEN */, children: "Open" }),
1127
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TabsTrigger, { value: "void" /* VOID */, children: "Void" }),
1128
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TabsTrigger, { value: "uncollectible" /* UNCOLLECTIBLE */, children: "Uncollectible" })
1123
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Tabs, { value: statusFilter, onValueChange: handleFilterChange, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.TabsList, { children: [
1124
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TabsTrigger, { value: "all", children: "All" }),
1125
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TabsTrigger, { value: "paid" /* PAID */, children: "Paid" }),
1126
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TabsTrigger, { value: "open" /* OPEN */, children: "Open" }),
1127
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TabsTrigger, { value: "void" /* VOID */, children: "Void" }),
1128
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TabsTrigger, { value: "uncollectible" /* UNCOLLECTIBLE */, children: "Uncollectible" })
1129
1129
  ] }) }),
1130
1130
  loading && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "text-center py-8 text-muted-foreground", children: "Loading invoices..." }),
1131
1131
  !loading && invoices.length === 0 && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "border border-dashed border-gray-300 rounded-lg p-8 text-center", children: [
@@ -1172,7 +1172,7 @@ function CancelSubscriptionDialog({
1172
1172
  const onSubmit = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async (_values) => {
1173
1173
  setIsSubmitting(true);
1174
1174
  try {
1175
- await _chunkIV4DTYXNjs.StripeSubscriptionService.cancelSubscription({
1175
+ await _chunkU7QVISQSjs.StripeSubscriptionService.cancelSubscription({
1176
1176
  id: subscription.id,
1177
1177
  cancelImmediately: false
1178
1178
  });
@@ -1185,19 +1185,19 @@ function CancelSubscriptionDialog({
1185
1185
  }
1186
1186
  }, "onSubmit");
1187
1187
  const periodEndDate = formatDate3(subscription.currentPeriodEnd);
1188
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Dialog, { open, onOpenChange, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.DialogContent, { className: "max-w-md", children: [
1189
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.DialogHeader, { children: [
1190
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.DialogTitle, { children: "Cancel Subscription" }),
1191
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.DialogDescription, { children: "Are you sure you want to cancel this subscription? This action cannot be undone." })
1188
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Dialog, { open, onOpenChange, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.DialogContent, { className: "max-w-md", children: [
1189
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.DialogHeader, { children: [
1190
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.DialogTitle, { children: "Cancel Subscription" }),
1191
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.DialogDescription, { children: "Are you sure you want to cancel this subscription? This action cannot be undone." })
1192
1192
  ] }),
1193
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Form, { ...form, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "form", { onSubmit: form.handleSubmit(onSubmit), className: "flex flex-col gap-y-4", children: [
1193
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Form, { ...form, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "form", { onSubmit: form.handleSubmit(onSubmit), className: "flex flex-col gap-y-4", children: [
1194
1194
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "bg-primary/10 border-primary/30 text-foreground rounded-lg border p-3 text-sm", children: [
1195
1195
  "Your subscription will remain active until ",
1196
1196
  periodEndDate,
1197
1197
  ". You can continue using the service until then."
1198
1198
  ] }),
1199
1199
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1200
- _chunk3YJF7QY4js.FormTextarea,
1200
+ _chunk2XCUAHQTjs.FormTextarea,
1201
1201
  {
1202
1202
  form,
1203
1203
  id: "reason",
@@ -1207,8 +1207,8 @@ function CancelSubscriptionDialog({
1207
1207
  }
1208
1208
  ),
1209
1209
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex gap-x-2 justify-end pt-2", children: [
1210
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Button, { type: "button", variant: "outline", onClick: () => onOpenChange(false), disabled: isSubmitting, children: "Keep Subscription" }),
1211
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Button, { type: "submit", variant: "destructive", disabled: isSubmitting, children: isSubmitting ? "Canceling..." : "Confirm Cancellation" })
1210
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Button, { type: "button", variant: "outline", onClick: () => onOpenChange(false), disabled: isSubmitting, children: "Keep Subscription" }),
1211
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Button, { type: "submit", variant: "destructive", disabled: isSubmitting, children: isSubmitting ? "Canceling..." : "Confirm Cancellation" })
1212
1212
  ] })
1213
1213
  ] }) })
1214
1214
  ] }) });
@@ -1257,7 +1257,7 @@ var cancelingConfig = {
1257
1257
  };
1258
1258
  function SubscriptionStatusBadge({ status, cancelAtPeriodEnd }) {
1259
1259
  const config = cancelAtPeriodEnd ? cancelingConfig : statusConfig2[status] || statusConfig2["canceled" /* CANCELED */];
1260
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Badge, { variant: config.variant, children: config.label });
1260
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Badge, { variant: config.variant, children: config.label });
1261
1261
  }
1262
1262
  _chunk7QVYU63Ejs.__name.call(void 0, SubscriptionStatusBadge, "SubscriptionStatusBadge");
1263
1263
 
@@ -1284,7 +1284,7 @@ function formatPlanName2(price) {
1284
1284
  _chunk7QVYU63Ejs.__name.call(void 0, formatPlanName2, "formatPlanName");
1285
1285
  function formatBillingAmount(price) {
1286
1286
  if (!_optionalChain([price, 'optionalAccess', _37 => _37.unitAmount])) return "N/A";
1287
- return _chunk3YJF7QY4js.formatCurrency.call(void 0, price.unitAmount, price.currency);
1287
+ return _chunk2XCUAHQTjs.formatCurrency.call(void 0, price.unitAmount, price.currency);
1288
1288
  }
1289
1289
  _chunk7QVYU63Ejs.__name.call(void 0, formatBillingAmount, "formatBillingAmount");
1290
1290
  function SubscriptionDetails({
@@ -1299,7 +1299,7 @@ function SubscriptionDetails({
1299
1299
  const handlePause = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
1300
1300
  setIsProcessing(true);
1301
1301
  try {
1302
- await _chunkIV4DTYXNjs.StripeSubscriptionService.pauseSubscription({ subscriptionId: subscription.id });
1302
+ await _chunkU7QVISQSjs.StripeSubscriptionService.pauseSubscription({ subscriptionId: subscription.id });
1303
1303
  onSubscriptionChange();
1304
1304
  } catch (error) {
1305
1305
  console.error("[SubscriptionDetails] Failed to pause subscription:", error);
@@ -1310,7 +1310,7 @@ function SubscriptionDetails({
1310
1310
  const handleResume = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
1311
1311
  setIsProcessing(true);
1312
1312
  try {
1313
- await _chunkIV4DTYXNjs.StripeSubscriptionService.resumeSubscription({ subscriptionId: subscription.id });
1313
+ await _chunkU7QVISQSjs.StripeSubscriptionService.resumeSubscription({ subscriptionId: subscription.id });
1314
1314
  onSubscriptionChange();
1315
1315
  } catch (error) {
1316
1316
  console.error("[SubscriptionDetails] Failed to resume subscription:", error);
@@ -1320,7 +1320,7 @@ function SubscriptionDetails({
1320
1320
  }, "handleResume");
1321
1321
  const handleManageViaPortal = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
1322
1322
  try {
1323
- const { url } = await _chunkIV4DTYXNjs.StripeCustomerService.createPortalSession();
1323
+ const { url } = await _chunkU7QVISQSjs.StripeCustomerService.createPortalSession();
1324
1324
  window.open(url, "_blank");
1325
1325
  } catch (error) {
1326
1326
  console.error("[SubscriptionDetails] Failed to create portal session:", error);
@@ -1330,10 +1330,10 @@ function SubscriptionDetails({
1330
1330
  const canResume = subscription.status === "paused" /* PAUSED */;
1331
1331
  const canCancel = subscription.status === "active" /* ACTIVE */ || subscription.status === "trialing" /* TRIALING */ || subscription.status === "paused" /* PAUSED */;
1332
1332
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
1333
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Dialog, { open, onOpenChange, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.DialogContent, { className: "max-w-2xl", children: [
1334
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.DialogHeader, { children: [
1335
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.DialogTitle, { children: "Subscription Details" }),
1336
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.DialogDescription, { children: "View and manage your subscription" })
1333
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Dialog, { open, onOpenChange, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.DialogContent, { className: "max-w-2xl", children: [
1334
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.DialogHeader, { children: [
1335
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.DialogTitle, { children: "Subscription Details" }),
1336
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.DialogDescription, { children: "View and manage your subscription" })
1337
1337
  ] }),
1338
1338
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-6", children: [
1339
1339
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center gap-x-3", children: [
@@ -1375,11 +1375,11 @@ function SubscriptionDetails({
1375
1375
  "."
1376
1376
  ] }) }),
1377
1377
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex flex-wrap gap-2 pt-4 border-t", children: [
1378
- onChangePlan && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Button, { variant: "default", onClick: () => onChangePlan(subscription), children: "Change Plan" }),
1379
- canPause && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Button, { variant: "outline", onClick: handlePause, disabled: isProcessing, children: isProcessing ? "Pausing..." : "Pause" }),
1380
- canResume && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Button, { variant: "outline", onClick: handleResume, disabled: isProcessing, children: isProcessing ? "Resuming..." : "Resume" }),
1381
- canCancel && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Button, { variant: "destructive", onClick: () => setShowCancel(true), children: "Cancel" }),
1382
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Button, { variant: "outline", onClick: handleManageViaPortal, children: "Manage via Portal" })
1378
+ onChangePlan && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Button, { variant: "default", onClick: () => onChangePlan(subscription), children: "Change Plan" }),
1379
+ canPause && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Button, { variant: "outline", onClick: handlePause, disabled: isProcessing, children: isProcessing ? "Pausing..." : "Pause" }),
1380
+ canResume && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Button, { variant: "outline", onClick: handleResume, disabled: isProcessing, children: isProcessing ? "Resuming..." : "Resume" }),
1381
+ canCancel && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Button, { variant: "destructive", onClick: () => setShowCancel(true), children: "Cancel" }),
1382
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Button, { variant: "outline", onClick: handleManageViaPortal, children: "Manage via Portal" })
1383
1383
  ] })
1384
1384
  ] })
1385
1385
  ] }) }),
@@ -1426,36 +1426,36 @@ function SubscriptionsList({ subscriptions, onSubscriptionsChange, onChangePlan
1426
1426
  setSelectedSub(subscription);
1427
1427
  }, "handleRowClick");
1428
1428
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
1429
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "border rounded-lg overflow-clip", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.Table, { children: [
1430
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableHeader, { className: "bg-muted", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.TableRow, { children: [
1431
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableHead, { children: "Status" }),
1432
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableHead, { children: "Plan" }),
1433
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableHead, { children: "Period" }),
1434
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableHead, { className: "text-end", children: "Amount" }),
1435
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableHead, { className: "text-end", children: "Actions" })
1429
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "border rounded-lg overflow-clip", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.Table, { children: [
1430
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableHeader, { className: "bg-muted", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.TableRow, { children: [
1431
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableHead, { children: "Status" }),
1432
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableHead, { children: "Plan" }),
1433
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableHead, { children: "Period" }),
1434
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableHead, { className: "text-end", children: "Amount" }),
1435
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableHead, { className: "text-end", children: "Actions" })
1436
1436
  ] }) }),
1437
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableBody, { children: subscriptions.map((subscription) => {
1437
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableBody, { children: subscriptions.map((subscription) => {
1438
1438
  const price = subscription.price;
1439
- const amount = _optionalChain([price, 'optionalAccess', _42 => _42.unitAmount]) ? _chunk3YJF7QY4js.formatCurrency.call(void 0, price.unitAmount, price.currency) : "0";
1439
+ const amount = _optionalChain([price, 'optionalAccess', _42 => _42.unitAmount]) ? _chunk2XCUAHQTjs.formatCurrency.call(void 0, price.unitAmount, price.currency) : "0";
1440
1440
  const period = `${formatDate3(subscription.currentPeriodStart)} - ${formatDate3(subscription.currentPeriodEnd)}`;
1441
1441
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
1442
- _chunk3YJF7QY4js.TableRow,
1442
+ _chunk2XCUAHQTjs.TableRow,
1443
1443
  {
1444
1444
  onClick: () => handleRowClick(subscription),
1445
1445
  className: "cursor-pointer hover:bg-muted/50",
1446
1446
  children: [
1447
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableCell, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1447
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableCell, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1448
1448
  SubscriptionStatusBadge,
1449
1449
  {
1450
1450
  status: subscription.status,
1451
1451
  cancelAtPeriodEnd: subscription.cancelAtPeriodEnd
1452
1452
  }
1453
1453
  ) }),
1454
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableCell, { className: "font-medium", children: formatPlanName3(price) }),
1455
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableCell, { className: "text-muted-foreground text-sm", children: period }),
1456
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableCell, { className: "text-end font-medium", children: amount }),
1457
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableCell, { className: "text-end", children: (subscription.status === "active" /* ACTIVE */ || subscription.status === "trialing" /* TRIALING */) && onChangePlan && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1458
- _chunk3YJF7QY4js.Button,
1454
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableCell, { className: "font-medium", children: formatPlanName3(price) }),
1455
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableCell, { className: "text-muted-foreground text-sm", children: period }),
1456
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableCell, { className: "text-end font-medium", children: amount }),
1457
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableCell, { className: "text-end", children: (subscription.status === "active" /* ACTIVE */ || subscription.status === "trialing" /* TRIALING */) && onChangePlan && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1458
+ _chunk2XCUAHQTjs.Button,
1459
1459
  {
1460
1460
  size: "sm",
1461
1461
  variant: "outline",
@@ -1500,7 +1500,7 @@ function SubscriptionsContainer({ onOpenWizard, hasActiveRecurringSubscription }
1500
1500
  const loadSubscriptions = _react.useCallback.call(void 0, async () => {
1501
1501
  setLoading(true);
1502
1502
  try {
1503
- const fetchedSubscriptions = await _chunkIV4DTYXNjs.StripeSubscriptionService.listSubscriptions();
1503
+ const fetchedSubscriptions = await _chunkU7QVISQSjs.StripeSubscriptionService.listSubscriptions();
1504
1504
  setSubscriptions(fetchedSubscriptions);
1505
1505
  } catch (error) {
1506
1506
  console.error("[SubscriptionsContainer] Failed to load subscriptions:", error);
@@ -1523,7 +1523,7 @@ function SubscriptionsContainer({ onOpenWizard, hasActiveRecurringSubscription }
1523
1523
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.CreditCard, { className: "h-8 w-8" }),
1524
1524
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h1", { className: "text-primary text-3xl font-semibold", children: "Subscriptions" })
1525
1525
  ] }),
1526
- subscriptions.length > 0 && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Button, { onClick: () => _optionalChain([onOpenWizard, 'optionalCall', _43 => _43()]), children: hasActiveRecurringSubscription ? "Purchase Add-ons" : "Subscribe to a Plan" })
1526
+ subscriptions.length > 0 && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Button, { onClick: () => _optionalChain([onOpenWizard, 'optionalCall', _43 => _43()]), children: hasActiveRecurringSubscription ? "Purchase Add-ons" : "Subscribe to a Plan" })
1527
1527
  ] }),
1528
1528
  criticalSubscriptions.map((subscription) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, BillingAlertBanner, { subscription }, subscription.id)),
1529
1529
  subscriptions.length === 0 && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex flex-col items-center justify-center py-12 space-y-4", children: [
@@ -1531,7 +1531,7 @@ function SubscriptionsContainer({ onOpenWizard, hasActiveRecurringSubscription }
1531
1531
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "text-center", children: [
1532
1532
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h3", { className: "text-sm font-medium mb-2", children: "No Active Subscriptions" }),
1533
1533
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-muted-foreground mb-6", children: "Choose a subscription plan to get started with our services." }),
1534
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Button, { onClick: () => _optionalChain([onOpenWizard, 'optionalCall', _44 => _44()]), children: "Subscribe to a Plan" })
1534
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Button, { onClick: () => _optionalChain([onOpenWizard, 'optionalCall', _44 => _44()]), children: "Subscribe to a Plan" })
1535
1535
  ] })
1536
1536
  ] }),
1537
1537
  subscriptions.length > 0 && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
@@ -1552,9 +1552,9 @@ function IntervalToggle({ value, onChange, hasMonthly, hasYearly }) {
1552
1552
  if (!hasMonthly || !hasYearly) {
1553
1553
  return null;
1554
1554
  }
1555
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Tabs, { value, onValueChange: (v) => onChange(v), children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.TabsList, { children: [
1556
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TabsTrigger, { value: "month", children: "Monthly" }),
1557
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TabsTrigger, { value: "year", children: "Yearly" })
1555
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Tabs, { value, onValueChange: (v) => onChange(v), children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.TabsList, { children: [
1556
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TabsTrigger, { value: "month", children: "Monthly" }),
1557
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TabsTrigger, { value: "year", children: "Yearly" })
1558
1558
  ] }) });
1559
1559
  }
1560
1560
  _chunk7QVYU63Ejs.__name.call(void 0, IntervalToggle, "IntervalToggle");
@@ -1572,8 +1572,8 @@ function PricingCard({
1572
1572
  }) {
1573
1573
  const description = price.description || price.nickname || "Standard";
1574
1574
  const features = price.features || [];
1575
- const formattedPrice = _chunk3YJF7QY4js.formatCurrency.call(void 0, price.unitAmount, price.currency);
1576
- const interval = _chunk3YJF7QY4js.formatInterval.call(void 0, price);
1575
+ const formattedPrice = _chunk2XCUAHQTjs.formatCurrency.call(void 0, price.unitAmount, price.currency);
1576
+ const interval = _chunk2XCUAHQTjs.formatInterval.call(void 0, price);
1577
1577
  const handleKeyDown = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (e) => {
1578
1578
  if ((e.key === "Enter" || e.key === " ") && !isDisabled && !isCurrentPlan) {
1579
1579
  e.preventDefault();
@@ -1586,7 +1586,7 @@ function PricingCard({
1586
1586
  }
1587
1587
  }, "handleClick");
1588
1588
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
1589
- _chunk3YJF7QY4js.Card,
1589
+ _chunk2XCUAHQTjs.Card,
1590
1590
  {
1591
1591
  role: "radio",
1592
1592
  "aria-checked": isSelected,
@@ -1594,7 +1594,7 @@ function PricingCard({
1594
1594
  tabIndex: isDisabled ? -1 : 0,
1595
1595
  onKeyDown: handleKeyDown,
1596
1596
  onClick: handleClick,
1597
- className: _chunkIV4DTYXNjs.cn.call(void 0,
1597
+ className: _chunkU7QVISQSjs.cn.call(void 0,
1598
1598
  "relative cursor-pointer transition-all duration-200 flex flex-col h-full",
1599
1599
  "focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2",
1600
1600
  isCurrentPlan && "bg-muted/30",
@@ -1604,9 +1604,9 @@ function PricingCard({
1604
1604
  isLoading && "pointer-events-none"
1605
1605
  ),
1606
1606
  children: [
1607
- isCurrentPlan && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Badge, { variant: "secondary", className: "absolute top-2 end-2", children: "Current" }),
1608
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardHeader, { className: "pb-2", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h3", { className: "text-sm font-medium", children: description }) }),
1609
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.CardContent, { className: "pb-4 grow", children: [
1607
+ isCurrentPlan && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Badge, { variant: "secondary", className: "absolute top-2 end-2", children: "Current" }),
1608
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardHeader, { className: "pb-2", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h3", { className: "text-sm font-medium", children: description }) }),
1609
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.CardContent, { className: "pb-4 grow", children: [
1610
1610
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "mb-4", children: [
1611
1611
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-3xl font-bold", children: formattedPrice }),
1612
1612
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-muted-foreground ms-1", children: interval })
@@ -1616,8 +1616,8 @@ function PricingCard({
1616
1616
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-sm text-muted-foreground", children: feature })
1617
1617
  ] }, index)) })
1618
1618
  ] }),
1619
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardFooter, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1620
- _chunk3YJF7QY4js.Button,
1619
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardFooter, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1620
+ _chunk2XCUAHQTjs.Button,
1621
1621
  {
1622
1622
  variant: isCurrentPlan ? "secondary" : isSelected ? "default" : "outline",
1623
1623
  className: "w-full",
@@ -1645,7 +1645,7 @@ function ProductPricingRow({
1645
1645
  return null;
1646
1646
  }
1647
1647
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-3", children: [
1648
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.SectionHeader, { children: product.name }),
1648
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.SectionHeader, { children: product.name }),
1649
1649
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1650
1650
  "div",
1651
1651
  {
@@ -1745,15 +1745,15 @@ function ProductPricingList({
1745
1745
  _chunk7QVYU63Ejs.__name.call(void 0, ProductPricingList, "ProductPricingList");
1746
1746
  function ProductPricingListSkeleton() {
1747
1747
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "space-y-6", children: [1, 2].map((rowIndex) => /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-3", children: [
1748
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Skeleton, { className: "h-6 w-32" }),
1748
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Skeleton, { className: "h-6 w-32" }),
1749
1749
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 gap-4", children: [1, 2, 3].map((cardIndex) => /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "p-4 rounded-lg border animate-pulse space-y-3", children: [
1750
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Skeleton, { className: "h-6 w-24" }),
1751
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Skeleton, { className: "h-8 w-32" }),
1750
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Skeleton, { className: "h-6 w-24" }),
1751
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Skeleton, { className: "h-8 w-32" }),
1752
1752
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2", children: [
1753
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Skeleton, { className: "h-4 w-full" }),
1754
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Skeleton, { className: "h-4 w-3/4" })
1753
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Skeleton, { className: "h-4 w-full" }),
1754
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Skeleton, { className: "h-4 w-3/4" })
1755
1755
  ] }),
1756
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Skeleton, { className: "h-10 w-full" })
1756
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Skeleton, { className: "h-10 w-full" })
1757
1757
  ] }, cardIndex)) })
1758
1758
  ] }, rowIndex)) });
1759
1759
  }
@@ -1767,18 +1767,18 @@ function ProrationPreview({ preview }) {
1767
1767
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2", children: [
1768
1768
  preview.lineItems.map((item, index) => /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex justify-between text-sm", children: [
1769
1769
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-muted-foreground", children: item.description }),
1770
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: `font-medium ${item.amount < 0 ? "text-success" : "text-foreground"}`, children: _chunk3YJF7QY4js.formatCurrency.call(void 0, item.amount, preview.currency) })
1770
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: `font-medium ${item.amount < 0 ? "text-success" : "text-foreground"}`, children: _chunk2XCUAHQTjs.formatCurrency.call(void 0, item.amount, preview.currency) })
1771
1771
  ] }, index)),
1772
1772
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "border-primary/30 mt-2 border-t pt-2", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex justify-between font-semibold", children: [
1773
1773
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-foreground", children: "Net Due Today" }),
1774
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-foreground", children: _chunk3YJF7QY4js.formatCurrency.call(void 0, preview.immediateCharge, preview.currency) })
1774
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-foreground", children: _chunk2XCUAHQTjs.formatCurrency.call(void 0, preview.immediateCharge, preview.currency) })
1775
1775
  ] }) }),
1776
1776
  preview.lineItems.length > 0 && preview.lineItems[0].period && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "text-muted-foreground mt-2 text-xs", children: [
1777
1777
  "Next invoice on ",
1778
1778
  formatDate3(preview.lineItems[0].period.end),
1779
1779
  " for",
1780
1780
  " ",
1781
- _chunk3YJF7QY4js.formatCurrency.call(void 0, preview.amountDue, preview.currency)
1781
+ _chunk2XCUAHQTjs.formatCurrency.call(void 0, preview.amountDue, preview.currency)
1782
1782
  ] })
1783
1783
  ] })
1784
1784
  ] });
@@ -1800,16 +1800,16 @@ function SubscriptionConfirmation({ price, isLoading, onConfirm, onCancel }) {
1800
1800
  productDescription && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "text-sm text-muted-foreground", children: productDescription })
1801
1801
  ] }),
1802
1802
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "text-lg font-semibold", children: [
1803
- _chunk3YJF7QY4js.formatCurrency.call(void 0, price.unitAmount, price.currency),
1804
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-sm font-normal text-muted-foreground", children: _chunk3YJF7QY4js.formatInterval.call(void 0, price) })
1803
+ _chunk2XCUAHQTjs.formatCurrency.call(void 0, price.unitAmount, price.currency),
1804
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-sm font-normal text-muted-foreground", children: _chunk2XCUAHQTjs.formatInterval.call(void 0, price) })
1805
1805
  ] }),
1806
1806
  features.length > 0 && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "space-y-1", children: features.map((feature, index) => /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center gap-2 text-sm ", children: [
1807
1807
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.Check, { className: "h-4 w-4 text-primary" }),
1808
1808
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: feature })
1809
1809
  ] }, index)) }),
1810
1810
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex justify-end gap-3 pt-2 border-t border-accent/30", children: [
1811
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Button, { variant: "outline", onClick: onCancel, disabled: isLoading, children: "Cancel" }),
1812
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Button, { onClick: onConfirm, disabled: isLoading, children: isLoading ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
1811
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Button, { variant: "outline", onClick: onCancel, disabled: isLoading, children: "Cancel" }),
1812
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Button, { onClick: onConfirm, disabled: isLoading, children: isLoading ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
1813
1813
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.Loader2, { className: "h-4 w-4 animate-spin me-2" }),
1814
1814
  "Processing..."
1815
1815
  ] }) : "Subscribe" })
@@ -1880,7 +1880,7 @@ function useSubscriptionWizard({ subscription, onSuccess, onClose }) {
1880
1880
  onCloseRef.current = onClose;
1881
1881
  const checkPaymentMethod = _react.useCallback.call(void 0, async () => {
1882
1882
  try {
1883
- const methods = await _chunkIV4DTYXNjs.StripeCustomerService.listPaymentMethods();
1883
+ const methods = await _chunkU7QVISQSjs.StripeCustomerService.listPaymentMethods();
1884
1884
  dispatch({ type: "SET_HAS_PAYMENT_METHOD", hasMethod: methods.length > 0 });
1885
1885
  } catch (error) {
1886
1886
  console.error("[useSubscriptionWizard] Failed to check payment methods:", error);
@@ -1904,7 +1904,7 @@ function useSubscriptionWizard({ subscription, onSuccess, onClose }) {
1904
1904
  const isTrialUpgrade = _optionalChain([subscription, 'optionalAccess', _55 => _55.status]) === "trialing" /* TRIALING */;
1905
1905
  dispatch({ type: "SET_IS_TRIAL_SUBSCRIPTION", isTrial: isTrialUpgrade });
1906
1906
  if (isTrialUpgrade && !state.hasPaymentMethod) {
1907
- const methods = await _chunkIV4DTYXNjs.StripeCustomerService.listPaymentMethods();
1907
+ const methods = await _chunkU7QVISQSjs.StripeCustomerService.listPaymentMethods();
1908
1908
  if (methods.length === 0) {
1909
1909
  dispatch({ type: "SET_STEP", step: "payment-method" });
1910
1910
  dispatch({
@@ -1915,7 +1915,7 @@ function useSubscriptionWizard({ subscription, onSuccess, onClose }) {
1915
1915
  }
1916
1916
  }
1917
1917
  if (subscription && state.selectedPrice.id !== _optionalChain([subscription, 'access', _56 => _56.price, 'optionalAccess', _57 => _57.id])) {
1918
- const preview = await _chunkIV4DTYXNjs.StripeSubscriptionService.getProrationPreview({
1918
+ const preview = await _chunkU7QVISQSjs.StripeSubscriptionService.getProrationPreview({
1919
1919
  subscriptionId: subscription.id,
1920
1920
  newPriceId: state.selectedPrice.id
1921
1921
  });
@@ -1940,14 +1940,14 @@ function useSubscriptionWizard({ subscription, onSuccess, onClose }) {
1940
1940
  newPriceId: state.selectedPrice.id,
1941
1941
  promotionCode: _optionalChain([state, 'access', _59 => _59.promotionCode, 'optionalAccess', _60 => _60.promotionCodeId])
1942
1942
  };
1943
- await _chunkIV4DTYXNjs.StripeSubscriptionService.changePlan(changePlanParams);
1943
+ await _chunkU7QVISQSjs.StripeSubscriptionService.changePlan(changePlanParams);
1944
1944
  } else {
1945
1945
  const createParams = {
1946
1946
  id: _uuid.v4.call(void 0, ),
1947
1947
  priceId: state.selectedPrice.id,
1948
1948
  promotionCode: _optionalChain([state, 'access', _61 => _61.promotionCode, 'optionalAccess', _62 => _62.promotionCodeId])
1949
1949
  };
1950
- await _chunkIV4DTYXNjs.StripeSubscriptionService.createSubscription(createParams);
1950
+ await _chunkU7QVISQSjs.StripeSubscriptionService.createSubscription(createParams);
1951
1951
  }
1952
1952
  onSuccessRef.current();
1953
1953
  onCloseRef.current();
@@ -1981,7 +1981,7 @@ function useSubscriptionWizard({ subscription, onSuccess, onClose }) {
1981
1981
  dispatch({ type: "SET_VALIDATING_PROMO_CODE", isValidating: true });
1982
1982
  dispatch({ type: "SET_PROMO_CODE_ERROR", error: null });
1983
1983
  try {
1984
- const result = await _chunkIV4DTYXNjs.StripePromotionCodeService.validatePromotionCode({
1984
+ const result = await _chunkU7QVISQSjs.StripePromotionCodeService.validatePromotionCode({
1985
1985
  code,
1986
1986
  stripePriceId: _optionalChain([state, 'access', _70 => _70.selectedPrice, 'optionalAccess', _71 => _71.id])
1987
1987
  });
@@ -2088,7 +2088,7 @@ function WizardStepPlanSelection({
2088
2088
  _react.useEffect.call(void 0, () => {
2089
2089
  const loadProducts = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
2090
2090
  try {
2091
- const fetchedProducts = await _chunkIV4DTYXNjs.StripeProductService.listProducts({ active: true });
2091
+ const fetchedProducts = await _chunkU7QVISQSjs.StripeProductService.listProducts({ active: true });
2092
2092
  setProducts(fetchedProducts);
2093
2093
  } catch (error) {
2094
2094
  console.error("[WizardStepPlanSelection] Failed to load products:", error);
@@ -2139,7 +2139,7 @@ function WizardStepPlanSelection({
2139
2139
  onSelectPrice: handleSelectPrice
2140
2140
  }
2141
2141
  ),
2142
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "flex justify-end pt-4 border-t", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Button, { onClick: onNext, disabled: !selectedPrice || isProcessing, children: isProcessing ? "Loading..." : "Next: Review" }) })
2142
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "flex justify-end pt-4 border-t", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Button, { onClick: onNext, disabled: !selectedPrice || isProcessing, children: isProcessing ? "Loading..." : "Next: Review" }) })
2143
2143
  ] });
2144
2144
  }
2145
2145
  _chunk7QVYU63Ejs.__name.call(void 0, WizardStepPlanSelection, "WizardStepPlanSelection");
@@ -2200,7 +2200,7 @@ function PromoCodeInput({
2200
2200
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-success text-sm", children: formatDiscount(appliedCode) })
2201
2201
  ] }),
2202
2202
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
2203
- _chunk3YJF7QY4js.Button,
2203
+ _chunk2XCUAHQTjs.Button,
2204
2204
  {
2205
2205
  variant: "ghost",
2206
2206
  size: "sm",
@@ -2217,7 +2217,7 @@ function PromoCodeInput({
2217
2217
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2", children: [
2218
2218
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex gap-2", children: [
2219
2219
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
2220
- _chunk3YJF7QY4js.Input,
2220
+ _chunk2XCUAHQTjs.Input,
2221
2221
  {
2222
2222
  placeholder: "Enter promo code",
2223
2223
  value: code,
@@ -2227,7 +2227,7 @@ function PromoCodeInput({
2227
2227
  className: "flex-1"
2228
2228
  }
2229
2229
  ),
2230
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Button, { variant: "outline", onClick: handleApply, disabled: disabled || isValidating || !code.trim(), children: isValidating ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.Loader2, { className: "h-4 w-4 animate-spin" }) : "Apply" })
2230
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Button, { variant: "outline", onClick: handleApply, disabled: disabled || isValidating || !code.trim(), children: isValidating ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.Loader2, { className: "h-4 w-4 animate-spin" }) : "Apply" })
2231
2231
  ] }),
2232
2232
  error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-destructive text-xs/relaxed", children: error })
2233
2233
  ] });
@@ -2292,14 +2292,14 @@ function WizardStepReview({
2292
2292
  return `${promotionCode.discountValue}% off`;
2293
2293
  }
2294
2294
  if (promotionCode.discountType === "amount_off" && promotionCode.discountValue) {
2295
- return `${_chunk3YJF7QY4js.formatCurrency.call(void 0, promotionCode.discountValue, promotionCode.currency || selectedPrice.currency)} off`;
2295
+ return `${_chunk2XCUAHQTjs.formatCurrency.call(void 0, promotionCode.discountValue, promotionCode.currency || selectedPrice.currency)} off`;
2296
2296
  }
2297
2297
  return null;
2298
2298
  }, "getDiscountDescription");
2299
2299
  const discountDescription = getDiscountDescription();
2300
2300
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-6", children: [
2301
2301
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "bg-muted/50 rounded-lg p-4 space-y-3", children: [
2302
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.SectionHeader, { children: "Selected Plan" }),
2302
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.SectionHeader, { children: "Selected Plan" }),
2303
2303
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex justify-between items-center", children: [
2304
2304
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { children: [
2305
2305
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "font-medium", children: _optionalChain([selectedPrice, 'access', _92 => _92.product, 'optionalAccess', _93 => _93.name]) }),
@@ -2307,10 +2307,10 @@ function WizardStepReview({
2307
2307
  ] }),
2308
2308
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "text-end", children: [
2309
2309
  discountedPrice !== null ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
2310
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-sm text-muted-foreground line-through", children: _chunk3YJF7QY4js.formatCurrency.call(void 0, selectedPrice.unitAmount || 0, selectedPrice.currency) }),
2311
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-success text-lg font-semibold", children: _chunk3YJF7QY4js.formatCurrency.call(void 0, discountedPrice, selectedPrice.currency) }),
2312
- discountDescription && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Badge, { variant: "softGreen", children: discountDescription })
2313
- ] }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "font-semibold text-lg", children: _chunk3YJF7QY4js.formatCurrency.call(void 0, selectedPrice.unitAmount || 0, selectedPrice.currency) }),
2310
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-sm text-muted-foreground line-through", children: _chunk2XCUAHQTjs.formatCurrency.call(void 0, selectedPrice.unitAmount || 0, selectedPrice.currency) }),
2311
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-success text-lg font-semibold", children: _chunk2XCUAHQTjs.formatCurrency.call(void 0, discountedPrice, selectedPrice.currency) }),
2312
+ discountDescription && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Badge, { variant: "softGreen", children: discountDescription })
2313
+ ] }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "font-semibold text-lg", children: _chunk2XCUAHQTjs.formatCurrency.call(void 0, selectedPrice.unitAmount || 0, selectedPrice.currency) }),
2314
2314
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-sm text-muted-foreground", children: formatInterval2(selectedPrice) })
2315
2315
  ] })
2316
2316
  ] })
@@ -2325,9 +2325,9 @@ function WizardStepReview({
2325
2325
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex justify-between text-sm", children: [
2326
2326
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: `${isTrialUpgrade ? "text-warning" : "text-muted-foreground"}`, children: isTrialUpgrade ? "Amount to charge now:" : "Amount due now:" }),
2327
2327
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: `font-medium ${isTrialUpgrade ? "text-warning" : "text-foreground"}`, children: discountedImmediateCharge !== null ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
2328
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "line-through text-muted-foreground me-2", children: _chunk3YJF7QY4js.formatCurrency.call(void 0, prorationPreview.immediateCharge, prorationPreview.currency) }),
2329
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-success", children: _chunk3YJF7QY4js.formatCurrency.call(void 0, discountedImmediateCharge, prorationPreview.currency) })
2330
- ] }) : _chunk3YJF7QY4js.formatCurrency.call(void 0, prorationPreview.immediateCharge, prorationPreview.currency) })
2328
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "line-through text-muted-foreground me-2", children: _chunk2XCUAHQTjs.formatCurrency.call(void 0, prorationPreview.immediateCharge, prorationPreview.currency) }),
2329
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-success", children: _chunk2XCUAHQTjs.formatCurrency.call(void 0, discountedImmediateCharge, prorationPreview.currency) })
2330
+ ] }) : _chunk2XCUAHQTjs.formatCurrency.call(void 0, prorationPreview.immediateCharge, prorationPreview.currency) })
2331
2331
  ] })
2332
2332
  ]
2333
2333
  }
@@ -2351,15 +2351,15 @@ function WizardStepReview({
2351
2351
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h4", { className: "font-medium", children: "Payment Method" }),
2352
2352
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-sm text-muted-foreground", children: hasPaymentMethod ? "A payment method is on file" : "No payment method on file" })
2353
2353
  ] }),
2354
- !hasPaymentMethod && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Button, { variant: "outline", onClick: onAddPaymentMethod, children: "Add Payment Method" })
2354
+ !hasPaymentMethod && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Button, { variant: "outline", onClick: onAddPaymentMethod, children: "Add Payment Method" })
2355
2355
  ] }) }),
2356
- error && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.Alert, { variant: "destructive", children: [
2356
+ error && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.Alert, { variant: "destructive", children: [
2357
2357
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.AlertCircle, { className: "h-4 w-4" }),
2358
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.AlertDescription, { children: error })
2358
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.AlertDescription, { children: error })
2359
2359
  ] }),
2360
2360
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex justify-between pt-4 border-t", children: [
2361
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Button, { variant: "outline", onClick: onBack, disabled: isProcessing, children: "Back" }),
2362
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Button, { onClick: hasPaymentMethod ? onConfirm : onAddPaymentMethod, disabled: isProcessing, children: isProcessing ? "Processing..." : hasPaymentMethod ? isChangingPlan ? "Confirm Plan Change" : "Subscribe Now" : "Add Payment Method" })
2361
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Button, { variant: "outline", onClick: onBack, disabled: isProcessing, children: "Back" }),
2362
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Button, { onClick: hasPaymentMethod ? onConfirm : onAddPaymentMethod, disabled: isProcessing, children: isProcessing ? "Processing..." : hasPaymentMethod ? isChangingPlan ? "Confirm Plan Change" : "Subscribe Now" : "Add Payment Method" })
2363
2363
  ] })
2364
2364
  ] });
2365
2365
  }
@@ -2370,7 +2370,7 @@ _chunk7QVYU63Ejs.__name.call(void 0, WizardStepReview, "WizardStepReview");
2370
2370
  function WizardStepPaymentMethod({ onBack, onSuccess, isProcessing }) {
2371
2371
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-6", children: [
2372
2372
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "text-center", children: [
2373
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.SectionHeader, { children: "Add Payment Method" }),
2373
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.SectionHeader, { children: "Add Payment Method" }),
2374
2374
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-sm text-muted-foreground", children: "Enter your card details to complete your subscription" })
2375
2375
  ] }),
2376
2376
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, PaymentMethodForm, { onSuccess, onCancel: onBack, isLoading: isProcessing })
@@ -2412,10 +2412,10 @@ function SubscriptionWizard({
2412
2412
  const isChangePlanMode = !!subscription;
2413
2413
  const dialogTitle = subscription ? "Change Subscription Plan" : isPurchasingAddons ? "Purchase Add-ons" : "Subscribe to a Plan";
2414
2414
  const dialogDescription = subscription ? "Select a new plan for your subscription" : isPurchasingAddons ? "Select one-time products to purchase" : "Choose a subscription plan to get started";
2415
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Dialog, { open, onOpenChange, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.DialogContent, { className: "max-w-2xl", children: [
2416
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.DialogHeader, { children: [
2417
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.DialogTitle, { children: dialogTitle }),
2418
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.DialogDescription, { children: dialogDescription })
2415
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Dialog, { open, onOpenChange, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.DialogContent, { className: "max-w-2xl", children: [
2416
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.DialogHeader, { children: [
2417
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.DialogTitle, { children: dialogTitle }),
2418
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.DialogDescription, { children: dialogDescription })
2419
2419
  ] }),
2420
2420
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, WizardProgressIndicator, { currentStep: state.step }),
2421
2421
  state.step === "plan-selection" && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
@@ -2498,15 +2498,15 @@ function UsageSummaryCard({ meter, summary }) {
2498
2498
  const progressWidth = percentage !== null ? Math.min(percentage, 100) : 0;
2499
2499
  const displayName = meter.displayName || meter.eventName;
2500
2500
  const hasLimit = limit !== null && limit !== void 0;
2501
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.Card, { children: [
2502
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.CardHeader, { className: "flex flex-row items-center gap-x-3 pb-3", children: [
2501
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.Card, { children: [
2502
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.CardHeader, { className: "flex flex-row items-center gap-x-3 pb-3", children: [
2503
2503
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "flex h-10 w-10 items-center justify-center rounded-lg bg-blue-100 text-blue-600", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.Activity, { className: "h-5 w-5" }) }),
2504
2504
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex flex-col", children: [
2505
2505
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h3", { className: "text-sm font-medium", children: displayName }),
2506
2506
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-muted-foreground text-xs", children: meter.id })
2507
2507
  ] })
2508
2508
  ] }),
2509
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.CardContent, { className: "flex flex-col gap-y-4", children: [
2509
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.CardContent, { className: "flex flex-col gap-y-4", children: [
2510
2510
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { children: [
2511
2511
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-3xl font-bold", children: currentUsage.toLocaleString() }),
2512
2512
  hasLimit && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "p", { className: "text-muted-foreground text-sm", children: [
@@ -2553,14 +2553,14 @@ function UsageContainer() {
2553
2553
  const loadUsageData = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
2554
2554
  setLoading(true);
2555
2555
  try {
2556
- const fetchedSubscriptions = await _chunkIV4DTYXNjs.StripeSubscriptionService.listSubscriptions();
2556
+ const fetchedSubscriptions = await _chunkU7QVISQSjs.StripeSubscriptionService.listSubscriptions();
2557
2557
  setSubscriptions(fetchedSubscriptions);
2558
2558
  const hasMeteredSubscriptions2 = fetchedSubscriptions.some((sub) => _optionalChain([sub, 'access', _99 => _99.price, 'optionalAccess', _100 => _100.recurring, 'optionalAccess', _101 => _101.usageType]) === "metered");
2559
2559
  if (!hasMeteredSubscriptions2) {
2560
2560
  setLoading(false);
2561
2561
  return;
2562
2562
  }
2563
- const fetchedMeters = await _chunkIV4DTYXNjs.StripeUsageService.listMeters();
2563
+ const fetchedMeters = await _chunkU7QVISQSjs.StripeUsageService.listMeters();
2564
2564
  setMeters(fetchedMeters);
2565
2565
  const summariesMap = {};
2566
2566
  const now = /* @__PURE__ */ new Date();
@@ -2568,7 +2568,7 @@ function UsageContainer() {
2568
2568
  const endOfMonth = new Date(now.getFullYear(), now.getMonth() + 1, 0, 23, 59, 59, 999);
2569
2569
  for (const meter of fetchedMeters) {
2570
2570
  try {
2571
- const meterSummaries = await _chunkIV4DTYXNjs.StripeUsageService.getMeterSummaries({
2571
+ const meterSummaries = await _chunkU7QVISQSjs.StripeUsageService.getMeterSummaries({
2572
2572
  meterId: meter.id,
2573
2573
  startTime: startOfMonth,
2574
2574
  endTime: endOfMonth
@@ -2633,22 +2633,22 @@ function UsageHistoryTable({ usageRecords }) {
2633
2633
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rounded-lg border p-8 text-center", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-muted-foreground", children: "No usage history available." }) });
2634
2634
  }
2635
2635
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex w-full flex-col gap-y-4", children: [
2636
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.SectionHeader, { level: 2, children: "Usage History" }),
2637
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "overflow-clip rounded-lg border", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.Table, { children: [
2638
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableHeader, { className: "bg-muted", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.TableRow, { children: [
2639
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableHead, { children: "Date & Time" }),
2640
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableHead, { children: "Meter Event" }),
2641
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableHead, { className: "text-end", children: "Quantity" }),
2642
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableHead, { children: "Event ID" })
2636
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.SectionHeader, { level: 2, children: "Usage History" }),
2637
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "overflow-clip rounded-lg border", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.Table, { children: [
2638
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableHeader, { className: "bg-muted", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.TableRow, { children: [
2639
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableHead, { children: "Date & Time" }),
2640
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableHead, { children: "Meter Event" }),
2641
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableHead, { className: "text-end", children: "Quantity" }),
2642
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableHead, { children: "Event ID" })
2643
2643
  ] }) }),
2644
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableBody, { children: usageRecords.map((record) => {
2644
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableBody, { children: usageRecords.map((record) => {
2645
2645
  const dateTime = formatDateTime(record.timestamp);
2646
2646
  const quantity = record.quantity.toLocaleString();
2647
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.TableRow, { children: [
2648
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableCell, { className: "font-medium", children: dateTime }),
2649
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableCell, { className: "text-muted-foreground", children: record.meterEventName }),
2650
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableCell, { className: "text-end font-medium", children: quantity }),
2651
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.TableCell, { className: "text-muted-foreground text-sm tabular-nums", children: record.stripeEventId })
2647
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.TableRow, { children: [
2648
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableCell, { className: "font-medium", children: dateTime }),
2649
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableCell, { className: "text-muted-foreground", children: record.meterEventName }),
2650
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableCell, { className: "text-end font-medium", children: quantity }),
2651
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.TableCell, { className: "text-muted-foreground text-sm tabular-nums", children: record.stripeEventId })
2652
2652
  ] }, record.id);
2653
2653
  }) })
2654
2654
  ] }) })
@@ -2659,8 +2659,8 @@ _chunk7QVYU63Ejs.__name.call(void 0, UsageHistoryTable, "UsageHistoryTable");
2659
2659
  // src/features/billing/components/modals/BillingDetailModal.tsx
2660
2660
 
2661
2661
  function BillingDetailModal({ open, onOpenChange, title, children, className }) {
2662
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Dialog, { open, onOpenChange, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.DialogContent, { className: _nullishCoalesce(className, () => ( "max-w-4xl max-h-[90vh] overflow-y-auto")), children: [
2663
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.DialogHeader, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.DialogTitle, { children: title }) }),
2662
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Dialog, { open, onOpenChange, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.DialogContent, { className: _nullishCoalesce(className, () => ( "max-w-4xl max-h-[90vh] overflow-y-auto")), children: [
2663
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.DialogHeader, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.DialogTitle, { children: title }) }),
2664
2664
  children
2665
2665
  ] }) });
2666
2666
  }
@@ -2677,7 +2677,7 @@ function BillingAlertBanner({ subscription, onUpdatePayment, onAddPayment }) {
2677
2677
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h3", { className: "text-destructive text-sm font-medium", children: "Payment Failed" }),
2678
2678
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-destructive mt-1 text-sm", children: "Your last payment failed. Please update your payment method to avoid service interruption." })
2679
2679
  ] }),
2680
- onUpdatePayment && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Button, { variant: "outline", size: "sm", onClick: onUpdatePayment, className: "text-destructive border-red-300", children: "Update Payment Method" })
2680
+ onUpdatePayment && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Button, { variant: "outline", size: "sm", onClick: onUpdatePayment, className: "text-destructive border-red-300", children: "Update Payment Method" })
2681
2681
  ] });
2682
2682
  }
2683
2683
  if (subscription.status === "trialing" /* TRIALING */ && subscription.trialEnd) {
@@ -2697,7 +2697,7 @@ function BillingAlertBanner({ subscription, onUpdatePayment, onAddPayment }) {
2697
2697
  ". Add a payment method to continue your subscription."
2698
2698
  ] })
2699
2699
  ] }),
2700
- onAddPayment && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Button, { variant: "outline", size: "sm", onClick: onAddPayment, className: "text-warning border-yellow-300", children: "Add Payment Method" })
2700
+ onAddPayment && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Button, { variant: "outline", size: "sm", onClick: onAddPayment, className: "text-warning border-yellow-300", children: "Add Payment Method" })
2701
2701
  ] });
2702
2702
  }
2703
2703
  }
@@ -2748,7 +2748,7 @@ function BillingDashboardContainer() {
2748
2748
  setNoCustomerExists(false);
2749
2749
  let customer = null;
2750
2750
  try {
2751
- customer = await _chunkIV4DTYXNjs.StripeCustomerService.getCustomer();
2751
+ customer = await _chunkU7QVISQSjs.StripeCustomerService.getCustomer();
2752
2752
  setData((prev) => ({ ...prev, customer }));
2753
2753
  setErrors((prev) => ({ ...prev, customer: null }));
2754
2754
  setNoCustomerExists(false);
@@ -2774,7 +2774,7 @@ function BillingDashboardContainer() {
2774
2774
  }
2775
2775
  const fetchSubscriptions = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
2776
2776
  try {
2777
- const subscriptions2 = await _chunkIV4DTYXNjs.StripeSubscriptionService.listSubscriptions();
2777
+ const subscriptions2 = await _chunkU7QVISQSjs.StripeSubscriptionService.listSubscriptions();
2778
2778
  setData((prev) => ({ ...prev, subscriptions: subscriptions2 }));
2779
2779
  setErrors((prev) => ({ ...prev, subscriptions: null }));
2780
2780
  return subscriptions2;
@@ -2788,7 +2788,7 @@ function BillingDashboardContainer() {
2788
2788
  }, "fetchSubscriptions");
2789
2789
  const fetchPaymentMethods = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
2790
2790
  try {
2791
- const paymentMethods = await _chunkIV4DTYXNjs.StripeCustomerService.listPaymentMethods();
2791
+ const paymentMethods = await _chunkU7QVISQSjs.StripeCustomerService.listPaymentMethods();
2792
2792
  setData((prev) => ({ ...prev, paymentMethods }));
2793
2793
  setErrors((prev) => ({ ...prev, paymentMethods: null }));
2794
2794
  } catch (error) {
@@ -2800,7 +2800,7 @@ function BillingDashboardContainer() {
2800
2800
  }, "fetchPaymentMethods");
2801
2801
  const fetchInvoices = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
2802
2802
  try {
2803
- const invoices = await _chunkIV4DTYXNjs.StripeInvoiceService.listInvoices();
2803
+ const invoices = await _chunkU7QVISQSjs.StripeInvoiceService.listInvoices();
2804
2804
  setData((prev) => ({ ...prev, invoices }));
2805
2805
  setErrors((prev) => ({ ...prev, invoices: null }));
2806
2806
  } catch (error) {
@@ -2823,7 +2823,7 @@ function BillingDashboardContainer() {
2823
2823
  const handleCreateCustomer = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
2824
2824
  setCreatingCustomer(true);
2825
2825
  try {
2826
- await _chunkIV4DTYXNjs.StripeCustomerService.createCustomer();
2826
+ await _chunkU7QVISQSjs.StripeCustomerService.createCustomer();
2827
2827
  setNoCustomerExists(false);
2828
2828
  await fetchAllData();
2829
2829
  } catch (error) {
@@ -2835,7 +2835,7 @@ function BillingDashboardContainer() {
2835
2835
  }, "handleCreateCustomer");
2836
2836
  const fetchUsageData = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
2837
2837
  try {
2838
- const meters = await _chunkIV4DTYXNjs.StripeUsageService.listMeters();
2838
+ const meters = await _chunkU7QVISQSjs.StripeUsageService.listMeters();
2839
2839
  setData((prev) => ({ ...prev, meters }));
2840
2840
  const summariesMap = {};
2841
2841
  const now = /* @__PURE__ */ new Date();
@@ -2843,7 +2843,7 @@ function BillingDashboardContainer() {
2843
2843
  const endOfMonth = new Date(now.getFullYear(), now.getMonth() + 1, 0, 23, 59, 59, 999);
2844
2844
  for (const meter of meters) {
2845
2845
  try {
2846
- const meterSummaries = await _chunkIV4DTYXNjs.StripeUsageService.getMeterSummaries({
2846
+ const meterSummaries = await _chunkU7QVISQSjs.StripeUsageService.getMeterSummaries({
2847
2847
  meterId: meter.id,
2848
2848
  startTime: startOfMonth,
2849
2849
  endTime: endOfMonth
@@ -2921,18 +2921,18 @@ function BillingDashboardContainer() {
2921
2921
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.Wallet, { className: "h-8 w-8" }),
2922
2922
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h1", { className: "text-primary text-3xl font-semibold", children: "Billing" })
2923
2923
  ] }),
2924
- isInitialLoading && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Card, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardContent, { className: "flex items-center justify-center py-12", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.Loader2, { className: "h-8 w-8 animate-spin text-muted-foreground" }) }) }),
2925
- noCustomerExists && !isInitialLoading && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.Card, { children: [
2926
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.CardHeader, { className: "text-center", children: [
2924
+ isInitialLoading && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Card, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardContent, { className: "flex items-center justify-center py-12", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.Loader2, { className: "h-8 w-8 animate-spin text-muted-foreground" }) }) }),
2925
+ noCustomerExists && !isInitialLoading && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.Card, { children: [
2926
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.CardHeader, { className: "text-center", children: [
2927
2927
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "mx-auto mb-4 flex h-16 w-16 items-center justify-center rounded-full bg-primary/10", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.CreditCard, { className: "h-8 w-8 text-primary" }) }),
2928
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardTitle, { children: "Set Up Billing" }),
2929
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardDescription, { children: "Your company doesn't have a billing account yet. Set one up to manage subscriptions, payment methods, and view invoices." })
2928
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardTitle, { children: "Set Up Billing" }),
2929
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardDescription, { children: "Your company doesn't have a billing account yet. Set one up to manage subscriptions, payment methods, and view invoices." })
2930
2930
  ] }),
2931
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardContent, { className: "flex justify-center pb-8", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Button, { onClick: handleCreateCustomer, disabled: creatingCustomer, size: "lg", children: creatingCustomer ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
2931
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardContent, { className: "flex justify-center pb-8", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Button, { onClick: handleCreateCustomer, disabled: creatingCustomer, size: "lg", children: creatingCustomer ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
2932
2932
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.Loader2, { className: "me-2 h-4 w-4 animate-spin" }),
2933
2933
  "Setting up..."
2934
2934
  ] }) : "Set Up Billing Account" }) }),
2935
- errors.customer && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.CardContent, { className: "pt-0", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-center text-destructive text-xs/relaxed", children: errors.customer }) })
2935
+ errors.customer && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.CardContent, { className: "pt-0", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-center text-destructive text-xs/relaxed", children: errors.customer }) })
2936
2936
  ] }),
2937
2937
  !noCustomerExists && !isInitialLoading && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
2938
2938
  criticalSubscriptions.map((subscription) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
@@ -3074,7 +3074,7 @@ function getStripePromise(publishableKey) {
3074
3074
  }
3075
3075
  _chunk7QVYU63Ejs.__name.call(void 0, getStripePromise, "getStripePromise");
3076
3076
  function StripeProvider({ children }) {
3077
- const publishableKey = _chunk3D2MCVRZjs.getStripePublishableKey.call(void 0, );
3077
+ const publishableKey = _chunk3AR4KA5Djs.getStripePublishableKey.call(void 0, );
3078
3078
  const stripePromise = _react.useMemo.call(void 0, () => getStripePromise(publishableKey), [publishableKey]);
3079
3079
  const options = _react.useMemo.call(void 0, () => ({}), []);
3080
3080
  if (!publishableKey) {
@@ -3084,7 +3084,7 @@ function StripeProvider({ children }) {
3084
3084
  }
3085
3085
  _chunk7QVYU63Ejs.__name.call(void 0, StripeProvider, "StripeProvider");
3086
3086
  function isStripeConfigured() {
3087
- return !!_chunk3D2MCVRZjs.getStripePublishableKey.call(void 0, );
3087
+ return !!_chunk3AR4KA5Djs.getStripePublishableKey.call(void 0, );
3088
3088
  }
3089
3089
  _chunk7QVYU63Ejs.__name.call(void 0, isStripeConfigured, "isStripeConfigured");
3090
3090
 
@@ -3104,12 +3104,12 @@ function PriceArchiver({ price }) {
3104
3104
  const isArchived = !price.active;
3105
3105
  const scope = isArchived ? "restore" : "archive";
3106
3106
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
3107
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.Button, { variant: "outline", size: "sm", onClick: () => setOpen(true), children: [
3107
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.Button, { variant: "outline", size: "sm", onClick: () => setOpen(true), children: [
3108
3108
  isArchived ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.RotateCcwIcon, {}) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.ArchiveIcon, {}),
3109
3109
  t(`billing.admin.prices.${scope}.confirm`)
3110
3110
  ] }),
3111
3111
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3112
- _chunk3YJF7QY4js.ConfirmDialog,
3112
+ _chunk2XCUAHQTjs.ConfirmDialog,
3113
3113
  {
3114
3114
  open,
3115
3115
  onOpenChange: setOpen,
@@ -3123,7 +3123,7 @@ function PriceArchiver({ price }) {
3123
3123
  if (isArchived) await restorePrice(price.id);
3124
3124
  else await archivePrice(price.id);
3125
3125
  } catch (error) {
3126
- _chunk3YJF7QY4js.errorToast.call(void 0, { title: t(`billing.admin.prices.${scope}.title`), error });
3126
+ _chunk2XCUAHQTjs.errorToast.call(void 0, { title: t(`billing.admin.prices.${scope}.title`), error });
3127
3127
  throw error;
3128
3128
  }
3129
3129
  }
@@ -3155,14 +3155,14 @@ function PriceEditorInternal({
3155
3155
  onDialogOpenChange
3156
3156
  }) {
3157
3157
  const t = _nextintl.useTranslations.call(void 0, );
3158
- const router = _chunk3D2MCVRZjs.useI18nRouter.call(void 0, );
3158
+ const router = _chunk3AR4KA5Djs.useI18nRouter.call(void 0, );
3159
3159
  const { createPrice, updatePrice, productId: contextProductId } = usePriceContext();
3160
3160
  const [allFeatures, setAllFeatures] = _react.useState.call(void 0, []);
3161
3161
  const isEdit = !!price;
3162
3162
  const targetProductId = _nullishCoalesce(_nullishCoalesce(productId, () => ( _optionalChain([price, 'optionalAccess', _117 => _117.product, 'optionalAccess', _118 => _118.id]))), () => ( contextProductId));
3163
3163
  _react.useEffect.call(void 0, () => {
3164
3164
  const fetchFeatures = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
3165
- setAllFeatures(await _chunkIV4DTYXNjs.FeatureService.findMany({}));
3165
+ setAllFeatures(await _chunkU7QVISQSjs.FeatureService.findMany({}));
3166
3166
  }, "fetchFeatures");
3167
3167
  void fetchFeatures();
3168
3168
  }, []);
@@ -3275,7 +3275,7 @@ function PriceEditorInternal({
3275
3275
  warnedUnknownFor.current = fingerprint;
3276
3276
  const { unknown } = resolvePlatformFeatures(seed.platformFeatures);
3277
3277
  if (unknown.length > 0)
3278
- _chunkIV4DTYXNjs.showToast.call(void 0, t("billing.admin.prices.import.warnings.unknownFeatures", { features: unknown.join(", ") }));
3278
+ _chunkU7QVISQSjs.showToast.call(void 0, t("billing.admin.prices.import.warnings.unknownFeatures", { features: unknown.join(", ") }));
3279
3279
  }, [seed, isEdit, allFeatures, resolvePlatformFeatures, t]);
3280
3280
  const watchInterval = form.watch("interval");
3281
3281
  const isRecurring = watchInterval !== "one_time";
@@ -3296,13 +3296,13 @@ function PriceEditorInternal({
3296
3296
  { id: "metered", text: t("billing.admin.prices.usage.metered") }
3297
3297
  ];
3298
3298
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3299
- _chunk3YJF7QY4js.EditorSheet,
3299
+ _chunk2XCUAHQTjs.EditorSheet,
3300
3300
  {
3301
3301
  form,
3302
3302
  entityType: t("billing.admin.prices.entity"),
3303
3303
  entityName: price ? priceLabel(price) : void 0,
3304
3304
  isEdit,
3305
- module: _chunkIV4DTYXNjs.Modules.StripePrice,
3305
+ module: _chunkU7QVISQSjs.Modules.StripePrice,
3306
3306
  size: "lg",
3307
3307
  propagateChanges,
3308
3308
  onSuccess,
@@ -3351,13 +3351,13 @@ function PriceEditorInternal({
3351
3351
  dialogOpen,
3352
3352
  onDialogOpenChange,
3353
3353
  children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex w-full flex-col gap-y-4", children: [
3354
- isEdit && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.Alert, { children: [
3355
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.AlertTitle, { children: t("billing.admin.prices.immutability.title") }),
3356
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.AlertDescription, { children: t("billing.admin.prices.immutability.description") })
3354
+ isEdit && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.Alert, { children: [
3355
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.AlertTitle, { children: t("billing.admin.prices.immutability.title") }),
3356
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.AlertDescription, { children: t("billing.admin.prices.immutability.description") })
3357
3357
  ] }),
3358
3358
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "grid grid-cols-2 gap-x-4", children: [
3359
3359
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3360
- _chunk3YJF7QY4js.FormInput,
3360
+ _chunk2XCUAHQTjs.FormInput,
3361
3361
  {
3362
3362
  form,
3363
3363
  id: "unitAmount",
@@ -3369,7 +3369,7 @@ function PriceEditorInternal({
3369
3369
  }
3370
3370
  ),
3371
3371
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3372
- _chunk3YJF7QY4js.FormSelect,
3372
+ _chunk2XCUAHQTjs.FormSelect,
3373
3373
  {
3374
3374
  form,
3375
3375
  id: "currency",
@@ -3380,7 +3380,7 @@ function PriceEditorInternal({
3380
3380
  )
3381
3381
  ] }),
3382
3382
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3383
- _chunk3YJF7QY4js.FormSelect,
3383
+ _chunk2XCUAHQTjs.FormSelect,
3384
3384
  {
3385
3385
  form,
3386
3386
  id: "interval",
@@ -3391,7 +3391,7 @@ function PriceEditorInternal({
3391
3391
  ),
3392
3392
  isRecurring && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "grid grid-cols-2 gap-x-4", children: [
3393
3393
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3394
- _chunk3YJF7QY4js.FormInput,
3394
+ _chunk2XCUAHQTjs.FormInput,
3395
3395
  {
3396
3396
  form,
3397
3397
  id: "intervalCount",
@@ -3402,7 +3402,7 @@ function PriceEditorInternal({
3402
3402
  }
3403
3403
  ),
3404
3404
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3405
- _chunk3YJF7QY4js.FormSelect,
3405
+ _chunk2XCUAHQTjs.FormSelect,
3406
3406
  {
3407
3407
  form,
3408
3408
  id: "usageType",
@@ -3413,7 +3413,7 @@ function PriceEditorInternal({
3413
3413
  )
3414
3414
  ] }),
3415
3415
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3416
- _chunk3YJF7QY4js.FormInput,
3416
+ _chunk2XCUAHQTjs.FormInput,
3417
3417
  {
3418
3418
  form,
3419
3419
  id: "nickname",
@@ -3422,7 +3422,7 @@ function PriceEditorInternal({
3422
3422
  }
3423
3423
  ),
3424
3424
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3425
- _chunk3YJF7QY4js.FormTextarea,
3425
+ _chunk2XCUAHQTjs.FormTextarea,
3426
3426
  {
3427
3427
  form,
3428
3428
  id: "description",
@@ -3432,7 +3432,7 @@ function PriceEditorInternal({
3432
3432
  }
3433
3433
  ),
3434
3434
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3435
- _chunk3YJF7QY4js.FormInput,
3435
+ _chunk2XCUAHQTjs.FormInput,
3436
3436
  {
3437
3437
  form,
3438
3438
  id: "token",
@@ -3442,10 +3442,10 @@ function PriceEditorInternal({
3442
3442
  }
3443
3443
  ),
3444
3444
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex flex-col gap-y-2", children: [
3445
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.FieldLabel, { children: t("billing.admin.prices.fields.features") }),
3445
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.FieldLabel, { children: t("billing.admin.prices.fields.features") }),
3446
3446
  form.watch("features").map((_, index) => /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex gap-2", children: [
3447
3447
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3448
- _chunk3YJF7QY4js.Input,
3448
+ _chunk2XCUAHQTjs.Input,
3449
3449
  {
3450
3450
  ...form.register(`features.${index}`),
3451
3451
  placeholder: t("billing.admin.prices.placeholders.feature", { index: index + 1 }),
@@ -3453,7 +3453,7 @@ function PriceEditorInternal({
3453
3453
  }
3454
3454
  ),
3455
3455
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3456
- _chunk3YJF7QY4js.Button,
3456
+ _chunk2XCUAHQTjs.Button,
3457
3457
  {
3458
3458
  type: "button",
3459
3459
  variant: "outline",
@@ -3468,7 +3468,7 @@ function PriceEditorInternal({
3468
3468
  )
3469
3469
  ] }, index)),
3470
3470
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
3471
- _chunk3YJF7QY4js.Button,
3471
+ _chunk2XCUAHQTjs.Button,
3472
3472
  {
3473
3473
  type: "button",
3474
3474
  variant: "outline",
@@ -3483,12 +3483,12 @@ function PriceEditorInternal({
3483
3483
  )
3484
3484
  ] }),
3485
3485
  isRecurring && allFeatures.length > 0 && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex flex-col gap-y-2", children: [
3486
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.FieldLabel, { children: t("billing.admin.prices.fields.platformFeatures") }),
3486
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.FieldLabel, { children: t("billing.admin.prices.fields.platformFeatures") }),
3487
3487
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "flex max-h-48 flex-col gap-y-2 overflow-y-auto rounded-md border p-4", children: allFeatures.map((feature) => {
3488
3488
  const isChecked = form.watch("featureIds").includes(feature.id);
3489
3489
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center gap-x-2", children: [
3490
3490
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3491
- _chunk3YJF7QY4js.Checkbox,
3491
+ _chunk2XCUAHQTjs.Checkbox,
3492
3492
  {
3493
3493
  id: `feature-${feature.id}`,
3494
3494
  checked: isChecked,
@@ -3504,13 +3504,13 @@ function PriceEditorInternal({
3504
3504
  }
3505
3505
  }
3506
3506
  ),
3507
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.FieldLabel, { htmlFor: `feature-${feature.id}`, children: feature.name }),
3507
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.FieldLabel, { htmlFor: `feature-${feature.id}`, children: feature.name }),
3508
3508
  feature.isCore && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-muted-foreground text-xs", children: t("billing.admin.prices.help.core") })
3509
3509
  ] }, feature.id);
3510
3510
  }) })
3511
3511
  ] }),
3512
3512
  isRecurring && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3513
- _chunk3YJF7QY4js.FormCheckbox,
3513
+ _chunk2XCUAHQTjs.FormCheckbox,
3514
3514
  {
3515
3515
  form,
3516
3516
  id: "isTrial",
@@ -3553,7 +3553,7 @@ var defaultContextValue = {
3553
3553
  productId: void 0
3554
3554
  };
3555
3555
  function priceLabel(price) {
3556
- return _nullishCoalesce(price.nickname, () => ( `${_chunk3YJF7QY4js.formatCurrency.call(void 0, price.unitAmount, price.currency)} ${_chunk3YJF7QY4js.formatInterval.call(void 0, price)}`.trim()));
3556
+ return _nullishCoalesce(price.nickname, () => ( `${_chunk2XCUAHQTjs.formatCurrency.call(void 0, price.unitAmount, price.currency)} ${_chunk2XCUAHQTjs.formatInterval.call(void 0, price)}`.trim()));
3557
3557
  }
3558
3558
  _chunk7QVYU63Ejs.__name.call(void 0, priceLabel, "priceLabel");
3559
3559
  var PriceProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({
@@ -3563,21 +3563,21 @@ var PriceProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({
3563
3563
  productId: productIdProp
3564
3564
  }) => {
3565
3565
  const t = _nextintl.useTranslations.call(void 0, );
3566
- const generateUrl = _chunk3YJF7QY4js.usePageUrlGenerator.call(void 0, );
3567
- const { hasRole } = _chunk3YJF7QY4js.useCurrentUserContext.call(void 0, );
3566
+ const generateUrl = _chunk2XCUAHQTjs.usePageUrlGenerator.call(void 0, );
3567
+ const { hasRole } = _chunk2XCUAHQTjs.useCurrentUserContext.call(void 0, );
3568
3568
  const [price, setPrice] = _react.useState.call(void 0,
3569
- dehydratedPrice ? _chunkIV4DTYXNjs.rehydrate.call(void 0, _chunkIV4DTYXNjs.Modules.StripePrice, dehydratedPrice) : void 0
3569
+ dehydratedPrice ? _chunkU7QVISQSjs.rehydrate.call(void 0, _chunkU7QVISQSjs.Modules.StripePrice, dehydratedPrice) : void 0
3570
3570
  );
3571
3571
  const [priceVersion, setPriceVersion] = _react.useState.call(void 0, 0);
3572
3572
  const refreshPrices = _react.useCallback.call(void 0, () => setPriceVersion((value2) => value2 + 1), []);
3573
3573
  const productId = _nullishCoalesce(productIdProp, () => ( _optionalChain([price, 'optionalAccess', _141 => _141.product, 'optionalAccess', _142 => _142.id])));
3574
3574
  const reloadPrice = _react.useCallback.call(void 0, async () => {
3575
3575
  if (!_optionalChain([price, 'optionalAccess', _143 => _143.id])) return;
3576
- setPrice(await _chunkIV4DTYXNjs.StripePriceService.getPrice({ id: price.id }));
3576
+ setPrice(await _chunkU7QVISQSjs.StripePriceService.getPrice({ id: price.id }));
3577
3577
  }, [_optionalChain([price, 'optionalAccess', _144 => _144.id])]);
3578
3578
  const createPrice = _react.useCallback.call(void 0,
3579
3579
  async (input) => {
3580
- const saved = await _chunkIV4DTYXNjs.StripePriceService.createPrice(input);
3580
+ const saved = await _chunkU7QVISQSjs.StripePriceService.createPrice(input);
3581
3581
  refreshPrices();
3582
3582
  return saved;
3583
3583
  },
@@ -3585,7 +3585,7 @@ var PriceProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({
3585
3585
  );
3586
3586
  const updatePrice = _react.useCallback.call(void 0,
3587
3587
  async (input) => {
3588
- const saved = await _chunkIV4DTYXNjs.StripePriceService.updatePrice(input);
3588
+ const saved = await _chunkU7QVISQSjs.StripePriceService.updatePrice(input);
3589
3589
  setPrice(saved);
3590
3590
  refreshPrices();
3591
3591
  return saved;
@@ -3596,7 +3596,7 @@ var PriceProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({
3596
3596
  async (id) => {
3597
3597
  const target = _nullishCoalesce(id, () => ( _optionalChain([price, 'optionalAccess', _145 => _145.id])));
3598
3598
  if (!target) return;
3599
- await _chunkIV4DTYXNjs.StripePriceService.archivePrice({ id: target });
3599
+ await _chunkU7QVISQSjs.StripePriceService.archivePrice({ id: target });
3600
3600
  await reloadPrice();
3601
3601
  refreshPrices();
3602
3602
  },
@@ -3606,7 +3606,7 @@ var PriceProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({
3606
3606
  async (id) => {
3607
3607
  const target = _nullishCoalesce(id, () => ( _optionalChain([price, 'optionalAccess', _147 => _147.id])));
3608
3608
  if (!target) return;
3609
- await _chunkIV4DTYXNjs.StripePriceService.reactivatePrice({ id: target });
3609
+ await _chunkU7QVISQSjs.StripePriceService.reactivatePrice({ id: target });
3610
3610
  await reloadPrice();
3611
3611
  refreshPrices();
3612
3612
  },
@@ -3630,12 +3630,12 @@ var PriceProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({
3630
3630
  if (!publishChrome) return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, PriceContext.Provider, { value, children });
3631
3631
  const breadcrumb = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, () => {
3632
3632
  const items = [
3633
- { name: t("billing.admin.products.title"), href: generateUrl({ page: _chunkIV4DTYXNjs.Modules.StripeProduct }) }
3633
+ { name: t("billing.admin.products.title"), href: generateUrl({ page: _chunkU7QVISQSjs.Modules.StripeProduct }) }
3634
3634
  ];
3635
3635
  if (_optionalChain([price, 'optionalAccess', _149 => _149.product]))
3636
3636
  items.push({
3637
3637
  name: price.product.name,
3638
- href: generateUrl({ page: _chunkIV4DTYXNjs.Modules.StripeProduct, id: price.product.id })
3638
+ href: generateUrl({ page: _chunkU7QVISQSjs.Modules.StripeProduct, id: price.product.id })
3639
3639
  });
3640
3640
  if (price) items.push({ name: priceLabel(price) });
3641
3641
  return items;
@@ -3644,7 +3644,7 @@ var PriceProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({
3644
3644
  const response = { type: t("billing.admin.prices.title") };
3645
3645
  if (!price) return response;
3646
3646
  response.element = priceLabel(price);
3647
- if (hasRole(_chunk3D2MCVRZjs.getRoleId.call(void 0, ).Administrator)) {
3647
+ if (hasRole(_chunk3AR4KA5Djs.getRoleId.call(void 0, ).Administrator)) {
3648
3648
  response.functions = [
3649
3649
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, PriceArchiver, { price }, "priceArchiver"),
3650
3650
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, PriceEditor, { price, propagateChanges: setPrice }, "priceEditor")
@@ -3652,7 +3652,7 @@ var PriceProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({
3652
3652
  }
3653
3653
  return response;
3654
3654
  }, "title");
3655
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.SharedProvider, { value: { breadcrumbs: breadcrumb(), title: title() }, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, PriceContext.Provider, { value, children }) });
3655
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.SharedProvider, { value: { breadcrumbs: breadcrumb(), title: title() }, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, PriceContext.Provider, { value, children }) });
3656
3656
  }, "PriceProvider");
3657
3657
  var usePriceContext = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, () => _nullishCoalesce(_react.useContext.call(void 0, PriceContext), () => ( defaultContextValue)), "usePriceContext");
3658
3658
 
@@ -3672,12 +3672,12 @@ function ProductArchiver({ product }) {
3672
3672
  const isArchived = !product.active;
3673
3673
  const scope = isArchived ? "restore" : "archive";
3674
3674
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
3675
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.Button, { variant: "outline", size: "sm", onClick: () => setOpen(true), children: [
3675
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.Button, { variant: "outline", size: "sm", onClick: () => setOpen(true), children: [
3676
3676
  isArchived ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.RotateCcwIcon, {}) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.ArchiveIcon, {}),
3677
3677
  t(`billing.admin.products.${scope}.confirm`)
3678
3678
  ] }),
3679
3679
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3680
- _chunk3YJF7QY4js.ConfirmDialog,
3680
+ _chunk2XCUAHQTjs.ConfirmDialog,
3681
3681
  {
3682
3682
  open,
3683
3683
  onOpenChange: setOpen,
@@ -3691,7 +3691,7 @@ function ProductArchiver({ product }) {
3691
3691
  if (isArchived) await restoreProduct(product.id);
3692
3692
  else await archiveProduct(product.id);
3693
3693
  } catch (error) {
3694
- _chunk3YJF7QY4js.errorToast.call(void 0, { title: t(`billing.admin.products.${scope}.title`), error });
3694
+ _chunk2XCUAHQTjs.errorToast.call(void 0, { title: t(`billing.admin.products.${scope}.title`), error });
3695
3695
  throw error;
3696
3696
  }
3697
3697
  }
@@ -3720,7 +3720,7 @@ function ProductEditorInternal({
3720
3720
  onDialogOpenChange
3721
3721
  }) {
3722
3722
  const t = _nextintl.useTranslations.call(void 0, );
3723
- const router = _chunk3D2MCVRZjs.useI18nRouter.call(void 0, );
3723
+ const router = _chunk3AR4KA5Djs.useI18nRouter.call(void 0, );
3724
3724
  const { createProduct, updateProduct } = useProductContext();
3725
3725
  const isEdit = !!product;
3726
3726
  const formSchema2 = _react.useMemo.call(void 0,
@@ -3744,13 +3744,13 @@ function ProductEditorInternal({
3744
3744
  defaultValues: getDefaultValues()
3745
3745
  });
3746
3746
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3747
- _chunk3YJF7QY4js.EditorSheet,
3747
+ _chunk2XCUAHQTjs.EditorSheet,
3748
3748
  {
3749
3749
  form,
3750
3750
  entityType: t("billing.admin.products.entity"),
3751
3751
  entityName: _optionalChain([product, 'optionalAccess', _153 => _153.name]),
3752
3752
  isEdit,
3753
- module: _chunkIV4DTYXNjs.Modules.StripeProduct,
3753
+ module: _chunkU7QVISQSjs.Modules.StripeProduct,
3754
3754
  size: "md",
3755
3755
  propagateChanges,
3756
3756
  onSuccess,
@@ -3767,7 +3767,7 @@ function ProductEditorInternal({
3767
3767
  onDialogOpenChange,
3768
3768
  children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex w-full flex-col gap-y-4", children: [
3769
3769
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3770
- _chunk3YJF7QY4js.FormInput,
3770
+ _chunk2XCUAHQTjs.FormInput,
3771
3771
  {
3772
3772
  form,
3773
3773
  id: "name",
@@ -3777,7 +3777,7 @@ function ProductEditorInternal({
3777
3777
  }
3778
3778
  ),
3779
3779
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3780
- _chunk3YJF7QY4js.FormTextarea,
3780
+ _chunk2XCUAHQTjs.FormTextarea,
3781
3781
  {
3782
3782
  form,
3783
3783
  id: "description",
@@ -3821,20 +3821,20 @@ var defaultContextValue2 = {
3821
3821
  };
3822
3822
  var ProductProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({ children, dehydratedProduct, publishChrome = true }) => {
3823
3823
  const t = _nextintl.useTranslations.call(void 0, );
3824
- const generateUrl = _chunk3YJF7QY4js.usePageUrlGenerator.call(void 0, );
3825
- const { hasRole } = _chunk3YJF7QY4js.useCurrentUserContext.call(void 0, );
3824
+ const generateUrl = _chunk2XCUAHQTjs.usePageUrlGenerator.call(void 0, );
3825
+ const { hasRole } = _chunk2XCUAHQTjs.useCurrentUserContext.call(void 0, );
3826
3826
  const [product, setProduct] = _react.useState.call(void 0,
3827
- dehydratedProduct ? _chunkIV4DTYXNjs.rehydrate.call(void 0, _chunkIV4DTYXNjs.Modules.StripeProduct, dehydratedProduct) : void 0
3827
+ dehydratedProduct ? _chunkU7QVISQSjs.rehydrate.call(void 0, _chunkU7QVISQSjs.Modules.StripeProduct, dehydratedProduct) : void 0
3828
3828
  );
3829
3829
  const [catalogueVersion, setCatalogueVersion] = _react.useState.call(void 0, 0);
3830
3830
  const refreshCatalogue = _react.useCallback.call(void 0, () => setCatalogueVersion((value2) => value2 + 1), []);
3831
3831
  const reloadProduct = _react.useCallback.call(void 0, async () => {
3832
3832
  if (!_optionalChain([product, 'optionalAccess', _154 => _154.id])) return;
3833
- setProduct(await _chunkIV4DTYXNjs.StripeProductService.getProduct({ id: product.id }));
3833
+ setProduct(await _chunkU7QVISQSjs.StripeProductService.getProduct({ id: product.id }));
3834
3834
  }, [_optionalChain([product, 'optionalAccess', _155 => _155.id])]);
3835
3835
  const createProduct = _react.useCallback.call(void 0,
3836
3836
  async (input) => {
3837
- const saved = await _chunkIV4DTYXNjs.StripeProductService.createProduct(input);
3837
+ const saved = await _chunkU7QVISQSjs.StripeProductService.createProduct(input);
3838
3838
  refreshCatalogue();
3839
3839
  return saved;
3840
3840
  },
@@ -3842,7 +3842,7 @@ var ProductProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({ ch
3842
3842
  );
3843
3843
  const updateProduct = _react.useCallback.call(void 0,
3844
3844
  async (input) => {
3845
- const saved = await _chunkIV4DTYXNjs.StripeProductService.updateProduct(input);
3845
+ const saved = await _chunkU7QVISQSjs.StripeProductService.updateProduct(input);
3846
3846
  setProduct(saved);
3847
3847
  refreshCatalogue();
3848
3848
  return saved;
@@ -3853,7 +3853,7 @@ var ProductProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({ ch
3853
3853
  async (id) => {
3854
3854
  const target = _nullishCoalesce(id, () => ( _optionalChain([product, 'optionalAccess', _156 => _156.id])));
3855
3855
  if (!target) return;
3856
- await _chunkIV4DTYXNjs.StripeProductService.archiveProduct({ id: target });
3856
+ await _chunkU7QVISQSjs.StripeProductService.archiveProduct({ id: target });
3857
3857
  await reloadProduct();
3858
3858
  refreshCatalogue();
3859
3859
  },
@@ -3863,7 +3863,7 @@ var ProductProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({ ch
3863
3863
  async (id) => {
3864
3864
  const target = _nullishCoalesce(id, () => ( _optionalChain([product, 'optionalAccess', _158 => _158.id])));
3865
3865
  if (!target) return;
3866
- await _chunkIV4DTYXNjs.StripeProductService.reactivateProduct({ id: target });
3866
+ await _chunkU7QVISQSjs.StripeProductService.reactivateProduct({ id: target });
3867
3867
  await reloadProduct();
3868
3868
  refreshCatalogue();
3869
3869
  },
@@ -3898,7 +3898,7 @@ var ProductProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({ ch
3898
3898
  {
3899
3899
  name: t("billing.admin.products.title"),
3900
3900
  // Linked only when it is NOT the current page.
3901
- ...product ? { href: generateUrl({ page: _chunkIV4DTYXNjs.Modules.StripeProduct }) } : {}
3901
+ ...product ? { href: generateUrl({ page: _chunkU7QVISQSjs.Modules.StripeProduct }) } : {}
3902
3902
  }
3903
3903
  ];
3904
3904
  if (product) items.push({ name: product.name });
@@ -3908,7 +3908,7 @@ var ProductProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({ ch
3908
3908
  const response = { type: t("billing.admin.products.title") };
3909
3909
  if (!product) return response;
3910
3910
  response.element = product.name;
3911
- if (hasRole(_chunk3D2MCVRZjs.getRoleId.call(void 0, ).Administrator)) {
3911
+ if (hasRole(_chunk3AR4KA5Djs.getRoleId.call(void 0, ).Administrator)) {
3912
3912
  response.functions = [
3913
3913
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, ProductArchiver, { product }, "productArchiver"),
3914
3914
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, ProductEditor, { product, propagateChanges: setProduct }, "productEditor")
@@ -3916,7 +3916,7 @@ var ProductProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({ ch
3916
3916
  }
3917
3917
  return response;
3918
3918
  }, "title");
3919
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.SharedProvider, { value: { breadcrumbs: breadcrumb(), title: title() }, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, ProductContext.Provider, { value, children }) });
3919
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.SharedProvider, { value: { breadcrumbs: breadcrumb(), title: title() }, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, ProductContext.Provider, { value, children }) });
3920
3920
  }, "ProductProvider");
3921
3921
  var useProductContext = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, () => _nullishCoalesce(_react.useContext.call(void 0, ProductContext), () => ( defaultContextValue2)), "useProductContext");
3922
3922
 
@@ -3925,56 +3925,56 @@ var useProductContext = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ()
3925
3925
 
3926
3926
  function PriceDetails() {
3927
3927
  const t = _nextintl.useTranslations.call(void 0, );
3928
- const generateUrl = _chunk3YJF7QY4js.usePageUrlGenerator.call(void 0, );
3928
+ const generateUrl = _chunk2XCUAHQTjs.usePageUrlGenerator.call(void 0, );
3929
3929
  const { price } = usePriceContext();
3930
3930
  if (!price) return null;
3931
3931
  const isRecurring = price.priceType === "recurring";
3932
3932
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex w-full flex-col gap-y-8", children: [
3933
3933
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex w-full flex-col gap-y-4", children: [
3934
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.SectionHeader, { children: t("billing.admin.prices.title") }),
3934
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.SectionHeader, { children: t("billing.admin.prices.title") }),
3935
3935
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "grid grid-cols-1 gap-4 md:grid-cols-2", children: [
3936
3936
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3937
- _chunk3YJF7QY4js.DetailField,
3937
+ _chunk2XCUAHQTjs.DetailField,
3938
3938
  {
3939
3939
  label: t("billing.admin.prices.fields.product"),
3940
- value: price.product ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Link, { href: generateUrl({ page: _chunkIV4DTYXNjs.Modules.StripeProduct, id: price.product.id }), children: price.product.name }) : "\u2014"
3940
+ value: price.product ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Link, { href: generateUrl({ page: _chunkU7QVISQSjs.Modules.StripeProduct, id: price.product.id }), children: price.product.name }) : "\u2014"
3941
3941
  }
3942
3942
  ),
3943
3943
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3944
- _chunk3YJF7QY4js.DetailField,
3944
+ _chunk2XCUAHQTjs.DetailField,
3945
3945
  {
3946
3946
  label: t("billing.admin.prices.fields.status"),
3947
3947
  value: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "flex flex-wrap items-center gap-1", children: [
3948
- price.active ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Badge, { variant: "softGreen", children: t("billing.admin.prices.status.active") }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Badge, { variant: "softGray", children: t("billing.admin.prices.status.archived") }),
3949
- price.isTrial && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Badge, { variant: "softBlue", children: t("billing.admin.prices.badge.trial") })
3948
+ price.active ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Badge, { variant: "softGreen", children: t("billing.admin.prices.status.active") }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Badge, { variant: "softGray", children: t("billing.admin.prices.status.archived") }),
3949
+ price.isTrial && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Badge, { variant: "softBlue", children: t("billing.admin.prices.badge.trial") })
3950
3950
  ] })
3951
3951
  }
3952
3952
  ),
3953
3953
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3954
- _chunk3YJF7QY4js.DetailField,
3954
+ _chunk2XCUAHQTjs.DetailField,
3955
3955
  {
3956
3956
  label: t("billing.admin.prices.fields.amount"),
3957
- value: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "tabular-nums", children: _chunk3YJF7QY4js.formatCurrency.call(void 0, price.unitAmount, price.currency) })
3957
+ value: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "tabular-nums", children: _chunk2XCUAHQTjs.formatCurrency.call(void 0, price.unitAmount, price.currency) })
3958
3958
  }
3959
3959
  ),
3960
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.DetailField, { label: t("billing.admin.prices.fields.currency"), value: price.currency.toUpperCase() }),
3960
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.DetailField, { label: t("billing.admin.prices.fields.currency"), value: price.currency.toUpperCase() }),
3961
3961
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3962
- _chunk3YJF7QY4js.DetailField,
3962
+ _chunk2XCUAHQTjs.DetailField,
3963
3963
  {
3964
3964
  label: t("billing.admin.prices.fields.type"),
3965
3965
  value: isRecurring ? t("billing.admin.prices.type.recurring") : t("billing.admin.prices.type.oneTime")
3966
3966
  }
3967
3967
  ),
3968
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.DetailField, { label: t("billing.admin.prices.fields.billing"), value: _chunk3YJF7QY4js.formatInterval.call(void 0, price) }),
3968
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.DetailField, { label: t("billing.admin.prices.fields.billing"), value: _chunk2XCUAHQTjs.formatInterval.call(void 0, price) }),
3969
3969
  isRecurring && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3970
- _chunk3YJF7QY4js.DetailField,
3970
+ _chunk2XCUAHQTjs.DetailField,
3971
3971
  {
3972
3972
  label: t("billing.admin.prices.fields.intervalCount"),
3973
3973
  value: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "tabular-nums", children: _nullishCoalesce(_optionalChain([price, 'access', _160 => _160.recurring, 'optionalAccess', _161 => _161.intervalCount]), () => ( 1)) })
3974
3974
  }
3975
3975
  ),
3976
3976
  isRecurring && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3977
- _chunk3YJF7QY4js.DetailField,
3977
+ _chunk2XCUAHQTjs.DetailField,
3978
3978
  {
3979
3979
  label: t("billing.admin.prices.fields.usageType"),
3980
3980
  value: _optionalChain([price, 'access', _162 => _162.recurring, 'optionalAccess', _163 => _163.usageType]) === "metered" ? t("billing.admin.prices.usage.metered") : t("billing.admin.prices.usage.licensed")
@@ -3983,24 +3983,24 @@ function PriceDetails() {
3983
3983
  ] })
3984
3984
  ] }),
3985
3985
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex w-full flex-col gap-y-4", children: [
3986
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.SectionHeader, { children: t("billing.admin.prices.fields.platformFeatures") }),
3986
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.SectionHeader, { children: t("billing.admin.prices.fields.platformFeatures") }),
3987
3987
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "grid grid-cols-1 gap-4 md:grid-cols-2", children: [
3988
3988
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3989
- _chunk3YJF7QY4js.DetailField,
3989
+ _chunk2XCUAHQTjs.DetailField,
3990
3990
  {
3991
3991
  label: t("billing.admin.prices.fields.token"),
3992
3992
  value: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "tabular-nums", children: _nullishCoalesce(price.token, () => ( "\u2014")) })
3993
3993
  }
3994
3994
  ),
3995
3995
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3996
- _chunk3YJF7QY4js.DetailField,
3996
+ _chunk2XCUAHQTjs.DetailField,
3997
3997
  {
3998
3998
  label: t("billing.admin.prices.fields.stripeId"),
3999
3999
  value: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "tabular-nums", children: price.stripePriceId })
4000
4000
  }
4001
4001
  ),
4002
4002
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4003
- _chunk3YJF7QY4js.DetailField,
4003
+ _chunk2XCUAHQTjs.DetailField,
4004
4004
  {
4005
4005
  label: t("billing.admin.prices.fields.description"),
4006
4006
  value: _nullishCoalesce(price.description, () => ( "\u2014")),
@@ -4008,7 +4008,7 @@ function PriceDetails() {
4008
4008
  }
4009
4009
  ),
4010
4010
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4011
- _chunk3YJF7QY4js.DetailField,
4011
+ _chunk2XCUAHQTjs.DetailField,
4012
4012
  {
4013
4013
  label: t("billing.admin.prices.fields.features"),
4014
4014
  className: "md:col-span-2",
@@ -4016,11 +4016,11 @@ function PriceDetails() {
4016
4016
  }
4017
4017
  ),
4018
4018
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4019
- _chunk3YJF7QY4js.DetailField,
4019
+ _chunk2XCUAHQTjs.DetailField,
4020
4020
  {
4021
4021
  label: t("billing.admin.prices.fields.platformFeatures"),
4022
4022
  className: "md:col-span-2",
4023
- value: price.priceFeatures.length > 0 ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "flex flex-wrap items-center gap-1", children: price.priceFeatures.map((feature) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Badge, { variant: "softGray", children: feature.name }, feature.id)) }) : "\u2014"
4023
+ value: price.priceFeatures.length > 0 ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "flex flex-wrap items-center gap-1", children: price.priceFeatures.map((feature) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Badge, { variant: "softGray", children: feature.name }, feature.id)) }) : "\u2014"
4024
4024
  }
4025
4025
  )
4026
4026
  ] })
@@ -4034,7 +4034,7 @@ _chunk7QVYU63Ejs.__name.call(void 0, PriceDetails, "PriceDetails");
4034
4034
  function PriceContainer() {
4035
4035
  const { price } = usePriceContext();
4036
4036
  if (!price) return null;
4037
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.RoundPageContainer, { module: _chunkIV4DTYXNjs.Modules.StripePrice, id: price.id, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, PriceDetails, {}) });
4037
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.RoundPageContainer, { module: _chunkU7QVISQSjs.Modules.StripePrice, id: price.id, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, PriceDetails, {}) });
4038
4038
  }
4039
4039
  _chunk7QVYU63Ejs.__name.call(void 0, PriceContainer, "PriceContainer");
4040
4040
 
@@ -4159,10 +4159,10 @@ function PricesList({ productId, fullWidth }) {
4159
4159
  const importInputRef = _react.useRef.call(void 0, null);
4160
4160
  const [seed, setSeed] = _react.useState.call(void 0, void 0);
4161
4161
  const [seedNonce, setSeedNonce] = _react.useState.call(void 0, 0);
4162
- const data = _chunk3YJF7QY4js.useDataListRetriever.call(void 0, {
4163
- retriever: /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (params) => _chunkIV4DTYXNjs.StripePriceService.listPrices({ ...params, productId }), "retriever"),
4162
+ const data = _chunk2XCUAHQTjs.useDataListRetriever.call(void 0, {
4163
+ retriever: /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (params) => _chunkU7QVISQSjs.StripePriceService.listPrices({ ...params, productId }), "retriever"),
4164
4164
  retrieverParams: {},
4165
- module: _chunkIV4DTYXNjs.Modules.StripePrice
4165
+ module: _chunkU7QVISQSjs.Modules.StripePrice
4166
4166
  });
4167
4167
  _react.useEffect.call(void 0, () => {
4168
4168
  if (priceVersion > 0) void data.refresh();
@@ -4197,7 +4197,7 @@ function PricesList({ productId, fullWidth }) {
4197
4197
  openSeededEditor(transfer.price);
4198
4198
  } catch (error) {
4199
4199
  console.error("[PricesList] price import failed", error);
4200
- _chunk3YJF7QY4js.errorToast.call(void 0, {
4200
+ _chunk2XCUAHQTjs.errorToast.call(void 0, {
4201
4201
  title: t("billing.admin.prices.import.errors.title"),
4202
4202
  error: t("billing.admin.prices.import.errors.invalid")
4203
4203
  });
@@ -4216,7 +4216,7 @@ function PricesList({ productId, fullWidth }) {
4216
4216
  "create-price"
4217
4217
  ),
4218
4218
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _react.Fragment, { children: [
4219
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3YJF7QY4js.Button, { variant: "outline", size: "sm", type: "button", onClick: () => _optionalChain([importInputRef, 'access', _178 => _178.current, 'optionalAccess', _179 => _179.click, 'call', _180 => _180()]), children: [
4219
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk2XCUAHQTjs.Button, { variant: "outline", size: "sm", type: "button", onClick: () => _optionalChain([importInputRef, 'access', _178 => _178.current, 'optionalAccess', _179 => _179.click, 'call', _180 => _180()]), children: [
4220
4220
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.UploadIcon, {}),
4221
4221
  t("billing.admin.prices.actions.import")
4222
4222
  ] }),
@@ -4234,7 +4234,7 @@ function PricesList({ productId, fullWidth }) {
4234
4234
  ];
4235
4235
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
4236
4236
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4237
- _chunk3YJF7QY4js.ContentListTable,
4237
+ _chunk2XCUAHQTjs.ContentListTable,
4238
4238
  {
4239
4239
  data,
4240
4240
  fields: [
@@ -4245,13 +4245,13 @@ function PricesList({ productId, fullWidth }) {
4245
4245
  "status" /* status */,
4246
4246
  "actions" /* actions */
4247
4247
  ],
4248
- tableGeneratorType: _chunkIV4DTYXNjs.Modules.StripePrice,
4248
+ tableGeneratorType: _chunkU7QVISQSjs.Modules.StripePrice,
4249
4249
  functions,
4250
4250
  context: tableContext,
4251
4251
  fullWidth,
4252
4252
  title: t("billing.admin.prices.title"),
4253
4253
  emptyState: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4254
- _chunk3YJF7QY4js.EmptyState,
4254
+ _chunk2XCUAHQTjs.EmptyState,
4255
4255
  {
4256
4256
  icon: _lucidereact.DollarSignIcon,
4257
4257
  title: t("billing.admin.prices.empty.title"),
@@ -4291,18 +4291,18 @@ function ProductDetails() {
4291
4291
  const { product } = useProductContext();
4292
4292
  if (!product) return null;
4293
4293
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex w-full flex-col gap-y-4", children: [
4294
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.SectionHeader, { children: t("billing.admin.products.tabs.details") }),
4294
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.SectionHeader, { children: t("billing.admin.products.tabs.details") }),
4295
4295
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "grid grid-cols-1 gap-4 md:grid-cols-2", children: [
4296
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.DetailField, { label: t("billing.admin.products.fields.name"), value: product.name }),
4296
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.DetailField, { label: t("billing.admin.products.fields.name"), value: product.name }),
4297
4297
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4298
- _chunk3YJF7QY4js.DetailField,
4298
+ _chunk2XCUAHQTjs.DetailField,
4299
4299
  {
4300
4300
  label: t("billing.admin.products.fields.status"),
4301
- value: product.active ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Badge, { variant: "softGreen", children: t("billing.admin.products.status.active") }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.Badge, { variant: "softGray", children: t("billing.admin.products.status.archived") })
4301
+ value: product.active ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Badge, { variant: "softGreen", children: t("billing.admin.products.status.active") }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.Badge, { variant: "softGray", children: t("billing.admin.products.status.archived") })
4302
4302
  }
4303
4303
  ),
4304
4304
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4305
- _chunk3YJF7QY4js.DetailField,
4305
+ _chunk2XCUAHQTjs.DetailField,
4306
4306
  {
4307
4307
  label: t("billing.admin.products.fields.description"),
4308
4308
  value: _nullishCoalesce(product.description, () => ( "\u2014")),
@@ -4310,14 +4310,14 @@ function ProductDetails() {
4310
4310
  }
4311
4311
  ),
4312
4312
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4313
- _chunk3YJF7QY4js.DetailField,
4313
+ _chunk2XCUAHQTjs.DetailField,
4314
4314
  {
4315
4315
  label: t("billing.admin.products.fields.prices"),
4316
4316
  value: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "tabular-nums", children: product.stripePrices.length })
4317
4317
  }
4318
4318
  ),
4319
4319
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4320
- _chunk3YJF7QY4js.DetailField,
4320
+ _chunk2XCUAHQTjs.DetailField,
4321
4321
  {
4322
4322
  label: t("billing.admin.products.fields.stripeId"),
4323
4323
  value: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "tabular-nums", children: product.stripeProductId })
@@ -4335,9 +4335,9 @@ function ProductContainer() {
4335
4335
  const { product } = useProductContext();
4336
4336
  if (!product) return null;
4337
4337
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4338
- _chunk3YJF7QY4js.RoundPageContainer,
4338
+ _chunk2XCUAHQTjs.RoundPageContainer,
4339
4339
  {
4340
- module: _chunkIV4DTYXNjs.Modules.StripeProduct,
4340
+ module: _chunkU7QVISQSjs.Modules.StripeProduct,
4341
4341
  id: product.id,
4342
4342
  tabs: [
4343
4343
  {
@@ -4346,7 +4346,7 @@ function ProductContainer() {
4346
4346
  content: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, ProductDetails, {})
4347
4347
  },
4348
4348
  {
4349
- key: _chunkIV4DTYXNjs.Modules.StripePrice,
4349
+ key: _chunkU7QVISQSjs.Modules.StripePrice,
4350
4350
  label: t("billing.admin.prices.title"),
4351
4351
  // publishChrome={false}: SharedProvider REPLACES its value for the
4352
4352
  // subtree (SharedContext.tsx:35-37), so a nested provider publishing
@@ -4370,26 +4370,26 @@ _chunk7QVYU63Ejs.__name.call(void 0, ProductContainer, "ProductContainer");
4370
4370
  function ProductsList({ fullWidth } = {}) {
4371
4371
  const t = _nextintl.useTranslations.call(void 0, );
4372
4372
  const { catalogueVersion } = useProductContext();
4373
- const data = _chunk3YJF7QY4js.useDataListRetriever.call(void 0, {
4374
- retriever: /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (params) => _chunkIV4DTYXNjs.StripeProductService.listProducts(params), "retriever"),
4373
+ const data = _chunk2XCUAHQTjs.useDataListRetriever.call(void 0, {
4374
+ retriever: /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (params) => _chunkU7QVISQSjs.StripeProductService.listProducts(params), "retriever"),
4375
4375
  retrieverParams: {},
4376
- module: _chunkIV4DTYXNjs.Modules.StripeProduct
4376
+ module: _chunkU7QVISQSjs.Modules.StripeProduct
4377
4377
  });
4378
4378
  _react.useEffect.call(void 0, () => {
4379
4379
  if (catalogueVersion > 0) void data.refresh();
4380
4380
  }, [catalogueVersion]);
4381
4381
  const functions = [/* @__PURE__ */ _jsxruntime.jsx.call(void 0, ProductEditor, {}, "create-product")];
4382
4382
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4383
- _chunk3YJF7QY4js.ContentListTable,
4383
+ _chunk2XCUAHQTjs.ContentListTable,
4384
4384
  {
4385
4385
  data,
4386
4386
  fields: ["name" /* name */, "status" /* status */, "prices" /* prices */],
4387
- tableGeneratorType: _chunkIV4DTYXNjs.Modules.StripeProduct,
4387
+ tableGeneratorType: _chunkU7QVISQSjs.Modules.StripeProduct,
4388
4388
  functions,
4389
4389
  fullWidth,
4390
4390
  title: t("billing.admin.products.title"),
4391
4391
  emptyState: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4392
- _chunk3YJF7QY4js.EmptyState,
4392
+ _chunk2XCUAHQTjs.EmptyState,
4393
4393
  {
4394
4394
  icon: _lucidereact.PackageIcon,
4395
4395
  title: t("billing.admin.products.empty.title"),
@@ -4404,7 +4404,7 @@ _chunk7QVYU63Ejs.__name.call(void 0, ProductsList, "ProductsList");
4404
4404
  // src/features/billing/stripe-product/components/containers/ProductsListContainer.tsx
4405
4405
 
4406
4406
  function ProductsListContainer() {
4407
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, ProductProvider, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3YJF7QY4js.RoundPageContainer, { module: _chunkIV4DTYXNjs.Modules.StripeProduct, fullWidth: true, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, ProductsList, { fullWidth: true }) }) });
4407
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, ProductProvider, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCUAHQTjs.RoundPageContainer, { module: _chunkU7QVISQSjs.Modules.StripeProduct, fullWidth: true, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, ProductsList, { fullWidth: true }) }) });
4408
4408
  }
4409
4409
  _chunk7QVYU63Ejs.__name.call(void 0, ProductsListContainer, "ProductsListContainer");
4410
4410
 
@@ -4462,5 +4462,10 @@ _chunk7QVYU63Ejs.__name.call(void 0, ProductsListContainer, "ProductsListContain
4462
4462
 
4463
4463
 
4464
4464
 
4465
- exports.BillingAlertBanner = BillingAlertBanner; exports.BillingDashboardContainer = BillingDashboardContainer; exports.BillingDetailModal = BillingDetailModal; exports.BillingUsageSummaryCard = BillingUsageSummaryCard; exports.CancelSubscriptionDialog = CancelSubscriptionDialog; exports.CustomerInfoCard = CustomerInfoCard; exports.IntervalToggle = IntervalToggle; exports.InvoiceDetails = InvoiceDetails; exports.InvoiceStatusBadge = InvoiceStatusBadge; exports.InvoicesContainer = InvoicesContainer; exports.InvoicesList = InvoicesList; exports.InvoicesSummaryCard = InvoicesSummaryCard; exports.PaymentMethodCard = PaymentMethodCard; exports.PaymentMethodEditor = PaymentMethodEditor; exports.PaymentMethodForm = PaymentMethodForm; exports.PaymentMethodSummaryCard = PaymentMethodSummaryCard; exports.PaymentMethodsContainer = PaymentMethodsContainer; exports.PaymentMethodsList = PaymentMethodsList; exports.PriceArchiver = PriceArchiver; exports.PriceContainer = PriceContainer; exports.PriceDetails = PriceDetails; exports.PriceEditor = PriceEditor; exports.PriceProvider = PriceProvider; exports.PricesList = PricesList; exports.PricingCard = PricingCard; exports.ProductArchiver = ProductArchiver; exports.ProductContainer = ProductContainer; exports.ProductDetails = ProductDetails; exports.ProductEditor = ProductEditor; exports.ProductPricingList = ProductPricingList; exports.ProductPricingRow = ProductPricingRow; exports.ProductProvider = ProductProvider; exports.ProductsList = ProductsList; exports.ProductsListContainer = ProductsListContainer; exports.PromoCodeInput = PromoCodeInput; exports.ProrationPreview = ProrationPreview; exports.StripeProvider = StripeProvider; exports.SubscriptionConfirmation = SubscriptionConfirmation; exports.SubscriptionDetails = SubscriptionDetails; exports.SubscriptionStatusBadge = SubscriptionStatusBadge; exports.SubscriptionSummaryCard = SubscriptionSummaryCard; exports.SubscriptionsContainer = SubscriptionsContainer; exports.SubscriptionsList = SubscriptionsList; exports.UsageContainer = UsageContainer; exports.UsageHistoryTable = UsageHistoryTable; exports.UsageSummaryCard = UsageSummaryCard; exports.UsageSummaryCards = UsageSummaryCards; exports.formatCurrency = _chunk3YJF7QY4js.formatCurrency; exports.formatDate = formatDate3; exports.formatInterval = _chunk3YJF7QY4js.formatInterval; exports.isStripeConfigured = isStripeConfigured; exports.priceLabel = priceLabel; exports.usePriceContext = usePriceContext; exports.useProductContext = useProductContext;
4465
+
4466
+
4467
+
4468
+
4469
+
4470
+ exports.BillingAlertBanner = BillingAlertBanner; exports.BillingDashboardContainer = BillingDashboardContainer; exports.BillingDetailModal = BillingDetailModal; exports.BillingUsageSummaryCard = BillingUsageSummaryCard; exports.CancelSubscriptionDialog = CancelSubscriptionDialog; exports.CustomerInfoCard = CustomerInfoCard; exports.IntervalToggle = IntervalToggle; exports.InvoiceDetails = InvoiceDetails; exports.InvoiceStatusBadge = InvoiceStatusBadge; exports.InvoicesContainer = InvoicesContainer; exports.InvoicesList = InvoicesList; exports.InvoicesSummaryCard = InvoicesSummaryCard; exports.PaymentMethodCard = PaymentMethodCard; exports.PaymentMethodEditor = PaymentMethodEditor; exports.PaymentMethodForm = PaymentMethodForm; exports.PaymentMethodSummaryCard = PaymentMethodSummaryCard; exports.PaymentMethodsContainer = PaymentMethodsContainer; exports.PaymentMethodsList = PaymentMethodsList; exports.PriceArchiver = PriceArchiver; exports.PriceContainer = PriceContainer; exports.PriceDetails = PriceDetails; exports.PriceEditor = PriceEditor; exports.PriceProvider = PriceProvider; exports.PricesList = PricesList; exports.PricingCard = PricingCard; exports.ProductArchiver = ProductArchiver; exports.ProductContainer = ProductContainer; exports.ProductDetails = ProductDetails; exports.ProductEditor = ProductEditor; exports.ProductPricingList = ProductPricingList; exports.ProductPricingRow = ProductPricingRow; exports.ProductProvider = ProductProvider; exports.ProductsList = ProductsList; exports.ProductsListContainer = ProductsListContainer; exports.PromoCodeInput = PromoCodeInput; exports.ProrationPreview = ProrationPreview; exports.StripeProvider = StripeProvider; exports.SubscriptionConfirmation = SubscriptionConfirmation; exports.SubscriptionDetails = SubscriptionDetails; exports.SubscriptionStatusBadge = SubscriptionStatusBadge; exports.SubscriptionSummaryCard = SubscriptionSummaryCard; exports.SubscriptionWizard = SubscriptionWizard; exports.SubscriptionsContainer = SubscriptionsContainer; exports.SubscriptionsList = SubscriptionsList; exports.UsageContainer = UsageContainer; exports.UsageHistoryTable = UsageHistoryTable; exports.UsageSummaryCard = UsageSummaryCard; exports.UsageSummaryCards = UsageSummaryCards; exports.WizardProgressIndicator = WizardProgressIndicator; exports.WizardStepPaymentMethod = WizardStepPaymentMethod; exports.WizardStepPlanSelection = WizardStepPlanSelection; exports.WizardStepReview = WizardStepReview; exports.formatCurrency = _chunk2XCUAHQTjs.formatCurrency; exports.formatDate = formatDate3; exports.formatInterval = _chunk2XCUAHQTjs.formatInterval; exports.isStripeConfigured = isStripeConfigured; exports.priceLabel = priceLabel; exports.usePriceContext = usePriceContext; exports.useProductContext = useProductContext;
4466
4471
  //# sourceMappingURL=index.js.map