@burdenoff/microfe-billing 2026.1101.1 → 2026.1108.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/billing/BillingAdminRoutes.d.ts +1 -2
- package/dist/billing/BillingAdminRoutes.js +11 -12
- package/dist/billing/BillingAdminRoutes.js.map +1 -1
- package/dist/billing/BillingRoot.d.ts +0 -1
- package/dist/billing/BillingRoot.js +10 -9
- package/dist/billing/BillingRoot.js.map +1 -1
- package/dist/billing/BillingUserRoutes.d.ts +1 -2
- package/dist/billing/BillingUserRoutes.js +13 -14
- package/dist/billing/BillingUserRoutes.js.map +1 -1
- package/dist/billing/hooks/useBillingAccountSelection.d.ts +0 -1
- package/dist/billing/hooks/useBillingAccountSelection.js +7 -5
- package/dist/billing/hooks/useBillingAccountSelection.js.map +1 -1
- package/dist/billing/hooks/useBillingEventEmitter.d.ts +0 -1
- package/dist/billing/hooks/useBillingEventEmitter.js +1 -2
- package/dist/billing/hooks/useBillingEventEmitter.js.map +1 -1
- package/dist/billing/hooks/useBillingNavigate.d.ts +0 -1
- package/dist/billing/hooks/useBillingNavigate.js +1 -2
- package/dist/billing/hooks/useBillingNavigate.js.map +1 -1
- package/dist/billing/hooks/useBillingPermissions.d.ts +0 -1
- package/dist/billing/hooks/useBillingPermissions.js +2 -3
- package/dist/billing/hooks/useBillingPermissions.js.map +1 -1
- package/dist/billing/hooks/useDefaultBillingCurrency.d.ts +0 -1
- package/dist/billing/hooks/useDefaultBillingCurrency.js +1 -2
- package/dist/billing/hooks/useDefaultBillingCurrency.js.map +1 -1
- package/dist/billing/hooks/useProducts.d.ts +0 -1
- package/dist/billing/hooks/useProducts.js +1 -2
- package/dist/billing/hooks/useProducts.js.map +1 -1
- package/dist/billing/index.d.ts +0 -1
- package/dist/billing/lib/native-purchases.d.ts +0 -1
- package/dist/billing/lib/native-purchases.js +1 -2
- package/dist/billing/lib/native-purchases.js.map +1 -1
- package/dist/billing/modules/addons/components/FloatingCartDrawer.d.ts +0 -1
- package/dist/billing/modules/addons/components/FloatingCartDrawer.js +4 -5
- package/dist/billing/modules/addons/components/FloatingCartDrawer.js.map +1 -1
- package/dist/billing/modules/addons/hooks/index.d.ts +0 -1
- package/dist/billing/modules/addons/hooks/index.js +3 -2
- package/dist/billing/modules/addons/hooks/useAddonPurchaseEligibility.d.ts +0 -1
- package/dist/billing/modules/addons/hooks/useAddonPurchaseEligibility.js +1 -2
- package/dist/billing/modules/addons/hooks/useAddonPurchaseEligibility.js.map +1 -1
- package/dist/billing/modules/addons/hooks/useAddons.d.ts +0 -1
- package/dist/billing/modules/addons/hooks/useAddons.js +1 -2
- package/dist/billing/modules/addons/hooks/useAddons.js.map +1 -1
- package/dist/billing/modules/addons/index.d.ts +0 -1
- package/dist/billing/modules/addons/index.js +10 -10
- package/dist/billing/modules/addons/pages/AddonBrowseDetailPage.d.ts +0 -1
- package/dist/billing/modules/addons/pages/AddonBrowseDetailPage.js +15 -16
- package/dist/billing/modules/addons/pages/AddonBrowseDetailPage.js.map +1 -1
- package/dist/billing/modules/addons/pages/AddonCreatePage.d.ts +0 -1
- package/dist/billing/modules/addons/pages/AddonCreatePage.js +11 -12
- package/dist/billing/modules/addons/pages/AddonCreatePage.js.map +1 -1
- package/dist/billing/modules/addons/pages/AddonDetailPage.d.ts +0 -1
- package/dist/billing/modules/addons/pages/AddonDetailPage.js +16 -17
- package/dist/billing/modules/addons/pages/AddonDetailPage.js.map +1 -1
- package/dist/billing/modules/addons/pages/AddonEditPage.d.ts +0 -1
- package/dist/billing/modules/addons/pages/AddonEditPage.js +16 -17
- package/dist/billing/modules/addons/pages/AddonEditPage.js.map +1 -1
- package/dist/billing/modules/addons/pages/AddonsBrowsePage.d.ts +0 -1
- package/dist/billing/modules/addons/pages/AddonsBrowsePage.js +111 -106
- package/dist/billing/modules/addons/pages/AddonsBrowsePage.js.map +1 -1
- package/dist/billing/modules/addons/pages/AddonsListPage.d.ts +0 -1
- package/dist/billing/modules/addons/pages/AddonsListPage.js +105 -100
- package/dist/billing/modules/addons/pages/AddonsListPage.js.map +1 -1
- package/dist/billing/modules/addons/pages/index.d.ts +0 -1
- package/dist/billing/modules/addons/pages/index.js +7 -6
- package/dist/billing/modules/addons/store/addonCartStore.d.ts +0 -1
- package/dist/billing/modules/addons/store/addonCartStore.js +2 -7
- package/dist/billing/modules/addons/store/addonCartStore.js.map +1 -1
- package/dist/billing/modules/affiliate/api.d.ts +0 -1
- package/dist/billing/modules/affiliate/api.js +1 -2
- package/dist/billing/modules/affiliate/api.js.map +1 -1
- package/dist/billing/modules/affiliate/index.d.ts +0 -1
- package/dist/billing/modules/affiliate/index.js +1 -2
- package/dist/billing/modules/affiliate/pages/AffiliateDashboardPage.d.ts +0 -1
- package/dist/billing/modules/affiliate/pages/AffiliateDashboardPage.js +29 -28
- package/dist/billing/modules/affiliate/pages/AffiliateDashboardPage.js.map +1 -1
- package/dist/billing/modules/analytics/index.d.ts +0 -1
- package/dist/billing/modules/analytics/index.js +1 -2
- package/dist/billing/modules/analytics/pages/AnalyticsPage.d.ts +0 -1
- package/dist/billing/modules/analytics/pages/AnalyticsPage.js +8 -9
- package/dist/billing/modules/analytics/pages/AnalyticsPage.js.map +1 -1
- package/dist/billing/modules/analytics/pages/index.d.ts +0 -1
- package/dist/billing/modules/analytics/pages/index.js +1 -1
- package/dist/billing/modules/billing/hooks/index.d.ts +0 -1
- package/dist/billing/modules/billing/hooks/index.js +5 -4
- package/dist/billing/modules/billing/hooks/useInvoices.d.ts +0 -1
- package/dist/billing/modules/billing/hooks/useInvoices.js +1 -2
- package/dist/billing/modules/billing/hooks/useInvoices.js.map +1 -1
- package/dist/billing/modules/billing/hooks/useOrderCallbacks.d.ts +0 -1
- package/dist/billing/modules/billing/hooks/useOrderCallbacks.js +1 -2
- package/dist/billing/modules/billing/hooks/useOrderCallbacks.js.map +1 -1
- package/dist/billing/modules/billing/hooks/usePayments.d.ts +0 -1
- package/dist/billing/modules/billing/hooks/useRefunds.d.ts +0 -1
- package/dist/billing/modules/billing/hooks/useRefunds.js +1 -2
- package/dist/billing/modules/billing/hooks/useRefunds.js.map +1 -1
- package/dist/billing/modules/billing/hooks/useTransactions.d.ts +0 -1
- package/dist/billing/modules/billing/hooks/useTransactions.js +30 -31
- package/dist/billing/modules/billing/hooks/useTransactions.js.map +1 -1
- package/dist/billing/modules/billing/index.d.ts +0 -1
- package/dist/billing/modules/billing/index.js +15 -15
- package/dist/billing/modules/billing/pages/BillingWebhookLogsPage.d.ts +0 -1
- package/dist/billing/modules/billing/pages/BillingWebhookLogsPage.js +11 -12
- package/dist/billing/modules/billing/pages/BillingWebhookLogsPage.js.map +1 -1
- package/dist/billing/modules/billing/pages/InvoiceDetailPage.d.ts +0 -1
- package/dist/billing/modules/billing/pages/InvoiceDetailPage.js +53 -59
- package/dist/billing/modules/billing/pages/InvoiceDetailPage.js.map +1 -1
- package/dist/billing/modules/billing/pages/InvoicesListPage.d.ts +0 -1
- package/dist/billing/modules/billing/pages/InvoicesListPage.js +81 -87
- package/dist/billing/modules/billing/pages/InvoicesListPage.js.map +1 -1
- package/dist/billing/modules/billing/pages/OrderCallbackLogsPage.d.ts +0 -1
- package/dist/billing/modules/billing/pages/OrderCallbackLogsPage.js +11 -12
- package/dist/billing/modules/billing/pages/OrderCallbackLogsPage.js.map +1 -1
- package/dist/billing/modules/billing/pages/PaymentMethodsPage.d.ts +0 -1
- package/dist/billing/modules/billing/pages/PaymentMethodsPage.js +51 -54
- package/dist/billing/modules/billing/pages/PaymentMethodsPage.js.map +1 -1
- package/dist/billing/modules/billing/pages/RefundIssueLogsPage.d.ts +0 -1
- package/dist/billing/modules/billing/pages/RefundIssueLogsPage.js +33 -34
- package/dist/billing/modules/billing/pages/RefundIssueLogsPage.js.map +1 -1
- package/dist/billing/modules/billing/pages/RefundsPage.d.ts +0 -1
- package/dist/billing/modules/billing/pages/RefundsPage.js +92 -93
- package/dist/billing/modules/billing/pages/RefundsPage.js.map +1 -1
- package/dist/billing/modules/billing/pages/TransactionsPage.d.ts +0 -1
- package/dist/billing/modules/billing/pages/TransactionsPage.js +38 -39
- package/dist/billing/modules/billing/pages/TransactionsPage.js.map +1 -1
- package/dist/billing/modules/billing/pages/UserRefundsPage.d.ts +0 -1
- package/dist/billing/modules/billing/pages/UserRefundsPage.js +24 -30
- package/dist/billing/modules/billing/pages/UserRefundsPage.js.map +1 -1
- package/dist/billing/modules/billing/pages/index.d.ts +0 -1
- package/dist/billing/modules/billing/pages/index.js +10 -9
- package/dist/billing/modules/checkout/components/AutoPayToggle.d.ts +0 -1
- package/dist/billing/modules/checkout/components/BillingAccountSelector.d.ts +0 -1
- package/dist/billing/modules/checkout/components/BillingAccountSelector.js +1 -2
- package/dist/billing/modules/checkout/components/BillingAccountSelector.js.map +1 -1
- package/dist/billing/modules/checkout/components/CompactAutoPayToggle.d.ts +0 -1
- package/dist/billing/modules/checkout/components/CompleteBillingAccountModal.d.ts +0 -1
- package/dist/billing/modules/checkout/components/CompleteBillingAccountModal.js +1 -2
- package/dist/billing/modules/checkout/components/CompleteBillingAccountModal.js.map +1 -1
- package/dist/billing/modules/checkout/components/CreditsAmountInput.d.ts +0 -1
- package/dist/billing/modules/checkout/components/CreditsAmountInput.js +1 -2
- package/dist/billing/modules/checkout/components/CreditsAmountInput.js.map +1 -1
- package/dist/billing/modules/checkout/components/CreditsPaymentOption.d.ts +0 -1
- package/dist/billing/modules/checkout/components/CurrencySelector.d.ts +0 -1
- package/dist/billing/modules/checkout/components/NativeCheckoutView.d.ts +0 -1
- package/dist/billing/modules/checkout/components/NativeCheckoutView.js +1 -2
- package/dist/billing/modules/checkout/components/NativeCheckoutView.js.map +1 -1
- package/dist/billing/modules/checkout/components/OrderSummary.d.ts +0 -1
- package/dist/billing/modules/checkout/components/OrderSummary.js +35 -32
- package/dist/billing/modules/checkout/components/OrderSummary.js.map +1 -1
- package/dist/billing/modules/checkout/components/PaymentProviderSelector.d.ts +0 -1
- package/dist/billing/modules/checkout/components/PromoCodeInput.d.ts +0 -1
- package/dist/billing/modules/checkout/components/PromoCodeInput.js +1 -2
- package/dist/billing/modules/checkout/components/PromoCodeInput.js.map +1 -1
- package/dist/billing/modules/checkout/components/RazorpayPaymentButton.d.ts +0 -1
- package/dist/billing/modules/checkout/components/RazorpayPaymentButton.js +1 -2
- package/dist/billing/modules/checkout/components/RazorpayPaymentButton.js.map +1 -1
- package/dist/billing/modules/checkout/components/SavedCardSelector.d.ts +0 -1
- package/dist/billing/modules/checkout/components/SimpleAutoPayToggle.d.ts +0 -1
- package/dist/billing/modules/checkout/components/SimpleAutoPayToggle.js +1 -2
- package/dist/billing/modules/checkout/components/SimpleAutoPayToggle.js.map +1 -1
- package/dist/billing/modules/checkout/components/StoreShippingSection.d.ts +0 -1
- package/dist/billing/modules/checkout/components/StoreShippingSection.js +5 -3
- package/dist/billing/modules/checkout/components/StoreShippingSection.js.map +1 -1
- package/dist/billing/modules/checkout/components/StripePaymentForm.d.ts +0 -1
- package/dist/billing/modules/checkout/components/StripePaymentForm.js +35 -41
- package/dist/billing/modules/checkout/components/StripePaymentForm.js.map +1 -1
- package/dist/billing/modules/checkout/components/SubscriptionSelector.d.ts +0 -1
- package/dist/billing/modules/checkout/components/SubscriptionSelector.js +1 -2
- package/dist/billing/modules/checkout/components/SubscriptionSelector.js.map +1 -1
- package/dist/billing/modules/checkout/components/UnifiedPaymentMethodSelector.d.ts +0 -1
- package/dist/billing/modules/checkout/components/UnifiedPaymentMethodSelector.js +1 -2
- package/dist/billing/modules/checkout/components/UnifiedPaymentMethodSelector.js.map +1 -1
- package/dist/billing/modules/checkout/components/WebCheckoutRedirectView.d.ts +0 -1
- package/dist/billing/modules/checkout/components/WebCheckoutRedirectView.js +5 -6
- package/dist/billing/modules/checkout/components/WebCheckoutRedirectView.js.map +1 -1
- package/dist/billing/modules/checkout/components/WorkspaceQuotaAssignmentModal.d.ts +0 -1
- package/dist/billing/modules/checkout/components/WorkspaceQuotaAssignmentModal.js +7 -8
- package/dist/billing/modules/checkout/components/WorkspaceQuotaAssignmentModal.js.map +1 -1
- package/dist/billing/modules/checkout/components/index.d.ts +0 -1
- package/dist/billing/modules/checkout/components/index.js +12 -11
- package/dist/billing/modules/checkout/hooks/index.d.ts +0 -1
- package/dist/billing/modules/checkout/hooks/index.js +5 -4
- package/dist/billing/modules/checkout/hooks/useCheckout.d.ts +0 -1
- package/dist/billing/modules/checkout/hooks/useCheckout.js +182 -195
- package/dist/billing/modules/checkout/hooks/useCheckout.js.map +1 -1
- package/dist/billing/modules/checkout/hooks/useNativeCheckout.d.ts +0 -1
- package/dist/billing/modules/checkout/hooks/useNativeCheckout.js +33 -32
- package/dist/billing/modules/checkout/hooks/useNativeCheckout.js.map +1 -1
- package/dist/billing/modules/checkout/hooks/usePaymentProviders.d.ts +0 -1
- package/dist/billing/modules/checkout/hooks/usePaymentProviders.js +1 -2
- package/dist/billing/modules/checkout/hooks/usePaymentProviders.js.map +1 -1
- package/dist/billing/modules/checkout/hooks/usePaymentStatusPolling.d.ts +0 -1
- package/dist/billing/modules/checkout/hooks/usePaymentStatusPolling.js +1 -2
- package/dist/billing/modules/checkout/hooks/usePaymentStatusPolling.js.map +1 -1
- package/dist/billing/modules/checkout/hooks/useStoreShipping.d.ts +4 -8
- package/dist/billing/modules/checkout/hooks/useStoreShipping.js +1 -2
- package/dist/billing/modules/checkout/hooks/useStoreShipping.js.map +1 -1
- package/dist/billing/modules/checkout/index.d.ts +0 -1
- package/dist/billing/modules/checkout/index.js +19 -19
- package/dist/billing/modules/checkout/pages/CheckoutPage.d.ts +0 -1
- package/dist/billing/modules/checkout/pages/CheckoutPage.js +730 -732
- package/dist/billing/modules/checkout/pages/CheckoutPage.js.map +1 -1
- package/dist/billing/modules/checkout/pages/index.d.ts +0 -1
- package/dist/billing/modules/checkout/pages/index.js +1 -1
- package/dist/billing/modules/checkout/types/index.d.ts +0 -1
- package/dist/billing/modules/checkout/utils/storeOrder.d.ts +0 -1
- package/dist/billing/modules/checkout/utils/storeOrder.js +0 -1
- package/dist/billing/modules/checkout/utils/storeOrder.js.map +1 -1
- package/dist/billing/modules/coupons/index.d.ts +0 -1
- package/dist/billing/modules/coupons/pages/CouponDetailPage.d.ts +0 -1
- package/dist/billing/modules/coupons/pages/CouponDetailPage.js +5 -6
- package/dist/billing/modules/coupons/pages/CouponDetailPage.js.map +1 -1
- package/dist/billing/modules/coupons/pages/CouponsListPage.d.ts +0 -1
- package/dist/billing/modules/coupons/pages/CouponsListPage.js +15 -13
- package/dist/billing/modules/coupons/pages/CouponsListPage.js.map +1 -1
- package/dist/billing/modules/coupons/pages/CreateCouponPage.d.ts +0 -1
- package/dist/billing/modules/coupons/pages/CreateCouponPage.js +12 -10
- package/dist/billing/modules/coupons/pages/CreateCouponPage.js.map +1 -1
- package/dist/billing/modules/coupons/pages/EditCouponPage.d.ts +0 -1
- package/dist/billing/modules/coupons/pages/EditCouponPage.js +7 -11
- package/dist/billing/modules/coupons/pages/EditCouponPage.js.map +1 -1
- package/dist/billing/modules/coupons/pages/index.d.ts +0 -1
- package/dist/billing/modules/coupons/pages/index.js +5 -4
- package/dist/billing/modules/credits/hooks/index.d.ts +0 -1
- package/dist/billing/modules/credits/hooks/useCredits.d.ts +0 -1
- package/dist/billing/modules/credits/hooks/useCredits.js +20 -21
- package/dist/billing/modules/credits/hooks/useCredits.js.map +1 -1
- package/dist/billing/modules/credits/index.d.ts +0 -1
- package/dist/billing/modules/credits/pages/AdminCreditsPage.d.ts +0 -1
- package/dist/billing/modules/credits/pages/AdminCreditsPage.js +19 -24
- package/dist/billing/modules/credits/pages/AdminCreditsPage.js.map +1 -1
- package/dist/billing/modules/credits/pages/CreditTransactionsPage.d.ts +0 -1
- package/dist/billing/modules/credits/pages/CreditTransactionsPage.js +26 -27
- package/dist/billing/modules/credits/pages/CreditTransactionsPage.js.map +1 -1
- package/dist/billing/modules/credits/pages/CreditWithdrawalPage.d.ts +0 -1
- package/dist/billing/modules/credits/pages/CreditWithdrawalPage.js +54 -52
- package/dist/billing/modules/credits/pages/CreditWithdrawalPage.js.map +1 -1
- package/dist/billing/modules/credits/pages/CreditsPage.d.ts +0 -1
- package/dist/billing/modules/credits/pages/CreditsPage.js +37 -38
- package/dist/billing/modules/credits/pages/CreditsPage.js.map +1 -1
- package/dist/billing/modules/credits/pages/index.d.ts +0 -1
- package/dist/billing/modules/credits/pages/index.js +5 -4
- package/dist/billing/modules/dashboard/components/ActiveSubscriptionCard.d.ts +0 -1
- package/dist/billing/modules/dashboard/components/ActiveSubscriptionCard.js +2 -3
- package/dist/billing/modules/dashboard/components/ActiveSubscriptionCard.js.map +1 -1
- package/dist/billing/modules/dashboard/components/AddPaymentMethodModal.d.ts +0 -1
- package/dist/billing/modules/dashboard/components/AddPaymentMethodModal.js +35 -43
- package/dist/billing/modules/dashboard/components/AddPaymentMethodModal.js.map +1 -1
- package/dist/billing/modules/dashboard/components/BillingAccountCard.d.ts +0 -1
- package/dist/billing/modules/dashboard/components/BillingAccountCard.js +1 -2
- package/dist/billing/modules/dashboard/components/BillingAccountCard.js.map +1 -1
- package/dist/billing/modules/dashboard/components/CreateBillingAccountModal.d.ts +0 -1
- package/dist/billing/modules/dashboard/components/CreateBillingAccountModal.js +1 -2
- package/dist/billing/modules/dashboard/components/CreateBillingAccountModal.js.map +1 -1
- package/dist/billing/modules/dashboard/components/PaymentMethodsSection.d.ts +0 -1
- package/dist/billing/modules/dashboard/components/PaymentMethodsSection.js +2 -5
- package/dist/billing/modules/dashboard/components/PaymentMethodsSection.js.map +1 -1
- package/dist/billing/modules/dashboard/components/RecommendedAddonsSection.d.ts +0 -1
- package/dist/billing/modules/dashboard/components/RecommendedAddonsSection.js +1 -2
- package/dist/billing/modules/dashboard/components/RecommendedAddonsSection.js.map +1 -1
- package/dist/billing/modules/dashboard/components/index.d.ts +0 -1
- package/dist/billing/modules/dashboard/components/index.js +7 -6
- package/dist/billing/modules/dashboard/hooks/index.d.ts +0 -1
- package/dist/billing/modules/dashboard/hooks/index.js +3 -2
- package/dist/billing/modules/dashboard/hooks/useBillingOverviewData.d.ts +0 -1
- package/dist/billing/modules/dashboard/hooks/useBillingOverviewData.js +2 -3
- package/dist/billing/modules/dashboard/hooks/useBillingOverviewData.js.map +1 -1
- package/dist/billing/modules/dashboard/hooks/useDashboard.d.ts +0 -1
- package/dist/billing/modules/dashboard/hooks/useDashboard.js +2 -3
- package/dist/billing/modules/dashboard/hooks/useDashboard.js.map +1 -1
- package/dist/billing/modules/dashboard/index.d.ts +0 -1
- package/dist/billing/modules/dashboard/index.js +11 -10
- package/dist/billing/modules/dashboard/pages/OverviewPage.d.ts +0 -1
- package/dist/billing/modules/dashboard/pages/OverviewPage.js +266 -264
- package/dist/billing/modules/dashboard/pages/OverviewPage.js.map +1 -1
- package/dist/billing/modules/dashboard/pages/index.d.ts +0 -1
- package/dist/billing/modules/dashboard/pages/index.js +1 -1
- package/dist/billing/modules/discounts/index.d.ts +0 -1
- package/dist/billing/modules/discounts/index.js +1 -2
- package/dist/billing/modules/discounts/pages/DiscountsListPage.d.ts +0 -1
- package/dist/billing/modules/discounts/pages/DiscountsListPage.js +169 -176
- package/dist/billing/modules/discounts/pages/DiscountsListPage.js.map +1 -1
- package/dist/billing/modules/discounts/pages/index.d.ts +0 -1
- package/dist/billing/modules/discounts/pages/index.js +1 -1
- package/dist/billing/modules/earnings/api.d.ts +1 -2
- package/dist/billing/modules/earnings/api.js +67 -68
- package/dist/billing/modules/earnings/api.js.map +1 -1
- package/dist/billing/modules/earnings/index.d.ts +0 -1
- package/dist/billing/modules/earnings/pages/DeveloperRevenueAdminPage.d.ts +0 -1
- package/dist/billing/modules/earnings/pages/DeveloperRevenueAdminPage.js +17 -17
- package/dist/billing/modules/earnings/pages/DeveloperRevenueAdminPage.js.map +1 -1
- package/dist/billing/modules/earnings/pages/DeveloperRevenueOrgDetailPage.d.ts +0 -1
- package/dist/billing/modules/earnings/pages/DeveloperRevenueOrgDetailPage.js +188 -189
- package/dist/billing/modules/earnings/pages/DeveloperRevenueOrgDetailPage.js.map +1 -1
- package/dist/billing/modules/earnings/pages/EarningsPage.d.ts +0 -1
- package/dist/billing/modules/earnings/pages/EarningsPage.js +111 -111
- package/dist/billing/modules/earnings/pages/EarningsPage.js.map +1 -1
- package/dist/billing/modules/earnings/pages/PayoutAdminPage.d.ts +0 -1
- package/dist/billing/modules/earnings/pages/PayoutAdminPage.js +29 -30
- package/dist/billing/modules/earnings/pages/PayoutAdminPage.js.map +1 -1
- package/dist/billing/modules/earnings/pages/PayoutsPage.d.ts +0 -1
- package/dist/billing/modules/earnings/pages/PayoutsPage.js +203 -166
- package/dist/billing/modules/earnings/pages/PayoutsPage.js.map +1 -1
- package/dist/billing/modules/earnings/payoutAccountStatus.d.ts +27 -0
- package/dist/billing/modules/earnings/payoutAccountStatus.js +46 -0
- package/dist/billing/modules/earnings/payoutAccountStatus.js.map +1 -0
- package/dist/billing/modules/plans/constants/enterprise.d.ts +0 -1
- package/dist/billing/modules/plans/constants/enterprise.js +1 -2
- package/dist/billing/modules/plans/constants/enterprise.js.map +1 -1
- package/dist/billing/modules/plans/constants/featuredQuotas.d.ts +0 -1
- package/dist/billing/modules/plans/constants/featuredQuotas.js +1 -2
- package/dist/billing/modules/plans/constants/featuredQuotas.js.map +1 -1
- package/dist/billing/modules/plans/hooks/index.d.ts +0 -1
- package/dist/billing/modules/plans/hooks/index.js +3 -2
- package/dist/billing/modules/plans/hooks/usePlans.d.ts +0 -1
- package/dist/billing/modules/plans/hooks/usePlans.js +1 -2
- package/dist/billing/modules/plans/hooks/usePlans.js.map +1 -1
- package/dist/billing/modules/plans/hooks/useQuotas.d.ts +0 -1
- package/dist/billing/modules/plans/hooks/useQuotas.js +1 -2
- package/dist/billing/modules/plans/hooks/useQuotas.js.map +1 -1
- package/dist/billing/modules/plans/index.d.ts +0 -1
- package/dist/billing/modules/plans/index.js +11 -11
- package/dist/billing/modules/plans/pages/PlanAssignFreePage.d.ts +0 -1
- package/dist/billing/modules/plans/pages/PlanAssignFreePage.js +12 -15
- package/dist/billing/modules/plans/pages/PlanAssignFreePage.js.map +1 -1
- package/dist/billing/modules/plans/pages/PlanBrowseDetailPage.d.ts +0 -1
- package/dist/billing/modules/plans/pages/PlanBrowseDetailPage.js +38 -39
- package/dist/billing/modules/plans/pages/PlanBrowseDetailPage.js.map +1 -1
- package/dist/billing/modules/plans/pages/PlanCreatePage.d.ts +0 -1
- package/dist/billing/modules/plans/pages/PlanCreatePage.js +10 -11
- package/dist/billing/modules/plans/pages/PlanCreatePage.js.map +1 -1
- package/dist/billing/modules/plans/pages/PlanDetailPage.d.ts +0 -1
- package/dist/billing/modules/plans/pages/PlanDetailPage.js +40 -41
- package/dist/billing/modules/plans/pages/PlanDetailPage.js.map +1 -1
- package/dist/billing/modules/plans/pages/PlanEditPage.d.ts +0 -1
- package/dist/billing/modules/plans/pages/PlanEditPage.js +15 -16
- package/dist/billing/modules/plans/pages/PlanEditPage.js.map +1 -1
- package/dist/billing/modules/plans/pages/PlansBrowsePage.d.ts +0 -1
- package/dist/billing/modules/plans/pages/PlansBrowsePage.js +18 -19
- package/dist/billing/modules/plans/pages/PlansBrowsePage.js.map +1 -1
- package/dist/billing/modules/plans/pages/PlansListPage.d.ts +0 -1
- package/dist/billing/modules/plans/pages/PlansListPage.js +100 -101
- package/dist/billing/modules/plans/pages/PlansListPage.js.map +1 -1
- package/dist/billing/modules/plans/pages/index.d.ts +0 -1
- package/dist/billing/modules/plans/pages/index.js +8 -7
- package/dist/billing/modules/plans/utils/currencyPriceOverrides.d.ts +0 -1
- package/dist/billing/modules/plans/utils/currencyPriceOverrides.js +1 -2
- package/dist/billing/modules/plans/utils/currencyPriceOverrides.js.map +1 -1
- package/dist/billing/modules/plans/utils/planSelector.d.ts +0 -1
- package/dist/billing/modules/plans/utils/planSelector.js +1 -2
- package/dist/billing/modules/plans/utils/planSelector.js.map +1 -1
- package/dist/billing/modules/promotions/index.d.ts +0 -1
- package/dist/billing/modules/promotions/pages/CreatePromotionPage.d.ts +0 -1
- package/dist/billing/modules/promotions/pages/CreatePromotionPage.js +5 -6
- package/dist/billing/modules/promotions/pages/CreatePromotionPage.js.map +1 -1
- package/dist/billing/modules/promotions/pages/PromotionsListPage.d.ts +0 -1
- package/dist/billing/modules/promotions/pages/PromotionsListPage.js +5 -6
- package/dist/billing/modules/promotions/pages/PromotionsListPage.js.map +1 -1
- package/dist/billing/modules/promotions/pages/index.d.ts +0 -1
- package/dist/billing/modules/promotions/pages/index.js +3 -2
- package/dist/billing/modules/quota/hooks/index.d.ts +0 -1
- package/dist/billing/modules/quota/hooks/index.js +1 -1
- package/dist/billing/modules/quota/hooks/useQuota.d.ts +0 -1
- package/dist/billing/modules/quota/hooks/useQuotaTemplates.d.ts +0 -1
- package/dist/billing/modules/quota/hooks/useQuotaTemplates.js +1 -2
- package/dist/billing/modules/quota/hooks/useQuotaTemplates.js.map +1 -1
- package/dist/billing/modules/quota/index.d.ts +0 -1
- package/dist/billing/modules/quota/index.js +8 -8
- package/dist/billing/modules/quota/pages/QuotaAssignFreePage.d.ts +0 -1
- package/dist/billing/modules/quota/pages/QuotaAssignFreePage.js +12 -15
- package/dist/billing/modules/quota/pages/QuotaAssignFreePage.js.map +1 -1
- package/dist/billing/modules/quota/pages/QuotaPage.d.ts +0 -1
- package/dist/billing/modules/quota/pages/QuotaPage.js +3 -3
- package/dist/billing/modules/quota/pages/QuotaTemplateCreatePage.d.ts +0 -1
- package/dist/billing/modules/quota/pages/QuotaTemplateCreatePage.js +13 -14
- package/dist/billing/modules/quota/pages/QuotaTemplateCreatePage.js.map +1 -1
- package/dist/billing/modules/quota/pages/QuotaTemplateDetailPage.d.ts +0 -1
- package/dist/billing/modules/quota/pages/QuotaTemplateDetailPage.js +9 -10
- package/dist/billing/modules/quota/pages/QuotaTemplateDetailPage.js.map +1 -1
- package/dist/billing/modules/quota/pages/QuotaTemplateEditPage.d.ts +0 -1
- package/dist/billing/modules/quota/pages/QuotaTemplateEditPage.js +12 -13
- package/dist/billing/modules/quota/pages/QuotaTemplateEditPage.js.map +1 -1
- package/dist/billing/modules/quota/pages/QuotaTemplatesListPage.d.ts +0 -1
- package/dist/billing/modules/quota/pages/QuotaTemplatesListPage.js +16 -17
- package/dist/billing/modules/quota/pages/QuotaTemplatesListPage.js.map +1 -1
- package/dist/billing/modules/quota/pages/index.d.ts +0 -1
- package/dist/billing/modules/quota/pages/index.js +6 -5
- package/dist/billing/modules/quota/utils/quotaSelector.d.ts +0 -1
- package/dist/billing/modules/quota/utils/quotaSelector.js +1 -2
- package/dist/billing/modules/quota/utils/quotaSelector.js.map +1 -1
- package/dist/billing/modules/settings/index.d.ts +0 -1
- package/dist/billing/modules/settings/pages/SettingsPage.d.ts +0 -1
- package/dist/billing/modules/settings/pages/SettingsPage.js +12 -13
- package/dist/billing/modules/settings/pages/SettingsPage.js.map +1 -1
- package/dist/billing/modules/settings/pages/TeamPermissionsPage.d.ts +0 -1
- package/dist/billing/modules/settings/pages/TeamPermissionsPage.js +32 -32
- package/dist/billing/modules/settings/pages/TeamPermissionsPage.js.map +1 -1
- package/dist/billing/modules/settings/pages/index.d.ts +0 -1
- package/dist/billing/modules/settings/pages/index.js +3 -2
- package/dist/billing/modules/store/graphql/index.d.ts +0 -1
- package/dist/billing/modules/store/index.d.ts +0 -1
- package/dist/billing/modules/store/index.js +1 -2
- package/dist/billing/modules/store/pages/StoreCheckoutPage.d.ts +0 -1
- package/dist/billing/modules/store/pages/StoreCheckoutPage.js +1 -2
- package/dist/billing/modules/store/pages/StoreCheckoutPage.js.map +1 -1
- package/dist/billing/modules/subscriptions/components/ManageSeatsModal.d.ts +0 -1
- package/dist/billing/modules/subscriptions/components/ManageSeatsModal.js +9 -11
- package/dist/billing/modules/subscriptions/components/ManageSeatsModal.js.map +1 -1
- package/dist/billing/modules/subscriptions/hooks/index.d.ts +0 -1
- package/dist/billing/modules/subscriptions/hooks/index.js +1 -1
- package/dist/billing/modules/subscriptions/hooks/useSubscriptions.d.ts +0 -1
- package/dist/billing/modules/subscriptions/hooks/useSubscriptions.js +1 -2
- package/dist/billing/modules/subscriptions/hooks/useSubscriptions.js.map +1 -1
- package/dist/billing/modules/subscriptions/index.d.ts +0 -1
- package/dist/billing/modules/subscriptions/index.js +6 -6
- package/dist/billing/modules/subscriptions/pages/SubscriptionDetailPage.d.ts +0 -1
- package/dist/billing/modules/subscriptions/pages/SubscriptionDetailPage.js +311 -312
- package/dist/billing/modules/subscriptions/pages/SubscriptionDetailPage.js.map +1 -1
- package/dist/billing/modules/subscriptions/pages/SubscriptionsListPage.d.ts +0 -1
- package/dist/billing/modules/subscriptions/pages/SubscriptionsListPage.js +61 -62
- package/dist/billing/modules/subscriptions/pages/SubscriptionsListPage.js.map +1 -1
- package/dist/billing/modules/subscriptions/pages/UpgradeSubscriptionPage.d.ts +0 -1
- package/dist/billing/modules/subscriptions/pages/UpgradeSubscriptionPage.js +30 -31
- package/dist/billing/modules/subscriptions/pages/UpgradeSubscriptionPage.js.map +1 -1
- package/dist/billing/modules/subscriptions/pages/index.d.ts +0 -1
- package/dist/billing/modules/subscriptions/pages/index.js +4 -3
- package/dist/billing/modules/usage/components/WorkspaceAiSpendPanel.d.ts +0 -1
- package/dist/billing/modules/usage/components/WorkspaceAiSpendPanel.js +17 -18
- package/dist/billing/modules/usage/components/WorkspaceAiSpendPanel.js.map +1 -1
- package/dist/billing/modules/usage/hooks/index.d.ts +0 -1
- package/dist/billing/modules/usage/hooks/useUsage.d.ts +0 -1
- package/dist/billing/modules/usage/hooks/useUsage.js +72 -73
- package/dist/billing/modules/usage/hooks/useUsage.js.map +1 -1
- package/dist/billing/modules/usage/hooks/useWorkspaceAiSpend.d.ts +0 -1
- package/dist/billing/modules/usage/hooks/useWorkspaceAiSpend.js +12 -13
- package/dist/billing/modules/usage/hooks/useWorkspaceAiSpend.js.map +1 -1
- package/dist/billing/modules/usage/index.d.ts +0 -1
- package/dist/billing/modules/usage/index.js +1 -2
- package/dist/billing/modules/usage/pages/UsagePage.d.ts +0 -1
- package/dist/billing/modules/usage/pages/UsagePage.js +229 -227
- package/dist/billing/modules/usage/pages/UsagePage.js.map +1 -1
- package/dist/billing/modules/usage/pages/index.d.ts +0 -1
- package/dist/billing/modules/usage/pages/index.js +1 -1
- package/dist/billing/modules/usage/utils/aiSpend.d.ts +0 -1
- package/dist/billing/modules/usage/utils/aiSpend.js +2 -3
- package/dist/billing/modules/usage/utils/aiSpend.js.map +1 -1
- package/dist/billing/providers/BillingProvider.d.ts +0 -1
- package/dist/billing/providers/BillingProvider.js +3 -4
- package/dist/billing/providers/BillingProvider.js.map +1 -1
- package/dist/billing/shared/components/AccessDenied.d.ts +0 -1
- package/dist/billing/shared/components/AccessDenied.js +1 -2
- package/dist/billing/shared/components/AccessDenied.js.map +1 -1
- package/dist/billing/shared/components/ActorIdentity.d.ts +0 -1
- package/dist/billing/shared/components/ActorIdentity.js +2 -3
- package/dist/billing/shared/components/ActorIdentity.js.map +1 -1
- package/dist/billing/shared/components/CurrencyPriceOverridesEditor.d.ts +0 -1
- package/dist/billing/shared/components/CurrencyPriceOverridesEditor.js +1 -2
- package/dist/billing/shared/components/CurrencyPriceOverridesEditor.js.map +1 -1
- package/dist/billing/shared/components/EmptyState.d.ts +0 -1
- package/dist/billing/shared/components/EmptyState.js +1 -2
- package/dist/billing/shared/components/EmptyState.js.map +1 -1
- package/dist/billing/shared/components/GeoPricingOverridesEditor.d.ts +0 -1
- package/dist/billing/shared/components/PageHeader.d.ts +0 -1
- package/dist/billing/shared/components/PageHeader.js +1 -2
- package/dist/billing/shared/components/PageHeader.js.map +1 -1
- package/dist/billing/shared/components/PushPermissionNudge.d.ts +0 -1
- package/dist/billing/shared/components/PushPermissionNudge.js +2 -3
- package/dist/billing/shared/components/PushPermissionNudge.js.map +1 -1
- package/dist/billing/shared/components/ServerError.d.ts +0 -1
- package/dist/billing/shared/components/ServerError.js +1 -2
- package/dist/billing/shared/components/ServerError.js.map +1 -1
- package/dist/billing/shared/components/StatCard.d.ts +0 -1
- package/dist/billing/shared/components/StatCard.js +1 -2
- package/dist/billing/shared/components/StatCard.js.map +1 -1
- package/dist/billing/shared/components/index.d.ts +0 -1
- package/dist/billing/shared/components/index.js +8 -7
- package/dist/billing/shared/hooks/index.d.ts +0 -1
- package/dist/billing/shared/hooks/index.js +1 -1
- package/dist/billing/shared/hooks/useActorProfiles.d.ts +0 -1
- package/dist/billing/shared/hooks/useActorProfiles.js +4 -8
- package/dist/billing/shared/hooks/useActorProfiles.js.map +1 -1
- package/dist/billing/shared/hooks/useTr.d.ts +0 -1
- package/dist/billing/shared/hooks/useTr.js +1 -2
- package/dist/billing/shared/hooks/useTr.js.map +1 -1
- package/dist/billing/shared/index.d.ts +0 -1
- package/dist/billing/shared/types/graphql.d.ts +0 -1
- package/dist/billing/shared/types/graphql.js +1 -2
- package/dist/billing/shared/types/graphql.js.map +1 -1
- package/dist/billing/shared/types/index.d.ts +0 -1
- package/dist/billing/shared/ui/Card.d.ts +1 -2
- package/dist/billing/shared/ui/Card.js +1 -2
- package/dist/billing/shared/ui/Card.js.map +1 -1
- package/dist/billing/shared/ui/MetricCard.d.ts +1 -2
- package/dist/billing/shared/ui/MetricCard.js +1 -2
- package/dist/billing/shared/ui/MetricCard.js.map +1 -1
- package/dist/billing/shared/ui/ProgressBar.d.ts +1 -2
- package/dist/billing/shared/ui/ProgressBar.js +1 -2
- package/dist/billing/shared/ui/ProgressBar.js.map +1 -1
- package/dist/billing/shared/ui/SectionHeader.d.ts +1 -2
- package/dist/billing/shared/ui/StatusPill.d.ts +1 -2
- package/dist/billing/shared/ui/StatusPill.js +1 -2
- package/dist/billing/shared/ui/StatusPill.js.map +1 -1
- package/dist/billing/shared/ui/index.d.ts +0 -1
- package/dist/billing/shared/ui/index.js +5 -4
- package/dist/billing/shared/utils/directActivityGraphql.d.ts +0 -1
- package/dist/billing/shared/utils/directBillingGraphql.d.ts +0 -1
- package/dist/billing/shared/utils/directBillingGraphql.js +1 -2
- package/dist/billing/shared/utils/directBillingGraphql.js.map +1 -1
- package/dist/billing/shared/utils/error.d.ts +0 -1
- package/dist/billing/shared/utils/error.js +1 -2
- package/dist/billing/shared/utils/error.js.map +1 -1
- package/dist/billing/shared/utils/format.d.ts +0 -1
- package/dist/billing/shared/utils/format.js +1 -2
- package/dist/billing/shared/utils/format.js.map +1 -1
- package/dist/billing/shared/utils/gatewayGraphql.d.ts +0 -1
- package/dist/billing/shared/utils/gatewayGraphql.js +2 -3
- package/dist/billing/shared/utils/gatewayGraphql.js.map +1 -1
- package/dist/billing/shared/utils/index.d.ts +0 -1
- package/dist/billing/shared/utils/index.js +9 -8
- package/dist/billing/shared/utils/navigation.d.ts +0 -1
- package/dist/billing/shared/utils/navigation.js +1 -2
- package/dist/billing/shared/utils/navigation.js.map +1 -1
- package/dist/billing/shared/utils/paymentTheme.d.ts +0 -1
- package/dist/billing/shared/utils/paymentTheme.js +2 -3
- package/dist/billing/shared/utils/paymentTheme.js.map +1 -1
- package/dist/billing/shared/utils/planFeatureQuantity.d.ts +0 -1
- package/dist/billing/shared/utils/planFeatureQuantity.js +2 -3
- package/dist/billing/shared/utils/planFeatureQuantity.js.map +1 -1
- package/dist/billing/shared/utils/status.d.ts +0 -1
- package/dist/billing/shared/utils/status.js +24 -25
- package/dist/billing/shared/utils/status.js.map +1 -1
- package/dist/billing/shared/utils/tokens.d.ts +0 -1
- package/dist/billing/shared/utils/tokens.js +1 -2
- package/dist/billing/shared/utils/tokens.js.map +1 -1
- package/dist/billing/translations/en.d.ts +0 -1
- package/dist/billing/types/index.d.ts +0 -1
- package/dist/dev/main.d.ts +0 -1
- package/dist/generated/global-operations.d.ts +3253 -3206
- package/dist/generated/global-operations.js +446 -422
- package/dist/generated/global-operations.js.map +1 -1
- package/dist/generated/global-types.d.ts +2 -22
- package/dist/generated/global-types.js +1 -2
- package/dist/generated/global-types.js.map +1 -1
- package/dist/generated/wspace-operations.d.ts +76 -47
- package/dist/generated/wspace-operations.js +2 -3
- package/dist/generated/wspace-operations.js.map +1 -1
- package/dist/generated/wspace-types.d.ts +4 -24
- package/dist/index.d.ts +0 -1
- package/dist/index.js +1 -2
- package/dist/node_modules/@capacitor/core/dist/index.js +12 -14
- package/dist/node_modules/@capacitor/core/dist/index.js.map +1 -1
- package/dist/node_modules/sonner/dist/index.js +75 -69
- package/dist/node_modules/sonner/dist/index.js.map +1 -1
- package/dist/utils/nativeBridge.d.ts +0 -1
- package/dist/utils/nativeBridge.js +1 -2
- package/package.json +65 -54
- package/dist/billing/BillingAdminRoutes.d.ts.map +0 -1
- package/dist/billing/BillingRoot.d.ts.map +0 -1
- package/dist/billing/BillingUserRoutes.d.ts.map +0 -1
- package/dist/billing/hooks/useBillingAccountSelection.d.ts.map +0 -1
- package/dist/billing/hooks/useBillingEventEmitter.d.ts.map +0 -1
- package/dist/billing/hooks/useBillingNavigate.d.ts.map +0 -1
- package/dist/billing/hooks/useBillingPermissions.d.ts.map +0 -1
- package/dist/billing/hooks/useDefaultBillingCurrency.d.ts.map +0 -1
- package/dist/billing/hooks/useProducts.d.ts.map +0 -1
- package/dist/billing/index.d.ts.map +0 -1
- package/dist/billing/lib/native-purchases.d.ts.map +0 -1
- package/dist/billing/modules/addons/components/FloatingCartDrawer.d.ts.map +0 -1
- package/dist/billing/modules/addons/hooks/index.d.ts.map +0 -1
- package/dist/billing/modules/addons/hooks/useAddonPurchaseEligibility.d.ts.map +0 -1
- package/dist/billing/modules/addons/hooks/useAddons.d.ts.map +0 -1
- package/dist/billing/modules/addons/index.d.ts.map +0 -1
- package/dist/billing/modules/addons/pages/AddonBrowseDetailPage.d.ts.map +0 -1
- package/dist/billing/modules/addons/pages/AddonCreatePage.d.ts.map +0 -1
- package/dist/billing/modules/addons/pages/AddonDetailPage.d.ts.map +0 -1
- package/dist/billing/modules/addons/pages/AddonEditPage.d.ts.map +0 -1
- package/dist/billing/modules/addons/pages/AddonsBrowsePage.d.ts.map +0 -1
- package/dist/billing/modules/addons/pages/AddonsListPage.d.ts.map +0 -1
- package/dist/billing/modules/addons/pages/index.d.ts.map +0 -1
- package/dist/billing/modules/addons/store/addonCartStore.d.ts.map +0 -1
- package/dist/billing/modules/affiliate/api.d.ts.map +0 -1
- package/dist/billing/modules/affiliate/index.d.ts.map +0 -1
- package/dist/billing/modules/affiliate/pages/AffiliateDashboardPage.d.ts.map +0 -1
- package/dist/billing/modules/analytics/index.d.ts.map +0 -1
- package/dist/billing/modules/analytics/pages/AnalyticsPage.d.ts.map +0 -1
- package/dist/billing/modules/analytics/pages/index.d.ts.map +0 -1
- package/dist/billing/modules/billing/hooks/index.d.ts.map +0 -1
- package/dist/billing/modules/billing/hooks/useInvoices.d.ts.map +0 -1
- package/dist/billing/modules/billing/hooks/useOrderCallbacks.d.ts.map +0 -1
- package/dist/billing/modules/billing/hooks/usePayments.d.ts.map +0 -1
- package/dist/billing/modules/billing/hooks/useRefunds.d.ts.map +0 -1
- package/dist/billing/modules/billing/hooks/useTransactions.d.ts.map +0 -1
- package/dist/billing/modules/billing/index.d.ts.map +0 -1
- package/dist/billing/modules/billing/pages/BillingWebhookLogsPage.d.ts.map +0 -1
- package/dist/billing/modules/billing/pages/InvoiceDetailPage.d.ts.map +0 -1
- package/dist/billing/modules/billing/pages/InvoicesListPage.d.ts.map +0 -1
- package/dist/billing/modules/billing/pages/OrderCallbackLogsPage.d.ts.map +0 -1
- package/dist/billing/modules/billing/pages/PaymentMethodsPage.d.ts.map +0 -1
- package/dist/billing/modules/billing/pages/RefundIssueLogsPage.d.ts.map +0 -1
- package/dist/billing/modules/billing/pages/RefundsPage.d.ts.map +0 -1
- package/dist/billing/modules/billing/pages/TransactionsPage.d.ts.map +0 -1
- package/dist/billing/modules/billing/pages/UserRefundsPage.d.ts.map +0 -1
- package/dist/billing/modules/billing/pages/index.d.ts.map +0 -1
- package/dist/billing/modules/checkout/components/AutoPayToggle.d.ts.map +0 -1
- package/dist/billing/modules/checkout/components/BillingAccountSelector.d.ts.map +0 -1
- package/dist/billing/modules/checkout/components/CompactAutoPayToggle.d.ts.map +0 -1
- package/dist/billing/modules/checkout/components/CompleteBillingAccountModal.d.ts.map +0 -1
- package/dist/billing/modules/checkout/components/CreditsAmountInput.d.ts.map +0 -1
- package/dist/billing/modules/checkout/components/CreditsPaymentOption.d.ts.map +0 -1
- package/dist/billing/modules/checkout/components/CurrencySelector.d.ts.map +0 -1
- package/dist/billing/modules/checkout/components/NativeCheckoutView.d.ts.map +0 -1
- package/dist/billing/modules/checkout/components/OrderSummary.d.ts.map +0 -1
- package/dist/billing/modules/checkout/components/PaymentProviderSelector.d.ts.map +0 -1
- package/dist/billing/modules/checkout/components/PromoCodeInput.d.ts.map +0 -1
- package/dist/billing/modules/checkout/components/RazorpayPaymentButton.d.ts.map +0 -1
- package/dist/billing/modules/checkout/components/SavedCardSelector.d.ts.map +0 -1
- package/dist/billing/modules/checkout/components/SimpleAutoPayToggle.d.ts.map +0 -1
- package/dist/billing/modules/checkout/components/StoreShippingSection.d.ts.map +0 -1
- package/dist/billing/modules/checkout/components/StripePaymentForm.d.ts.map +0 -1
- package/dist/billing/modules/checkout/components/SubscriptionSelector.d.ts.map +0 -1
- package/dist/billing/modules/checkout/components/UnifiedPaymentMethodSelector.d.ts.map +0 -1
- package/dist/billing/modules/checkout/components/WebCheckoutRedirectView.d.ts.map +0 -1
- package/dist/billing/modules/checkout/components/WorkspaceQuotaAssignmentModal.d.ts.map +0 -1
- package/dist/billing/modules/checkout/components/index.d.ts.map +0 -1
- package/dist/billing/modules/checkout/hooks/index.d.ts.map +0 -1
- package/dist/billing/modules/checkout/hooks/useCheckout.d.ts.map +0 -1
- package/dist/billing/modules/checkout/hooks/useNativeCheckout.d.ts.map +0 -1
- package/dist/billing/modules/checkout/hooks/usePaymentProviders.d.ts.map +0 -1
- package/dist/billing/modules/checkout/hooks/usePaymentStatusPolling.d.ts.map +0 -1
- package/dist/billing/modules/checkout/hooks/useStoreShipping.d.ts.map +0 -1
- package/dist/billing/modules/checkout/index.d.ts.map +0 -1
- package/dist/billing/modules/checkout/pages/CheckoutPage.d.ts.map +0 -1
- package/dist/billing/modules/checkout/pages/index.d.ts.map +0 -1
- package/dist/billing/modules/checkout/types/index.d.ts.map +0 -1
- package/dist/billing/modules/checkout/utils/storeOrder.d.ts.map +0 -1
- package/dist/billing/modules/coupons/index.d.ts.map +0 -1
- package/dist/billing/modules/coupons/pages/CouponDetailPage.d.ts.map +0 -1
- package/dist/billing/modules/coupons/pages/CouponsListPage.d.ts.map +0 -1
- package/dist/billing/modules/coupons/pages/CreateCouponPage.d.ts.map +0 -1
- package/dist/billing/modules/coupons/pages/EditCouponPage.d.ts.map +0 -1
- package/dist/billing/modules/coupons/pages/index.d.ts.map +0 -1
- package/dist/billing/modules/credits/hooks/index.d.ts.map +0 -1
- package/dist/billing/modules/credits/hooks/useCredits.d.ts.map +0 -1
- package/dist/billing/modules/credits/index.d.ts.map +0 -1
- package/dist/billing/modules/credits/pages/AdminCreditsPage.d.ts.map +0 -1
- package/dist/billing/modules/credits/pages/CreditTransactionsPage.d.ts.map +0 -1
- package/dist/billing/modules/credits/pages/CreditWithdrawalPage.d.ts.map +0 -1
- package/dist/billing/modules/credits/pages/CreditsPage.d.ts.map +0 -1
- package/dist/billing/modules/credits/pages/index.d.ts.map +0 -1
- package/dist/billing/modules/dashboard/components/ActiveSubscriptionCard.d.ts.map +0 -1
- package/dist/billing/modules/dashboard/components/AddPaymentMethodModal.d.ts.map +0 -1
- package/dist/billing/modules/dashboard/components/BillingAccountCard.d.ts.map +0 -1
- package/dist/billing/modules/dashboard/components/CreateBillingAccountModal.d.ts.map +0 -1
- package/dist/billing/modules/dashboard/components/PaymentMethodsSection.d.ts.map +0 -1
- package/dist/billing/modules/dashboard/components/RecommendedAddonsSection.d.ts.map +0 -1
- package/dist/billing/modules/dashboard/components/index.d.ts.map +0 -1
- package/dist/billing/modules/dashboard/hooks/index.d.ts.map +0 -1
- package/dist/billing/modules/dashboard/hooks/useBillingOverviewData.d.ts.map +0 -1
- package/dist/billing/modules/dashboard/hooks/useDashboard.d.ts.map +0 -1
- package/dist/billing/modules/dashboard/index.d.ts.map +0 -1
- package/dist/billing/modules/dashboard/pages/OverviewPage.d.ts.map +0 -1
- package/dist/billing/modules/dashboard/pages/index.d.ts.map +0 -1
- package/dist/billing/modules/discounts/index.d.ts.map +0 -1
- package/dist/billing/modules/discounts/pages/DiscountsListPage.d.ts.map +0 -1
- package/dist/billing/modules/discounts/pages/index.d.ts.map +0 -1
- package/dist/billing/modules/earnings/api.d.ts.map +0 -1
- package/dist/billing/modules/earnings/index.d.ts.map +0 -1
- package/dist/billing/modules/earnings/pages/DeveloperRevenueAdminPage.d.ts.map +0 -1
- package/dist/billing/modules/earnings/pages/DeveloperRevenueOrgDetailPage.d.ts.map +0 -1
- package/dist/billing/modules/earnings/pages/EarningsPage.d.ts.map +0 -1
- package/dist/billing/modules/earnings/pages/PayoutAdminPage.d.ts.map +0 -1
- package/dist/billing/modules/earnings/pages/PayoutsPage.d.ts.map +0 -1
- package/dist/billing/modules/plans/constants/enterprise.d.ts.map +0 -1
- package/dist/billing/modules/plans/constants/featuredQuotas.d.ts.map +0 -1
- package/dist/billing/modules/plans/hooks/index.d.ts.map +0 -1
- package/dist/billing/modules/plans/hooks/usePlans.d.ts.map +0 -1
- package/dist/billing/modules/plans/hooks/useQuotas.d.ts.map +0 -1
- package/dist/billing/modules/plans/index.d.ts.map +0 -1
- package/dist/billing/modules/plans/pages/PlanAssignFreePage.d.ts.map +0 -1
- package/dist/billing/modules/plans/pages/PlanBrowseDetailPage.d.ts.map +0 -1
- package/dist/billing/modules/plans/pages/PlanCreatePage.d.ts.map +0 -1
- package/dist/billing/modules/plans/pages/PlanDetailPage.d.ts.map +0 -1
- package/dist/billing/modules/plans/pages/PlanEditPage.d.ts.map +0 -1
- package/dist/billing/modules/plans/pages/PlansBrowsePage.d.ts.map +0 -1
- package/dist/billing/modules/plans/pages/PlansListPage.d.ts.map +0 -1
- package/dist/billing/modules/plans/pages/index.d.ts.map +0 -1
- package/dist/billing/modules/plans/utils/currencyPriceOverrides.d.ts.map +0 -1
- package/dist/billing/modules/plans/utils/planSelector.d.ts.map +0 -1
- package/dist/billing/modules/promotions/index.d.ts.map +0 -1
- package/dist/billing/modules/promotions/pages/CreatePromotionPage.d.ts.map +0 -1
- package/dist/billing/modules/promotions/pages/PromotionsListPage.d.ts.map +0 -1
- package/dist/billing/modules/promotions/pages/index.d.ts.map +0 -1
- package/dist/billing/modules/quota/hooks/index.d.ts.map +0 -1
- package/dist/billing/modules/quota/hooks/useQuota.d.ts.map +0 -1
- package/dist/billing/modules/quota/hooks/useQuotaTemplates.d.ts.map +0 -1
- package/dist/billing/modules/quota/index.d.ts.map +0 -1
- package/dist/billing/modules/quota/pages/QuotaAssignFreePage.d.ts.map +0 -1
- package/dist/billing/modules/quota/pages/QuotaPage.d.ts.map +0 -1
- package/dist/billing/modules/quota/pages/QuotaTemplateCreatePage.d.ts.map +0 -1
- package/dist/billing/modules/quota/pages/QuotaTemplateDetailPage.d.ts.map +0 -1
- package/dist/billing/modules/quota/pages/QuotaTemplateEditPage.d.ts.map +0 -1
- package/dist/billing/modules/quota/pages/QuotaTemplatesListPage.d.ts.map +0 -1
- package/dist/billing/modules/quota/pages/index.d.ts.map +0 -1
- package/dist/billing/modules/quota/utils/quotaSelector.d.ts.map +0 -1
- package/dist/billing/modules/settings/index.d.ts.map +0 -1
- package/dist/billing/modules/settings/pages/SettingsPage.d.ts.map +0 -1
- package/dist/billing/modules/settings/pages/TeamPermissionsPage.d.ts.map +0 -1
- package/dist/billing/modules/settings/pages/index.d.ts.map +0 -1
- package/dist/billing/modules/store/graphql/index.d.ts.map +0 -1
- package/dist/billing/modules/store/index.d.ts.map +0 -1
- package/dist/billing/modules/store/pages/StoreCheckoutPage.d.ts.map +0 -1
- package/dist/billing/modules/subscriptions/components/ManageSeatsModal.d.ts.map +0 -1
- package/dist/billing/modules/subscriptions/hooks/index.d.ts.map +0 -1
- package/dist/billing/modules/subscriptions/hooks/useSubscriptions.d.ts.map +0 -1
- package/dist/billing/modules/subscriptions/index.d.ts.map +0 -1
- package/dist/billing/modules/subscriptions/pages/SubscriptionDetailPage.d.ts.map +0 -1
- package/dist/billing/modules/subscriptions/pages/SubscriptionsListPage.d.ts.map +0 -1
- package/dist/billing/modules/subscriptions/pages/UpgradeSubscriptionPage.d.ts.map +0 -1
- package/dist/billing/modules/subscriptions/pages/index.d.ts.map +0 -1
- package/dist/billing/modules/usage/components/WorkspaceAiSpendPanel.d.ts.map +0 -1
- package/dist/billing/modules/usage/hooks/index.d.ts.map +0 -1
- package/dist/billing/modules/usage/hooks/useUsage.d.ts.map +0 -1
- package/dist/billing/modules/usage/hooks/useWorkspaceAiSpend.d.ts.map +0 -1
- package/dist/billing/modules/usage/index.d.ts.map +0 -1
- package/dist/billing/modules/usage/pages/UsagePage.d.ts.map +0 -1
- package/dist/billing/modules/usage/pages/index.d.ts.map +0 -1
- package/dist/billing/modules/usage/utils/aiSpend.d.ts.map +0 -1
- package/dist/billing/providers/BillingProvider.d.ts.map +0 -1
- package/dist/billing/shared/components/AccessDenied.d.ts.map +0 -1
- package/dist/billing/shared/components/ActorIdentity.d.ts.map +0 -1
- package/dist/billing/shared/components/CurrencyPriceOverridesEditor.d.ts.map +0 -1
- package/dist/billing/shared/components/EmptyState.d.ts.map +0 -1
- package/dist/billing/shared/components/GeoPricingOverridesEditor.d.ts.map +0 -1
- package/dist/billing/shared/components/PageHeader.d.ts.map +0 -1
- package/dist/billing/shared/components/PushPermissionNudge.d.ts.map +0 -1
- package/dist/billing/shared/components/ServerError.d.ts.map +0 -1
- package/dist/billing/shared/components/StatCard.d.ts.map +0 -1
- package/dist/billing/shared/components/index.d.ts.map +0 -1
- package/dist/billing/shared/hooks/index.d.ts.map +0 -1
- package/dist/billing/shared/hooks/useActorProfiles.d.ts.map +0 -1
- package/dist/billing/shared/hooks/useTr.d.ts.map +0 -1
- package/dist/billing/shared/index.d.ts.map +0 -1
- package/dist/billing/shared/types/graphql.d.ts.map +0 -1
- package/dist/billing/shared/types/index.d.ts.map +0 -1
- package/dist/billing/shared/ui/Card.d.ts.map +0 -1
- package/dist/billing/shared/ui/MetricCard.d.ts.map +0 -1
- package/dist/billing/shared/ui/ProgressBar.d.ts.map +0 -1
- package/dist/billing/shared/ui/SectionHeader.d.ts.map +0 -1
- package/dist/billing/shared/ui/StatusPill.d.ts.map +0 -1
- package/dist/billing/shared/ui/index.d.ts.map +0 -1
- package/dist/billing/shared/utils/directActivityGraphql.d.ts.map +0 -1
- package/dist/billing/shared/utils/directBillingGraphql.d.ts.map +0 -1
- package/dist/billing/shared/utils/error.d.ts.map +0 -1
- package/dist/billing/shared/utils/format.d.ts.map +0 -1
- package/dist/billing/shared/utils/gatewayGraphql.d.ts.map +0 -1
- package/dist/billing/shared/utils/index.d.ts.map +0 -1
- package/dist/billing/shared/utils/navigation.d.ts.map +0 -1
- package/dist/billing/shared/utils/paymentTheme.d.ts.map +0 -1
- package/dist/billing/shared/utils/planFeatureQuantity.d.ts.map +0 -1
- package/dist/billing/shared/utils/status.d.ts.map +0 -1
- package/dist/billing/shared/utils/tokens.d.ts.map +0 -1
- package/dist/billing/translations/en.d.ts.map +0 -1
- package/dist/billing/types/index.d.ts.map +0 -1
- package/dist/dev/main.d.ts.map +0 -1
- package/dist/generated/global-operations.d.ts.map +0 -1
- package/dist/generated/global-types.d.ts.map +0 -1
- package/dist/generated/wspace-operations.d.ts.map +0 -1
- package/dist/generated/wspace-types.d.ts.map +0 -1
- package/dist/index.d.ts.map +0 -1
- package/dist/utils/nativeBridge.d.ts.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useActorProfiles.js","names":[],"sources":["../../../../src/billing/shared/hooks/useActorProfiles.ts"],"sourcesContent":["import { useEffect, useMemo, useRef, useState } from 'react';\nimport { useBilling } from '../../providers/BillingProvider';\nimport { directBillingGraphqlRequest } from '../utils';\n\nexport interface ActorProfile {\n actorId: string;\n actorType: string;\n displayName: string;\n secondaryLabel: string;\n email?: string;\n avatarUrl?: string;\n resolved: boolean;\n}\n\nexport type ActorProfileMap = Record<string, ActorProfile>;\n\ninterface ActorInput {\n actorId: string;\n actorType: string;\n}\n\nconst USER_QUERY = `\n query ActorProfileUser($id: ID!) {\n user(id: $id) {\n id\n email\n firstName\n lastName\n name\n username\n avatar\n }\n }\n`;\n\ninterface UserResponse {\n user: {\n id: string;\n email?: string | null;\n firstName?: string | null;\n lastName?: string | null;\n name?: string | null;\n username?: string | null;\n avatar?: string | null;\n } | null;\n}\n\nfunction shortId(actorId: string): string {\n if (actorId.length <= 12) return actorId;\n return `${actorId.slice(0, 8)}…${actorId.slice(-4)}`;\n}\n\nfunction humanizeType(actorType: string): string {\n switch (actorType.toLowerCase()) {\n case 'user':\n return 'User';\n case 'app':\n return 'App';\n case 'service':\n return 'Service';\n case 'super_admin':\n return 'Super Admin';\n default:\n return actorType\n .split('_')\n .map((segment) => segment.charAt(0) + segment.slice(1).toLowerCase())\n .join(' ');\n }\n}\n\nfunction buildFallback(actor: ActorInput): ActorProfile {\n return {\n actorId: actor.actorId,\n actorType: actor.actorType,\n displayName:\n actor.actorType.toLowerCase() === 'user'\n ? `User ${shortId(actor.actorId)}`\n : humanizeType(actor.actorType),\n secondaryLabel: shortId(actor.actorId),\n resolved: false,\n };\n}\n\nconst cache = new Map<string, ActorProfile>();\nconst inflight = new Map<string, Promise<ActorProfile>>();\nconst CACHE_TTL_MS = 5 * 60 * 1000;\nconst cacheExpiresAt = new Map<string, number>();\n\nfunction cacheGet(actorId: string): ActorProfile | undefined {\n const expiresAt = cacheExpiresAt.get(actorId);\n if (!expiresAt || expiresAt < Date.now()) {\n cache.delete(actorId);\n cacheExpiresAt.delete(actorId);\n return undefined;\n }\n return cache.get(actorId);\n}\n\nfunction cacheSet(profile: ActorProfile): void {\n cache.set(profile.actorId, profile);\n cacheExpiresAt.set(profile.actorId, Date.now() + CACHE_TTL_MS);\n}\n\nexport function useActorProfiles(actors: ActorInput[]): ActorProfileMap {\n const { authToken, apiGatewayUrl, orgId } = useBilling();\n const [profileMap, setProfileMap] = useState<ActorProfileMap>(() => {\n const initial: ActorProfileMap = {};\n for (const actor of actors) {\n const cached = cacheGet(actor.actorId);\n initial[actor.actorId] = cached ?? buildFallback(actor);\n }\n return initial;\n });\n\n const actorsKey = useMemo(\n () =>\n actors\n .map((a) => `${a.actorId}|${a.actorType}`)\n .sort()\n .join(','),\n [actors]\n );\n const lastTokenRef = useRef<string | undefined>(undefined);\n\n useEffect(() => {\n let cancelled = false;\n lastTokenRef.current = authToken;\n\n async function loadOne(actor: ActorInput): Promise<ActorProfile> {\n const cached = cacheGet(actor.actorId);\n if (cached?.resolved) return cached;\n\n if (actor.actorType.toLowerCase() !== 'user') {\n const profile = buildFallback(actor);\n cacheSet(profile);\n return profile;\n }\n\n const key = actor.actorId;\n const existing = inflight.get(key);\n if (existing) return existing;\n\n const promise = (async () => {\n try {\n const data = await directBillingGraphqlRequest<UserResponse>({\n apiGatewayUrl,\n authToken,\n orgId,\n query: USER_QUERY,\n variables: { id: actor.actorId },\n });\n if (!data.user) {\n const profile = buildFallback(actor);\n cacheSet(profile);\n return profile;\n }\n const u = data.user;\n const displayName =\n u.name?.trim() ||\n [u.firstName, u.lastName].filter(Boolean).join(' ').trim() ||\n u.username?.trim() ||\n u.email?.trim() ||\n `User ${shortId(actor.actorId)}`;\n const profile: ActorProfile = {\n actorId: actor.actorId,\n actorType: actor.actorType,\n displayName,\n secondaryLabel: u.email ?? shortId(actor.actorId),\n email: u.email ?? undefined,\n avatarUrl: u.avatar ?? undefined,\n resolved: true,\n };\n cacheSet(profile);\n return profile;\n } catch {\n const profile = buildFallback(actor);\n return profile;\n } finally {\n inflight.delete(key);\n }\n })();\n inflight.set(key, promise);\n return promise;\n }\n\n async function run() {\n const results = await Promise.all(actors.map(loadOne));\n if (cancelled) return;\n setProfileMap((prev) => {\n const next: ActorProfileMap = { ...prev };\n for (const profile of results) {\n next[profile.actorId] = profile;\n }\n return next;\n });\n }\n\n void run();\n return () => {\n cancelled = true;\n };\n }, [actorsKey, authToken, apiGatewayUrl, orgId]); // eslint-disable-line react-hooks/exhaustive-deps\n\n return profileMap;\n}\n"],"mappings":";;;;;AAqBA,
|
|
1
|
+
{"version":3,"file":"useActorProfiles.js","names":["USER_QUERY","shortId","actorId","humanizeType","actorType","segment","buildFallback","actor","cache","inflight","CACHE_TTL_MS","cacheExpiresAt","cacheGet","expiresAt","cacheSet","profile","useActorProfiles","useBilling","profileMap","setProfileMap","useState","initial","actors","cached","actorsKey","useMemo","a","lastTokenRef","useRef","useEffect","cancelled","authToken","loadOne","key","existing","promise","data","directBillingGraphqlRequest","u","displayName","run","results","next","prev","apiGatewayUrl","orgId"],"sources":["../../../../src/billing/shared/hooks/useActorProfiles.ts"],"sourcesContent":["import { useEffect, useMemo, useRef, useState } from 'react';\nimport { useBilling } from '../../providers/BillingProvider';\nimport { directBillingGraphqlRequest } from '../utils';\n\nexport interface ActorProfile {\n actorId: string;\n actorType: string;\n displayName: string;\n secondaryLabel: string;\n email?: string;\n avatarUrl?: string;\n resolved: boolean;\n}\n\nexport type ActorProfileMap = Record<string, ActorProfile>;\n\ninterface ActorInput {\n actorId: string;\n actorType: string;\n}\n\nconst USER_QUERY = `\n query ActorProfileUser($id: ID!) {\n user(id: $id) {\n id\n email\n firstName\n lastName\n name\n username\n avatar\n }\n }\n`;\n\ninterface UserResponse {\n user: {\n id: string;\n email?: string | null;\n firstName?: string | null;\n lastName?: string | null;\n name?: string | null;\n username?: string | null;\n avatar?: string | null;\n } | null;\n}\n\nfunction shortId(actorId: string): string {\n if (actorId.length <= 12) return actorId;\n return `${actorId.slice(0, 8)}…${actorId.slice(-4)}`;\n}\n\nfunction humanizeType(actorType: string): string {\n switch (actorType.toLowerCase()) {\n case 'user':\n return 'User';\n case 'app':\n return 'App';\n case 'service':\n return 'Service';\n case 'super_admin':\n return 'Super Admin';\n default:\n return actorType\n .split('_')\n .map((segment) => segment.charAt(0) + segment.slice(1).toLowerCase())\n .join(' ');\n }\n}\n\nfunction buildFallback(actor: ActorInput): ActorProfile {\n return {\n actorId: actor.actorId,\n actorType: actor.actorType,\n displayName:\n actor.actorType.toLowerCase() === 'user'\n ? `User ${shortId(actor.actorId)}`\n : humanizeType(actor.actorType),\n secondaryLabel: shortId(actor.actorId),\n resolved: false,\n };\n}\n\nconst cache = new Map<string, ActorProfile>();\nconst inflight = new Map<string, Promise<ActorProfile>>();\nconst CACHE_TTL_MS = 5 * 60 * 1000;\nconst cacheExpiresAt = new Map<string, number>();\n\nfunction cacheGet(actorId: string): ActorProfile | undefined {\n const expiresAt = cacheExpiresAt.get(actorId);\n if (!expiresAt || expiresAt < Date.now()) {\n cache.delete(actorId);\n cacheExpiresAt.delete(actorId);\n return undefined;\n }\n return cache.get(actorId);\n}\n\nfunction cacheSet(profile: ActorProfile): void {\n cache.set(profile.actorId, profile);\n cacheExpiresAt.set(profile.actorId, Date.now() + CACHE_TTL_MS);\n}\n\nexport function useActorProfiles(actors: ActorInput[]): ActorProfileMap {\n const { authToken, apiGatewayUrl, orgId } = useBilling();\n const [profileMap, setProfileMap] = useState<ActorProfileMap>(() => {\n const initial: ActorProfileMap = {};\n for (const actor of actors) {\n const cached = cacheGet(actor.actorId);\n initial[actor.actorId] = cached ?? buildFallback(actor);\n }\n return initial;\n });\n\n const actorsKey = useMemo(\n () =>\n actors\n .map((a) => `${a.actorId}|${a.actorType}`)\n .sort()\n .join(','),\n [actors]\n );\n const lastTokenRef = useRef<string | undefined>(undefined);\n\n useEffect(() => {\n let cancelled = false;\n lastTokenRef.current = authToken;\n\n async function loadOne(actor: ActorInput): Promise<ActorProfile> {\n const cached = cacheGet(actor.actorId);\n if (cached?.resolved) return cached;\n\n if (actor.actorType.toLowerCase() !== 'user') {\n const profile = buildFallback(actor);\n cacheSet(profile);\n return profile;\n }\n\n const key = actor.actorId;\n const existing = inflight.get(key);\n if (existing) return existing;\n\n const promise = (async () => {\n try {\n const data = await directBillingGraphqlRequest<UserResponse>({\n apiGatewayUrl,\n authToken,\n orgId,\n query: USER_QUERY,\n variables: { id: actor.actorId },\n });\n if (!data.user) {\n const profile = buildFallback(actor);\n cacheSet(profile);\n return profile;\n }\n const u = data.user;\n const displayName =\n u.name?.trim() ||\n [u.firstName, u.lastName].filter(Boolean).join(' ').trim() ||\n u.username?.trim() ||\n u.email?.trim() ||\n `User ${shortId(actor.actorId)}`;\n const profile: ActorProfile = {\n actorId: actor.actorId,\n actorType: actor.actorType,\n displayName,\n secondaryLabel: u.email ?? shortId(actor.actorId),\n email: u.email ?? undefined,\n avatarUrl: u.avatar ?? undefined,\n resolved: true,\n };\n cacheSet(profile);\n return profile;\n } catch {\n const profile = buildFallback(actor);\n return profile;\n } finally {\n inflight.delete(key);\n }\n })();\n inflight.set(key, promise);\n return promise;\n }\n\n async function run() {\n const results = await Promise.all(actors.map(loadOne));\n if (cancelled) return;\n setProfileMap((prev) => {\n const next: ActorProfileMap = { ...prev };\n for (const profile of results) {\n next[profile.actorId] = profile;\n }\n return next;\n });\n }\n\n void run();\n return () => {\n cancelled = true;\n };\n }, [actorsKey, authToken, apiGatewayUrl, orgId]); // eslint-disable-line react-hooks/exhaustive-deps\n\n return profileMap;\n}\n"],"mappings":";;;;;AAqBA,IAAMA,IAAa;AA0BnB,SAASC,EAAQ,GAAyB;CAExC,OADIC,EAAQ,UAAU,KAAWA,IAC1B,GAAGA,EAAQ,MAAM,GAAG,CAAC,EAAE,GAAGA,EAAQ,MAAM,EAAE;AACnD;AAEA,SAASC,EAAa,GAA2B;CAC/C,QAAQC,EAAU,YAAY,GAA9B;EACE,KAAK,QACH,OAAO;EACT,KAAK,OACH,OAAO;EACT,KAAK,WACH,OAAO;EACT,KAAK,eACH,OAAO;EACT,SACE,OAAOA,EACJ,MAAM,GAAG,CAAC,CACV,KAAK,MAAYC,EAAQ,OAAO,CAAC,IAAIA,EAAQ,MAAM,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,CACpE,KAAK,GAAG;CACf;AACF;AAEA,SAASC,EAAc,GAAiC;CACtD,OAAO;EACL,SAASC,EAAM;EACf,WAAWA,EAAM;EACjB,aACEA,EAAM,UAAU,YAAY,MAAM,SAC9B,QAAQN,EAAQM,EAAM,OAAO,MAC7BJ,EAAaI,EAAM,SAAS;EAClC,gBAAgBN,EAAQM,EAAM,OAAO;EACrC,UAAU;CACZ;AACF;AAEA,IAAMC,oBAAQ,IAAI,IAA0B,GACtCC,oBAAW,IAAI,IAAmC,GAClDC,IAAe,KACfC,oBAAiB,IAAI,IAAoB;AAE/C,SAASC,EAAS,GAA2C;CAC3D,IAAMC,IAAYF,EAAe,IAAIT,CAAO;CAC5C,IAAI,CAACW,KAAaA,IAAY,KAAK,IAAI,GAErC,AADAL,EAAM,OAAON,CAAO,GACpBS,EAAe,OAAOT,CAAO;MAG/B,OAAOM,EAAM,IAAIN,CAAO;AAC1B;AAEA,SAASY,EAAS,GAA6B;CAE7C,AADAN,EAAM,IAAIO,EAAQ,SAASA,CAAO,GAClCJ,EAAe,IAAII,EAAQ,SAAS,KAAK,IAAI,IAAIL,CAAY;AAC/D;AAEA,SAAgBM,EAAiB,GAAuC;CACtE,IAAM,EAAE,cAAW,kBAAe,aAAUC,EAAW,GACjD,CAACC,GAAYC,KAAiBC,QAAgC;EAClE,IAAMC,IAA2B,CAAC;EAClC,KAAK,IAAMd,KAASe,GAAQ;GAC1B,IAAMC,IAASX,EAASL,EAAM,OAAO;GACrC,EAAQA,EAAM,WAAWgB,KAAUjB,EAAcC,CAAK;EACxD;EACA,OAAOc;CACT,CAAC,GAEKG,IAAYC,QAEdH,EACG,KAAK,MAAM,GAAGI,EAAE,QAAQ,GAAGA,EAAE,WAAW,CAAC,CACzC,KAAK,CAAC,CACN,KAAK,GAAG,GACb,CAACJ,CAAM,CACT,GACMK,IAAeC,EAA2B,KAAA,CAAS;CAiFzD,OA/EAC,QAAgB;EACd,IAAIC,IAAY;EAChB,EAAa,UAAUC;EAEvB,eAAeC,EAAQ,GAA0C;GAC/D,IAAMT,IAASX,EAASL,EAAM,OAAO;GACrC,IAAIgB,GAAQ,UAAU,OAAOA;GAE7B,IAAIhB,EAAM,UAAU,YAAY,MAAM,QAAQ;IAC5C,IAAMQ,IAAUT,EAAcC,CAAK;IAEnC,OADAO,EAASC,CAAO,GACTA;GACT;GAEA,IAAMkB,IAAM1B,EAAM,SACZ2B,IAAWzB,EAAS,IAAIwB,CAAG;GACjC,IAAIC,GAAU,OAAOA;GAErB,IAAMC,KAAW,YAAY;IAC3B,IAAI;KACF,IAAMC,IAAO,MAAMC,EAA0C;MAC3D;MACA;MACA;MACA,OAAOrC;MACP,WAAW,EAAE,IAAIO,EAAM,QAAQ;KACjC,CAAC;KACD,IAAI,CAAC6B,EAAK,MAAM;MACd,IAAMrB,IAAUT,EAAcC,CAAK;MAEnC,OADAO,EAASC,CAAO,GACTA;KACT;KACA,IAAMuB,IAAIF,EAAK,MACTG,IACJD,EAAE,MAAM,KAAK,KACb,CAACA,EAAE,WAAWA,EAAE,QAAQ,CAAC,CAAC,OAAO,OAAO,CAAC,CAAC,KAAK,GAAG,CAAC,CAAC,KAAK,KACzDA,EAAE,UAAU,KAAK,KACjBA,EAAE,OAAO,KAAK,KACd,QAAQrC,EAAQM,EAAM,OAAO,KACzBQ,IAAwB;MAC5B,SAASR,EAAM;MACf,WAAWA,EAAM;MACjB;MACA,gBAAgB+B,EAAE,SAASrC,EAAQM,EAAM,OAAO;MAChD,OAAO+B,EAAE,SAAS,KAAA;MAClB,WAAWA,EAAE,UAAU,KAAA;MACvB,UAAU;KACZ;KAEA,OADAxB,EAASC,CAAO,GACTA;IACT,QAAQ;KAEN,OADgBT,EAAcC,CACvB;IACT,UAAU;KACR,EAAS,OAAO0B,CAAG;IACrB;GACF,EAAA,CAAG;GAEH,OADAxB,EAAS,IAAIwB,GAAKE,CAAO,GAClBA;EACT;EAEA,eAAeK,IAAM;GACnB,IAAMC,IAAU,MAAM,QAAQ,IAAInB,EAAO,IAAIU,CAAO,CAAC;GACrD,AAAIF,KACJX,GAAe,MAAS;IACtB,IAAMuB,IAAwB,EAAE,GAAGC,EAAK;IACxC,KAAK,IAAM5B,KAAW0B,GACpB,EAAK1B,EAAQ,WAAWA;IAE1B,OAAO2B;GACT,CAAC;EACH;EAGA,OADAF,EAAS,SACI;GACX,IAAY;EACd;CACF,GAAG;EAAChB;EAAWO;EAAWa;EAAeC;CAAK,CAAC,GAExC3B;AACT"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { useCallback as e } from "react";
|
|
2
2
|
import { useI18n as t } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
|
|
3
|
-
|
|
3
|
+
// src/billing/shared/hooks/useTr.ts
|
|
4
4
|
function n() {
|
|
5
5
|
let { t: n } = t();
|
|
6
6
|
return e((e, t, r) => {
|
|
@@ -8,7 +8,6 @@ function n() {
|
|
|
8
8
|
return r ? Object.entries(r).reduce((e, [t, n]) => e.replace(RegExp(`\\{\\{${t}\\}\\}`, "g"), String(n)), a) : a;
|
|
9
9
|
}, [n]);
|
|
10
10
|
}
|
|
11
|
-
//#endregion
|
|
12
11
|
export { n as useTr };
|
|
13
12
|
|
|
14
13
|
//# sourceMappingURL=useTr.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useTr.js","names":[],"sources":["../../../../src/billing/shared/hooks/useTr.ts"],"sourcesContent":["import { useCallback } from 'react';\nimport { useI18n } from '@burdenoff/fe-libs/shared/providers/shell/I18nProvider';\n\n/**\n * useTr — translation hook with fallback semantics.\n *\n * Wraps `useI18n().t()` so that when a key has no translation (i.e. the\n * provider returns the key itself), the caller's English fallback is used\n * instead. This keeps consumer call sites consistent and avoids leaking\n * untranslated keys into the UI.\n *\n * Supports optional interpolation params using `{{key}}` placeholders.\n *\n * @example\n * const tr = useTr();\n * return <h1>{tr('billing.dashboard.title', 'Dashboard')}</h1>;\n * return <p>{tr('billing.delete.confirm', 'Delete {{count}} items?', { count: 5 })}</p>;\n */\nexport function useTr(): (\n key: string,\n fallback: string,\n params?: Record<string, string | number>\n) => string {\n const { t } = useI18n();\n return useCallback(\n (key: string, fallback: string, params?: Record<string, string | number>): string => {\n const translated = t(key);\n const raw = translated === key ? fallback : translated;\n if (!params) return raw;\n return Object.entries(params).reduce(\n (str, [k, v]) => str.replace(new RegExp(`\\\\{\\\\{${k}\\\\}\\\\}`, 'g'), String(v)),\n raw\n );\n },\n [t]\n );\n}\n"],"mappings":";;;AAkBA,
|
|
1
|
+
{"version":3,"file":"useTr.js","names":["useTr","useI18n","useCallback","translated","t","key","raw","fallback","params","k","v","str"],"sources":["../../../../src/billing/shared/hooks/useTr.ts"],"sourcesContent":["import { useCallback } from 'react';\nimport { useI18n } from '@burdenoff/fe-libs/shared/providers/shell/I18nProvider';\n\n/**\n * useTr — translation hook with fallback semantics.\n *\n * Wraps `useI18n().t()` so that when a key has no translation (i.e. the\n * provider returns the key itself), the caller's English fallback is used\n * instead. This keeps consumer call sites consistent and avoids leaking\n * untranslated keys into the UI.\n *\n * Supports optional interpolation params using `{{key}}` placeholders.\n *\n * @example\n * const tr = useTr();\n * return <h1>{tr('billing.dashboard.title', 'Dashboard')}</h1>;\n * return <p>{tr('billing.delete.confirm', 'Delete {{count}} items?', { count: 5 })}</p>;\n */\nexport function useTr(): (\n key: string,\n fallback: string,\n params?: Record<string, string | number>\n) => string {\n const { t } = useI18n();\n return useCallback(\n (key: string, fallback: string, params?: Record<string, string | number>): string => {\n const translated = t(key);\n const raw = translated === key ? fallback : translated;\n if (!params) return raw;\n return Object.entries(params).reduce(\n (str, [k, v]) => str.replace(new RegExp(`\\\\{\\\\{${k}\\\\}\\\\}`, 'g'), String(v)),\n raw\n );\n },\n [t]\n );\n}\n"],"mappings":";;;AAkBA,SAAgBA,IAIJ;CACV,IAAM,EAAE,SAAMC,EAAQ;CACtB,OAAOC,GACJ,GAAa,GAAkB,MAAqD;EACnF,IAAMC,IAAaC,EAAEC,CAAG,GAClBC,IAAMH,MAAeE,IAAME,IAAWJ;EAE5C,OADKK,IACE,OAAO,QAAQA,CAAM,CAAC,CAAC,QAC3B,GAAK,CAACC,GAAGC,OAAOC,EAAI,QAAY,OAAO,SAASF,EAAE,SAAS,GAAG,GAAG,OAAOC,CAAC,CAAC,GAC3EJ,CACF,IAJoBA;CAKtB,GACA,CAACF,CAAC,CACJ;AACF"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
// src/billing/shared/types/graphql.ts
|
|
2
2
|
var e = /* @__PURE__ */ function(e) {
|
|
3
3
|
return e.ACTIVE = "active", e.CANCELED = "canceled", e.EXPIRED = "expired", e.UPGRADED = "upgraded", e;
|
|
4
4
|
}({}), t = /* @__PURE__ */ function(e) {
|
|
@@ -24,7 +24,6 @@ var e = /* @__PURE__ */ function(e) {
|
|
|
24
24
|
}({}), d = /* @__PURE__ */ function(e) {
|
|
25
25
|
return e.LAST_7_DAYS = "LAST_7_DAYS", e.LAST_30_DAYS = "LAST_30_DAYS", e.LAST_90_DAYS = "LAST_90_DAYS", e.LAST_MONTH = "LAST_MONTH", e.CURRENT_MONTH = "CURRENT_MONTH", e;
|
|
26
26
|
}({});
|
|
27
|
-
//#endregion
|
|
28
27
|
export { d as AnalyticsPeriod, l as CreditTransactionStatus, c as CreditTransactionType, t as InvoiceStatus, u as PaymentProviderPreference, n as PlanDuration, r as PricingModel, a as QuotaResetPeriod, o as QuotaStatus, i as QuotaType, e as SubscriptionStatus, s as TransactionStatus };
|
|
29
28
|
|
|
30
29
|
//# sourceMappingURL=graphql.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"graphql.js","names":[],"sources":["../../../../src/billing/shared/types/graphql.ts"],"sourcesContent":["/**\n * GraphQL Types for Billing Module\n * Auto-generated types matching the backend billing service schema\n */\n\n// ============================================================================\n// Enums\n// ============================================================================\n\nexport enum SubscriptionStatus {\n ACTIVE = 'active',\n CANCELED = 'canceled',\n EXPIRED = 'expired',\n UPGRADED = 'upgraded',\n}\n\nexport enum InvoiceStatus {\n DRAFT = 'DRAFT',\n OPEN = 'OPEN',\n PAID = 'PAID',\n VOID = 'VOID',\n UNCOLLECTIBLE = 'UNCOLLECTIBLE',\n}\n\nexport enum PaymentStatus {\n PENDING = 'PENDING',\n SUCCEEDED = 'SUCCEEDED',\n FAILED = 'FAILED',\n CANCELED = 'CANCELED',\n REFUNDED = 'REFUNDED',\n}\n\nexport enum ChargeStatus {\n PENDING = 'PENDING',\n SUCCEEDED = 'SUCCEEDED',\n FAILED = 'FAILED',\n REFUNDED = 'REFUNDED',\n}\n\nexport enum RefundStatus {\n PENDING = 'PENDING',\n SUCCEEDED = 'SUCCEEDED',\n FAILED = 'FAILED',\n CANCELED = 'CANCELED',\n}\n\nexport enum PaymentMethodType {\n CREDIT_CARD = 'CREDIT_CARD',\n DEBIT_CARD = 'DEBIT_CARD',\n BANK_TRANSFER = 'BANK_TRANSFER',\n PAYPAL = 'PAYPAL',\n CRYPTO = 'CRYPTO',\n WALLET = 'WALLET',\n NETBANKING = 'NETBANKING',\n}\n\nexport enum PlanDuration {\n MONTHLY = 'monthly',\n YEARLY = 'yearly',\n}\n\nexport enum PricingModel {\n FLAT_RATE = 'FLAT_RATE',\n PER_SEAT = 'PER_SEAT',\n}\n\nexport enum QuotaType {\n POOLED = 'POOLED',\n PRODUCT_SPECIFIC = 'PRODUCT_SPECIFIC',\n}\n\nexport enum QuotaScope {\n WORKSPACE = 'WORKSPACE',\n GLOBAL = 'GLOBAL',\n}\n\nexport enum QuotaResetPeriod {\n NEVER = 'NEVER',\n DAILY = 'DAILY',\n MONTHLY = 'MONTHLY',\n}\n\nexport enum QuotaStatus {\n HEALTHY = 'HEALTHY',\n WARNING = 'WARNING',\n CRITICAL = 'CRITICAL',\n EXHAUSTED = 'EXHAUSTED',\n INACTIVE = 'INACTIVE',\n}\n\nexport enum TransactionType {\n PAYMENT = 'payment',\n REFUND = 'refund',\n ADJUSTMENT = 'adjustment',\n}\n\nexport enum TransactionStatus {\n PENDING = 'pending',\n SUCCESS = 'success',\n FAILED = 'failed',\n}\n\nexport enum CreditTransactionType {\n PURCHASE = 'purchase',\n USAGE = 'usage',\n ADJUSTMENT = 'adjustment',\n GRANTED = 'granted',\n}\n\nexport enum CreditTransactionStatus {\n PENDING = 'pending',\n SUCCESS = 'success',\n FAILED = 'failed',\n REFUND = 'refund',\n}\n\nexport enum EntitlementAccessType {\n FREE_ACCESS = 'FREE_ACCESS',\n DISCOUNT = 'DISCOUNT',\n}\n\nexport enum PurchaseType {\n PLAN = 'PLAN',\n ADDON = 'ADDON',\n CREDITS = 'CREDITS',\n}\n\nexport enum PaymentProviderPreference {\n AUTO = 'AUTO',\n STRIPE = 'STRIPE',\n RAZORPAY = 'RAZORPAY',\n}\n\nexport enum AnalyticsPeriod {\n LAST_7_DAYS = 'LAST_7_DAYS',\n LAST_30_DAYS = 'LAST_30_DAYS',\n LAST_90_DAYS = 'LAST_90_DAYS',\n LAST_MONTH = 'LAST_MONTH',\n CURRENT_MONTH = 'CURRENT_MONTH',\n}\n\nexport enum UsageMetricType {\n USERS = 'USERS',\n STORAGE = 'STORAGE',\n API_CALLS = 'API_CALLS',\n BANDWIDTH = 'BANDWIDTH',\n REQUESTS = 'REQUESTS',\n COMPUTE_HOURS = 'COMPUTE_HOURS',\n TRANSACTIONS = 'TRANSACTIONS',\n CUSTOM = 'CUSTOM',\n}\n\n// ============================================================================\n// Core Types\n// ============================================================================\n\nexport interface BillingAccount {\n id: string;\n orgId: string;\n name: string;\n email: string;\n billingEmail?: string;\n currency: string;\n creditAmount: number;\n stripeCustomerId?: string;\n razorpayCustomerId?: string;\n defaultPaymentMethod?: string;\n taxId?: string;\n isActive: boolean;\n isDefault?: boolean;\n metadata?: Record<string, unknown>;\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n // Relations\n subscriptions?: BillingSubscription[];\n paymentMethods?: PaymentMethod[];\n creditTransactions?: CreditTransaction[];\n quotaAssignments?: QuotaAssignment[];\n billingAddresses?: BillingAddress[];\n transactions?: Transaction[];\n}\n\nexport interface BillingAddress {\n id: string;\n billingAccountId: string;\n orgId: string;\n line1: string;\n line2?: string;\n city: string;\n state?: string;\n postalCode: string;\n country: string;\n metadata?: Record<string, unknown>;\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n}\n\n// ============================================================================\n// Plan Types\n// ============================================================================\n\nexport interface Plan {\n id: string;\n productID: string;\n name: string;\n price: number;\n currency: string;\n currencyPrices?: Record<string, number>;\n geoPricingOverrides?: GeoPricingOverrideInput[];\n duration: PlanDuration;\n pricingModel?: PricingModel;\n pricePerSeat?: number;\n minSeats?: number;\n maxSeats?: number;\n /** Max distinct workspaces one subscription to this plan can activate its\n * WORKSPACE-scoped quotas against (each gets the full allotment, not\n * divided). Unset/null = today's implicit single-workspace behavior. */\n maxWorkspaces?: number;\n isActive: boolean;\n isPurchasable: boolean;\n features?: SubscriptionFeatures[];\n itemEntitlements?: SubscriptionEntitlement[];\n subscriptions?: BillingSubscription[];\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n // Relations\n product?: Product;\n}\n\nexport interface SubscriptionFeatures {\n id: string;\n planId?: string;\n addonId?: string;\n quotaId?: string;\n plan?: Plan;\n addon?: Addon;\n quota?: Quota;\n context?: Record<string, unknown>;\n}\n\nexport interface SubscriptionEntitlement {\n id: string;\n planId: string;\n itemId: string;\n accessType: EntitlementAccessType;\n discountPercentage?: number;\n plan?: Plan;\n item?: { id: string };\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n}\n\n// ============================================================================\n// Subscription Types\n// ============================================================================\n\nexport interface BillingSubscription {\n id: string;\n billingAccountId: string;\n planId: string;\n status: SubscriptionStatus;\n startDate: string;\n endDate: string;\n autoRenewal: boolean;\n recurrence: boolean;\n seatCount?: number;\n lastSeatChangeAt?: string;\n lastBillingDate?: string;\n nextBillingDate?: string;\n lastRenewalDate?: string;\n canceledAt?: string;\n canceledBy?: string;\n cancellationReason?: string;\n stripeSubscriptionId?: string;\n razorpaySubscriptionId?: string;\n paymentGateway?: string;\n assignedWorkspaceId?: string | null;\n activatedWorkspaceIds?: string[];\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n // Relations\n plan?: Plan;\n billingAccount?: BillingAccount;\n addonSubscriptions?: AddonSubscription[];\n quotas?: QuotaAssignment[];\n transactions?: Transaction[];\n history?: SubscriptionHistory[];\n}\n\nexport interface SubscriptionHistory {\n id: string;\n subscriptionId: string;\n fromStatus: SubscriptionStatus;\n toStatus: SubscriptionStatus;\n reason?: string;\n metadata?: Record<string, unknown>;\n context?: Record<string, unknown>;\n createdAt: string;\n}\n\n// ============================================================================\n// Addon Types\n// ============================================================================\n\nexport interface Addon {\n id: string;\n productID: string;\n name: string;\n price: number;\n currency: string;\n currencyPrices?: Record<string, number>;\n geoPricingOverrides?: GeoPricingOverrideInput[];\n duration: PlanDuration;\n isActive: boolean;\n /** BOFF-9889: buying it needs a paid subscription to its product. */\n requiresPaidSubscription?: boolean | null;\n features?: SubscriptionFeatures[];\n addonSubscriptions?: AddonSubscription[];\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n // Relations\n product?: Product;\n}\n\nexport interface AddonSubscription {\n id: string;\n addonId: string;\n currentSubscriptionId: string;\n quantity: number;\n startDate: string;\n endDate: string;\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n // Relations\n addon?: Addon;\n currentSubscription?: BillingSubscription;\n}\n\n// ============================================================================\n// Invoice Types\n// ============================================================================\n\nexport interface Invoice {\n id: string;\n orgId: string;\n billingAccountId?: string;\n subscriptionId?: string;\n paymentId?: string;\n invoiceNumber: string;\n status: InvoiceStatus;\n subtotal: number;\n tax: number;\n total: number;\n amountPaid: number;\n currency: string;\n dueDate?: string;\n paidAt?: string;\n gatewayInvoiceId?: string;\n invoiceUrl?: string;\n pdfUrl?: string;\n itemDescription?: string;\n metadata?: Record<string, unknown>;\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n // Relations\n items: InvoiceItem[];\n subscription?: BillingSubscription;\n payment?: Payment;\n}\n\nexport interface InvoiceItem {\n id: string;\n invoiceId: string;\n description: string;\n quantity: number;\n unitPrice: number;\n amount: number;\n metadata?: Record<string, unknown>;\n context?: Record<string, unknown>;\n}\n\n// ============================================================================\n// Payment Types\n// ============================================================================\n\nexport interface Payment {\n id: string;\n orgId: string;\n transactionId?: string;\n amount: number;\n currency: string;\n status: PaymentStatus;\n method: PaymentMethodType;\n provider?: string;\n gatewayPaymentId?: string;\n gatewayOrderId?: string;\n failureReason?: string;\n paidAt?: string;\n metadata?: Record<string, unknown>;\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n // Relations\n invoice?: Invoice;\n}\n\nexport interface PaymentMethod {\n id: string;\n orgId: string;\n billingAccountId?: string;\n type: PaymentMethodType;\n brand?: string;\n last4?: string;\n expiryMonth?: number;\n expiryYear?: number;\n isDefault: boolean;\n isVerified: boolean;\n verifiedAt?: string;\n stripeCustomerId?: string;\n stripePaymentMethodId?: string;\n razorpayCustomerId?: string;\n razorpayPaymentMethodId?: string;\n metadata?: Record<string, unknown>;\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n // Relations\n billingAccount?: BillingAccount;\n transactions?: Transaction[];\n}\n\nexport interface Charge {\n id: string;\n orgId: string;\n amount: number;\n currency: string;\n status: ChargeStatus;\n description?: string;\n provider?: string;\n gatewayChargeId?: string;\n gatewayPaymentId?: string;\n metadata?: Record<string, unknown>;\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n // Relations\n refunds: Refund[];\n}\n\nexport interface Refund {\n id: string;\n chargeId: string;\n amount: number;\n currency: string;\n status: RefundStatus;\n reason?: string;\n provider?: string;\n gatewayRefundId?: string;\n processedAt?: string;\n metadata?: Record<string, unknown>;\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n // Relations\n charge?: Charge;\n}\n\n// ============================================================================\n// Transaction Types\n// ============================================================================\n\nexport interface Transaction {\n id: string;\n billingAccountId: string;\n amount: number;\n currency: string;\n type: TransactionType;\n status: TransactionStatus;\n description?: string;\n stripePaymentId?: string;\n razorpayPaymentId?: string;\n metadata?: Record<string, unknown>;\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n}\n\n// ============================================================================\n// Credit Types\n// ============================================================================\n\nexport interface CreditTransaction {\n id: string;\n billingAccountId: string;\n productId: string;\n amount: number;\n type: CreditTransactionType;\n status: CreditTransactionStatus;\n fromType?: CreditTransactionType | null;\n payoutRequestId?: string | null;\n entityType?: string;\n entityId?: string;\n transactionId?: string;\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n // Relations\n billingAccount?: BillingAccount;\n transaction?: Transaction;\n}\n\nexport interface CreditBalanceByType {\n purchased: number;\n earned: number;\n granted: number;\n withdrawable: number;\n total: number;\n}\n\nexport interface CreditNote {\n id: string;\n orgId: string;\n invoiceId?: string;\n number: string;\n amount: number;\n currency: string;\n reason?: string;\n metadata?: Record<string, unknown>;\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n}\n\nexport interface CreditRate {\n id: string;\n rateUSD: number;\n effectiveFrom: string;\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n}\n\n// ============================================================================\n// Quota Types\n// ============================================================================\n\nexport interface Quota {\n id: string;\n name: string;\n limits: Record<string, unknown>;\n quotaType: QuotaType;\n reusable: boolean;\n resetPeriod: QuotaResetPeriod;\n isActive: boolean;\n scope?: QuotaScope;\n subscriptions?: SubscriptionFeatures[];\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n}\n\nexport interface QuotaAssignment {\n id: string;\n billingAccountId?: string;\n subscriptionId?: string;\n name: string;\n limits: Record<string, unknown>;\n quotaType: QuotaType;\n reusable: boolean;\n currentUsageSum: number;\n totalUsageCount: number;\n endtime: string;\n context?: Record<string, unknown>;\n createdAt: string;\n // Relations\n billingAccount?: BillingAccount;\n subscription?: BillingSubscription;\n usages?: Usage[];\n recentUsages?: Usage[];\n usageAnalytics?: QuotaUsageAnalytics;\n}\n\nexport interface QuotaAssignmentWithAnalytics extends QuotaAssignment {\n status: QuotaStatus;\n healthScore: number;\n usagePercentage: number;\n limitLeft: number;\n analytics: QuotaUsageAnalytics;\n}\n\nexport interface QuotaAssignmentUsageSummary {\n id: string;\n name: string;\n quotaType: QuotaType;\n reusable: boolean;\n limit: number;\n limitLeft: number;\n used: number;\n usagePercentage: number;\n noLimit: boolean;\n subscriptionId?: string;\n recentUsages: Usage[];\n createdAt: string;\n endtime: string;\n}\n\n// ============================================================================\n// Usage Types\n// ============================================================================\n\nexport interface Usage {\n id: string;\n quotaAssignmentId: string;\n userId?: string;\n productId?: string;\n amount: number;\n description?: string;\n tags?: Record<string, unknown>;\n timestamp: string;\n lastUpdated: string;\n context?: Record<string, unknown>;\n // Relations\n quotaAssignment?: QuotaAssignment;\n user?: { id: string };\n}\n\nexport interface UsageRecord {\n id: string;\n orgId: string;\n subscriptionId?: string;\n metricType: UsageMetricType;\n quantity: number;\n unitCost?: number;\n totalCost?: number;\n timestamp: string;\n metadata?: Record<string, unknown>;\n context?: Record<string, unknown>;\n createdAt: string;\n}\n\nexport interface DailyUsage {\n date: string;\n usage: number;\n count: number;\n}\n\nexport interface PeakUsage {\n peakDate: string;\n maxDailyUsage: number;\n peakHour?: number;\n}\n\nexport interface UsageTrends {\n averageDailyUsage?: number;\n growthRate?: number;\n predictedUsage?: number;\n}\n\nexport interface UsageByType {\n resourceType: string;\n usage: number;\n count: number;\n percentage: number;\n}\n\nexport interface QuotaUsageAnalytics {\n dailyUsage: DailyUsage[];\n usageByType: UsageByType[];\n peakUsage?: PeakUsage;\n trends?: UsageTrends;\n}\n\nexport interface QuotaUsageSummary {\n quotaId: string;\n quotaName: string;\n usage: number;\n limit: number;\n percentage: number;\n status: QuotaStatus;\n}\n\nexport interface UsageActivity {\n id: string;\n quotaName: string;\n amount: number;\n description: string;\n tags?: Record<string, unknown>;\n timestamp: string;\n}\n\nexport interface UsageDashboard {\n totalUsage: number;\n totalQuotas: number;\n activeQuotas: number;\n healthyQuotas: number;\n warningQuotas: number;\n criticalQuotas: number;\n exhaustedQuotas: number;\n topUsageByQuota: QuotaUsageSummary[];\n recentActivities: UsageActivity[];\n overallTrends: UsageTrends;\n}\n\nexport interface BillingAccountQuotasSummary {\n billingAccountId: string;\n totalUsage: number;\n totalLimit: number;\n pooledQuotas: QuotaAssignmentUsageSummary[];\n subscriptionQuotas: QuotaAssignmentUsageSummary[];\n}\n\n// ============================================================================\n// Other Types\n// ============================================================================\n\nexport interface Product {\n id: string;\n name: string;\n url?: string;\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n}\n\nexport interface Discount {\n id: string;\n code: string;\n type: string;\n value: number;\n currency?: string;\n maxUses?: number;\n usedCount: number;\n validFrom: string;\n validUntil?: string;\n metadata?: Record<string, unknown>;\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n transactions?: Transaction[];\n}\n\nexport interface TaxRate {\n id: string;\n country: string;\n state?: string;\n rate: number;\n description?: string;\n active: boolean;\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n}\n\nexport interface BillingNotification {\n id: string;\n orgId: string;\n type: string;\n message: string;\n sentAt?: string;\n metadata?: Record<string, unknown>;\n context?: Record<string, unknown>;\n createdAt: string;\n}\n\n// ============================================================================\n// Payment Initiation Types\n// ============================================================================\n\nexport interface InitiatePaymentInput {\n billingAccountId: string;\n purchaseType: PurchaseType;\n amount: number;\n currency: string;\n planId?: string;\n addonId?: string;\n quantity?: number;\n // Multiple addons support (cart checkout)\n addonIds?: string[];\n quantities?: number[];\n creditAmount?: number;\n productId?: string;\n provider?: PaymentProviderPreference;\n // Saved card support\n paymentMethodId?: string;\n saveCard?: boolean;\n // Plan change/upgrade support\n upgradeFromSubscriptionId?: string;\n // Plan downgrade — old sub auto-renewal cancelled, runs to natural expiry\n downgradeFromSubscriptionId?: string;\n metadata?: Record<string, unknown>;\n // Auto-renewal (for plan purchases)\n autoRenew?: boolean;\n autoRenewPaymentMethodId?: string;\n}\n\nexport interface InitiatePaymentResponse {\n success: boolean;\n provider: string;\n paymentId?: string;\n clientSecret?: string;\n orderId?: string;\n razorpayKeyId?: string;\n razorpayCustomerId?: string;\n prefillName?: string;\n prefillEmail?: string;\n prefillContact?: string;\n subtotal: number;\n taxAmount: number;\n taxRate: number;\n taxType: string;\n taxBreakdown?: Record<string, unknown>;\n jurisdiction: string;\n total: number;\n currency: string;\n error?: string;\n}\n\nexport interface VerifyPaymentMethodInput {\n billingAccountId: string;\n currency: string;\n provider?: PaymentProviderPreference;\n setAsDefault?: boolean;\n metadata?: Record<string, unknown>;\n}\n\nexport interface VerifyPaymentMethodResponse {\n success: boolean;\n provider: string;\n orderId?: string;\n razorpayKeyId?: string;\n razorpayCustomerId?: string;\n clientSecret?: string;\n amount: number;\n currency: string;\n prefillName?: string;\n prefillEmail?: string;\n prefillContact?: string;\n error?: string;\n}\n\n// ============================================================================\n// Pagination Types\n// ============================================================================\n\nexport interface PaginationInput {\n page?: number;\n limit?: number;\n offset?: number;\n cursor?: string;\n}\n\nexport interface PaginatedResponse<T> {\n items: T[];\n page: number;\n pageSize: number;\n totalCount: number;\n totalPages: number;\n hasMore: boolean;\n}\n\nexport interface PaginatedCreditTransactions {\n creditTransactions: CreditTransaction[];\n page: number;\n pageSize: number;\n totalCount: number;\n hasMore: boolean;\n}\n\nexport interface PaginatedQuotaAssignments {\n quotaAssignments: QuotaAssignment[];\n page: number;\n pageSize: number;\n totalCount: number;\n totalPages: number;\n}\n\nexport interface PaginatedQuotaAssignmentsWithAnalytics {\n quotaAssignments: QuotaAssignmentWithAnalytics[];\n page: number;\n pageSize: number;\n totalCount: number;\n totalPages: number;\n}\n\nexport interface PaginatedUsages {\n usages: Usage[];\n page: number;\n pageSize: number;\n totalCount: number;\n totalPages: number;\n}\n\n// ============================================================================\n// Input Types\n// ============================================================================\n\nexport interface CreateBillingAccountInput {\n name: string;\n email: string;\n billingEmail?: string;\n currency?: string;\n taxId?: string;\n metadata?: Record<string, unknown>;\n}\n\nexport interface UpdateBillingAccountInput {\n id: string;\n name?: string;\n email?: string;\n billingEmail?: string;\n currency?: string;\n taxId?: string;\n isActive?: boolean;\n metadata?: Record<string, unknown>;\n}\n\nexport interface CreatePaymentMethodInput {\n billingAccountId: string;\n type: PaymentMethodType;\n brand?: string;\n last4?: string;\n expiryMonth?: number;\n expiryYear?: number;\n isDefault?: boolean;\n stripePaymentMethodId?: string;\n razorpayPaymentMethodId?: string;\n metadata?: Record<string, unknown>;\n}\n\nexport interface SetBillingAddressInput {\n billingAccountId: string;\n line1: string;\n line2?: string;\n city: string;\n state?: string;\n postalCode: string;\n country: string;\n metadata?: Record<string, unknown>;\n}\n\nexport interface CreatePlanInput {\n productId: string;\n name: string;\n price: number;\n currency?: string;\n duration: PlanDuration;\n isPurchasable?: boolean;\n quotas: { quotaId: string; quantity: number }[];\n geoPricingOverrides?: GeoPricingOverrideInput[];\n currencyPriceOverrides?: CurrencyPriceOverrideInput[];\n}\n\nexport interface UpdatePlanInput {\n id: string;\n name?: string;\n price?: number;\n currency?: string;\n duration?: PlanDuration;\n isActive?: boolean;\n isPurchasable?: boolean;\n quotas: { quotaId: string; quantity: number }[];\n geoPricingOverrides?: GeoPricingOverrideInput[];\n currencyPriceOverrides?: CurrencyPriceOverrideInput[];\n}\n\nexport interface GeoPricingOverrideInput {\n country?: string;\n state?: string;\n region?: string;\n currency: string;\n amount?: number;\n perSeatAmount?: number;\n}\n\nexport interface CurrencyPriceOverrideInput {\n currency: string;\n amount: number;\n perSeatAmount?: number;\n}\n\nexport interface CreateAddonInput {\n productId: string;\n name: string;\n price: number;\n currency: string;\n duration: PlanDuration;\n quotas: { quotaId: string; quantity: number }[];\n geoPricingOverrides?: GeoPricingOverrideInput[];\n currencyPriceOverrides?: CurrencyPriceOverrideInput[];\n requiresPaidSubscription?: boolean;\n}\n\nexport interface UpdateAddonInput {\n id: string;\n name?: string;\n price?: number;\n currency?: string;\n duration?: PlanDuration;\n isActive?: boolean;\n requiresPaidSubscription?: boolean;\n quotas: { quotaId: string; quantity: number }[];\n geoPricingOverrides?: GeoPricingOverrideInput[];\n currencyPriceOverrides?: CurrencyPriceOverrideInput[];\n}\n\nexport interface CreateQuotaInput {\n name: string;\n limits: Record<string, unknown>;\n quotaType?: QuotaType;\n reusable: boolean;\n resetPeriod?: QuotaResetPeriod;\n context?: Record<string, unknown>;\n}\n\nexport interface UpdateQuotaInput {\n id: string;\n name?: string;\n limits?: Record<string, unknown>;\n reusable?: boolean;\n isActive: boolean;\n resetPeriod?: QuotaResetPeriod;\n context?: Record<string, unknown>;\n}\n\nexport interface SpendCreditsInput {\n billingAccountId: string;\n planId?: string;\n storeItemId?: string;\n isAnnual?: boolean;\n addOnIds?: { id: string; quantity?: number }[];\n upgradeFromSubscriptionId?: string;\n subscriptionId?: string;\n /** Seat count for PER_SEAT plans. Credits charged = pricePerSeat × seatCount. */\n seatCount?: number;\n}\n\nexport interface CancelSubscriptionInput {\n billingAccountId: string;\n subscriptionId: string;\n reason?: string;\n canceledBy?: string;\n}\n\nexport interface UpdateSubscriptionSeatsInput {\n subscriptionId: string;\n seatCount: number;\n}\n\nexport interface CreateEntitlementInput {\n planId: string;\n itemId: string;\n accessType: EntitlementAccessType;\n discountPercentage?: number;\n}\n\nexport interface UpdateEntitlementInput {\n id: string;\n accessType?: EntitlementAccessType;\n discountPercentage?: number;\n}\n\n// ============================================================================\n// Filter & Sort Types\n// ============================================================================\n\nexport interface DateRangeInput {\n from?: string;\n to?: string;\n}\n\nexport interface AmountRangeInput {\n min?: number;\n max?: number;\n}\n\nexport interface ContextFilterInput {\n orgId?: string;\n userId?: string;\n workspaceId?: string;\n organizationId?: string;\n projectId?: string;\n}\n\nexport interface ContextInput {\n orgId?: string;\n userId?: string;\n workspaceId?: string;\n organizationId?: string;\n projectId?: string;\n custom?: Record<string, unknown>;\n}\n"],"mappings":";AASA,IAAY,IAAL,yBAAA,GAAA;QACL,EAAA,SAAA,UACA,EAAA,WAAA,YACA,EAAA,UAAA,WACA,EAAA,WAAA;AACF,EAAA,CAAA,CAAA,GAEY,IAAL,yBAAA,GAAA;QACL,EAAA,QAAA,SACA,EAAA,OAAA,QACA,EAAA,OAAA,QACA,EAAA,OAAA,QACA,EAAA,gBAAA;AACF,EAAA,CAAA,CAAA,GAkCY,IAAL,yBAAA,GAAA;QACL,EAAA,UAAA,WACA,EAAA,SAAA;AACF,EAAA,CAAA,CAAA,GAEY,IAAL,yBAAA,GAAA;QACL,EAAA,YAAA,aACA,EAAA,WAAA;AACF,EAAA,CAAA,CAAA,GAEY,IAAL,yBAAA,GAAA;QACL,EAAA,SAAA,UACA,EAAA,mBAAA;AACF,EAAA,CAAA,CAAA,GAOY,IAAL,yBAAA,GAAA;QACL,EAAA,QAAA,SACA,EAAA,QAAA,SACA,EAAA,UAAA;AACF,EAAA,CAAA,CAAA,GAEY,IAAL,yBAAA,GAAA;QACL,EAAA,UAAA,WACA,EAAA,UAAA,WACA,EAAA,WAAA,YACA,EAAA,YAAA,aACA,EAAA,WAAA;AACF,EAAA,CAAA,CAAA,GAQY,IAAL,yBAAA,GAAA;QACL,EAAA,UAAA,WACA,EAAA,UAAA,WACA,EAAA,SAAA;AACF,EAAA,CAAA,CAAA,GAEY,IAAL,yBAAA,GAAA;QACL,EAAA,WAAA,YACA,EAAA,QAAA,SACA,EAAA,aAAA,cACA,EAAA,UAAA;AACF,EAAA,CAAA,CAAA,GAEY,IAAL,yBAAA,GAAA;QACL,EAAA,UAAA,WACA,EAAA,UAAA,WACA,EAAA,SAAA,UACA,EAAA,SAAA;AACF,EAAA,CAAA,CAAA,GAaY,IAAL,yBAAA,GAAA;QACL,EAAA,OAAA,QACA,EAAA,SAAA,UACA,EAAA,WAAA;AACF,EAAA,CAAA,CAAA,GAEY,IAAL,yBAAA,GAAA;QACL,EAAA,cAAA,eACA,EAAA,eAAA,gBACA,EAAA,eAAA,gBACA,EAAA,aAAA,cACA,EAAA,gBAAA;AACF,EAAA,CAAA,CAAA"}
|
|
1
|
+
{"version":3,"file":"graphql.js","names":["SubscriptionStatus","\"ACTIVE\"","\"CANCELED\"","\"EXPIRED\"","\"UPGRADED\"","InvoiceStatus","\"DRAFT\"","\"OPEN\"","\"PAID\"","\"VOID\"","\"UNCOLLECTIBLE\"","PlanDuration","\"MONTHLY\"","\"YEARLY\"","PricingModel","\"FLAT_RATE\"","\"PER_SEAT\"","QuotaType","\"POOLED\"","\"PRODUCT_SPECIFIC\"","QuotaResetPeriod","\"NEVER\"","\"DAILY\"","QuotaStatus","\"HEALTHY\"","\"WARNING\"","\"CRITICAL\"","\"EXHAUSTED\"","\"INACTIVE\"","TransactionStatus","\"PENDING\"","\"SUCCESS\"","\"FAILED\"","CreditTransactionType","\"PURCHASE\"","\"USAGE\"","\"ADJUSTMENT\"","\"GRANTED\"","CreditTransactionStatus","\"REFUND\"","PaymentProviderPreference","\"AUTO\"","\"STRIPE\"","\"RAZORPAY\"","AnalyticsPeriod","\"LAST_7_DAYS\"","\"LAST_30_DAYS\"","\"LAST_90_DAYS\"","\"LAST_MONTH\"","\"CURRENT_MONTH\""],"sources":["../../../../src/billing/shared/types/graphql.ts"],"sourcesContent":["/**\n * GraphQL Types for Billing Module\n * Auto-generated types matching the backend billing service schema\n */\n\n// ============================================================================\n// Enums\n// ============================================================================\n\nexport enum SubscriptionStatus {\n ACTIVE = 'active',\n CANCELED = 'canceled',\n EXPIRED = 'expired',\n UPGRADED = 'upgraded',\n}\n\nexport enum InvoiceStatus {\n DRAFT = 'DRAFT',\n OPEN = 'OPEN',\n PAID = 'PAID',\n VOID = 'VOID',\n UNCOLLECTIBLE = 'UNCOLLECTIBLE',\n}\n\nexport enum PaymentStatus {\n PENDING = 'PENDING',\n SUCCEEDED = 'SUCCEEDED',\n FAILED = 'FAILED',\n CANCELED = 'CANCELED',\n REFUNDED = 'REFUNDED',\n}\n\nexport enum ChargeStatus {\n PENDING = 'PENDING',\n SUCCEEDED = 'SUCCEEDED',\n FAILED = 'FAILED',\n REFUNDED = 'REFUNDED',\n}\n\nexport enum RefundStatus {\n PENDING = 'PENDING',\n SUCCEEDED = 'SUCCEEDED',\n FAILED = 'FAILED',\n CANCELED = 'CANCELED',\n}\n\nexport enum PaymentMethodType {\n CREDIT_CARD = 'CREDIT_CARD',\n DEBIT_CARD = 'DEBIT_CARD',\n BANK_TRANSFER = 'BANK_TRANSFER',\n PAYPAL = 'PAYPAL',\n CRYPTO = 'CRYPTO',\n WALLET = 'WALLET',\n NETBANKING = 'NETBANKING',\n}\n\nexport enum PlanDuration {\n MONTHLY = 'monthly',\n YEARLY = 'yearly',\n}\n\nexport enum PricingModel {\n FLAT_RATE = 'FLAT_RATE',\n PER_SEAT = 'PER_SEAT',\n}\n\nexport enum QuotaType {\n POOLED = 'POOLED',\n PRODUCT_SPECIFIC = 'PRODUCT_SPECIFIC',\n}\n\nexport enum QuotaScope {\n WORKSPACE = 'WORKSPACE',\n GLOBAL = 'GLOBAL',\n}\n\nexport enum QuotaResetPeriod {\n NEVER = 'NEVER',\n DAILY = 'DAILY',\n MONTHLY = 'MONTHLY',\n}\n\nexport enum QuotaStatus {\n HEALTHY = 'HEALTHY',\n WARNING = 'WARNING',\n CRITICAL = 'CRITICAL',\n EXHAUSTED = 'EXHAUSTED',\n INACTIVE = 'INACTIVE',\n}\n\nexport enum TransactionType {\n PAYMENT = 'payment',\n REFUND = 'refund',\n ADJUSTMENT = 'adjustment',\n}\n\nexport enum TransactionStatus {\n PENDING = 'pending',\n SUCCESS = 'success',\n FAILED = 'failed',\n}\n\nexport enum CreditTransactionType {\n PURCHASE = 'purchase',\n USAGE = 'usage',\n ADJUSTMENT = 'adjustment',\n GRANTED = 'granted',\n}\n\nexport enum CreditTransactionStatus {\n PENDING = 'pending',\n SUCCESS = 'success',\n FAILED = 'failed',\n REFUND = 'refund',\n}\n\nexport enum EntitlementAccessType {\n FREE_ACCESS = 'FREE_ACCESS',\n DISCOUNT = 'DISCOUNT',\n}\n\nexport enum PurchaseType {\n PLAN = 'PLAN',\n ADDON = 'ADDON',\n CREDITS = 'CREDITS',\n}\n\nexport enum PaymentProviderPreference {\n AUTO = 'AUTO',\n STRIPE = 'STRIPE',\n RAZORPAY = 'RAZORPAY',\n}\n\nexport enum AnalyticsPeriod {\n LAST_7_DAYS = 'LAST_7_DAYS',\n LAST_30_DAYS = 'LAST_30_DAYS',\n LAST_90_DAYS = 'LAST_90_DAYS',\n LAST_MONTH = 'LAST_MONTH',\n CURRENT_MONTH = 'CURRENT_MONTH',\n}\n\nexport enum UsageMetricType {\n USERS = 'USERS',\n STORAGE = 'STORAGE',\n API_CALLS = 'API_CALLS',\n BANDWIDTH = 'BANDWIDTH',\n REQUESTS = 'REQUESTS',\n COMPUTE_HOURS = 'COMPUTE_HOURS',\n TRANSACTIONS = 'TRANSACTIONS',\n CUSTOM = 'CUSTOM',\n}\n\n// ============================================================================\n// Core Types\n// ============================================================================\n\nexport interface BillingAccount {\n id: string;\n orgId: string;\n name: string;\n email: string;\n billingEmail?: string;\n currency: string;\n creditAmount: number;\n stripeCustomerId?: string;\n razorpayCustomerId?: string;\n defaultPaymentMethod?: string;\n taxId?: string;\n isActive: boolean;\n isDefault?: boolean;\n metadata?: Record<string, unknown>;\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n // Relations\n subscriptions?: BillingSubscription[];\n paymentMethods?: PaymentMethod[];\n creditTransactions?: CreditTransaction[];\n quotaAssignments?: QuotaAssignment[];\n billingAddresses?: BillingAddress[];\n transactions?: Transaction[];\n}\n\nexport interface BillingAddress {\n id: string;\n billingAccountId: string;\n orgId: string;\n line1: string;\n line2?: string;\n city: string;\n state?: string;\n postalCode: string;\n country: string;\n metadata?: Record<string, unknown>;\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n}\n\n// ============================================================================\n// Plan Types\n// ============================================================================\n\nexport interface Plan {\n id: string;\n productID: string;\n name: string;\n price: number;\n currency: string;\n currencyPrices?: Record<string, number>;\n geoPricingOverrides?: GeoPricingOverrideInput[];\n duration: PlanDuration;\n pricingModel?: PricingModel;\n pricePerSeat?: number;\n minSeats?: number;\n maxSeats?: number;\n /** Max distinct workspaces one subscription to this plan can activate its\n * WORKSPACE-scoped quotas against (each gets the full allotment, not\n * divided). Unset/null = today's implicit single-workspace behavior. */\n maxWorkspaces?: number;\n isActive: boolean;\n isPurchasable: boolean;\n features?: SubscriptionFeatures[];\n itemEntitlements?: SubscriptionEntitlement[];\n subscriptions?: BillingSubscription[];\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n // Relations\n product?: Product;\n}\n\nexport interface SubscriptionFeatures {\n id: string;\n planId?: string;\n addonId?: string;\n quotaId?: string;\n plan?: Plan;\n addon?: Addon;\n quota?: Quota;\n context?: Record<string, unknown>;\n}\n\nexport interface SubscriptionEntitlement {\n id: string;\n planId: string;\n itemId: string;\n accessType: EntitlementAccessType;\n discountPercentage?: number;\n plan?: Plan;\n item?: { id: string };\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n}\n\n// ============================================================================\n// Subscription Types\n// ============================================================================\n\nexport interface BillingSubscription {\n id: string;\n billingAccountId: string;\n planId: string;\n status: SubscriptionStatus;\n startDate: string;\n endDate: string;\n autoRenewal: boolean;\n recurrence: boolean;\n seatCount?: number;\n lastSeatChangeAt?: string;\n lastBillingDate?: string;\n nextBillingDate?: string;\n lastRenewalDate?: string;\n canceledAt?: string;\n canceledBy?: string;\n cancellationReason?: string;\n stripeSubscriptionId?: string;\n razorpaySubscriptionId?: string;\n paymentGateway?: string;\n assignedWorkspaceId?: string | null;\n activatedWorkspaceIds?: string[];\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n // Relations\n plan?: Plan;\n billingAccount?: BillingAccount;\n addonSubscriptions?: AddonSubscription[];\n quotas?: QuotaAssignment[];\n transactions?: Transaction[];\n history?: SubscriptionHistory[];\n}\n\nexport interface SubscriptionHistory {\n id: string;\n subscriptionId: string;\n fromStatus: SubscriptionStatus;\n toStatus: SubscriptionStatus;\n reason?: string;\n metadata?: Record<string, unknown>;\n context?: Record<string, unknown>;\n createdAt: string;\n}\n\n// ============================================================================\n// Addon Types\n// ============================================================================\n\nexport interface Addon {\n id: string;\n productID: string;\n name: string;\n price: number;\n currency: string;\n currencyPrices?: Record<string, number>;\n geoPricingOverrides?: GeoPricingOverrideInput[];\n duration: PlanDuration;\n isActive: boolean;\n /** BOFF-9889: buying it needs a paid subscription to its product. */\n requiresPaidSubscription?: boolean | null;\n features?: SubscriptionFeatures[];\n addonSubscriptions?: AddonSubscription[];\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n // Relations\n product?: Product;\n}\n\nexport interface AddonSubscription {\n id: string;\n addonId: string;\n currentSubscriptionId: string;\n quantity: number;\n startDate: string;\n endDate: string;\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n // Relations\n addon?: Addon;\n currentSubscription?: BillingSubscription;\n}\n\n// ============================================================================\n// Invoice Types\n// ============================================================================\n\nexport interface Invoice {\n id: string;\n orgId: string;\n billingAccountId?: string;\n subscriptionId?: string;\n paymentId?: string;\n invoiceNumber: string;\n status: InvoiceStatus;\n subtotal: number;\n tax: number;\n total: number;\n amountPaid: number;\n currency: string;\n dueDate?: string;\n paidAt?: string;\n gatewayInvoiceId?: string;\n invoiceUrl?: string;\n pdfUrl?: string;\n itemDescription?: string;\n metadata?: Record<string, unknown>;\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n // Relations\n items: InvoiceItem[];\n subscription?: BillingSubscription;\n payment?: Payment;\n}\n\nexport interface InvoiceItem {\n id: string;\n invoiceId: string;\n description: string;\n quantity: number;\n unitPrice: number;\n amount: number;\n metadata?: Record<string, unknown>;\n context?: Record<string, unknown>;\n}\n\n// ============================================================================\n// Payment Types\n// ============================================================================\n\nexport interface Payment {\n id: string;\n orgId: string;\n transactionId?: string;\n amount: number;\n currency: string;\n status: PaymentStatus;\n method: PaymentMethodType;\n provider?: string;\n gatewayPaymentId?: string;\n gatewayOrderId?: string;\n failureReason?: string;\n paidAt?: string;\n metadata?: Record<string, unknown>;\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n // Relations\n invoice?: Invoice;\n}\n\nexport interface PaymentMethod {\n id: string;\n orgId: string;\n billingAccountId?: string;\n type: PaymentMethodType;\n brand?: string;\n last4?: string;\n expiryMonth?: number;\n expiryYear?: number;\n isDefault: boolean;\n isVerified: boolean;\n verifiedAt?: string;\n stripeCustomerId?: string;\n stripePaymentMethodId?: string;\n razorpayCustomerId?: string;\n razorpayPaymentMethodId?: string;\n metadata?: Record<string, unknown>;\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n // Relations\n billingAccount?: BillingAccount;\n transactions?: Transaction[];\n}\n\nexport interface Charge {\n id: string;\n orgId: string;\n amount: number;\n currency: string;\n status: ChargeStatus;\n description?: string;\n provider?: string;\n gatewayChargeId?: string;\n gatewayPaymentId?: string;\n metadata?: Record<string, unknown>;\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n // Relations\n refunds: Refund[];\n}\n\nexport interface Refund {\n id: string;\n chargeId: string;\n amount: number;\n currency: string;\n status: RefundStatus;\n reason?: string;\n provider?: string;\n gatewayRefundId?: string;\n processedAt?: string;\n metadata?: Record<string, unknown>;\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n // Relations\n charge?: Charge;\n}\n\n// ============================================================================\n// Transaction Types\n// ============================================================================\n\nexport interface Transaction {\n id: string;\n billingAccountId: string;\n amount: number;\n currency: string;\n type: TransactionType;\n status: TransactionStatus;\n description?: string;\n stripePaymentId?: string;\n razorpayPaymentId?: string;\n metadata?: Record<string, unknown>;\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n}\n\n// ============================================================================\n// Credit Types\n// ============================================================================\n\nexport interface CreditTransaction {\n id: string;\n billingAccountId: string;\n productId: string;\n amount: number;\n type: CreditTransactionType;\n status: CreditTransactionStatus;\n fromType?: CreditTransactionType | null;\n payoutRequestId?: string | null;\n entityType?: string;\n entityId?: string;\n transactionId?: string;\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n // Relations\n billingAccount?: BillingAccount;\n transaction?: Transaction;\n}\n\nexport interface CreditBalanceByType {\n purchased: number;\n earned: number;\n granted: number;\n withdrawable: number;\n total: number;\n}\n\nexport interface CreditNote {\n id: string;\n orgId: string;\n invoiceId?: string;\n number: string;\n amount: number;\n currency: string;\n reason?: string;\n metadata?: Record<string, unknown>;\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n}\n\nexport interface CreditRate {\n id: string;\n rateUSD: number;\n effectiveFrom: string;\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n}\n\n// ============================================================================\n// Quota Types\n// ============================================================================\n\nexport interface Quota {\n id: string;\n name: string;\n limits: Record<string, unknown>;\n quotaType: QuotaType;\n reusable: boolean;\n resetPeriod: QuotaResetPeriod;\n isActive: boolean;\n scope?: QuotaScope;\n subscriptions?: SubscriptionFeatures[];\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n}\n\nexport interface QuotaAssignment {\n id: string;\n billingAccountId?: string;\n subscriptionId?: string;\n name: string;\n limits: Record<string, unknown>;\n quotaType: QuotaType;\n reusable: boolean;\n currentUsageSum: number;\n totalUsageCount: number;\n endtime: string;\n context?: Record<string, unknown>;\n createdAt: string;\n // Relations\n billingAccount?: BillingAccount;\n subscription?: BillingSubscription;\n usages?: Usage[];\n recentUsages?: Usage[];\n usageAnalytics?: QuotaUsageAnalytics;\n}\n\nexport interface QuotaAssignmentWithAnalytics extends QuotaAssignment {\n status: QuotaStatus;\n healthScore: number;\n usagePercentage: number;\n limitLeft: number;\n analytics: QuotaUsageAnalytics;\n}\n\nexport interface QuotaAssignmentUsageSummary {\n id: string;\n name: string;\n quotaType: QuotaType;\n reusable: boolean;\n limit: number;\n limitLeft: number;\n used: number;\n usagePercentage: number;\n noLimit: boolean;\n subscriptionId?: string;\n recentUsages: Usage[];\n createdAt: string;\n endtime: string;\n}\n\n// ============================================================================\n// Usage Types\n// ============================================================================\n\nexport interface Usage {\n id: string;\n quotaAssignmentId: string;\n userId?: string;\n productId?: string;\n amount: number;\n description?: string;\n tags?: Record<string, unknown>;\n timestamp: string;\n lastUpdated: string;\n context?: Record<string, unknown>;\n // Relations\n quotaAssignment?: QuotaAssignment;\n user?: { id: string };\n}\n\nexport interface UsageRecord {\n id: string;\n orgId: string;\n subscriptionId?: string;\n metricType: UsageMetricType;\n quantity: number;\n unitCost?: number;\n totalCost?: number;\n timestamp: string;\n metadata?: Record<string, unknown>;\n context?: Record<string, unknown>;\n createdAt: string;\n}\n\nexport interface DailyUsage {\n date: string;\n usage: number;\n count: number;\n}\n\nexport interface PeakUsage {\n peakDate: string;\n maxDailyUsage: number;\n peakHour?: number;\n}\n\nexport interface UsageTrends {\n averageDailyUsage?: number;\n growthRate?: number;\n predictedUsage?: number;\n}\n\nexport interface UsageByType {\n resourceType: string;\n usage: number;\n count: number;\n percentage: number;\n}\n\nexport interface QuotaUsageAnalytics {\n dailyUsage: DailyUsage[];\n usageByType: UsageByType[];\n peakUsage?: PeakUsage;\n trends?: UsageTrends;\n}\n\nexport interface QuotaUsageSummary {\n quotaId: string;\n quotaName: string;\n usage: number;\n limit: number;\n percentage: number;\n status: QuotaStatus;\n}\n\nexport interface UsageActivity {\n id: string;\n quotaName: string;\n amount: number;\n description: string;\n tags?: Record<string, unknown>;\n timestamp: string;\n}\n\nexport interface UsageDashboard {\n totalUsage: number;\n totalQuotas: number;\n activeQuotas: number;\n healthyQuotas: number;\n warningQuotas: number;\n criticalQuotas: number;\n exhaustedQuotas: number;\n topUsageByQuota: QuotaUsageSummary[];\n recentActivities: UsageActivity[];\n overallTrends: UsageTrends;\n}\n\nexport interface BillingAccountQuotasSummary {\n billingAccountId: string;\n totalUsage: number;\n totalLimit: number;\n pooledQuotas: QuotaAssignmentUsageSummary[];\n subscriptionQuotas: QuotaAssignmentUsageSummary[];\n}\n\n// ============================================================================\n// Other Types\n// ============================================================================\n\nexport interface Product {\n id: string;\n name: string;\n url?: string;\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n}\n\nexport interface Discount {\n id: string;\n code: string;\n type: string;\n value: number;\n currency?: string;\n maxUses?: number;\n usedCount: number;\n validFrom: string;\n validUntil?: string;\n metadata?: Record<string, unknown>;\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n transactions?: Transaction[];\n}\n\nexport interface TaxRate {\n id: string;\n country: string;\n state?: string;\n rate: number;\n description?: string;\n active: boolean;\n context?: Record<string, unknown>;\n createdAt: string;\n updatedAt: string;\n}\n\nexport interface BillingNotification {\n id: string;\n orgId: string;\n type: string;\n message: string;\n sentAt?: string;\n metadata?: Record<string, unknown>;\n context?: Record<string, unknown>;\n createdAt: string;\n}\n\n// ============================================================================\n// Payment Initiation Types\n// ============================================================================\n\nexport interface InitiatePaymentInput {\n billingAccountId: string;\n purchaseType: PurchaseType;\n amount: number;\n currency: string;\n planId?: string;\n addonId?: string;\n quantity?: number;\n // Multiple addons support (cart checkout)\n addonIds?: string[];\n quantities?: number[];\n creditAmount?: number;\n productId?: string;\n provider?: PaymentProviderPreference;\n // Saved card support\n paymentMethodId?: string;\n saveCard?: boolean;\n // Plan change/upgrade support\n upgradeFromSubscriptionId?: string;\n // Plan downgrade — old sub auto-renewal cancelled, runs to natural expiry\n downgradeFromSubscriptionId?: string;\n metadata?: Record<string, unknown>;\n // Auto-renewal (for plan purchases)\n autoRenew?: boolean;\n autoRenewPaymentMethodId?: string;\n}\n\nexport interface InitiatePaymentResponse {\n success: boolean;\n provider: string;\n paymentId?: string;\n clientSecret?: string;\n orderId?: string;\n razorpayKeyId?: string;\n razorpayCustomerId?: string;\n prefillName?: string;\n prefillEmail?: string;\n prefillContact?: string;\n subtotal: number;\n taxAmount: number;\n taxRate: number;\n taxType: string;\n taxBreakdown?: Record<string, unknown>;\n jurisdiction: string;\n total: number;\n currency: string;\n error?: string;\n}\n\nexport interface VerifyPaymentMethodInput {\n billingAccountId: string;\n currency: string;\n provider?: PaymentProviderPreference;\n setAsDefault?: boolean;\n metadata?: Record<string, unknown>;\n}\n\nexport interface VerifyPaymentMethodResponse {\n success: boolean;\n provider: string;\n orderId?: string;\n razorpayKeyId?: string;\n razorpayCustomerId?: string;\n clientSecret?: string;\n amount: number;\n currency: string;\n prefillName?: string;\n prefillEmail?: string;\n prefillContact?: string;\n error?: string;\n}\n\n// ============================================================================\n// Pagination Types\n// ============================================================================\n\nexport interface PaginationInput {\n page?: number;\n limit?: number;\n offset?: number;\n cursor?: string;\n}\n\nexport interface PaginatedResponse<T> {\n items: T[];\n page: number;\n pageSize: number;\n totalCount: number;\n totalPages: number;\n hasMore: boolean;\n}\n\nexport interface PaginatedCreditTransactions {\n creditTransactions: CreditTransaction[];\n page: number;\n pageSize: number;\n totalCount: number;\n hasMore: boolean;\n}\n\nexport interface PaginatedQuotaAssignments {\n quotaAssignments: QuotaAssignment[];\n page: number;\n pageSize: number;\n totalCount: number;\n totalPages: number;\n}\n\nexport interface PaginatedQuotaAssignmentsWithAnalytics {\n quotaAssignments: QuotaAssignmentWithAnalytics[];\n page: number;\n pageSize: number;\n totalCount: number;\n totalPages: number;\n}\n\nexport interface PaginatedUsages {\n usages: Usage[];\n page: number;\n pageSize: number;\n totalCount: number;\n totalPages: number;\n}\n\n// ============================================================================\n// Input Types\n// ============================================================================\n\nexport interface CreateBillingAccountInput {\n name: string;\n email: string;\n billingEmail?: string;\n currency?: string;\n taxId?: string;\n metadata?: Record<string, unknown>;\n}\n\nexport interface UpdateBillingAccountInput {\n id: string;\n name?: string;\n email?: string;\n billingEmail?: string;\n currency?: string;\n taxId?: string;\n isActive?: boolean;\n metadata?: Record<string, unknown>;\n}\n\nexport interface CreatePaymentMethodInput {\n billingAccountId: string;\n type: PaymentMethodType;\n brand?: string;\n last4?: string;\n expiryMonth?: number;\n expiryYear?: number;\n isDefault?: boolean;\n stripePaymentMethodId?: string;\n razorpayPaymentMethodId?: string;\n metadata?: Record<string, unknown>;\n}\n\nexport interface SetBillingAddressInput {\n billingAccountId: string;\n line1: string;\n line2?: string;\n city: string;\n state?: string;\n postalCode: string;\n country: string;\n metadata?: Record<string, unknown>;\n}\n\nexport interface CreatePlanInput {\n productId: string;\n name: string;\n price: number;\n currency?: string;\n duration: PlanDuration;\n isPurchasable?: boolean;\n quotas: { quotaId: string; quantity: number }[];\n geoPricingOverrides?: GeoPricingOverrideInput[];\n currencyPriceOverrides?: CurrencyPriceOverrideInput[];\n}\n\nexport interface UpdatePlanInput {\n id: string;\n name?: string;\n price?: number;\n currency?: string;\n duration?: PlanDuration;\n isActive?: boolean;\n isPurchasable?: boolean;\n quotas: { quotaId: string; quantity: number }[];\n geoPricingOverrides?: GeoPricingOverrideInput[];\n currencyPriceOverrides?: CurrencyPriceOverrideInput[];\n}\n\nexport interface GeoPricingOverrideInput {\n country?: string;\n state?: string;\n region?: string;\n currency: string;\n amount?: number;\n perSeatAmount?: number;\n}\n\nexport interface CurrencyPriceOverrideInput {\n currency: string;\n amount: number;\n perSeatAmount?: number;\n}\n\nexport interface CreateAddonInput {\n productId: string;\n name: string;\n price: number;\n currency: string;\n duration: PlanDuration;\n quotas: { quotaId: string; quantity: number }[];\n geoPricingOverrides?: GeoPricingOverrideInput[];\n currencyPriceOverrides?: CurrencyPriceOverrideInput[];\n requiresPaidSubscription?: boolean;\n}\n\nexport interface UpdateAddonInput {\n id: string;\n name?: string;\n price?: number;\n currency?: string;\n duration?: PlanDuration;\n isActive?: boolean;\n requiresPaidSubscription?: boolean;\n quotas: { quotaId: string; quantity: number }[];\n geoPricingOverrides?: GeoPricingOverrideInput[];\n currencyPriceOverrides?: CurrencyPriceOverrideInput[];\n}\n\nexport interface CreateQuotaInput {\n name: string;\n limits: Record<string, unknown>;\n quotaType?: QuotaType;\n reusable: boolean;\n resetPeriod?: QuotaResetPeriod;\n context?: Record<string, unknown>;\n}\n\nexport interface UpdateQuotaInput {\n id: string;\n name?: string;\n limits?: Record<string, unknown>;\n reusable?: boolean;\n isActive: boolean;\n resetPeriod?: QuotaResetPeriod;\n context?: Record<string, unknown>;\n}\n\nexport interface SpendCreditsInput {\n billingAccountId: string;\n planId?: string;\n storeItemId?: string;\n isAnnual?: boolean;\n addOnIds?: { id: string; quantity?: number }[];\n upgradeFromSubscriptionId?: string;\n subscriptionId?: string;\n /** Seat count for PER_SEAT plans. Credits charged = pricePerSeat × seatCount. */\n seatCount?: number;\n}\n\nexport interface CancelSubscriptionInput {\n billingAccountId: string;\n subscriptionId: string;\n reason?: string;\n canceledBy?: string;\n}\n\nexport interface UpdateSubscriptionSeatsInput {\n subscriptionId: string;\n seatCount: number;\n}\n\nexport interface CreateEntitlementInput {\n planId: string;\n itemId: string;\n accessType: EntitlementAccessType;\n discountPercentage?: number;\n}\n\nexport interface UpdateEntitlementInput {\n id: string;\n accessType?: EntitlementAccessType;\n discountPercentage?: number;\n}\n\n// ============================================================================\n// Filter & Sort Types\n// ============================================================================\n\nexport interface DateRangeInput {\n from?: string;\n to?: string;\n}\n\nexport interface AmountRangeInput {\n min?: number;\n max?: number;\n}\n\nexport interface ContextFilterInput {\n orgId?: string;\n userId?: string;\n workspaceId?: string;\n organizationId?: string;\n projectId?: string;\n}\n\nexport interface ContextInput {\n orgId?: string;\n userId?: string;\n workspaceId?: string;\n organizationId?: string;\n projectId?: string;\n custom?: Record<string, unknown>;\n}\n"],"mappings":";AASA,IAAYA,IAAL,yBAAA,GAAA;C,OACL,EAAAC,SAAA,UACA,EAAAC,WAAA,YACA,EAAAC,UAAA,WACA,EAAAC,WAAA,Y;AACF,EAAA,CAAA,CAAA,GAEYC,IAAL,yBAAA,GAAA;C,OACL,EAAAC,QAAA,SACA,EAAAC,OAAA,QACA,EAAAC,OAAA,QACA,EAAAC,OAAA,QACA,EAAAC,gBAAA,iB;AACF,EAAA,CAAA,CAAA,GAkCYC,IAAL,yBAAA,GAAA;C,OACL,EAAAC,UAAA,WACA,EAAAC,SAAA,U;AACF,EAAA,CAAA,CAAA,GAEYC,IAAL,yBAAA,GAAA;C,OACL,EAAAC,YAAA,aACA,EAAAC,WAAA,Y;AACF,EAAA,CAAA,CAAA,GAEYC,IAAL,yBAAA,GAAA;C,OACL,EAAAC,SAAA,UACA,EAAAC,mBAAA,oB;AACF,EAAA,CAAA,CAAA,GAOYC,IAAL,yBAAA,GAAA;C,OACL,EAAAC,QAAA,SACA,EAAAC,QAAA,SACA,EAAAV,UAAA,W;AACF,EAAA,CAAA,CAAA,GAEYW,IAAL,yBAAA,GAAA;C,OACL,EAAAC,UAAA,WACA,EAAAC,UAAA,WACA,EAAAC,WAAA,YACA,EAAAC,YAAA,aACA,EAAAC,WAAA,Y;AACF,EAAA,CAAA,CAAA,GAQYC,IAAL,yBAAA,GAAA;C,OACL,EAAAC,UAAA,WACA,EAAAC,UAAA,WACA,EAAAC,SAAA,U;AACF,EAAA,CAAA,CAAA,GAEYC,IAAL,yBAAA,GAAA;C,OACL,EAAAC,WAAA,YACA,EAAAC,QAAA,SACA,EAAAC,aAAA,cACA,EAAAC,UAAA,W;AACF,EAAA,CAAA,CAAA,GAEYC,IAAL,yBAAA,GAAA;C,OACL,EAAAR,UAAA,WACA,EAAAC,UAAA,WACA,EAAAC,SAAA,UACA,EAAAO,SAAA,U;AACF,EAAA,CAAA,CAAA,GAaYC,IAAL,yBAAA,GAAA;C,OACL,EAAAC,OAAA,QACA,EAAAC,SAAA,UACA,EAAAC,WAAA,Y;AACF,EAAA,CAAA,CAAA,GAEYC,IAAL,yBAAA,GAAA;C,OACL,EAAAC,cAAA,eACA,EAAAC,eAAA,gBACA,EAAAC,eAAA,gBACA,EAAAC,aAAA,cACA,EAAAC,gBAAA,iB;AACF,EAAA,CAAA,CAAA"}
|
|
@@ -12,6 +12,5 @@ interface CardProps {
|
|
|
12
12
|
/** Passthrough for data-tour and other data-* hooks. */
|
|
13
13
|
[key: `data-${string}`]: string | undefined;
|
|
14
14
|
}
|
|
15
|
-
export declare function Card({ children, className, interactive, selected, as, onClick, ...rest }: CardProps): import(
|
|
15
|
+
export declare function Card({ children, className, interactive, selected, as, onClick, ...rest }: CardProps): import('react').JSX.Element;
|
|
16
16
|
export {};
|
|
17
|
-
//# sourceMappingURL=Card.d.ts.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as e } from "react/jsx-runtime";
|
|
2
2
|
import { cn as t } from "@burdenoff/fe-libs/shared/utils";
|
|
3
|
-
|
|
3
|
+
// src/billing/shared/ui/Card.tsx
|
|
4
4
|
function n({ children: n, className: r, interactive: i = !1, selected: a = !1, as: o, onClick: s, ...c }) {
|
|
5
5
|
return /* @__PURE__ */ e(o ?? "div", {
|
|
6
6
|
onClick: s,
|
|
@@ -9,7 +9,6 @@ function n({ children: n, className: r, interactive: i = !1, selected: a = !1, a
|
|
|
9
9
|
children: n
|
|
10
10
|
});
|
|
11
11
|
}
|
|
12
|
-
//#endregion
|
|
13
12
|
export { n as Card };
|
|
14
13
|
|
|
15
14
|
//# sourceMappingURL=Card.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Card.js","names":[],"sources":["../../../../src/billing/shared/ui/Card.tsx"],"sourcesContent":["/**\n * Boff UI — Card primitive\n *\n * The workhorse surface for the billing MFE. Renders the canonical Boff UI\n * card recipe: `rounded-card border border-border-subtle bg-bg-surface\n * shadow-elevation-1`. Set `interactive` for the hover-lift treatment and\n * `selected` for the accent-soft selected state.\n *\n * Visual-only primitive — no business logic.\n */\n\nimport type { ElementType, ReactNode } from 'react';\nimport { cn } from '@burdenoff/fe-libs/shared/utils';\n\ninterface CardProps {\n children: ReactNode;\n className?: string;\n /** Apply hover lift + stronger border/elevation (use for clickable cards). */\n interactive?: boolean;\n /** Apply the accent-soft selected ring/wash. */\n selected?: boolean;\n /** Render as a different element (e.g. 'section', 'article'). Defaults to 'div'. */\n as?: ElementType;\n onClick?: () => void;\n /** Passthrough for data-tour and other data-* hooks. */\n [key: `data-${string}`]: string | undefined;\n}\n\nexport function Card({\n children,\n className,\n interactive = false,\n selected = false,\n as,\n onClick,\n ...rest\n}: CardProps) {\n const Component = as ?? 'div';\n return (\n <Component\n onClick={onClick}\n className={cn(\n 'rounded-card border border-border-seam bg-bg-surface shadow-elevation-1',\n interactive &&\n 'transition-[box-shadow,transform] duration-200 ease-[var(--motion-easing-out)] shadow-[var(--shadow-pop)] hover:shadow-elevation-2 [@media(hover:none)]:',\n selected && 'ring-1 ring-[var(--color-focus-ring)] border-border-strong',\n onClick && 'cursor-pointer text-left',\n className\n )}\n {...rest}\n >\n {children}\n </Component>\n );\n}\n"],"mappings":";;;AA4BA,
|
|
1
|
+
{"version":3,"file":"Card.js","names":["Card","rest","as","cn","interactive","selected","onClick","className"],"sources":["../../../../src/billing/shared/ui/Card.tsx"],"sourcesContent":["/**\n * Boff UI — Card primitive\n *\n * The workhorse surface for the billing MFE. Renders the canonical Boff UI\n * card recipe: `rounded-card border border-border-subtle bg-bg-surface\n * shadow-elevation-1`. Set `interactive` for the hover-lift treatment and\n * `selected` for the accent-soft selected state.\n *\n * Visual-only primitive — no business logic.\n */\n\nimport type { ElementType, ReactNode } from 'react';\nimport { cn } from '@burdenoff/fe-libs/shared/utils';\n\ninterface CardProps {\n children: ReactNode;\n className?: string;\n /** Apply hover lift + stronger border/elevation (use for clickable cards). */\n interactive?: boolean;\n /** Apply the accent-soft selected ring/wash. */\n selected?: boolean;\n /** Render as a different element (e.g. 'section', 'article'). Defaults to 'div'. */\n as?: ElementType;\n onClick?: () => void;\n /** Passthrough for data-tour and other data-* hooks. */\n [key: `data-${string}`]: string | undefined;\n}\n\nexport function Card({\n children,\n className,\n interactive = false,\n selected = false,\n as,\n onClick,\n ...rest\n}: CardProps) {\n const Component = as ?? 'div';\n return (\n <Component\n onClick={onClick}\n className={cn(\n 'rounded-card border border-border-seam bg-bg-surface shadow-elevation-1',\n interactive &&\n 'transition-[box-shadow,transform] duration-200 ease-[var(--motion-easing-out)] shadow-[var(--shadow-pop)] hover:shadow-elevation-2 [@media(hover:none)]:',\n selected && 'ring-1 ring-[var(--color-focus-ring)] border-border-strong',\n onClick && 'cursor-pointer text-left',\n className\n )}\n {...rest}\n >\n {children}\n </Component>\n );\n}\n"],"mappings":";;;AA4BA,SAAgBA,EAAK,EACnB,aACA,cACA,iBAAc,IACd,cAAW,IACX,OACA,YACA,GAAGC,KACS;CAEZ,OACE,kBAFgBC,KAAM,OAEtB;EACW;EACT,WAAWC,EACT,2EACAC,KACE,4JACFC,KAAY,8DACZC,KAAW,4BACXC,CACF;EACA,GAAIN;EAEH;CACQ,CAAA;AAEf"}
|
|
@@ -15,6 +15,5 @@ interface MetricCardProps {
|
|
|
15
15
|
/** Passthrough for data-tour and other data-* hooks. */
|
|
16
16
|
[key: `data-${string}`]: string | undefined;
|
|
17
17
|
}
|
|
18
|
-
export declare function MetricCard({ label, value, icon, trend, onClick, isActive, className, ...rest }: MetricCardProps): import(
|
|
18
|
+
export declare function MetricCard({ label, value, icon, trend, onClick, isActive, className, ...rest }: MetricCardProps): import('react').JSX.Element;
|
|
19
19
|
export {};
|
|
20
|
-
//# sourceMappingURL=MetricCard.d.ts.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Fragment as e, jsx as t, jsxs as n } from "react/jsx-runtime";
|
|
2
2
|
import { cn as r } from "@burdenoff/fe-libs/shared/utils";
|
|
3
3
|
import { GlassCard as i } from "@burdenoff/fe-libs/ui";
|
|
4
|
-
|
|
4
|
+
// src/billing/shared/ui/MetricCard.tsx
|
|
5
5
|
function a({ label: a, value: o, icon: s, trend: c, onClick: l, isActive: u = !1, className: d, ...f }) {
|
|
6
6
|
let p = r("p-5 text-left", l && "w-full focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--color-focus-ring)]", u && "ring-1 ring-[var(--color-focus-ring)] border-border-strong", d), m = /* @__PURE__ */ n(e, { children: [
|
|
7
7
|
/* @__PURE__ */ n("div", {
|
|
@@ -45,7 +45,6 @@ function a({ label: a, value: o, icon: s, trend: c, onClick: l, isActive: u = !1
|
|
|
45
45
|
children: m
|
|
46
46
|
});
|
|
47
47
|
}
|
|
48
|
-
//#endregion
|
|
49
48
|
export { a as MetricCard };
|
|
50
49
|
|
|
51
50
|
//# sourceMappingURL=MetricCard.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MetricCard.js","names":[],"sources":["../../../../src/billing/shared/ui/MetricCard.tsx"],"sourcesContent":["/**\n * Boff UI — MetricCard primitive\n *\n * Stat/metric card following the Boff UI recipe: small muted label, large\n * tabular-nums value, optional trend, and an optional icon in an accent-soft\n * tile. One question per card. Can render as a button when `onClick` is\n * provided (used by the usage dashboard's filterable stats).\n *\n * Visual-only primitive.\n */\n\nimport type { ReactNode } from 'react';\nimport { cn } from '@burdenoff/fe-libs/shared/utils';\nimport { GlassCard } from '@burdenoff/fe-libs/ui';\n\ninterface MetricCardTrend {\n value: number;\n isPositive: boolean;\n}\n\ninterface MetricCardProps {\n label: ReactNode;\n value: ReactNode;\n icon?: ReactNode;\n trend?: MetricCardTrend;\n /** When provided, renders an interactive button (with selected ring when active). */\n onClick?: () => void;\n isActive?: boolean;\n className?: string;\n /** Passthrough for data-tour and other data-* hooks. */\n [key: `data-${string}`]: string | undefined;\n}\n\nexport function MetricCard({\n label,\n value,\n icon,\n trend,\n onClick,\n isActive = false,\n className,\n ...rest\n}: MetricCardProps) {\n const base = cn(\n 'p-5 text-left',\n onClick &&\n 'w-full focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--color-focus-ring)]',\n isActive && 'ring-1 ring-[var(--color-focus-ring)] border-border-strong',\n className\n );\n\n const inner = (\n <>\n <div className=\"flex items-start justify-between gap-3\">\n <p className=\"text-sm text-text-secondary\">{label}</p>\n {icon && (\n <span className=\"flex size-9 shrink-0 items-center justify-center rounded-lg bg-[var(--color-accent-soft)] text-text-primary\">\n {icon}\n </span>\n )}\n </div>\n <p className=\"mt-2 text-2xl font-semibold tabular-nums text-text-primary\">{value}</p>\n {trend && (\n <p\n className={cn(\n 'mt-1 text-xs font-medium tabular-nums',\n trend.isPositive ? 'text-status-success-text' : 'text-status-error-text'\n )}\n >\n {trend.isPositive ? '+' : ''}\n {trend.value}%\n </p>\n )}\n </>\n );\n\n if (onClick) {\n return (\n <GlassCard\n treatment=\"metric\"\n role=\"button\"\n tabIndex={0}\n onClick={onClick}\n onKeyDown={(e) => {\n if (e.key === 'Enter' || e.key === ' ') {\n e.preventDefault();\n onClick();\n }\n }}\n className={cn(base, 'cursor-pointer')}\n {...rest}\n >\n {inner}\n </GlassCard>\n );\n }\n\n return (\n <GlassCard treatment=\"metric\" className={base} {...rest}>\n {inner}\n </GlassCard>\n );\n}\n"],"mappings":";;;;AAiCA,
|
|
1
|
+
{"version":3,"file":"MetricCard.js","names":["_Fragment","MetricCard","rest","base","cn","onClick","isActive","className","inner","Fragment","label","icon","value","trend","GlassCard"],"sources":["../../../../src/billing/shared/ui/MetricCard.tsx"],"sourcesContent":["/**\n * Boff UI — MetricCard primitive\n *\n * Stat/metric card following the Boff UI recipe: small muted label, large\n * tabular-nums value, optional trend, and an optional icon in an accent-soft\n * tile. One question per card. Can render as a button when `onClick` is\n * provided (used by the usage dashboard's filterable stats).\n *\n * Visual-only primitive.\n */\n\nimport type { ReactNode } from 'react';\nimport { cn } from '@burdenoff/fe-libs/shared/utils';\nimport { GlassCard } from '@burdenoff/fe-libs/ui';\n\ninterface MetricCardTrend {\n value: number;\n isPositive: boolean;\n}\n\ninterface MetricCardProps {\n label: ReactNode;\n value: ReactNode;\n icon?: ReactNode;\n trend?: MetricCardTrend;\n /** When provided, renders an interactive button (with selected ring when active). */\n onClick?: () => void;\n isActive?: boolean;\n className?: string;\n /** Passthrough for data-tour and other data-* hooks. */\n [key: `data-${string}`]: string | undefined;\n}\n\nexport function MetricCard({\n label,\n value,\n icon,\n trend,\n onClick,\n isActive = false,\n className,\n ...rest\n}: MetricCardProps) {\n const base = cn(\n 'p-5 text-left',\n onClick &&\n 'w-full focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--color-focus-ring)]',\n isActive && 'ring-1 ring-[var(--color-focus-ring)] border-border-strong',\n className\n );\n\n const inner = (\n <>\n <div className=\"flex items-start justify-between gap-3\">\n <p className=\"text-sm text-text-secondary\">{label}</p>\n {icon && (\n <span className=\"flex size-9 shrink-0 items-center justify-center rounded-lg bg-[var(--color-accent-soft)] text-text-primary\">\n {icon}\n </span>\n )}\n </div>\n <p className=\"mt-2 text-2xl font-semibold tabular-nums text-text-primary\">{value}</p>\n {trend && (\n <p\n className={cn(\n 'mt-1 text-xs font-medium tabular-nums',\n trend.isPositive ? 'text-status-success-text' : 'text-status-error-text'\n )}\n >\n {trend.isPositive ? '+' : ''}\n {trend.value}%\n </p>\n )}\n </>\n );\n\n if (onClick) {\n return (\n <GlassCard\n treatment=\"metric\"\n role=\"button\"\n tabIndex={0}\n onClick={onClick}\n onKeyDown={(e) => {\n if (e.key === 'Enter' || e.key === ' ') {\n e.preventDefault();\n onClick();\n }\n }}\n className={cn(base, 'cursor-pointer')}\n {...rest}\n >\n {inner}\n </GlassCard>\n );\n }\n\n return (\n <GlassCard treatment=\"metric\" className={base} {...rest}>\n {inner}\n </GlassCard>\n );\n}\n"],"mappings":";;;;AAiCA,SAAgBC,EAAW,EACzB,UACA,UACA,SACA,UACA,YACA,cAAW,IACX,cACA,GAAGC,KACe;CAClB,IAAMC,IAAOC,EACX,iBACAC,KACE,uGACFC,KAAY,8DACZC,CACF,GAEMC,IACJ,kBAAAR,GAAA,EAAA,UAAA;EACE,kBAAC,OAAD;GAAK,WAAU;GAAf,UAAA,CACE,kBAAC,KAAD;IAAG,WAAU;IAA+B,UAAAU;GAAS,CAAA,GACpDC,KACC,kBAAC,QAAD;IAAM,WAAU;IACb,UAAAA;GACG,CAAA,CAEL;;EACL,kBAAC,KAAD;GAAG,WAAU;GAA8D,UAAAC;EAAS,CAAA;EACnFC,KACC,kBAAC,KAAD;GACE,WAAWT,EACT,yCACAS,EAAM,aAAa,6BAA6B,wBAClD;GAJF,UAAA;IAMGA,EAAM,aAAa,MAAM;IACzBA,EAAM;IAAM;GACZ;;CAEL,EAAA,CAAA;CAwBJ,OArBIR,IAEA,kBAACS,GAAD;EACE,WAAU;EACV,MAAK;EACL,UAAU;EACD;EACT,YAAY,MAAM;GAChB,CAAI,EAAE,QAAQ,WAAW,EAAE,QAAQ,SACjC,EAAE,eAAe,GACjBT,EAAQ;EAEZ;EACA,WAAWD,EAAGD,GAAM,gBAAgB;EACpC,GAAID;EAEH,UAAAM;CACQ,CAAA,IAKb,kBAACM,GAAD;EAAW,WAAU;EAAS,WAAWX;EAAM,GAAID;EAChD,UAAAM;CACQ,CAAA;AAEf"}
|
|
@@ -10,6 +10,5 @@ interface ProgressBarProps {
|
|
|
10
10
|
/** Accessible label for the progress meter. */
|
|
11
11
|
'aria-label'?: string;
|
|
12
12
|
}
|
|
13
|
-
export declare function ProgressBar({ value, status, size, className, 'aria-label': ariaLabel, }: ProgressBarProps): import(
|
|
13
|
+
export declare function ProgressBar({ value, status, size, className, 'aria-label': ariaLabel, }: ProgressBarProps): import('react').JSX.Element;
|
|
14
14
|
export {};
|
|
15
|
-
//# sourceMappingURL=ProgressBar.d.ts.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as e } from "react/jsx-runtime";
|
|
2
2
|
import { cn as t } from "@burdenoff/fe-libs/shared/utils";
|
|
3
|
-
|
|
3
|
+
// src/billing/shared/ui/ProgressBar.tsx
|
|
4
4
|
var n = {
|
|
5
5
|
success: "bg-status-success-bg",
|
|
6
6
|
warning: "bg-status-warning-bg",
|
|
@@ -24,7 +24,6 @@ function r({ value: r, status: i = "primary", size: a = "md", className: o, "ari
|
|
|
24
24
|
})
|
|
25
25
|
});
|
|
26
26
|
}
|
|
27
|
-
//#endregion
|
|
28
27
|
export { r as ProgressBar };
|
|
29
28
|
|
|
30
29
|
//# sourceMappingURL=ProgressBar.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ProgressBar.js","names":[],"sources":["../../../../src/billing/shared/ui/ProgressBar.tsx"],"sourcesContent":["/**\n * Boff UI — ProgressBar primitive\n *\n * Quota / usage progress bar with status-driven fill colors. Track uses the\n * sunken surface; the fill maps the billing `SemanticStatus` palette to the\n * canonical status tokens. Clamps the value to 0-100.\n *\n * Visual-only primitive.\n */\n\nimport { cn } from '@burdenoff/fe-libs/shared/utils';\nimport type { SemanticStatus } from '../utils/tokens';\n\nconst FILL_TONE: Record<SemanticStatus, string> = {\n success: 'bg-status-success-bg',\n warning: 'bg-status-warning-bg',\n error: 'bg-status-error-bg',\n info: 'bg-status-info-bg',\n neutral: 'bg-text-muted',\n primary: 'bg-action-primary-bg',\n};\n\ninterface ProgressBarProps {\n /** Percentage 0-100. */\n value: number;\n /** Status tone for the fill color. Defaults to a neutral/primary fill. */\n status?: SemanticStatus;\n /** Bar height: sm = h-1.5, md = h-2.5. */\n size?: 'sm' | 'md';\n className?: string;\n /** Accessible label for the progress meter. */\n 'aria-label'?: string;\n}\n\nexport function ProgressBar({\n value,\n status = 'primary',\n size = 'md',\n className,\n 'aria-label': ariaLabel,\n}: ProgressBarProps) {\n const clamped = Math.min(100, Math.max(0, value));\n return (\n <div\n className={cn(\n 'w-full overflow-hidden rounded-full bg-bg-sunken',\n size === 'sm' ? 'h-1.5' : 'h-2.5',\n className\n )}\n role=\"progressbar\"\n aria-valuenow={Math.round(clamped)}\n aria-valuemin={0}\n aria-valuemax={100}\n aria-label={ariaLabel}\n >\n <div\n className={cn(\n 'h-full rounded-full transition-all duration-300 ease-[var(--motion-easing-out)]',\n FILL_TONE[status]\n )}\n style={{ width: `${clamped}%` }}\n />\n </div>\n );\n}\n"],"mappings":";;;AAaA,
|
|
1
|
+
{"version":3,"file":"ProgressBar.js","names":["FILL_TONE","ProgressBar","ariaLabel","clamped","value","cn","size","className","status"],"sources":["../../../../src/billing/shared/ui/ProgressBar.tsx"],"sourcesContent":["/**\n * Boff UI — ProgressBar primitive\n *\n * Quota / usage progress bar with status-driven fill colors. Track uses the\n * sunken surface; the fill maps the billing `SemanticStatus` palette to the\n * canonical status tokens. Clamps the value to 0-100.\n *\n * Visual-only primitive.\n */\n\nimport { cn } from '@burdenoff/fe-libs/shared/utils';\nimport type { SemanticStatus } from '../utils/tokens';\n\nconst FILL_TONE: Record<SemanticStatus, string> = {\n success: 'bg-status-success-bg',\n warning: 'bg-status-warning-bg',\n error: 'bg-status-error-bg',\n info: 'bg-status-info-bg',\n neutral: 'bg-text-muted',\n primary: 'bg-action-primary-bg',\n};\n\ninterface ProgressBarProps {\n /** Percentage 0-100. */\n value: number;\n /** Status tone for the fill color. Defaults to a neutral/primary fill. */\n status?: SemanticStatus;\n /** Bar height: sm = h-1.5, md = h-2.5. */\n size?: 'sm' | 'md';\n className?: string;\n /** Accessible label for the progress meter. */\n 'aria-label'?: string;\n}\n\nexport function ProgressBar({\n value,\n status = 'primary',\n size = 'md',\n className,\n 'aria-label': ariaLabel,\n}: ProgressBarProps) {\n const clamped = Math.min(100, Math.max(0, value));\n return (\n <div\n className={cn(\n 'w-full overflow-hidden rounded-full bg-bg-sunken',\n size === 'sm' ? 'h-1.5' : 'h-2.5',\n className\n )}\n role=\"progressbar\"\n aria-valuenow={Math.round(clamped)}\n aria-valuemin={0}\n aria-valuemax={100}\n aria-label={ariaLabel}\n >\n <div\n className={cn(\n 'h-full rounded-full transition-all duration-300 ease-[var(--motion-easing-out)]',\n FILL_TONE[status]\n )}\n style={{ width: `${clamped}%` }}\n />\n </div>\n );\n}\n"],"mappings":";;;AAaA,IAAMA,IAA4C;CAChD,SAAS;CACT,SAAS;CACT,OAAO;CACP,MAAM;CACN,SAAS;CACT,SAAS;AACX;AAcA,SAAgBC,EAAY,EAC1B,UACA,YAAS,WACT,UAAO,MACP,cACA,cAAcC,KACK;CACnB,IAAMC,IAAU,KAAK,IAAI,KAAK,KAAK,IAAI,GAAGC,CAAK,CAAC;CAChD,OACE,kBAAC,OAAD;EACE,WAAWC,EACT,oDACAC,MAAS,OAAO,UAAU,SAC1BC,CACF;EACA,MAAK;EACL,iBAAe,KAAK,MAAMJ,CAAO;EACjC,iBAAe;EACf,iBAAe;EACf,cAAYD;EAEZ,UAAA,kBAAC,OAAD;GACE,WAAWG,EACT,mFACAL,EAAUQ,EACZ;GACA,OAAO,EAAE,OAAO,GAAGL,EAAQ,GAAG;EAC/B,CAAA;CACE,CAAA;AAET"}
|
|
@@ -10,6 +10,5 @@ interface SectionHeaderProps {
|
|
|
10
10
|
/** Heading level for the title element (defaults to h3 for in-card sections). */
|
|
11
11
|
as?: 'h2' | 'h3';
|
|
12
12
|
}
|
|
13
|
-
export declare function SectionHeader({ title, description, icon, actions, className, as: Heading, }: SectionHeaderProps): import(
|
|
13
|
+
export declare function SectionHeader({ title, description, icon, actions, className, as: Heading, }: SectionHeaderProps): import('react').JSX.Element;
|
|
14
14
|
export {};
|
|
15
|
-
//# sourceMappingURL=SectionHeader.d.ts.map
|
|
@@ -9,6 +9,5 @@ interface StatusPillProps {
|
|
|
9
9
|
pulse?: boolean;
|
|
10
10
|
className?: string;
|
|
11
11
|
}
|
|
12
|
-
export declare function StatusPill({ status, children, dot, pulse, className, }: StatusPillProps): import(
|
|
12
|
+
export declare function StatusPill({ status, children, dot, pulse, className, }: StatusPillProps): import('react').JSX.Element;
|
|
13
13
|
export {};
|
|
14
|
-
//# sourceMappingURL=StatusPill.d.ts.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as e, jsxs as t } from "react/jsx-runtime";
|
|
2
2
|
import { cn as n } from "@burdenoff/fe-libs/shared/utils";
|
|
3
|
-
|
|
3
|
+
// src/billing/shared/ui/StatusPill.tsx
|
|
4
4
|
var r = {
|
|
5
5
|
success: "bg-status-success-bg-subtle text-status-success-text",
|
|
6
6
|
warning: "bg-status-warning-bg-subtle text-status-warning-text",
|
|
@@ -22,7 +22,6 @@ function a({ status: a, children: o, dot: s = !1, pulse: c = !1, className: l })
|
|
|
22
22
|
children: [s && /* @__PURE__ */ e("span", { className: n("size-1.5 rounded-full", i[a], c && "motion-safe:animate-vc-glow-pulse") }), o]
|
|
23
23
|
});
|
|
24
24
|
}
|
|
25
|
-
//#endregion
|
|
26
25
|
export { a as StatusPill };
|
|
27
26
|
|
|
28
27
|
//# sourceMappingURL=StatusPill.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"StatusPill.js","names":[],"sources":["../../../../src/billing/shared/ui/StatusPill.tsx"],"sourcesContent":["/**\n * Boff UI — StatusPill primitive\n *\n * Subtle status badge following the Boff UI recipe\n * (for example, `bg-status-success-bg-subtle text-status-success-text`;\n * neutral uses `bg-bg-sunken text-text-secondary`). Always keeps the text\n * label and an optional dot — never color-only. Maps the billing module's\n * existing `SemanticStatus` palette to the canonical tokens.\n *\n * Visual-only primitive.\n */\n\nimport type { ReactNode } from 'react';\nimport { cn } from '@burdenoff/fe-libs/shared/utils';\nimport type { SemanticStatus } from '../utils/tokens';\n\nconst PILL_TONE: Record<SemanticStatus, string> = {\n success: 'bg-status-success-bg-subtle text-status-success-text',\n warning: 'bg-status-warning-bg-subtle text-status-warning-text',\n error: 'bg-status-error-bg-subtle text-status-error-text',\n info: 'bg-status-info-bg-subtle text-status-info-text',\n neutral: 'bg-bg-sunken text-text-secondary',\n primary: 'bg-[var(--color-accent-soft)] text-text-link',\n};\n\nconst DOT_TONE: Record<SemanticStatus, string> = {\n success: 'bg-status-success-bg',\n warning: 'bg-status-warning-bg',\n error: 'bg-status-error-bg',\n info: 'bg-status-info-bg',\n neutral: 'bg-text-muted',\n primary: 'bg-action-primary-bg',\n};\n\ninterface StatusPillProps {\n status: SemanticStatus;\n children: ReactNode;\n /** Show a leading status dot. */\n dot?: boolean;\n /** Pulse the dot (e.g. live / offline indicators). */\n pulse?: boolean;\n className?: string;\n}\n\nexport function StatusPill({\n status,\n children,\n dot = false,\n pulse = false,\n className,\n}: StatusPillProps) {\n return (\n <span\n className={cn(\n 'inline-flex items-center gap-1.5 rounded-full px-2.5 py-0.5 text-xs font-medium',\n PILL_TONE[status],\n className\n )}\n >\n {dot && (\n <span\n className={cn(\n 'size-1.5 rounded-full',\n DOT_TONE[status],\n pulse && 'motion-safe:animate-vc-glow-pulse'\n )}\n />\n )}\n {children}\n </span>\n );\n}\n"],"mappings":";;;AAgBA,
|
|
1
|
+
{"version":3,"file":"StatusPill.js","names":["PILL_TONE","DOT_TONE","StatusPill","cn","status","className","dot","pulse","children"],"sources":["../../../../src/billing/shared/ui/StatusPill.tsx"],"sourcesContent":["/**\n * Boff UI — StatusPill primitive\n *\n * Subtle status badge following the Boff UI recipe\n * (for example, `bg-status-success-bg-subtle text-status-success-text`;\n * neutral uses `bg-bg-sunken text-text-secondary`). Always keeps the text\n * label and an optional dot — never color-only. Maps the billing module's\n * existing `SemanticStatus` palette to the canonical tokens.\n *\n * Visual-only primitive.\n */\n\nimport type { ReactNode } from 'react';\nimport { cn } from '@burdenoff/fe-libs/shared/utils';\nimport type { SemanticStatus } from '../utils/tokens';\n\nconst PILL_TONE: Record<SemanticStatus, string> = {\n success: 'bg-status-success-bg-subtle text-status-success-text',\n warning: 'bg-status-warning-bg-subtle text-status-warning-text',\n error: 'bg-status-error-bg-subtle text-status-error-text',\n info: 'bg-status-info-bg-subtle text-status-info-text',\n neutral: 'bg-bg-sunken text-text-secondary',\n primary: 'bg-[var(--color-accent-soft)] text-text-link',\n};\n\nconst DOT_TONE: Record<SemanticStatus, string> = {\n success: 'bg-status-success-bg',\n warning: 'bg-status-warning-bg',\n error: 'bg-status-error-bg',\n info: 'bg-status-info-bg',\n neutral: 'bg-text-muted',\n primary: 'bg-action-primary-bg',\n};\n\ninterface StatusPillProps {\n status: SemanticStatus;\n children: ReactNode;\n /** Show a leading status dot. */\n dot?: boolean;\n /** Pulse the dot (e.g. live / offline indicators). */\n pulse?: boolean;\n className?: string;\n}\n\nexport function StatusPill({\n status,\n children,\n dot = false,\n pulse = false,\n className,\n}: StatusPillProps) {\n return (\n <span\n className={cn(\n 'inline-flex items-center gap-1.5 rounded-full px-2.5 py-0.5 text-xs font-medium',\n PILL_TONE[status],\n className\n )}\n >\n {dot && (\n <span\n className={cn(\n 'size-1.5 rounded-full',\n DOT_TONE[status],\n pulse && 'motion-safe:animate-vc-glow-pulse'\n )}\n />\n )}\n {children}\n </span>\n );\n}\n"],"mappings":";;;AAgBA,IAAMA,IAA4C;CAChD,SAAS;CACT,SAAS;CACT,OAAO;CACP,MAAM;CACN,SAAS;CACT,SAAS;AACX,GAEMC,IAA2C;CAC/C,SAAS;CACT,SAAS;CACT,OAAO;CACP,MAAM;CACN,SAAS;CACT,SAAS;AACX;AAYA,SAAgBC,EAAW,EACzB,WACA,aACA,SAAM,IACN,WAAQ,IACR,gBACkB;CAClB,OACE,kBAAC,QAAD;EACE,WAAWC,EACT,mFACAH,EAAUI,IACVC,CACF;EALF,UAAA,CAOGC,KACC,kBAAC,QAAD,EACE,WAAWH,EACT,yBACAF,EAASG,IACTG,KAAS,mCACX,EACD,CAAA,GAEFC,CACG;;AAEV"}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import "./Card.js";
|
|
1
|
+
import { Card as e } from "./Card.js";
|
|
2
2
|
import "./SectionHeader.js";
|
|
3
|
-
import "./StatusPill.js";
|
|
4
|
-
import "./MetricCard.js";
|
|
5
|
-
import "./ProgressBar.js";
|
|
3
|
+
import { StatusPill as t } from "./StatusPill.js";
|
|
4
|
+
import { MetricCard as n } from "./MetricCard.js";
|
|
5
|
+
import { ProgressBar as r } from "./ProgressBar.js";
|
|
6
|
+
export { e as Card, n as MetricCard, r as ProgressBar, t as StatusPill };
|
|
@@ -9,4 +9,3 @@ interface DirectActivityGraphqlRequestOptions<TVariables> {
|
|
|
9
9
|
export declare function resolveDirectActivityGraphqlUrl(apiGatewayUrl?: string): string | undefined;
|
|
10
10
|
export declare function directActivityGraphqlRequest<TData, TVariables = Record<string, unknown>>(options: DirectActivityGraphqlRequestOptions<TVariables>): Promise<TData>;
|
|
11
11
|
export {};
|
|
12
|
-
//# sourceMappingURL=directActivityGraphql.d.ts.map
|
|
@@ -9,4 +9,3 @@ interface DirectBillingGraphqlRequestOptions<TVariables> {
|
|
|
9
9
|
export declare function resolveDirectBillingGraphqlUrl(apiGatewayUrl?: string): string | undefined;
|
|
10
10
|
export declare function directBillingGraphqlRequest<TData, TVariables = Record<string, unknown>>(options: DirectBillingGraphqlRequestOptions<TVariables>): Promise<TData>;
|
|
11
11
|
export {};
|
|
12
|
-
//# sourceMappingURL=directBillingGraphql.d.ts.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { normalizeGlobalGatewayBaseUrl as e, toGraphqlQuery as t } from "./gatewayGraphql.js";
|
|
2
2
|
import { graphqlFetch as n } from "@burdenoff/fe-libs/shared/graphql/fetch";
|
|
3
|
-
|
|
3
|
+
// src/billing/shared/utils/directBillingGraphql.ts
|
|
4
4
|
function r(t) {
|
|
5
5
|
return e(t, ["localhost:4012", "/billing-graphql"]);
|
|
6
6
|
}
|
|
@@ -16,7 +16,6 @@ async function i(e) {
|
|
|
16
16
|
if (i.errors?.length || !i.data) throw Error(i.errors?.[0]?.message || "Billing GraphQL request failed");
|
|
17
17
|
return i.data;
|
|
18
18
|
}
|
|
19
|
-
//#endregion
|
|
20
19
|
export { i as directBillingGraphqlRequest, r as resolveDirectBillingGraphqlUrl };
|
|
21
20
|
|
|
22
21
|
//# sourceMappingURL=directBillingGraphql.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"directBillingGraphql.js","names":[],"sources":["../../../../src/billing/shared/utils/directBillingGraphql.ts"],"sourcesContent":["import { graphqlFetch } from '@burdenoff/fe-libs/shared/graphql/fetch';\n\nimport {\n normalizeGlobalGatewayBaseUrl,\n toGraphqlQuery,\n type GatewayGraphqlDocument,\n} from './gatewayGraphql';\n\ninterface DirectBillingGraphqlRequestOptions<TVariables> {\n apiGatewayUrl?: string;\n authToken?: string;\n orgId?: string;\n query: GatewayGraphqlDocument;\n variables?: TVariables;\n}\n\nexport function resolveDirectBillingGraphqlUrl(apiGatewayUrl?: string): string | undefined {\n return normalizeGlobalGatewayBaseUrl(apiGatewayUrl, ['localhost:4012', '/billing-graphql']);\n}\n\nexport async function directBillingGraphqlRequest<TData, TVariables = Record<string, unknown>>(\n options: DirectBillingGraphqlRequestOptions<TVariables>\n): Promise<TData> {\n const response = await graphqlFetch<TData>({\n gateway: 'global',\n baseUrl: resolveDirectBillingGraphqlUrl(options.apiGatewayUrl),\n authToken: options.authToken,\n organizationId: options.orgId,\n query: toGraphqlQuery(options.query),\n variables: options.variables as Record<string, unknown> | undefined,\n });\n\n if (response.errors?.length || !response.data) {\n throw new Error(response.errors?.[0]?.message || 'Billing GraphQL request failed');\n }\n\n return response.data;\n}\n"],"mappings":";;;AAgBA,
|
|
1
|
+
{"version":3,"file":"directBillingGraphql.js","names":["resolveDirectBillingGraphqlUrl","normalizeGlobalGatewayBaseUrl","apiGatewayUrl","directBillingGraphqlRequest","response","graphqlFetch","options","toGraphqlQuery"],"sources":["../../../../src/billing/shared/utils/directBillingGraphql.ts"],"sourcesContent":["import { graphqlFetch } from '@burdenoff/fe-libs/shared/graphql/fetch';\n\nimport {\n normalizeGlobalGatewayBaseUrl,\n toGraphqlQuery,\n type GatewayGraphqlDocument,\n} from './gatewayGraphql';\n\ninterface DirectBillingGraphqlRequestOptions<TVariables> {\n apiGatewayUrl?: string;\n authToken?: string;\n orgId?: string;\n query: GatewayGraphqlDocument;\n variables?: TVariables;\n}\n\nexport function resolveDirectBillingGraphqlUrl(apiGatewayUrl?: string): string | undefined {\n return normalizeGlobalGatewayBaseUrl(apiGatewayUrl, ['localhost:4012', '/billing-graphql']);\n}\n\nexport async function directBillingGraphqlRequest<TData, TVariables = Record<string, unknown>>(\n options: DirectBillingGraphqlRequestOptions<TVariables>\n): Promise<TData> {\n const response = await graphqlFetch<TData>({\n gateway: 'global',\n baseUrl: resolveDirectBillingGraphqlUrl(options.apiGatewayUrl),\n authToken: options.authToken,\n organizationId: options.orgId,\n query: toGraphqlQuery(options.query),\n variables: options.variables as Record<string, unknown> | undefined,\n });\n\n if (response.errors?.length || !response.data) {\n throw new Error(response.errors?.[0]?.message || 'Billing GraphQL request failed');\n }\n\n return response.data;\n}\n"],"mappings":";;;AAgBA,SAAgBA,EAA+B,GAA4C;CACzF,OAAOC,EAA8BC,GAAe,CAAC,kBAAkB,kBAAkB,CAAC;AAC5F;AAEA,eAAsBC,EACpB,GACgB;CAChB,IAAMC,IAAW,MAAMC,EAAoB;EACzC,SAAS;EACT,SAASL,EAA+BM,EAAQ,aAAa;EAC7D,WAAWA,EAAQ;EACnB,gBAAgBA,EAAQ;EACxB,OAAOC,EAAeD,EAAQ,KAAK;EACnC,WAAWA,EAAQ;CACrB,CAAC;CAED,IAAIF,EAAS,QAAQ,UAAU,CAACA,EAAS,MACvC,MAAU,MAAMA,EAAS,SAAS,EAAE,EAAE,WAAW,gCAAgC;CAGnF,OAAOA,EAAS;AAClB"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
// src/billing/shared/utils/error.ts
|
|
2
2
|
function e(e) {
|
|
3
3
|
if (!e) return !1;
|
|
4
4
|
if ("networkError" in e && e.networkError) {
|
|
@@ -10,7 +10,6 @@ function e(e) {
|
|
|
10
10
|
let t = e.message?.toLowerCase() || "";
|
|
11
11
|
return !!(t.includes("500") || t.includes("internal server error") || t.includes("service unavailable") || t.includes("bad gateway") || t.includes("gateway timeout"));
|
|
12
12
|
}
|
|
13
|
-
//#endregion
|
|
14
13
|
export { e as isServerError };
|
|
15
14
|
|
|
16
15
|
//# sourceMappingURL=error.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"error.js","names":[],"sources":["../../../../src/billing/shared/utils/error.ts"],"sourcesContent":["/**\n * Error Handling Utilities\n */\n\n/**\n * GraphQL error type with network error support\n * Compatible with Apollo Client 4.x error shape\n */\ninterface GraphQLError extends Error {\n networkError?: {\n statusCode?: number;\n message?: string;\n } | null;\n graphQLErrors?: Array<{ message: string }>;\n}\n\n/**\n * Check if an Apollo error is a server error (5xx status)\n */\nexport function isServerError(error: GraphQLError | Error | undefined | null): boolean {\n if (!error) return false;\n\n // Check if it's an Apollo error with network error\n if ('networkError' in error && error.networkError) {\n const networkError = error.networkError as { statusCode?: number; message?: string };\n\n // Check for 5xx status codes\n if (networkError.statusCode && networkError.statusCode >= 500) {\n return true;\n }\n\n // Check for common network error messages\n const message = networkError.message?.toLowerCase() || '';\n if (\n message.includes('failed to fetch') ||\n message.includes('network request failed') ||\n message.includes('econnrefused') ||\n message.includes('server error') ||\n message.includes('502') ||\n message.includes('503') ||\n message.includes('504')\n ) {\n return true;\n }\n }\n\n // Check error message for 500 errors\n const errorMessage = error.message?.toLowerCase() || '';\n if (\n errorMessage.includes('500') ||\n errorMessage.includes('internal server error') ||\n errorMessage.includes('service unavailable') ||\n errorMessage.includes('bad gateway') ||\n errorMessage.includes('gateway timeout')\n ) {\n return true;\n }\n\n return false;\n}\n\n/**\n * Check if an error is a network connectivity issue\n */\nexport function isNetworkError(error: GraphQLError | Error | undefined | null): boolean {\n if (!error) return false;\n\n if ('networkError' in error && error.networkError) {\n const message = (error.networkError as { message?: string }).message?.toLowerCase() || '';\n return (\n message.includes('failed to fetch') ||\n message.includes('network request failed') ||\n message.includes('econnrefused') ||\n message.includes('networkerror')\n );\n }\n\n return false;\n}\n\n/**\n * Get a user-friendly error message\n */\nexport function getErrorMessage(error: GraphQLError | Error | undefined | null): string {\n if (!error) return 'An unexpected error occurred.';\n\n if (isServerError(error)) {\n return 'The server is currently unavailable. Please try again later.';\n }\n\n if (isNetworkError(error)) {\n return 'Unable to connect to the server. Please check your internet connection.';\n }\n\n // Return the actual error message if it's user-friendly enough\n if (error.message && !error.message.includes('GraphQL')) {\n return error.message;\n }\n\n return 'Something went wrong. Please try again.';\n}\n"],"mappings":";AAmBA,
|
|
1
|
+
{"version":3,"file":"error.js","names":["isServerError","error","networkError","message","errorMessage"],"sources":["../../../../src/billing/shared/utils/error.ts"],"sourcesContent":["/**\n * Error Handling Utilities\n */\n\n/**\n * GraphQL error type with network error support\n * Compatible with Apollo Client 4.x error shape\n */\ninterface GraphQLError extends Error {\n networkError?: {\n statusCode?: number;\n message?: string;\n } | null;\n graphQLErrors?: Array<{ message: string }>;\n}\n\n/**\n * Check if an Apollo error is a server error (5xx status)\n */\nexport function isServerError(error: GraphQLError | Error | undefined | null): boolean {\n if (!error) return false;\n\n // Check if it's an Apollo error with network error\n if ('networkError' in error && error.networkError) {\n const networkError = error.networkError as { statusCode?: number; message?: string };\n\n // Check for 5xx status codes\n if (networkError.statusCode && networkError.statusCode >= 500) {\n return true;\n }\n\n // Check for common network error messages\n const message = networkError.message?.toLowerCase() || '';\n if (\n message.includes('failed to fetch') ||\n message.includes('network request failed') ||\n message.includes('econnrefused') ||\n message.includes('server error') ||\n message.includes('502') ||\n message.includes('503') ||\n message.includes('504')\n ) {\n return true;\n }\n }\n\n // Check error message for 500 errors\n const errorMessage = error.message?.toLowerCase() || '';\n if (\n errorMessage.includes('500') ||\n errorMessage.includes('internal server error') ||\n errorMessage.includes('service unavailable') ||\n errorMessage.includes('bad gateway') ||\n errorMessage.includes('gateway timeout')\n ) {\n return true;\n }\n\n return false;\n}\n\n/**\n * Check if an error is a network connectivity issue\n */\nexport function isNetworkError(error: GraphQLError | Error | undefined | null): boolean {\n if (!error) return false;\n\n if ('networkError' in error && error.networkError) {\n const message = (error.networkError as { message?: string }).message?.toLowerCase() || '';\n return (\n message.includes('failed to fetch') ||\n message.includes('network request failed') ||\n message.includes('econnrefused') ||\n message.includes('networkerror')\n );\n }\n\n return false;\n}\n\n/**\n * Get a user-friendly error message\n */\nexport function getErrorMessage(error: GraphQLError | Error | undefined | null): string {\n if (!error) return 'An unexpected error occurred.';\n\n if (isServerError(error)) {\n return 'The server is currently unavailable. Please try again later.';\n }\n\n if (isNetworkError(error)) {\n return 'Unable to connect to the server. Please check your internet connection.';\n }\n\n // Return the actual error message if it's user-friendly enough\n if (error.message && !error.message.includes('GraphQL')) {\n return error.message;\n }\n\n return 'Something went wrong. Please try again.';\n}\n"],"mappings":";AAmBA,SAAgBA,EAAc,GAAyD;CACrF,IAAI,CAACC,GAAO,OAAO;CAGnB,IAAI,kBAAkBA,KAASA,EAAM,cAAc;EACjD,IAAMC,IAAeD,EAAM;EAG3B,IAAIC,EAAa,cAAcA,EAAa,cAAc,KACxD,OAAO;EAIT,IAAMC,IAAUD,EAAa,SAAS,YAAY,KAAK;EACvD,IACEC,EAAQ,SAAS,iBAAiB,KAClCA,EAAQ,SAAS,wBAAwB,KACzCA,EAAQ,SAAS,cAAc,KAC/BA,EAAQ,SAAS,cAAc,KAC/BA,EAAQ,SAAS,KAAK,KACtBA,EAAQ,SAAS,KAAK,KACtBA,EAAQ,SAAS,KAAK,GAEtB,OAAO;CAEX;CAGA,IAAMC,IAAeH,EAAM,SAAS,YAAY,KAAK;CAWrD,OAVA,GACEG,EAAa,SAAS,KAAK,KAC3BA,EAAa,SAAS,uBAAuB,KAC7CA,EAAa,SAAS,qBAAqB,KAC3CA,EAAa,SAAS,aAAa,KACnCA,EAAa,SAAS,iBAAiB;AAM3C"}
|
|
@@ -30,4 +30,3 @@ export declare function formatInvoiceNumber(number: string): string;
|
|
|
30
30
|
* raw byte count — everything else falls back to a plain localized number.
|
|
31
31
|
*/
|
|
32
32
|
export declare function formatQuotaValue(value: number, unit?: string): string;
|
|
33
|
-
//# sourceMappingURL=format.d.ts.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { CreditTransactionType as e, InvoiceStatus as t, PlanDuration as n, SubscriptionStatus as r } from "../types/graphql.js";
|
|
2
2
|
import { formatBytes as i, formatBytes as a, formatCurrency as o, formatDate as s, formatDateTime as c, formatNumber as l, formatPercentage as u, formatRelativeTime as d } from "@burdenoff/fe-libs/shared/utils";
|
|
3
|
-
|
|
3
|
+
// src/billing/shared/utils/format.ts
|
|
4
4
|
function f(e, t = "USD", n = "en-US") {
|
|
5
5
|
return t.toUpperCase() === "CREDITS" ? p(e) : o(e, t, n);
|
|
6
6
|
}
|
|
@@ -53,7 +53,6 @@ function y(e) {
|
|
|
53
53
|
function b(e, t) {
|
|
54
54
|
return t === "bytes" ? i(e) : e.toLocaleString();
|
|
55
55
|
}
|
|
56
|
-
//#endregion
|
|
57
56
|
export { a as formatBytes, v as formatCreditTransactionType, p as formatCredits, f as formatCurrency, s as formatDate, c as formatDateTime, y as formatInvoiceNumber, h as formatInvoiceStatus, l as formatNumber, u as formatPercentage, g as formatPlanDuration, _ as formatPlanDurationLabel, b as formatQuotaValue, d as formatRelativeTime, m as formatSubscriptionStatus };
|
|
58
57
|
|
|
59
58
|
//# sourceMappingURL=format.js.map
|