@carlonicora/nextjs-jsonapi 1.22.0 → 1.24.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 (88) hide show
  1. package/dist/ApiDataInterface-DPP8s46n.d.mts +21 -0
  2. package/dist/ApiDataInterface-DPP8s46n.d.ts +21 -0
  3. package/dist/ApiRequestDataTypeInterface-CUKFDBx2.d.mts +20 -0
  4. package/dist/ApiRequestDataTypeInterface-CUKFDBx2.d.ts +20 -0
  5. package/dist/{ApiResponseInterface-BKyod24U.d.ts → ApiResponseInterface-CAIAeP5d.d.ts} +1 -1
  6. package/dist/{ApiResponseInterface-Dqvu09tz.d.mts → ApiResponseInterface-zeewugD7.d.mts} +1 -1
  7. package/dist/AuthComponent-hxOPs9o8.d.mts +11 -0
  8. package/dist/AuthComponent-hxOPs9o8.d.ts +11 -0
  9. package/dist/{BlockNoteEditor-5AX5ELIN.mjs → BlockNoteEditor-AHWG3PPE.mjs} +5 -5
  10. package/dist/{BlockNoteEditor-HO44QCO5.js → BlockNoteEditor-EZE237PI.js} +15 -15
  11. package/dist/{BlockNoteEditor-HO44QCO5.js.map → BlockNoteEditor-EZE237PI.js.map} +1 -1
  12. package/dist/JsonApiRequest-GR3L56A5.js +24 -0
  13. package/dist/{JsonApiRequest-54ZBO7WQ.js.map → JsonApiRequest-GR3L56A5.js.map} +1 -1
  14. package/dist/{JsonApiRequest-XWQWTFEQ.mjs → JsonApiRequest-K5BRU7RE.mjs} +2 -2
  15. package/dist/billing/index.d.mts +249 -0
  16. package/dist/billing/index.d.ts +249 -0
  17. package/dist/billing/index.js +3479 -0
  18. package/dist/billing/index.js.map +1 -0
  19. package/dist/billing/index.mjs +3479 -0
  20. package/dist/billing/index.mjs.map +1 -0
  21. package/dist/{chunk-KUFWHMMY.mjs → chunk-5U4NJJOF.mjs} +5 -5
  22. package/dist/{chunk-5OENRJNZ.js → chunk-BUULE6HA.js} +704 -4107
  23. package/dist/chunk-BUULE6HA.js.map +1 -0
  24. package/dist/{chunk-LSIUPIYQ.js → chunk-EW6QPMN3.js} +3 -3
  25. package/dist/{chunk-LSIUPIYQ.js.map → chunk-EW6QPMN3.js.map} +1 -1
  26. package/dist/{chunk-LI6CPNJI.js → chunk-FM6WRAN5.js} +1 -1
  27. package/dist/{chunk-LI6CPNJI.js.map → chunk-FM6WRAN5.js.map} +1 -1
  28. package/dist/{chunk-L6XLESU5.mjs → chunk-GR4QPP36.mjs} +2 -2
  29. package/dist/{chunk-UYY34W7R.js → chunk-NQVPCNRS.js} +26 -26
  30. package/dist/{chunk-UYY34W7R.js.map → chunk-NQVPCNRS.js.map} +1 -1
  31. package/dist/{chunk-3VM3WAOV.mjs → chunk-U4MTVHOC.mjs} +1 -1
  32. package/dist/{chunk-QNSYPIJK.mjs → chunk-WRSFYOJI.mjs} +305 -3708
  33. package/dist/chunk-WRSFYOJI.mjs.map +1 -0
  34. package/dist/client/index.d.mts +7 -6
  35. package/dist/client/index.d.ts +7 -6
  36. package/dist/client/index.js +5 -5
  37. package/dist/client/index.mjs +4 -4
  38. package/dist/components/index.d.mts +6 -248
  39. package/dist/components/index.d.ts +6 -248
  40. package/dist/components/index.js +5 -83
  41. package/dist/components/index.js.map +1 -1
  42. package/dist/components/index.mjs +4 -82
  43. package/dist/{config--nwiW74Z.d.ts → config-D_91hrI-.d.ts} +1 -1
  44. package/dist/{config-BKSQmUWU.d.mts → config-h0hNLceh.d.mts} +1 -1
  45. package/dist/{content.interface-4VICFRA0.d.ts → content.interface-CUIEQ0jk.d.ts} +2 -2
  46. package/dist/{content.interface-CFc97-Cj.d.mts → content.interface-QcsFR5Ad.d.mts} +2 -2
  47. package/dist/contexts/index.d.mts +4 -3
  48. package/dist/contexts/index.d.ts +4 -3
  49. package/dist/contexts/index.js +5 -5
  50. package/dist/contexts/index.mjs +4 -4
  51. package/dist/core/index.d.mts +12 -10
  52. package/dist/core/index.d.ts +12 -10
  53. package/dist/core/index.js +3 -3
  54. package/dist/core/index.mjs +2 -2
  55. package/dist/index.d.mts +9 -7
  56. package/dist/index.d.ts +9 -7
  57. package/dist/index.js +4 -4
  58. package/dist/index.mjs +3 -3
  59. package/dist/{notification.interface-CqwaOIgM.d.ts → notification.interface-D7_g5SnS.d.ts} +2 -1
  60. package/dist/{notification.interface-BGaPiCUM.d.mts → notification.interface-blT8r47t.d.mts} +2 -1
  61. package/dist/{s3.service-BYs88XEE.d.ts → s3.service-B83hUhqV.d.ts} +4 -3
  62. package/dist/{s3.service-C0BjOdvn.d.mts → s3.service-DSDfcr0S.d.mts} +4 -3
  63. package/dist/server/index.d.mts +6 -5
  64. package/dist/server/index.d.ts +6 -5
  65. package/dist/server/index.js +15 -15
  66. package/dist/server/index.js.map +1 -1
  67. package/dist/server/index.mjs +5 -5
  68. package/dist/{stripe-subscription.interface-B-TM40Io.d.ts → stripe-subscription.interface-CFtupgYh.d.mts} +2 -12
  69. package/dist/{stripe-subscription.interface-DDxnpj0F.d.mts → stripe-subscription.interface-CNTsrbAx.d.ts} +2 -12
  70. package/dist/testing/index.d.mts +3 -2
  71. package/dist/testing/index.d.ts +3 -2
  72. package/dist/{useSocket-BNj9PrRw.d.mts → useSocket-B5M_a4bD.d.mts} +1 -1
  73. package/dist/{useSocket-Dwt8cz1x.d.ts → useSocket-Dd03muLJ.d.ts} +1 -1
  74. package/package.json +6 -1
  75. package/src/billing/index.ts +8 -0
  76. package/src/components/forms/FormDate.tsx +6 -7
  77. package/src/components/forms/FormDateTime.tsx +7 -7
  78. package/src/components/index.ts +1 -7
  79. package/dist/ApiRequestDataTypeInterface-DIEOFn9s.d.mts +0 -40
  80. package/dist/ApiRequestDataTypeInterface-DIEOFn9s.d.ts +0 -40
  81. package/dist/JsonApiRequest-54ZBO7WQ.js +0 -24
  82. package/dist/chunk-5OENRJNZ.js.map +0 -1
  83. package/dist/chunk-QNSYPIJK.mjs.map +0 -1
  84. /package/dist/{BlockNoteEditor-5AX5ELIN.mjs.map → BlockNoteEditor-AHWG3PPE.mjs.map} +0 -0
  85. /package/dist/{JsonApiRequest-XWQWTFEQ.mjs.map → JsonApiRequest-K5BRU7RE.mjs.map} +0 -0
  86. /package/dist/{chunk-KUFWHMMY.mjs.map → chunk-5U4NJJOF.mjs.map} +0 -0
  87. /package/dist/{chunk-L6XLESU5.mjs.map → chunk-GR4QPP36.mjs.map} +0 -0
  88. /package/dist/{chunk-3VM3WAOV.mjs.map → chunk-U4MTVHOC.mjs.map} +0 -0
