@burdenoff/microfe-billing 2026.510.114
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +12 -0
- package/dist/billing/BillingAdminRoutes.d.ts +6 -0
- package/dist/billing/BillingAdminRoutes.d.ts.map +1 -0
- package/dist/billing/BillingAdminRoutes.js +359 -0
- package/dist/billing/BillingAdminRoutes.js.map +1 -0
- package/dist/billing/BillingRoot.d.ts +37 -0
- package/dist/billing/BillingRoot.d.ts.map +1 -0
- package/dist/billing/BillingRoot.js +190 -0
- package/dist/billing/BillingRoot.js.map +1 -0
- package/dist/billing/BillingUserRoutes.d.ts +7 -0
- package/dist/billing/BillingUserRoutes.d.ts.map +1 -0
- package/dist/billing/BillingUserRoutes.js +479 -0
- package/dist/billing/BillingUserRoutes.js.map +1 -0
- package/dist/billing/constants/permissions.d.ts +18 -0
- package/dist/billing/constants/permissions.d.ts.map +1 -0
- package/dist/billing/hooks/useBillingAccountSelection.d.ts +36 -0
- package/dist/billing/hooks/useBillingAccountSelection.d.ts.map +1 -0
- package/dist/billing/hooks/useBillingAccountSelection.js +81 -0
- package/dist/billing/hooks/useBillingAccountSelection.js.map +1 -0
- package/dist/billing/hooks/useBillingEventEmitter.d.ts +8 -0
- package/dist/billing/hooks/useBillingEventEmitter.d.ts.map +1 -0
- package/dist/billing/hooks/useBillingEventEmitter.js +15 -0
- package/dist/billing/hooks/useBillingEventEmitter.js.map +1 -0
- package/dist/billing/hooks/useBillingNavigate.d.ts +30 -0
- package/dist/billing/hooks/useBillingNavigate.d.ts.map +1 -0
- package/dist/billing/hooks/useBillingNavigate.js +23 -0
- package/dist/billing/hooks/useBillingNavigate.js.map +1 -0
- package/dist/billing/hooks/useBillingPermissions.d.ts +94 -0
- package/dist/billing/hooks/useBillingPermissions.d.ts.map +1 -0
- package/dist/billing/hooks/useBillingPermissions.js +78 -0
- package/dist/billing/hooks/useBillingPermissions.js.map +1 -0
- package/dist/billing/hooks/useDefaultBillingCurrency.d.ts +14 -0
- package/dist/billing/hooks/useDefaultBillingCurrency.d.ts.map +1 -0
- package/dist/billing/hooks/useDefaultBillingCurrency.js +23 -0
- package/dist/billing/hooks/useDefaultBillingCurrency.js.map +1 -0
- package/dist/billing/index.d.ts +31 -0
- package/dist/billing/index.d.ts.map +1 -0
- package/dist/billing/lib/native-purchases.d.ts +51 -0
- package/dist/billing/lib/native-purchases.d.ts.map +1 -0
- package/dist/billing/lib/native-purchases.js +44 -0
- package/dist/billing/lib/native-purchases.js.map +1 -0
- package/dist/billing/modules/addons/components/FloatingCartDrawer.d.ts +4 -0
- package/dist/billing/modules/addons/components/FloatingCartDrawer.d.ts.map +1 -0
- package/dist/billing/modules/addons/components/FloatingCartDrawer.js +179 -0
- package/dist/billing/modules/addons/components/FloatingCartDrawer.js.map +1 -0
- package/dist/billing/modules/addons/components/index.d.ts +5 -0
- package/dist/billing/modules/addons/components/index.d.ts.map +1 -0
- package/dist/billing/modules/addons/hooks/index.d.ts +6 -0
- package/dist/billing/modules/addons/hooks/index.d.ts.map +1 -0
- package/dist/billing/modules/addons/hooks/index.js +1 -0
- package/dist/billing/modules/addons/hooks/useAddons.d.ts +55 -0
- package/dist/billing/modules/addons/hooks/useAddons.d.ts.map +1 -0
- package/dist/billing/modules/addons/hooks/useAddons.js +77 -0
- package/dist/billing/modules/addons/hooks/useAddons.js.map +1 -0
- package/dist/billing/modules/addons/index.d.ts +7 -0
- package/dist/billing/modules/addons/index.d.ts.map +1 -0
- package/dist/billing/modules/addons/index.js +10 -0
- package/dist/billing/modules/addons/pages/AddonBrowseDetailPage.d.ts +4 -0
- package/dist/billing/modules/addons/pages/AddonBrowseDetailPage.d.ts.map +1 -0
- package/dist/billing/modules/addons/pages/AddonBrowseDetailPage.js +266 -0
- package/dist/billing/modules/addons/pages/AddonBrowseDetailPage.js.map +1 -0
- package/dist/billing/modules/addons/pages/AddonCreatePage.d.ts +4 -0
- package/dist/billing/modules/addons/pages/AddonCreatePage.d.ts.map +1 -0
- package/dist/billing/modules/addons/pages/AddonCreatePage.js +369 -0
- package/dist/billing/modules/addons/pages/AddonCreatePage.js.map +1 -0
- package/dist/billing/modules/addons/pages/AddonDetailPage.d.ts +4 -0
- package/dist/billing/modules/addons/pages/AddonDetailPage.d.ts.map +1 -0
- package/dist/billing/modules/addons/pages/AddonDetailPage.js +280 -0
- package/dist/billing/modules/addons/pages/AddonDetailPage.js.map +1 -0
- package/dist/billing/modules/addons/pages/AddonEditPage.d.ts +4 -0
- package/dist/billing/modules/addons/pages/AddonEditPage.d.ts.map +1 -0
- package/dist/billing/modules/addons/pages/AddonEditPage.js +396 -0
- package/dist/billing/modules/addons/pages/AddonEditPage.js.map +1 -0
- package/dist/billing/modules/addons/pages/AddonsBrowsePage.d.ts +4 -0
- package/dist/billing/modules/addons/pages/AddonsBrowsePage.d.ts.map +1 -0
- package/dist/billing/modules/addons/pages/AddonsBrowsePage.js +582 -0
- package/dist/billing/modules/addons/pages/AddonsBrowsePage.js.map +1 -0
- package/dist/billing/modules/addons/pages/AddonsListPage.d.ts +4 -0
- package/dist/billing/modules/addons/pages/AddonsListPage.d.ts.map +1 -0
- package/dist/billing/modules/addons/pages/AddonsListPage.js +744 -0
- package/dist/billing/modules/addons/pages/AddonsListPage.js.map +1 -0
- package/dist/billing/modules/addons/pages/index.d.ts +11 -0
- package/dist/billing/modules/addons/pages/index.d.ts.map +1 -0
- package/dist/billing/modules/addons/pages/index.js +6 -0
- package/dist/billing/modules/addons/store/addonCartStore.d.ts +38 -0
- package/dist/billing/modules/addons/store/addonCartStore.d.ts.map +1 -0
- package/dist/billing/modules/addons/store/addonCartStore.js +74 -0
- package/dist/billing/modules/addons/store/addonCartStore.js.map +1 -0
- package/dist/billing/modules/affiliate/api.d.ts +101 -0
- package/dist/billing/modules/affiliate/api.d.ts.map +1 -0
- package/dist/billing/modules/affiliate/api.js +38 -0
- package/dist/billing/modules/affiliate/api.js.map +1 -0
- package/dist/billing/modules/affiliate/index.d.ts +2 -0
- package/dist/billing/modules/affiliate/index.d.ts.map +1 -0
- package/dist/billing/modules/affiliate/index.js +2 -0
- package/dist/billing/modules/affiliate/pages/AffiliateDashboardPage.d.ts +4 -0
- package/dist/billing/modules/affiliate/pages/AffiliateDashboardPage.d.ts.map +1 -0
- package/dist/billing/modules/affiliate/pages/AffiliateDashboardPage.js +464 -0
- package/dist/billing/modules/affiliate/pages/AffiliateDashboardPage.js.map +1 -0
- package/dist/billing/modules/analytics/index.d.ts +5 -0
- package/dist/billing/modules/analytics/index.d.ts.map +1 -0
- package/dist/billing/modules/analytics/index.js +3 -0
- package/dist/billing/modules/analytics/pages/AnalyticsPage.d.ts +4 -0
- package/dist/billing/modules/analytics/pages/AnalyticsPage.d.ts.map +1 -0
- package/dist/billing/modules/analytics/pages/AnalyticsPage.js +469 -0
- package/dist/billing/modules/analytics/pages/AnalyticsPage.js.map +1 -0
- package/dist/billing/modules/analytics/pages/index.d.ts +5 -0
- package/dist/billing/modules/analytics/pages/index.d.ts.map +1 -0
- package/dist/billing/modules/analytics/pages/index.js +1 -0
- package/dist/billing/modules/billing/hooks/index.d.ts +10 -0
- package/dist/billing/modules/billing/hooks/index.d.ts.map +1 -0
- package/dist/billing/modules/billing/hooks/index.js +4 -0
- package/dist/billing/modules/billing/hooks/useInvoices.d.ts +67 -0
- package/dist/billing/modules/billing/hooks/useInvoices.d.ts.map +1 -0
- package/dist/billing/modules/billing/hooks/useInvoices.js +87 -0
- package/dist/billing/modules/billing/hooks/useInvoices.js.map +1 -0
- package/dist/billing/modules/billing/hooks/usePayments.d.ts +62 -0
- package/dist/billing/modules/billing/hooks/usePayments.d.ts.map +1 -0
- package/dist/billing/modules/billing/hooks/usePayments.js +3 -0
- package/dist/billing/modules/billing/hooks/useRefunds.d.ts +191 -0
- package/dist/billing/modules/billing/hooks/useRefunds.d.ts.map +1 -0
- package/dist/billing/modules/billing/hooks/useRefunds.js +162 -0
- package/dist/billing/modules/billing/hooks/useRefunds.js.map +1 -0
- package/dist/billing/modules/billing/hooks/useTransactions.d.ts +41 -0
- package/dist/billing/modules/billing/hooks/useTransactions.d.ts.map +1 -0
- package/dist/billing/modules/billing/hooks/useTransactions.js +55 -0
- package/dist/billing/modules/billing/hooks/useTransactions.js.map +1 -0
- package/dist/billing/modules/billing/index.d.ts +7 -0
- package/dist/billing/modules/billing/index.d.ts.map +1 -0
- package/dist/billing/modules/billing/index.js +11 -0
- package/dist/billing/modules/billing/pages/InvoiceDetailPage.d.ts +4 -0
- package/dist/billing/modules/billing/pages/InvoiceDetailPage.d.ts.map +1 -0
- package/dist/billing/modules/billing/pages/InvoiceDetailPage.js +631 -0
- package/dist/billing/modules/billing/pages/InvoiceDetailPage.js.map +1 -0
- package/dist/billing/modules/billing/pages/InvoicesListPage.d.ts +4 -0
- package/dist/billing/modules/billing/pages/InvoicesListPage.d.ts.map +1 -0
- package/dist/billing/modules/billing/pages/InvoicesListPage.js +382 -0
- package/dist/billing/modules/billing/pages/InvoicesListPage.js.map +1 -0
- package/dist/billing/modules/billing/pages/PaymentMethodsPage.d.ts +4 -0
- package/dist/billing/modules/billing/pages/PaymentMethodsPage.d.ts.map +1 -0
- package/dist/billing/modules/billing/pages/PaymentMethodsPage.js +147 -0
- package/dist/billing/modules/billing/pages/PaymentMethodsPage.js.map +1 -0
- package/dist/billing/modules/billing/pages/RefundsPage.d.ts +4 -0
- package/dist/billing/modules/billing/pages/RefundsPage.d.ts.map +1 -0
- package/dist/billing/modules/billing/pages/RefundsPage.js +1074 -0
- package/dist/billing/modules/billing/pages/RefundsPage.js.map +1 -0
- package/dist/billing/modules/billing/pages/TransactionsPage.d.ts +4 -0
- package/dist/billing/modules/billing/pages/TransactionsPage.d.ts.map +1 -0
- package/dist/billing/modules/billing/pages/TransactionsPage.js +587 -0
- package/dist/billing/modules/billing/pages/TransactionsPage.js.map +1 -0
- package/dist/billing/modules/billing/pages/index.d.ts +10 -0
- package/dist/billing/modules/billing/pages/index.d.ts.map +1 -0
- package/dist/billing/modules/billing/pages/index.js +5 -0
- package/dist/billing/modules/checkout/components/AutoPayToggle.d.ts +14 -0
- package/dist/billing/modules/checkout/components/AutoPayToggle.d.ts.map +1 -0
- package/dist/billing/modules/checkout/components/AutoPayToggle.js +3 -0
- package/dist/billing/modules/checkout/components/BillingAccountSelector.d.ts +14 -0
- package/dist/billing/modules/checkout/components/BillingAccountSelector.d.ts.map +1 -0
- package/dist/billing/modules/checkout/components/BillingAccountSelector.js +151 -0
- package/dist/billing/modules/checkout/components/BillingAccountSelector.js.map +1 -0
- package/dist/billing/modules/checkout/components/CompactAutoPayToggle.d.ts +14 -0
- package/dist/billing/modules/checkout/components/CompactAutoPayToggle.d.ts.map +1 -0
- package/dist/billing/modules/checkout/components/CompactAutoPayToggle.js +4 -0
- package/dist/billing/modules/checkout/components/CreditsAmountInput.d.ts +14 -0
- package/dist/billing/modules/checkout/components/CreditsAmountInput.d.ts.map +1 -0
- package/dist/billing/modules/checkout/components/CreditsAmountInput.js +130 -0
- package/dist/billing/modules/checkout/components/CreditsAmountInput.js.map +1 -0
- package/dist/billing/modules/checkout/components/CreditsPaymentOption.d.ts +16 -0
- package/dist/billing/modules/checkout/components/CreditsPaymentOption.d.ts.map +1 -0
- package/dist/billing/modules/checkout/components/CreditsPaymentOption.js +5 -0
- package/dist/billing/modules/checkout/components/CurrencySelector.d.ts +19 -0
- package/dist/billing/modules/checkout/components/CurrencySelector.d.ts.map +1 -0
- package/dist/billing/modules/checkout/components/CurrencySelector.js +5 -0
- package/dist/billing/modules/checkout/components/NativeCheckoutView.d.ts +14 -0
- package/dist/billing/modules/checkout/components/NativeCheckoutView.d.ts.map +1 -0
- package/dist/billing/modules/checkout/components/NativeCheckoutView.js +273 -0
- package/dist/billing/modules/checkout/components/NativeCheckoutView.js.map +1 -0
- package/dist/billing/modules/checkout/components/OrderSummary.d.ts +22 -0
- package/dist/billing/modules/checkout/components/OrderSummary.d.ts.map +1 -0
- package/dist/billing/modules/checkout/components/OrderSummary.js +293 -0
- package/dist/billing/modules/checkout/components/OrderSummary.js.map +1 -0
- package/dist/billing/modules/checkout/components/PaymentProviderSelector.d.ts +19 -0
- package/dist/billing/modules/checkout/components/PaymentProviderSelector.d.ts.map +1 -0
- package/dist/billing/modules/checkout/components/PaymentProviderSelector.js +3 -0
- package/dist/billing/modules/checkout/components/PromoCodeInput.d.ts +19 -0
- package/dist/billing/modules/checkout/components/PromoCodeInput.d.ts.map +1 -0
- package/dist/billing/modules/checkout/components/PromoCodeInput.js +102 -0
- package/dist/billing/modules/checkout/components/PromoCodeInput.js.map +1 -0
- package/dist/billing/modules/checkout/components/RazorpayPaymentButton.d.ts +25 -0
- package/dist/billing/modules/checkout/components/RazorpayPaymentButton.d.ts.map +1 -0
- package/dist/billing/modules/checkout/components/RazorpayPaymentButton.js +169 -0
- package/dist/billing/modules/checkout/components/RazorpayPaymentButton.js.map +1 -0
- package/dist/billing/modules/checkout/components/SavedCardSelector.d.ts +13 -0
- package/dist/billing/modules/checkout/components/SavedCardSelector.d.ts.map +1 -0
- package/dist/billing/modules/checkout/components/SavedCardSelector.js +4 -0
- package/dist/billing/modules/checkout/components/SimpleAutoPayToggle.d.ts +13 -0
- package/dist/billing/modules/checkout/components/SimpleAutoPayToggle.d.ts.map +1 -0
- package/dist/billing/modules/checkout/components/SimpleAutoPayToggle.js +78 -0
- package/dist/billing/modules/checkout/components/SimpleAutoPayToggle.js.map +1 -0
- package/dist/billing/modules/checkout/components/StripePaymentForm.d.ts +16 -0
- package/dist/billing/modules/checkout/components/StripePaymentForm.d.ts.map +1 -0
- package/dist/billing/modules/checkout/components/StripePaymentForm.js +253 -0
- package/dist/billing/modules/checkout/components/StripePaymentForm.js.map +1 -0
- package/dist/billing/modules/checkout/components/SubscriptionSelector.d.ts +26 -0
- package/dist/billing/modules/checkout/components/SubscriptionSelector.d.ts.map +1 -0
- package/dist/billing/modules/checkout/components/SubscriptionSelector.js +84 -0
- package/dist/billing/modules/checkout/components/SubscriptionSelector.js.map +1 -0
- package/dist/billing/modules/checkout/components/UnifiedPaymentMethodSelector.d.ts +23 -0
- package/dist/billing/modules/checkout/components/UnifiedPaymentMethodSelector.d.ts.map +1 -0
- package/dist/billing/modules/checkout/components/UnifiedPaymentMethodSelector.js +229 -0
- package/dist/billing/modules/checkout/components/UnifiedPaymentMethodSelector.js.map +1 -0
- package/dist/billing/modules/checkout/components/index.d.ts +20 -0
- package/dist/billing/modules/checkout/components/index.d.ts.map +1 -0
- package/dist/billing/modules/checkout/components/index.js +16 -0
- package/dist/billing/modules/checkout/graphql/index.d.ts +6 -0
- package/dist/billing/modules/checkout/graphql/index.d.ts.map +1 -0
- package/dist/billing/modules/checkout/hooks/index.d.ts +9 -0
- package/dist/billing/modules/checkout/hooks/index.d.ts.map +1 -0
- package/dist/billing/modules/checkout/hooks/index.js +4 -0
- package/dist/billing/modules/checkout/hooks/useCheckout.d.ts +69 -0
- package/dist/billing/modules/checkout/hooks/useCheckout.d.ts.map +1 -0
- package/dist/billing/modules/checkout/hooks/useCheckout.js +377 -0
- package/dist/billing/modules/checkout/hooks/useCheckout.js.map +1 -0
- package/dist/billing/modules/checkout/hooks/useNativeCheckout.d.ts +26 -0
- package/dist/billing/modules/checkout/hooks/useNativeCheckout.d.ts.map +1 -0
- package/dist/billing/modules/checkout/hooks/useNativeCheckout.js +88 -0
- package/dist/billing/modules/checkout/hooks/useNativeCheckout.js.map +1 -0
- package/dist/billing/modules/checkout/hooks/usePaymentProviders.d.ts +19 -0
- package/dist/billing/modules/checkout/hooks/usePaymentProviders.d.ts.map +1 -0
- package/dist/billing/modules/checkout/hooks/usePaymentProviders.js +16 -0
- package/dist/billing/modules/checkout/hooks/usePaymentProviders.js.map +1 -0
- package/dist/billing/modules/checkout/hooks/usePaymentStatusPolling.d.ts +59 -0
- package/dist/billing/modules/checkout/hooks/usePaymentStatusPolling.d.ts.map +1 -0
- package/dist/billing/modules/checkout/hooks/usePaymentStatusPolling.js +107 -0
- package/dist/billing/modules/checkout/hooks/usePaymentStatusPolling.js.map +1 -0
- package/dist/billing/modules/checkout/index.d.ts +24 -0
- package/dist/billing/modules/checkout/index.d.ts.map +1 -0
- package/dist/billing/modules/checkout/index.js +19 -0
- package/dist/billing/modules/checkout/pages/CheckoutPage.d.ts +4 -0
- package/dist/billing/modules/checkout/pages/CheckoutPage.d.ts.map +1 -0
- package/dist/billing/modules/checkout/pages/CheckoutPage.js +1248 -0
- package/dist/billing/modules/checkout/pages/CheckoutPage.js.map +1 -0
- package/dist/billing/modules/checkout/pages/index.d.ts +5 -0
- package/dist/billing/modules/checkout/pages/index.d.ts.map +1 -0
- package/dist/billing/modules/checkout/pages/index.js +1 -0
- package/dist/billing/modules/checkout/types/index.d.ts +270 -0
- package/dist/billing/modules/checkout/types/index.d.ts.map +1 -0
- package/dist/billing/modules/checkout/utils/storeOrder.d.ts +20 -0
- package/dist/billing/modules/checkout/utils/storeOrder.d.ts.map +1 -0
- package/dist/billing/modules/checkout/utils/storeOrder.js +27 -0
- package/dist/billing/modules/checkout/utils/storeOrder.js.map +1 -0
- package/dist/billing/modules/coupons/index.d.ts +5 -0
- package/dist/billing/modules/coupons/index.d.ts.map +1 -0
- package/dist/billing/modules/coupons/index.js +6 -0
- package/dist/billing/modules/coupons/pages/CouponDetailPage.d.ts +4 -0
- package/dist/billing/modules/coupons/pages/CouponDetailPage.d.ts.map +1 -0
- package/dist/billing/modules/coupons/pages/CouponDetailPage.js +489 -0
- package/dist/billing/modules/coupons/pages/CouponDetailPage.js.map +1 -0
- package/dist/billing/modules/coupons/pages/CouponsListPage.d.ts +4 -0
- package/dist/billing/modules/coupons/pages/CouponsListPage.d.ts.map +1 -0
- package/dist/billing/modules/coupons/pages/CouponsListPage.js +544 -0
- package/dist/billing/modules/coupons/pages/CouponsListPage.js.map +1 -0
- package/dist/billing/modules/coupons/pages/CreateCouponPage.d.ts +4 -0
- package/dist/billing/modules/coupons/pages/CreateCouponPage.d.ts.map +1 -0
- package/dist/billing/modules/coupons/pages/CreateCouponPage.js +421 -0
- package/dist/billing/modules/coupons/pages/CreateCouponPage.js.map +1 -0
- package/dist/billing/modules/coupons/pages/EditCouponPage.d.ts +4 -0
- package/dist/billing/modules/coupons/pages/EditCouponPage.d.ts.map +1 -0
- package/dist/billing/modules/coupons/pages/EditCouponPage.js +379 -0
- package/dist/billing/modules/coupons/pages/EditCouponPage.js.map +1 -0
- package/dist/billing/modules/coupons/pages/index.d.ts +8 -0
- package/dist/billing/modules/coupons/pages/index.d.ts.map +1 -0
- package/dist/billing/modules/coupons/pages/index.js +4 -0
- package/dist/billing/modules/credits/hooks/index.d.ts +5 -0
- package/dist/billing/modules/credits/hooks/index.d.ts.map +1 -0
- package/dist/billing/modules/credits/hooks/index.js +1 -0
- package/dist/billing/modules/credits/hooks/useCredits.d.ts +75 -0
- package/dist/billing/modules/credits/hooks/useCredits.d.ts.map +1 -0
- package/dist/billing/modules/credits/hooks/useCredits.js +78 -0
- package/dist/billing/modules/credits/hooks/useCredits.js.map +1 -0
- package/dist/billing/modules/credits/index.d.ts +6 -0
- package/dist/billing/modules/credits/index.d.ts.map +1 -0
- package/dist/billing/modules/credits/index.js +8 -0
- package/dist/billing/modules/credits/pages/AdminCreditsPage.d.ts +4 -0
- package/dist/billing/modules/credits/pages/AdminCreditsPage.d.ts.map +1 -0
- package/dist/billing/modules/credits/pages/AdminCreditsPage.js +140 -0
- package/dist/billing/modules/credits/pages/AdminCreditsPage.js.map +1 -0
- package/dist/billing/modules/credits/pages/CreditTransactionsPage.d.ts +4 -0
- package/dist/billing/modules/credits/pages/CreditTransactionsPage.d.ts.map +1 -0
- package/dist/billing/modules/credits/pages/CreditTransactionsPage.js +331 -0
- package/dist/billing/modules/credits/pages/CreditTransactionsPage.js.map +1 -0
- package/dist/billing/modules/credits/pages/CreditWithdrawalPage.d.ts +4 -0
- package/dist/billing/modules/credits/pages/CreditWithdrawalPage.d.ts.map +1 -0
- package/dist/billing/modules/credits/pages/CreditWithdrawalPage.js +770 -0
- package/dist/billing/modules/credits/pages/CreditWithdrawalPage.js.map +1 -0
- package/dist/billing/modules/credits/pages/CreditsPage.d.ts +4 -0
- package/dist/billing/modules/credits/pages/CreditsPage.d.ts.map +1 -0
- package/dist/billing/modules/credits/pages/CreditsPage.js +324 -0
- package/dist/billing/modules/credits/pages/CreditsPage.js.map +1 -0
- package/dist/billing/modules/credits/pages/index.d.ts +8 -0
- package/dist/billing/modules/credits/pages/index.d.ts.map +1 -0
- package/dist/billing/modules/credits/pages/index.js +4 -0
- package/dist/billing/modules/dashboard/components/ActiveSubscriptionCard.d.ts +14 -0
- package/dist/billing/modules/dashboard/components/ActiveSubscriptionCard.d.ts.map +1 -0
- package/dist/billing/modules/dashboard/components/ActiveSubscriptionCard.js +185 -0
- package/dist/billing/modules/dashboard/components/ActiveSubscriptionCard.js.map +1 -0
- package/dist/billing/modules/dashboard/components/AddPaymentMethodModal.d.ts +111 -0
- package/dist/billing/modules/dashboard/components/AddPaymentMethodModal.d.ts.map +1 -0
- package/dist/billing/modules/dashboard/components/AddPaymentMethodModal.js +388 -0
- package/dist/billing/modules/dashboard/components/AddPaymentMethodModal.js.map +1 -0
- package/dist/billing/modules/dashboard/components/BillingAccountCard.d.ts +16 -0
- package/dist/billing/modules/dashboard/components/BillingAccountCard.d.ts.map +1 -0
- package/dist/billing/modules/dashboard/components/BillingAccountCard.js +146 -0
- package/dist/billing/modules/dashboard/components/BillingAccountCard.js.map +1 -0
- package/dist/billing/modules/dashboard/components/CreateBillingAccountModal.d.ts +13 -0
- package/dist/billing/modules/dashboard/components/CreateBillingAccountModal.d.ts.map +1 -0
- package/dist/billing/modules/dashboard/components/CreateBillingAccountModal.js +1044 -0
- package/dist/billing/modules/dashboard/components/CreateBillingAccountModal.js.map +1 -0
- package/dist/billing/modules/dashboard/components/PaymentMethodsSection.d.ts +15 -0
- package/dist/billing/modules/dashboard/components/PaymentMethodsSection.d.ts.map +1 -0
- package/dist/billing/modules/dashboard/components/PaymentMethodsSection.js +216 -0
- package/dist/billing/modules/dashboard/components/PaymentMethodsSection.js.map +1 -0
- package/dist/billing/modules/dashboard/components/RecommendedAddonsSection.d.ts +27 -0
- package/dist/billing/modules/dashboard/components/RecommendedAddonsSection.d.ts.map +1 -0
- package/dist/billing/modules/dashboard/components/RecommendedAddonsSection.js +193 -0
- package/dist/billing/modules/dashboard/components/RecommendedAddonsSection.js.map +1 -0
- package/dist/billing/modules/dashboard/components/index.d.ts +10 -0
- package/dist/billing/modules/dashboard/components/index.d.ts.map +1 -0
- package/dist/billing/modules/dashboard/components/index.js +6 -0
- package/dist/billing/modules/dashboard/hooks/index.d.ts +6 -0
- package/dist/billing/modules/dashboard/hooks/index.d.ts.map +1 -0
- package/dist/billing/modules/dashboard/hooks/index.js +2 -0
- package/dist/billing/modules/dashboard/hooks/useBillingOverviewData.d.ts +17 -0
- package/dist/billing/modules/dashboard/hooks/useBillingOverviewData.d.ts.map +1 -0
- package/dist/billing/modules/dashboard/hooks/useBillingOverviewData.js +42 -0
- package/dist/billing/modules/dashboard/hooks/useBillingOverviewData.js.map +1 -0
- package/dist/billing/modules/dashboard/hooks/useDashboard.d.ts +145 -0
- package/dist/billing/modules/dashboard/hooks/useDashboard.d.ts.map +1 -0
- package/dist/billing/modules/dashboard/hooks/useDashboard.js +118 -0
- package/dist/billing/modules/dashboard/hooks/useDashboard.js.map +1 -0
- package/dist/billing/modules/dashboard/index.d.ts +8 -0
- package/dist/billing/modules/dashboard/index.d.ts.map +1 -0
- package/dist/billing/modules/dashboard/index.js +12 -0
- package/dist/billing/modules/dashboard/pages/OverviewPage.d.ts +4 -0
- package/dist/billing/modules/dashboard/pages/OverviewPage.d.ts.map +1 -0
- package/dist/billing/modules/dashboard/pages/OverviewPage.js +478 -0
- package/dist/billing/modules/dashboard/pages/OverviewPage.js.map +1 -0
- package/dist/billing/modules/dashboard/pages/index.d.ts +5 -0
- package/dist/billing/modules/dashboard/pages/index.d.ts.map +1 -0
- package/dist/billing/modules/dashboard/pages/index.js +1 -0
- package/dist/billing/modules/discounts/index.d.ts +6 -0
- package/dist/billing/modules/discounts/index.d.ts.map +1 -0
- package/dist/billing/modules/discounts/index.js +3 -0
- package/dist/billing/modules/discounts/pages/DiscountsListPage.d.ts +4 -0
- package/dist/billing/modules/discounts/pages/DiscountsListPage.d.ts.map +1 -0
- package/dist/billing/modules/discounts/pages/DiscountsListPage.js +1009 -0
- package/dist/billing/modules/discounts/pages/DiscountsListPage.js.map +1 -0
- package/dist/billing/modules/discounts/pages/index.d.ts +6 -0
- package/dist/billing/modules/discounts/pages/index.d.ts.map +1 -0
- package/dist/billing/modules/discounts/pages/index.js +1 -0
- package/dist/billing/modules/earnings/api.d.ts +131 -0
- package/dist/billing/modules/earnings/api.d.ts.map +1 -0
- package/dist/billing/modules/earnings/api.js +122 -0
- package/dist/billing/modules/earnings/api.js.map +1 -0
- package/dist/billing/modules/earnings/index.d.ts +4 -0
- package/dist/billing/modules/earnings/index.d.ts.map +1 -0
- package/dist/billing/modules/earnings/index.js +4 -0
- package/dist/billing/modules/earnings/pages/EarningsPage.d.ts +4 -0
- package/dist/billing/modules/earnings/pages/EarningsPage.d.ts.map +1 -0
- package/dist/billing/modules/earnings/pages/EarningsPage.js +435 -0
- package/dist/billing/modules/earnings/pages/EarningsPage.js.map +1 -0
- package/dist/billing/modules/earnings/pages/PayoutAdminPage.d.ts +4 -0
- package/dist/billing/modules/earnings/pages/PayoutAdminPage.d.ts.map +1 -0
- package/dist/billing/modules/earnings/pages/PayoutAdminPage.js +273 -0
- package/dist/billing/modules/earnings/pages/PayoutAdminPage.js.map +1 -0
- package/dist/billing/modules/earnings/pages/PayoutsPage.d.ts +4 -0
- package/dist/billing/modules/earnings/pages/PayoutsPage.d.ts.map +1 -0
- package/dist/billing/modules/earnings/pages/PayoutsPage.js +480 -0
- package/dist/billing/modules/earnings/pages/PayoutsPage.js.map +1 -0
- package/dist/billing/modules/plans/hooks/index.d.ts +7 -0
- package/dist/billing/modules/plans/hooks/index.d.ts.map +1 -0
- package/dist/billing/modules/plans/hooks/index.js +2 -0
- package/dist/billing/modules/plans/hooks/usePlans.d.ts +46 -0
- package/dist/billing/modules/plans/hooks/usePlans.d.ts.map +1 -0
- package/dist/billing/modules/plans/hooks/usePlans.js +77 -0
- package/dist/billing/modules/plans/hooks/usePlans.js.map +1 -0
- package/dist/billing/modules/plans/hooks/useQuotas.d.ts +27 -0
- package/dist/billing/modules/plans/hooks/useQuotas.d.ts.map +1 -0
- package/dist/billing/modules/plans/hooks/useQuotas.js +21 -0
- package/dist/billing/modules/plans/hooks/useQuotas.js.map +1 -0
- package/dist/billing/modules/plans/index.d.ts +7 -0
- package/dist/billing/modules/plans/index.d.ts.map +1 -0
- package/dist/billing/modules/plans/index.js +11 -0
- package/dist/billing/modules/plans/pages/PlanBrowseDetailPage.d.ts +4 -0
- package/dist/billing/modules/plans/pages/PlanBrowseDetailPage.d.ts.map +1 -0
- package/dist/billing/modules/plans/pages/PlanBrowseDetailPage.js +264 -0
- package/dist/billing/modules/plans/pages/PlanBrowseDetailPage.js.map +1 -0
- package/dist/billing/modules/plans/pages/PlanCreatePage.d.ts +4 -0
- package/dist/billing/modules/plans/pages/PlanCreatePage.d.ts.map +1 -0
- package/dist/billing/modules/plans/pages/PlanCreatePage.js +368 -0
- package/dist/billing/modules/plans/pages/PlanCreatePage.js.map +1 -0
- package/dist/billing/modules/plans/pages/PlanDetailPage.d.ts +4 -0
- package/dist/billing/modules/plans/pages/PlanDetailPage.d.ts.map +1 -0
- package/dist/billing/modules/plans/pages/PlanDetailPage.js +356 -0
- package/dist/billing/modules/plans/pages/PlanDetailPage.js.map +1 -0
- package/dist/billing/modules/plans/pages/PlanEditPage.d.ts +4 -0
- package/dist/billing/modules/plans/pages/PlanEditPage.d.ts.map +1 -0
- package/dist/billing/modules/plans/pages/PlanEditPage.js +395 -0
- package/dist/billing/modules/plans/pages/PlanEditPage.js.map +1 -0
- package/dist/billing/modules/plans/pages/PlansBrowsePage.d.ts +4 -0
- package/dist/billing/modules/plans/pages/PlansBrowsePage.d.ts.map +1 -0
- package/dist/billing/modules/plans/pages/PlansBrowsePage.js +314 -0
- package/dist/billing/modules/plans/pages/PlansBrowsePage.js.map +1 -0
- package/dist/billing/modules/plans/pages/PlansListPage.d.ts +4 -0
- package/dist/billing/modules/plans/pages/PlansListPage.d.ts.map +1 -0
- package/dist/billing/modules/plans/pages/PlansListPage.js +438 -0
- package/dist/billing/modules/plans/pages/PlansListPage.js.map +1 -0
- package/dist/billing/modules/plans/pages/index.d.ts +11 -0
- package/dist/billing/modules/plans/pages/index.d.ts.map +1 -0
- package/dist/billing/modules/plans/pages/index.js +6 -0
- package/dist/billing/modules/quota/hooks/index.d.ts +6 -0
- package/dist/billing/modules/quota/hooks/index.d.ts.map +1 -0
- package/dist/billing/modules/quota/hooks/index.js +2 -0
- package/dist/billing/modules/quota/hooks/useQuota.d.ts +102 -0
- package/dist/billing/modules/quota/hooks/useQuota.d.ts.map +1 -0
- package/dist/billing/modules/quota/hooks/useQuota.js +63 -0
- package/dist/billing/modules/quota/hooks/useQuota.js.map +1 -0
- package/dist/billing/modules/quota/hooks/useQuotaTemplates.d.ts +39 -0
- package/dist/billing/modules/quota/hooks/useQuotaTemplates.d.ts.map +1 -0
- package/dist/billing/modules/quota/hooks/useQuotaTemplates.js +67 -0
- package/dist/billing/modules/quota/hooks/useQuotaTemplates.js.map +1 -0
- package/dist/billing/modules/quota/index.d.ts +6 -0
- package/dist/billing/modules/quota/index.d.ts.map +1 -0
- package/dist/billing/modules/quota/index.js +10 -0
- package/dist/billing/modules/quota/pages/QuotaPage.d.ts +4 -0
- package/dist/billing/modules/quota/pages/QuotaPage.d.ts.map +1 -0
- package/dist/billing/modules/quota/pages/QuotaPage.js +337 -0
- package/dist/billing/modules/quota/pages/QuotaPage.js.map +1 -0
- package/dist/billing/modules/quota/pages/QuotaTemplateCreatePage.d.ts +4 -0
- package/dist/billing/modules/quota/pages/QuotaTemplateCreatePage.d.ts.map +1 -0
- package/dist/billing/modules/quota/pages/QuotaTemplateCreatePage.js +273 -0
- package/dist/billing/modules/quota/pages/QuotaTemplateCreatePage.js.map +1 -0
- package/dist/billing/modules/quota/pages/QuotaTemplateDetailPage.d.ts +4 -0
- package/dist/billing/modules/quota/pages/QuotaTemplateDetailPage.d.ts.map +1 -0
- package/dist/billing/modules/quota/pages/QuotaTemplateDetailPage.js +272 -0
- package/dist/billing/modules/quota/pages/QuotaTemplateDetailPage.js.map +1 -0
- package/dist/billing/modules/quota/pages/QuotaTemplateEditPage.d.ts +4 -0
- package/dist/billing/modules/quota/pages/QuotaTemplateEditPage.d.ts.map +1 -0
- package/dist/billing/modules/quota/pages/QuotaTemplateEditPage.js +316 -0
- package/dist/billing/modules/quota/pages/QuotaTemplateEditPage.js.map +1 -0
- package/dist/billing/modules/quota/pages/QuotaTemplatesListPage.d.ts +4 -0
- package/dist/billing/modules/quota/pages/QuotaTemplatesListPage.d.ts.map +1 -0
- package/dist/billing/modules/quota/pages/QuotaTemplatesListPage.js +401 -0
- package/dist/billing/modules/quota/pages/QuotaTemplatesListPage.js.map +1 -0
- package/dist/billing/modules/quota/pages/index.d.ts +9 -0
- package/dist/billing/modules/quota/pages/index.d.ts.map +1 -0
- package/dist/billing/modules/quota/pages/index.js +5 -0
- package/dist/billing/modules/settings/index.d.ts +5 -0
- package/dist/billing/modules/settings/index.d.ts.map +1 -0
- package/dist/billing/modules/settings/index.js +4 -0
- package/dist/billing/modules/settings/pages/SettingsPage.d.ts +4 -0
- package/dist/billing/modules/settings/pages/SettingsPage.d.ts.map +1 -0
- package/dist/billing/modules/settings/pages/SettingsPage.js +632 -0
- package/dist/billing/modules/settings/pages/SettingsPage.js.map +1 -0
- package/dist/billing/modules/settings/pages/TeamPermissionsPage.d.ts +4 -0
- package/dist/billing/modules/settings/pages/TeamPermissionsPage.d.ts.map +1 -0
- package/dist/billing/modules/settings/pages/TeamPermissionsPage.js +270 -0
- package/dist/billing/modules/settings/pages/TeamPermissionsPage.js.map +1 -0
- package/dist/billing/modules/settings/pages/index.d.ts +6 -0
- package/dist/billing/modules/settings/pages/index.d.ts.map +1 -0
- package/dist/billing/modules/settings/pages/index.js +2 -0
- package/dist/billing/modules/store/graphql/index.d.ts +6 -0
- package/dist/billing/modules/store/graphql/index.d.ts.map +1 -0
- package/dist/billing/modules/store/graphql/index.js +1 -0
- package/dist/billing/modules/store/index.d.ts +6 -0
- package/dist/billing/modules/store/index.d.ts.map +1 -0
- package/dist/billing/modules/store/index.js +3 -0
- package/dist/billing/modules/store/pages/StoreCheckoutPage.d.ts +11 -0
- package/dist/billing/modules/store/pages/StoreCheckoutPage.d.ts.map +1 -0
- package/dist/billing/modules/store/pages/StoreCheckoutPage.js +18 -0
- package/dist/billing/modules/store/pages/StoreCheckoutPage.js.map +1 -0
- package/dist/billing/modules/subscriptions/components/ManageSeatsModal.d.ts +12 -0
- package/dist/billing/modules/subscriptions/components/ManageSeatsModal.d.ts.map +1 -0
- package/dist/billing/modules/subscriptions/components/ManageSeatsModal.js +167 -0
- package/dist/billing/modules/subscriptions/components/ManageSeatsModal.js.map +1 -0
- package/dist/billing/modules/subscriptions/hooks/index.d.ts +6 -0
- package/dist/billing/modules/subscriptions/hooks/index.d.ts.map +1 -0
- package/dist/billing/modules/subscriptions/hooks/index.js +1 -0
- package/dist/billing/modules/subscriptions/hooks/useSubscriptions.d.ts +92 -0
- package/dist/billing/modules/subscriptions/hooks/useSubscriptions.d.ts.map +1 -0
- package/dist/billing/modules/subscriptions/hooks/useSubscriptions.js +136 -0
- package/dist/billing/modules/subscriptions/hooks/useSubscriptions.js.map +1 -0
- package/dist/billing/modules/subscriptions/index.d.ts +7 -0
- package/dist/billing/modules/subscriptions/index.d.ts.map +1 -0
- package/dist/billing/modules/subscriptions/index.js +7 -0
- package/dist/billing/modules/subscriptions/pages/SubscriptionDetailPage.d.ts +4 -0
- package/dist/billing/modules/subscriptions/pages/SubscriptionDetailPage.d.ts.map +1 -0
- package/dist/billing/modules/subscriptions/pages/SubscriptionDetailPage.js +551 -0
- package/dist/billing/modules/subscriptions/pages/SubscriptionDetailPage.js.map +1 -0
- package/dist/billing/modules/subscriptions/pages/SubscriptionsListPage.d.ts +4 -0
- package/dist/billing/modules/subscriptions/pages/SubscriptionsListPage.d.ts.map +1 -0
- package/dist/billing/modules/subscriptions/pages/SubscriptionsListPage.js +529 -0
- package/dist/billing/modules/subscriptions/pages/SubscriptionsListPage.js.map +1 -0
- package/dist/billing/modules/subscriptions/pages/UpgradeSubscriptionPage.d.ts +4 -0
- package/dist/billing/modules/subscriptions/pages/UpgradeSubscriptionPage.d.ts.map +1 -0
- package/dist/billing/modules/subscriptions/pages/UpgradeSubscriptionPage.js +430 -0
- package/dist/billing/modules/subscriptions/pages/UpgradeSubscriptionPage.js.map +1 -0
- package/dist/billing/modules/subscriptions/pages/index.d.ts +8 -0
- package/dist/billing/modules/subscriptions/pages/index.d.ts.map +1 -0
- package/dist/billing/modules/subscriptions/pages/index.js +3 -0
- package/dist/billing/modules/usage/hooks/index.d.ts +6 -0
- package/dist/billing/modules/usage/hooks/index.d.ts.map +1 -0
- package/dist/billing/modules/usage/hooks/index.js +1 -0
- package/dist/billing/modules/usage/hooks/useUsage.d.ts +203 -0
- package/dist/billing/modules/usage/hooks/useUsage.d.ts.map +1 -0
- package/dist/billing/modules/usage/hooks/useUsage.js +271 -0
- package/dist/billing/modules/usage/hooks/useUsage.js.map +1 -0
- package/dist/billing/modules/usage/index.d.ts +6 -0
- package/dist/billing/modules/usage/index.d.ts.map +1 -0
- package/dist/billing/modules/usage/index.js +5 -0
- package/dist/billing/modules/usage/pages/UsagePage.d.ts +4 -0
- package/dist/billing/modules/usage/pages/UsagePage.d.ts.map +1 -0
- package/dist/billing/modules/usage/pages/UsagePage.js +817 -0
- package/dist/billing/modules/usage/pages/UsagePage.js.map +1 -0
- package/dist/billing/modules/usage/pages/index.d.ts +5 -0
- package/dist/billing/modules/usage/pages/index.d.ts.map +1 -0
- package/dist/billing/modules/usage/pages/index.js +1 -0
- package/dist/billing/providers/BillingProvider.d.ts +16 -0
- package/dist/billing/providers/BillingProvider.d.ts.map +1 -0
- package/dist/billing/providers/BillingProvider.js +40 -0
- package/dist/billing/providers/BillingProvider.js.map +1 -0
- package/dist/billing/shared/components/AccessDenied.d.ts +8 -0
- package/dist/billing/shared/components/AccessDenied.d.ts.map +1 -0
- package/dist/billing/shared/components/AccessDenied.js +44 -0
- package/dist/billing/shared/components/AccessDenied.js.map +1 -0
- package/dist/billing/shared/components/CurrencyPriceOverridesEditor.d.ts +11 -0
- package/dist/billing/shared/components/CurrencyPriceOverridesEditor.d.ts.map +1 -0
- package/dist/billing/shared/components/CurrencyPriceOverridesEditor.js +230 -0
- package/dist/billing/shared/components/CurrencyPriceOverridesEditor.js.map +1 -0
- package/dist/billing/shared/components/EmptyState.d.ts +11 -0
- package/dist/billing/shared/components/EmptyState.d.ts.map +1 -0
- package/dist/billing/shared/components/EmptyState.js +27 -0
- package/dist/billing/shared/components/EmptyState.js.map +1 -0
- package/dist/billing/shared/components/GeoPricingOverridesEditor.d.ts +11 -0
- package/dist/billing/shared/components/GeoPricingOverridesEditor.d.ts.map +1 -0
- package/dist/billing/shared/components/GeoPricingOverridesEditor.js +1 -0
- package/dist/billing/shared/components/PageHeader.d.ts +11 -0
- package/dist/billing/shared/components/PageHeader.d.ts.map +1 -0
- package/dist/billing/shared/components/PageHeader.js +25 -0
- package/dist/billing/shared/components/PageHeader.js.map +1 -0
- package/dist/billing/shared/components/ServerError.d.ts +11 -0
- package/dist/billing/shared/components/ServerError.d.ts.map +1 -0
- package/dist/billing/shared/components/ServerError.js +75 -0
- package/dist/billing/shared/components/ServerError.js.map +1 -0
- package/dist/billing/shared/components/StatCard.d.ts +15 -0
- package/dist/billing/shared/components/StatCard.d.ts.map +1 -0
- package/dist/billing/shared/components/StatCard.js +37 -0
- package/dist/billing/shared/components/StatCard.js.map +1 -0
- package/dist/billing/shared/components/index.d.ts +11 -0
- package/dist/billing/shared/components/index.d.ts.map +1 -0
- package/dist/billing/shared/components/index.js +7 -0
- package/dist/billing/shared/index.d.ts +8 -0
- package/dist/billing/shared/index.d.ts.map +1 -0
- package/dist/billing/shared/types/graphql.d.ts +926 -0
- package/dist/billing/shared/types/graphql.d.ts.map +1 -0
- package/dist/billing/shared/types/graphql.js +30 -0
- package/dist/billing/shared/types/graphql.js.map +1 -0
- package/dist/billing/shared/types/index.d.ts +96 -0
- package/dist/billing/shared/types/index.d.ts.map +1 -0
- package/dist/billing/shared/utils/directActivityGraphql.d.ts +13 -0
- package/dist/billing/shared/utils/directActivityGraphql.d.ts.map +1 -0
- package/dist/billing/shared/utils/directActivityGraphql.js +2 -0
- package/dist/billing/shared/utils/directBillingGraphql.d.ts +13 -0
- package/dist/billing/shared/utils/directBillingGraphql.d.ts.map +1 -0
- package/dist/billing/shared/utils/directBillingGraphql.js +22 -0
- package/dist/billing/shared/utils/directBillingGraphql.js.map +1 -0
- package/dist/billing/shared/utils/error.d.ts +30 -0
- package/dist/billing/shared/utils/error.d.ts.map +1 -0
- package/dist/billing/shared/utils/error.js +16 -0
- package/dist/billing/shared/utils/error.js.map +1 -0
- package/dist/billing/shared/utils/format.d.ts +28 -0
- package/dist/billing/shared/utils/format.d.ts.map +1 -0
- package/dist/billing/shared/utils/format.js +65 -0
- package/dist/billing/shared/utils/format.js.map +1 -0
- package/dist/billing/shared/utils/gatewayGraphql.d.ts +15 -0
- package/dist/billing/shared/utils/gatewayGraphql.d.ts.map +1 -0
- package/dist/billing/shared/utils/gatewayGraphql.js +27 -0
- package/dist/billing/shared/utils/gatewayGraphql.js.map +1 -0
- package/dist/billing/shared/utils/index.d.ts +13 -0
- package/dist/billing/shared/utils/index.d.ts.map +1 -0
- package/dist/billing/shared/utils/index.js +8 -0
- package/dist/billing/shared/utils/navigation.d.ts +2 -0
- package/dist/billing/shared/utils/navigation.d.ts.map +1 -0
- package/dist/billing/shared/utils/navigation.js +8 -0
- package/dist/billing/shared/utils/navigation.js.map +1 -0
- package/dist/billing/shared/utils/paymentTheme.d.ts +18 -0
- package/dist/billing/shared/utils/paymentTheme.d.ts.map +1 -0
- package/dist/billing/shared/utils/paymentTheme.js +32 -0
- package/dist/billing/shared/utils/paymentTheme.js.map +1 -0
- package/dist/billing/shared/utils/status.d.ts +28 -0
- package/dist/billing/shared/utils/status.d.ts.map +1 -0
- package/dist/billing/shared/utils/status.js +57 -0
- package/dist/billing/shared/utils/status.js.map +1 -0
- package/dist/billing/shared/utils/tokens.d.ts +156 -0
- package/dist/billing/shared/utils/tokens.d.ts.map +1 -0
- package/dist/billing/shared/utils/tokens.js +128 -0
- package/dist/billing/shared/utils/tokens.js.map +1 -0
- package/dist/billing/types/index.d.ts +268 -0
- package/dist/billing/types/index.d.ts.map +1 -0
- package/dist/billing/utils/index.d.ts +128 -0
- package/dist/billing/utils/index.d.ts.map +1 -0
- package/dist/dev/main.d.ts +2 -0
- package/dist/dev/main.d.ts.map +1 -0
- package/dist/generated/global-operations.d.ts +9544 -0
- package/dist/generated/global-operations.d.ts.map +1 -0
- package/dist/generated/global-operations.js +3542 -0
- package/dist/generated/global-operations.js.map +1 -0
- package/dist/generated/global-types.d.ts +22208 -0
- package/dist/generated/global-types.d.ts.map +1 -0
- package/dist/generated/global-types.js +12 -0
- package/dist/generated/global-types.js.map +1 -0
- package/dist/generated/wspace-operations.d.ts +61 -0
- package/dist/generated/wspace-operations.d.ts.map +1 -0
- package/dist/generated/wspace-operations.js +35 -0
- package/dist/generated/wspace-operations.js.map +1 -0
- package/dist/generated/wspace-types.d.ts +48578 -0
- package/dist/generated/wspace-types.d.ts.map +1 -0
- package/dist/index.d.ts +8 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +2 -0
- package/dist/node_modules/@capacitor/core/dist/index.js +270 -0
- package/dist/node_modules/@capacitor/core/dist/index.js.map +1 -0
- package/dist/utils/nativeBridge.d.ts +3 -0
- package/dist/utils/nativeBridge.d.ts.map +1 -0
- package/dist/utils/nativeBridge.js +2 -0
- package/package.json +112 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"UsagePage.js","names":[],"sources":["../../../../../src/billing/modules/usage/pages/UsagePage.tsx"],"sourcesContent":["/**\n * Usage Module - Enhanced Usage Page\n * Displays usage dashboard with billing account selector, aggregated quotas by subscription,\n * pooled quotas, and lazy-loaded past subscriptions\n */\n\nimport { useState, useMemo, useDeferredValue, useCallback, type FC } from 'react';\nimport {\n ChevronDown,\n ChevronRight,\n AlertTriangle,\n CheckCircle,\n XCircle,\n AlertCircle,\n Layers,\n Package,\n Clock,\n RefreshCw,\n Info,\n ChevronLeft,\n X,\n Search,\n} from 'lucide-react';\nimport {\n useEnhancedUsagePage,\n useBillingAccountsForUsage,\n useQuotaUsageDetails,\n type AggregatedQuota,\n type SubscriptionWithAggregatedQuotas,\n} from '../hooks/useUsage';\nimport { useBillingPermissions } from '../../../hooks/useBillingPermissions';\nimport { useBilling } from '../../../providers/BillingProvider';\nimport { formatNumber, formatRelativeTime, formatDateTime } from '../../../shared/utils/format';\nimport { statusTokens } from '../../../shared/utils/tokens';\nimport type { QuotaStatus } from '../../../shared/types';\nimport { useI18n } from '@burdenoff/fe-libs/shared/providers/shell/I18nProvider';\n\n// ============================================================================\n// Types\n// ============================================================================\n\ninterface QuotaDetailModalProps {\n quota: AggregatedQuota;\n onClose: () => void;\n}\n\n// ============================================================================\n// Helper Components\n// ============================================================================\n\nconst StatusIcon: FC<{ status: QuotaStatus; className?: string }> = ({\n status,\n className = 'w-4 h-4',\n}) => {\n switch (status) {\n case 'EXHAUSTED':\n return <XCircle className={`${className} ${statusTokens.error.icon}`} />;\n case 'CRITICAL':\n return <AlertTriangle className={`${className} ${statusTokens.error.icon}`} />;\n case 'WARNING':\n return <AlertCircle className={`${className} ${statusTokens.warning.icon}`} />;\n case 'HEALTHY':\n return <CheckCircle className={`${className} ${statusTokens.success.icon}`} />;\n default:\n return <Info className={`${className} ${statusTokens.neutral.icon}`} />;\n }\n};\n\nconst StatusBadge: FC<{ status: QuotaStatus }> = ({ status }) => {\n const colors: Record<QuotaStatus, string> = {\n EXHAUSTED: `${statusTokens.error.bg} ${statusTokens.error.text}`,\n CRITICAL: `${statusTokens.error.bg} ${statusTokens.error.text}`,\n WARNING: `${statusTokens.warning.bg} ${statusTokens.warning.text}`,\n HEALTHY: `${statusTokens.success.bg} ${statusTokens.success.text}`,\n INACTIVE: `${statusTokens.neutral.bg} ${statusTokens.neutral.text}`,\n };\n\n return (\n <span className={`px-2 py-0.5 text-xs font-medium rounded ${colors[status]}`}>{status}</span>\n );\n};\n\nconst ProgressBar: FC<{ percentage: number; status: QuotaStatus }> = ({ percentage, status }) => {\n const clampedPercentage = Math.min(100, Math.max(0, percentage));\n\n const barColors: Record<QuotaStatus, string> = {\n EXHAUSTED: statusTokens.error.dot,\n CRITICAL: statusTokens.error.dot,\n WARNING: statusTokens.warning.dot,\n HEALTHY: statusTokens.success.dot,\n INACTIVE: statusTokens.neutral.dot,\n };\n\n return (\n <div className=\"w-full bg-muted rounded-full h-2.5 overflow-hidden\">\n <div\n className={`h-full rounded-full transition-all duration-300 ${barColors[status]}`}\n style={{ width: `${clampedPercentage}%` }}\n />\n </div>\n );\n};\n\n// ============================================================================\n// Stat Card Component\n// ============================================================================\n\ntype StatusFilter = 'all' | 'healthy' | 'warning' | 'critical';\n\ninterface StatCardProps {\n label: string;\n value: string | number;\n icon: React.ReactNode;\n color: 'blue' | 'emerald' | 'amber' | 'red' | 'gray';\n isActive?: boolean;\n onClick?: () => void;\n}\n\nconst StatCard: FC<StatCardProps> = ({ label, value, icon, color, isActive, onClick }) => {\n // Map color prop to semantic status tokens\n const colorToStatus = {\n blue: statusTokens.info,\n emerald: statusTokens.success,\n amber: statusTokens.warning,\n red: statusTokens.error,\n gray: statusTokens.neutral,\n };\n\n const tokens = colorToStatus[color];\n\n const colors = {\n blue: `${tokens.bg} ${tokens.border}`,\n emerald: `${tokens.bg} ${tokens.border}`,\n amber: `${tokens.bg} ${tokens.border}`,\n red: `${tokens.bg} ${tokens.border}`,\n gray: `${tokens.bg} ${tokens.border}`,\n };\n\n // Active ring colors - using semantic dot color for consistency\n const activeColors = {\n blue: `ring-2 ring-offset-2 dark:ring-offset-background ${statusTokens.info.border.replace('border-', 'ring-')}`,\n emerald: `ring-2 ring-offset-2 dark:ring-offset-background ${statusTokens.success.border.replace('border-', 'ring-')}`,\n amber: `ring-2 ring-offset-2 dark:ring-offset-background ${statusTokens.warning.border.replace('border-', 'ring-')}`,\n red: `ring-2 ring-offset-2 dark:ring-offset-background ${statusTokens.error.border.replace('border-', 'ring-')}`,\n gray: `ring-2 ring-offset-2 dark:ring-offset-background ${statusTokens.neutral.border.replace('border-', 'ring-')}`,\n };\n\n const iconColors = {\n blue: statusTokens.info.icon,\n emerald: statusTokens.success.icon,\n amber: statusTokens.warning.icon,\n red: statusTokens.error.icon,\n gray: statusTokens.neutral.icon,\n };\n\n return (\n <button\n onClick={onClick}\n className={`border rounded-lg p-4 w-full text-left transition-all ${colors[color]} ${\n onClick ? 'cursor-pointer hover:shadow-md' : ''\n } ${isActive ? activeColors[color] : ''}`}\n >\n <div className=\"flex items-center gap-2 mb-2\">\n <span className={iconColors[color]}>{icon}</span>\n <span className=\"text-sm text-muted-foreground\">{label}</span>\n </div>\n <p className=\"text-2xl font-bold text-foreground\">{value}</p>\n </button>\n );\n};\n\n// ============================================================================\n// Quota Card Component\n// ============================================================================\n\ninterface QuotaCardProps {\n quota: AggregatedQuota;\n onClick: () => void;\n}\n\nconst QuotaCard: FC<QuotaCardProps> = ({ quota, onClick }) => {\n // Check if there's an actual limit (ignore noLimit flag, check actual value)\n const hasLimit = quota.totalLimit != null && quota.totalLimit > 0;\n const displayLimit = hasLimit ? formatNumber(quota.totalLimit) : '∞';\n const displayUsed = formatNumber(quota.totalUsed);\n\n return (\n <button\n onClick={onClick}\n className=\"w-full text-left border border-border rounded-lg p-4 bg-card hover:shadow-md transition-all hover:border-primary/50\"\n >\n <div className=\"flex items-start justify-between gap-4\">\n <div className=\"flex-1 min-w-0\">\n <div className=\"flex items-center gap-2 mb-2\">\n <StatusIcon status={quota.status} />\n <span className=\"font-medium text-foreground capitalize\">\n {quota.name.replace(/_/g, ' ')}\n </span>\n <StatusBadge status={quota.status} />\n </div>\n\n <div className=\"mb-2\">\n <ProgressBar percentage={quota.usagePercentage} status={quota.status} />\n </div>\n\n <div className=\"flex items-center justify-between text-sm\">\n <span className=\"text-muted-foreground\">\n {displayUsed} / {displayLimit}\n {quota.unit && ` ${quota.unit}`}\n </span>\n <span className=\"font-medium text-foreground\">\n {hasLimit ? `${Math.round(quota.usagePercentage)}%` : '-'}\n </span>\n </div>\n\n {quota.quotaCount > 1 && (\n <p className=\"text-xs text-muted-foreground mt-2\">\n Across {quota.quotaCount} quota assignments\n </p>\n )}\n </div>\n\n <ChevronRight className=\"w-5 h-5 text-muted-foreground flex-shrink-0\" />\n </div>\n </button>\n );\n};\n\n// ============================================================================\n// Subscription Section Component\n// ============================================================================\n\ninterface SubscriptionSectionProps {\n subscription: SubscriptionWithAggregatedQuotas;\n onQuotaClick: (quota: AggregatedQuota) => void;\n defaultExpanded?: boolean;\n}\n\nconst SubscriptionSection: FC<SubscriptionSectionProps> = ({\n subscription,\n onQuotaClick,\n defaultExpanded = true,\n}) => {\n const [isExpanded, setIsExpanded] = useState(defaultExpanded);\n\n const statusColors: Record<string, string> = {\n active: `${statusTokens.success.bg} ${statusTokens.success.text}`,\n trialing: `${statusTokens.info.bg} ${statusTokens.info.text}`,\n past_due: `${statusTokens.warning.bg} ${statusTokens.warning.text}`,\n canceled: `${statusTokens.neutral.bg} ${statusTokens.neutral.text}`,\n expired: `${statusTokens.neutral.bg} ${statusTokens.neutral.text}`,\n upgraded: `${statusTokens.primary.bg} ${statusTokens.primary.text}`,\n };\n\n return (\n <div className=\"border border-border rounded-lg bg-card overflow-hidden\">\n <button\n onClick={() => setIsExpanded(!isExpanded)}\n className=\"w-full flex items-center justify-between p-4 hover:bg-muted/50 transition-colors\"\n >\n <div className=\"flex items-center gap-3\">\n <Package className=\"w-5 h-5 text-primary\" />\n <div className=\"text-left\">\n <div className=\"flex items-center gap-2\">\n <span className=\"font-medium text-foreground\">Subscription</span>\n <span\n className={`px-2 py-0.5 text-xs font-medium rounded capitalize ${statusColors[subscription.status.toLowerCase()] || statusColors.active}`}\n >\n {subscription.status}\n </span>\n </div>\n <p className=\"text-xs text-muted-foreground\">\n {subscription.aggregatedQuotas.length} quota type\n {subscription.aggregatedQuotas.length !== 1 ? 's' : ''}\n </p>\n </div>\n </div>\n {isExpanded ? (\n <ChevronDown className=\"w-5 h-5 text-muted-foreground\" />\n ) : (\n <ChevronRight className=\"w-5 h-5 text-muted-foreground\" />\n )}\n </button>\n\n {isExpanded && subscription.aggregatedQuotas.length > 0 && (\n <div className=\"border-t border-border p-4 space-y-3\">\n {subscription.aggregatedQuotas.map((quota) => (\n <QuotaCard key={quota.name} quota={quota} onClick={() => onQuotaClick(quota)} />\n ))}\n </div>\n )}\n\n {isExpanded && subscription.aggregatedQuotas.length === 0 && (\n <div className=\"border-t border-border p-6 text-center\">\n <p className=\"text-sm text-muted-foreground\">No quotas assigned to this subscription</p>\n </div>\n )}\n </div>\n );\n};\n\n// ============================================================================\n// Quota Detail Modal Component\n// ============================================================================\n\nconst QuotaDetailModal: FC<QuotaDetailModalProps> = ({ quota, onClose }) => {\n // Cursor stack: [null] = page 1, [null, c1] = page 2, etc.\n const [cursorStack, setCursorStack] = useState<Array<string | null>>([null]);\n const currentCursor = cursorStack[cursorStack.length - 1] ?? null;\n const currentPage = cursorStack.length;\n const { workspaceId } = useBilling();\n\n // Get usage details for the first quota assignment directly from activity-svc\n const firstAssignmentId = quota.quotaAssignments[0]?.id;\n const { usages, hasNextPage, nextCursor, isLoading } = useQuotaUsageDetails(\n firstAssignmentId,\n 10,\n currentCursor,\n workspaceId\n );\n\n const handleNext = () => {\n if (nextCursor) setCursorStack((prev) => [...prev, nextCursor]);\n };\n\n const handlePrev = () => {\n if (cursorStack.length > 1) setCursorStack((prev) => prev.slice(0, -1));\n };\n\n return (\n <div className=\"fixed inset-0 z-50 flex items-center justify-center\">\n <div className=\"absolute inset-0 bg-overlay-scrim\" onClick={onClose} />\n <div\n className=\"relative bg-background border border-border rounded-lg shadow-xl max-w-2xl w-full mx-4 max-h-[90vh] overflow-auto\"\n role=\"dialog\"\n aria-modal=\"true\"\n aria-labelledby=\"quota-detail-title\"\n >\n {/* Header */}\n <div className=\"sticky top-0 bg-background border-b border-border p-4 flex items-center justify-between\">\n <div className=\"flex items-center gap-3\">\n <StatusIcon status={quota.status} className=\"w-5 h-5\" />\n <div>\n <h2 id=\"quota-detail-title\" className=\"text-lg font-semibold capitalize\">\n {quota.name.replace(/_/g, ' ')}\n </h2>\n <p className=\"text-sm text-muted-foreground\">\n {quota.quotaCount} quota assignment{quota.quotaCount !== 1 ? 's' : ''}\n </p>\n </div>\n </div>\n <button\n onClick={onClose}\n className=\"p-1 rounded-md hover:bg-muted/50 transition-colors\"\n aria-label=\"Close quota details\"\n >\n <X className=\"w-5 h-5\" />\n </button>\n </div>\n\n {/* Summary */}\n <div className=\"p-4 border-b border-border\">\n <div className=\"mb-4\">\n <div className=\"flex items-center justify-between mb-2\">\n <span className=\"text-sm text-muted-foreground\">Usage</span>\n <StatusBadge status={quota.status} />\n </div>\n <ProgressBar percentage={quota.usagePercentage} status={quota.status} />\n <div className=\"flex items-center justify-between mt-2 text-sm\">\n <span className=\"font-medium\">\n {formatNumber(quota.totalUsed)} /{' '}\n {quota.totalLimit != null && quota.totalLimit > 0\n ? formatNumber(quota.totalLimit)\n : '∞'}\n {quota.unit && ` ${quota.unit}`}\n </span>\n <span className=\"text-muted-foreground\">\n {quota.totalLimit != null && quota.totalLimit > 0\n ? `${Math.round(quota.usagePercentage)}% used`\n : 'Unlimited'}\n </span>\n </div>\n </div>\n\n {/* Quota Assignments Breakdown - sorted by expiry date (earliest first) */}\n {quota.quotaCount > 1 && (\n <div className=\"mt-4\">\n <h3 className=\"text-sm font-medium text-foreground mb-3\">Quota Breakdown</h3>\n <div className=\"border border-border rounded-lg overflow-hidden divide-y divide-border\">\n {[...quota.quotaAssignments]\n .sort((a, b) => {\n // Sort by endtime ascending (earliest expiry first)\n const dateA = a.endtime ? new Date(a.endtime).getTime() : Infinity;\n const dateB = b.endtime ? new Date(b.endtime).getTime() : Infinity;\n return dateA - dateB;\n })\n .map((assignment) => {\n const expiryDate = assignment.endtime ? new Date(assignment.endtime) : null;\n const now = new Date();\n const isExpired = expiryDate && expiryDate < now;\n const daysUntilExpiry = expiryDate\n ? Math.ceil((expiryDate.getTime() - now.getTime()) / (24 * 60 * 60 * 1000))\n : null;\n const isExpiringSoon =\n daysUntilExpiry !== null && daysUntilExpiry > 0 && daysUntilExpiry <= 7;\n\n return (\n <div\n key={assignment.id}\n className={`flex items-center justify-between px-3 py-2.5 ${\n isExpired\n ? 'bg-muted/30'\n : isExpiringSoon\n ? statusTokens.warning.bg\n : 'bg-background'\n }`}\n >\n <div className=\"flex items-center gap-2\">\n {isExpiringSoon && !isExpired && (\n <span\n className={`w-2 h-2 rounded-full ${statusTokens.warning.dot} animate-pulse`}\n />\n )}\n <div className=\"flex flex-col\">\n <span\n className={`text-sm ${isExpired ? 'text-muted-foreground' : 'text-foreground'}`}\n >\n {expiryDate\n ? expiryDate.toLocaleDateString('en-US', {\n month: 'short',\n day: 'numeric',\n year: 'numeric',\n })\n : 'No expiry'}\n </span>\n <span\n className={`text-xs ${\n isExpired\n ? 'text-destructive'\n : isExpiringSoon\n ? statusTokens.warning.text\n : 'text-muted-foreground'\n }`}\n >\n {isExpired\n ? 'Expired'\n : daysUntilExpiry !== null\n ? daysUntilExpiry === 0\n ? 'Expires today'\n : daysUntilExpiry === 1\n ? 'Expires tomorrow'\n : `${daysUntilExpiry} days left`\n : 'Never expires'}\n </span>\n </div>\n </div>\n <div className=\"text-right\">\n <span\n className={`text-sm font-semibold ${isExpired ? 'text-muted-foreground' : 'text-foreground'}`}\n >\n {formatNumber(assignment.used)}\n <span className=\"text-muted-foreground font-normal\">\n {' / '}\n {assignment.limit != null && assignment.limit > 0\n ? formatNumber(assignment.limit)\n : '∞'}\n {assignment.unit && ` ${assignment.unit}`}\n </span>\n </span>\n </div>\n </div>\n );\n })}\n </div>\n </div>\n )}\n </div>\n\n {/* Usage History */}\n <div className=\"p-4\">\n <h3 className=\"text-sm font-medium text-foreground mb-3\">Recent Usage</h3>\n\n {isLoading ? (\n <div className=\"space-y-2\">\n {[1, 2, 3].map((i) => (\n <div key={i} className=\"h-12 bg-muted animate-pulse rounded\" />\n ))}\n </div>\n ) : usages.length === 0 ? (\n <p className=\"text-sm text-muted-foreground text-center py-6\">No usage records found</p>\n ) : (\n <div className=\"space-y-2\">\n {usages.map((usage) => (\n <div\n key={usage.id}\n className=\"flex items-center justify-between p-3 border border-border rounded-lg\"\n >\n <div className=\"flex-1 min-w-0\">\n <p className=\"text-sm font-medium text-foreground\">\n {usage.description || 'Usage recorded'}\n </p>\n <p className=\"text-xs text-muted-foreground\">\n {formatRelativeTime(usage.timestamp)} • {formatDateTime(usage.timestamp)}\n </p>\n </div>\n <span className=\"text-sm font-medium text-foreground ml-4\">\n {formatNumber(usage.amount)}\n </span>\n </div>\n ))}\n </div>\n )}\n\n {/* Pagination */}\n {(cursorStack.length > 1 || hasNextPage) && (\n <div className=\"flex items-center justify-center gap-2 mt-4\">\n <button\n onClick={handlePrev}\n disabled={cursorStack.length === 1}\n className=\"px-3 py-1.5 text-sm border border-border rounded-md disabled:opacity-50\"\n aria-label=\"Previous usage page\"\n >\n <ChevronLeft className=\"w-4 h-4\" />\n </button>\n <span className=\"text-sm text-muted-foreground\">Page {currentPage}</span>\n <button\n onClick={handleNext}\n disabled={!hasNextPage}\n className=\"px-3 py-1.5 text-sm border border-border rounded-md disabled:opacity-50\"\n aria-label=\"Next usage page\"\n >\n <ChevronRight className=\"w-4 h-4\" />\n </button>\n </div>\n )}\n </div>\n\n {/* Footer */}\n <div className=\"sticky bottom-0 bg-background border-t border-border p-4\">\n <button\n onClick={onClose}\n className=\"w-full py-2 px-4 bg-primary text-primary-foreground rounded-md hover:bg-primary/90 transition-colors\"\n >\n Close\n </button>\n </div>\n </div>\n </div>\n );\n};\n\n// ============================================================================\n// Main Usage Page Component\n// ============================================================================\n\nexport const UsagePage: FC = () => {\n const { t } = useI18n();\n const tr = (key: string, fallback: string): string => {\n const translated = t(key);\n return translated === key ? fallback : translated;\n };\n const permissions = useBillingPermissions();\n\n // Helper to get billing account ID from URL (for navigation from Overview page)\n const getInitialBillingAccountId = (): string | undefined => {\n if (typeof window === 'undefined') return undefined;\n const urlParams = new URLSearchParams(window.location.search);\n return urlParams.get('billingAccountId') || undefined;\n };\n\n // State - initialize with URL param if present\n const [selectedBillingAccountId, setSelectedBillingAccountId] = useState<string | undefined>(\n getInitialBillingAccountId\n );\n const [selectedQuota, setSelectedQuota] = useState<AggregatedQuota | null>(null);\n\n // Search and filter state\n const [searchQuery, setSearchQuery] = useState('');\n const [statusFilter, setStatusFilter] = useState<StatusFilter>('all');\n\n // View mode: 'active' | 'past' | 'all'\n type ViewMode = 'active' | 'past' | 'all';\n const [viewMode, setViewMode] = useState<ViewMode>('active');\n\n // Debounce search query to avoid too many API calls\n const deferredSearchQuery = useDeferredValue(searchQuery);\n\n // Fetch billing accounts\n const { billingAccounts, isLoading: isLoadingAccounts } = useBillingAccountsForUsage();\n\n // Prefer the default account, fall back to first\n const defaultBillingAccountId = (billingAccounts.find((a) => a.isDefault) ?? billingAccounts[0])\n ?.id;\n // ?? so that an explicit empty string (cleared URL param) still falls back to default\n const effectiveBillingAccountId = selectedBillingAccountId ?? defaultBillingAccountId;\n\n // Fetch usage data - passes searchQuery and viewMode to backend for server-side filtering\n const {\n dashboard,\n pooledQuotas,\n activeSubscriptions,\n pastSubscriptions,\n isLoading,\n isPastSubscriptionsLoading,\n error,\n refetch,\n // Pagination for past subscriptions\n loadMorePastSubscriptions,\n hasMorePastSubscriptions,\n isLoadingMorePast,\n pastSubscriptionsCount,\n } = useEnhancedUsagePage({\n billingAccountId: effectiveBillingAccountId,\n searchQuery: deferredSearchQuery || undefined,\n viewMode, // 'active' | 'past' | 'all'\n });\n\n // Filter quotas by status (search is now handled by backend)\n const filterQuotaByStatus = useCallback(\n (quota: AggregatedQuota): boolean => {\n if (statusFilter === 'all') return true;\n if (statusFilter === 'healthy') return quota.status === 'HEALTHY';\n if (statusFilter === 'warning') return quota.status === 'WARNING';\n if (statusFilter === 'critical')\n return quota.status === 'CRITICAL' || quota.status === 'EXHAUSTED';\n return true;\n },\n [statusFilter]\n );\n\n // Filtered data - only status filter is client-side, search is backend\n const filteredPooledQuotas = useMemo(() => {\n return pooledQuotas.filter(filterQuotaByStatus);\n }, [pooledQuotas, filterQuotaByStatus]);\n\n const filteredActiveSubscriptions = useMemo(() => {\n if (statusFilter === 'all') {\n return activeSubscriptions;\n }\n return activeSubscriptions\n .map((sub) => ({\n ...sub,\n aggregatedQuotas: sub.aggregatedQuotas.filter(filterQuotaByStatus),\n }))\n .filter((sub) => sub.aggregatedQuotas.length > 0);\n }, [activeSubscriptions, statusFilter, filterQuotaByStatus]);\n\n const filteredPastSubscriptions = useMemo(() => {\n if (statusFilter === 'all') {\n return pastSubscriptions;\n }\n return pastSubscriptions\n .map((sub) => ({\n ...sub,\n aggregatedQuotas: sub.aggregatedQuotas.filter(filterQuotaByStatus),\n }))\n .filter((sub) => sub.aggregatedQuotas.length > 0);\n }, [pastSubscriptions, statusFilter, filterQuotaByStatus]);\n\n // Subscriptions to display based on view mode\n const displayedSubscriptions = useMemo(() => {\n if (viewMode === 'active') {\n return { active: filteredActiveSubscriptions, past: [] };\n }\n if (viewMode === 'past') {\n return { active: [], past: filteredPastSubscriptions };\n }\n // 'all' - show both\n return { active: filteredActiveSubscriptions, past: filteredPastSubscriptions };\n }, [viewMode, filteredActiveSubscriptions, filteredPastSubscriptions]);\n\n const hasActiveFilters = searchQuery !== '' || statusFilter !== 'all';\n const isSearching = deferredSearchQuery !== searchQuery; // Show loading indicator while debouncing\n\n const clearFilters = () => {\n setSearchQuery('');\n setStatusFilter('all');\n };\n\n // Toggle status filter (click same to deselect)\n const toggleStatusFilter = (filter: StatusFilter) => {\n setStatusFilter((prev) => (prev === filter ? 'all' : filter));\n };\n\n // Permission check\n if (!permissions.canViewUsage) {\n return (\n <div className=\"flex items-center justify-center h-full min-h-[400px]\">\n <div className=\"text-center space-y-2\">\n <div className=\"w-12 h-12 mx-auto rounded-full bg-muted flex items-center justify-center\">\n <AlertTriangle className=\"w-6 h-6 text-muted-foreground\" />\n </div>\n <h2 className=\"text-lg font-semibold text-foreground\">Access Denied</h2>\n <p className=\"text-sm text-muted-foreground max-w-sm\">\n You don't have permission to view usage data.\n </p>\n </div>\n </div>\n );\n }\n\n // Loading state\n if ((isLoadingAccounts || isLoading) && !dashboard) {\n return (\n <div className=\"space-y-6 p-6\">\n <div className=\"h-8 w-48 bg-muted animate-pulse rounded\" />\n <div className=\"grid grid-cols-2 sm:grid-cols-4 gap-4\">\n {[1, 2, 3, 4].map((i) => (\n <div key={i} className=\"h-24 bg-muted animate-pulse rounded-lg\" />\n ))}\n </div>\n <div className=\"h-64 bg-muted animate-pulse rounded-lg\" />\n </div>\n );\n }\n\n // Error state\n if (error) {\n return (\n <div className=\"flex items-center justify-center h-full min-h-[400px]\">\n <div className=\"text-center space-y-4\">\n <div className=\"w-12 h-12 mx-auto rounded-full bg-destructive/10 flex items-center justify-center\">\n <AlertTriangle className=\"w-6 h-6 text-destructive\" />\n </div>\n <h2 className=\"text-lg font-semibold text-foreground\">Failed to load usage data</h2>\n <p className=\"text-sm text-muted-foreground\">{error.message}</p>\n <button\n onClick={() => refetch()}\n className=\"px-4 py-2 text-sm font-medium bg-primary text-primary-foreground rounded-md hover:bg-primary/90 transition-colors\"\n >\n Try Again\n </button>\n </div>\n </div>\n );\n }\n\n const selectedAccount = billingAccounts.find((a) => a.id === effectiveBillingAccountId);\n\n return (\n <div className=\"space-y-6 p-6\">\n {/* Header with Billing Account Selector */}\n <div className=\"flex flex-col gap-4 sm:flex-row sm:items-center sm:justify-between\">\n <div>\n <h1 className=\"text-2xl font-bold text-foreground\">\n {tr('billing.usage.title', 'Usage')}\n </h1>\n <p className=\"text-sm text-muted-foreground mt-1\">\n Monitor your resource consumption and quota usage\n </p>\n </div>\n\n <div className=\"flex items-center gap-3\">\n {/* Billing Account Selector */}\n {billingAccounts.length > 1 && (\n <select\n value={effectiveBillingAccountId || ''}\n onChange={(e) => setSelectedBillingAccountId(e.target.value)}\n className=\"px-3 py-2 text-sm border border-border rounded-md bg-background text-foreground focus:outline-none focus:ring-2 focus:ring-primary min-w-[200px]\"\n >\n {billingAccounts.map((account) => (\n <option key={account.id} value={account.id}>\n {account.name}\n </option>\n ))}\n </select>\n )}\n\n {/* Refresh Button */}\n <button\n onClick={() => refetch()}\n className=\"p-2 border border-border rounded-md hover:bg-muted/50 transition-colors\"\n title=\"Refresh\"\n >\n <RefreshCw className=\"w-4 h-4\" />\n </button>\n </div>\n </div>\n\n {/* Search and Filters */}\n <div className=\"flex flex-col gap-3 sm:flex-row sm:items-center\">\n {/* Search Input */}\n <div className=\"relative flex-1 max-w-md\">\n <Search className=\"absolute left-3 top-1/2 -translate-y-1/2 w-4 h-4 text-muted-foreground\" />\n <input\n type=\"text\"\n value={searchQuery}\n onChange={(e) => setSearchQuery(e.target.value)}\n placeholder={`Search ${viewMode === 'past' ? 'past' : viewMode === 'all' ? 'all' : 'active'} quotas...`}\n className=\"w-full pl-9 pr-3 py-2 text-sm border border-border rounded-md bg-background text-foreground placeholder:text-muted-foreground focus:outline-none focus:ring-2 focus:ring-primary\"\n />\n {(searchQuery || isSearching) && (\n <button\n onClick={() => setSearchQuery('')}\n className=\"absolute right-2 top-1/2 -translate-y-1/2 p-1 rounded hover:bg-muted/50\"\n >\n {isSearching ? (\n <RefreshCw className=\"w-3 h-3 text-muted-foreground animate-spin\" />\n ) : (\n <X className=\"w-3 h-3 text-muted-foreground\" />\n )}\n </button>\n )}\n </div>\n\n {/* View Mode Tabs */}\n <div className=\"flex items-center bg-muted/50 rounded-lg p-1 border border-border\">\n <button\n onClick={() => setViewMode('active')}\n className={`flex items-center gap-1.5 px-3 py-1.5 text-sm rounded-md transition-all ${\n viewMode === 'active'\n ? 'bg-background text-foreground shadow-sm font-medium'\n : 'text-muted-foreground hover:text-foreground'\n }`}\n >\n <Package className=\"w-3.5 h-3.5\" />\n Active\n </button>\n <button\n onClick={() => setViewMode('past')}\n disabled={isPastSubscriptionsLoading && viewMode !== 'past'}\n className={`flex items-center gap-1.5 px-3 py-1.5 text-sm rounded-md transition-all ${\n viewMode === 'past'\n ? 'bg-background text-foreground shadow-sm font-medium'\n : 'text-muted-foreground hover:text-foreground'\n } ${isPastSubscriptionsLoading && viewMode !== 'past' ? 'opacity-70' : ''}`}\n >\n {isPastSubscriptionsLoading && viewMode === 'past' ? (\n <RefreshCw className=\"w-3.5 h-3.5 animate-spin\" />\n ) : (\n <Clock className=\"w-3.5 h-3.5\" />\n )}\n Past\n </button>\n </div>\n\n {/* Active Filters Indicator */}\n {hasActiveFilters && (\n <button\n onClick={clearFilters}\n className=\"flex items-center gap-1.5 px-3 py-1.5 text-sm text-muted-foreground hover:text-foreground border border-border rounded-md hover:bg-muted/50 transition-colors\"\n >\n <X className=\"w-3 h-3\" />\n Clear filters\n </button>\n )}\n </div>\n\n {/* Billing Account Info */}\n {selectedAccount && (\n <div className=\"text-sm text-muted-foreground\">\n Viewing usage for{' '}\n <span className=\"font-medium text-foreground\">{selectedAccount.name}</span>\n </div>\n )}\n\n {/* Overview Stats - Clickable to filter */}\n {dashboard && (\n <div className=\"grid grid-cols-2 sm:grid-cols-4 gap-4\">\n <StatCard\n label=\"Total Quotas\"\n value={dashboard.totalQuotas}\n icon={<Layers className=\"w-5 h-5\" />}\n color=\"blue\"\n isActive={statusFilter === 'all'}\n onClick={() => setStatusFilter('all')}\n />\n <StatCard\n label=\"Healthy\"\n value={dashboard.healthyQuotas}\n icon={<CheckCircle className=\"w-5 h-5\" />}\n color=\"emerald\"\n isActive={statusFilter === 'healthy'}\n onClick={() => toggleStatusFilter('healthy')}\n />\n <StatCard\n label=\"Warning\"\n value={dashboard.warningQuotas}\n icon={<AlertCircle className=\"w-5 h-5\" />}\n color=\"amber\"\n isActive={statusFilter === 'warning'}\n onClick={() => toggleStatusFilter('warning')}\n />\n <StatCard\n label=\"Critical / Exhausted\"\n value={dashboard.criticalQuotas + dashboard.exhaustedQuotas}\n icon={<AlertTriangle className=\"w-5 h-5\" />}\n color=\"red\"\n isActive={statusFilter === 'critical'}\n onClick={() => toggleStatusFilter('critical')}\n />\n </div>\n )}\n\n {/* Filter Results Info */}\n {(hasActiveFilters || viewMode !== 'active') && (\n <div className=\"flex items-center gap-2 text-sm text-muted-foreground flex-wrap\">\n <span>\n Showing{' '}\n {displayedSubscriptions.active.reduce((acc, s) => acc + s.aggregatedQuotas.length, 0) +\n displayedSubscriptions.past.reduce((acc, s) => acc + s.aggregatedQuotas.length, 0) +\n (viewMode !== 'past' ? filteredPooledQuotas.length : 0)}{' '}\n quotas\n </span>\n <span className=\"px-2 py-0.5 bg-primary/10 text-primary rounded text-xs capitalize\">\n {viewMode === 'active' ? 'Active' : viewMode === 'past' ? 'Past' : 'All'} subscriptions\n </span>\n {statusFilter !== 'all' && (\n <span className=\"px-2 py-0.5 bg-muted rounded text-xs capitalize\">\n {statusFilter === 'critical' ? 'Critical / Exhausted' : statusFilter}\n </span>\n )}\n {searchQuery && (\n <span className=\"px-2 py-0.5 bg-muted rounded text-xs\">\n “{searchQuery}”\n </span>\n )}\n </div>\n )}\n\n {/* Active Subscriptions Section */}\n {displayedSubscriptions.active.length > 0 && (\n <section>\n <h2 className=\"text-lg font-semibold text-foreground mb-4 flex items-center gap-2\">\n <Package className=\"w-5 h-5 text-primary\" />\n {viewMode === 'all' ? 'Active Subscription Quotas' : 'Subscription Quotas'}\n </h2>\n <div className=\"space-y-4\">\n {displayedSubscriptions.active.map((subscription) => (\n <SubscriptionSection\n key={subscription.id}\n subscription={subscription}\n onQuotaClick={setSelectedQuota}\n defaultExpanded={true}\n />\n ))}\n </div>\n </section>\n )}\n\n {/* Past Subscriptions Section (when viewMode is 'past' or 'all') */}\n {displayedSubscriptions.past.length > 0 && (\n <section>\n <h2 className=\"text-lg font-semibold text-foreground mb-4 flex items-center gap-2\">\n <Clock className=\"w-5 h-5 text-muted-foreground\" />\n Past Subscription Quotas\n <span className=\"text-xs font-normal text-muted-foreground\">\n (Canceled / Expired / Upgraded)\n </span>\n {pastSubscriptionsCount > 0 && (\n <span className=\"text-xs font-normal px-2 py-0.5 bg-muted rounded-full\">\n {displayedSubscriptions.past.length}\n {hasMorePastSubscriptions ? '+' : ''} of {pastSubscriptionsCount}\n </span>\n )}\n </h2>\n <div className=\"space-y-4\">\n {displayedSubscriptions.past.map((subscription) => (\n <SubscriptionSection\n key={subscription.id}\n subscription={subscription}\n onQuotaClick={setSelectedQuota}\n defaultExpanded={viewMode === 'past'}\n />\n ))}\n\n {/* Load More Button */}\n {hasMorePastSubscriptions && (\n <div className=\"flex justify-center pt-2\">\n <button\n onClick={loadMorePastSubscriptions}\n disabled={isLoadingMorePast}\n className=\"flex items-center gap-2 px-4 py-2 text-sm font-medium text-muted-foreground hover:text-foreground border border-border rounded-md hover:bg-muted/50 transition-colors disabled:opacity-50\"\n >\n {isLoadingMorePast ? (\n <>\n <RefreshCw className=\"w-4 h-4 animate-spin\" />\n Loading...\n </>\n ) : (\n <>\n <ChevronDown className=\"w-4 h-4\" />\n Load more past subscriptions\n </>\n )}\n </button>\n </div>\n )}\n </div>\n </section>\n )}\n\n {/* Pooled Quotas Section - Only show for active/all views (pooled quotas are account-level) */}\n {viewMode !== 'past' && filteredPooledQuotas.length > 0 && (\n <section>\n <h2 className=\"text-lg font-semibold text-foreground mb-4 flex items-center gap-2\">\n <Layers className={`w-5 h-5 ${statusTokens.info.icon}`} />\n Pooled Quotas\n <span className=\"text-xs font-normal text-muted-foreground\">\n (Shared across all products)\n </span>\n </h2>\n <div className=\"grid grid-cols-1 md:grid-cols-2 gap-4\">\n {filteredPooledQuotas.map((quota) => (\n <QuotaCard key={quota.name} quota={quota} onClick={() => setSelectedQuota(quota)} />\n ))}\n </div>\n </section>\n )}\n\n {/* Empty State - No quotas at all (when viewing active) */}\n {viewMode === 'active' &&\n activeSubscriptions.length === 0 &&\n pooledQuotas.length === 0 &&\n !hasActiveFilters && (\n <div className=\"flex flex-col items-center justify-center py-12 border border-dashed border-border rounded-lg\">\n <div className=\"w-12 h-12 rounded-full bg-muted flex items-center justify-center mb-4\">\n <Layers className=\"w-6 h-6 text-muted-foreground\" />\n </div>\n <h3 className=\"text-lg font-medium text-foreground\">No active quotas found</h3>\n <p className=\"text-sm text-muted-foreground mt-1 text-center max-w-sm\">\n Quotas will appear here once you have active subscriptions or pooled allocations.\n </p>\n </div>\n )}\n\n {/* Empty State - No past subscriptions */}\n {viewMode === 'past' &&\n pastSubscriptions.length === 0 &&\n !hasActiveFilters &&\n !isPastSubscriptionsLoading && (\n <div className=\"flex flex-col items-center justify-center py-12 border border-dashed border-border rounded-lg\">\n <div className=\"w-12 h-12 rounded-full bg-muted flex items-center justify-center mb-4\">\n <Clock className=\"w-6 h-6 text-muted-foreground\" />\n </div>\n <h3 className=\"text-lg font-medium text-foreground\">No past subscriptions</h3>\n <p className=\"text-sm text-muted-foreground mt-1 text-center max-w-sm\">\n You don't have any canceled, expired, or upgraded subscriptions yet.\n </p>\n <button\n onClick={() => setViewMode('active')}\n className=\"mt-4 px-4 py-2 text-sm font-medium bg-primary text-primary-foreground rounded-md hover:bg-primary/90 transition-colors\"\n >\n View active subscriptions\n </button>\n </div>\n )}\n\n {/* Loading State for Past Subscriptions */}\n {viewMode === 'past' && isPastSubscriptionsLoading && (\n <div className=\"space-y-4\">\n {[1, 2, 3].map((i) => (\n <div key={i} className=\"h-24 bg-muted animate-pulse rounded-lg\" />\n ))}\n </div>\n )}\n\n {/* Empty State - No results from search/filter */}\n {hasActiveFilters &&\n displayedSubscriptions.active.length === 0 &&\n displayedSubscriptions.past.length === 0 &&\n (viewMode === 'past' || filteredPooledQuotas.length === 0) && (\n <div className=\"flex flex-col items-center justify-center py-12 border border-dashed border-border rounded-lg\">\n <div className=\"w-12 h-12 rounded-full bg-muted flex items-center justify-center mb-4\">\n {statusFilter !== 'all' && !searchQuery ? (\n <StatusIcon\n status={\n (statusFilter === 'healthy'\n ? 'HEALTHY'\n : statusFilter === 'warning'\n ? 'WARNING'\n : 'CRITICAL') as QuotaStatus\n }\n className=\"w-6 h-6\"\n />\n ) : (\n <Search className=\"w-6 h-6 text-muted-foreground\" />\n )}\n </div>\n <h3 className=\"text-lg font-medium text-foreground\">\n {statusFilter !== 'all' && !searchQuery\n ? `No ${statusFilter === 'critical' ? 'critical or exhausted' : statusFilter} quotas`\n : 'No matching quotas'}\n </h3>\n <p className=\"text-sm text-muted-foreground mt-1 text-center max-w-sm\">\n {statusFilter !== 'all' && !searchQuery ? (\n <>\n All your quotas are in a different status.\n {dashboard && (\n <span className=\"block mt-1\">\n You have {dashboard.healthyQuotas} healthy, {dashboard.warningQuotas} warning,\n and {dashboard.criticalQuotas + dashboard.exhaustedQuotas} critical quotas.\n </span>\n )}\n </>\n ) : (\n <>\n No quotas match your current search or filter criteria in{' '}\n {viewMode === 'past' ? 'past' : viewMode === 'all' ? 'any' : 'active'}{' '}\n subscriptions.\n {viewMode === 'active' && !statusFilter.includes('all') && (\n <span className=\"block mt-1\">\n Try switching to “Past” or “All” to search across more\n subscriptions.\n </span>\n )}\n </>\n )}\n </p>\n <div className=\"flex gap-2 mt-4\">\n <button\n onClick={clearFilters}\n className=\"px-4 py-2 text-sm font-medium border border-border rounded-md hover:bg-muted/50 transition-colors\"\n >\n {statusFilter !== 'all' ? 'Show all quotas' : 'Clear filters'}\n </button>\n {viewMode === 'active' && searchQuery && (\n <button\n onClick={() => setViewMode('all')}\n className=\"px-4 py-2 text-sm font-medium bg-primary text-primary-foreground rounded-md hover:bg-primary/90 transition-colors\"\n >\n Search all\n </button>\n )}\n </div>\n </div>\n )}\n\n {/* Quota Detail Modal */}\n {selectedQuota && (\n <QuotaDetailModal quota={selectedQuota} onClose={() => setSelectedQuota(null)} />\n )}\n </div>\n );\n};\n"],"mappings":";;;;;;;;;;AAkDA,IAAM,KAA+D,EACnE,WACA,eAAY,gBACR;AACJ,SAAQ,GAAR;EACE,KAAK,YACH,QAAO,kBAAC,GAAD,EAAS,WAAW,GAAG,EAAU,GAAG,EAAa,MAAM,QAAU,CAAA;EAC1E,KAAK,WACH,QAAO,kBAAC,GAAD,EAAe,WAAW,GAAG,EAAU,GAAG,EAAa,MAAM,QAAU,CAAA;EAChF,KAAK,UACH,QAAO,kBAAC,GAAD,EAAa,WAAW,GAAG,EAAU,GAAG,EAAa,QAAQ,QAAU,CAAA;EAChF,KAAK,UACH,QAAO,kBAAC,GAAD,EAAa,WAAW,GAAG,EAAU,GAAG,EAAa,QAAQ,QAAU,CAAA;EAChF,QACE,QAAO,kBAAC,GAAD,EAAM,WAAW,GAAG,EAAU,GAAG,EAAa,QAAQ,QAAU,CAAA;;GAIvE,KAA4C,EAAE,gBAUhD,kBAAC,QAAD;CAAM,WAAW,2CATyB;EAC1C,WAAW,GAAG,EAAa,MAAM,GAAG,GAAG,EAAa,MAAM;EAC1D,UAAU,GAAG,EAAa,MAAM,GAAG,GAAG,EAAa,MAAM;EACzD,SAAS,GAAG,EAAa,QAAQ,GAAG,GAAG,EAAa,QAAQ;EAC5D,SAAS,GAAG,EAAa,QAAQ,GAAG,GAAG,EAAa,QAAQ;EAC5D,UAAU,GAAG,EAAa,QAAQ,GAAG,GAAG,EAAa,QAAQ;EAC9D,CAGoE;WAAY;CAAc,CAAA,EAI3F,KAAgE,EAAE,eAAY,gBAAa;CAC/F,IAAM,IAAoB,KAAK,IAAI,KAAK,KAAK,IAAI,GAAG,EAAW,CAAC;AAUhE,QACE,kBAAC,OAAD;EAAK,WAAU;YACb,kBAAC,OAAD;GACE,WAAW,mDAX8B;IAC7C,WAAW,EAA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S,MAAa,QAAQ,QAAQ;OAAU;OAAI;OAE1E,MAAa,YAAY,CAAC,EAAa,SAAS,MAAM,IACrD,kBAAC,QAAD;QAAM,WAAU;kBAAa;QAGtB,CAAA;OAER,EAAA,CAAA;MAEH,CAAA;KACJ,kBAAC,OAAD;MAAK,WAAU;gBAAf,CACE,kBAAC,UAAD;OACE,SAAS;OACT,WAAU;iBAET,MAAiB,QAA4B,kBAApB;OACnB,CAAA,EACR,MAAa,YAAY,KACxB,kBAAC,UAAD;OACE,eAAe,EAAY,MAAM;OACjC,WAAU;iBACX;OAEQ,CAAA,CAEP;;KACF;;GAIT,KACC,kBAAC,IAAD;IAAkB,OAAO;IAAe,eAAe,EAAiB,KAAK;IAAI,CAAA;GAE/E"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/billing/modules/usage/pages/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import "./UsagePage.js";
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { FC, PropsWithChildren } from 'react';
|
|
2
|
+
import { BillingRootProps } from '../types';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Hook to access Billing context
|
|
6
|
+
*/
|
|
7
|
+
export declare const useBilling: () => BillingRootProps;
|
|
8
|
+
/**
|
|
9
|
+
* Provider component for Billing microfrontend
|
|
10
|
+
* Sets up routing and context
|
|
11
|
+
*
|
|
12
|
+
* When integrated into a shell (basePath provided), the shell already has a router
|
|
13
|
+
* so we don't create another one. When standalone (no basePath), use MemoryRouter.
|
|
14
|
+
*/
|
|
15
|
+
export declare const BillingProvider: FC<PropsWithChildren<BillingRootProps>>;
|
|
16
|
+
//# sourceMappingURL=BillingProvider.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"BillingProvider.d.ts","sourceRoot":"","sources":["../../../src/billing/providers/BillingProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,EAAE,iBAAiB,EAAE,MAAM,OAAO,CAAC;AAInD,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,UAAU,CAAC;AASjD;;GAEG;AACH,eAAO,MAAM,UAAU,wBAMtB,CAAC;AAEF;;;;;;GAMG;AACH,eAAO,MAAM,eAAe,EAAE,EAAE,CAAC,iBAAiB,CAAC,gBAAgB,CAAC,CAoDnE,CAAC"}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import { createContext as e, useContext as t } from "react";
|
|
2
|
+
import { MemoryRouter as n } from "react-router-dom";
|
|
3
|
+
import { PermissionProvider as r } from "@burdenoff/fe-libs/shared/providers/shell";
|
|
4
|
+
import { jsx as i } from "react/jsx-runtime";
|
|
5
|
+
//#region src/billing/providers/BillingProvider.tsx
|
|
6
|
+
var a = e(null), o = () => {
|
|
7
|
+
let e = t(a);
|
|
8
|
+
if (!e) throw Error("useBilling must be used within BillingProvider");
|
|
9
|
+
return e;
|
|
10
|
+
}, s = ({ children: e, basePath: t, navigate: o, currentUser: s, workspaceId: c, orgId: l, productId: u, apiGatewayUrl: d, authToken: f, stripePublishableKey: p, razorpayKey: m, onSubscriptionCreate: h, onSubscriptionUpdate: g, onPaymentProcess: _, registerNavItems: v, registerFooterItems: y }) => {
|
|
11
|
+
let b = {
|
|
12
|
+
basePath: t,
|
|
13
|
+
navigate: o,
|
|
14
|
+
currentUser: s,
|
|
15
|
+
workspaceId: c,
|
|
16
|
+
orgId: l,
|
|
17
|
+
productId: u,
|
|
18
|
+
apiGatewayUrl: d,
|
|
19
|
+
authToken: f,
|
|
20
|
+
stripePublishableKey: p,
|
|
21
|
+
razorpayKey: m,
|
|
22
|
+
onSubscriptionCreate: h,
|
|
23
|
+
onSubscriptionUpdate: g,
|
|
24
|
+
onPaymentProcess: _,
|
|
25
|
+
registerNavItems: v,
|
|
26
|
+
registerFooterItems: y
|
|
27
|
+
}, x = /* @__PURE__ */ i(a.Provider, {
|
|
28
|
+
value: b,
|
|
29
|
+
children: /* @__PURE__ */ i(r, {
|
|
30
|
+
scopeId: l,
|
|
31
|
+
gateway: "global",
|
|
32
|
+
children: e
|
|
33
|
+
})
|
|
34
|
+
});
|
|
35
|
+
return t ? x : /* @__PURE__ */ i(n, { children: x });
|
|
36
|
+
};
|
|
37
|
+
//#endregion
|
|
38
|
+
export { s as BillingProvider, o as useBilling };
|
|
39
|
+
|
|
40
|
+
//# sourceMappingURL=BillingProvider.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"BillingProvider.js","names":[],"sources":["../../../src/billing/providers/BillingProvider.tsx"],"sourcesContent":["import type { FC, PropsWithChildren } from 'react';\nimport { createContext, useContext } from 'react';\nimport { MemoryRouter } from 'react-router-dom';\nimport { PermissionProvider } from '@burdenoff/fe-libs/shared/providers/shell';\nimport type { BillingRootProps } from '../types';\n\n/**\n * Context value for Billing microfrontend\n */\ntype BillingContextValue = BillingRootProps;\n\nconst BillingContext = createContext<BillingContextValue | null>(null);\n\n/**\n * Hook to access Billing context\n */\nexport const useBilling = () => {\n const context = useContext(BillingContext);\n if (!context) {\n throw new Error('useBilling must be used within BillingProvider');\n }\n return context;\n};\n\n/**\n * Provider component for Billing microfrontend\n * Sets up routing and context\n *\n * When integrated into a shell (basePath provided), the shell already has a router\n * so we don't create another one. When standalone (no basePath), use MemoryRouter.\n */\nexport const BillingProvider: FC<PropsWithChildren<BillingRootProps>> = ({\n children,\n basePath,\n navigate,\n currentUser,\n workspaceId,\n orgId,\n productId,\n apiGatewayUrl,\n authToken,\n stripePublishableKey,\n razorpayKey,\n onSubscriptionCreate,\n onSubscriptionUpdate,\n onPaymentProcess,\n registerNavItems,\n registerFooterItems,\n}) => {\n const contextValue: BillingContextValue = {\n basePath,\n navigate,\n currentUser,\n workspaceId,\n orgId,\n productId,\n apiGatewayUrl,\n authToken,\n stripePublishableKey,\n razorpayKey,\n onSubscriptionCreate,\n onSubscriptionUpdate,\n onPaymentProcess,\n registerNavItems,\n registerFooterItems,\n };\n\n const content = (\n <BillingContext.Provider value={contextValue}>\n <PermissionProvider scopeId={orgId} gateway=\"global\">\n {children}\n </PermissionProvider>\n </BillingContext.Provider>\n );\n\n // When integrated into a shell (basePath provided), the shell already has a router\n // so we don't create another one. When standalone (no basePath), use MemoryRouter.\n if (basePath) {\n return content;\n }\n\n // Standalone mode: create MemoryRouter for independent operation\n return <MemoryRouter>{content}</MemoryRouter>;\n};\n"],"mappings":";;;;;AAWA,IAAM,IAAiB,EAA0C,KAAK,EAKzD,UAAmB;CAC9B,IAAM,IAAU,EAAW,EAAe;AAC1C,KAAI,CAAC,EACH,OAAU,MAAM,iDAAiD;AAEnE,QAAO;GAUI,KAA4D,EACvE,aACA,aACA,aACA,gBACA,gBACA,UACA,cACA,kBACA,cACA,yBACA,gBACA,yBACA,yBACA,qBACA,qBACA,6BACI;CACJ,IAAM,IAAoC;EACxC;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACD,EAEK,IACJ,kBAAC,EAAe,UAAhB;EAAyB,OAAO;YAC9B,kBAAC,GAAD;GAAoB,SAAS;GAAO,SAAQ;GACzC;GACkB,CAAA;EACG,CAAA;AAU5B,QALI,IACK,IAIF,kBAAC,GAAD,EAAA,UAAe,GAAuB,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"AccessDenied.d.ts","sourceRoot":"","sources":["../../../../src/billing/shared/components/AccessDenied.tsx"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAGhC,UAAU,iBAAiB;IACzB,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAED,eAAO,MAAM,YAAY,EAAE,EAAE,CAAC,iBAAiB,CAoC9C,CAAC"}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { jsx as e, jsxs as t } from "react/jsx-runtime";
|
|
2
|
+
import { useI18n as n } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
|
|
3
|
+
//#region src/billing/shared/components/AccessDenied.tsx
|
|
4
|
+
var r = ({ message: r }) => {
|
|
5
|
+
let { t: i } = n(), a = (e, t) => {
|
|
6
|
+
let n = i(e);
|
|
7
|
+
return n === e ? t : n;
|
|
8
|
+
}, o = r ?? a("billing.accessDenied.defaultMessage", "You don't have permission to access this page.");
|
|
9
|
+
return /* @__PURE__ */ e("div", {
|
|
10
|
+
className: "flex items-center justify-center h-full min-h-[400px]",
|
|
11
|
+
children: /* @__PURE__ */ t("div", {
|
|
12
|
+
className: "text-center space-y-2",
|
|
13
|
+
children: [
|
|
14
|
+
/* @__PURE__ */ e("div", {
|
|
15
|
+
className: "w-12 h-12 mx-auto rounded-full bg-muted flex items-center justify-center",
|
|
16
|
+
children: /* @__PURE__ */ e("svg", {
|
|
17
|
+
className: "w-6 h-6 text-muted-foreground",
|
|
18
|
+
fill: "none",
|
|
19
|
+
viewBox: "0 0 24 24",
|
|
20
|
+
stroke: "currentColor",
|
|
21
|
+
children: /* @__PURE__ */ e("path", {
|
|
22
|
+
strokeLinecap: "round",
|
|
23
|
+
strokeLinejoin: "round",
|
|
24
|
+
strokeWidth: 2,
|
|
25
|
+
d: "M12 15v2m-6 4h12a2 2 0 002-2v-6a2 2 0 00-2-2H6a2 2 0 00-2 2v6a2 2 0 002 2zm10-10V7a4 4 0 00-8 0v4h8z"
|
|
26
|
+
})
|
|
27
|
+
})
|
|
28
|
+
}),
|
|
29
|
+
/* @__PURE__ */ e("h2", {
|
|
30
|
+
className: "text-lg font-semibold text-foreground",
|
|
31
|
+
children: a("billing.accessDenied.title", "Access Denied")
|
|
32
|
+
}),
|
|
33
|
+
/* @__PURE__ */ e("p", {
|
|
34
|
+
className: "text-sm text-muted-foreground max-w-sm",
|
|
35
|
+
children: o
|
|
36
|
+
})
|
|
37
|
+
]
|
|
38
|
+
})
|
|
39
|
+
});
|
|
40
|
+
};
|
|
41
|
+
//#endregion
|
|
42
|
+
export { r as AccessDenied };
|
|
43
|
+
|
|
44
|
+
//# sourceMappingURL=AccessDenied.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"AccessDenied.js","names":[],"sources":["../../../../src/billing/shared/components/AccessDenied.tsx"],"sourcesContent":["/**\n * Shared Access Denied Component\n * Displays when user lacks permission to view a page\n */\n\nimport type { FC } from 'react';\nimport { useI18n } from '@burdenoff/fe-libs/shared/providers/shell/I18nProvider';\n\ninterface AccessDeniedProps {\n message?: string;\n}\n\nexport const AccessDenied: FC<AccessDeniedProps> = ({ message }) => {\n const { t } = useI18n();\n const tr = (key: string, fallback: string): string => {\n const translated = t(key);\n return translated === key ? fallback : translated;\n };\n\n const displayMessage =\n message ??\n tr('billing.accessDenied.defaultMessage', \"You don't have permission to access this page.\");\n\n return (\n <div className=\"flex items-center justify-center h-full min-h-[400px]\">\n <div className=\"text-center space-y-2\">\n <div className=\"w-12 h-12 mx-auto rounded-full bg-muted flex items-center justify-center\">\n <svg\n className=\"w-6 h-6 text-muted-foreground\"\n fill=\"none\"\n viewBox=\"0 0 24 24\"\n stroke=\"currentColor\"\n >\n <path\n strokeLinecap=\"round\"\n strokeLinejoin=\"round\"\n strokeWidth={2}\n d=\"M12 15v2m-6 4h12a2 2 0 002-2v-6a2 2 0 00-2-2H6a2 2 0 00-2 2v6a2 2 0 002 2zm10-10V7a4 4 0 00-8 0v4h8z\"\n />\n </svg>\n </div>\n <h2 className=\"text-lg font-semibold text-foreground\">\n {tr('billing.accessDenied.title', 'Access Denied')}\n </h2>\n <p className=\"text-sm text-muted-foreground max-w-sm\">{displayMessage}</p>\n </div>\n </div>\n );\n};\n"],"mappings":";;;AAYA,IAAa,KAAuC,EAAE,iBAAc;CAClE,IAAM,EAAE,SAAM,GAAS,EACjB,KAAM,GAAa,MAA6B;EACpD,IAAM,IAAa,EAAE,EAAI;AACzB,SAAO,MAAe,IAAM,IAAW;IAGnC,IACJ,KACA,EAAG,uCAAuC,iDAAiD;AAE7F,QACE,kBAAC,OAAD;EAAK,WAAU;YACb,kBAAC,OAAD;GAAK,WAAU;aAAf;IACE,kBAAC,OAAD;KAAK,WAAU;eACb,kBAAC,OAAD;MACE,WAAU;MACV,MAAK;MACL,SAAQ;MACR,QAAO;gBAEP,kBAAC,QAAD;OACE,eAAc;OACd,gBAAe;OACf,aAAa;OACb,GAAE;OACF,CAAA;MACE,CAAA;KACF,CAAA;IACN,kBAAC,MAAD;KAAI,WAAU;eACX,EAAG,8BAA8B,gBAAgB;KAC/C,CAAA;IACL,kBAAC,KAAD;KAAG,WAAU;eAA0C;KAAmB,CAAA;IACtE;;EACF,CAAA"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { FC } from 'react';
|
|
2
|
+
import { CurrencyPriceOverrideInput } from '../types';
|
|
3
|
+
|
|
4
|
+
interface CurrencyPriceOverridesEditorProps {
|
|
5
|
+
overrides: CurrencyPriceOverrideInput[];
|
|
6
|
+
onChange: (overrides: CurrencyPriceOverrideInput[]) => void;
|
|
7
|
+
showPerSeatAmount?: boolean;
|
|
8
|
+
}
|
|
9
|
+
export declare const CurrencyPriceOverridesEditor: FC<CurrencyPriceOverridesEditorProps>;
|
|
10
|
+
export {};
|
|
11
|
+
//# sourceMappingURL=CurrencyPriceOverridesEditor.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CurrencyPriceOverridesEditor.d.ts","sourceRoot":"","sources":["../../../../src/billing/shared/components/CurrencyPriceOverridesEditor.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAY,KAAK,EAAE,EAAE,MAAM,OAAO,CAAC;AAE1C,OAAO,KAAK,EAAE,0BAA0B,EAAE,MAAM,UAAU,CAAC;AAE3D,UAAU,iCAAiC;IACzC,SAAS,EAAE,0BAA0B,EAAE,CAAC;IACxC,QAAQ,EAAE,CAAC,SAAS,EAAE,0BAA0B,EAAE,KAAK,IAAI,CAAC;IAC5D,iBAAiB,CAAC,EAAE,OAAO,CAAC;CAC7B;AAyBD,eAAO,MAAM,4BAA4B,EAAE,EAAE,CAAC,iCAAiC,CAgJ9E,CAAC"}
|
|
@@ -0,0 +1,230 @@
|
|
|
1
|
+
import { useState as e } from "react";
|
|
2
|
+
import { jsx as t, jsxs as n } from "react/jsx-runtime";
|
|
3
|
+
//#region src/billing/shared/components/CurrencyPriceOverridesEditor.tsx
|
|
4
|
+
var r = [
|
|
5
|
+
{
|
|
6
|
+
code: "EUR",
|
|
7
|
+
name: "Euro",
|
|
8
|
+
symbol: "€"
|
|
9
|
+
},
|
|
10
|
+
{
|
|
11
|
+
code: "GBP",
|
|
12
|
+
name: "British Pound",
|
|
13
|
+
symbol: "£"
|
|
14
|
+
},
|
|
15
|
+
{
|
|
16
|
+
code: "INR",
|
|
17
|
+
name: "Indian Rupee",
|
|
18
|
+
symbol: "₹"
|
|
19
|
+
},
|
|
20
|
+
{
|
|
21
|
+
code: "AUD",
|
|
22
|
+
name: "Australian Dollar",
|
|
23
|
+
symbol: "A$"
|
|
24
|
+
},
|
|
25
|
+
{
|
|
26
|
+
code: "CAD",
|
|
27
|
+
name: "Canadian Dollar",
|
|
28
|
+
symbol: "C$"
|
|
29
|
+
},
|
|
30
|
+
{
|
|
31
|
+
code: "SGD",
|
|
32
|
+
name: "Singapore Dollar",
|
|
33
|
+
symbol: "S$"
|
|
34
|
+
},
|
|
35
|
+
{
|
|
36
|
+
code: "JPY",
|
|
37
|
+
name: "Japanese Yen",
|
|
38
|
+
symbol: "¥"
|
|
39
|
+
},
|
|
40
|
+
{
|
|
41
|
+
code: "MXN",
|
|
42
|
+
name: "Mexican Peso",
|
|
43
|
+
symbol: "MX$"
|
|
44
|
+
},
|
|
45
|
+
{
|
|
46
|
+
code: "BRL",
|
|
47
|
+
name: "Brazilian Real",
|
|
48
|
+
symbol: "R$"
|
|
49
|
+
},
|
|
50
|
+
{
|
|
51
|
+
code: "CHF",
|
|
52
|
+
name: "Swiss Franc",
|
|
53
|
+
symbol: "Fr"
|
|
54
|
+
},
|
|
55
|
+
{
|
|
56
|
+
code: "CNY",
|
|
57
|
+
name: "Chinese Yuan",
|
|
58
|
+
symbol: "¥"
|
|
59
|
+
},
|
|
60
|
+
{
|
|
61
|
+
code: "HKD",
|
|
62
|
+
name: "Hong Kong Dollar",
|
|
63
|
+
symbol: "HK$"
|
|
64
|
+
},
|
|
65
|
+
{
|
|
66
|
+
code: "NZD",
|
|
67
|
+
name: "New Zealand Dollar",
|
|
68
|
+
symbol: "NZ$"
|
|
69
|
+
},
|
|
70
|
+
{
|
|
71
|
+
code: "SEK",
|
|
72
|
+
name: "Swedish Krona",
|
|
73
|
+
symbol: "kr"
|
|
74
|
+
},
|
|
75
|
+
{
|
|
76
|
+
code: "KRW",
|
|
77
|
+
name: "South Korean Won",
|
|
78
|
+
symbol: "₩"
|
|
79
|
+
},
|
|
80
|
+
{
|
|
81
|
+
code: "NOK",
|
|
82
|
+
name: "Norwegian Krone",
|
|
83
|
+
symbol: "kr"
|
|
84
|
+
},
|
|
85
|
+
{
|
|
86
|
+
code: "DKK",
|
|
87
|
+
name: "Danish Krone",
|
|
88
|
+
symbol: "kr"
|
|
89
|
+
},
|
|
90
|
+
{
|
|
91
|
+
code: "PLN",
|
|
92
|
+
name: "Polish Złoty",
|
|
93
|
+
symbol: "zł"
|
|
94
|
+
},
|
|
95
|
+
{
|
|
96
|
+
code: "THB",
|
|
97
|
+
name: "Thai Baht",
|
|
98
|
+
symbol: "฿"
|
|
99
|
+
},
|
|
100
|
+
{
|
|
101
|
+
code: "MYR",
|
|
102
|
+
name: "Malaysian Ringgit",
|
|
103
|
+
symbol: "RM"
|
|
104
|
+
}
|
|
105
|
+
], i = ({ overrides: i, onChange: a, showPerSeatAmount: o = !1 }) => {
|
|
106
|
+
let [s, c] = e(!1), l = (e) => i.find((t) => t.currency === e), u = (e, t) => {
|
|
107
|
+
let n = t.trim(), r = i.filter((t) => t.currency !== e);
|
|
108
|
+
if (n === "") {
|
|
109
|
+
a(r);
|
|
110
|
+
return;
|
|
111
|
+
}
|
|
112
|
+
let o = parseFloat(n);
|
|
113
|
+
if (isNaN(o) || o < 0) return;
|
|
114
|
+
let s = l(e);
|
|
115
|
+
a([...r, {
|
|
116
|
+
currency: e,
|
|
117
|
+
amount: o,
|
|
118
|
+
...s?.perSeatAmount === void 0 ? {} : { perSeatAmount: s.perSeatAmount }
|
|
119
|
+
}]);
|
|
120
|
+
}, d = (e, t) => {
|
|
121
|
+
let n = t.trim(), r = i.filter((t) => t.currency !== e), o = l(e);
|
|
122
|
+
if (!o) return;
|
|
123
|
+
if (n === "") {
|
|
124
|
+
a([...r, {
|
|
125
|
+
currency: e,
|
|
126
|
+
amount: o.amount
|
|
127
|
+
}]);
|
|
128
|
+
return;
|
|
129
|
+
}
|
|
130
|
+
let s = parseFloat(n);
|
|
131
|
+
isNaN(s) || s < 0 || a([...r, {
|
|
132
|
+
...o,
|
|
133
|
+
perSeatAmount: s
|
|
134
|
+
}]);
|
|
135
|
+
}, f = i.length;
|
|
136
|
+
return /* @__PURE__ */ n("div", {
|
|
137
|
+
className: "border border-border rounded-lg bg-card overflow-hidden",
|
|
138
|
+
children: [/* @__PURE__ */ n("button", {
|
|
139
|
+
type: "button",
|
|
140
|
+
onClick: () => c((e) => !e),
|
|
141
|
+
className: "w-full p-4 border-b border-border bg-muted/30 flex items-center justify-between hover:bg-muted/50 transition-colors",
|
|
142
|
+
children: [/* @__PURE__ */ n("div", {
|
|
143
|
+
className: "flex items-center gap-2",
|
|
144
|
+
children: [/* @__PURE__ */ t("h2", {
|
|
145
|
+
className: "font-semibold text-foreground",
|
|
146
|
+
children: "Currency Price Overrides"
|
|
147
|
+
}), f > 0 && /* @__PURE__ */ n("span", {
|
|
148
|
+
className: "px-2 py-0.5 text-xs font-medium bg-primary/10 text-primary rounded-full",
|
|
149
|
+
children: [f, " set"]
|
|
150
|
+
})]
|
|
151
|
+
}), /* @__PURE__ */ n("div", {
|
|
152
|
+
className: "flex items-center gap-2 text-sm text-muted-foreground",
|
|
153
|
+
children: [/* @__PURE__ */ n("span", { children: [s ? "Hide" : "Show", " — leave blank to use auto-calculated exchange rates"] }), /* @__PURE__ */ t("svg", {
|
|
154
|
+
className: `w-4 h-4 transition-transform ${s ? "rotate-180" : ""}`,
|
|
155
|
+
fill: "none",
|
|
156
|
+
viewBox: "0 0 24 24",
|
|
157
|
+
stroke: "currentColor",
|
|
158
|
+
children: /* @__PURE__ */ t("path", {
|
|
159
|
+
strokeLinecap: "round",
|
|
160
|
+
strokeLinejoin: "round",
|
|
161
|
+
strokeWidth: 2,
|
|
162
|
+
d: "M19 9l-7 7-7-7"
|
|
163
|
+
})
|
|
164
|
+
})]
|
|
165
|
+
})]
|
|
166
|
+
}), s && /* @__PURE__ */ n("div", {
|
|
167
|
+
className: "p-4",
|
|
168
|
+
children: [
|
|
169
|
+
/* @__PURE__ */ t("p", {
|
|
170
|
+
className: "text-xs text-muted-foreground mb-4",
|
|
171
|
+
children: "Set a specific price for any currency. Leave a field empty to auto-calculate from the USD base price using live exchange rates."
|
|
172
|
+
}),
|
|
173
|
+
/* @__PURE__ */ t("div", {
|
|
174
|
+
className: "grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 xl:grid-cols-4 gap-3",
|
|
175
|
+
children: r.map(({ code: e, name: r, symbol: i }) => {
|
|
176
|
+
let a = l(e);
|
|
177
|
+
return /* @__PURE__ */ n("div", {
|
|
178
|
+
className: "space-y-1",
|
|
179
|
+
children: [/* @__PURE__ */ n("label", {
|
|
180
|
+
className: "flex items-center gap-1 text-xs font-medium text-foreground",
|
|
181
|
+
children: [
|
|
182
|
+
/* @__PURE__ */ t("span", {
|
|
183
|
+
className: "text-muted-foreground",
|
|
184
|
+
children: i
|
|
185
|
+
}),
|
|
186
|
+
/* @__PURE__ */ t("span", { children: e }),
|
|
187
|
+
/* @__PURE__ */ n("span", {
|
|
188
|
+
className: "text-muted-foreground font-normal truncate",
|
|
189
|
+
children: ["— ", r]
|
|
190
|
+
})
|
|
191
|
+
]
|
|
192
|
+
}), /* @__PURE__ */ n("div", {
|
|
193
|
+
className: o ? "flex gap-1" : "",
|
|
194
|
+
children: [/* @__PURE__ */ t("input", {
|
|
195
|
+
type: "number",
|
|
196
|
+
step: "0.01",
|
|
197
|
+
min: "0",
|
|
198
|
+
value: a?.amount ?? "",
|
|
199
|
+
onChange: (t) => u(e, t.target.value),
|
|
200
|
+
placeholder: "auto",
|
|
201
|
+
className: `px-2 py-1.5 text-sm border border-border rounded-md bg-background text-foreground focus:outline-none focus:ring-1 focus:ring-primary placeholder:text-muted-foreground ${o ? "flex-1 min-w-0" : "w-full"} ${a?.amount === void 0 ? "" : "border-primary/50"}`
|
|
202
|
+
}), o && /* @__PURE__ */ t("input", {
|
|
203
|
+
type: "number",
|
|
204
|
+
step: "0.01",
|
|
205
|
+
min: "0",
|
|
206
|
+
value: a?.perSeatAmount ?? "",
|
|
207
|
+
onChange: (t) => d(e, t.target.value),
|
|
208
|
+
placeholder: "/seat",
|
|
209
|
+
disabled: !a,
|
|
210
|
+
title: "Per-seat amount (requires flat amount to be set first)",
|
|
211
|
+
className: "flex-1 min-w-0 px-2 py-1.5 text-sm border border-border rounded-md bg-background text-foreground focus:outline-none focus:ring-1 focus:ring-primary placeholder:text-muted-foreground disabled:opacity-40"
|
|
212
|
+
})]
|
|
213
|
+
})]
|
|
214
|
+
}, e);
|
|
215
|
+
})
|
|
216
|
+
}),
|
|
217
|
+
f > 0 && /* @__PURE__ */ t("button", {
|
|
218
|
+
type: "button",
|
|
219
|
+
onClick: () => a([]),
|
|
220
|
+
className: "mt-4 text-xs text-status-error-text hover:underline",
|
|
221
|
+
children: "Clear all overrides"
|
|
222
|
+
})
|
|
223
|
+
]
|
|
224
|
+
})]
|
|
225
|
+
});
|
|
226
|
+
};
|
|
227
|
+
//#endregion
|
|
228
|
+
export { i as CurrencyPriceOverridesEditor };
|
|
229
|
+
|
|
230
|
+
//# sourceMappingURL=CurrencyPriceOverridesEditor.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CurrencyPriceOverridesEditor.js","names":[],"sources":["../../../../src/billing/shared/components/CurrencyPriceOverridesEditor.tsx"],"sourcesContent":["import { useState, type FC } from 'react';\n\nimport type { CurrencyPriceOverrideInput } from '../types';\n\ninterface CurrencyPriceOverridesEditorProps {\n overrides: CurrencyPriceOverrideInput[];\n onChange: (overrides: CurrencyPriceOverrideInput[]) => void;\n showPerSeatAmount?: boolean;\n}\n\nconst PRICING_CURRENCIES: { code: string; name: string; symbol: string }[] = [\n { code: 'EUR', name: 'Euro', symbol: '€' },\n { code: 'GBP', name: 'British Pound', symbol: '£' },\n { code: 'INR', name: 'Indian Rupee', symbol: '₹' },\n { code: 'AUD', name: 'Australian Dollar', symbol: 'A$' },\n { code: 'CAD', name: 'Canadian Dollar', symbol: 'C$' },\n { code: 'SGD', name: 'Singapore Dollar', symbol: 'S$' },\n { code: 'JPY', name: 'Japanese Yen', symbol: '¥' },\n { code: 'MXN', name: 'Mexican Peso', symbol: 'MX$' },\n { code: 'BRL', name: 'Brazilian Real', symbol: 'R$' },\n { code: 'CHF', name: 'Swiss Franc', symbol: 'Fr' },\n { code: 'CNY', name: 'Chinese Yuan', symbol: '¥' },\n { code: 'HKD', name: 'Hong Kong Dollar', symbol: 'HK$' },\n { code: 'NZD', name: 'New Zealand Dollar', symbol: 'NZ$' },\n { code: 'SEK', name: 'Swedish Krona', symbol: 'kr' },\n { code: 'KRW', name: 'South Korean Won', symbol: '₩' },\n { code: 'NOK', name: 'Norwegian Krone', symbol: 'kr' },\n { code: 'DKK', name: 'Danish Krone', symbol: 'kr' },\n { code: 'PLN', name: 'Polish Złoty', symbol: 'zł' },\n { code: 'THB', name: 'Thai Baht', symbol: '฿' },\n { code: 'MYR', name: 'Malaysian Ringgit', symbol: 'RM' },\n];\n\nexport const CurrencyPriceOverridesEditor: FC<CurrencyPriceOverridesEditorProps> = ({\n overrides,\n onChange,\n showPerSeatAmount = false,\n}) => {\n const [isExpanded, setIsExpanded] = useState(false);\n\n const getOverride = (currency: string): CurrencyPriceOverrideInput | undefined =>\n overrides.find((o) => o.currency === currency);\n\n const handleAmountChange = (currency: string, value: string) => {\n const trimmed = value.trim();\n const existing = overrides.filter((o) => o.currency !== currency);\n\n if (trimmed === '') {\n onChange(existing);\n return;\n }\n\n const amount = parseFloat(trimmed);\n if (isNaN(amount) || amount < 0) return;\n\n const currentOverride = getOverride(currency);\n onChange([\n ...existing,\n {\n currency,\n amount,\n ...(currentOverride?.perSeatAmount !== undefined\n ? { perSeatAmount: currentOverride.perSeatAmount }\n : {}),\n },\n ]);\n };\n\n const handlePerSeatChange = (currency: string, value: string) => {\n const trimmed = value.trim();\n const existing = overrides.filter((o) => o.currency !== currency);\n const currentOverride = getOverride(currency);\n\n if (!currentOverride) return;\n\n if (trimmed === '') {\n onChange([...existing, { currency, amount: currentOverride.amount }]);\n return;\n }\n\n const perSeatAmount = parseFloat(trimmed);\n if (isNaN(perSeatAmount) || perSeatAmount < 0) return;\n\n onChange([...existing, { ...currentOverride, perSeatAmount }]);\n };\n\n const overrideCount = overrides.length;\n\n return (\n <div className=\"border border-border rounded-lg bg-card overflow-hidden\">\n <button\n type=\"button\"\n onClick={() => setIsExpanded((v) => !v)}\n className=\"w-full p-4 border-b border-border bg-muted/30 flex items-center justify-between hover:bg-muted/50 transition-colors\"\n >\n <div className=\"flex items-center gap-2\">\n <h2 className=\"font-semibold text-foreground\">Currency Price Overrides</h2>\n {overrideCount > 0 && (\n <span className=\"px-2 py-0.5 text-xs font-medium bg-primary/10 text-primary rounded-full\">\n {overrideCount} set\n </span>\n )}\n </div>\n <div className=\"flex items-center gap-2 text-sm text-muted-foreground\">\n <span>\n {isExpanded ? 'Hide' : 'Show'} — leave blank to use auto-calculated exchange rates\n </span>\n <svg\n className={`w-4 h-4 transition-transform ${isExpanded ? 'rotate-180' : ''}`}\n fill=\"none\"\n viewBox=\"0 0 24 24\"\n stroke=\"currentColor\"\n >\n <path strokeLinecap=\"round\" strokeLinejoin=\"round\" strokeWidth={2} d=\"M19 9l-7 7-7-7\" />\n </svg>\n </div>\n </button>\n\n {isExpanded && (\n <div className=\"p-4\">\n <p className=\"text-xs text-muted-foreground mb-4\">\n Set a specific price for any currency. Leave a field empty to auto-calculate from the\n USD base price using live exchange rates.\n </p>\n <div className=\"grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 xl:grid-cols-4 gap-3\">\n {PRICING_CURRENCIES.map(({ code, name, symbol }) => {\n const override = getOverride(code);\n return (\n <div key={code} className=\"space-y-1\">\n <label className=\"flex items-center gap-1 text-xs font-medium text-foreground\">\n <span className=\"text-muted-foreground\">{symbol}</span>\n <span>{code}</span>\n <span className=\"text-muted-foreground font-normal truncate\">— {name}</span>\n </label>\n <div className={showPerSeatAmount ? 'flex gap-1' : ''}>\n <input\n type=\"number\"\n step=\"0.01\"\n min=\"0\"\n value={override?.amount ?? ''}\n onChange={(e) => handleAmountChange(code, e.target.value)}\n placeholder=\"auto\"\n className={`px-2 py-1.5 text-sm border border-border rounded-md bg-background text-foreground focus:outline-none focus:ring-1 focus:ring-primary placeholder:text-muted-foreground ${\n showPerSeatAmount ? 'flex-1 min-w-0' : 'w-full'\n } ${override?.amount !== undefined ? 'border-primary/50' : ''}`}\n />\n {showPerSeatAmount && (\n <input\n type=\"number\"\n step=\"0.01\"\n min=\"0\"\n value={override?.perSeatAmount ?? ''}\n onChange={(e) => handlePerSeatChange(code, e.target.value)}\n placeholder=\"/seat\"\n disabled={!override}\n title=\"Per-seat amount (requires flat amount to be set first)\"\n className=\"flex-1 min-w-0 px-2 py-1.5 text-sm border border-border rounded-md bg-background text-foreground focus:outline-none focus:ring-1 focus:ring-primary placeholder:text-muted-foreground disabled:opacity-40\"\n />\n )}\n </div>\n </div>\n );\n })}\n </div>\n {overrideCount > 0 && (\n <button\n type=\"button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MAAK;KACL,eAAe,EAAS,EAAE,CAAC;KAC3B,WAAU;eACX;KAEQ,CAAA;IAEP;KAEJ"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { FC, ReactNode } from 'react';
|
|
2
|
+
|
|
3
|
+
interface EmptyStateProps {
|
|
4
|
+
icon?: ReactNode;
|
|
5
|
+
title: string;
|
|
6
|
+
description?: string;
|
|
7
|
+
action?: ReactNode;
|
|
8
|
+
}
|
|
9
|
+
export declare const EmptyState: FC<EmptyStateProps>;
|
|
10
|
+
export {};
|
|
11
|
+
//# sourceMappingURL=EmptyState.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"EmptyState.d.ts","sourceRoot":"","sources":["../../../../src/billing/shared/components/EmptyState.tsx"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,EAAE,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAE3C,UAAU,eAAe;IACvB,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,MAAM,CAAC,EAAE,SAAS,CAAC;CACpB;AAED,eAAO,MAAM,UAAU,EAAE,EAAE,CAAC,eAAe,CAe1C,CAAC"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { jsx as e, jsxs as t } from "react/jsx-runtime";
|
|
2
|
+
//#region src/billing/shared/components/EmptyState.tsx
|
|
3
|
+
var n = ({ icon: n, title: r, description: i, action: a }) => /* @__PURE__ */ t("div", {
|
|
4
|
+
className: "flex flex-col items-center justify-center py-12 border border-dashed border-border rounded-lg",
|
|
5
|
+
children: [
|
|
6
|
+
n && /* @__PURE__ */ e("div", {
|
|
7
|
+
className: "w-12 h-12 rounded-full bg-muted flex items-center justify-center mb-4",
|
|
8
|
+
children: n
|
|
9
|
+
}),
|
|
10
|
+
/* @__PURE__ */ e("h3", {
|
|
11
|
+
className: "text-lg font-medium text-foreground",
|
|
12
|
+
children: r
|
|
13
|
+
}),
|
|
14
|
+
i && /* @__PURE__ */ e("p", {
|
|
15
|
+
className: "text-sm text-muted-foreground mt-1 text-center max-w-sm",
|
|
16
|
+
children: i
|
|
17
|
+
}),
|
|
18
|
+
a && /* @__PURE__ */ e("div", {
|
|
19
|
+
className: "mt-4",
|
|
20
|
+
children: a
|
|
21
|
+
})
|
|
22
|
+
]
|
|
23
|
+
});
|
|
24
|
+
//#endregion
|
|
25
|
+
export { n as EmptyState };
|
|
26
|
+
|
|
27
|
+
//# sourceMappingURL=EmptyState.js.map
|