@carlonicora/nextjs-jsonapi 5.1.3 → 5.2.0

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 (103) hide show
  1. package/dist/{BlockNoteEditor-66FJUDL4.mjs → BlockNoteEditor-2QJVK2HH.mjs} +4 -4
  2. package/dist/{BlockNoteEditor-KO6YFNIU.js → BlockNoteEditor-EGY4ZAAM.js} +19 -19
  3. package/dist/{BlockNoteEditor-KO6YFNIU.js.map → BlockNoteEditor-EGY4ZAAM.js.map} +1 -1
  4. package/dist/{BlockNoteViewer-SUK7OMWH.mjs → BlockNoteViewer-6BQXJ4TB.mjs} +2 -2
  5. package/dist/{BlockNoteViewer-LK22AE7Z.js → BlockNoteViewer-I2MMFH3S.js} +3 -3
  6. package/dist/{BlockNoteViewer-LK22AE7Z.js.map → BlockNoteViewer-I2MMFH3S.js.map} +1 -1
  7. package/dist/auth.interface-CSzJ1oP1.d.ts +64 -0
  8. package/dist/auth.interface-DD4uQv2K.d.mts +64 -0
  9. package/dist/billing/index.js +441 -441
  10. package/dist/billing/index.mjs +3 -3
  11. package/dist/{chunk-5JADF7ZA.mjs → chunk-2Z3ZCYXX.mjs} +171 -95
  12. package/dist/chunk-2Z3ZCYXX.mjs.map +1 -0
  13. package/dist/{chunk-SZQNUGDG.js → chunk-3VEQ5JZJ.js} +1005 -929
  14. package/dist/chunk-3VEQ5JZJ.js.map +1 -0
  15. package/dist/{chunk-TO6IYGML.js → chunk-75MLT74B.js} +126 -8
  16. package/dist/chunk-75MLT74B.js.map +1 -0
  17. package/dist/{chunk-67NJY7SM.js → chunk-EXICQC4A.js} +3 -3
  18. package/dist/{chunk-67NJY7SM.js.map → chunk-EXICQC4A.js.map} +1 -1
  19. package/dist/{chunk-OCJEXAGE.mjs → chunk-HNOWSFM5.mjs} +55 -4
  20. package/dist/chunk-HNOWSFM5.mjs.map +1 -0
  21. package/dist/{chunk-OKUGTXDN.mjs → chunk-JEZQTZQ4.mjs} +121 -3
  22. package/dist/chunk-JEZQTZQ4.mjs.map +1 -0
  23. package/dist/{chunk-KL7CAQP3.mjs → chunk-NPKFMRH5.mjs} +2 -2
  24. package/dist/{chunk-VVJDWQEI.js → chunk-S5MQDWWC.js} +55 -4
  25. package/dist/chunk-S5MQDWWC.js.map +1 -0
  26. package/dist/{chunk-XCHXOCEJ.js → chunk-THKYH65N.js} +4 -4
  27. package/dist/{chunk-XCHXOCEJ.js.map → chunk-THKYH65N.js.map} +1 -1
  28. package/dist/{chunk-XLVRAHUK.mjs → chunk-YMUPTXOT.mjs} +2 -2
  29. package/dist/client/index.js +4 -4
  30. package/dist/client/index.mjs +3 -3
  31. package/dist/components/index.d.mts +17 -3
  32. package/dist/components/index.d.ts +17 -3
  33. package/dist/components/index.js +6 -4
  34. package/dist/components/index.js.map +1 -1
  35. package/dist/components/index.mjs +5 -3
  36. package/dist/contexts/index.js +4 -4
  37. package/dist/contexts/index.mjs +3 -3
  38. package/dist/core/index.d.mts +27 -7
  39. package/dist/core/index.d.ts +27 -7
  40. package/dist/core/index.js +2 -2
  41. package/dist/core/index.mjs +1 -1
  42. package/dist/features/analytics/index.js +122 -122
  43. package/dist/features/analytics/index.mjs +4 -4
  44. package/dist/features/analytics/server.js +4 -4
  45. package/dist/features/analytics/server.mjs +2 -2
  46. package/dist/features/help/index.js +37 -37
  47. package/dist/features/help/index.mjs +3 -3
  48. package/dist/features/tokenusage/index.js +125 -125
  49. package/dist/features/tokenusage/index.mjs +4 -4
  50. package/dist/index.d.mts +3 -3
  51. package/dist/index.d.ts +3 -3
  52. package/dist/index.js +13 -3
  53. package/dist/index.js.map +1 -1
  54. package/dist/index.mjs +13 -3
  55. package/dist/{s3.service-C-4YpEMu.d.ts → s3.service-CY-jgOAM.d.ts} +1 -1
  56. package/dist/{s3.service-dVj-nxMl.d.mts → s3.service-Sri0QP7Z.d.mts} +1 -1
  57. package/dist/server/index.d.mts +2 -2
  58. package/dist/server/index.d.ts +2 -2
  59. package/dist/server/index.js +3 -3
  60. package/dist/server/index.mjs +2 -2
  61. package/dist/{waitlist.config-kPfjImle.d.mts → waitlist.config-Cagmgm7-.d.mts} +7 -0
  62. package/dist/{waitlist.config-kPfjImle.d.ts → waitlist.config-Cagmgm7-.d.ts} +7 -0
  63. package/messages/en.json +15 -1
  64. package/messages/it.json +15 -1
  65. package/package.json +1 -1
  66. package/scripts/validate-messages.mjs +1 -0
  67. package/src/components/index.ts +1 -0
  68. package/src/features/auth/components/buttons/GoogleSignInButton.tsx +8 -4
  69. package/src/features/auth/components/forms/Register.tsx +20 -8
  70. package/src/features/auth/data/auth.interface.ts +2 -0
  71. package/src/features/auth/data/auth.ts +10 -0
  72. package/src/features/signup-source/SignupSourceCapture.tsx +27 -0
  73. package/src/features/signup-source/__tests__/signup-source.spec.ts +161 -0
  74. package/src/features/signup-source/index.ts +9 -0
  75. package/src/features/signup-source/signup-source.ts +135 -0
  76. package/src/features/waitlist/components/forms/WaitlistForm.tsx +2 -0
  77. package/src/features/waitlist/components/forms/WaitlistQuestionnaireRenderer.tsx +15 -13
  78. package/src/features/waitlist/components/lists/WaitlistList.tsx +60 -22
  79. package/src/features/waitlist/components/sections/WaitlistHeroSection.tsx +6 -5
  80. package/src/features/waitlist/config/waitlist.config.ts +23 -0
  81. package/src/features/waitlist/data/Waitlist.ts +51 -3
  82. package/src/features/waitlist/data/WaitlistInterface.ts +9 -1
  83. package/src/features/waitlist/data/WaitlistService.ts +3 -2
  84. package/src/features/waitlist/data/__tests__/Waitlist.spec.ts +82 -0
  85. package/src/features/waitlist/data/__tests__/WaitlistService.spec.ts +48 -0
  86. package/src/features/waitlist/data/waitlist.fields.ts +1 -0
  87. package/src/features/waitlist/hooks/__tests__/formatSignupSource.spec.ts +24 -0
  88. package/src/features/waitlist/hooks/formatSignupSource.ts +14 -0
  89. package/src/features/waitlist/hooks/useWaitlistTableStructure.tsx +26 -14
  90. package/src/hooks/__tests__/usePageTracker.spec.tsx +16 -10
  91. package/src/index.ts +3 -0
  92. package/dist/auth.interface-CeFCz9NU.d.mts +0 -34
  93. package/dist/auth.interface-D1R7VVky.d.ts +0 -34
  94. package/dist/chunk-5JADF7ZA.mjs.map +0 -1
  95. package/dist/chunk-OCJEXAGE.mjs.map +0 -1
  96. package/dist/chunk-OKUGTXDN.mjs.map +0 -1
  97. package/dist/chunk-SZQNUGDG.js.map +0 -1
  98. package/dist/chunk-TO6IYGML.js.map +0 -1
  99. package/dist/chunk-VVJDWQEI.js.map +0 -1
  100. /package/dist/{BlockNoteEditor-66FJUDL4.mjs.map → BlockNoteEditor-2QJVK2HH.mjs.map} +0 -0
  101. /package/dist/{BlockNoteViewer-SUK7OMWH.mjs.map → BlockNoteViewer-6BQXJ4TB.mjs.map} +0 -0
  102. /package/dist/{chunk-KL7CAQP3.mjs.map → chunk-NPKFMRH5.mjs.map} +0 -0
  103. /package/dist/{chunk-XLVRAHUK.mjs.map → chunk-YMUPTXOT.mjs.map} +0 -0
@@ -65,10 +65,10 @@
65
65
 
66
66
 
67
67
 
68
- var _chunkSZQNUGDGjs = require('../chunk-SZQNUGDG.js');
68
+ var _chunk3VEQ5JZJjs = require('../chunk-3VEQ5JZJ.js');
69
69
 
70
70
 
71
- var _chunkTO6IYGMLjs = require('../chunk-TO6IYGML.js');
71
+ var _chunk75MLT74Bjs = require('../chunk-75MLT74B.js');
72
72
 
73
73
 
74
74
  var _chunkG4JR3SFVjs = require('../chunk-G4JR3SFV.js');
@@ -89,7 +89,7 @@ var _chunkG4JR3SFVjs = require('../chunk-G4JR3SFV.js');
89
89
 
90
90
 
91
91
 
92
- var _chunkVVJDWQEIjs = require('../chunk-VVJDWQEI.js');
92
+ var _chunkS5MQDWWCjs = require('../chunk-S5MQDWWC.js');
93
93
  require('../chunk-LXKSUWAV.js');
94
94
  require('../chunk-JTPRJNT2.js');
95
95
  require('../chunk-GHE4VT2R.js');
@@ -102,7 +102,7 @@ var _chunk7QVYU63Ejs = require('../chunk-7QVYU63E.js');
102
102
  var _nextintl = require('next-intl');
103
103
  var _lucidereact = require('lucide-react');
104
104
  var _jsxruntime = require('react/jsx-runtime');
105
- var SUBSCRIPTION_STATUSES = Object.values(_chunkVVJDWQEIjs.SubscriptionStatus);
105
+ var SUBSCRIPTION_STATUSES = Object.values(_chunkS5MQDWWCjs.SubscriptionStatus);
106
106
  function getStatusBadgeVariant(status) {
107
107
  switch (status) {
108
108
  case "active" /* ACTIVE */:
@@ -134,43 +134,43 @@ function SubscriptionSummaryCard({
134
134
  onManageClick
135
135
  }) {
136
136
  const t = _nextintl.useTranslations.call(void 0, );
137
- const fmt = _chunkSZQNUGDGjs.useBillingFormatOptions.call(void 0, );
137
+ const fmt = _chunk3VEQ5JZJjs.useBillingFormatOptions.call(void 0, );
138
138
  if (loading) {
139
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.Card, { children: [
140
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
141
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.CardTitle, { children: t("billing.ui.subscriptions.title") }),
139
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.Card, { children: [
140
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
141
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.CardTitle, { children: t("billing.ui.subscriptions.title") }),
142
142
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.CreditCard, { className: "h-4 w-4 text-muted-foreground" })
143
143
  ] }),
144
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.CardContent, { children: [
145
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Skeleton, { className: "h-6 w-32 mb-2" }),
146
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Skeleton, { className: "h-4 w-24 mb-1" }),
147
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Skeleton, { className: "h-4 w-40" })
144
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.CardContent, { children: [
145
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Skeleton, { className: "h-6 w-32 mb-2" }),
146
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Skeleton, { className: "h-4 w-24 mb-1" }),
147
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Skeleton, { className: "h-4 w-40" })
148
148
  ] })
149
149
  ] });
150
150
  }
151
151
  if (error) {
152
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.Card, { children: [
153
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
154
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.CardTitle, { children: t("billing.ui.subscriptions.title") }),
152
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.Card, { children: [
153
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
154
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.CardTitle, { children: t("billing.ui.subscriptions.title") }),
155
155
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.CreditCard, { className: "h-4 w-4 text-muted-foreground" })
156
156
  ] }),
157
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.CardContent, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-destructive text-xs/relaxed", children: error }) })
157
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.CardContent, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-destructive text-xs/relaxed", children: error }) })
158
158
  ] });
159
159
  }
160
160
  const activeSubscriptions = subscriptions.filter(
161
161
  (sub) => sub.status === "active" /* ACTIVE */ || sub.status === "trialing" /* TRIALING */
162
162
  );
163
163
  const primarySubscription = activeSubscriptions[0];
164
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.Card, { className: "cursor-pointer hover:bg-accent/50 transition-colors", onClick: onManageClick, children: [
165
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
166
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.CardTitle, { children: t("billing.ui.subscriptions.title") }),
164
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.Card, { className: "cursor-pointer hover:bg-accent/50 transition-colors", onClick: onManageClick, children: [
165
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
166
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.CardTitle, { children: t("billing.ui.subscriptions.title") }),
167
167
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.CreditCard, { className: "h-4 w-4 text-muted-foreground" })
168
168
  ] }),
169
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.CardContent, { children: subscriptions.length === 0 ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2", children: [
169
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.CardContent, { children: subscriptions.length === 0 ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2", children: [
170
170
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-xl font-bold text-muted-foreground", children: t("billing.ui.cards.subscriptions.empty_title") }),
171
171
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-xs text-muted-foreground", children: t("billing.ui.cards.subscriptions.empty_description") }),
172
172
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
173
- _chunkSZQNUGDGjs.Button,
173
+ _chunk3VEQ5JZJjs.Button,
174
174
  {
175
175
  variant: "outline",
176
176
  size: "sm",
@@ -189,7 +189,7 @@ function SubscriptionSummaryCard({
189
189
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center gap-2", children: [
190
190
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-xl font-bold", children: formatPlanName(primarySubscription, t("billing.ui.cards.subscriptions.fallback_name")) }),
191
191
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
192
- _chunkSZQNUGDGjs.Badge,
192
+ _chunk3VEQ5JZJjs.Badge,
193
193
  {
194
194
  variant: primarySubscription.cancelAtPeriodEnd ? "secondary" : getStatusBadgeVariant(primarySubscription.status),
195
195
  children: primarySubscription.cancelAtPeriodEnd ? t("billing.ui.cards.subscriptions.canceling") : SUBSCRIPTION_STATUSES.includes(primarySubscription.status) ? t(`billing.ui.subscription_status.${primarySubscription.status}`) : primarySubscription.status
@@ -197,11 +197,11 @@ function SubscriptionSummaryCard({
197
197
  )
198
198
  ] }),
199
199
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-xs text-muted-foreground", children: !_optionalChain([primarySubscription, 'access', _8 => _8.price, 'optionalAccess', _9 => _9.isTrial]) ? t("billing.ui.cards.subscriptions.ends_on", {
200
- date: _chunkSZQNUGDGjs.formatDate.call(void 0, primarySubscription.currentPeriodEnd, fmt)
200
+ date: _chunk3VEQ5JZJjs.formatDate.call(void 0, primarySubscription.currentPeriodEnd, fmt)
201
201
  }) : primarySubscription.cancelAtPeriodEnd ? t("billing.ui.cards.subscriptions.cancels_on", {
202
- date: _chunkSZQNUGDGjs.formatDate.call(void 0, primarySubscription.currentPeriodEnd, fmt)
202
+ date: _chunk3VEQ5JZJjs.formatDate.call(void 0, primarySubscription.currentPeriodEnd, fmt)
203
203
  }) : t("billing.ui.cards.subscriptions.renews_on", {
204
- date: _chunkSZQNUGDGjs.formatDate.call(void 0, primarySubscription.currentPeriodEnd, fmt)
204
+ date: _chunk3VEQ5JZJjs.formatDate.call(void 0, primarySubscription.currentPeriodEnd, fmt)
205
205
  }) }),
206
206
  activeSubscriptions.length > 1 && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-xs text-muted-foreground", children: t("billing.ui.cards.subscriptions.more", { count: activeSubscriptions.length - 1 }) })
207
207
  ] }) : null })
@@ -235,37 +235,37 @@ function PaymentMethodSummaryCard({
235
235
  }) {
236
236
  const t = _nextintl.useTranslations.call(void 0, );
237
237
  if (loading) {
238
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.Card, { children: [
239
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
240
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.CardTitle, { children: t("billing.ui.payment_method.title") }),
238
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.Card, { children: [
239
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
240
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.CardTitle, { children: t("billing.ui.payment_method.title") }),
241
241
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.Wallet, { className: "h-4 w-4 text-muted-foreground" })
242
242
  ] }),
243
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.CardContent, { children: [
244
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Skeleton, { className: "h-6 w-32 mb-2" }),
245
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Skeleton, { className: "h-4 w-24" })
243
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.CardContent, { children: [
244
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Skeleton, { className: "h-6 w-32 mb-2" }),
245
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Skeleton, { className: "h-4 w-24" })
246
246
  ] })
247
247
  ] });
248
248
  }
249
249
  if (error) {
250
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.Card, { children: [
251
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
252
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.CardTitle, { children: t("billing.ui.payment_method.title") }),
250
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.Card, { children: [
251
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
252
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.CardTitle, { children: t("billing.ui.payment_method.title") }),
253
253
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.Wallet, { className: "h-4 w-4 text-muted-foreground" })
254
254
  ] }),
255
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.CardContent, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-destructive text-xs/relaxed", children: error }) })
255
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.CardContent, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-destructive text-xs/relaxed", children: error }) })
256
256
  ] });
257
257
  }
258
258
  const defaultMethod = paymentMethods.find((pm) => pm.id === defaultPaymentMethodId) || paymentMethods[0];
259
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.Card, { className: "cursor-pointer hover:bg-accent/50 transition-colors", onClick: onManageClick, children: [
260
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
261
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.CardTitle, { children: t("billing.ui.payment_method.title") }),
259
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.Card, { className: "cursor-pointer hover:bg-accent/50 transition-colors", onClick: onManageClick, children: [
260
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
261
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.CardTitle, { children: t("billing.ui.payment_method.title") }),
262
262
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.Wallet, { className: "h-4 w-4 text-muted-foreground" })
263
263
  ] }),
264
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.CardContent, { children: paymentMethods.length === 0 ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2", children: [
264
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.CardContent, { children: paymentMethods.length === 0 ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2", children: [
265
265
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-xl font-bold text-muted-foreground", children: t("billing.ui.cards.payment_method.empty_title") }),
266
266
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-xs text-muted-foreground", children: t("billing.ui.cards.payment_method.empty_description") }),
267
267
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
268
- _chunkSZQNUGDGjs.Button,
268
+ _chunk3VEQ5JZJjs.Button,
269
269
  {
270
270
  variant: "outline",
271
271
  size: "sm",
@@ -314,13 +314,13 @@ function formatBalance(balance, currency, locale) {
314
314
  _chunk7QVYU63Ejs.__name.call(void 0, formatBalance, "formatBalance");
315
315
  function CustomerInfoCard({ customer, loading, error }) {
316
316
  const t = _nextintl.useTranslations.call(void 0, );
317
- const locale = _chunkVVJDWQEIjs.useI18nLocale.call(void 0, );
317
+ const locale = _chunkS5MQDWWCjs.useI18nLocale.call(void 0, );
318
318
  const [portalLoading, setPortalLoading] = _react.useState.call(void 0, false);
319
319
  const handlePortalClick = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async (e) => {
320
320
  e.stopPropagation();
321
321
  setPortalLoading(true);
322
322
  try {
323
- const { url } = await _chunkVVJDWQEIjs.StripeCustomerService.createPortalSession();
323
+ const { url } = await _chunkS5MQDWWCjs.StripeCustomerService.createPortalSession();
324
324
  window.open(url, "_blank");
325
325
  } catch (err) {
326
326
  console.error("[CustomerInfoCard] Failed to create portal session:", err);
@@ -329,45 +329,45 @@ function CustomerInfoCard({ customer, loading, error }) {
329
329
  }
330
330
  }, "handlePortalClick");
331
331
  if (loading) {
332
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.Card, { children: [
333
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
334
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.CardTitle, { children: t("billing.ui.cards.customer.title") }),
332
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.Card, { children: [
333
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
334
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.CardTitle, { children: t("billing.ui.cards.customer.title") }),
335
335
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.User, { className: "h-4 w-4 text-muted-foreground" })
336
336
  ] }),
337
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.CardContent, { children: [
338
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Skeleton, { className: "h-6 w-32 mb-2" }),
339
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Skeleton, { className: "h-4 w-48 mb-1" }),
340
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Skeleton, { className: "h-4 w-24" })
337
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.CardContent, { children: [
338
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Skeleton, { className: "h-6 w-32 mb-2" }),
339
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Skeleton, { className: "h-4 w-48 mb-1" }),
340
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Skeleton, { className: "h-4 w-24" })
341
341
  ] })
342
342
  ] });
343
343
  }
344
344
  if (error) {
345
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.Card, { children: [
346
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
347
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.CardTitle, { children: t("billing.ui.cards.customer.title") }),
345
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.Card, { children: [
346
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
347
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.CardTitle, { children: t("billing.ui.cards.customer.title") }),
348
348
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.User, { className: "h-4 w-4 text-muted-foreground" })
349
349
  ] }),
350
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.CardContent, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-destructive text-xs/relaxed", children: error }) })
350
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.CardContent, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-destructive text-xs/relaxed", children: error }) })
351
351
  ] });
352
352
  }
353
353
  if (!customer) {
354
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.Card, { children: [
355
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
356
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.CardTitle, { children: t("billing.ui.cards.customer.title") }),
354
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.Card, { children: [
355
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
356
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.CardTitle, { children: t("billing.ui.cards.customer.title") }),
357
357
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.User, { className: "h-4 w-4 text-muted-foreground" })
358
358
  ] }),
359
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.CardContent, { children: [
359
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.CardContent, { children: [
360
360
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-xl font-bold text-muted-foreground", children: t("billing.ui.cards.customer.not_set_up") }),
361
361
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-xs text-muted-foreground", children: t("billing.ui.cards.customer.not_set_up_description") })
362
362
  ] })
363
363
  ] });
364
364
  }