@@ -0,0 +1,249 @@
1
+ import * as react_jsx_runtime from 'react/jsx-runtime';
2
+ import { j as StripeSubscriptionInterface, P as PaymentMethodInterface, S as StripeCustomerInterface, a as StripeInvoiceInterface, M as MeterInterface, o as MeterSummaryInterface, d as StripePriceInterface, I as InvoiceStatus, g as StripeProductInterface, b as ProrationPreviewInterface, i as SubscriptionStatus, n as StripeUsageInterface } from '../stripe-subscription.interface-CFtupgYh.mjs';
3
+ import { ReactNode } from 'react';
4
+ import '../ApiDataInterface-DPP8s46n.mjs';
5
+
6
+ type SubscriptionSummaryCardProps = {
7
+ subscriptions: StripeSubscriptionInterface[];
8
+ loading?: boolean;
9
+ error?: string;
10
+ onManageClick: () => void;
11
+ };
12
+ declare function SubscriptionSummaryCard({ subscriptions, loading, error, onManageClick, }: SubscriptionSummaryCardProps): react_jsx_runtime.JSX.Element;
13
+
14
+ type PaymentMethodSummaryCardProps = {
15
+ paymentMethods: PaymentMethodInterface[];
16
+ defaultPaymentMethodId?: string;
17
+ loading?: boolean;
18
+ error?: string;
19
+ onManageClick: () => void;
20
+ };
21
+ declare function PaymentMethodSummaryCard({ paymentMethods, defaultPaymentMethodId, loading, error, onManageClick, }: PaymentMethodSummaryCardProps): react_jsx_runtime.JSX.Element;
22
+
23
+ type CustomerInfoCardProps = {
24
+ customer: StripeCustomerInterface | null;
25
+ loading?: boolean;
26
+ error?: string;
27
+ };
28
+ declare function CustomerInfoCard({ customer, loading, error }: CustomerInfoCardProps): react_jsx_runtime.JSX.Element;
29
+
30
+ type InvoicesSummaryCardProps = {
31
+ invoices: StripeInvoiceInterface[];
32
+ loading?: boolean;
33
+ error?: string;
34
+ onViewAllClick: () => void;
35
+ };
36
+ declare function InvoicesSummaryCard({ invoices, loading, error, onViewAllClick }: InvoicesSummaryCardProps): react_jsx_runtime.JSX.Element;
37
+
38
+ type BillingUsageSummaryCardProps = {
39
+ meters: MeterInterface[];
40
+ summaries: Record<string, MeterSummaryInterface | null>;
41
+ loading?: boolean;
42
+ error?: string;
43
+ onViewDetailsClick: () => void;
44
+ };
45
+ declare function BillingUsageSummaryCard({ meters, summaries, loading, error, onViewDetailsClick, }: BillingUsageSummaryCardProps): react_jsx_runtime.JSX.Element;
46
+
47
+ declare function BillingDashboardContainer(): react_jsx_runtime.JSX.Element;
48
+
49
+ type BillingDetailModalProps = {
50
+ open: boolean;
51
+ onOpenChange: (open: boolean) => void;
52
+ title: string;
53
+ children: ReactNode;
54
+ className?: string;
55
+ };
56
+ declare function BillingDetailModal({ open, onOpenChange, title, children, className, }: BillingDetailModalProps): react_jsx_runtime.JSX.Element;
57
+
58
+ declare function StripeProvider({ children }: {
59
+ children: ReactNode;
60
+ }): react_jsx_runtime.JSX.Element;
61
+ declare function isStripeConfigured(): boolean;
62
+
63
+ /**
64
+ * Format price recurring interval for display
65
+ * @param price - Stripe price object
66
+ * @returns Formatted interval string (e.g., "/month", "/year", "/2 weeks", "one-time")
67
+ */
68
+ declare function formatInterval(price: StripePriceInterface): string;
69
+ /**
70
+ * Format currency amount from cents to localized currency string
71
+ * @param amount - Amount in cents
72
+ * @param currency - Currency code (e.g., "USD", "EUR", "GBP")
73
+ * @returns Formatted currency string (e.g., "$9.99", "€9,99")
74
+ */
75
+ declare function formatCurrency(amount: number | undefined, currency: string): string;
76
+
77
+ /**
78
+ * Format a date to a localized date string
79
+ * @param date - Date object or ISO string
80
+ * @returns Formatted date string (e.g., "Jan 15, 2025")
81
+ */
82
+ declare function formatDate(date: Date | string | undefined): string;
83
+
84
+ type BillingAlertBannerProps = {
85
+ subscription: StripeSubscriptionInterface;
86
+ onUpdatePayment?: () => void;
87
+ onAddPayment?: () => void;
88
+ };
89
+ declare function BillingAlertBanner({ subscription, onUpdatePayment, onAddPayment }: BillingAlertBannerProps): react_jsx_runtime.JSX.Element | null;
90
+
91
+ declare function PaymentMethodsContainer(): react_jsx_runtime.JSX.Element;
92
+
93
+ type PaymentMethodCardProps = {
94
+ paymentMethod: PaymentMethodInterface;
95
+ onUpdate: () => void;
96
+ };
97
+ declare function PaymentMethodCard({ paymentMethod, onUpdate }: PaymentMethodCardProps): react_jsx_runtime.JSX.Element;
98
+
99
+ type PaymentMethodEditorProps = {
100
+ open: boolean;
101
+ onOpenChange: (open: boolean) => void;
102
+ onSuccess: () => void;
103
+ };
104
+ declare function PaymentMethodEditor({ open, onOpenChange, onSuccess }: PaymentMethodEditorProps): react_jsx_runtime.JSX.Element;
105
+
106
+ type PaymentMethodsListProps = {
107
+ paymentMethods: PaymentMethodInterface[];
108
+ onUpdate: () => void;
109
+ };
110
+ declare function PaymentMethodsList({ paymentMethods, onUpdate }: PaymentMethodsListProps): react_jsx_runtime.JSX.Element;
111
+
112
+ declare function InvoicesContainer(): react_jsx_runtime.JSX.Element;
113
+
114
+ type InvoiceDetailsProps = {
115
+ invoice: StripeInvoiceInterface;
116
+ open: boolean;
117
+ onOpenChange: (open: boolean) => void;
118
+ onInvoiceChange: () => void;
119
+ };
120
+ declare function InvoiceDetails({ invoice, open, onOpenChange, onInvoiceChange }: InvoiceDetailsProps): react_jsx_runtime.JSX.Element;
121
+
122
+ type InvoicesListProps = {
123
+ invoices: StripeInvoiceInterface[];
124
+ onInvoicesChange: () => void;
125
+ };
126
+ declare function InvoicesList({ invoices, onInvoicesChange }: InvoicesListProps): react_jsx_runtime.JSX.Element;
127
+
128
+ type InvoiceStatusBadgeProps = {
129
+ status: InvoiceStatus;
130
+ };
131
+ declare function InvoiceStatusBadge({ status }: InvoiceStatusBadgeProps): react_jsx_runtime.JSX.Element;
132
+
133
+ type PriceEditorProps = {
134
+ productId: string;
135
+ price?: StripePriceInterface;
136
+ open: boolean;
137
+ onOpenChange: (open: boolean) => void;
138
+ onSuccess: () => void;
139
+ };
140
+ declare function PriceEditor({ productId, price, open, onOpenChange, onSuccess }: PriceEditorProps): react_jsx_runtime.JSX.Element;
141
+
142
+ type PricesListProps = {
143
+ productId: string;
144
+ onPricesChange: () => void;
145
+ };
146
+ declare function PricesList({ productId, onPricesChange }: PricesListProps): react_jsx_runtime.JSX.Element;
147
+
148
+ declare function ProductsAdminContainer(): react_jsx_runtime.JSX.Element;
149
+
150
+ type ProductEditorProps = {
151
+ product?: StripeProductInterface;
152
+ open: boolean;
153
+ onOpenChange: (open: boolean) => void;
154
+ onSuccess: () => void;
155
+ };
156
+ declare function ProductEditor({ product, open, onOpenChange, onSuccess }: ProductEditorProps): react_jsx_runtime.JSX.Element;
157
+
158
+ type ProductsListProps = {
159
+ products: StripeProductInterface[];
160
+ onProductsChange: () => void;
161
+ };
162
+ declare function ProductsList({ products, onProductsChange }: ProductsListProps): react_jsx_runtime.JSX.Element;
163
+
164
+ declare function SubscriptionsContainer(): react_jsx_runtime.JSX.Element;
165
+
166
+ type SubscriptionDetailsProps = {
167
+ subscription: StripeSubscriptionInterface;
168
+ open: boolean;
169
+ onOpenChange: (open: boolean) => void;
170
+ onSubscriptionChange: () => void;
171
+ };
172
+ declare function SubscriptionDetails({ subscription, open, onOpenChange, onSubscriptionChange, }: SubscriptionDetailsProps): react_jsx_runtime.JSX.Element;
173
+
174
+ type CancelSubscriptionDialogProps = {
175
+ subscription: StripeSubscriptionInterface;
176
+ open: boolean;
177
+ onOpenChange: (open: boolean) => void;
178
+ onSuccess: () => void;
179
+ };
180
+ declare function CancelSubscriptionDialog({ subscription, open, onOpenChange, onSuccess, }: CancelSubscriptionDialogProps): react_jsx_runtime.JSX.Element;
181
+
182
+ type SubscriptionEditorProps = {
183
+ subscription?: StripeSubscriptionInterface;
184
+ open: boolean;
185
+ onOpenChange: (open: boolean) => void;
186
+ onSuccess: () => void;
187
+ onAddPaymentMethod?: () => void;
188
+ };
189
+ declare function SubscriptionEditor({ subscription, open, onOpenChange, onSuccess, onAddPaymentMethod, }: SubscriptionEditorProps): react_jsx_runtime.JSX.Element;
190
+
191
+ type SubscriptionsListProps = {
192
+ subscriptions: StripeSubscriptionInterface[];
193
+ onSubscriptionsChange: () => void;
194
+ };
195
+ declare function SubscriptionsList({ subscriptions, onSubscriptionsChange }: SubscriptionsListProps): react_jsx_runtime.JSX.Element;
196
+
197
+ type PricingCardProps = {
198
+ price: StripePriceInterface;
199
+ isCurrentPlan?: boolean;
200
+ isSelected?: boolean;
201
+ isDisabled?: boolean;
202
+ isLoading?: boolean;
203
+ onSelect: (price: StripePriceInterface) => void;
204
+ };
205
+ declare function PricingCard({ price, isCurrentPlan, isSelected, isDisabled, isLoading, onSelect }: PricingCardProps): react_jsx_runtime.JSX.Element;
206
+
207
+ type PricesByProduct = Map<string, StripePriceInterface[]>;
208
+ type PricingCardsGridProps = {
209
+ products: StripeProductInterface[];
210
+ pricesByProduct: PricesByProduct;
211
+ currentPriceId?: string;
212
+ selectedPriceId?: string;
213
+ loadingPriceId?: string;
214
+ loading?: boolean;
215
+ onSelectPrice: (price: StripePriceInterface) => void;
216
+ };
217
+ declare function PricingCardsGrid({ products, pricesByProduct, currentPriceId, selectedPriceId, loadingPriceId, loading, onSelectPrice, }: PricingCardsGridProps): react_jsx_runtime.JSX.Element;
218
+
219
+ type ProrationPreviewProps = {
220
+ preview: ProrationPreviewInterface;
221
+ };
222
+ declare function ProrationPreview({ preview }: ProrationPreviewProps): react_jsx_runtime.JSX.Element;
223
+
224
+ type SubscriptionStatusBadgeProps = {
225
+ status: SubscriptionStatus;
226
+ cancelAtPeriodEnd?: boolean;
227
+ };
228
+ declare function SubscriptionStatusBadge({ status, cancelAtPeriodEnd }: SubscriptionStatusBadgeProps): react_jsx_runtime.JSX.Element;
229
+
230
+ declare function UsageContainer(): react_jsx_runtime.JSX.Element | null;
231
+
232
+ type UsageSummaryCardProps = {
233
+ meter: MeterInterface;
234
+ summary: MeterSummaryInterface | null;
235
+ };
236
+ declare function UsageSummaryCard({ meter, summary }: UsageSummaryCardProps): react_jsx_runtime.JSX.Element;
237
+
238
+ type UsageHistoryTableProps = {
239
+ usageRecords: StripeUsageInterface[];
240
+ };
241
+ declare function UsageHistoryTable({ usageRecords }: UsageHistoryTableProps): react_jsx_runtime.JSX.Element;
242
+
243
+ type UsageSummaryCardsProps = {
244
+ meters: MeterInterface[];
245
+ summaries: Record<string, MeterSummaryInterface | null>;
246
+ };
247
+ declare function UsageSummaryCards({ meters, summaries }: UsageSummaryCardsProps): react_jsx_runtime.JSX.Element;
248
+
249
+ export { BillingAlertBanner, BillingDashboardContainer, BillingDetailModal, BillingUsageSummaryCard, CancelSubscriptionDialog, CustomerInfoCard, InvoiceDetails, InvoiceStatusBadge, InvoicesContainer, InvoicesList, InvoicesSummaryCard, PaymentMethodCard, PaymentMethodEditor, PaymentMethodSummaryCard, PaymentMethodsContainer, PaymentMethodsList, PriceEditor, type PricesByProduct, PricesList, PricingCard, type PricingCardProps, PricingCardsGrid, type PricingCardsGridProps, ProductEditor, ProductsAdminContainer, ProductsList, ProrationPreview, StripeProvider, SubscriptionDetails, SubscriptionEditor, SubscriptionStatusBadge, SubscriptionSummaryCard, SubscriptionsContainer, SubscriptionsList, UsageContainer, UsageHistoryTable, UsageSummaryCard, UsageSummaryCards, formatCurrency, formatDate, formatInterval, isStripeConfigured };
@@ -0,0 +1,249 @@
1
+ import * as react_jsx_runtime from 'react/jsx-runtime';
2
+ import { j as StripeSubscriptionInterface, P as PaymentMethodInterface, S as StripeCustomerInterface, a as StripeInvoiceInterface, M as MeterInterface, o as MeterSummaryInterface, d as StripePriceInterface, I as InvoiceStatus, g as StripeProductInterface, b as ProrationPreviewInterface, i as SubscriptionStatus, n as StripeUsageInterface } from '../stripe-subscription.interface-CNTsrbAx.js';
3
+ import { ReactNode } from 'react';
4
+ import '../ApiDataInterface-DPP8s46n.js';
5
+
6
+ type SubscriptionSummaryCardProps = {
7
+ subscriptions: StripeSubscriptionInterface[];
8
+ loading?: boolean;
9
+ error?: string;
10
+ onManageClick: () => void;
11
+ };
12
+ declare function SubscriptionSummaryCard({ subscriptions, loading, error, onManageClick, }: SubscriptionSummaryCardProps): react_jsx_runtime.JSX.Element;
13
+
14
+ type PaymentMethodSummaryCardProps = {
15
+ paymentMethods: PaymentMethodInterface[];
16
+ defaultPaymentMethodId?: string;
17
+ loading?: boolean;
18
+ error?: string;
19
+ onManageClick: () => void;
20
+ };
21
+ declare function PaymentMethodSummaryCard({ paymentMethods, defaultPaymentMethodId, loading, error, onManageClick, }: PaymentMethodSummaryCardProps): react_jsx_runtime.JSX.Element;
22
+
23
+ type CustomerInfoCardProps = {
24
+ customer: StripeCustomerInterface | null;
25
+ loading?: boolean;
26
+ error?: string;
27
+ };
28
+ declare function CustomerInfoCard({ customer, loading, error }: CustomerInfoCardProps): react_jsx_runtime.JSX.Element;
29
+
30
+ type InvoicesSummaryCardProps = {
31
+ invoices: StripeInvoiceInterface[];
32
+ loading?: boolean;
33
+ error?: string;
34
+ onViewAllClick: () => void;
35
+ };
36
+ declare function InvoicesSummaryCard({ invoices, loading, error, onViewAllClick }: InvoicesSummaryCardProps): react_jsx_runtime.JSX.Element;
37
+
38
+ type BillingUsageSummaryCardProps = {
39
+ meters: MeterInterface[];
40
+ summaries: Record<string, MeterSummaryInterface | null>;
41
+ loading?: boolean;
42
+ error?: string;
43
+ onViewDetailsClick: () => void;
44
+ };
45
+ declare function BillingUsageSummaryCard({ meters, summaries, loading, error, onViewDetailsClick, }: BillingUsageSummaryCardProps): react_jsx_runtime.JSX.Element;
46
+
47
+ declare function BillingDashboardContainer(): react_jsx_runtime.JSX.Element;
48
+
49
+ type BillingDetailModalProps = {
50
+ open: boolean;
51
+ onOpenChange: (open: boolean) => void;
52
+ title: string;
53
+ children: ReactNode;
54
+ className?: string;
55
+ };
56
+ declare function BillingDetailModal({ open, onOpenChange, title, children, className, }: BillingDetailModalProps): react_jsx_runtime.JSX.Element;
57
+
58
+ declare function StripeProvider({ children }: {
59
+ children: ReactNode;
60
+ }): react_jsx_runtime.JSX.Element;
61
+ declare function isStripeConfigured(): boolean;
62
+
63
+ /**
64
+ * Format price recurring interval for display
65
+ * @param price - Stripe price object
66
+ * @returns Formatted interval string (e.g., "/month", "/year", "/2 weeks", "one-time")
67
+ */
68
+ declare function formatInterval(price: StripePriceInterface): string;
69
+ /**
70
+ * Format currency amount from cents to localized currency string
71
+ * @param amount - Amount in cents
72
+ * @param currency - Currency code (e.g., "USD", "EUR", "GBP")
73
+ * @returns Formatted currency string (e.g., "$9.99", "€9,99")
74
+ */
75
+ declare function formatCurrency(amount: number | undefined, currency: string): string;
76
+
77
+ /**
78
+ * Format a date to a localized date string
79
+ * @param date - Date object or ISO string
80
+ * @returns Formatted date string (e.g., "Jan 15, 2025")
81
+ */
82
+ declare function formatDate(date: Date | string | undefined): string;
83
+
84
+ type BillingAlertBannerProps = {
85
+ subscription: StripeSubscriptionInterface;
86
+ onUpdatePayment?: () => void;
87
+ onAddPayment?: () => void;
88
+ };
89
+ declare function BillingAlertBanner({ subscription, onUpdatePayment, onAddPayment }: BillingAlertBannerProps): react_jsx_runtime.JSX.Element | null;
90
+
91
+ declare function PaymentMethodsContainer(): react_jsx_runtime.JSX.Element;
92
+
93
+ type PaymentMethodCardProps = {
94
+ paymentMethod: PaymentMethodInterface;
95
+ onUpdate: () => void;
96
+ };
97
+ declare function PaymentMethodCard({ paymentMethod, onUpdate }: PaymentMethodCardProps): react_jsx_runtime.JSX.Element;
98
+
99
+ type PaymentMethodEditorProps = {
100
+ open: boolean;
101
+ onOpenChange: (open: boolean) => void;
102
+ onSuccess: () => void;
103
+ };
104
+ declare function PaymentMethodEditor({ open, onOpenChange, onSuccess }: PaymentMethodEditorProps): react_jsx_runtime.JSX.Element;
105
+
106
+ type PaymentMethodsListProps = {
107
+ paymentMethods: PaymentMethodInterface[];
108
+ onUpdate: () => void;
109
+ };
110
+ declare function PaymentMethodsList({ paymentMethods, onUpdate }: PaymentMethodsListProps): react_jsx_runtime.JSX.Element;
111
+
112
+ declare function InvoicesContainer(): react_jsx_runtime.JSX.Element;
113
+
114
+ type InvoiceDetailsProps = {
115
+ invoice: StripeInvoiceInterface;
116
+ open: boolean;
117
+ onOpenChange: (open: boolean) => void;
118
+ onInvoiceChange: () => void;
119
+ };
120
+ declare function InvoiceDetails({ invoice, open, onOpenChange, onInvoiceChange }: InvoiceDetailsProps): react_jsx_runtime.JSX.Element;
121
+
122
+ type InvoicesListProps = {
123
+ invoices: StripeInvoiceInterface[];
124
+ onInvoicesChange: () => void;
125
+ };
126
+ declare function InvoicesList({ invoices, onInvoicesChange }: InvoicesListProps): react_jsx_runtime.JSX.Element;
127
+
128
+ type InvoiceStatusBadgeProps = {
129
+ status: InvoiceStatus;
130
+ };
131
+ declare function InvoiceStatusBadge({ status }: InvoiceStatusBadgeProps): react_jsx_runtime.JSX.Element;
132
+
133
+ type PriceEditorProps = {
134
+ productId: string;
135
+ price?: StripePriceInterface;
136
+ open: boolean;
137
+ onOpenChange: (open: boolean) => void;
138
+ onSuccess: () => void;
139
+ };
140
+ declare function PriceEditor({ productId, price, open, onOpenChange, onSuccess }: PriceEditorProps): react_jsx_runtime.JSX.Element;
141
+
142
+ type PricesListProps = {
143
+ productId: string;
144
+ onPricesChange: () => void;
145
+ };
146
+ declare function PricesList({ productId, onPricesChange }: PricesListProps): react_jsx_runtime.JSX.Element;
147
+
148
+ declare function ProductsAdminContainer(): react_jsx_runtime.JSX.Element;
149
+
150
+ type ProductEditorProps = {
151
+ product?: StripeProductInterface;
152
+ open: boolean;
153
+ onOpenChange: (open: boolean) => void;
154
+ onSuccess: () => void;
155
+ };
156
+ declare function ProductEditor({ product, open, onOpenChange, onSuccess }: ProductEditorProps): react_jsx_runtime.JSX.Element;
157
+
158
+ type ProductsListProps = {
159
+ products: StripeProductInterface[];
160
+ onProductsChange: () => void;
161
+ };
162
+ declare function ProductsList({ products, onProductsChange }: ProductsListProps): react_jsx_runtime.JSX.Element;
163
+
164
+ declare function SubscriptionsContainer(): react_jsx_runtime.JSX.Element;
165
+
166
+ type SubscriptionDetailsProps = {
167
+ subscription: StripeSubscriptionInterface;
168
+ open: boolean;
169
+ onOpenChange: (open: boolean) => void;
170
+ onSubscriptionChange: () => void;
171
+ };
172
+ declare function SubscriptionDetails({ subscription, open, onOpenChange, onSubscriptionChange, }: SubscriptionDetailsProps): react_jsx_runtime.JSX.Element;
173
+
174
+ type CancelSubscriptionDialogProps = {
175
+ subscription: StripeSubscriptionInterface;
176
+ open: boolean;
177
+ onOpenChange: (open: boolean) => void;
178
+ onSuccess: () => void;
179
+ };
180
+ declare function CancelSubscriptionDialog({ subscription, open, onOpenChange, onSuccess, }: CancelSubscriptionDialogProps): react_jsx_runtime.JSX.Element;
181
+
182
+ type SubscriptionEditorProps = {
183
+ subscription?: StripeSubscriptionInterface;
184
+ open: boolean;
185
+ onOpenChange: (open: boolean) => void;
186
+ onSuccess: () => void;
187
+ onAddPaymentMethod?: () => void;
188
+ };
189
+ declare function SubscriptionEditor({ subscription, open, onOpenChange, onSuccess, onAddPaymentMethod, }: SubscriptionEditorProps): react_jsx_runtime.JSX.Element;
190
+
191
+ type SubscriptionsListProps = {
192
+ subscriptions: StripeSubscriptionInterface[];
193
+ onSubscriptionsChange: () => void;
194
+ };
195
+ declare function SubscriptionsList({ subscriptions, onSubscriptionsChange }: SubscriptionsListProps): react_jsx_runtime.JSX.Element;
196
+
197
+ type PricingCardProps = {
198
+ price: StripePriceInterface;
199
+ isCurrentPlan?: boolean;
200
+ isSelected?: boolean;
201
+ isDisabled?: boolean;
202
+ isLoading?: boolean;
203
+ onSelect: (price: StripePriceInterface) => void;
204
+ };
205
+ declare function PricingCard({ price, isCurrentPlan, isSelected, isDisabled, isLoading, onSelect }: PricingCardProps): react_jsx_runtime.JSX.Element;
206
+
207
+ type PricesByProduct = Map<string, StripePriceInterface[]>;
208
+ type PricingCardsGridProps = {
209
+ products: StripeProductInterface[];
210
+ pricesByProduct: PricesByProduct;
211
+ currentPriceId?: string;
212
+ selectedPriceId?: string;
213
+ loadingPriceId?: string;
214
+ loading?: boolean;
215
+ onSelectPrice: (price: StripePriceInterface) => void;
216
+ };
217
+ declare function PricingCardsGrid({ products, pricesByProduct, currentPriceId, selectedPriceId, loadingPriceId, loading, onSelectPrice, }: PricingCardsGridProps): react_jsx_runtime.JSX.Element;
218
+
219
+ type ProrationPreviewProps = {
220
+ preview: ProrationPreviewInterface;
221
+ };
222
+ declare function ProrationPreview({ preview }: ProrationPreviewProps): react_jsx_runtime.JSX.Element;
223
+
224
+ type SubscriptionStatusBadgeProps = {
225
+ status: SubscriptionStatus;
226
+ cancelAtPeriodEnd?: boolean;
227
+ };
228
+ declare function SubscriptionStatusBadge({ status, cancelAtPeriodEnd }: SubscriptionStatusBadgeProps): react_jsx_runtime.JSX.Element;
229
+
230
+ declare function UsageContainer(): react_jsx_runtime.JSX.Element | null;
231
+
232
+ type UsageSummaryCardProps = {
233
+ meter: MeterInterface;
234
+ summary: MeterSummaryInterface | null;
235
+ };
236
+ declare function UsageSummaryCard({ meter, summary }: UsageSummaryCardProps): react_jsx_runtime.JSX.Element;
237
+
238
+ type UsageHistoryTableProps = {
239
+ usageRecords: StripeUsageInterface[];
240
+ };
241
+ declare function UsageHistoryTable({ usageRecords }: UsageHistoryTableProps): react_jsx_runtime.JSX.Element;
242
+
243
+ type UsageSummaryCardsProps = {
244
+ meters: MeterInterface[];
245
+ summaries: Record<string, MeterSummaryInterface | null>;
246
+ };
247
+ declare function UsageSummaryCards({ meters, summaries }: UsageSummaryCardsProps): react_jsx_runtime.JSX.Element;
248
+
249
+ export { BillingAlertBanner, BillingDashboardContainer, BillingDetailModal, BillingUsageSummaryCard, CancelSubscriptionDialog, CustomerInfoCard, InvoiceDetails, InvoiceStatusBadge, InvoicesContainer, InvoicesList, InvoicesSummaryCard, PaymentMethodCard, PaymentMethodEditor, PaymentMethodSummaryCard, PaymentMethodsContainer, PaymentMethodsList, PriceEditor, type PricesByProduct, PricesList, PricingCard, type PricingCardProps, PricingCardsGrid, type PricingCardsGridProps, ProductEditor, ProductsAdminContainer, ProductsList, ProrationPreview, StripeProvider, SubscriptionDetails, SubscriptionEditor, SubscriptionStatusBadge, SubscriptionSummaryCard, SubscriptionsContainer, SubscriptionsList, UsageContainer, UsageHistoryTable, UsageSummaryCard, UsageSummaryCards, formatCurrency, formatDate, formatInterval, isStripeConfigured };