365
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.Card, { children: [
366
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
367
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.CardTitle, { children: t("billing.ui.cards.customer.title") }),
365
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.Card, { children: [
366
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
367
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.CardTitle, { children: t("billing.ui.cards.customer.title") }),
368
368
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.User, { className: "h-4 w-4 text-muted-foreground" })
369
369
  ] }),
370
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.CardContent, { children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2", children: [
370
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.CardContent, { children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2", children: [
371
371
  customer.name && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-xl font-bold", children: customer.name }),
372
372
  customer.email && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-sm text-muted-foreground", children: customer.email }),
373
373
  customer.balance !== void 0 && customer.balance !== 0 && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "p", { className: "text-sm", children: [
@@ -377,7 +377,7 @@ function CustomerInfoCard({ customer, loading, error }) {
377
377
  ] }),
378
378
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: customer.balance < 0 ? "text-success" : "text-destructive", children: formatBalance(customer.balance, customer.currency, locale) })
379
379
  ] }),
380
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.Button, { variant: "outline", size: "sm", className: "mt-2", onClick: handlePortalClick, disabled: portalLoading, children: [
380
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.Button, { variant: "outline", size: "sm", className: "mt-2", onClick: handlePortalClick, disabled: portalLoading, children: [
381
381
  portalLoading ? t("common.loading") : t("billing.ui.cards.customer.manage_portal"),
382
382
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.ExternalLink, { className: "h-4 w-4 ms-1" })
383
383
  ] })
@@ -390,7 +390,7 @@ _chunk7QVYU63Ejs.__name.call(void 0, CustomerInfoCard, "CustomerInfoCard");
390
390
 
391
391
 
392
392
 
393
- var INVOICE_STATUSES = Object.values(_chunkVVJDWQEIjs.InvoiceStatus);
393
+ var INVOICE_STATUSES = Object.values(_chunkS5MQDWWCjs.InvoiceStatus);
394
394
  function getStatusBadgeVariant2(status) {
395
395
  switch (status) {
396
396
  case "paid" /* PAID */:
@@ -415,46 +415,46 @@ function formatAmount(amount, currency, locale) {
415
415
  _chunk7QVYU63Ejs.__name.call(void 0, formatAmount, "formatAmount");
416
416
  function InvoicesSummaryCard({ invoices, loading, error, onViewAllClick }) {
417
417
  const t = _nextintl.useTranslations.call(void 0, );
418
- const fmt = _chunkSZQNUGDGjs.useBillingFormatOptions.call(void 0, );
418
+ const fmt = _chunk3VEQ5JZJjs.useBillingFormatOptions.call(void 0, );
419
419
  if (loading) {
420
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.Card, { children: [
421
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
422
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.CardTitle, { children: t("billing.ui.cards.invoices.title") }),
420
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.Card, { children: [
421
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
422
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.CardTitle, { children: t("billing.ui.cards.invoices.title") }),
423
423
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.ReceiptIcon, { className: "h-4 w-4 text-muted-foreground" })
424
424
  ] }),
425
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.CardContent, { children: [
426
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Skeleton, { className: "h-6 w-24 mb-2" }),
427
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Skeleton, { className: "h-4 w-32 mb-1" }),
428
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Skeleton, { className: "h-4 w-20" })
425
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.CardContent, { children: [
426
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Skeleton, { className: "h-6 w-24 mb-2" }),
427
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Skeleton, { className: "h-4 w-32 mb-1" }),
428
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Skeleton, { className: "h-4 w-20" })
429
429
  ] })
430
430
  ] });
431
431
  }
432
432
  if (error) {
433
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.Card, { children: [
434
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
435
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.CardTitle, { children: t("billing.ui.cards.invoices.title") }),
433
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.Card, { children: [
434
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
435
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.CardTitle, { children: t("billing.ui.cards.invoices.title") }),
436
436
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.ReceiptIcon, { className: "h-4 w-4 text-muted-foreground" })
437
437
  ] }),
438
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.CardContent, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-destructive text-xs/relaxed", children: error }) })
438
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.CardContent, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-destructive text-xs/relaxed", children: error }) })
439
439
  ] });
440
440
  }
441
441
  const latestInvoice = invoices[0];
442
442
  const paidInvoices = invoices.filter((inv) => inv.status === "paid" /* PAID */);
443
443
  const openInvoices = invoices.filter((inv) => inv.status === "open" /* OPEN */);
444
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.Card, { className: "cursor-pointer hover:bg-accent/50 transition-colors", onClick: onViewAllClick, children: [
445
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
446
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.CardTitle, { children: t("billing.ui.cards.invoices.title") }),
444
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.Card, { className: "cursor-pointer hover:bg-accent/50 transition-colors", onClick: onViewAllClick, children: [
445
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
446
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.CardTitle, { children: t("billing.ui.cards.invoices.title") }),
447
447
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.ReceiptIcon, { className: "h-4 w-4 text-muted-foreground" })
448
448
  ] }),
449
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.CardContent, { children: invoices.length === 0 ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2", children: [
449
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.CardContent, { children: invoices.length === 0 ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2", children: [
450
450
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-xl font-bold text-muted-foreground", children: t("billing.ui.invoices.empty_title") }),
451
451
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-xs text-muted-foreground", children: t("billing.ui.cards.invoices.empty_description") })
452
452
  ] }) : latestInvoice ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2", children: [
453
453
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center gap-2", children: [
454
454
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-xl font-bold", children: formatAmount(latestInvoice.total, latestInvoice.currency, fmt.locale) }),
455
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Badge, { variant: getStatusBadgeVariant2(latestInvoice.status), children: INVOICE_STATUSES.includes(latestInvoice.status) ? t(`billing.ui.invoice_status.${latestInvoice.status}`) : latestInvoice.status })
455
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Badge, { variant: getStatusBadgeVariant2(latestInvoice.status), children: INVOICE_STATUSES.includes(latestInvoice.status) ? t(`billing.ui.invoice_status.${latestInvoice.status}`) : latestInvoice.status })
456
456
  ] }),
457
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-sm text-muted-foreground", children: latestInvoice.stripeInvoiceNumber || t("billing.ui.cards.invoices.invoice_from", { date: _chunkSZQNUGDGjs.formatDate.call(void 0, latestInvoice.periodStart, fmt) }) }),
457
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-sm text-muted-foreground", children: latestInvoice.stripeInvoiceNumber || t("billing.ui.cards.invoices.invoice_from", { date: _chunk3VEQ5JZJjs.formatDate.call(void 0, latestInvoice.periodStart, fmt) }) }),
458
458
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center gap-4 text-xs text-muted-foreground", children: [
459
459
  paidInvoices.length > 0 && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: t("billing.ui.cards.invoices.paid_count", { count: paidInvoices.length }) }),
460
460
  openInvoices.length > 0 && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-warning", children: t("billing.ui.cards.invoices.open_count", { count: openInvoices.length }) }),
@@ -487,26 +487,26 @@ function BillingUsageSummaryCard({
487
487
  onViewDetailsClick
488
488
  }) {
489
489
  const t = _nextintl.useTranslations.call(void 0, );
490
- const locale = _chunkVVJDWQEIjs.useI18nLocale.call(void 0, );
490
+ const locale = _chunkS5MQDWWCjs.useI18nLocale.call(void 0, );
491
491
  if (loading) {
492
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.Card, { children: [
493
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
494
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.CardTitle, { children: t("billing.ui.cards.usage.title") }),
492
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.Card, { children: [
493
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
494
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.CardTitle, { children: t("billing.ui.cards.usage.title") }),
495
495
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.Activity, { className: "h-4 w-4 text-muted-foreground" })
496
496
  ] }),
497
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.CardContent, { children: [
498
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Skeleton, { className: "h-6 w-24 mb-2" }),
499
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Skeleton, { className: "h-4 w-32" })
497
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.CardContent, { children: [
498
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Skeleton, { className: "h-6 w-24 mb-2" }),
499
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Skeleton, { className: "h-4 w-32" })
500
500
  ] })
501
501
  ] });
502
502
  }
503
503
  if (error) {
504
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.Card, { children: [
505
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
506
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.CardTitle, { children: t("billing.ui.cards.usage.title") }),
504
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.Card, { children: [
505
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
506
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.CardTitle, { children: t("billing.ui.cards.usage.title") }),
507
507
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.Activity, { className: "h-4 w-4 text-muted-foreground" })
508
508
  ] }),
509
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.CardContent, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-destructive text-xs/relaxed", children: error }) })
509
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.CardContent, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-destructive text-xs/relaxed", children: error }) })
510
510
  ] });
511
511
  }
512
512
  const totalUsage = Object.values(summaries).reduce((acc, summary) => {
@@ -514,12 +514,12 @@ function BillingUsageSummaryCard({
514
514
  }, 0);
515
515
  const primaryMeter = meters.find((m) => _optionalChain([summaries, 'access', _17 => _17[m.id], 'optionalAccess', _18 => _18.aggregatedValue]));
516
516
  const primarySummary = primaryMeter ? summaries[primaryMeter.id] : null;
517
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.Card, { className: "cursor-pointer hover:bg-accent/50 transition-colors", onClick: onViewDetailsClick, children: [
518
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
519
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.CardTitle, { children: t("billing.ui.cards.usage.title") }),
517
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.Card, { className: "cursor-pointer hover:bg-accent/50 transition-colors", onClick: onViewDetailsClick, children: [
518
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.CardHeader, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
519
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.CardTitle, { children: t("billing.ui.cards.usage.title") }),
520
520
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.Activity, { className: "h-4 w-4 text-muted-foreground" })
521
521
  ] }),
522
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.CardContent, { children: meters.length === 0 ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2", children: [
522
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.CardContent, { children: meters.length === 0 ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2", children: [
523
523
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-xl font-bold text-muted-foreground", children: t("billing.ui.cards.usage.no_meters") }),
524
524
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-xs text-muted-foreground", children: t("billing.ui.cards.usage.no_meters_description") })
525
525
  ] }) : /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2", children: [
@@ -571,7 +571,7 @@ function PaymentMethodForm({ onSuccess, onCancel, isLoading = false }) {
571
571
  const fetchSetupIntent = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
572
572
  setLoading(true);
573
573
  try {
574
- const intent = await _chunkVVJDWQEIjs.StripeCustomerService.createSetupIntent();
574
+ const intent = await _chunkS5MQDWWCjs.StripeCustomerService.createSetupIntent();
575
575
  setSetupIntent(intent);
576
576
  } catch (err) {
577
577
  console.error("[PaymentMethodForm] Failed to create setup intent:", err);
@@ -609,7 +609,7 @@ function PaymentMethodForm({ onSuccess, onCancel, isLoading = false }) {
609
609
  return;
610
610
  }
611
611
  if (setAsDefault && _optionalChain([confirmedSetupIntent, 'optionalAccess', _19 => _19.payment_method])) {
612
- await _chunkVVJDWQEIjs.StripeCustomerService.setDefaultPaymentMethod({
612
+ await _chunkS5MQDWWCjs.StripeCustomerService.setDefaultPaymentMethod({
613
613
  paymentMethodId: typeof confirmedSetupIntent.payment_method === "string" ? confirmedSetupIntent.payment_method : confirmedSetupIntent.payment_method.id
614
614
  });
615
615
  }
@@ -625,7 +625,7 @@ function PaymentMethodForm({ onSuccess, onCancel, isLoading = false }) {
625
625
  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: t("billing.ui.payment_form.loading") }) });
626
626
  }
627
627
  if (!setupIntent && error) {
628
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Alert, { variant: "destructive", className: "bg-red-50 border-red-200", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.AlertDescription, { children: error }) });
628
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Alert, { variant: "destructive", className: "bg-red-50 border-red-200", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.AlertDescription, { children: error }) });
629
629
  }
630
630
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "form", { onSubmit: handleSubmit, className: "flex flex-col gap-y-4", children: [
631
631
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rounded-md border border-gray-300 p-3", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
@@ -648,13 +648,13 @@ function PaymentMethodForm({ onSuccess, onCancel, isLoading = false }) {
648
648
  }
649
649
  ) }),
650
650
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center gap-x-2", children: [
651
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Checkbox, { id: "setAsDefault", checked: setAsDefault, onCheckedChange: (checked) => setSetAsDefault(!!checked) }),
652
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Label, { htmlFor: "setAsDefault", className: "cursor-pointer font-normal", children: t("billing.ui.payment_form.set_default") })
651
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Checkbox, { id: "setAsDefault", checked: setAsDefault, onCheckedChange: (checked) => setSetAsDefault(!!checked) }),
652
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Label, { htmlFor: "setAsDefault", className: "cursor-pointer font-normal", children: t("billing.ui.payment_form.set_default") })
653
653
  ] }),
654
- error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Alert, { variant: "destructive", className: "bg-red-50 border-red-200", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.AlertDescription, { children: error }) }),
654
+ error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Alert, { variant: "destructive", className: "bg-red-50 border-red-200", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.AlertDescription, { children: error }) }),
655
655
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex justify-end gap-x-2", children: [
656
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Button, { type: "button", variant: "outline", onClick: onCancel, disabled: isSubmitting || isLoading, children: t("ui.buttons.cancel") }),
657
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Button, { type: "submit", disabled: !stripe || isSubmitting || isLoading, children: isSubmitting ? t("billing.ui.wizard.review.processing") : t("billing.ui.cards.payment_method.add_card") })
656
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Button, { type: "button", variant: "outline", onClick: onCancel, disabled: isSubmitting || isLoading, children: t("ui.buttons.cancel") }),
657
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Button, { type: "submit", disabled: !stripe || isSubmitting || isLoading, children: isSubmitting ? t("billing.ui.wizard.review.processing") : t("billing.ui.cards.payment_method.add_card") })
658
658
  ] })
659
659
  ] });
660
660
  }
@@ -671,10 +671,10 @@ function PaymentMethodEditor({ open, onOpenChange, onSuccess }) {
671
671
  const handleCancel = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, () => {
672
672
  onOpenChange(false);
673
673
  }, "handleCancel");
674
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Dialog, { open, onOpenChange, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.DialogContent, { className: "max-w-md", children: [
675
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.DialogHeader, { children: [
676
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.DialogTitle, { children: t("billing.ui.payment_methods.add") }),
677
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.DialogDescription, { children: t("billing.ui.payment_methods.add_description") })
674
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Dialog, { open, onOpenChange, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.DialogContent, { className: "max-w-md", children: [
675
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.DialogHeader, { children: [
676
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.DialogTitle, { children: t("billing.ui.payment_methods.add") }),
677
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.DialogDescription, { children: t("billing.ui.payment_methods.add_description") })
678
678
  ] }),
679
679
  open && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, PaymentMethodForm, { onSuccess: handleSuccess, onCancel: handleCancel })
680
680
  ] }) });
@@ -700,7 +700,7 @@ function PaymentMethodCard({ paymentMethod, onUpdate }) {
700
700
  _react.useEffect.call(void 0, () => {
701
701
  const loadCustomer = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
702
702
  try {
703
- const fetchedCustomer = await _chunkVVJDWQEIjs.StripeCustomerService.getCustomer();
703
+ const fetchedCustomer = await _chunkS5MQDWWCjs.StripeCustomerService.getCustomer();
704
704
  setCustomer(fetchedCustomer);
705
705
  } catch (error) {
706
706
  console.error("[PaymentMethodCard] Failed to load customer:", error);
@@ -717,7 +717,7 @@ function PaymentMethodCard({ paymentMethod, onUpdate }) {
717
717
  const handleSetDefault = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
718
718
  setLoading(true);
719
719
  try {
720
- await _chunkVVJDWQEIjs.StripeCustomerService.setDefaultPaymentMethod({ paymentMethodId: paymentMethod.id });
720
+ await _chunkS5MQDWWCjs.StripeCustomerService.setDefaultPaymentMethod({ paymentMethodId: paymentMethod.id });
721
721
  onUpdate();
722
722
  } catch (error) {
723
723
  console.error("[PaymentMethodCard] Failed to set as default:", error);
@@ -728,7 +728,7 @@ function PaymentMethodCard({ paymentMethod, onUpdate }) {
728
728
  const handleRemove = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
729
729
  setLoading(true);
730
730
  try {
731
- await _chunkVVJDWQEIjs.StripeCustomerService.removePaymentMethod({ paymentMethodId: paymentMethod.id });
731
+ await _chunkS5MQDWWCjs.StripeCustomerService.removePaymentMethod({ paymentMethodId: paymentMethod.id });
732
732
  setShowRemoveDialog(false);
733
733
  onUpdate();
734
734
  } catch (error) {
@@ -737,16 +737,16 @@ function PaymentMethodCard({ paymentMethod, onUpdate }) {
737
737
  }
738
738
  }, "handleRemove");
739
739
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
740
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.Card, { className: "relative", children: [
741
- isDefault && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Badge, { variant: "softGreen", className: "absolute end-2 top-2", children: t("billing.ui.payment_methods.default") }),
742
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.CardHeader, { className: "flex flex-row items-center justify-between pb-2", children: [
740
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.Card, { className: "relative", children: [
741
+ isDefault && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Badge, { variant: "softGreen", className: "absolute end-2 top-2", children: t("billing.ui.payment_methods.default") }),
742
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.CardHeader, { className: "flex flex-row items-center justify-between pb-2", children: [
743
743
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center gap-x-2", children: [
744
744
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-2xl", children: brandIcon }),
745
745
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-sm font-medium capitalize", children: brand })
746
746
  ] }),
747
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.DropdownMenu, { children: [
748
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.DropdownMenuTrigger, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
749
- _chunkSZQNUGDGjs.Button,
747
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.DropdownMenu, { children: [
748
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.DropdownMenuTrigger, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
749
+ _chunk3VEQ5JZJjs.Button,
750
750
  {
751
751
  render: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", {}),
752
752
  nativeButton: false,
@@ -757,10 +757,10 @@ function PaymentMethodCard({ paymentMethod, onUpdate }) {
757
757
  children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.MoreVertical, { className: "h-4 w-4" })
758
758
  }
759
759
  ) }),
760
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.DropdownMenuContent, { align: "end", children: [
761
- !isDefault && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.DropdownMenuItem, { onClick: handleSetDefault, disabled: loading, children: t("billing.ui.payment_methods.set_default") }),
760
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.DropdownMenuContent, { align: "end", children: [
761
+ !isDefault && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.DropdownMenuItem, { onClick: handleSetDefault, disabled: loading, children: t("billing.ui.payment_methods.set_default") }),
762
762
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
763
- _chunkSZQNUGDGjs.DropdownMenuItem,
763
+ _chunk3VEQ5JZJjs.DropdownMenuItem,
764
764
  {
765
765
  onClick: () => setShowRemoveDialog(true),
766
766
  disabled: loading,
@@ -771,7 +771,7 @@ function PaymentMethodCard({ paymentMethod, onUpdate }) {
771
771
  ] })
772
772
  ] })
773
773
  ] }),
774
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.CardContent, { children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex flex-col gap-y-1", children: [
774
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.CardContent, { children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex flex-col gap-y-1", children: [
775
775
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "p", { className: "text-lg font-semibold", children: [
776
776
  "\u2022\u2022\u2022\u2022 ",
777
777
  last4
@@ -779,17 +779,17 @@ function PaymentMethodCard({ paymentMethod, onUpdate }) {
779
779
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-sm text-muted-foreground", children: t("billing.ui.payment_method.expires", { date: `${String(expMonth).padStart(2, "0")}/${expYear}` }) })
780
780
  ] }) })
781
781
  ] }),
782
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.AlertDialog, { open: showRemoveDialog, onOpenChange: setShowRemoveDialog, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.AlertDialogContent, { children: [
783
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.AlertDialogHeader, { children: [
784
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.AlertDialogTitle, { children: t("billing.ui.payment_methods.remove_title") }),
785
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.AlertDialogDescription, { children: [
782
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.AlertDialog, { open: showRemoveDialog, onOpenChange: setShowRemoveDialog, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.AlertDialogContent, { children: [
783
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.AlertDialogHeader, { children: [
784
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.AlertDialogTitle, { children: t("billing.ui.payment_methods.remove_title") }),
785
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.AlertDialogDescription, { children: [
786
786
  t("billing.ui.payment_methods.remove_description"),
787
787
  isDefault && ` ${t("billing.ui.payment_methods.remove_default_warning")}`
788
788
  ] })
789
789
  ] }),
790
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.AlertDialogFooter, { children: [
791
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.AlertDialogCancel, { disabled: loading, children: t("ui.buttons.cancel") }),
792
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.AlertDialogAction, { onClick: handleRemove, disabled: loading, className: "bg-red-600 hover:bg-red-700", children: loading ? t("billing.ui.payment_methods.removing") : t("ui.buttons.remove") })
790
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.AlertDialogFooter, { children: [
791
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.AlertDialogCancel, { disabled: loading, children: t("ui.buttons.cancel") }),
792
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.AlertDialogAction, { onClick: handleRemove, disabled: loading, className: "bg-red-600 hover:bg-red-700", children: loading ? t("billing.ui.payment_methods.removing") : t("ui.buttons.remove") })
793
793
  ] })
794
794
  ] }) })
795
795
  ] });
@@ -813,7 +813,7 @@ function PaymentMethodsContainer() {
813
813
  const loadPaymentMethods = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
814
814
  setLoading(true);
815
815
  try {
816
- const fetchedPaymentMethods = await _chunkVVJDWQEIjs.StripeCustomerService.listPaymentMethods();
816
+ const fetchedPaymentMethods = await _chunkS5MQDWWCjs.StripeCustomerService.listPaymentMethods();
817
817
  setPaymentMethods(fetchedPaymentMethods);
818
818
  } catch (error) {
819
819
  console.error("[PaymentMethodsContainer] Failed to load payment methods:", error);
@@ -833,14 +833,14 @@ function PaymentMethodsContainer() {
833
833
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.CreditCard, { className: "h-8 w-8" }),
834
834
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h1", { className: "text-primary text-3xl font-semibold", children: t("billing.ui.payment_methods.title") })
835
835
  ] }),
836
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Button, { onClick: () => setShowAddPaymentMethod(true), children: t("billing.ui.payment_methods.add") })
836
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Button, { onClick: () => setShowAddPaymentMethod(true), children: t("billing.ui.payment_methods.add") })
837
837
  ] }),
838
838
  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: [
839
839
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.CreditCard, { className: "h-16 w-16 text-muted-foreground" }),
840
840
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "text-center", children: [
841
841
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h3", { className: "mb-2 text-sm font-medium", children: t("billing.ui.payment_methods.empty_title") }),
842
842
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "mb-4 text-muted-foreground", children: t("billing.ui.payment_methods.empty_description") }),
843
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Button, { onClick: () => setShowAddPaymentMethod(true), children: t("billing.ui.payment_methods.add_first") })
843
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Button, { onClick: () => setShowAddPaymentMethod(true), children: t("billing.ui.payment_methods.add_first") })
844
844
  ] })
845
845
  ] }),
846
846
  paymentMethods.length > 0 && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, PaymentMethodsList, { paymentMethods, onUpdate: loadPaymentMethods }),
@@ -896,7 +896,7 @@ var statusConfig = {
896
896
  function InvoiceStatusBadge({ status }) {
897
897
  const t = _nextintl.useTranslations.call(void 0, );
898
898
  const config = statusConfig[status] || statusConfig["draft" /* DRAFT */];
899
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Badge, { variant: config.variant, children: t(config.label) });
899
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Badge, { variant: config.variant, children: t(config.label) });
900
900
  }
901
901
  _chunk7QVYU63Ejs.__name.call(void 0, InvoiceStatusBadge, "InvoiceStatusBadge");
902
902
 
@@ -909,7 +909,7 @@ function InvoiceDetails({
909
909
  onInvoiceChange: _onInvoiceChange
910
910
  }) {
911
911
  const t = _nextintl.useTranslations.call(void 0, );
912
- const fmt = _chunkSZQNUGDGjs.useBillingFormatOptions.call(void 0, );
912
+ const fmt = _chunk3VEQ5JZJjs.useBillingFormatOptions.call(void 0, );
913
913
  const handleDownloadPDF = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, () => {
914
914
  if (invoice.stripePdfUrl) {
915
915
  window.open(invoice.stripePdfUrl, "_blank");
@@ -929,10 +929,10 @@ function InvoiceDetails({
929
929
  return invoice.stripeInvoiceId.slice(-8);
930
930
  }, "getInvoiceNumber");
931
931
  const productName = _optionalChain([invoice, 'access', _29 => _29.subscription, 'optionalAccess', _30 => _30.price, 'optionalAccess', _31 => _31.product, 'optionalAccess', _32 => _32.name]) || t("billing.ui.cards.subscriptions.fallback_name");
932
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Dialog, { open, onOpenChange, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.DialogContent, { className: "max-w-2xl", children: [
933
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.DialogHeader, { children: [
934
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.DialogTitle, { children: t("billing.ui.invoice.title", { number: getInvoiceNumber() }) }),
935
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.DialogDescription, { children: _chunkSZQNUGDGjs.formatDate.call(void 0, invoice.periodStart, fmt) })
932
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Dialog, { open, onOpenChange, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.DialogContent, { className: "max-w-2xl", children: [
933
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.DialogHeader, { children: [
934
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.DialogTitle, { children: t("billing.ui.invoice.title", { number: getInvoiceNumber() }) }),
935
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.DialogDescription, { children: _chunk3VEQ5JZJjs.formatDate.call(void 0, invoice.periodStart, fmt) })
936
936
  ] }),
937
937
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-6", children: [
938
938
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center gap-x-3", children: [
@@ -943,18 +943,18 @@ function InvoiceDetails({
943
943
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { children: [
944
944
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-muted-foreground text-xs", children: t("billing.ui.invoice.billing_period") }),
945
945
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "p", { className: "text-sm", children: [
946
- _chunkSZQNUGDGjs.formatDate.call(void 0, invoice.periodStart, fmt),
946
+ _chunk3VEQ5JZJjs.formatDate.call(void 0, invoice.periodStart, fmt),
947
947
  " - ",
948
- _chunkSZQNUGDGjs.formatDate.call(void 0, invoice.periodEnd, fmt)
948
+ _chunk3VEQ5JZJjs.formatDate.call(void 0, invoice.periodEnd, fmt)
949
949
  ] })
950
950
  ] }),
951
951
  invoice.dueDate && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { children: [
952
952
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-muted-foreground text-xs", children: t("billing.ui.invoice.due_date") }),
953
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-sm", children: _chunkSZQNUGDGjs.formatDate.call(void 0, invoice.dueDate, fmt) })
953
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-sm", children: _chunk3VEQ5JZJjs.formatDate.call(void 0, invoice.dueDate, fmt) })
954
954
  ] }),
955
955
  invoice.paidAt && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { children: [
956
956
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-muted-foreground text-xs", children: t("billing.ui.invoice.paid_date") }),
957
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-sm", children: _chunkSZQNUGDGjs.formatDate.call(void 0, invoice.paidAt, fmt) })
957
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-sm", children: _chunk3VEQ5JZJjs.formatDate.call(void 0, invoice.paidAt, fmt) })
958
958
  ] }),
959
959
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { children: [
960
960
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-muted-foreground text-xs", children: t("billing.ui.invoice.attempt_count") }),
@@ -970,42 +970,42 @@ function InvoiceDetails({
970
970
  ] }) }),
971
971
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "tbody", { children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "tr", { className: "border-t", children: [
972
972
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "td", { className: "p-3", children: productName }),
973
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "td", { className: "p-3 text-end", children: _chunkSZQNUGDGjs.formatCurrency.call(void 0, invoice.subtotal, invoice.currency, fmt) })
973
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "td", { className: "p-3 text-end", children: _chunk3VEQ5JZJjs.formatCurrency.call(void 0, invoice.subtotal, invoice.currency, fmt) })
974
974
  ] }) })
975
975
  ] }) })
976
976
  ] }),
977
977
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2 border-t pt-4", children: [
978
978
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex justify-between", children: [
979
979
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-muted-foreground text-xs", children: t("billing.ui.invoice.subtotal") }),
980
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-sm", children: _chunkSZQNUGDGjs.formatCurrency.call(void 0, invoice.subtotal, invoice.currency, fmt) })
980
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-sm", children: _chunk3VEQ5JZJjs.formatCurrency.call(void 0, invoice.subtotal, invoice.currency, fmt) })
981
981
  ] }),
982
982
  invoice.tax !== void 0 && invoice.tax > 0 && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex justify-between", children: [
983
983
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-muted-foreground text-xs", children: t("billing.ui.invoice.tax") }),
984
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-sm", children: _chunkSZQNUGDGjs.formatCurrency.call(void 0, invoice.tax, invoice.currency, fmt) })
984
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-sm", children: _chunk3VEQ5JZJjs.formatCurrency.call(void 0, invoice.tax, invoice.currency, fmt) })
985
985
  ] }),
986
986
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex justify-between text-lg font-semibold border-t pt-2", children: [
987
987
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: t("billing.ui.invoice.total") }),
988
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: _chunkSZQNUGDGjs.formatCurrency.call(void 0, invoice.total, invoice.currency, fmt) })
988
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: _chunk3VEQ5JZJjs.formatCurrency.call(void 0, invoice.total, invoice.currency, fmt) })
989
989
  ] }),
990
990
  invoice.amountPaid > 0 && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex justify-between", children: [
991
991
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-muted-foreground text-xs", children: t("billing.ui.invoice.amount_paid") }),
992
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-sm text-success", children: _chunkSZQNUGDGjs.formatCurrency.call(void 0, invoice.amountPaid, invoice.currency, fmt) })
992
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-sm text-success", children: _chunk3VEQ5JZJjs.formatCurrency.call(void 0, invoice.amountPaid, invoice.currency, fmt) })
993
993
  ] }),
994
994
  invoice.amountRemaining > 0 && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex justify-between", children: [
995
995
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-muted-foreground text-xs", children: t("billing.ui.invoice.amount_due") }),
996
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-sm text-destructive", children: _chunkSZQNUGDGjs.formatCurrency.call(void 0, invoice.amountRemaining, invoice.currency, fmt) })
996
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-sm text-destructive", children: _chunk3VEQ5JZJjs.formatCurrency.call(void 0, invoice.amountRemaining, invoice.currency, fmt) })
997
997
  ] })
998
998
  ] }),
999
999
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex flex-wrap gap-2 pt-4 border-t", children: [
1000
- invoice.stripePdfUrl && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.Button, { variant: "outline", onClick: handleDownloadPDF, children: [
1000
+ invoice.stripePdfUrl && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.Button, { variant: "outline", onClick: handleDownloadPDF, children: [
1001
1001
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.Download, { className: "me-2 h-4 w-4" }),
1002
1002
  t("billing.ui.invoice.download_pdf")
1003
1003
  ] }),
1004
- invoice.status === "open" /* OPEN */ && invoice.attempted && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.Button, { variant: "default", onClick: handleRetryPayment, children: [
1004
+ invoice.status === "open" /* OPEN */ && invoice.attempted && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.Button, { variant: "default", onClick: handleRetryPayment, children: [
1005
1005
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.RefreshCw, { className: "me-2 h-4 w-4" }),
1006
1006
  t("billing.ui.invoice.retry_payment")
1007
1007
  ] }),
1008
- invoice.stripeHostedInvoiceUrl && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.Button, { variant: "outline", onClick: handleViewInStripe, children: [
1008
+ invoice.stripeHostedInvoiceUrl && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.Button, { variant: "outline", onClick: handleViewInStripe, children: [
1009
1009
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.ExternalLink, { className: "me-2 h-4 w-4" }),
1010
1010
  t("billing.ui.invoice.view_in_stripe")
1011
1011
  ] })
@@ -1019,7 +1019,7 @@ _chunk7QVYU63Ejs.__name.call(void 0, InvoiceDetails, "InvoiceDetails");
1019
1019
 
1020
1020
  function InvoicesList({ invoices, onInvoicesChange }) {
1021
1021
  const t = _nextintl.useTranslations.call(void 0, );
1022
- const fmt = _chunkSZQNUGDGjs.useBillingFormatOptions.call(void 0, );
1022
+ const fmt = _chunk3VEQ5JZJjs.useBillingFormatOptions.call(void 0, );
1023
1023
  const [selectedInvoice, setSelectedInvoice] = _react.useState.call(void 0, null);
1024
1024
  const handleRowClick = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (invoice) => {
1025
1025
  setSelectedInvoice(invoice);
@@ -1031,30 +1031,30 @@ function InvoicesList({ invoices, onInvoicesChange }) {
1031
1031
  return invoice.stripeInvoiceId.slice(-8);
1032
1032
  }, "getInvoiceNumber");
1033
1033
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
1034
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "border rounded-lg overflow-clip", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.Table, { children: [
1035
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableHeader, { className: "bg-muted", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.TableRow, { children: [
1036
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableHead, { children: t("billing.ui.columns.invoice_number") }),
1037
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableHead, { children: t("billing.ui.columns.date") }),
1038
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableHead, { children: t("billing.ui.columns.status") }),
1039
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableHead, { className: "text-end", children: t("billing.ui.columns.amount") }),
1040
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableHead, { children: t("billing.ui.columns.period") })
1034
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "border rounded-lg overflow-clip", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.Table, { children: [
1035
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableHeader, { className: "bg-muted", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.TableRow, { children: [
1036
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableHead, { children: t("billing.ui.columns.invoice_number") }),
1037
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableHead, { children: t("billing.ui.columns.date") }),
1038
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableHead, { children: t("billing.ui.columns.status") }),
1039
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableHead, { className: "text-end", children: t("billing.ui.columns.amount") }),
1040
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableHead, { children: t("billing.ui.columns.period") })
1041
1041
  ] }) }),
1042
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableBody, { children: invoices.map((invoice) => {
1042
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableBody, { children: invoices.map((invoice) => {
1043
1043
  const invoiceNumber = getInvoiceNumber(invoice);
1044
- const date = _chunkSZQNUGDGjs.formatDate.call(void 0, invoice.periodStart, fmt);
1045
- const amount = _chunkSZQNUGDGjs.formatCurrency.call(void 0, invoice.total, invoice.currency, fmt);
1046
- const period = `${_chunkSZQNUGDGjs.formatDate.call(void 0, invoice.periodStart, fmt)} - ${_chunkSZQNUGDGjs.formatDate.call(void 0, invoice.periodEnd, fmt)}`;
1044
+ const date = _chunk3VEQ5JZJjs.formatDate.call(void 0, invoice.periodStart, fmt);
1045
+ const amount = _chunk3VEQ5JZJjs.formatCurrency.call(void 0, invoice.total, invoice.currency, fmt);
1046
+ const period = `${_chunk3VEQ5JZJjs.formatDate.call(void 0, invoice.periodStart, fmt)} - ${_chunk3VEQ5JZJjs.formatDate.call(void 0, invoice.periodEnd, fmt)}`;
1047
1047
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
1048
- _chunkSZQNUGDGjs.TableRow,
1048
+ _chunk3VEQ5JZJjs.TableRow,
1049
1049
  {
1050
1050
  onClick: () => handleRowClick(invoice),
1051
1051
  className: "cursor-pointer hover:bg-muted/50",
1052
1052
  children: [
1053
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableCell, { className: "font-medium", children: invoiceNumber }),
1054
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableCell, { className: "text-muted-foreground text-xs", children: date }),
1055
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableCell, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, InvoiceStatusBadge, { status: invoice.status }) }),
1056
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableCell, { className: "text-end font-medium", children: amount }),
1057
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableCell, { className: "text-muted-foreground text-xs", children: period })
1053
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableCell, { className: "font-medium", children: invoiceNumber }),
1054
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableCell, { className: "text-muted-foreground text-xs", children: date }),
1055
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableCell, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, InvoiceStatusBadge, { status: invoice.status }) }),
1056
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableCell, { className: "text-end font-medium", children: amount }),
1057
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableCell, { className: "text-muted-foreground text-xs", children: period })
1058
1058
  ]
1059
1059
  },
1060
1060
  invoice.id
@@ -1088,7 +1088,7 @@ function InvoicesContainer() {
1088
1088
  setLoading(true);
1089
1089
  try {
1090
1090
  const params = statusFilter !== "all" ? { status: statusFilter } : void 0;
1091
- const data = await _chunkVVJDWQEIjs.StripeInvoiceService.listInvoices(params);
1091
+ const data = await _chunkS5MQDWWCjs.StripeInvoiceService.listInvoices(params);
1092
1092
  setInvoices(data);
1093
1093
  } catch (error) {
1094
1094
  console.error("[InvoicesContainer] Failed to load invoices:", error);
@@ -1104,12 +1104,12 @@ function InvoicesContainer() {
1104
1104
  setStatusFilter(value);
1105
1105
  }, "handleFilterChange");
1106
1106
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-4", children: [
1107
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Tabs, { value: statusFilter, onValueChange: handleFilterChange, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.TabsList, { children: [
1108
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TabsTrigger, { value: "all", children: t("billing.ui.invoices.filter_all") }),
1109
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TabsTrigger, { value: "paid" /* PAID */, children: t("billing.ui.invoice_status.paid") }),
1110
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TabsTrigger, { value: "open" /* OPEN */, children: t("billing.ui.invoice_status.open") }),
1111
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TabsTrigger, { value: "void" /* VOID */, children: t("billing.ui.invoice_status.void") }),
1112
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TabsTrigger, { value: "uncollectible" /* UNCOLLECTIBLE */, children: t("billing.ui.invoice_status.uncollectible") })
1107
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Tabs, { value: statusFilter, onValueChange: handleFilterChange, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.TabsList, { children: [
1108
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TabsTrigger, { value: "all", children: t("billing.ui.invoices.filter_all") }),
1109
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TabsTrigger, { value: "paid" /* PAID */, children: t("billing.ui.invoice_status.paid") }),
1110
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TabsTrigger, { value: "open" /* OPEN */, children: t("billing.ui.invoice_status.open") }),
1111
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TabsTrigger, { value: "void" /* VOID */, children: t("billing.ui.invoice_status.void") }),
1112
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TabsTrigger, { value: "uncollectible" /* UNCOLLECTIBLE */, children: t("billing.ui.invoice_status.uncollectible") })
1113
1113
  ] }) }),
1114
1114
  loading && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "text-center py-8 text-muted-foreground", children: t("billing.ui.invoices.loading") }),
1115
1115
  !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: [
@@ -1151,7 +1151,7 @@ function CancelSubscriptionDialog({
1151
1151
  onSuccess
1152
1152
  }) {
1153
1153
  const t = _nextintl.useTranslations.call(void 0, );
1154
- const fmt = _chunkSZQNUGDGjs.useBillingFormatOptions.call(void 0, );
1154
+ const fmt = _chunk3VEQ5JZJjs.useBillingFormatOptions.call(void 0, );
1155
1155
  const [isSubmitting, setIsSubmitting] = _react.useState.call(void 0, false);
1156
1156
  const form = _reacthookform.useForm.call(void 0, {
1157
1157
  resolver: _zod.zodResolver.call(void 0, formSchema),
@@ -1162,7 +1162,7 @@ function CancelSubscriptionDialog({
1162
1162
  const onSubmit = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async (_values) => {
1163
1163
  setIsSubmitting(true);
1164
1164
  try {
1165
- await _chunkVVJDWQEIjs.StripeSubscriptionService.cancelSubscription({
1165
+ await _chunkS5MQDWWCjs.StripeSubscriptionService.cancelSubscription({
1166
1166
  id: subscription.id,
1167
1167
  cancelImmediately: false
1168
1168
  });
@@ -1174,16 +1174,16 @@ function CancelSubscriptionDialog({
1174
1174
  setIsSubmitting(false);
1175
1175
  }
1176
1176
  }, "onSubmit");
1177
- const periodEndDate = _chunkSZQNUGDGjs.formatDate.call(void 0, subscription.currentPeriodEnd, fmt);
1178
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Dialog, { open, onOpenChange, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.DialogContent, { className: "max-w-md", children: [
1179
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.DialogHeader, { children: [
1180
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.DialogTitle, { children: t("billing.ui.subscription.cancel.title") }),
1181
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.DialogDescription, { children: t("billing.ui.subscription.cancel.description") })
1177
+ const periodEndDate = _chunk3VEQ5JZJjs.formatDate.call(void 0, subscription.currentPeriodEnd, fmt);
1178
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Dialog, { open, onOpenChange, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.DialogContent, { className: "max-w-md", children: [
1179
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.DialogHeader, { children: [
1180
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.DialogTitle, { children: t("billing.ui.subscription.cancel.title") }),
1181
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.DialogDescription, { children: t("billing.ui.subscription.cancel.description") })
1182
1182
  ] }),
1183
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Form, { ...form, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "form", { onSubmit: form.handleSubmit(onSubmit), className: "flex flex-col gap-y-4", children: [
1183
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Form, { ...form, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "form", { onSubmit: form.handleSubmit(onSubmit), className: "flex flex-col gap-y-4", children: [
1184
1184
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "bg-primary/10 border-primary/30 text-foreground rounded-lg border p-3 text-sm", children: t("billing.ui.subscription.cancel.remains_active", { date: periodEndDate }) }),
1185
1185
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1186
- _chunkSZQNUGDGjs.FormTextarea,
1186
+ _chunk3VEQ5JZJjs.FormTextarea,
1187
1187
  {
1188
1188
  form,
1189
1189
  id: "reason",
@@ -1193,8 +1193,8 @@ function CancelSubscriptionDialog({
1193
1193
  }
1194
1194
  ),
1195
1195
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex gap-x-2 justify-end pt-2", children: [
1196
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Button, { type: "button", variant: "outline", onClick: () => onOpenChange(false), disabled: isSubmitting, children: t("billing.ui.subscription.cancel.keep") }),
1197
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Button, { type: "submit", variant: "destructive", disabled: isSubmitting, children: isSubmitting ? t("billing.ui.subscription.cancel.canceling") : t("billing.ui.subscription.cancel.confirm") })
1196
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Button, { type: "button", variant: "outline", onClick: () => onOpenChange(false), disabled: isSubmitting, children: t("billing.ui.subscription.cancel.keep") }),
1197
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Button, { type: "submit", variant: "destructive", disabled: isSubmitting, children: isSubmitting ? t("billing.ui.subscription.cancel.canceling") : t("billing.ui.subscription.cancel.confirm") })
1198
1198
  ] })
1199
1199
  ] }) })
1200
1200
  ] }) });
@@ -1245,7 +1245,7 @@ var cancelingConfig = {
1245
1245
  function SubscriptionStatusBadge({ status, cancelAtPeriodEnd }) {
1246
1246
  const t = _nextintl.useTranslations.call(void 0, );
1247
1247
  const config = cancelAtPeriodEnd ? cancelingConfig : statusConfig2[status] || statusConfig2["canceled" /* CANCELED */];
1248
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Badge, { variant: config.variant, children: t(config.label) });
1248
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Badge, { variant: config.variant, children: t(config.label) });
1249
1249
  }
1250
1250
  _chunk7QVYU63Ejs.__name.call(void 0, SubscriptionStatusBadge, "SubscriptionStatusBadge");
1251
1251
 
@@ -1272,7 +1272,7 @@ function formatPlanName2(price, t) {
1272
1272
  _chunk7QVYU63Ejs.__name.call(void 0, formatPlanName2, "formatPlanName");
1273
1273
  function formatBillingAmount(price, notAvailable, fmt) {
1274
1274
  if (!_optionalChain([price, 'optionalAccess', _37 => _37.unitAmount])) return notAvailable;
1275
- return _chunkSZQNUGDGjs.formatCurrency.call(void 0, price.unitAmount, price.currency, fmt);
1275
+ return _chunk3VEQ5JZJjs.formatCurrency.call(void 0, price.unitAmount, price.currency, fmt);
1276
1276
  }
1277
1277
  _chunk7QVYU63Ejs.__name.call(void 0, formatBillingAmount, "formatBillingAmount");
1278
1278
  function SubscriptionDetails({
@@ -1283,13 +1283,13 @@ function SubscriptionDetails({
1283
1283
  onChangePlan
1284
1284
  }) {
1285
1285
  const t = _nextintl.useTranslations.call(void 0, );
1286
- const fmt = _chunkSZQNUGDGjs.useBillingFormatOptions.call(void 0, );
1286
+ const fmt = _chunk3VEQ5JZJjs.useBillingFormatOptions.call(void 0, );
1287
1287
  const [showCancel, setShowCancel] = _react.useState.call(void 0, false);
1288
1288
  const [isProcessing, setIsProcessing] = _react.useState.call(void 0, false);
1289
1289
  const handlePause = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
1290
1290
  setIsProcessing(true);
1291
1291
  try {
1292
- await _chunkVVJDWQEIjs.StripeSubscriptionService.pauseSubscription({ subscriptionId: subscription.id });
1292
+ await _chunkS5MQDWWCjs.StripeSubscriptionService.pauseSubscription({ subscriptionId: subscription.id });
1293
1293
  onSubscriptionChange();
1294
1294
  } catch (error) {
1295
1295
  console.error("[SubscriptionDetails] Failed to pause subscription:", error);
@@ -1300,7 +1300,7 @@ function SubscriptionDetails({
1300
1300
  const handleResume = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
1301
1301
  setIsProcessing(true);
1302
1302
  try {
1303
- await _chunkVVJDWQEIjs.StripeSubscriptionService.resumeSubscription({ subscriptionId: subscription.id });
1303
+ await _chunkS5MQDWWCjs.StripeSubscriptionService.resumeSubscription({ subscriptionId: subscription.id });
1304
1304
  onSubscriptionChange();
1305
1305
  } catch (error) {
1306
1306
  console.error("[SubscriptionDetails] Failed to resume subscription:", error);
@@ -1310,7 +1310,7 @@ function SubscriptionDetails({
1310
1310
  }, "handleResume");
1311
1311
  const handleManageViaPortal = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
1312
1312
  try {
1313
- const { url } = await _chunkVVJDWQEIjs.StripeCustomerService.createPortalSession();
1313
+ const { url } = await _chunkS5MQDWWCjs.StripeCustomerService.createPortalSession();
1314
1314
  window.open(url, "_blank");
1315
1315
  } catch (error) {
1316
1316
  console.error("[SubscriptionDetails] Failed to create portal session:", error);
@@ -1320,10 +1320,10 @@ function SubscriptionDetails({
1320
1320
  const canResume = subscription.status === "paused" /* PAUSED */;
1321
1321
  const canCancel = subscription.status === "active" /* ACTIVE */ || subscription.status === "trialing" /* TRIALING */ || subscription.status === "paused" /* PAUSED */;
1322
1322
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
1323
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Dialog, { open, onOpenChange, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.DialogContent, { className: "max-w-2xl", children: [
1324
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.DialogHeader, { children: [
1325
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.DialogTitle, { children: t("billing.ui.subscription.details_title") }),
1326
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.DialogDescription, { children: t("billing.ui.subscription.details_description") })
1323
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Dialog, { open, onOpenChange, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.DialogContent, { className: "max-w-2xl", children: [
1324
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.DialogHeader, { children: [
1325
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.DialogTitle, { children: t("billing.ui.subscription.details_title") }),
1326
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.DialogDescription, { children: t("billing.ui.subscription.details_description") })
1327
1327
  ] }),
1328
1328
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-6", children: [
1329
1329
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center gap-x-3", children: [
@@ -1349,24 +1349,24 @@ function SubscriptionDetails({
1349
1349
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "space-y-2", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex justify-between", children: [
1350
1350
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-muted-foreground text-xs", children: t("billing.ui.subscription.current_period") }),
1351
1351
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "text-sm", children: [
1352
- _chunkSZQNUGDGjs.formatDate.call(void 0, subscription.currentPeriodStart, fmt),
1352
+ _chunk3VEQ5JZJjs.formatDate.call(void 0, subscription.currentPeriodStart, fmt),
1353
1353
  " - ",
1354
- _chunkSZQNUGDGjs.formatDate.call(void 0, subscription.currentPeriodEnd, fmt)
1354
+ _chunk3VEQ5JZJjs.formatDate.call(void 0, subscription.currentPeriodEnd, fmt)
1355
1355
  ] })
1356
1356
  ] }) }),
1357
1357
  subscription.trialEnd && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex justify-between", children: [
1358
1358
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-muted-foreground text-xs", children: t("billing.ui.subscription.trial_ends") }),
1359
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-sm", children: _chunkSZQNUGDGjs.formatDate.call(void 0, subscription.trialEnd, fmt) })
1359
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-sm", children: _chunk3VEQ5JZJjs.formatDate.call(void 0, subscription.trialEnd, fmt) })
1360
1360
  ] }),
1361
1361
  subscription.cancelAtPeriodEnd && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "bg-warning/15 border-warning/30 rounded-lg border p-3", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-warning text-xs/relaxed", children: t("billing.ui.subscription.cancel_at_period_end", {
1362
- date: _chunkSZQNUGDGjs.formatDate.call(void 0, subscription.currentPeriodEnd, fmt)
1362
+ date: _chunk3VEQ5JZJjs.formatDate.call(void 0, subscription.currentPeriodEnd, fmt)
1363
1363
  }) }) }),
1364
1364
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex flex-wrap gap-2 pt-4 border-t", children: [
1365
- onChangePlan && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Button, { variant: "default", onClick: () => onChangePlan(subscription), children: t("billing.ui.subscription.change_plan") }),
1366
- canPause && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Button, { variant: "outline", onClick: handlePause, disabled: isProcessing, children: isProcessing ? t("billing.ui.subscription.pausing") : t("billing.ui.subscription.pause") }),
1367
- canResume && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Button, { variant: "outline", onClick: handleResume, disabled: isProcessing, children: isProcessing ? t("billing.ui.subscription.resuming") : t("billing.ui.subscription.resume") }),
1368
- canCancel && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Button, { variant: "destructive", onClick: () => setShowCancel(true), children: t("ui.buttons.cancel") }),
1369
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Button, { variant: "outline", onClick: handleManageViaPortal, children: t("billing.ui.subscription.manage_portal") })
1365
+ onChangePlan && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Button, { variant: "default", onClick: () => onChangePlan(subscription), children: t("billing.ui.subscription.change_plan") }),
1366
+ canPause && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Button, { variant: "outline", onClick: handlePause, disabled: isProcessing, children: isProcessing ? t("billing.ui.subscription.pausing") : t("billing.ui.subscription.pause") }),
1367
+ canResume && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Button, { variant: "outline", onClick: handleResume, disabled: isProcessing, children: isProcessing ? t("billing.ui.subscription.resuming") : t("billing.ui.subscription.resume") }),
1368
+ canCancel && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Button, { variant: "destructive", onClick: () => setShowCancel(true), children: t("ui.buttons.cancel") }),
1369
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Button, { variant: "outline", onClick: handleManageViaPortal, children: t("billing.ui.subscription.manage_portal") })
1370
1370
  ] })
1371
1371
  ] })
1372
1372
  ] }) }),
@@ -1409,42 +1409,42 @@ function formatPlanName3(price, t) {
1409
1409
  _chunk7QVYU63Ejs.__name.call(void 0, formatPlanName3, "formatPlanName");
1410
1410
  function SubscriptionsList({ subscriptions, onSubscriptionsChange, onChangePlan }) {
1411
1411
  const t = _nextintl.useTranslations.call(void 0, );
1412
- const fmt = _chunkSZQNUGDGjs.useBillingFormatOptions.call(void 0, );
1412
+ const fmt = _chunk3VEQ5JZJjs.useBillingFormatOptions.call(void 0, );
1413
1413
  const [selectedSub, setSelectedSub] = _react.useState.call(void 0, null);
1414
1414
  const handleRowClick = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (subscription) => {
1415
1415
  setSelectedSub(subscription);
1416
1416
  }, "handleRowClick");
1417
1417
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
1418
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "border rounded-lg overflow-clip", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.Table, { children: [
1419
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableHeader, { className: "bg-muted", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.TableRow, { children: [
1420
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableHead, { children: t("billing.ui.columns.status") }),
1421
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableHead, { children: t("billing.ui.columns.plan") }),
1422
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableHead, { children: t("billing.ui.columns.period") }),
1423
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableHead, { className: "text-end", children: t("billing.ui.columns.amount") }),
1424
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableHead, { className: "text-end", children: t("billing.ui.columns.actions") })
1418
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "border rounded-lg overflow-clip", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.Table, { children: [
1419
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableHeader, { className: "bg-muted", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.TableRow, { children: [
1420
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableHead, { children: t("billing.ui.columns.status") }),
1421
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableHead, { children: t("billing.ui.columns.plan") }),
1422
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableHead, { children: t("billing.ui.columns.period") }),
1423
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableHead, { className: "text-end", children: t("billing.ui.columns.amount") }),
1424
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableHead, { className: "text-end", children: t("billing.ui.columns.actions") })
1425
1425
  ] }) }),
1426
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableBody, { children: subscriptions.map((subscription) => {
1426
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableBody, { children: subscriptions.map((subscription) => {
1427
1427
  const price = subscription.price;
1428
- const amount = _optionalChain([price, 'optionalAccess', _42 => _42.unitAmount]) ? _chunkSZQNUGDGjs.formatCurrency.call(void 0, price.unitAmount, price.currency, fmt) : "0";
1429
- const period = `${_chunkSZQNUGDGjs.formatDate.call(void 0, subscription.currentPeriodStart, fmt)} - ${_chunkSZQNUGDGjs.formatDate.call(void 0, subscription.currentPeriodEnd, fmt)}`;
1428
+ const amount = _optionalChain([price, 'optionalAccess', _42 => _42.unitAmount]) ? _chunk3VEQ5JZJjs.formatCurrency.call(void 0, price.unitAmount, price.currency, fmt) : "0";
1429
+ const period = `${_chunk3VEQ5JZJjs.formatDate.call(void 0, subscription.currentPeriodStart, fmt)} - ${_chunk3VEQ5JZJjs.formatDate.call(void 0, subscription.currentPeriodEnd, fmt)}`;
1430
1430
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
1431
- _chunkSZQNUGDGjs.TableRow,
1431
+ _chunk3VEQ5JZJjs.TableRow,
1432
1432
  {
1433
1433
  onClick: () => handleRowClick(subscription),
1434
1434
  className: "cursor-pointer hover:bg-muted/50",
1435
1435
  children: [
1436
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableCell, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1436
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableCell, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1437
1437
  SubscriptionStatusBadge,
1438
1438
  {
1439
1439
  status: subscription.status,
1440
1440
  cancelAtPeriodEnd: subscription.cancelAtPeriodEnd
1441
1441
  }
1442
1442
  ) }),
1443
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableCell, { className: "font-medium", children: formatPlanName3(price, t) }),
1444
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableCell, { className: "text-muted-foreground text-sm", children: period }),
1445
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableCell, { className: "text-end font-medium", children: amount }),
1446
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableCell, { className: "text-end", children: (subscription.status === "active" /* ACTIVE */ || subscription.status === "trialing" /* TRIALING */) && onChangePlan && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1447
- _chunkSZQNUGDGjs.Button,
1443
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableCell, { className: "font-medium", children: formatPlanName3(price, t) }),
1444
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableCell, { className: "text-muted-foreground text-sm", children: period }),
1445
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableCell, { className: "text-end font-medium", children: amount }),
1446
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableCell, { className: "text-end", children: (subscription.status === "active" /* ACTIVE */ || subscription.status === "trialing" /* TRIALING */) && onChangePlan && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1447
+ _chunk3VEQ5JZJjs.Button,
1448
1448
  {
1449
1449
  size: "sm",
1450
1450
  variant: "outline",
@@ -1490,7 +1490,7 @@ function SubscriptionsContainer({ onOpenWizard, hasActiveRecurringSubscription }
1490
1490
  const loadSubscriptions = _react.useCallback.call(void 0, async () => {
1491
1491
  setLoading(true);
1492
1492
  try {
1493
- const fetchedSubscriptions = await _chunkVVJDWQEIjs.StripeSubscriptionService.listSubscriptions();
1493
+ const fetchedSubscriptions = await _chunkS5MQDWWCjs.StripeSubscriptionService.listSubscriptions();
1494
1494
  setSubscriptions(fetchedSubscriptions);
1495
1495
  } catch (error) {
1496
1496
  console.error("[SubscriptionsContainer] Failed to load subscriptions:", error);
@@ -1513,7 +1513,7 @@ function SubscriptionsContainer({ onOpenWizard, hasActiveRecurringSubscription }
1513
1513
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.CreditCard, { className: "h-8 w-8" }),
1514
1514
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h1", { className: "text-primary text-3xl font-semibold", children: t("billing.ui.subscriptions.title") })
1515
1515
  ] }),
1516
- subscriptions.length > 0 && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Button, { onClick: () => _optionalChain([onOpenWizard, 'optionalCall', _43 => _43()]), children: hasActiveRecurringSubscription ? t("billing.ui.subscriptions.purchase_addons") : t("billing.ui.subscriptions.subscribe") })
1516
+ subscriptions.length > 0 && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Button, { onClick: () => _optionalChain([onOpenWizard, 'optionalCall', _43 => _43()]), children: hasActiveRecurringSubscription ? t("billing.ui.subscriptions.purchase_addons") : t("billing.ui.subscriptions.subscribe") })
1517
1517
  ] }),
1518
1518
  criticalSubscriptions.map((subscription) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, BillingAlertBanner, { subscription }, subscription.id)),
1519
1519
  subscriptions.length === 0 && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex flex-col items-center justify-center py-12 space-y-4", children: [
@@ -1521,7 +1521,7 @@ function SubscriptionsContainer({ onOpenWizard, hasActiveRecurringSubscription }
1521
1521
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "text-center", children: [
1522
1522
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h3", { className: "text-sm font-medium mb-2", children: t("billing.ui.subscriptions.empty_title") }),
1523
1523
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-muted-foreground mb-6", children: t("billing.ui.subscriptions.empty_description") }),
1524
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Button, { onClick: () => _optionalChain([onOpenWizard, 'optionalCall', _44 => _44()]), children: t("billing.ui.subscriptions.subscribe") })
1524
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Button, { onClick: () => _optionalChain([onOpenWizard, 'optionalCall', _44 => _44()]), children: t("billing.ui.subscriptions.subscribe") })
1525
1525
  ] })
1526
1526
  ] }),
1527
1527
  subscriptions.length > 0 && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
@@ -1544,9 +1544,9 @@ function IntervalToggle({ value, onChange, hasMonthly, hasYearly }) {
1544
1544
  if (!hasMonthly || !hasYearly) {
1545
1545
  return null;
1546
1546
  }
1547
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Tabs, { value, onValueChange: (v) => onChange(v), children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.TabsList, { children: [
1548
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TabsTrigger, { value: "month", children: t("billing.admin.prices.interval.month") }),
1549
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TabsTrigger, { value: "year", children: t("billing.admin.prices.interval.year") })
1547
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Tabs, { value, onValueChange: (v) => onChange(v), children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.TabsList, { children: [
1548
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TabsTrigger, { value: "month", children: t("billing.admin.prices.interval.month") }),
1549
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TabsTrigger, { value: "year", children: t("billing.admin.prices.interval.year") })
1550
1550
  ] }) });
1551
1551
  }
1552
1552
  _chunk7QVYU63Ejs.__name.call(void 0, IntervalToggle, "IntervalToggle");
@@ -1564,11 +1564,11 @@ function PricingCard({
1564
1564
  onSelect
1565
1565
  }) {
1566
1566
  const t = _nextintl.useTranslations.call(void 0, );
1567
- const fmt = _chunkSZQNUGDGjs.useBillingFormatOptions.call(void 0, );
1567
+ const fmt = _chunk3VEQ5JZJjs.useBillingFormatOptions.call(void 0, );
1568
1568
  const description = price.description || price.nickname || t("billing.ui.pricing.standard");
1569
1569
  const features = price.features || [];
1570
- const formattedPrice = _chunkSZQNUGDGjs.formatCurrency.call(void 0, price.unitAmount, price.currency, fmt);
1571
- const interval = _chunkSZQNUGDGjs.formatInterval.call(void 0, price, fmt);
1570
+ const formattedPrice = _chunk3VEQ5JZJjs.formatCurrency.call(void 0, price.unitAmount, price.currency, fmt);
1571
+ const interval = _chunk3VEQ5JZJjs.formatInterval.call(void 0, price, fmt);
1572
1572
  const handleKeyDown = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (e) => {
1573
1573
  if ((e.key === "Enter" || e.key === " ") && !isDisabled && !isCurrentPlan) {
1574
1574
  e.preventDefault();
@@ -1581,7 +1581,7 @@ function PricingCard({
1581
1581
  }
1582
1582
  }, "handleClick");
1583
1583
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
1584
- _chunkSZQNUGDGjs.Card,
1584
+ _chunk3VEQ5JZJjs.Card,
1585
1585
  {
1586
1586
  role: "radio",
1587
1587
  "aria-checked": isSelected,
@@ -1589,7 +1589,7 @@ function PricingCard({
1589
1589
  tabIndex: isDisabled ? -1 : 0,
1590
1590
  onKeyDown: handleKeyDown,
1591
1591
  onClick: handleClick,
1592
- className: _chunkVVJDWQEIjs.cn.call(void 0,
1592
+ className: _chunkS5MQDWWCjs.cn.call(void 0,
1593
1593
  "relative cursor-pointer transition-all duration-200 flex flex-col h-full",
1594
1594
  "focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2",
1595
1595
  isCurrentPlan && "bg-muted/30",
@@ -1599,9 +1599,9 @@ function PricingCard({
1599
1599
  isLoading && "pointer-events-none"
1600
1600
  ),
1601
1601
  children: [
1602
- isCurrentPlan && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Badge, { variant: "secondary", className: "absolute top-2 end-2", children: t("billing.ui.pricing.current") }),
1603
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.CardHeader, { className: "pb-2", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h3", { className: "text-sm font-medium", children: description }) }),
1604
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.CardContent, { className: "pb-4 grow", children: [
1602
+ isCurrentPlan && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Badge, { variant: "secondary", className: "absolute top-2 end-2", children: t("billing.ui.pricing.current") }),
1603
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.CardHeader, { className: "pb-2", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h3", { className: "text-sm font-medium", children: description }) }),
1604
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.CardContent, { className: "pb-4 grow", children: [
1605
1605
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "mb-4", children: [
1606
1606
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-3xl font-bold", children: formattedPrice }),
1607
1607
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-muted-foreground ms-1", children: interval })
@@ -1611,8 +1611,8 @@ function PricingCard({
1611
1611
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-sm text-muted-foreground", children: feature })
1612
1612
  ] }, index)) })
1613
1613
  ] }),
1614
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.CardFooter, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1615
- _chunkSZQNUGDGjs.Button,
1614
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.CardFooter, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1615
+ _chunk3VEQ5JZJjs.Button,
1616
1616
  {
1617
1617
  variant: isCurrentPlan ? "secondary" : isSelected ? "default" : "outline",
1618
1618
  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, _chunkSZQNUGDGjs.SectionHeader, { children: product.name }),
1648
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.SectionHeader, { children: product.name }),
1649
1649
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1650
1650
  "div",
1651
1651
  {
@@ -1746,15 +1746,15 @@ function ProductPricingList({
1746
1746
  _chunk7QVYU63Ejs.__name.call(void 0, ProductPricingList, "ProductPricingList");
1747
1747
  function ProductPricingListSkeleton() {
1748
1748
  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: [
1749
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Skeleton, { className: "h-6 w-32" }),
1749
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Skeleton, { className: "h-6 w-32" }),
1750
1750
  /* @__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: [
1751
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Skeleton, { className: "h-6 w-24" }),
1752
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Skeleton, { className: "h-8 w-32" }),
1751
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Skeleton, { className: "h-6 w-24" }),
1752
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Skeleton, { className: "h-8 w-32" }),
1753
1753
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2", children: [
1754
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Skeleton, { className: "h-4 w-full" }),
1755
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Skeleton, { className: "h-4 w-3/4" })
1754
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Skeleton, { className: "h-4 w-full" }),
1755
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Skeleton, { className: "h-4 w-3/4" })
1756
1756
  ] }),
1757
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Skeleton, { className: "h-10 w-full" })
1757
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Skeleton, { className: "h-10 w-full" })
1758
1758
  ] }, cardIndex)) })
1759
1759
  ] }, rowIndex)) });
1760
1760
  }
@@ -1765,21 +1765,21 @@ _chunk7QVYU63Ejs.__name.call(void 0, ProductPricingListSkeleton, "ProductPricing
1765
1765
 
1766
1766
  function ProrationPreview({ preview }) {
1767
1767
  const t = _nextintl.useTranslations.call(void 0, );
1768
- const fmt = _chunkSZQNUGDGjs.useBillingFormatOptions.call(void 0, );
1768
+ const fmt = _chunk3VEQ5JZJjs.useBillingFormatOptions.call(void 0, );
1769
1769
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "bg-primary/10 border-primary/30 rounded-lg border p-4", children: [
1770
1770
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h4", { className: "text-primary mb-3 font-semibold", children: t("billing.ui.proration.title") }),
1771
1771
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2", children: [
1772
1772
  preview.lineItems.map((item, index) => /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex justify-between text-sm", children: [
1773
1773
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-muted-foreground", children: item.description }),
1774
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: `font-medium ${item.amount < 0 ? "text-success" : "text-foreground"}`, children: _chunkSZQNUGDGjs.formatCurrency.call(void 0, item.amount, preview.currency, fmt) })
1774
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: `font-medium ${item.amount < 0 ? "text-success" : "text-foreground"}`, children: _chunk3VEQ5JZJjs.formatCurrency.call(void 0, item.amount, preview.currency, fmt) })
1775
1775
  ] }, index)),
1776
1776
  /* @__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: [
1777
1777
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-foreground", children: t("billing.ui.proration.net_due_today") }),
1778
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-foreground", children: _chunkSZQNUGDGjs.formatCurrency.call(void 0, preview.immediateCharge, preview.currency, fmt) })
1778
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-foreground", children: _chunk3VEQ5JZJjs.formatCurrency.call(void 0, preview.immediateCharge, preview.currency, fmt) })
1779
1779
  ] }) }),
1780
1780
  preview.lineItems.length > 0 && preview.lineItems[0].period && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "text-muted-foreground mt-2 text-xs", children: t("billing.ui.proration.next_invoice", {
1781
- date: _chunkSZQNUGDGjs.formatDate.call(void 0, preview.lineItems[0].period.end, fmt),
1782
- amount: _chunkSZQNUGDGjs.formatCurrency.call(void 0, preview.amountDue, preview.currency, fmt)
1781
+ date: _chunk3VEQ5JZJjs.formatDate.call(void 0, preview.lineItems[0].period.end, fmt),
1782
+ amount: _chunk3VEQ5JZJjs.formatCurrency.call(void 0, preview.amountDue, preview.currency, fmt)
1783
1783
  }) })
1784
1784
  ] })
1785
1785
  ] });
@@ -1792,7 +1792,7 @@ _chunk7QVYU63Ejs.__name.call(void 0, ProrationPreview, "ProrationPreview");
1792
1792
 
1793
1793
  function SubscriptionConfirmation({ price, isLoading, onConfirm, onCancel }) {
1794
1794
  const t = _nextintl.useTranslations.call(void 0, );
1795
- const fmt = _chunkSZQNUGDGjs.useBillingFormatOptions.call(void 0, );
1795
+ const fmt = _chunk3VEQ5JZJjs.useBillingFormatOptions.call(void 0, );
1796
1796
  const productName = _optionalChain([price, 'access', _50 => _50.product, 'optionalAccess', _51 => _51.name]) || price.nickname || t("billing.ui.wizard.review.selected_plan");
1797
1797
  const productDescription = _optionalChain([price, 'access', _52 => _52.product, 'optionalAccess', _53 => _53.description]) || price.description;
1798
1798
  const features = price.features || [];
@@ -1804,16 +1804,16 @@ function SubscriptionConfirmation({ price, isLoading, onConfirm, onCancel }) {
1804
1804
  productDescription && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "text-sm text-muted-foreground", children: productDescription })
1805
1805
  ] }),
1806
1806
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "text-lg font-semibold", children: [
1807
- _chunkSZQNUGDGjs.formatCurrency.call(void 0, price.unitAmount, price.currency, fmt),
1808
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-sm font-normal text-muted-foreground", children: _chunkSZQNUGDGjs.formatInterval.call(void 0, price, fmt) })
1807
+ _chunk3VEQ5JZJjs.formatCurrency.call(void 0, price.unitAmount, price.currency, fmt),
1808
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-sm font-normal text-muted-foreground", children: _chunk3VEQ5JZJjs.formatInterval.call(void 0, price, fmt) })
1809
1809
  ] }),
1810
1810
  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: [
1811
1811
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.Check, { className: "h-4 w-4 text-primary" }),
1812
1812
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: feature })
1813
1813
  ] }, index)) }),
1814
1814
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex justify-end gap-3 pt-2 border-t border-accent/30", children: [
1815
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Button, { variant: "outline", onClick: onCancel, disabled: isLoading, children: t("ui.buttons.cancel") }),
1816
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Button, { onClick: onConfirm, disabled: isLoading, children: isLoading ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
1815
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Button, { variant: "outline", onClick: onCancel, disabled: isLoading, children: t("ui.buttons.cancel") }),
1816
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Button, { onClick: onConfirm, disabled: isLoading, children: isLoading ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
1817
1817
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.Loader2, { className: "h-4 w-4 animate-spin me-2" }),
1818
1818
  t("billing.ui.wizard.review.processing")
1819
1819
  ] }) : t("billing.ui.confirmation.subscribe") })
@@ -1877,7 +1877,7 @@ function wizardReducer(state, action) {
1877
1877
  _chunk7QVYU63Ejs.__name.call(void 0, wizardReducer, "wizardReducer");
1878
1878
  function useSubscriptionWizard({ subscription, onSuccess, onClose }) {
1879
1879
  const t = _nextintl.useTranslations.call(void 0, );
1880
- const locale = _chunkVVJDWQEIjs.useI18nLocale.call(void 0, );
1880
+ const locale = _chunkS5MQDWWCjs.useI18nLocale.call(void 0, );
1881
1881
  const [state, dispatch] = _react.useReducer.call(void 0, wizardReducer, {
1882
1882
  ...initialState,
1883
1883
  selectedPrice: _optionalChain([subscription, 'optionalAccess', _54 => _54.price]) || null
@@ -1888,7 +1888,7 @@ function useSubscriptionWizard({ subscription, onSuccess, onClose }) {
1888
1888
  onCloseRef.current = onClose;
1889
1889
  const checkPaymentMethod = _react.useCallback.call(void 0, async () => {
1890
1890
  try {
1891
- const methods = await _chunkVVJDWQEIjs.StripeCustomerService.listPaymentMethods();
1891
+ const methods = await _chunkS5MQDWWCjs.StripeCustomerService.listPaymentMethods();
1892
1892
  dispatch({ type: "SET_HAS_PAYMENT_METHOD", hasMethod: methods.length > 0 });
1893
1893
  } catch (error) {
1894
1894
  console.error("[useSubscriptionWizard] Failed to check payment methods:", error);
@@ -1912,7 +1912,7 @@ function useSubscriptionWizard({ subscription, onSuccess, onClose }) {
1912
1912
  const isTrialUpgrade = _optionalChain([subscription, 'optionalAccess', _55 => _55.status]) === "trialing" /* TRIALING */;
1913
1913
  dispatch({ type: "SET_IS_TRIAL_SUBSCRIPTION", isTrial: isTrialUpgrade });
1914
1914
  if (isTrialUpgrade && !state.hasPaymentMethod) {
1915
- const methods = await _chunkVVJDWQEIjs.StripeCustomerService.listPaymentMethods();
1915
+ const methods = await _chunkS5MQDWWCjs.StripeCustomerService.listPaymentMethods();
1916
1916
  if (methods.length === 0) {
1917
1917
  dispatch({ type: "SET_STEP", step: "payment-method" });
1918
1918
  dispatch({
@@ -1923,7 +1923,7 @@ function useSubscriptionWizard({ subscription, onSuccess, onClose }) {
1923
1923
  }
1924
1924
  }
1925
1925
  if (subscription && state.selectedPrice.id !== _optionalChain([subscription, 'access', _56 => _56.price, 'optionalAccess', _57 => _57.id])) {
1926
- const preview = await _chunkVVJDWQEIjs.StripeSubscriptionService.getProrationPreview({
1926
+ const preview = await _chunkS5MQDWWCjs.StripeSubscriptionService.getProrationPreview({
1927
1927
  subscriptionId: subscription.id,
1928
1928
  newPriceId: state.selectedPrice.id
1929
1929
  });
@@ -1948,14 +1948,14 @@ function useSubscriptionWizard({ subscription, onSuccess, onClose }) {
1948
1948
  newPriceId: state.selectedPrice.id,
1949
1949
  promotionCode: _optionalChain([state, 'access', _59 => _59.promotionCode, 'optionalAccess', _60 => _60.promotionCodeId])
1950
1950
  };
1951
- await _chunkVVJDWQEIjs.StripeSubscriptionService.changePlan(changePlanParams);
1951
+ await _chunkS5MQDWWCjs.StripeSubscriptionService.changePlan(changePlanParams);
1952
1952
  } else {
1953
1953
  const createParams = {
1954
1954
  id: _uuid.v4.call(void 0, ),
1955
1955
  priceId: state.selectedPrice.id,
1956
1956
  promotionCode: _optionalChain([state, 'access', _61 => _61.promotionCode, 'optionalAccess', _62 => _62.promotionCodeId])
1957
1957
  };
1958
- await _chunkVVJDWQEIjs.StripeSubscriptionService.createSubscription(createParams);
1958
+ await _chunkS5MQDWWCjs.StripeSubscriptionService.createSubscription(createParams);
1959
1959
  }
1960
1960
  onSuccessRef.current();
1961
1961
  onCloseRef.current();
@@ -1989,7 +1989,7 @@ function useSubscriptionWizard({ subscription, onSuccess, onClose }) {
1989
1989
  dispatch({ type: "SET_VALIDATING_PROMO_CODE", isValidating: true });
1990
1990
  dispatch({ type: "SET_PROMO_CODE_ERROR", error: null });
1991
1991
  try {
1992
- const result = await _chunkVVJDWQEIjs.StripePromotionCodeService.validatePromotionCode({
1992
+ const result = await _chunkS5MQDWWCjs.StripePromotionCodeService.validatePromotionCode({
1993
1993
  code,
1994
1994
  stripePriceId: _optionalChain([state, 'access', _70 => _70.selectedPrice, 'optionalAccess', _71 => _71.id]),
1995
1995
  language: locale
@@ -2107,7 +2107,7 @@ function WizardStepPlanSelection({
2107
2107
  _react.useEffect.call(void 0, () => {
2108
2108
  const loadProducts = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
2109
2109
  try {
2110
- const fetchedProducts = await _chunkVVJDWQEIjs.StripeProductService.listProducts({ active: true });
2110
+ const fetchedProducts = await _chunkS5MQDWWCjs.StripeProductService.listProducts({ active: true });
2111
2111
  setProducts(fetchedProducts);
2112
2112
  } catch (error) {
2113
2113
  console.error("[WizardStepPlanSelection] Failed to load products:", error);
@@ -2158,7 +2158,7 @@ function WizardStepPlanSelection({
2158
2158
  onSelectPrice: handleSelectPrice
2159
2159
  }
2160
2160
  ),
2161
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "flex justify-end pt-4 border-t", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Button, { onClick: onNext, disabled: !selectedPrice || isProcessing, children: isProcessing ? t("common.loading") : t("billing.ui.wizard.next_review") }) })
2161
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "flex justify-end pt-4 border-t", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Button, { onClick: onNext, disabled: !selectedPrice || isProcessing, children: isProcessing ? t("common.loading") : t("billing.ui.wizard.next_review") }) })
2162
2162
  ] });
2163
2163
  }
2164
2164
  _chunk7QVYU63Ejs.__name.call(void 0, WizardStepPlanSelection, "WizardStepPlanSelection");
@@ -2181,7 +2181,7 @@ function PromoCodeInput({
2181
2181
  disabled = false
2182
2182
  }) {
2183
2183
  const t = _nextintl.useTranslations.call(void 0, );
2184
- const locale = _chunkVVJDWQEIjs.useI18nLocale.call(void 0, );
2184
+ const locale = _chunkS5MQDWWCjs.useI18nLocale.call(void 0, );
2185
2185
  const [code, setCode] = _react.useState.call(void 0, "");
2186
2186
  const handleApply = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, () => {
2187
2187
  if (code.trim()) {
@@ -2200,7 +2200,7 @@ function PromoCodeInput({
2200
2200
  }
2201
2201
  const amount = (result.discountValue || 0) / 100;
2202
2202
  const currency = _optionalChain([result, 'access', _80 => _80.currency, 'optionalAccess', _81 => _81.toUpperCase, 'call', _82 => _82()]) || "USD";
2203
- return t("billing.ui.wizard.review.amount_off", { amount: `${currency} ${_chunkSZQNUGDGjs.formatFixed.call(void 0, amount, locale, 2)}` });
2203
+ return t("billing.ui.wizard.review.amount_off", { amount: `${currency} ${_chunk3VEQ5JZJjs.formatFixed.call(void 0, amount, locale, 2)}` });
2204
2204
  }, "formatDiscount");
2205
2205
  const formatDuration = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (result) => {
2206
2206
  switch (result.duration) {
@@ -2223,7 +2223,7 @@ function PromoCodeInput({
2223
2223
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-success text-sm", children: formatDiscount(appliedCode) })
2224
2224
  ] }),
2225
2225
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
2226
- _chunkSZQNUGDGjs.Button,
2226
+ _chunk3VEQ5JZJjs.Button,
2227
2227
  {
2228
2228
  variant: "ghost",
2229
2229
  size: "sm",
@@ -2240,7 +2240,7 @@ function PromoCodeInput({
2240
2240
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2", children: [
2241
2241
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex gap-2", children: [
2242
2242
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
2243
- _chunkSZQNUGDGjs.Input,
2243
+ _chunk3VEQ5JZJjs.Input,
2244
2244
  {
2245
2245
  placeholder: t("billing.ui.promo_code.placeholder"),
2246
2246
  value: code,
@@ -2250,7 +2250,7 @@ function PromoCodeInput({
2250
2250
  className: "flex-1"
2251
2251
  }
2252
2252
  ),
2253
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.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" }) : t("billing.ui.promo_code.apply") })
2253
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.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" }) : t("billing.ui.promo_code.apply") })
2254
2254
  ] }),
2255
2255
  error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-destructive text-xs/relaxed", children: error })
2256
2256
  ] });
@@ -2277,7 +2277,7 @@ function WizardStepReview({
2277
2277
  isTrialUpgrade
2278
2278
  }) {
2279
2279
  const t = _nextintl.useTranslations.call(void 0, );
2280
- const fmt = _chunkSZQNUGDGjs.useBillingFormatOptions.call(void 0, );
2280
+ const fmt = _chunk3VEQ5JZJjs.useBillingFormatOptions.call(void 0, );
2281
2281
  if (!selectedPrice) {
2282
2282
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "text-center py-8 text-muted-foreground", children: t("billing.ui.wizard.review.no_plan") });
2283
2283
  }
@@ -2318,7 +2318,7 @@ function WizardStepReview({
2318
2318
  }
2319
2319
  if (promotionCode.discountType === "amount_off" && promotionCode.discountValue) {
2320
2320
  return t("billing.ui.wizard.review.amount_off", {
2321
- amount: _chunkSZQNUGDGjs.formatCurrency.call(void 0, promotionCode.discountValue, promotionCode.currency || selectedPrice.currency, fmt)
2321
+ amount: _chunk3VEQ5JZJjs.formatCurrency.call(void 0, promotionCode.discountValue, promotionCode.currency || selectedPrice.currency, fmt)
2322
2322
  });
2323
2323
  }
2324
2324
  return null;
@@ -2326,7 +2326,7 @@ function WizardStepReview({
2326
2326
  const discountDescription = getDiscountDescription();
2327
2327
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-6", children: [
2328
2328
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "bg-muted/50 rounded-lg p-4 space-y-3", children: [
2329
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.SectionHeader, { children: t("billing.ui.wizard.review.selected_plan") }),
2329
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.SectionHeader, { children: t("billing.ui.wizard.review.selected_plan") }),
2330
2330
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex justify-between items-center", children: [
2331
2331
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { children: [
2332
2332
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "font-medium", children: _optionalChain([selectedPrice, 'access', _92 => _92.product, 'optionalAccess', _93 => _93.name]) }),
@@ -2334,10 +2334,10 @@ function WizardStepReview({
2334
2334
  ] }),
2335
2335
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "text-end", children: [
2336
2336
  discountedPrice !== null ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
2337
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-sm text-muted-foreground line-through", children: _chunkSZQNUGDGjs.formatCurrency.call(void 0, selectedPrice.unitAmount || 0, selectedPrice.currency, fmt) }),
2338
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-success text-lg font-semibold", children: _chunkSZQNUGDGjs.formatCurrency.call(void 0, discountedPrice, selectedPrice.currency, fmt) }),
2339
- discountDescription && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Badge, { variant: "softGreen", children: discountDescription })
2340
- ] }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "font-semibold text-lg", children: _chunkSZQNUGDGjs.formatCurrency.call(void 0, selectedPrice.unitAmount || 0, selectedPrice.currency, fmt) }),
2337
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-sm text-muted-foreground line-through", children: _chunk3VEQ5JZJjs.formatCurrency.call(void 0, selectedPrice.unitAmount || 0, selectedPrice.currency, fmt) }),
2338
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-success text-lg font-semibold", children: _chunk3VEQ5JZJjs.formatCurrency.call(void 0, discountedPrice, selectedPrice.currency, fmt) }),
2339
+ discountDescription && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Badge, { variant: "softGreen", children: discountDescription })
2340
+ ] }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "font-semibold text-lg", children: _chunk3VEQ5JZJjs.formatCurrency.call(void 0, selectedPrice.unitAmount || 0, selectedPrice.currency, fmt) }),
2341
2341
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-sm text-muted-foreground", children: formatInterval2(selectedPrice) })
2342
2342
  ] })
2343
2343
  ] })
@@ -2352,9 +2352,9 @@ function WizardStepReview({
2352
2352
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex justify-between text-sm", children: [
2353
2353
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: `${isTrialUpgrade ? "text-warning" : "text-muted-foreground"}`, children: isTrialUpgrade ? t("billing.ui.wizard.review.charge_now") : t("billing.ui.wizard.review.due_now") }),
2354
2354
  /* @__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: [
2355
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "line-through text-muted-foreground me-2", children: _chunkSZQNUGDGjs.formatCurrency.call(void 0, prorationPreview.immediateCharge, prorationPreview.currency, fmt) }),
2356
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-success", children: _chunkSZQNUGDGjs.formatCurrency.call(void 0, discountedImmediateCharge, prorationPreview.currency, fmt) })
2357
- ] }) : _chunkSZQNUGDGjs.formatCurrency.call(void 0, prorationPreview.immediateCharge, prorationPreview.currency, fmt) })
2355
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "line-through text-muted-foreground me-2", children: _chunk3VEQ5JZJjs.formatCurrency.call(void 0, prorationPreview.immediateCharge, prorationPreview.currency, fmt) }),
2356
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-success", children: _chunk3VEQ5JZJjs.formatCurrency.call(void 0, discountedImmediateCharge, prorationPreview.currency, fmt) })
2357
+ ] }) : _chunk3VEQ5JZJjs.formatCurrency.call(void 0, prorationPreview.immediateCharge, prorationPreview.currency, fmt) })
2358
2358
  ] })
2359
2359
  ]
2360
2360
  }
@@ -2378,15 +2378,15 @@ function WizardStepReview({
2378
2378
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h4", { className: "font-medium", children: t("billing.ui.payment_method.title") }),
2379
2379
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-sm text-muted-foreground", children: hasPaymentMethod ? t("billing.ui.wizard.review.payment_on_file") : t("billing.ui.wizard.review.no_payment_on_file") })
2380
2380
  ] }),
2381
- !hasPaymentMethod && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Button, { variant: "outline", onClick: onAddPaymentMethod, children: t("billing.ui.payment_methods.add") })
2381
+ !hasPaymentMethod && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Button, { variant: "outline", onClick: onAddPaymentMethod, children: t("billing.ui.payment_methods.add") })
2382
2382
  ] }) }),
2383
- error && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.Alert, { variant: "destructive", children: [
2383
+ error && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.Alert, { variant: "destructive", children: [
2384
2384
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.AlertCircle, { className: "h-4 w-4" }),
2385
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.AlertDescription, { children: error })
2385
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.AlertDescription, { children: error })
2386
2386
  ] }),
2387
2387
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex justify-between pt-4 border-t", children: [
2388
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Button, { variant: "outline", onClick: onBack, disabled: isProcessing, children: t("billing.ui.wizard.back") }),
2389
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Button, { onClick: hasPaymentMethod ? onConfirm : onAddPaymentMethod, disabled: isProcessing, children: isProcessing ? t("billing.ui.wizard.review.processing") : hasPaymentMethod ? isChangingPlan ? t("billing.ui.wizard.review.confirm_change") : t("billing.ui.wizard.review.subscribe_now") : t("billing.ui.payment_methods.add") })
2388
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Button, { variant: "outline", onClick: onBack, disabled: isProcessing, children: t("billing.ui.wizard.back") }),
2389
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Button, { onClick: hasPaymentMethod ? onConfirm : onAddPaymentMethod, disabled: isProcessing, children: isProcessing ? t("billing.ui.wizard.review.processing") : hasPaymentMethod ? isChangingPlan ? t("billing.ui.wizard.review.confirm_change") : t("billing.ui.wizard.review.subscribe_now") : t("billing.ui.payment_methods.add") })
2390
2390
  ] })
2391
2391
  ] });
2392
2392
  }
@@ -2399,7 +2399,7 @@ function WizardStepPaymentMethod({ onBack, onSuccess, isProcessing }) {
2399
2399
  const t = _nextintl.useTranslations.call(void 0, );
2400
2400
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-6", children: [
2401
2401
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "text-center", children: [
2402
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.SectionHeader, { children: t("billing.ui.payment_methods.add") }),
2402
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.SectionHeader, { children: t("billing.ui.payment_methods.add") }),
2403
2403
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-sm text-muted-foreground", children: t("billing.ui.wizard.payment_description") })
2404
2404
  ] }),
2405
2405
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, PaymentMethodForm, { onSuccess, onCancel: onBack, isLoading: isProcessing })
@@ -2442,10 +2442,10 @@ function SubscriptionWizard({
2442
2442
  const isChangePlanMode = !!subscription;
2443
2443
  const dialogTitle = subscription ? t("billing.ui.wizard.change_title") : isPurchasingAddons ? t("billing.ui.subscriptions.purchase_addons") : t("billing.ui.subscriptions.subscribe");
2444
2444
  const dialogDescription = subscription ? t("billing.ui.wizard.change_description") : isPurchasingAddons ? t("billing.ui.wizard.addons_description") : t("billing.ui.wizard.subscribe_description");
2445
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Dialog, { open, onOpenChange, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.DialogContent, { className: "max-w-2xl", children: [
2446
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.DialogHeader, { children: [
2447
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.DialogTitle, { children: dialogTitle }),
2448
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.DialogDescription, { children: dialogDescription })
2445
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Dialog, { open, onOpenChange, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.DialogContent, { className: "max-w-2xl", children: [
2446
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.DialogHeader, { children: [
2447
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.DialogTitle, { children: dialogTitle }),
2448
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.DialogDescription, { children: dialogDescription })
2449
2449
  ] }),
2450
2450
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, WizardProgressIndicator, { currentStep: state.step }),
2451
2451
  state.step === "plan-selection" && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
@@ -2524,7 +2524,7 @@ function formatDate2(date, { locale, t }) {
2524
2524
  _chunk7QVYU63Ejs.__name.call(void 0, formatDate2, "formatDate");
2525
2525
  function UsageSummaryCard({ meter, summary }) {
2526
2526
  const t = _nextintl.useTranslations.call(void 0, );
2527
- const fmt = _chunkSZQNUGDGjs.useBillingFormatOptions.call(void 0, );
2527
+ const fmt = _chunk3VEQ5JZJjs.useBillingFormatOptions.call(void 0, );
2528
2528
  const currentUsage = _nullishCoalesce(_optionalChain([summary, 'optionalAccess', _96 => _96.aggregatedValue]), () => ( 0));
2529
2529
  const limit = meter.limit;
2530
2530
  const percentage = limit && limit > 0 ? currentUsage / limit * 100 : null;
@@ -2532,15 +2532,15 @@ function UsageSummaryCard({ meter, summary }) {
2532
2532
  const progressWidth = percentage !== null ? Math.min(percentage, 100) : 0;
2533
2533
  const displayName = meter.displayName || meter.eventName;
2534
2534
  const hasLimit = limit !== null && limit !== void 0;
2535
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.Card, { children: [
2536
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.CardHeader, { className: "flex flex-row items-center gap-x-3 pb-3", children: [
2535
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.Card, { children: [
2536
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.CardHeader, { className: "flex flex-row items-center gap-x-3 pb-3", children: [
2537
2537
  /* @__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" }) }),
2538
2538
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex flex-col", children: [
2539
2539
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h3", { className: "text-sm font-medium", children: displayName }),
2540
2540
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-muted-foreground text-xs", children: meter.id })
2541
2541
  ] })
2542
2542
  ] }),
2543
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.CardContent, { className: "flex flex-col gap-y-4", children: [
2543
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.CardContent, { className: "flex flex-col gap-y-4", children: [
2544
2544
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { children: [
2545
2545
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-3xl font-bold", children: currentUsage.toLocaleString(fmt.locale) }),
2546
2546
  hasLimit && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-muted-foreground text-sm", children: t("billing.ui.usage.of_limit_used", { limit: limit.toLocaleString(fmt.locale) }) })
@@ -2548,7 +2548,7 @@ function UsageSummaryCard({ meter, summary }) {
2548
2548
  hasLimit ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex flex-col gap-y-2", children: [
2549
2549
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "h-2 w-full overflow-hidden rounded-full bg-gray-200", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: `h-full transition-all ${progressColor}`, style: { width: `${progressWidth}%` } }) }),
2550
2550
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-muted-foreground text-sm", children: t("billing.ui.usage.percent_used", {
2551
- value: percentage !== null ? _chunkSZQNUGDGjs.formatFixed.call(void 0, percentage, fmt.locale, 1) : ""
2551
+ value: percentage !== null ? _chunk3VEQ5JZJjs.formatFixed.call(void 0, percentage, fmt.locale, 1) : ""
2552
2552
  }) })
2553
2553
  ] }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-muted-foreground text-sm", children: t("billing.ui.usage.no_limit") }),
2554
2554
  summary && summary.start && summary.end && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "border-t pt-3", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-muted-foreground text-xs", children: t("billing.ui.usage.period", {
@@ -2581,14 +2581,14 @@ function UsageContainer() {
2581
2581
  const loadUsageData = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
2582
2582
  setLoading(true);
2583
2583
  try {
2584
- const fetchedSubscriptions = await _chunkVVJDWQEIjs.StripeSubscriptionService.listSubscriptions();
2584
+ const fetchedSubscriptions = await _chunkS5MQDWWCjs.StripeSubscriptionService.listSubscriptions();
2585
2585
  setSubscriptions(fetchedSubscriptions);
2586
2586
  const hasMeteredSubscriptions2 = fetchedSubscriptions.some((sub) => _optionalChain([sub, 'access', _97 => _97.price, 'optionalAccess', _98 => _98.recurring, 'optionalAccess', _99 => _99.usageType]) === "metered");
2587
2587
  if (!hasMeteredSubscriptions2) {
2588
2588
  setLoading(false);
2589
2589
  return;
2590
2590
  }
2591
- const fetchedMeters = await _chunkVVJDWQEIjs.StripeUsageService.listMeters();
2591
+ const fetchedMeters = await _chunkS5MQDWWCjs.StripeUsageService.listMeters();
2592
2592
  setMeters(fetchedMeters);
2593
2593
  const summariesMap = {};
2594
2594
  const now = /* @__PURE__ */ new Date();
@@ -2596,7 +2596,7 @@ function UsageContainer() {
2596
2596
  const endOfMonth = new Date(now.getFullYear(), now.getMonth() + 1, 0, 23, 59, 59, 999);
2597
2597
  for (const meter of fetchedMeters) {
2598
2598
  try {
2599
- const meterSummaries = await _chunkVVJDWQEIjs.StripeUsageService.getMeterSummaries({
2599
+ const meterSummaries = await _chunkS5MQDWWCjs.StripeUsageService.getMeterSummaries({
2600
2600
  meterId: meter.id,
2601
2601
  startTime: startOfMonth,
2602
2602
  endTime: endOfMonth
@@ -2659,27 +2659,27 @@ function formatDateTime(date, { locale, t }) {
2659
2659
  _chunk7QVYU63Ejs.__name.call(void 0, formatDateTime, "formatDateTime");
2660
2660
  function UsageHistoryTable({ usageRecords }) {
2661
2661
  const t = _nextintl.useTranslations.call(void 0, );
2662
- const fmt = _chunkSZQNUGDGjs.useBillingFormatOptions.call(void 0, );
2662
+ const fmt = _chunk3VEQ5JZJjs.useBillingFormatOptions.call(void 0, );
2663
2663
  if (usageRecords.length === 0) {
2664
2664
  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: t("billing.ui.usage.history_empty") }) });
2665
2665
  }
2666
2666
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex w-full flex-col gap-y-4", children: [
2667
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.SectionHeader, { level: 2, children: t("billing.ui.usage.history_title") }),
2668
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "overflow-clip rounded-lg border", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.Table, { children: [
2669
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableHeader, { className: "bg-muted", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.TableRow, { children: [
2670
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableHead, { children: t("billing.ui.columns.date_time") }),
2671
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableHead, { children: t("billing.ui.columns.meter_event") }),
2672
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableHead, { className: "text-end", children: t("billing.ui.columns.quantity") }),
2673
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableHead, { children: t("billing.ui.columns.event_id") })
2667
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.SectionHeader, { level: 2, children: t("billing.ui.usage.history_title") }),
2668
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "overflow-clip rounded-lg border", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.Table, { children: [
2669
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableHeader, { className: "bg-muted", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.TableRow, { children: [
2670
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableHead, { children: t("billing.ui.columns.date_time") }),
2671
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableHead, { children: t("billing.ui.columns.meter_event") }),
2672
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableHead, { className: "text-end", children: t("billing.ui.columns.quantity") }),
2673
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableHead, { children: t("billing.ui.columns.event_id") })
2674
2674
  ] }) }),
2675
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableBody, { children: usageRecords.map((record) => {
2675
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableBody, { children: usageRecords.map((record) => {
2676
2676
  const dateTime = formatDateTime(record.timestamp, fmt);
2677
2677
  const quantity = record.quantity.toLocaleString(fmt.locale);
2678
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.TableRow, { children: [
2679
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableCell, { className: "font-medium", children: dateTime }),
2680
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableCell, { className: "text-muted-foreground", children: record.meterEventName }),
2681
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableCell, { className: "text-end font-medium", children: quantity }),
2682
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.TableCell, { className: "text-muted-foreground text-sm tabular-nums", children: record.stripeEventId })
2678
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.TableRow, { children: [
2679
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableCell, { className: "font-medium", children: dateTime }),
2680
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableCell, { className: "text-muted-foreground", children: record.meterEventName }),
2681
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableCell, { className: "text-end font-medium", children: quantity }),
2682
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.TableCell, { className: "text-muted-foreground text-sm tabular-nums", children: record.stripeEventId })
2683
2683
  ] }, record.id);
2684
2684
  }) })
2685
2685
  ] }) })
@@ -2690,8 +2690,8 @@ _chunk7QVYU63Ejs.__name.call(void 0, UsageHistoryTable, "UsageHistoryTable");
2690
2690
  // src/features/billing/components/modals/BillingDetailModal.tsx
2691
2691
 
2692
2692
  function BillingDetailModal({ open, onOpenChange, title, children, className }) {
2693
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Dialog, { open, onOpenChange, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.DialogContent, { className: _nullishCoalesce(className, () => ( "max-w-4xl max-h-[90vh] overflow-y-auto")), children: [
2694
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.DialogHeader, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.DialogTitle, { children: title }) }),
2693
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Dialog, { open, onOpenChange, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.DialogContent, { className: _nullishCoalesce(className, () => ( "max-w-4xl max-h-[90vh] overflow-y-auto")), children: [
2694
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.DialogHeader, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.DialogTitle, { children: title }) }),
2695
2695
  children
2696
2696
  ] }) });
2697
2697
  }
@@ -2710,7 +2710,7 @@ function BillingAlertBanner({ subscription, onUpdatePayment, onAddPayment }) {
2710
2710
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h3", { className: "text-destructive text-sm font-medium", children: t("billing.ui.alert.payment_failed_title") }),
2711
2711
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-destructive mt-1 text-sm", children: t("billing.ui.alert.payment_failed_description") })
2712
2712
  ] }),
2713
- onUpdatePayment && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Button, { variant: "outline", size: "sm", onClick: onUpdatePayment, className: "text-destructive border-red-300", children: t("billing.ui.alert.update_payment_method") })
2713
+ onUpdatePayment && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Button, { variant: "outline", size: "sm", onClick: onUpdatePayment, className: "text-destructive border-red-300", children: t("billing.ui.alert.update_payment_method") })
2714
2714
  ] });
2715
2715
  }
2716
2716
  if (subscription.status === "trialing" /* TRIALING */ && subscription.trialEnd) {
@@ -2724,7 +2724,7 @@ function BillingAlertBanner({ subscription, onUpdatePayment, onAddPayment }) {
2724
2724
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h3", { className: "text-warning text-sm font-medium", children: t("billing.ui.alert.trial_ending_title") }),
2725
2725
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-warning mt-1 text-sm", children: t("billing.ui.alert.trial_ending_description", { count: daysRemaining }) })
2726
2726
  ] }),
2727
- onAddPayment && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Button, { variant: "outline", size: "sm", onClick: onAddPayment, className: "text-warning border-yellow-300", children: t("billing.ui.payment_methods.add") })
2727
+ onAddPayment && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Button, { variant: "outline", size: "sm", onClick: onAddPayment, className: "text-warning border-yellow-300", children: t("billing.ui.payment_methods.add") })
2728
2728
  ] });
2729
2729
  }
2730
2730
  }
@@ -2776,7 +2776,7 @@ function BillingDashboardContainer() {
2776
2776
  setNoCustomerExists(false);
2777
2777
  let customer = null;
2778
2778
  try {
2779
- customer = await _chunkVVJDWQEIjs.StripeCustomerService.getCustomer();
2779
+ customer = await _chunkS5MQDWWCjs.StripeCustomerService.getCustomer();
2780
2780
  setData((prev) => ({ ...prev, customer }));
2781
2781
  setErrors((prev) => ({ ...prev, customer: null }));
2782
2782
  setNoCustomerExists(false);
@@ -2802,7 +2802,7 @@ function BillingDashboardContainer() {
2802
2802
  }
2803
2803
  const fetchSubscriptions = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
2804
2804
  try {
2805
- const subscriptions2 = await _chunkVVJDWQEIjs.StripeSubscriptionService.listSubscriptions();
2805
+ const subscriptions2 = await _chunkS5MQDWWCjs.StripeSubscriptionService.listSubscriptions();
2806
2806
  setData((prev) => ({ ...prev, subscriptions: subscriptions2 }));
2807
2807
  setErrors((prev) => ({ ...prev, subscriptions: null }));
2808
2808
  return subscriptions2;
@@ -2816,7 +2816,7 @@ function BillingDashboardContainer() {
2816
2816
  }, "fetchSubscriptions");
2817
2817
  const fetchPaymentMethods = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
2818
2818
  try {
2819
- const paymentMethods = await _chunkVVJDWQEIjs.StripeCustomerService.listPaymentMethods();
2819
+ const paymentMethods = await _chunkS5MQDWWCjs.StripeCustomerService.listPaymentMethods();
2820
2820
  setData((prev) => ({ ...prev, paymentMethods }));
2821
2821
  setErrors((prev) => ({ ...prev, paymentMethods: null }));
2822
2822
  } catch (error) {
@@ -2828,7 +2828,7 @@ function BillingDashboardContainer() {
2828
2828
  }, "fetchPaymentMethods");
2829
2829
  const fetchInvoices = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
2830
2830
  try {
2831
- const invoices = await _chunkVVJDWQEIjs.StripeInvoiceService.listInvoices();
2831
+ const invoices = await _chunkS5MQDWWCjs.StripeInvoiceService.listInvoices();
2832
2832
  setData((prev) => ({ ...prev, invoices }));
2833
2833
  setErrors((prev) => ({ ...prev, invoices: null }));
2834
2834
  } catch (error) {
@@ -2851,7 +2851,7 @@ function BillingDashboardContainer() {
2851
2851
  const handleCreateCustomer = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
2852
2852
  setCreatingCustomer(true);
2853
2853
  try {
2854
- await _chunkVVJDWQEIjs.StripeCustomerService.createCustomer();
2854
+ await _chunkS5MQDWWCjs.StripeCustomerService.createCustomer();
2855
2855
  setNoCustomerExists(false);
2856
2856
  await fetchAllData();
2857
2857
  } catch (error) {
@@ -2863,7 +2863,7 @@ function BillingDashboardContainer() {
2863
2863
  }, "handleCreateCustomer");
2864
2864
  const fetchUsageData = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
2865
2865
  try {
2866
- const meters = await _chunkVVJDWQEIjs.StripeUsageService.listMeters();
2866
+ const meters = await _chunkS5MQDWWCjs.StripeUsageService.listMeters();
2867
2867
  setData((prev) => ({ ...prev, meters }));
2868
2868
  const summariesMap = {};
2869
2869
  const now = /* @__PURE__ */ new Date();
@@ -2871,7 +2871,7 @@ function BillingDashboardContainer() {
2871
2871
  const endOfMonth = new Date(now.getFullYear(), now.getMonth() + 1, 0, 23, 59, 59, 999);
2872
2872
  for (const meter of meters) {
2873
2873
  try {
2874
- const meterSummaries = await _chunkVVJDWQEIjs.StripeUsageService.getMeterSummaries({
2874
+ const meterSummaries = await _chunkS5MQDWWCjs.StripeUsageService.getMeterSummaries({
2875
2875
  meterId: meter.id,
2876
2876
  startTime: startOfMonth,
2877
2877
  endTime: endOfMonth
@@ -2949,18 +2949,18 @@ function BillingDashboardContainer() {
2949
2949
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.Wallet, { className: "h-8 w-8" }),
2950
2950
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h1", { className: "text-primary text-3xl font-semibold", children: t("billing.title") })
2951
2951
  ] }),
2952
- isInitialLoading && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Card, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.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" }) }) }),
2953
- noCustomerExists && !isInitialLoading && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.Card, { children: [
2954
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.CardHeader, { className: "text-center", children: [
2952
+ isInitialLoading && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Card, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.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" }) }) }),
2953
+ noCustomerExists && !isInitialLoading && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.Card, { children: [
2954
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.CardHeader, { className: "text-center", children: [
2955
2955
  /* @__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" }) }),
2956
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.CardTitle, { children: t("billing.ui.dashboard.setup_title") }),
2957
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.CardDescription, { children: t("billing.ui.dashboard.setup_description") })
2956
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.CardTitle, { children: t("billing.ui.dashboard.setup_title") }),
2957
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.CardDescription, { children: t("billing.ui.dashboard.setup_description") })
2958
2958
  ] }),
2959
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.CardContent, { className: "flex justify-center pb-8", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Button, { onClick: handleCreateCustomer, disabled: creatingCustomer, size: "lg", children: creatingCustomer ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
2959
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.CardContent, { className: "flex justify-center pb-8", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Button, { onClick: handleCreateCustomer, disabled: creatingCustomer, size: "lg", children: creatingCustomer ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
2960
2960
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.Loader2, { className: "me-2 h-4 w-4 animate-spin" }),
2961
2961
  t("billing.ui.dashboard.setting_up")
2962
2962
  ] }) : t("billing.ui.dashboard.setup_button") }) }),
2963
- errors.customer && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.CardContent, { className: "pt-0", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-center text-destructive text-xs/relaxed", children: t(errors.customer) }) })
2963
+ errors.customer && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.CardContent, { className: "pt-0", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-center text-destructive text-xs/relaxed", children: t(errors.customer) }) })
2964
2964
  ] }),
2965
2965
  !noCustomerExists && !isInitialLoading && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
2966
2966
  criticalSubscriptions.map((subscription) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
@@ -3102,7 +3102,7 @@ function getStripePromise(publishableKey) {
3102
3102
  }
3103
3103
  _chunk7QVYU63Ejs.__name.call(void 0, getStripePromise, "getStripePromise");
3104
3104
  function StripeProvider({ children }) {
3105
- const publishableKey = _chunkTO6IYGMLjs.getStripePublishableKey.call(void 0, );
3105
+ const publishableKey = _chunk75MLT74Bjs.getStripePublishableKey.call(void 0, );
3106
3106
  const stripePromise = _react.useMemo.call(void 0, () => getStripePromise(publishableKey), [publishableKey]);
3107
3107
  const options = _react.useMemo.call(void 0, () => ({}), []);
3108
3108
  if (!publishableKey) {
@@ -3112,7 +3112,7 @@ function StripeProvider({ children }) {
3112
3112
  }
3113
3113
  _chunk7QVYU63Ejs.__name.call(void 0, StripeProvider, "StripeProvider");
3114
3114
  function isStripeConfigured() {
3115
- return !!_chunkTO6IYGMLjs.getStripePublishableKey.call(void 0, );
3115
+ return !!_chunk75MLT74Bjs.getStripePublishableKey.call(void 0, );
3116
3116
  }
3117
3117
  _chunk7QVYU63Ejs.__name.call(void 0, isStripeConfigured, "isStripeConfigured");
3118
3118
 
@@ -3127,18 +3127,18 @@ _chunk7QVYU63Ejs.__name.call(void 0, isStripeConfigured, "isStripeConfigured");
3127
3127
 
3128
3128
  function PriceArchiver({ price }) {
3129
3129
  const t = _nextintl.useTranslations.call(void 0, );
3130
- const fmt = _chunkSZQNUGDGjs.useBillingFormatOptions.call(void 0, );
3130
+ const fmt = _chunk3VEQ5JZJjs.useBillingFormatOptions.call(void 0, );
3131
3131
  const { archivePrice, restorePrice } = usePriceContext();
3132
3132
  const [open, setOpen] = _react.useState.call(void 0, false);
3133
3133
  const isArchived = !price.active;
3134
3134
  const scope = isArchived ? "restore" : "archive";
3135
3135
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
3136
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.Button, { variant: "outline", size: "sm", onClick: () => setOpen(true), children: [
3136
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.Button, { variant: "outline", size: "sm", onClick: () => setOpen(true), children: [
3137
3137
  isArchived ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.RotateCcwIcon, {}) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.ArchiveIcon, {}),
3138
3138
  t(`billing.admin.prices.${scope}.confirm`)
3139
3139
  ] }),
3140
3140
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3141
- _chunkSZQNUGDGjs.ConfirmDialog,
3141
+ _chunk3VEQ5JZJjs.ConfirmDialog,
3142
3142
  {
3143
3143
  open,
3144
3144
  onOpenChange: setOpen,
@@ -3152,7 +3152,7 @@ function PriceArchiver({ price }) {
3152
3152
  if (isArchived) await restorePrice(price.id);
3153
3153
  else await archivePrice(price.id);
3154
3154
  } catch (error) {
3155
- _chunkSZQNUGDGjs.errorToast.call(void 0, { title: t(`billing.admin.prices.${scope}.title`), error });
3155
+ _chunk3VEQ5JZJjs.errorToast.call(void 0, { title: t(`billing.admin.prices.${scope}.title`), error });
3156
3156
  throw error;
3157
3157
  }
3158
3158
  }
@@ -3184,15 +3184,15 @@ function PriceEditorInternal({
3184
3184
  onDialogOpenChange
3185
3185
  }) {
3186
3186
  const t = _nextintl.useTranslations.call(void 0, );
3187
- const fmt = _chunkSZQNUGDGjs.useBillingFormatOptions.call(void 0, );
3188
- const router = _chunkVVJDWQEIjs.useI18nRouter.call(void 0, );
3187
+ const fmt = _chunk3VEQ5JZJjs.useBillingFormatOptions.call(void 0, );
3188
+ const router = _chunkS5MQDWWCjs.useI18nRouter.call(void 0, );
3189
3189
  const { createPrice, updatePrice, productId: contextProductId } = usePriceContext();
3190
3190
  const [allFeatures, setAllFeatures] = _react.useState.call(void 0, []);
3191
3191
  const isEdit = !!price;
3192
3192
  const targetProductId = _nullishCoalesce(_nullishCoalesce(productId, () => ( _optionalChain([price, 'optionalAccess', _115 => _115.product, 'optionalAccess', _116 => _116.id]))), () => ( contextProductId));
3193
3193
  _react.useEffect.call(void 0, () => {
3194
3194
  const fetchFeatures = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
3195
- setAllFeatures(await _chunkVVJDWQEIjs.FeatureService.findMany({}));
3195
+ setAllFeatures(await _chunkS5MQDWWCjs.FeatureService.findMany({}));
3196
3196
  }, "fetchFeatures");
3197
3197
  void fetchFeatures();
3198
3198
  }, []);
@@ -3305,7 +3305,7 @@ function PriceEditorInternal({
3305
3305
  warnedUnknownFor.current = fingerprint;
3306
3306
  const { unknown } = resolvePlatformFeatures(seed.platformFeatures);
3307
3307
  if (unknown.length > 0)
3308
- _chunkVVJDWQEIjs.showToast.call(void 0, t("billing.admin.prices.import.warnings.unknownFeatures", { features: unknown.join(", ") }));
3308
+ _chunkS5MQDWWCjs.showToast.call(void 0, t("billing.admin.prices.import.warnings.unknownFeatures", { features: unknown.join(", ") }));
3309
3309
  }, [seed, isEdit, allFeatures, resolvePlatformFeatures, t]);
3310
3310
  const watchInterval = form.watch("interval");
3311
3311
  const isRecurring = watchInterval !== "one_time";
@@ -3326,13 +3326,13 @@ function PriceEditorInternal({
3326
3326
  { id: "metered", text: t("billing.admin.prices.usage.metered") }
3327
3327
  ];
3328
3328
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3329
- _chunkSZQNUGDGjs.EditorSheet,
3329
+ _chunk3VEQ5JZJjs.EditorSheet,
3330
3330
  {
3331
3331
  form,
3332
3332
  entityType: t("billing.admin.prices.entity"),
3333
3333
  entityName: price ? priceLabel(price, fmt) : void 0,
3334
3334
  isEdit,
3335
- module: _chunkVVJDWQEIjs.Modules.StripePrice,
3335
+ module: _chunkS5MQDWWCjs.Modules.StripePrice,
3336
3336
  size: "lg",
3337
3337
  propagateChanges,
3338
3338
  onSuccess,
@@ -3381,13 +3381,13 @@ function PriceEditorInternal({
3381
3381
  dialogOpen,
3382
3382
  onDialogOpenChange,
3383
3383
  children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex w-full flex-col gap-y-4", children: [
3384
- isEdit && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.Alert, { children: [
3385
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.AlertTitle, { children: t("billing.admin.prices.immutability.title") }),
3386
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.AlertDescription, { children: t("billing.admin.prices.immutability.description") })
3384
+ isEdit && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.Alert, { children: [
3385
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.AlertTitle, { children: t("billing.admin.prices.immutability.title") }),
3386
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.AlertDescription, { children: t("billing.admin.prices.immutability.description") })
3387
3387
  ] }),
3388
3388
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "grid grid-cols-2 gap-x-4", children: [
3389
3389
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3390
- _chunkSZQNUGDGjs.FormInput,
3390
+ _chunk3VEQ5JZJjs.FormInput,
3391
3391
  {
3392
3392
  form,
3393
3393
  id: "unitAmount",
@@ -3399,7 +3399,7 @@ function PriceEditorInternal({
3399
3399
  }
3400
3400
  ),
3401
3401
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3402
- _chunkSZQNUGDGjs.FormSelect,
3402
+ _chunk3VEQ5JZJjs.FormSelect,
3403
3403
  {
3404
3404
  form,
3405
3405
  id: "currency",
@@ -3410,7 +3410,7 @@ function PriceEditorInternal({
3410
3410
  )
3411
3411
  ] }),
3412
3412
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3413
- _chunkSZQNUGDGjs.FormSelect,
3413
+ _chunk3VEQ5JZJjs.FormSelect,
3414
3414
  {
3415
3415
  form,
3416
3416
  id: "interval",
@@ -3421,7 +3421,7 @@ function PriceEditorInternal({
3421
3421
  ),
3422
3422
  isRecurring && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "grid grid-cols-2 gap-x-4", children: [
3423
3423
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3424
- _chunkSZQNUGDGjs.FormInput,
3424
+ _chunk3VEQ5JZJjs.FormInput,
3425
3425
  {
3426
3426
  form,
3427
3427
  id: "intervalCount",
@@ -3432,7 +3432,7 @@ function PriceEditorInternal({
3432
3432
  }
3433
3433
  ),
3434
3434
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3435
- _chunkSZQNUGDGjs.FormSelect,
3435
+ _chunk3VEQ5JZJjs.FormSelect,
3436
3436
  {
3437
3437
  form,
3438
3438
  id: "usageType",
@@ -3443,7 +3443,7 @@ function PriceEditorInternal({
3443
3443
  )
3444
3444
  ] }),
3445
3445
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3446
- _chunkSZQNUGDGjs.FormInput,
3446
+ _chunk3VEQ5JZJjs.FormInput,
3447
3447
  {
3448
3448
  form,
3449
3449
  id: "nickname",
@@ -3452,7 +3452,7 @@ function PriceEditorInternal({
3452
3452
  }
3453
3453
  ),
3454
3454
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3455
- _chunkSZQNUGDGjs.FormTextarea,
3455
+ _chunk3VEQ5JZJjs.FormTextarea,
3456
3456
  {
3457
3457
  form,
3458
3458
  id: "description",
@@ -3462,7 +3462,7 @@ function PriceEditorInternal({
3462
3462
  }
3463
3463
  ),
3464
3464
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3465
- _chunkSZQNUGDGjs.FormInput,
3465
+ _chunk3VEQ5JZJjs.FormInput,
3466
3466
  {
3467
3467
  form,
3468
3468
  id: "token",
@@ -3472,10 +3472,10 @@ function PriceEditorInternal({
3472
3472
  }
3473
3473
  ),
3474
3474
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex flex-col gap-y-2", children: [
3475
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.FieldLabel, { children: t("billing.admin.prices.fields.features") }),
3475
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.FieldLabel, { children: t("billing.admin.prices.fields.features") }),
3476
3476
  form.watch("features").map((_, index) => /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex gap-2", children: [
3477
3477
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3478
- _chunkSZQNUGDGjs.Input,
3478
+ _chunk3VEQ5JZJjs.Input,
3479
3479
  {
3480
3480
  ...form.register(`features.${index}`),
3481
3481
  placeholder: t("billing.admin.prices.placeholders.feature", { index: index + 1 }),
@@ -3483,7 +3483,7 @@ function PriceEditorInternal({
3483
3483
  }
3484
3484
  ),
3485
3485
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3486
- _chunkSZQNUGDGjs.Button,
3486
+ _chunk3VEQ5JZJjs.Button,
3487
3487
  {
3488
3488
  type: "button",
3489
3489
  variant: "outline",
@@ -3498,7 +3498,7 @@ function PriceEditorInternal({
3498
3498
  )
3499
3499
  ] }, index)),
3500
3500
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
3501
- _chunkSZQNUGDGjs.Button,
3501
+ _chunk3VEQ5JZJjs.Button,
3502
3502
  {
3503
3503
  type: "button",
3504
3504
  variant: "outline",
@@ -3513,12 +3513,12 @@ function PriceEditorInternal({
3513
3513
  )
3514
3514
  ] }),
3515
3515
  isRecurring && allFeatures.length > 0 && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex flex-col gap-y-2", children: [
3516
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.FieldLabel, { children: t("billing.admin.prices.fields.platformFeatures") }),
3516
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.FieldLabel, { children: t("billing.admin.prices.fields.platformFeatures") }),
3517
3517
  /* @__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) => {
3518
3518
  const isChecked = form.watch("featureIds").includes(feature.id);
3519
3519
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center gap-x-2", children: [
3520
3520
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3521
- _chunkSZQNUGDGjs.Checkbox,
3521
+ _chunk3VEQ5JZJjs.Checkbox,
3522
3522
  {
3523
3523
  id: `feature-${feature.id}`,
3524
3524
  checked: isChecked,
@@ -3534,13 +3534,13 @@ function PriceEditorInternal({
3534
3534
  }
3535
3535
  }
3536
3536
  ),
3537
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.FieldLabel, { htmlFor: `feature-${feature.id}`, children: feature.name }),
3537
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.FieldLabel, { htmlFor: `feature-${feature.id}`, children: feature.name }),
3538
3538
  feature.isCore && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-muted-foreground text-xs", children: t("billing.admin.prices.help.core") })
3539
3539
  ] }, feature.id);
3540
3540
  }) })
3541
3541
  ] }),
3542
3542
  isRecurring && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3543
- _chunkSZQNUGDGjs.FormCheckbox,
3543
+ _chunk3VEQ5JZJjs.FormCheckbox,
3544
3544
  {
3545
3545
  form,
3546
3546
  id: "isTrial",
@@ -3583,7 +3583,7 @@ var defaultContextValue = {
3583
3583
  productId: void 0
3584
3584
  };
3585
3585
  function priceLabel(price, fmt = {}) {
3586
- return _nullishCoalesce(price.nickname, () => ( `${_chunkSZQNUGDGjs.formatCurrency.call(void 0, price.unitAmount, price.currency, fmt)} ${_chunkSZQNUGDGjs.formatInterval.call(void 0, price, fmt)}`.trim()));
3586
+ return _nullishCoalesce(price.nickname, () => ( `${_chunk3VEQ5JZJjs.formatCurrency.call(void 0, price.unitAmount, price.currency, fmt)} ${_chunk3VEQ5JZJjs.formatInterval.call(void 0, price, fmt)}`.trim()));
3587
3587
  }
3588
3588
  _chunk7QVYU63Ejs.__name.call(void 0, priceLabel, "priceLabel");
3589
3589
  var PriceProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({
@@ -3593,22 +3593,22 @@ var PriceProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({
3593
3593
  productId: productIdProp
3594
3594
  }) => {
3595
3595
  const t = _nextintl.useTranslations.call(void 0, );
3596
- const fmt = _chunkSZQNUGDGjs.useBillingFormatOptions.call(void 0, );
3597
- const generateUrl = _chunkSZQNUGDGjs.usePageUrlGenerator.call(void 0, );
3598
- const { hasRole } = _chunkSZQNUGDGjs.useCurrentUserContext.call(void 0, );
3596
+ const fmt = _chunk3VEQ5JZJjs.useBillingFormatOptions.call(void 0, );
3597
+ const generateUrl = _chunk3VEQ5JZJjs.usePageUrlGenerator.call(void 0, );
3598
+ const { hasRole } = _chunk3VEQ5JZJjs.useCurrentUserContext.call(void 0, );
3599
3599
  const [price, setPrice] = _react.useState.call(void 0,
3600
- dehydratedPrice ? _chunkVVJDWQEIjs.rehydrate.call(void 0, _chunkVVJDWQEIjs.Modules.StripePrice, dehydratedPrice) : void 0
3600
+ dehydratedPrice ? _chunkS5MQDWWCjs.rehydrate.call(void 0, _chunkS5MQDWWCjs.Modules.StripePrice, dehydratedPrice) : void 0
3601
3601
  );
3602
3602
  const [priceVersion, setPriceVersion] = _react.useState.call(void 0, 0);
3603
3603
  const refreshPrices = _react.useCallback.call(void 0, () => setPriceVersion((value2) => value2 + 1), []);
3604
3604
  const productId = _nullishCoalesce(productIdProp, () => ( _optionalChain([price, 'optionalAccess', _139 => _139.product, 'optionalAccess', _140 => _140.id])));
3605
3605
  const reloadPrice = _react.useCallback.call(void 0, async () => {
3606
3606
  if (!_optionalChain([price, 'optionalAccess', _141 => _141.id])) return;
3607
- setPrice(await _chunkVVJDWQEIjs.StripePriceService.getPrice({ id: price.id }));
3607
+ setPrice(await _chunkS5MQDWWCjs.StripePriceService.getPrice({ id: price.id }));
3608
3608
  }, [_optionalChain([price, 'optionalAccess', _142 => _142.id])]);
3609
3609
  const createPrice = _react.useCallback.call(void 0,
3610
3610
  async (input) => {
3611
- const saved = await _chunkVVJDWQEIjs.StripePriceService.createPrice(input);
3611
+ const saved = await _chunkS5MQDWWCjs.StripePriceService.createPrice(input);
3612
3612
  refreshPrices();
3613
3613
  return saved;
3614
3614
  },
@@ -3616,7 +3616,7 @@ var PriceProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({
3616
3616
  );
3617
3617
  const updatePrice = _react.useCallback.call(void 0,
3618
3618
  async (input) => {
3619
- const saved = await _chunkVVJDWQEIjs.StripePriceService.updatePrice(input);
3619
+ const saved = await _chunkS5MQDWWCjs.StripePriceService.updatePrice(input);
3620
3620
  setPrice(saved);
3621
3621
  refreshPrices();
3622
3622
  return saved;
@@ -3627,7 +3627,7 @@ var PriceProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({
3627
3627
  async (id) => {
3628
3628
  const target = _nullishCoalesce(id, () => ( _optionalChain([price, 'optionalAccess', _143 => _143.id])));
3629
3629
  if (!target) return;
3630
- await _chunkVVJDWQEIjs.StripePriceService.archivePrice({ id: target });
3630
+ await _chunkS5MQDWWCjs.StripePriceService.archivePrice({ id: target });
3631
3631
  await reloadPrice();
3632
3632
  refreshPrices();
3633
3633
  },
@@ -3637,7 +3637,7 @@ var PriceProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({
3637
3637
  async (id) => {
3638
3638
  const target = _nullishCoalesce(id, () => ( _optionalChain([price, 'optionalAccess', _145 => _145.id])));
3639
3639
  if (!target) return;
3640
- await _chunkVVJDWQEIjs.StripePriceService.reactivatePrice({ id: target });
3640
+ await _chunkS5MQDWWCjs.StripePriceService.reactivatePrice({ id: target });
3641
3641
  await reloadPrice();
3642
3642
  refreshPrices();
3643
3643
  },
@@ -3661,12 +3661,12 @@ var PriceProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({
3661
3661
  if (!publishChrome) return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, PriceContext.Provider, { value, children });
3662
3662
  const breadcrumb = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, () => {
3663
3663
  const items = [
3664
- { name: t("billing.admin.products.title"), href: generateUrl({ page: _chunkVVJDWQEIjs.Modules.StripeProduct }) }
3664
+ { name: t("billing.admin.products.title"), href: generateUrl({ page: _chunkS5MQDWWCjs.Modules.StripeProduct }) }
3665
3665
  ];
3666
3666
  if (_optionalChain([price, 'optionalAccess', _147 => _147.product]))
3667
3667
  items.push({
3668
3668
  name: price.product.name,
3669
- href: generateUrl({ page: _chunkVVJDWQEIjs.Modules.StripeProduct, id: price.product.id })
3669
+ href: generateUrl({ page: _chunkS5MQDWWCjs.Modules.StripeProduct, id: price.product.id })
3670
3670
  });
3671
3671
  if (price) items.push({ name: priceLabel(price, fmt) });
3672
3672
  return items;
@@ -3683,7 +3683,7 @@ var PriceProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({
3683
3683
  }
3684
3684
  return response;
3685
3685
  }, "title");
3686
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.SharedProvider, { value: { breadcrumbs: breadcrumb(), title: title() }, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, PriceContext.Provider, { value, children }) });
3686
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.SharedProvider, { value: { breadcrumbs: breadcrumb(), title: title() }, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, PriceContext.Provider, { value, children }) });
3687
3687
  }, "PriceProvider");
3688
3688
  var usePriceContext = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, () => _nullishCoalesce(_react.useContext.call(void 0, PriceContext), () => ( defaultContextValue)), "usePriceContext");
3689
3689
 
@@ -3703,12 +3703,12 @@ function ProductArchiver({ product }) {
3703
3703
  const isArchived = !product.active;
3704
3704
  const scope = isArchived ? "restore" : "archive";
3705
3705
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
3706
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.Button, { variant: "outline", size: "sm", onClick: () => setOpen(true), children: [
3706
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.Button, { variant: "outline", size: "sm", onClick: () => setOpen(true), children: [
3707
3707
  isArchived ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.RotateCcwIcon, {}) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.ArchiveIcon, {}),
3708
3708
  t(`billing.admin.products.${scope}.confirm`)
3709
3709
  ] }),
3710
3710
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3711
- _chunkSZQNUGDGjs.ConfirmDialog,
3711
+ _chunk3VEQ5JZJjs.ConfirmDialog,
3712
3712
  {
3713
3713
  open,
3714
3714
  onOpenChange: setOpen,
@@ -3722,7 +3722,7 @@ function ProductArchiver({ product }) {
3722
3722
  if (isArchived) await restoreProduct(product.id);
3723
3723
  else await archiveProduct(product.id);
3724
3724
  } catch (error) {
3725
- _chunkSZQNUGDGjs.errorToast.call(void 0, { title: t(`billing.admin.products.${scope}.title`), error });
3725
+ _chunk3VEQ5JZJjs.errorToast.call(void 0, { title: t(`billing.admin.products.${scope}.title`), error });
3726
3726
  throw error;
3727
3727
  }
3728
3728
  }
@@ -3751,7 +3751,7 @@ function ProductEditorInternal({
3751
3751
  onDialogOpenChange
3752
3752
  }) {
3753
3753
  const t = _nextintl.useTranslations.call(void 0, );
3754
- const router = _chunkVVJDWQEIjs.useI18nRouter.call(void 0, );
3754
+ const router = _chunkS5MQDWWCjs.useI18nRouter.call(void 0, );
3755
3755
  const { createProduct, updateProduct } = useProductContext();
3756
3756
  const isEdit = !!product;
3757
3757
  const formSchema2 = _react.useMemo.call(void 0,
@@ -3775,13 +3775,13 @@ function ProductEditorInternal({
3775
3775
  defaultValues: getDefaultValues()
3776
3776
  });
3777
3777
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3778
- _chunkSZQNUGDGjs.EditorSheet,
3778
+ _chunk3VEQ5JZJjs.EditorSheet,
3779
3779
  {
3780
3780
  form,
3781
3781
  entityType: t("billing.admin.products.entity"),
3782
3782
  entityName: _optionalChain([product, 'optionalAccess', _151 => _151.name]),
3783
3783
  isEdit,
3784
- module: _chunkVVJDWQEIjs.Modules.StripeProduct,
3784
+ module: _chunkS5MQDWWCjs.Modules.StripeProduct,
3785
3785
  size: "md",
3786
3786
  propagateChanges,
3787
3787
  onSuccess,
@@ -3798,7 +3798,7 @@ function ProductEditorInternal({
3798
3798
  onDialogOpenChange,
3799
3799
  children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex w-full flex-col gap-y-4", children: [
3800
3800
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3801
- _chunkSZQNUGDGjs.FormInput,
3801
+ _chunk3VEQ5JZJjs.FormInput,
3802
3802
  {
3803
3803
  form,
3804
3804
  id: "name",
@@ -3808,7 +3808,7 @@ function ProductEditorInternal({
3808
3808
  }
3809
3809
  ),
3810
3810
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3811
- _chunkSZQNUGDGjs.FormTextarea,
3811
+ _chunk3VEQ5JZJjs.FormTextarea,
3812
3812
  {
3813
3813
  form,
3814
3814
  id: "description",
@@ -3852,20 +3852,20 @@ var defaultContextValue2 = {
3852
3852
  };
3853
3853
  var ProductProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({ children, dehydratedProduct, publishChrome = true }) => {
3854
3854
  const t = _nextintl.useTranslations.call(void 0, );
3855
- const generateUrl = _chunkSZQNUGDGjs.usePageUrlGenerator.call(void 0, );
3856
- const { hasRole } = _chunkSZQNUGDGjs.useCurrentUserContext.call(void 0, );
3855
+ const generateUrl = _chunk3VEQ5JZJjs.usePageUrlGenerator.call(void 0, );
3856
+ const { hasRole } = _chunk3VEQ5JZJjs.useCurrentUserContext.call(void 0, );
3857
3857
  const [product, setProduct] = _react.useState.call(void 0,
3858
- dehydratedProduct ? _chunkVVJDWQEIjs.rehydrate.call(void 0, _chunkVVJDWQEIjs.Modules.StripeProduct, dehydratedProduct) : void 0
3858
+ dehydratedProduct ? _chunkS5MQDWWCjs.rehydrate.call(void 0, _chunkS5MQDWWCjs.Modules.StripeProduct, dehydratedProduct) : void 0
3859
3859
  );
3860
3860
  const [catalogueVersion, setCatalogueVersion] = _react.useState.call(void 0, 0);
3861
3861
  const refreshCatalogue = _react.useCallback.call(void 0, () => setCatalogueVersion((value2) => value2 + 1), []);
3862
3862
  const reloadProduct = _react.useCallback.call(void 0, async () => {
3863
3863
  if (!_optionalChain([product, 'optionalAccess', _152 => _152.id])) return;
3864
- setProduct(await _chunkVVJDWQEIjs.StripeProductService.getProduct({ id: product.id }));
3864
+ setProduct(await _chunkS5MQDWWCjs.StripeProductService.getProduct({ id: product.id }));
3865
3865
  }, [_optionalChain([product, 'optionalAccess', _153 => _153.id])]);
3866
3866
  const createProduct = _react.useCallback.call(void 0,
3867
3867
  async (input) => {
3868
- const saved = await _chunkVVJDWQEIjs.StripeProductService.createProduct(input);
3868
+ const saved = await _chunkS5MQDWWCjs.StripeProductService.createProduct(input);
3869
3869
  refreshCatalogue();
3870
3870
  return saved;
3871
3871
  },
@@ -3873,7 +3873,7 @@ var ProductProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({ ch
3873
3873
  );
3874
3874
  const updateProduct = _react.useCallback.call(void 0,
3875
3875
  async (input) => {
3876
- const saved = await _chunkVVJDWQEIjs.StripeProductService.updateProduct(input);
3876
+ const saved = await _chunkS5MQDWWCjs.StripeProductService.updateProduct(input);
3877
3877
  setProduct(saved);
3878
3878
  refreshCatalogue();
3879
3879
  return saved;
@@ -3884,7 +3884,7 @@ var ProductProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({ ch
3884
3884
  async (id) => {
3885
3885
  const target = _nullishCoalesce(id, () => ( _optionalChain([product, 'optionalAccess', _154 => _154.id])));
3886
3886
  if (!target) return;
3887
- await _chunkVVJDWQEIjs.StripeProductService.archiveProduct({ id: target });
3887
+ await _chunkS5MQDWWCjs.StripeProductService.archiveProduct({ id: target });
3888
3888
  await reloadProduct();
3889
3889
  refreshCatalogue();
3890
3890
  },
@@ -3894,7 +3894,7 @@ var ProductProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({ ch
3894
3894
  async (id) => {
3895
3895
  const target = _nullishCoalesce(id, () => ( _optionalChain([product, 'optionalAccess', _156 => _156.id])));
3896
3896
  if (!target) return;
3897
- await _chunkVVJDWQEIjs.StripeProductService.reactivateProduct({ id: target });
3897
+ await _chunkS5MQDWWCjs.StripeProductService.reactivateProduct({ id: target });
3898
3898
  await reloadProduct();
3899
3899
  refreshCatalogue();
3900
3900
  },
@@ -3929,7 +3929,7 @@ var ProductProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({ ch
3929
3929
  {
3930
3930
  name: t("billing.admin.products.title"),
3931
3931
  // Linked only when it is NOT the current page.
3932
- ...product ? { href: generateUrl({ page: _chunkVVJDWQEIjs.Modules.StripeProduct }) } : {}
3932
+ ...product ? { href: generateUrl({ page: _chunkS5MQDWWCjs.Modules.StripeProduct }) } : {}
3933
3933
  }
3934
3934
  ];
3935
3935
  if (product) items.push({ name: product.name });
@@ -3947,7 +3947,7 @@ var ProductProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({ ch
3947
3947
  }
3948
3948
  return response;
3949
3949
  }, "title");
3950
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.SharedProvider, { value: { breadcrumbs: breadcrumb(), title: title() }, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, ProductContext.Provider, { value, children }) });
3950
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.SharedProvider, { value: { breadcrumbs: breadcrumb(), title: title() }, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, ProductContext.Provider, { value, children }) });
3951
3951
  }, "ProductProvider");
3952
3952
  var useProductContext = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, () => _nullishCoalesce(_react.useContext.call(void 0, ProductContext), () => ( defaultContextValue2)), "useProductContext");
3953
3953
 
@@ -3956,57 +3956,57 @@ var useProductContext = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ()
3956
3956
 
3957
3957
  function PriceDetails() {
3958
3958
  const t = _nextintl.useTranslations.call(void 0, );
3959
- const fmt = _chunkSZQNUGDGjs.useBillingFormatOptions.call(void 0, );
3960
- const generateUrl = _chunkSZQNUGDGjs.usePageUrlGenerator.call(void 0, );
3959
+ const fmt = _chunk3VEQ5JZJjs.useBillingFormatOptions.call(void 0, );
3960
+ const generateUrl = _chunk3VEQ5JZJjs.usePageUrlGenerator.call(void 0, );
3961
3961
  const { price } = usePriceContext();
3962
3962
  if (!price) return null;
3963
3963
  const isRecurring = price.priceType === "recurring";
3964
3964
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex w-full flex-col gap-y-8", children: [
3965
3965
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex w-full flex-col gap-y-4", children: [
3966
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.SectionHeader, { children: t("billing.admin.prices.title") }),
3966
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.SectionHeader, { children: t("billing.admin.prices.title") }),
3967
3967
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "grid grid-cols-1 gap-4 md:grid-cols-2", children: [
3968
3968
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3969
- _chunkSZQNUGDGjs.DetailField,
3969
+ _chunk3VEQ5JZJjs.DetailField,
3970
3970
  {
3971
3971
  label: t("billing.admin.prices.fields.product"),
3972
- value: price.product ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Link, { href: generateUrl({ page: _chunkVVJDWQEIjs.Modules.StripeProduct, id: price.product.id }), children: price.product.name }) : "\u2014"
3972
+ value: price.product ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Link, { href: generateUrl({ page: _chunkS5MQDWWCjs.Modules.StripeProduct, id: price.product.id }), children: price.product.name }) : "\u2014"
3973
3973
  }
3974
3974
  ),
3975
3975
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3976
- _chunkSZQNUGDGjs.DetailField,
3976
+ _chunk3VEQ5JZJjs.DetailField,
3977
3977
  {
3978
3978
  label: t("billing.admin.prices.fields.status"),
3979
3979
  value: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "flex flex-wrap items-center gap-1", children: [
3980
- price.active ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Badge, { variant: "softGreen", children: t("billing.admin.prices.status.active") }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Badge, { variant: "softGray", children: t("billing.admin.prices.status.archived") }),
3981
- price.isTrial && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Badge, { variant: "softBlue", children: t("billing.admin.prices.badge.trial") })
3980
+ price.active ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Badge, { variant: "softGreen", children: t("billing.admin.prices.status.active") }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Badge, { variant: "softGray", children: t("billing.admin.prices.status.archived") }),
3981
+ price.isTrial && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Badge, { variant: "softBlue", children: t("billing.admin.prices.badge.trial") })
3982
3982
  ] })
3983
3983
  }
3984
3984
  ),
3985
3985
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3986
- _chunkSZQNUGDGjs.DetailField,
3986
+ _chunk3VEQ5JZJjs.DetailField,
3987
3987
  {
3988
3988
  label: t("billing.admin.prices.fields.amount"),
3989
- value: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "tabular-nums", children: _chunkSZQNUGDGjs.formatCurrency.call(void 0, price.unitAmount, price.currency, fmt) })
3989
+ value: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "tabular-nums", children: _chunk3VEQ5JZJjs.formatCurrency.call(void 0, price.unitAmount, price.currency, fmt) })
3990
3990
  }
3991
3991
  ),
3992
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.DetailField, { label: t("billing.admin.prices.fields.currency"), value: price.currency.toUpperCase() }),
3992
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.DetailField, { label: t("billing.admin.prices.fields.currency"), value: price.currency.toUpperCase() }),
3993
3993
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3994
- _chunkSZQNUGDGjs.DetailField,
3994
+ _chunk3VEQ5JZJjs.DetailField,
3995
3995
  {
3996
3996
  label: t("billing.admin.prices.fields.type"),
3997
3997
  value: isRecurring ? t("billing.admin.prices.type.recurring") : t("billing.admin.prices.type.oneTime")
3998
3998
  }
3999
3999
  ),
4000
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.DetailField, { label: t("billing.admin.prices.fields.billing"), value: _chunkSZQNUGDGjs.formatInterval.call(void 0, price, fmt) }),
4000
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.DetailField, { label: t("billing.admin.prices.fields.billing"), value: _chunk3VEQ5JZJjs.formatInterval.call(void 0, price, fmt) }),
4001
4001
  isRecurring && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4002
- _chunkSZQNUGDGjs.DetailField,
4002
+ _chunk3VEQ5JZJjs.DetailField,
4003
4003
  {
4004
4004
  label: t("billing.admin.prices.fields.intervalCount"),
4005
4005
  value: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "tabular-nums", children: _nullishCoalesce(_optionalChain([price, 'access', _158 => _158.recurring, 'optionalAccess', _159 => _159.intervalCount]), () => ( 1)) })
4006
4006
  }
4007
4007
  ),
4008
4008
  isRecurring && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4009
- _chunkSZQNUGDGjs.DetailField,
4009
+ _chunk3VEQ5JZJjs.DetailField,
4010
4010
  {
4011
4011
  label: t("billing.admin.prices.fields.usageType"),
4012
4012
  value: _optionalChain([price, 'access', _160 => _160.recurring, 'optionalAccess', _161 => _161.usageType]) === "metered" ? t("billing.admin.prices.usage.metered") : t("billing.admin.prices.usage.licensed")
@@ -4015,24 +4015,24 @@ function PriceDetails() {
4015
4015
  ] })
4016
4016
  ] }),
4017
4017
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex w-full flex-col gap-y-4", children: [
4018
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.SectionHeader, { children: t("billing.admin.prices.fields.platformFeatures") }),
4018
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.SectionHeader, { children: t("billing.admin.prices.fields.platformFeatures") }),
4019
4019
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "grid grid-cols-1 gap-4 md:grid-cols-2", children: [
4020
4020
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4021
- _chunkSZQNUGDGjs.DetailField,
4021
+ _chunk3VEQ5JZJjs.DetailField,
4022
4022
  {
4023
4023
  label: t("billing.admin.prices.fields.token"),
4024
4024
  value: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "tabular-nums", children: _nullishCoalesce(price.token, () => ( "\u2014")) })
4025
4025
  }
4026
4026
  ),
4027
4027
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4028
- _chunkSZQNUGDGjs.DetailField,
4028
+ _chunk3VEQ5JZJjs.DetailField,
4029
4029
  {
4030
4030
  label: t("billing.admin.prices.fields.stripeId"),
4031
4031
  value: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "tabular-nums", children: price.stripePriceId })
4032
4032
  }
4033
4033
  ),
4034
4034
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4035
- _chunkSZQNUGDGjs.DetailField,
4035
+ _chunk3VEQ5JZJjs.DetailField,
4036
4036
  {
4037
4037
  label: t("billing.admin.prices.fields.description"),
4038
4038
  value: _nullishCoalesce(price.description, () => ( "\u2014")),
@@ -4040,7 +4040,7 @@ function PriceDetails() {
4040
4040
  }
4041
4041
  ),
4042
4042
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4043
- _chunkSZQNUGDGjs.DetailField,
4043
+ _chunk3VEQ5JZJjs.DetailField,
4044
4044
  {
4045
4045
  label: t("billing.admin.prices.fields.features"),
4046
4046
  className: "md:col-span-2",
@@ -4048,11 +4048,11 @@ function PriceDetails() {
4048
4048
  }
4049
4049
  ),
4050
4050
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4051
- _chunkSZQNUGDGjs.DetailField,
4051
+ _chunk3VEQ5JZJjs.DetailField,
4052
4052
  {
4053
4053
  label: t("billing.admin.prices.fields.platformFeatures"),
4054
4054
  className: "md:col-span-2",
4055
- 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, _chunkSZQNUGDGjs.Badge, { variant: "softGray", children: feature.name }, feature.id)) }) : "\u2014"
4055
+ 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, _chunk3VEQ5JZJjs.Badge, { variant: "softGray", children: feature.name }, feature.id)) }) : "\u2014"
4056
4056
  }
4057
4057
  )
4058
4058
  ] })
@@ -4066,7 +4066,7 @@ _chunk7QVYU63Ejs.__name.call(void 0, PriceDetails, "PriceDetails");
4066
4066
  function PriceContainer() {
4067
4067
  const { price } = usePriceContext();
4068
4068
  if (!price) return null;
4069
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.RoundPageContainer, { module: _chunkVVJDWQEIjs.Modules.StripePrice, id: price.id, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, PriceDetails, {}) });
4069
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.RoundPageContainer, { module: _chunkS5MQDWWCjs.Modules.StripePrice, id: price.id, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, PriceDetails, {}) });
4070
4070
  }
4071
4071
  _chunk7QVYU63Ejs.__name.call(void 0, PriceContainer, "PriceContainer");
4072
4072
 
@@ -4191,10 +4191,10 @@ function PricesList({ productId, fullWidth }) {
4191
4191
  const importInputRef = _react.useRef.call(void 0, null);
4192
4192
  const [seed, setSeed] = _react.useState.call(void 0, void 0);
4193
4193
  const [seedNonce, setSeedNonce] = _react.useState.call(void 0, 0);
4194
- const data = _chunkSZQNUGDGjs.useDataListRetriever.call(void 0, {
4195
- retriever: /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (params) => _chunkVVJDWQEIjs.StripePriceService.listPrices({ ...params, productId }), "retriever"),
4194
+ const data = _chunk3VEQ5JZJjs.useDataListRetriever.call(void 0, {
4195
+ retriever: /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (params) => _chunkS5MQDWWCjs.StripePriceService.listPrices({ ...params, productId }), "retriever"),
4196
4196
  retrieverParams: {},
4197
- module: _chunkVVJDWQEIjs.Modules.StripePrice
4197
+ module: _chunkS5MQDWWCjs.Modules.StripePrice
4198
4198
  });
4199
4199
  _react.useEffect.call(void 0, () => {
4200
4200
  if (priceVersion > 0) void data.refresh();
@@ -4229,7 +4229,7 @@ function PricesList({ productId, fullWidth }) {
4229
4229
  openSeededEditor(transfer.price);
4230
4230
  } catch (error) {
4231
4231
  console.error("[PricesList] price import failed", error);
4232
- _chunkSZQNUGDGjs.errorToast.call(void 0, {
4232
+ _chunk3VEQ5JZJjs.errorToast.call(void 0, {
4233
4233
  title: t("billing.admin.prices.import.errors.title"),
4234
4234
  error: t("billing.admin.prices.import.errors.invalid")
4235
4235
  });
@@ -4248,7 +4248,7 @@ function PricesList({ productId, fullWidth }) {
4248
4248
  "create-price"
4249
4249
  ),
4250
4250
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _react.Fragment, { children: [
4251
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkSZQNUGDGjs.Button, { variant: "outline", size: "sm", type: "button", onClick: () => _optionalChain([importInputRef, 'access', _176 => _176.current, 'optionalAccess', _177 => _177.click, 'call', _178 => _178()]), children: [
4251
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3VEQ5JZJjs.Button, { variant: "outline", size: "sm", type: "button", onClick: () => _optionalChain([importInputRef, 'access', _176 => _176.current, 'optionalAccess', _177 => _177.click, 'call', _178 => _178()]), children: [
4252
4252
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.UploadIcon, {}),
4253
4253
  t("billing.admin.prices.actions.import")
4254
4254
  ] }),
@@ -4266,7 +4266,7 @@ function PricesList({ productId, fullWidth }) {
4266
4266
  ];
4267
4267
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
4268
4268
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4269
- _chunkSZQNUGDGjs.ContentListTable,
4269
+ _chunk3VEQ5JZJjs.ContentListTable,
4270
4270
  {
4271
4271
  data,
4272
4272
  fields: [
@@ -4277,13 +4277,13 @@ function PricesList({ productId, fullWidth }) {
4277
4277
  "status" /* status */,
4278
4278
  "actions" /* actions */
4279
4279
  ],
4280
- tableGeneratorType: _chunkVVJDWQEIjs.Modules.StripePrice,
4280
+ tableGeneratorType: _chunkS5MQDWWCjs.Modules.StripePrice,
4281
4281
  functions,
4282
4282
  context: tableContext,
4283
4283
  fullWidth,
4284
4284
  title: t("billing.admin.prices.title"),
4285
4285
  emptyState: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4286
- _chunkSZQNUGDGjs.EmptyState,
4286
+ _chunk3VEQ5JZJjs.EmptyState,
4287
4287
  {
4288
4288
  icon: _lucidereact.DollarSignIcon,
4289
4289
  title: t("billing.admin.prices.empty.title"),
@@ -4323,18 +4323,18 @@ function ProductDetails() {
4323
4323
  const { product } = useProductContext();
4324
4324
  if (!product) return null;
4325
4325
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex w-full flex-col gap-y-4", children: [
4326
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.SectionHeader, { children: t("billing.admin.products.tabs.details") }),
4326
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.SectionHeader, { children: t("billing.admin.products.tabs.details") }),
4327
4327
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "grid grid-cols-1 gap-4 md:grid-cols-2", children: [
4328
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.DetailField, { label: t("billing.admin.products.fields.name"), value: product.name }),
4328
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.DetailField, { label: t("billing.admin.products.fields.name"), value: product.name }),
4329
4329
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4330
- _chunkSZQNUGDGjs.DetailField,
4330
+ _chunk3VEQ5JZJjs.DetailField,
4331
4331
  {
4332
4332
  label: t("billing.admin.products.fields.status"),
4333
- value: product.active ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Badge, { variant: "softGreen", children: t("billing.admin.products.status.active") }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.Badge, { variant: "softGray", children: t("billing.admin.products.status.archived") })
4333
+ value: product.active ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Badge, { variant: "softGreen", children: t("billing.admin.products.status.active") }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.Badge, { variant: "softGray", children: t("billing.admin.products.status.archived") })
4334
4334
  }
4335
4335
  ),
4336
4336
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4337
- _chunkSZQNUGDGjs.DetailField,
4337
+ _chunk3VEQ5JZJjs.DetailField,
4338
4338
  {
4339
4339
  label: t("billing.admin.products.fields.description"),
4340
4340
  value: _nullishCoalesce(product.description, () => ( "\u2014")),
@@ -4342,14 +4342,14 @@ function ProductDetails() {
4342
4342
  }
4343
4343
  ),
4344
4344
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4345
- _chunkSZQNUGDGjs.DetailField,
4345
+ _chunk3VEQ5JZJjs.DetailField,
4346
4346
  {
4347
4347
  label: t("billing.admin.products.fields.prices"),
4348
4348
  value: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "tabular-nums", children: product.stripePrices.length })
4349
4349
  }
4350
4350
  ),
4351
4351
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4352
- _chunkSZQNUGDGjs.DetailField,
4352
+ _chunk3VEQ5JZJjs.DetailField,
4353
4353
  {
4354
4354
  label: t("billing.admin.products.fields.stripeId"),
4355
4355
  value: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "tabular-nums", children: product.stripeProductId })
@@ -4367,9 +4367,9 @@ function ProductContainer() {
4367
4367
  const { product } = useProductContext();
4368
4368
  if (!product) return null;
4369
4369
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4370
- _chunkSZQNUGDGjs.RoundPageContainer,
4370
+ _chunk3VEQ5JZJjs.RoundPageContainer,
4371
4371
  {
4372
- module: _chunkVVJDWQEIjs.Modules.StripeProduct,
4372
+ module: _chunkS5MQDWWCjs.Modules.StripeProduct,
4373
4373
  id: product.id,
4374
4374
  tabs: [
4375
4375
  {
@@ -4378,7 +4378,7 @@ function ProductContainer() {
4378
4378
  content: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, ProductDetails, {})
4379
4379
  },
4380
4380
  {
4381
- key: _chunkVVJDWQEIjs.Modules.StripePrice,
4381
+ key: _chunkS5MQDWWCjs.Modules.StripePrice,
4382
4382
  label: t("billing.admin.prices.title"),
4383
4383
  // publishChrome={false}: SharedProvider REPLACES its value for the
4384
4384
  // subtree (SharedContext.tsx:35-37), so a nested provider publishing
@@ -4402,26 +4402,26 @@ _chunk7QVYU63Ejs.__name.call(void 0, ProductContainer, "ProductContainer");
4402
4402
  function ProductsList({ fullWidth } = {}) {
4403
4403
  const t = _nextintl.useTranslations.call(void 0, );
4404
4404
  const { catalogueVersion } = useProductContext();
4405
- const data = _chunkSZQNUGDGjs.useDataListRetriever.call(void 0, {
4406
- retriever: /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (params) => _chunkVVJDWQEIjs.StripeProductService.listProducts(params), "retriever"),
4405
+ const data = _chunk3VEQ5JZJjs.useDataListRetriever.call(void 0, {
4406
+ retriever: /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (params) => _chunkS5MQDWWCjs.StripeProductService.listProducts(params), "retriever"),
4407
4407
  retrieverParams: {},
4408
- module: _chunkVVJDWQEIjs.Modules.StripeProduct
4408
+ module: _chunkS5MQDWWCjs.Modules.StripeProduct
4409
4409
  });
4410
4410
  _react.useEffect.call(void 0, () => {
4411
4411
  if (catalogueVersion > 0) void data.refresh();
4412
4412
  }, [catalogueVersion]);
4413
4413
  const functions = [/* @__PURE__ */ _jsxruntime.jsx.call(void 0, ProductEditor, {}, "create-product")];
4414
4414
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4415
- _chunkSZQNUGDGjs.ContentListTable,
4415
+ _chunk3VEQ5JZJjs.ContentListTable,
4416
4416
  {
4417
4417
  data,
4418
4418
  fields: ["name" /* name */, "status" /* status */, "prices" /* prices */],
4419
- tableGeneratorType: _chunkVVJDWQEIjs.Modules.StripeProduct,
4419
+ tableGeneratorType: _chunkS5MQDWWCjs.Modules.StripeProduct,
4420
4420
  functions,
4421
4421
  fullWidth,
4422
4422
  title: t("billing.admin.products.title"),
4423
4423
  emptyState: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4424
- _chunkSZQNUGDGjs.EmptyState,
4424
+ _chunk3VEQ5JZJjs.EmptyState,
4425
4425
  {
4426
4426
  icon: _lucidereact.PackageIcon,
4427
4427
  title: t("billing.admin.products.empty.title"),
@@ -4436,7 +4436,7 @@ _chunk7QVYU63Ejs.__name.call(void 0, ProductsList, "ProductsList");
4436
4436
  // src/features/billing/stripe-product/components/containers/ProductsListContainer.tsx
4437
4437
 
4438
4438
  function ProductsListContainer() {
4439
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, ProductProvider, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSZQNUGDGjs.RoundPageContainer, { module: _chunkVVJDWQEIjs.Modules.StripeProduct, fullWidth: true, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, ProductsList, { fullWidth: true }) }) });
4439
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, ProductProvider, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3VEQ5JZJjs.RoundPageContainer, { module: _chunkS5MQDWWCjs.Modules.StripeProduct, fullWidth: true, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, ProductsList, { fullWidth: true }) }) });
4440
4440
  }
4441
4441
  _chunk7QVYU63Ejs.__name.call(void 0, ProductsListContainer, "ProductsListContainer");
4442
4442
 
@@ -4501,5 +4501,5 @@ _chunk7QVYU63Ejs.__name.call(void 0, ProductsListContainer, "ProductsListContain
4501
4501
 
4502
4502
 
4503
4503
 
4504
- 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 = _chunkSZQNUGDGjs.formatCurrency; exports.formatDate = _chunkSZQNUGDGjs.formatDate; exports.formatFixed = _chunkSZQNUGDGjs.formatFixed; exports.formatInterval = _chunkSZQNUGDGjs.formatInterval; exports.isStripeConfigured = isStripeConfigured; exports.priceLabel = priceLabel; exports.useBillingFormatOptions = _chunkSZQNUGDGjs.useBillingFormatOptions; exports.usePriceContext = usePriceContext; exports.useProductContext = useProductContext;
4504
+ 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 = _chunk3VEQ5JZJjs.formatCurrency; exports.formatDate = _chunk3VEQ5JZJjs.formatDate; exports.formatFixed = _chunk3VEQ5JZJjs.formatFixed; exports.formatInterval = _chunk3VEQ5JZJjs.formatInterval; exports.isStripeConfigured = isStripeConfigured; exports.priceLabel = priceLabel; exports.useBillingFormatOptions = _chunk3VEQ5JZJjs.useBillingFormatOptions; exports.usePriceContext = usePriceContext; exports.useProductContext = useProductContext;
4505
4505
  //# sourceMappingURL=index.js.map