@solvimon/solvimon-web 0.1.0-alpha.27 → 0.1.0-alpha.29
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +151 -17
- package/dist/{Alert.vue.es-lIiAWf2S.mjs → Alert.vue.es-CNrEaLvh.mjs} +58 -46
- package/dist/ApiStatus-CSFKl_ra.mjs +9 -0
- package/dist/AuthProvider.handle-DKfNs8rr.mjs +50 -0
- package/dist/{Avatar.vue.es-sfMZiX7A.mjs → Avatar.vue.es-r0NbcIib.mjs} +1 -1
- package/dist/{BillingInformation.vue_vue_type_script_setup_true_lang-DmY3a-Wi.mjs → BillingInformation.vue_vue_type_script_setup_true_lang-Cp4yGqaw.mjs} +18 -19
- package/dist/{Button.vue.es-Cmjfm4jw.mjs → Button.vue.es-Zw--kuaU.mjs} +4 -4
- package/dist/{ChargeOnDemandModal-CB4mrvkU.mjs → ChargeOnDemandModal-B8FDkS9U.mjs} +240 -251
- package/dist/Checkout.entry.ce-DsGl-5aR.mjs +4202 -0
- package/dist/CheckoutAddressFields.vue_vue_type_script_setup_true_lang-2D8VM_7W.mjs +828 -0
- package/dist/{Chip.vue.es-DksjbJO8.mjs → Chip.vue.es-D3UDSyXC.mjs} +35 -21
- package/dist/Comparators.vue.es-DQBI3f7m.mjs +103 -0
- package/dist/ContentWithAsideLayout-Bnbsq8_5.mjs +32 -0
- package/dist/{ContextMenu.vue.es-zRvoEJlV.mjs → ContextMenu.vue.es-B9mFpUQK.mjs} +87 -88
- package/dist/{CustomerBillingInformation.vue.es-DhFbpZPK.mjs → CustomerBillingInformation.vue.es-B8NiQaJs.mjs} +3 -3
- package/dist/{CustomerPaymentMethods.vue_vue_type_script_setup_true_lang-B41la-T7.mjs → CustomerPaymentMethods.vue_vue_type_script_setup_true_lang-DBivC5Eb.mjs} +27 -30
- package/dist/CustomerShippingAddresses-Bj8Y17O8.mjs +397 -0
- package/dist/CustomerWalletBalances.vue_vue_type_script_setup_true_lang-BmPKfIjT.mjs +2927 -0
- package/dist/{DividerText.vue.es-nAo1eRMV.mjs → DividerText.vue.es-CNbgif-3.mjs} +1 -1
- package/dist/EmptyStatePlaceholder.vue_vue_type_script_setup_true_lang-CVP-7ne3.mjs +55 -0
- package/dist/{ErrorNotification.vue.es-h-D37rfG.mjs → ErrorNotification.vue.es-DNd65mQq.mjs} +2 -2
- package/dist/FormMessage.vue.es-Cjv358Ab.mjs +39 -0
- package/dist/{IconButton.vue.es-DvfErUOq.mjs → IconButton.vue.es-C8lYFx5_.mjs} +2 -2
- package/dist/{IconTitle.vue.es-B_8bS0tn.mjs → IconTitle.vue.es-O2kcqgKm.mjs} +3 -3
- package/dist/Input.vue.es-D8Oj8MWv.mjs +250 -0
- package/dist/{InvoiceDetailsBlock.vue_vue_type_script_setup_true_lang-gpMtYNzn.mjs → InvoiceDetailsBlock.vue_vue_type_script_setup_true_lang-rhqYVdfV.mjs} +14 -13
- package/dist/InvoiceEntryView.vue_vue_type_script_setup_true_lang-06R-M8Q3.mjs +56 -0
- package/dist/InvoicePreview.vue.es-4Q2hzaFS.mjs +286 -0
- package/dist/InvoicePricingClauseChip.vue.es-DKU0xu0t.mjs +124 -0
- package/dist/Label.vue.es-DtpLM1KH.mjs +113 -0
- package/dist/{Modal.vue.es-BeI5C9-9.mjs → Modal.vue.es-C8ZcO117.mjs} +109 -103
- package/dist/OrderSummaryInvoice.vue_vue_type_script_setup_true_lang-3DQLCR3U.mjs +441 -0
- package/dist/PaymentCompletedCard.vue_vue_type_script_setup_true_lang-DfTb9psX.mjs +48 -0
- package/dist/{PaymentErrorCard.vue_vue_type_script_setup_true_lang-DqHcOnZp.mjs → PaymentErrorCard.vue_vue_type_script_setup_true_lang-BoGTtg5G.mjs} +70 -113
- package/dist/{PaymentFeedbackCard.vue_vue_type_script_setup_true_lang-DlqoWKQq.mjs → PaymentFeedbackCard.vue_vue_type_script_setup_true_lang-BIAm22Kq.mjs} +3 -3
- package/dist/{PaymentHistoryBlock-mCqdFjnL.mjs → PaymentHistoryBlock-BvY2nXGV.mjs} +1 -1
- package/dist/{PaymentHistoryBlock.vue_vue_type_script_setup_true_lang-DxaY3eFN.mjs → PaymentHistoryBlock.vue_vue_type_script_setup_true_lang-bQKhUonq.mjs} +24 -24
- package/dist/{PaymentIntegrationForm-DVx4DEtD.mjs → PaymentIntegrationForm-CcfQSzKM.mjs} +1 -1
- package/dist/PaymentIntegrationForm.vue_vue_type_script_setup_true_lang-CvzcLJVq.mjs +181 -0
- package/dist/{PaymentIntegrationFormAdyen-Yr8p5Fly.mjs → PaymentIntegrationFormAdyen-DqgDfO6K.mjs} +422 -311
- package/dist/PaymentIntegrationFormStripe-BYdAkvLt.mjs +757 -0
- package/dist/{PaymentMethod.vue.es-4YRmQZHX.mjs → PaymentMethod.vue.es-b0p3a0L-.mjs} +7 -7
- package/dist/{PaymentMethodForm-Dnj_7mJU.mjs → PaymentMethodForm-BsTrTwCg.mjs} +1 -1
- package/dist/{PaymentMethodForm.vue_vue_type_script_setup_true_lang-DsD3UjkC.mjs → PaymentMethodForm.vue_vue_type_script_setup_true_lang-sUOmLORl.mjs} +57 -65
- package/dist/PaymentMethodSelector.vue_vue_type_script_setup_true_lang-DsnAhR79.mjs +169 -0
- package/dist/{PaymentMethodsList.vue_vue_type_script_setup_true_lang-CjECKNi_.mjs → PaymentMethodsList.vue_vue_type_script_setup_true_lang-CSW4LfmH.mjs} +13 -8
- package/dist/PlanCustomizationEditor-D29N4HUM.mjs +711 -0
- package/dist/PortalLinkUnverified-B_EE2wTJ.mjs +52 -0
- package/dist/PortalNotAvailable-DPE9y37H.mjs +25 -0
- package/dist/{PricingGroupRangeInput.vue.es-BhNcjD7z.mjs → PricingGroupRangeInput.vue.es-tIMXIhpZ.mjs} +14 -13
- package/dist/{PricingGroupSingleEditor.vue_vue_type_script_setup_true_lang-CmJITenR.mjs → PricingGroupSingleEditor.vue_vue_type_script_setup_true_lang-DqxWxSQe.mjs} +48 -48
- package/dist/RadioGroupExtended.vue.es-3nDXqIGi.mjs +176 -0
- package/dist/{Section.vue.es-DVEpre9O.mjs → Section.vue.es-CvX9tg2f.mjs} +1 -1
- package/dist/SecurePaymentsKPI.vue_vue_type_script_setup_true_lang-Cl7I1Apo.mjs +60 -0
- package/dist/ShippingAddressesModal-C4p1IXXk.mjs +418 -0
- package/dist/Skeleton.vue_vue_type_script_setup_true_lang-D7MFjvrP.mjs +32 -0
- package/dist/{StepInput.vue.es-o-3Lg4Ai.mjs → StepInput.vue.es-DweyzpkL.mjs} +5 -4
- package/dist/{SubscriptionDetails.entry.ce-CGl6Z5ql.mjs → SubscriptionDetails.entry.ce-D5SwM0YS.mjs} +448 -460
- package/dist/{SubscriptionSchedules-DuWZmnD2.mjs → SubscriptionSchedules-BZqlpAtk.mjs} +1 -1
- package/dist/SubscriptionSchedules.vue_vue_type_script_setup_true_lang-BH7DdOWK.mjs +5185 -0
- package/dist/SubscriptionSummary.vue_vue_type_script_setup_true_lang-DoJxiqVB.mjs +203 -0
- package/dist/{SubscriptionsList.vue_vue_type_script_setup_true_lang-BsdevoeT.mjs → SubscriptionsList.vue_vue_type_script_setup_true_lang-BbjdBHSQ.mjs} +126 -90
- package/dist/TooltipParagraph.vue.es-Dw0ndjle.mjs +132 -0
- package/dist/TranslationOverride.vue_vue_type_script_setup_true_lang-BhjZVMSx.mjs +31 -0
- package/dist/{TrialChip.vue.es-Dmv3lPiQ.mjs → TrialChip.vue.es-DOopmaXA.mjs} +2 -2
- package/dist/addressFormats.data-dzBx49dw.mjs +278 -0
- package/dist/amount-CondixVt.mjs +36 -0
- package/dist/{api.es-QaC926Xu.mjs → api.es-qgvzNMU-.mjs} +2 -2
- package/dist/{cn.es-Cvt6TIwv.mjs → cn.es-B8acFrov.mjs} +385 -477
- package/dist/{comparators.es-D8WGL-c4.mjs → comparators.es-C8rHpb70.mjs} +17 -13
- package/dist/components/BillingInformation/BillingInformation.mjs +11 -10
- package/dist/components/BillingInformationForm/BillingInformationForm.mjs +397 -350
- package/dist/components/CustomerPaymentMethods/CustomerPaymentMethods.mjs +20 -19
- package/dist/components/Invoice/Invoice.mjs +2691 -227
- package/dist/components/InvoiceDetails/InvoiceDetails.mjs +66 -62
- package/dist/components/InvoiceHeader/InvoiceHeader.mjs +40 -40
- package/dist/components/InvoicesList/InvoicesList.mjs +20 -18
- package/dist/components/PaymentHistory/PaymentHistory.mjs +72 -64
- package/dist/components/PaymentMethodForm/PaymentMethodForm.mjs +33 -31
- package/dist/components/SubscriptionSchedules/SubscriptionSchedules.mjs +49 -45
- package/dist/components/SubscriptionsList/SubscriptionsList.mjs +47 -31
- package/dist/components/WalletBalances/WalletBalances.mjs +22 -21
- package/dist/core/index.mjs +61 -95
- package/dist/customElements-BTj4ii4f.mjs +5072 -0
- package/dist/customer-BIjC0CWJ.mjs +31 -0
- package/dist/customer.es-DQKl6wFt.mjs +24 -0
- package/dist/{de-DE-DKp5LCu0.mjs → de-DE-DBbERiFr.mjs} +110 -18
- package/dist/{de-DE-jkW2dJrX.mjs → de-DE-UJ6X6jXu.mjs} +16 -10
- package/dist/floating-ui.vue.es-BvAf8-si.mjs +1003 -0
- package/dist/formControl-BZQLHnOO.mjs +749 -0
- package/dist/fr-FR-Cvvbkwlj.mjs +307 -0
- package/dist/fr-FR-IWJE-urI.mjs +431 -0
- package/dist/icon-sprite.svg.es-BWBB8SGw.mjs +4 -0
- package/dist/{index.es-CXkP_k3u.mjs → index.es-C7J3WGGo.mjs} +4 -4
- package/dist/index.es-CpmQmvOg.mjs +633 -0
- package/dist/index.mjs +2 -2
- package/dist/invoiceState-BJVHaKs7.mjs +14 -0
- package/dist/{invoices-3520M5AN.mjs → invoices-e1sKLgxg.mjs} +40 -35
- package/dist/{it-IT-BgFVsO5S.mjs → it-IT-B7ui2oxO.mjs} +110 -18
- package/dist/{it-IT-CaaFToGB.mjs → it-IT-DnJP5URH.mjs} +9 -3
- package/dist/{nl-NL-UiRWbO9S.mjs → nl-NL-Bafh2xoT.mjs} +116 -24
- package/dist/{nl-NL-D0MQKaql.mjs → nl-NL-q9xfTZF0.mjs} +12 -6
- package/dist/paymentMethods-B_82JGk_.mjs +77 -0
- package/dist/paymentMethods-Nfv9HdkS.mjs +61 -0
- package/dist/paymentOutcome-BXEU5-84.mjs +67 -0
- package/dist/payments-BnxbzQUC.mjs +68 -0
- package/dist/{pricing-BIMpDI_p.mjs → pricing-BOhvWWMj.mjs} +3 -3
- package/dist/pricingItemConfigs.es-D3pX_9AJ.mjs +78 -0
- package/dist/pricingPlanScheduleOverrides-Dxv5FOBd.mjs +233 -0
- package/dist/pricingPlanSchedules-Dv7ZCgNp.mjs +38 -0
- package/dist/sanitization.es-C6dbuxUJ.mjs +4 -0
- package/dist/screens/Checkout/Checkout.mjs +2 -2
- package/dist/screens/CustomerOverview/CustomerOverview.mjs +146 -94
- package/dist/screens/PayInvoice/PayInvoice.mjs +603 -278
- package/dist/screens/PaymentMethodsManagement/PaymentMethodsManagement.mjs +102 -88
- package/dist/screens/SubscriptionDetails/SubscriptionDetails.mjs +2 -2
- package/dist/screens/SubscriptionManagement/SubscriptionManagement.mjs +371 -347
- package/dist/sessionReference-B8Dbmx5t.mjs +38 -0
- package/dist/sorting.es-CVyKw23D.mjs +77 -0
- package/dist/subscription-BhxoqwcT.mjs +83 -0
- package/dist/subscriptions-BWXZGK0E.mjs +66 -0
- package/dist/taxId.es-DkD3Ltr8.mjs +243 -0
- package/dist/types/components/InvoiceTable/InvoiceTable.types.d.ts +2 -0
- package/dist/types/components/checkout/PromotionCodeSection.types.d.ts +2 -0
- package/dist/types/components/customer/CheckoutForm/CheckoutAddressFields.types.d.ts +22 -0
- package/dist/types/components/customer/CheckoutForm/CheckoutForm.types.d.ts +15 -0
- package/dist/types/components/customer/CustomerPaymentMethodsBlock/CustomerPaymentMethodsBlock.types.d.ts +0 -2
- package/dist/types/components/customer/ShippingAddressForm/ShippingAddressForm.types.d.ts +9 -0
- package/dist/types/components/customer/ShippingAddresses/ShippingAddressCard.types.d.ts +11 -0
- package/dist/types/components/customer/ShippingAddresses/ShippingAddressList.types.d.ts +9 -0
- package/dist/types/components/customer/ShippingAddresses/ShippingAddressesModal.types.d.ts +26 -0
- package/dist/types/components/invoices/InvoiceOrderSummary/InvoiceOrderSummary.types.d.ts +5 -0
- package/dist/types/components/payments/OnDemandPaymentModalShell/OnDemandPaymentModalShell.types.d.ts +0 -1
- package/dist/types/components/payments/PayButton/PayButton.types.d.ts +2 -0
- package/dist/types/components/payments/PaymentCompletedCard/PaymentCompletedCard.types.d.ts +0 -2
- package/dist/types/components/payments/PaymentErrorCard/PaymentErrorCard.types.d.ts +9 -2
- package/dist/types/components/payments/PaymentIntegrationForm/PaymentIntegrationForm.types.d.ts +47 -4
- package/dist/types/components/payments/PaymentIntegrationFormStripe/PaymentIntegrationFormStripeFrame.types.d.ts +11 -1
- package/dist/types/components/payments/PaymentMethodSelector/PaymentMethodSelector.types.d.ts +0 -4
- package/dist/types/components/providers/AuthProvider/AuthProvider.handle.d.ts +17 -0
- package/dist/types/components/providers/AuthProvider/AuthProvider.lib.d.ts +30 -3
- package/dist/types/components/providers/AuthProvider/AuthProvider.types.d.ts +12 -0
- package/dist/types/components/providers/AuthProvider/AuthProvider.vue.d.ts +3 -1
- package/dist/types/components/providers/AuthProvider/composables/useAuth.d.ts +1 -3
- package/dist/types/components/providers/ConfigProvider/ConfigProvider.lib.d.ts +2 -4
- package/dist/types/components/providers/CssOverridesProvider/CssOverridesProvider.lib.d.ts +11 -0
- package/dist/types/components/providers/EntryProvider/EntryProvider.lib.d.ts +7 -0
- package/dist/types/components/providers/EntryProvider/EntryProvider.types.d.ts +2 -0
- package/dist/types/components/providers/EntryProvider/EntryProvider.vue.d.ts +3 -1
- package/dist/types/components/providers/ErrorBoundary/ErrorBoundary.vue.d.ts +5 -1
- package/dist/types/components/providers/ExperimentalFeatureProvider/ExperimentalFeatureProvider.lib.d.ts +2 -2
- package/dist/types/components/providers/HostElementProvider/HostElementProvider.lib.d.ts +6 -1
- package/dist/types/components/providers/LoggerProvider/LoggerProvider.types.d.ts +2 -2
- package/dist/types/components/providers/LoggerProvider/LoggerProvider.vue.d.ts +5 -1
- package/dist/types/components/providers/PortalProvider/PortalProvider.lib.d.ts +10 -7
- package/dist/types/components/providers/PortalProvider/PortalProvider.types.d.ts +1 -1
- package/dist/types/components/providers/PortalProvider/PortalProvider.vue.d.ts +3 -1
- package/dist/types/components/providers/PortalProvider/composables/usePortal.d.ts +2 -2
- package/dist/types/components/providers/Provider/Provider.types.d.ts +2 -2
- package/dist/types/components/providers/Provider/Provider.vue.d.ts +13 -4
- package/dist/types/components/providers/RequiredPropertiesGuard/RequiredPropertiesGuard.vue.d.ts +17 -0
- package/dist/types/components/providers/TranslationProvider/TranslationProvider.lib.d.ts +7 -2
- package/dist/types/components/providers/TranslationProvider/TranslationProvider.types.d.ts +1 -1
- package/dist/types/components/subscriptions/ChargeOnDemandModal/ChargeOnDemandModal.types.d.ts +1 -2
- package/dist/types/components/subscriptions/EnabledPricingsList/EnabledPricingsListItem.types.d.ts +2 -0
- package/dist/types/components/subscriptions/OrderSummary.types.d.ts +1 -10
- package/dist/types/components/subscriptions/OrderSummaryInvoice.types.d.ts +16 -0
- package/dist/types/components/subscriptions/SubscriptionCancellationModal/SubscriptionCancellationModal.types.d.ts +5 -1
- package/dist/types/components/subscriptions/SubscriptionManagement/SubscriptionManagementForm.types.d.ts +10 -16
- package/dist/types/components/subscriptions/SubscriptionSummary.types.d.ts +1 -14
- package/dist/types/components/subscriptions/SubscriptionsList/SubscriptionsList.types.d.ts +4 -1
- package/dist/types/components/subscriptions/SubscriptionsList/SubscriptionsListItem.types.d.ts +1 -2
- package/dist/types/components/wallets/AutoTopUpConfig/AutoTopUpConfig.types.d.ts +0 -3
- package/dist/types/components/wallets/TopUpModal/TopUpModalForm.types.d.ts +3 -1
- package/dist/types/components/wallets/TopUpModal/TopUpModalSuccess.types.d.ts +1 -7
- package/dist/types/public/components/BillingInformation/BillingInformation.entry.ce.d.ts +1 -1
- package/dist/types/public/components/BillingInformation/BillingInformation.types.d.ts +0 -3
- package/dist/types/public/components/BillingInformationForm/BillingInformationForm.entry.ce.d.ts +1 -1
- package/dist/types/public/components/CustomerPaymentMethods/CustomerPaymentMethods.entry.ce.d.ts +1 -1
- package/dist/types/public/components/CustomerPaymentMethods/CustomerPaymentMethods.types.d.ts +0 -1
- package/dist/types/public/components/CustomerShippingAddresses/CustomerShippingAddresses.types.d.ts +12 -0
- package/dist/types/public/components/Invoice/Invoice.entry.ce.d.ts +1 -1
- package/dist/types/public/components/Invoice/Invoice.types.d.ts +0 -1
- package/dist/types/public/components/InvoiceDetails/InvoiceDetails.entry.ce.d.ts +1 -1
- package/dist/types/public/components/InvoiceDetails/InvoiceDetails.entry.types.d.ts +3 -2
- package/dist/types/public/components/InvoiceDetails/InvoiceDetails.types.d.ts +0 -2
- package/dist/types/public/components/InvoiceHeader/InvoiceHeader.entry.ce.d.ts +1 -1
- package/dist/types/public/components/InvoiceHeader/InvoiceHeader.types.d.ts +0 -1
- package/dist/types/public/components/InvoicesList/InvoicesList.entry.ce.d.ts +1 -1
- package/dist/types/public/components/InvoicesList/InvoicesList.types.d.ts +2 -0
- package/dist/types/public/components/PaymentHistory/PaymentHistory.entry.ce.d.ts +1 -1
- package/dist/types/public/components/PaymentHistory/PaymentHistory.entry.types.d.ts +3 -2
- package/dist/types/public/components/PaymentHistory/PaymentHistory.types.d.ts +0 -2
- package/dist/types/public/components/PaymentMethodForm/PaymentMethodForm.entry.ce.d.ts +1 -1
- package/dist/types/public/components/SubscriptionSchedules/SubscriptionSchedules.entry.ce.d.ts +1 -1
- package/dist/types/public/components/SubscriptionSchedules/SubscriptionSchedules.entry.types.d.ts +3 -2
- package/dist/types/public/components/SubscriptionSchedules/SubscriptionSchedules.types.d.ts +0 -2
- package/dist/types/public/components/SubscriptionsList/SubscriptionsList.entry.ce.d.ts +1 -1
- package/dist/types/public/components/SubscriptionsList/SubscriptionsList.types.d.ts +3 -0
- package/dist/types/public/components/WalletBalances/WalletBalances.entry.ce.d.ts +1 -1
- package/dist/types/public/components/WalletBalances/WalletBalances.entry.types.d.ts +1 -3
- package/dist/types/public/core/action-request.types.d.ts +5 -0
- package/dist/types/public/core/registry.ce.d.ts +3 -3
- package/dist/types/public/core/registry.d.ts +0 -3
- package/dist/types/public/core/types.d.ts +5 -0
- package/dist/types/public/screens/Checkout/Checkout.entry.ce.d.ts +1 -1
- package/dist/types/public/screens/Checkout/Checkout.entry.types.d.ts +0 -7
- package/dist/types/public/screens/Checkout/Checkout.types.d.ts +2 -2
- package/dist/types/public/screens/CustomerOverview/CustomerOverview.entry.ce.d.ts +1 -1
- package/dist/types/public/screens/PayInvoice/PayInvoice.entry.ce.d.ts +1 -1
- package/dist/types/public/screens/PayInvoice/PayInvoice.types.d.ts +5 -1
- package/dist/types/public/screens/PaymentMethodsManagement/PaymentMethodsManagement.entry.ce.d.ts +1 -1
- package/dist/types/public/screens/SubscriptionDetails/SubscriptionDetails.entry.ce.d.ts +1 -1
- package/dist/types/public/screens/SubscriptionDetails/SubscriptionDetails.types.d.ts +1 -2
- package/dist/types/public/screens/SubscriptionManagement/SubscriptionManagement.entry.ce.d.ts +1 -1
- package/dist/types/services/paymentMethods.types.d.ts +2 -10
- package/dist/types/services/requests.types.d.ts +16 -6
- package/dist/types/translations/supported.d.ts +1 -1
- package/dist/types/types/errors.d.ts +3 -2
- package/dist/types/types/portalAuthentication.d.ts +2 -0
- package/dist/types/types/portalToken.d.ts +9 -0
- package/dist/types/types/shippingAddress.d.ts +9 -0
- package/dist/types/vendor/@adyen/adyen-web/index.d.ts +2 -0
- package/dist/types/vendor/@solvimon/solvimon-types/index.d.ts +2 -0
- package/dist/types/vendor/@solvimon/solvimon-types/types/ApprovalPolicies.d.ts +1 -1
- package/dist/types/vendor/@solvimon/solvimon-types/types/ApprovalRequests.d.ts +27 -6
- package/dist/types/vendor/@solvimon/solvimon-types/types/ConfigMeterProperties.d.ts +3 -0
- package/dist/types/vendor/@solvimon/solvimon-types/types/Entitlement.d.ts +6 -0
- package/dist/types/vendor/@solvimon/solvimon-types/types/Integrations.d.ts +9 -1
- package/dist/types/vendor/@solvimon/solvimon-types/types/Invoice.d.ts +16 -1
- package/dist/types/vendor/@solvimon/solvimon-types/types/JWT.d.ts +10 -0
- package/dist/types/vendor/@solvimon/solvimon-types/types/MeterPropertyVariable.d.ts +16 -0
- package/dist/types/vendor/@solvimon/solvimon-types/types/Payment.d.ts +1 -1
- package/dist/types/vendor/@solvimon/solvimon-types/types/PaymentAcceptor.d.ts +6 -0
- package/dist/types/vendor/@solvimon/solvimon-types/types/Permission.d.ts +1 -1
- package/dist/types/vendor/@solvimon/solvimon-types/types/Platform.d.ts +12 -3
- package/dist/types/vendor/@solvimon/solvimon-types/types/Portal.d.ts +71 -0
- package/dist/types/vendor/@solvimon/solvimon-types/types/PricingPlanSubscription.d.ts +14 -0
- package/dist/types/vendor/@solvimon/solvimon-types/types/QuoteTemplates.d.ts +1 -0
- package/dist/types/vendor/@solvimon/solvimon-types/types/QuoteVersions.d.ts +35 -0
- package/dist/types/vendor/@solvimon/solvimon-types/types/Quotes.d.ts +16 -0
- package/dist/types/vendor/@solvimon/solvimon-types/types/ShippingAddress.d.ts +54 -0
- package/dist/types/vendor/@solvimon/solvimon-types/utils.d.ts +1 -1
- package/dist/types/vendor/@solvimon/solvimon-ui/components/providers/BrandProvider/BrandProvider.types.d.ts +16 -0
- package/dist/types/vendor/@solvimon/solvimon-ui/components/providers/IntlProvider/IntlProvider.types.d.ts +66 -0
- package/dist/types/vendor/@solvimon/solvimon-ui/index.d.ts +2 -0
- package/dist/useActionDispatchProvider-3W2vEyIg.mjs +9 -0
- package/dist/{useCustomer-B-jyJIVy.mjs → useCustomer-cObBvDOu.mjs} +2 -2
- package/dist/useCustomerFormLabels-DJWf2O17.mjs +1173 -0
- package/dist/useIncrementalLoading-CATuO36d.mjs +60 -0
- package/dist/useInvoiceData-DD44HTl7.mjs +21 -0
- package/dist/useInvoicesList-CpB-41MQ.mjs +674 -0
- package/dist/useLazyFloating.es-CycqRyeb.mjs +68 -0
- package/dist/useLoadInitialData-qzdnBoui.mjs +15 -0
- package/dist/usePaymentFormHold-ByUZi3A-.mjs +181 -0
- package/dist/{usePaymentMethodAvailability-DAcsKGeh.mjs → usePaymentMethodAvailability-DUdrs0Ji.mjs} +8 -8
- package/dist/usePaymentMethods-ByaKF7mf.mjs +21 -0
- package/dist/{usePayments-Cr6NlGaW.mjs → usePayments-BXABv-lF.mjs} +9 -9
- package/dist/usePortal-CwR_FxTb.mjs +7 -0
- package/dist/useService-BZcbUZHI.mjs +56 -0
- package/dist/{useTimePeriod.es-DWLsLFqs.mjs → useTimePeriod.es-BpdiVwg8.mjs} +1 -1
- package/dist/useViewport-psZejz_H.mjs +19 -0
- package/package.json +33 -60
- package/dist/AddPaymentMethodPane.vue_vue_type_script_setup_true_lang-081H9T3X.js +0 -1
- package/dist/AddPaymentMethodPane.vue_vue_type_script_setup_true_lang-DNepCMRp.mjs +0 -223
- package/dist/Alert.vue.es-RyK53a2P.js +0 -1
- package/dist/Amount.vue.es-DExaYBqm.js +0 -1
- package/dist/Avatar.vue.es-BJxSCU76.js +0 -1
- package/dist/BillingInformation.vue_vue_type_script_setup_true_lang-BV5iEOxn.js +0 -1
- package/dist/Button.vue.es-BzkuglKw.js +0 -1
- package/dist/ChargeOnDemandModal-b17YswWA.js +0 -1
- package/dist/Checkout.entry.ce-HlUrJ1kh.js +0 -2
- package/dist/Checkout.entry.ce-X2zGo6hG.mjs +0 -4381
- package/dist/Chip.vue.es-B2jjzIOc.js +0 -1
- package/dist/Comparators.vue.es-CwhX3rbx.mjs +0 -93
- package/dist/Comparators.vue.es-DmkxV0gb.js +0 -1
- package/dist/ContentWithAsideLayout-BCM8tmZN.mjs +0 -38
- package/dist/ContentWithAsideLayout-RSdKXqAf.js +0 -1
- package/dist/ContextMenu.vue.es-DUU43tCy.js +0 -1
- package/dist/CustomerBillingInformation.vue.es-BfPEB42w.js +0 -1
- package/dist/CustomerPaymentMethods.lib-BKgQTCtc.js +0 -1
- package/dist/CustomerPaymentMethods.vue_vue_type_script_setup_true_lang-BISD6n8X.js +0 -1
- package/dist/CustomerWalletBalances.vue_vue_type_script_setup_true_lang-DssxYPSA.mjs +0 -2688
- package/dist/CustomerWalletBalances.vue_vue_type_script_setup_true_lang-XufY6bdV.js +0 -1
- package/dist/Divider.vue.es-UwnWvUTl.js +0 -1
- package/dist/DividerText.vue.es-CoyDk9eH.js +0 -1
- package/dist/EmptyStatePlaceholder.vue_vue_type_script_setup_true_lang-CQ0KrXHJ.js +0 -1
- package/dist/EmptyStatePlaceholder.vue_vue_type_script_setup_true_lang-QW9NdxyZ.mjs +0 -335
- package/dist/ErrorNotification.vue.es-tS9vySUZ.js +0 -1
- package/dist/Expand.vue.es-BtM0EZEr.js +0 -1
- package/dist/FormMessage.vue.es-dqATjC2N.js +0 -1
- package/dist/FormMessage.vue.es-jG3fQZms.mjs +0 -29
- package/dist/IconButton.vue.es-DgQN18Am.js +0 -1
- package/dist/IconTitle.vue.es-Dn2xcPHj.js +0 -1
- package/dist/Input.vue.es-B60eK8Ds.js +0 -1
- package/dist/Input.vue.es-CU9u5yKH.mjs +0 -235
- package/dist/InvoiceDetailsBlock.vue_vue_type_script_setup_true_lang-Dqdezse7.js +0 -1
- package/dist/InvoiceEntryView.vue_vue_type_script_setup_true_lang-Cl6HU243.js +0 -1
- package/dist/InvoiceEntryView.vue_vue_type_script_setup_true_lang-DNqawlYV.mjs +0 -41
- package/dist/InvoiceSummary.vue.es-CAmA8g0t.js +0 -1
- package/dist/InvoiceSummary.vue.es-CRiFJ5x-.mjs +0 -2596
- package/dist/Modal.vue.es-DvLB3uCG.js +0 -1
- package/dist/PaymentErrorCard.vue_vue_type_script_setup_true_lang-Dg4rn1cm.js +0 -1
- package/dist/PaymentFeedbackCard.vue_vue_type_script_setup_true_lang-B9R5JRJv.js +0 -1
- package/dist/PaymentHistoryBlock-Uw8xeKUk.js +0 -1
- package/dist/PaymentHistoryBlock.vue_vue_type_script_setup_true_lang-ALI5f0py.js +0 -1
- package/dist/PaymentIntegrationForm-Cx0zCf_C.js +0 -1
- package/dist/PaymentIntegrationForm.vue_vue_type_script_setup_true_lang-B-viSd_i.js +0 -1
- package/dist/PaymentIntegrationForm.vue_vue_type_script_setup_true_lang-CCKCXXZX.mjs +0 -154
- package/dist/PaymentIntegrationFormAdyen-B-v-4nlj.js +0 -98
- package/dist/PaymentIntegrationFormStripe-CoLmAzas.js +0 -102
- package/dist/PaymentIntegrationFormStripe-Ds0BXt89.mjs +0 -587
- package/dist/PaymentMethod.vue.es-D0D9jW8s.js +0 -1
- package/dist/PaymentMethodForm-CMP5FLRO.js +0 -1
- package/dist/PaymentMethodForm.vue_vue_type_script_setup_true_lang-nxnGyJmE.js +0 -1
- package/dist/PaymentMethodsList.vue_vue_type_script_setup_true_lang-CIrrQUS6.js +0 -1
- package/dist/PlanCustomizationEditor-DS1r2vBO.js +0 -1
- package/dist/PlanCustomizationEditor-DlVSCKGN.mjs +0 -722
- package/dist/PricingGroupRangeInput.vue.es-VoOTnHjk.js +0 -185
- package/dist/PricingGroupSingleEditor.vue_vue_type_script_setup_true_lang-hS6A-KcP.js +0 -1
- package/dist/RadioGroupExtended.vue.es-9YzXzZF0.mjs +0 -163
- package/dist/RadioGroupExtended.vue.es-DlbURHQN.js +0 -1
- package/dist/Section.vue.es-Bbt0RITt.js +0 -1
- package/dist/SecurePaymentsKPI.vue_vue_type_script_setup_true_lang-Dl7MbMlk.js +0 -1
- package/dist/SecurePaymentsKPI.vue_vue_type_script_setup_true_lang-xzjqB-v-.mjs +0 -687
- package/dist/Skeleton.vue_vue_type_script_setup_true_lang-CJWE7wVi.mjs +0 -41
- package/dist/Skeleton.vue_vue_type_script_setup_true_lang-otI7Hz2w.js +0 -1
- package/dist/StepInput.vue.es-H-3R4jJq.js +0 -1
- package/dist/SubscriptionDetails.entry.ce-CQUO_uXH.js +0 -1
- package/dist/SubscriptionSchedules-Dy0fUgx5.js +0 -1
- package/dist/SubscriptionSchedules.vue_vue_type_script_setup_true_lang-C1kTiW-H.mjs +0 -5234
- package/dist/SubscriptionSchedules.vue_vue_type_script_setup_true_lang-Dd_Rr6qn.js +0 -1
- package/dist/SubscriptionSummary.vue_vue_type_script_setup_true_lang-CYyP4ra9.js +0 -1
- package/dist/SubscriptionSummary.vue_vue_type_script_setup_true_lang-CsekphtV.mjs +0 -91
- package/dist/SubscriptionsList.vue_vue_type_script_setup_true_lang-B4j8Clbj.js +0 -1
- package/dist/TooltipParagraph.vue.es-B9A17aG7.mjs +0 -129
- package/dist/TooltipParagraph.vue.es-DvC5Wjaz.js +0 -1
- package/dist/TrialChip.vue.es-CLQZ5F0n.js +0 -1
- package/dist/accel.svg.es-DFJXdioD.js +0 -1
- package/dist/ach.svg.es-BYP873jU.js +0 -1
- package/dist/adyen-BJfC7N6f.js +0 -1
- package/dist/adyenSdk-BP2XXzeJ.js +0 -1
- package/dist/amazon-pay.svg.es-CQWgtowB.js +0 -1
- package/dist/amex.svg.es-DKhW4Txt.js +0 -1
- package/dist/api.es-duCDtZD9.js +0 -1
- package/dist/apple-pay.svg.es-Dyojd0F-.js +0 -1
- package/dist/bacs.svg.es-GJpZs1sD.js +0 -1
- package/dist/bancontact.svg.es-BQh7nAup.js +0 -1
- package/dist/carnet.svg.es-DY04-F2L.js +0 -1
- package/dist/cartes-bancaires.svg.es-BleHMlkN.js +0 -1
- package/dist/cashapp.svg.es-MwXGYom6.js +0 -1
- package/dist/cn.es-C9Yqq4tg.js +0 -1
- package/dist/comparators.es-OGt19O9U.js +0 -1
- package/dist/components/BillingInformation/BillingInformation.cjs +0 -1
- package/dist/components/BillingInformationForm/BillingInformationForm.cjs +0 -1
- package/dist/components/CustomerPaymentMethods/CustomerPaymentMethods.cjs +0 -1
- package/dist/components/Invoice/Invoice.cjs +0 -1
- package/dist/components/InvoiceDetails/InvoiceDetails.cjs +0 -1
- package/dist/components/InvoiceHeader/InvoiceHeader.cjs +0 -1
- package/dist/components/InvoicesList/InvoicesList.cjs +0 -1
- package/dist/components/PaymentHistory/PaymentHistory.cjs +0 -1
- package/dist/components/PaymentMethodForm/PaymentMethodForm.cjs +0 -1
- package/dist/components/SubscriptionSchedules/SubscriptionSchedules.cjs +0 -1
- package/dist/components/SubscriptionsList/SubscriptionsList.cjs +0 -1
- package/dist/components/WalletBalances/WalletBalances.cjs +0 -1
- package/dist/configuration-akTS7Wiw.js +0 -1
- package/dist/core/index.cjs +0 -1
- package/dist/countryData.es-C4jHBzfo.js +0 -1
- package/dist/customElements-B58FcXIN.mjs +0 -6633
- package/dist/customElements-DUMRMFQ5.js +0 -1215
- package/dist/customer-B3LPAhaD.mjs +0 -31
- package/dist/customer-CisTPaXj.js +0 -1
- package/dist/customer.es-B5ppZf0j.mjs +0 -20
- package/dist/customer.es-BButyYo0.js +0 -1
- package/dist/dana.svg.es-BDtZLpwd.js +0 -1
- package/dist/dankort.svg.es-CksaipXF.js +0 -1
- package/dist/de-DE-B4TUdnUf.js +0 -1
- package/dist/de-DE-DL74pMLb.js +0 -1
- package/dist/diners.svg.es-D6Mu1pqP.js +0 -1
- package/dist/discover.svg.es-DgqWCMUM.js +0 -1
- package/dist/eftpos.svg.es-Dk2DOT8W.js +0 -1
- package/dist/elo.svg.es-C-BzjuRP.js +0 -1
- package/dist/en-US-B2XFj-_p.js +0 -1
- package/dist/en-US-DQ5vlv9Z.mjs +0 -339
- package/dist/en-US-J85TQRI8.js +0 -1
- package/dist/en-US-SDhjlY_v.mjs +0 -301
- package/dist/eps.svg.es-B_85bP-W.js +0 -1
- package/dist/error-BHVZJGwD.mjs +0 -13
- package/dist/error-CmduqgVq.js +0 -1
- package/dist/floating-ui.vue.es-Bly3DGWm.js +0 -1
- package/dist/floating-ui.vue.es-CYt0fSY7.mjs +0 -1108
- package/dist/formControl-ODrpUvcA.js +0 -1
- package/dist/formControl-dX7l8o3c.mjs +0 -845
- package/dist/formatting.es-C72Nsrmh.js +0 -1
- package/dist/gcash.svg.es-BKAdhWzv.js +0 -1
- package/dist/getComposedString.es-haS4bAj7.js +0 -1
- package/dist/getCountryNameByCode.es-Xxc0nZsH.js +0 -1
- package/dist/girocard.svg.es-HSOEvDif.js +0 -1
- package/dist/go-pay.svg.es-DQjtunZ_.js +0 -1
- package/dist/google-pay.svg.es-hzc_EgiJ.js +0 -1
- package/dist/hipercard.svg.es-CbCsRY2q.js +0 -1
- package/dist/icon-sprite.svg.es-BZIz7-0d.mjs +0 -4
- package/dist/icon-sprite.svg.es-Ds6lDf5p.js +0 -1
- package/dist/ideal.svg.es-Booz1IML.js +0 -1
- package/dist/index-BPZPnOQQ.js +0 -7
- package/dist/index.cjs +0 -1
- package/dist/index.es-BclokHQX.js +0 -1
- package/dist/invoices-CKQBLar2.js +0 -1
- package/dist/it-IT-CSYvGmpT.js +0 -1
- package/dist/it-IT-CqNK62qe.js +0 -1
- package/dist/jcb.svg.es-B3WPB8c2.js +0 -1
- package/dist/kakao-pay.svg.es-Cs-lCW74.js +0 -1
- package/dist/klarna.svg.es-Cs6XaHD7.js +0 -1
- package/dist/maestro.svg.es-BvK4oPg4.js +0 -1
- package/dist/mastercard.svg.es-lp4AXyyV.js +0 -1
- package/dist/momo.svg.es-C5aLYf_R.js +0 -1
- package/dist/nl-NL-CpE4IgwO.js +0 -1
- package/dist/nl-NL-Dx-TNXQ1.js +0 -1
- package/dist/nyce.svg.es-ArAivAZW.js +0 -1
- package/dist/object.es-CdriXMPs.js +0 -1
- package/dist/open-banking.svg.es-Q3rRkCvP.js +0 -1
- package/dist/paymentFailure-Bh60UhxA.mjs +0 -47
- package/dist/paymentFailure-Cki8c5BX.js +0 -1
- package/dist/paymentMethods-CWlvwK5V.mjs +0 -77
- package/dist/paymentMethods-Cw-i95mM.js +0 -1
- package/dist/payments-2qeQdpiW.mjs +0 -45
- package/dist/payments-CS7_YcOW.js +0 -1
- package/dist/paypal.svg.es-Cjp5sNI3.js +0 -1
- package/dist/pricing-BOqG21f9.js +0 -1
- package/dist/pricing.es-C07bgEZx.js +0 -1
- package/dist/pricingItemConfigs.es-D4aYkYcf.js +0 -1
- package/dist/pricingItemConfigs.es-ORxsk_YS.mjs +0 -77
- package/dist/pricingPlanSchedule-BM8vsKkV.js +0 -1
- package/dist/pricingPlanSchedules-B_sTAIgU.js +0 -1
- package/dist/pricingPlanSchedules-ChQCbMfe.mjs +0 -32
- package/dist/pulse.svg.es-Dit33E8S.js +0 -1
- package/dist/screens/Checkout/Checkout.cjs +0 -1
- package/dist/screens/CustomerOverview/CustomerOverview.cjs +0 -1
- package/dist/screens/PayInvoice/PayInvoice.cjs +0 -1
- package/dist/screens/PaymentMethodsManagement/PaymentMethodsManagement.cjs +0 -1
- package/dist/screens/SubscriptionDetails/SubscriptionDetails.cjs +0 -1
- package/dist/screens/SubscriptionManagement/SubscriptionManagement.cjs +0 -1
- package/dist/sepa.svg.es-0t4DKeA1.js +0 -1
- package/dist/sessionReference-3h-6FdrC.mjs +0 -43
- package/dist/sessionReference-m_6Rp4X1.js +0 -1
- package/dist/slots.es-T9ZJRGtG.js +0 -1
- package/dist/sorting.es-DCihKqD2.mjs +0 -77
- package/dist/sorting.es-DQsjKr8A.js +0 -1
- package/dist/star.svg.es-D2JncY7b.js +0 -1
- package/dist/subscription-D1yHKUNc.mjs +0 -69
- package/dist/subscription-ZA62t4E9.js +0 -1
- package/dist/subscriptions-DcfcBYAq.mjs +0 -55
- package/dist/subscriptions-DwVsf4Ev.js +0 -1
- package/dist/trustly.svg.es-GJByiFAs.js +0 -1
- package/dist/twint.svg.es-BJ2f48og.js +0 -1
- package/dist/typeGuards.es-DS3vZaJn.js +0 -1
- package/dist/types/components/payments/AddPaymentMethodModal/AddPaymentMethodModal.types.d.ts +0 -14
- package/dist/types/components/payments/SubscriptionPaymentCompletedCard/SubscriptionPaymentCompletedCard.types.d.ts +0 -3
- package/dist/types/components/subscriptions/PlanCustomizationForm/AddonSingleEditor.types.d.ts +0 -5
- package/dist/types/services/portals.types.d.ts +0 -70
- package/dist/types/types/subscription.d.ts +0 -4
- package/dist/unionpay.svg.es-DjFZ5EMQ.js +0 -1
- package/dist/url-TNRgVI8A.mjs +0 -21
- package/dist/url-vloPOiXd.js +0 -1
- package/dist/useActionDispatchProvider-B3AvkLL2.mjs +0 -11
- package/dist/useActionDispatchProvider-DFhppdve.js +0 -1
- package/dist/useCustomer-BwZKd9i5.js +0 -1
- package/dist/useCustomerFormLabels-BQk3d9PZ.mjs +0 -968
- package/dist/useCustomerFormLabels-DV9QiMYh.js +0 -1
- package/dist/useExperimentalFeature-BciA3Ok9.mjs +0 -135
- package/dist/useExperimentalFeature-CGIkgFR4.js +0 -1
- package/dist/useIncrementalLoading-CaWOE8Xl.js +0 -1
- package/dist/useIncrementalLoading-Cgxw2GD7.mjs +0 -48
- package/dist/useInvoiceData-BocKdeg7.mjs +0 -38
- package/dist/useInvoiceData-CNV_FMV8.js +0 -1
- package/dist/useInvoicesList-C8nsXMJ6.mjs +0 -500
- package/dist/useInvoicesList-S0IbQcrD.js +0 -1
- package/dist/useLoadInitialData-D9GkzY8t.mjs +0 -15
- package/dist/useLoadInitialData-D_R6Jy1s.js +0 -1
- package/dist/usePaymentMethodAvailability-BO_guwAw.js +0 -1
- package/dist/usePaymentMethodOptions-1vRAo6Ib.mjs +0 -39
- package/dist/usePaymentMethodOptions-CuzOoi2k.js +0 -1
- package/dist/usePaymentMethods-CbwnGONc.mjs +0 -15
- package/dist/usePaymentMethods-DDaTZQZp.js +0 -1
- package/dist/usePayments-DDSjo0rH.js +0 -1
- package/dist/usePortal-C27omjhz.js +0 -1
- package/dist/usePortal-C5AsegpS.mjs +0 -11
- package/dist/useService-Bh47bllz.mjs +0 -50
- package/dist/useService-H7BjLg8P.js +0 -1
- package/dist/useSubscription-BZJL0VOA.mjs +0 -210
- package/dist/useSubscription-D787IXY-.js +0 -1
- package/dist/useTimePeriod.es-rzxqUCTu.js +0 -1
- package/dist/useViewport-BgdA2PPt.mjs +0 -29
- package/dist/useViewport-hPRVDWCm.js +0 -1
- package/dist/useWatchDebounced-B8iX7ykx.js +0 -1
- package/dist/useWatchDebounced-BHlBPcXB.mjs +0 -20
- package/dist/visa.svg.es-NY3BHhda.js +0 -1
- package/dist/vpay.svg.es-VViQi42w.js +0 -1
- package/dist/wallets.es-CNIMW5ay.js +0 -1
- package/dist/zip.svg.es-C9S_F31W.js +0 -1
|
@@ -1 +0,0 @@
|
|
|
1
|
-
const e=require("vue"),M=require("./index.es-BclokHQX.js"),L=require("./ContextMenu.vue.es-DUU43tCy.js"),k=require("./Button.vue.es-BzkuglKw.js"),C=require("./slots.es-T9ZJRGtG.js"),X=require("./Avatar.vue.es-BJxSCU76.js"),q=require("./customElements-DUMRMFQ5.js"),Y=require("./IconButton.vue.es-DgQN18Am.js"),J=require("./floating-ui.vue.es-Bly3DGWm.js"),w=60,B="z-index-tracker",Q=()=>({defaultZIndex:w,getZIndex:()=>{const o=document.querySelectorAll(`.${B}`);let i=w;return(o??[]).forEach(s=>{const r=window.getComputedStyle(s).getPropertyValue("z-index");r&&+r>=i&&(i=+r+1)}),i},getTopZIndex:()=>{const o=document.querySelectorAll(`.${B}`);let i=w;return(o??[]).forEach(s=>{const r=window.getComputedStyle(s).getPropertyValue("z-index");r&&+r>i&&(i=+r)}),i},trackingClass:B}),W=e.defineComponent({__name:"Backdrop",props:{blurred:{type:Boolean,default:!1},color:{default:"gray"},zIndex:{}},setup(t){return(n,o)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["fixed inset-0",{"bg-white/90 backdrop-blur":t.blurred&&t.color==="white","bg-white/80":!t.blurred&&t.color==="white","bg-gray-200/90 backdrop-blur":t.blurred&&t.color==="gray","bg-gray-200/80":!t.blurred&&t.color==="gray"}]),style:e.normalizeStyle({zIndex:t.zIndex})},[e.renderSlot(n.$slots,"default")],6))}}),_={class:"grow overflow-hidden text-ellipsis"},ee=e.defineComponent({__name:"Title",props:{title:{},subTitle:{},variant:{default:"default"},suffix:{},size:{default:"md"},avatar:{type:Boolean,default:!1},uppercase:{type:Boolean,default:!0},resourceId:{}},setup(t){return(n,o)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["flex text-left",{"gap-4":["md","lg"].includes(t.size),"gap-3":t.size==="sm","gap-2":t.size==="xs"&&t.variant!=="transparent","gap-1":t.size==="xs"&&t.variant==="transparent"}])},[t.avatar&&t.title?(e.openBlock(),e.createBlock(e.unref(X._sfc_main),{key:0,initials:t.title.slice(0,1),"color-hash":t.title,size:["sm","xs"].includes(t.size)?"lg":"xl"},null,8,["initials","color-hash","size"])):e.createCommentVNode("",!0),e.createElementVNode("div",_,[t.title||n.$slots.default?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass([{"text-3xl":t.size==="lg","text-2xl":t.size==="md","text-base":t.size==="sm","text-xs text-subtle":t.size==="xs","text-default":t.size!=="xs",uppercase:t.size==="xs"&&t.uppercase,"font-general-sans":["md","lg"].includes(t.size)},"flex items-center font-semibold"])},[e.renderSlot(n.$slots,"prefix"),e.renderSlot(n.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.title),1)]),e.renderSlot(n.$slots,"suffix",{},()=>[e.createTextVNode(e.toDisplayString(t.suffix),1)])],2)):e.createCommentVNode("",!0),t.subTitle||n.$slots.subTitle&&!e.unref(C.isVnodeEmpty)(n.$slots.subTitle({}))?(e.openBlock(),e.createBlock(e.unref(q._sfc_main),{key:1,variant:"body-sm",color:"secondary","no-spacing":"",class:"mt-1"},{default:e.withCtx(()=>[e.renderSlot(n.$slots,"subTitle",{},()=>[e.createTextVNode(e.toDisplayString(t.subTitle),1)])]),_:3})):e.createCommentVNode("",!0)])],2))}}),te=["aria-label","aria-labelledby","aria-busy"],le={key:0,role:"status",class:"absolute bottom-0 left-0 right-0 top-0 z-10 flex items-center justify-center bg-white/80"},oe={class:"sr-only"},ae={key:1,"data-testid":"modal-top-bar",class:"flex justify-end border-b border-gray-200 py-2 pr-2"},ne={"aria-hidden":"true",class:"sticky top-0 z-10 -mx-6 h-0"},se={"data-testid":"modal-body-content",class:"py-6"},re=["id"],ie={"aria-hidden":"true",class:"sticky bottom-0 z-10 -mx-6 h-0"},de={key:0},ce={key:3,"data-testid":"modal-footer",class:"border-t border-gray-200 px-6 py-3 [&_button]:w-full"},ue={class:"flex flex-col gap-2"},fe=e.defineComponent({__name:"Modal",props:{children:{default:()=>[]},size:{default:"2xl"},noCloseButton:{type:Boolean,default:!1},noClickAway:{type:Boolean,default:!1},noBackdropClose:{type:Boolean,default:!1},showModal:{type:Boolean,default:!1},blurred:{type:Boolean,default:!1},title:{},subTitle:{},confirmButtonText:{},cancelButtonText:{},overflowVisible:{type:Boolean},isLoading:{type:Boolean,default:!1},isEmbedded:{type:Boolean,default:!1},ariaLabel:{},ariaLabelledby:{}},emits:["confirm","close"],setup(t,{emit:n}){const o=t,i=n,s=e.useSlots(),{$t:r}=q.useIntl(),z=e.computed(()=>{var l,a;return!!((l=s.body)!=null&&l.call(s))&&!C.isVnodeEmpty((a=s.body)==null?void 0:a.call(s,{}))}),u=e.computed(()=>{var l,a;return!!o.title||!!((l=s.header)!=null&&l.call(s))&&!C.isVnodeEmpty((a=s.header)==null?void 0:a.call(s,{}))}),D=e.computed(()=>z.value||u.value),{getZIndex:A,getTopZIndex:Z,trackingClass:R,defaultZIndex:E}=Q(),m=e.ref(),c=e.ref(),f=e.ref(E),p=e.useId(),V=e.computed(()=>{if(o.ariaLabelledby)return o.ariaLabelledby;if(!o.ariaLabel&&!o.title&&u.value)return p}),F=e.computed(()=>{if(!V.value)return o.ariaLabel||o.title||void 0}),S=e.ref(!1),N=e.ref(!1),K=e.computed(()=>o.blurred||o.isEmbedded),O={xs:"max-w-xs",sm:"max-w-sm",md:"max-w-md",lg:"max-w-lg",xl:"max-w-xl","2xl":"max-w-2xl","3xl":"max-w-3xl","4xl":"max-w-4xl","5xl":"max-w-5xl","6xl":"max-w-6xl","7xl":"max-w-7xl"},U=["a[href]","button:not([disabled])",'input:not([disabled]):not([type="hidden"])',"select:not([disabled])","textarea:not([disabled])",'[contenteditable="true"]','[tabindex]:not([tabindex^="-"])'].join(","),y=e.ref(null),T=()=>c.value?Array.from(c.value.querySelectorAll(U)).filter(l=>!l.closest('[aria-hidden="true"]')):[],j=()=>{const l=c.value;if(!l)return;(l.querySelector("[autofocus]")??T()[0]??l).focus()},I=()=>o.showModal&&f.value>=Z(),b=()=>i("close"),H=()=>{o.noBackdropClose||b()},G=()=>{if(!m.value)return;const{scrollTop:l,scrollHeight:a,clientHeight:d}=m.value;S.value=l>0,N.value=l+d<a-1};M.onKeyStroke("Escape",()=>{o.noClickAway||!I()||b()}),M.onKeyStroke("Tab",l=>{const a=c.value;if(!a||!I())return;const d=T();if(!d.length){l.preventDefault(),a.focus();return}const v=d[0],h=d[d.length-1],g=document.activeElement;if(!a.contains(g)){l.preventDefault(),(l.shiftKey?h:v).focus();return}l.shiftKey&&g===v?(l.preventDefault(),h.focus()):!l.shiftKey&&g===h&&(l.preventDefault(),v.focus())});const x=l=>{const a=document.querySelector("body");a&&(a.style.overflowY=l)},$=async()=>{f.value=A(),x("hidden"),y.value=document.activeElement,await e.nextTick(),j()},P=()=>{var l;f.value=E,x("unset"),(l=y.value)==null||l.focus(),y.value=null};return e.watch(()=>o.showModal,l=>l?$():P()),e.onMounted(()=>{o.showModal&&$()}),e.onBeforeUnmount(()=>{x("unset")}),(l,a)=>(e.openBlock(),e.createBlock(e.unref(L._sfc_main),{to:"modal"},{default:e.withCtx(()=>[e.createVNode(e.Transition,{name:"modal",appear:""},{default:e.withCtx(()=>[t.showModal?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["h-modal z-60 fixed left-0 right-0 top-0 flex w-full items-center justify-center overflow-y-auto overflow-x-hidden md:inset-0 md:h-full",e.unref(R)]),style:e.normalizeStyle({zIndex:f.value})},[e.createVNode(e.unref(W),{"aria-hidden":"true",blurred:K.value,color:o.isEmbedded?"white":void 0,onMousedown:e.withModifiers(H,["self"])},null,8,["blurred","color"]),e.createElementVNode("div",{class:e.normalizeClass(["modal-panel relative h-full w-full p-4 md:h-auto",`${O[t.size]}`])},[e.createElementVNode("div",{ref_key:"dialogElementRef",ref:c,role:"dialog","aria-modal":"true",tabindex:"-1","aria-label":F.value,"aria-labelledby":V.value,"aria-busy":t.isLoading,class:"relative flex max-h-[min(95vh,920px)] flex-col rounded-xl bg-white shadow-lg focus:outline-none"},[t.isLoading?(e.openBlock(),e.createElementBlock("div",le,[e.createVNode(k._sfc_main$2,{size:"6","aria-hidden":"true"}),e.createElementVNode("span",oe,e.toDisplayString(e.unref(r)({defaultMessage:"Loading",id:"h+GlcT",description:"Modal loading state"})),1)])):e.createCommentVNode("",!0),t.noCloseButton?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",ae,[e.createVNode(e.unref(Y._sfc_main),{icon:"close",size:"xs",intent:"secondary","data-testid":"close-button","aria-label":e.unref(r)({defaultMessage:"Close",id:"U+ONwt",description:"Modal close button"}),onClick:b},null,8,["aria-label"])])),D.value?(e.openBlock(),e.createElementBlock("div",{key:2,ref_key:"contentElementRef",ref:m,class:e.normalizeClass(["overflow-auto px-6",{"overflow-visible":t.overflowVisible}]),onScroll:G},[e.createElementVNode("div",ne,[e.createElementVNode("div",{class:e.normalizeClass(["transition-duration-700 pointer-events-none h-6 w-full bg-gradient-to-b from-black/[.06] to-transparent transition-opacity",S.value?"opacity-100":"opacity-0"])},null,2)]),e.createElementVNode("div",se,[u.value?(e.openBlock(),e.createElementBlock("div",{key:0,id:e.unref(p)},[e.renderSlot(l.$slots,"header",{},()=>[t.title?(e.openBlock(),e.createBlock(ee,{key:0,title:t.title,"sub-title":t.subTitle,size:"md"},null,8,["title","sub-title"])):e.createCommentVNode("",!0)],!0)],8,re)):e.createCommentVNode("",!0),z.value?(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass({"mt-4":u.value})},[e.renderSlot(l.$slots,"body",{},void 0,!0)],2)):e.createCommentVNode("",!0)]),e.createElementVNode("div",ie,[e.createElementVNode("div",{class:e.normalizeClass(["transition-duration-700 pointer-events-none h-6 w-full -translate-y-6 bg-gradient-to-t from-black/[.06] to-transparent transition-opacity",N.value?"opacity-100":"opacity-0"])},null,2)])],34)):e.createCommentVNode("",!0),e.createVNode(L.Fade,null,{default:e.withCtx(()=>[l.$slots.error?(e.openBlock(),e.createElementBlock("div",de,[e.renderSlot(l.$slots,"error",{},void 0,!0)])):e.createCommentVNode("",!0)]),_:3}),l.$slots.footer||t.confirmButtonText||t.cancelButtonText?(e.openBlock(),e.createElementBlock("div",ce,[e.renderSlot(l.$slots,"footer",{},()=>[e.createElementVNode("div",ue,[e.createVNode(e.unref(k._sfc_main),{size:"md",autofocus:"",loading:t.isLoading,onClick:a[0]||(a[0]=d=>l.$emit("confirm"))},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.confirmButtonText||e.unref(r)({defaultMessage:"Confirm",id:"N2IrpM",description:"Modal comfirm button"})),1)]),_:1},8,["loading"]),e.createVNode(e.unref(k._sfc_main),{size:"md",intent:"secondary",onClick:a[1]||(a[1]=d=>l.$emit("close"))},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.cancelButtonText||e.unref(r)({defaultMessage:"Cancel",id:"47FYwb",description:"Modal cancel button"})),1)]),_:1})])],!0)])):e.createCommentVNode("",!0)],8,te)],2)],6)):e.createCommentVNode("",!0)]),_:3})]),_:3}))}}),me=J._export_sfc(fe,[["__scopeId","data-v-f0b441a8"]]);exports.Modal=me;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
const e=require("vue"),f=require("./formatting.es-C72Nsrmh.js"),l=require("./Button.vue.es-BzkuglKw.js"),n=require("./customElements-DUMRMFQ5.js"),u=require("./PaymentFeedbackCard.vue_vue_type_script_setup_true_lang-B9R5JRJv.js"),_=require("./IconButton.vue.es-DgQN18Am.js"),h=()=>{const t=e.ref(null);return[async r=>{if(!(navigator!=null&&navigator.clipboard))return!1;try{return await navigator.clipboard.writeText(r),t.value=r,!0}catch{return t.value=null,!1}},t.value]},y=e.defineComponent({__name:"PaymentCompletedCard",props:{amount:{type:Object},variant:{type:String},redirecting:{type:Boolean}},setup(t){const a=t,{$t:r}=n.useIntl(),o=e.computed(()=>a.variant==="AUTHORIZE"?r({defaultMessage:"Payment successful",description:"The title for when a payment has been successful",id:"payment_completed_card.title.authorize"}):r({defaultMessage:"Your payment method is added",description:"The title for when a payment method was successfully added",id:"payment_completed_card.title.tokenize"}));return(i,s)=>(e.openBlock(),e.createBlock(u._sfc_main,{status:"success",title:o.value},{default:e.withCtx(()=>[t.amount?(e.openBlock(),e.createBlock(e.unref(n._sfc_main),{key:0,variant:"body-sm",class:"mt-1"},{default:e.withCtx(()=>[e.createVNode(e.unref(l._sfc_main$1),{icon:"check"}),e.createTextVNode(e.toDisplayString(e.unref(f.formatAmount)(t.amount)),1)]),_:1})):e.createCommentVNode("",!0),t.redirecting?(e.openBlock(),e.createBlock(e.unref(n._sfc_main),{key:1,variant:"body-xs",color:"subtle"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(r)({defaultMessage:"You are being redirected...",description:"The text shown after a successful message before a redirect",id:"payment_completed_card.redirect_message"})),1)]),_:1})):e.createCommentVNode("",!0)]),_:1},8,["title"]))}});function g(t){return{UNKNOWN_ERROR:{title:t({defaultMessage:"Something went wrong",description:"Title of the error card shown when a payment failed for no known reason",id:"payments.error_card.unknown_error.title"}),message:t({defaultMessage:"An unknown error has occurred",description:"Message of the error card shown when a payment failed for no known reason",id:"payments.error_card.unknown_error.message"}),isReloadButtonVisible:!0},AUTHORIZATION_FAILED:{title:t({defaultMessage:"Payment failed",description:"Title of the error card shown when a payment was not authorized",id:"payments.error_card.authorization_failed.title"}),message:t({defaultMessage:"The payment could not be completed. Try again, or use a different payment method.",description:"Message of the error card shown when a payment was not authorized",id:"payments.error_card.authorization_failed.message"}),isReloadButtonVisible:!0},PAYMENT_DETAILS_CALL_FAILED:{title:t({defaultMessage:"Payment could not be confirmed",description:"Title of the error card shown when the payment details could not be retrieved",id:"payments.error_card.payment_details_call_failed.title"}),message:t({defaultMessage:"There was a problem confirming your payment.",description:"Message of the error card shown when the payment details could not be retrieved",id:"payments.error_card.payment_details_call_failed.message"}),isReloadButtonVisible:!0},PAYMENT_METHOD_STORAGE_FAILED:{title:t({defaultMessage:"Payment method could not be saved",description:"Title of the error card shown when storing a payment method failed",id:"payments.error_card.payment_method_storage_failed.title"}),message:t({defaultMessage:"Something went wrong while saving your payment method.",description:"Message of the error card shown when storing a payment method failed",id:"payments.error_card.payment_method_storage_failed.message"}),isReloadButtonVisible:!0},REDIRECT_RESULT_PAYMENT_ACCEPTOR_MISSING:{title:t({defaultMessage:"Payment could not be completed",description:"Title of the error card shown when a redirect returned without a payment acceptor",id:"payments.error_card.redirect_result_payment_acceptor_missing.title"}),message:t({defaultMessage:"Your payment could not be matched to this order.",description:"Message of the error card shown when a redirect returned without a payment acceptor",id:"payments.error_card.redirect_result_payment_acceptor_missing.message"})},TOKENIZE_FAILED:{title:t({defaultMessage:"Payment method could not be saved",description:"Title of the error card shown when tokenization failed",id:"payments.error_card.tokenize_failed.title"}),message:t({defaultMessage:"Your payment method could not be saved. Try again, or use a different one.",description:"Message of the error card shown when tokenization failed",id:"payments.error_card.tokenize_failed.message"}),isReloadButtonVisible:!0},PAYMENT_INTEGRATION_INITIALIZATION_FAILED:{title:t({defaultMessage:"Payment methods could not be loaded",description:"Title of the error card shown when the payment form failed to load",id:"payments.error_card.payment_integration_initialization_failed.title"}),message:t({defaultMessage:"The payment form could not be loaded.",description:"Message of the error card shown when the payment form failed to load",id:"payments.error_card.payment_integration_initialization_failed.message"}),isReloadButtonVisible:!0},RESOURCE_REVOKED:{title:t({defaultMessage:"This page is no longer available",description:"Title of the error card shown when the portal resource was revoked",id:"payments.error_card.resource_revoked.title"}),message:t({defaultMessage:"The link you followed has expired or was withdrawn.",description:"Message of the error card shown when the portal resource was revoked",id:"payments.error_card.resource_revoked.message"}),isReloadButtonVisible:!0}}}const w=2e3;function b({resetAfterMs:t=w}={}){const[a]=h(),r=e.ref(!1);let o;const i=async s=>{const d=await a(s);return r.value=d,d&&(clearTimeout(o),o=setTimeout(()=>{r.value=!1},t)),d};return e.onBeforeUnmount(()=>clearTimeout(o)),{copy:i,hasCopied:r}}const T={class:"flex flex-col items-center gap-6"},v={key:1,class:"flex flex-col items-center gap-1"},C={class:"flex items-center gap-1"},M=e.defineComponent({__name:"PaymentErrorCard",props:{error:{type:Object}},setup(t){const a=t,{$t:r}=n.useIntl(),{copy:o,hasCopied:i}=b(),s=e.computed(()=>g(r)[a.error.code]),d=()=>{window.location.reload()},c=e.computed(()=>r({defaultMessage:"Copy reference",description:"Label of the button that copies the payment error reference",id:"payments.error_card.reference.copy.label"})),m=e.computed(()=>r({defaultMessage:"Copied",description:"Confirmation shown after copying the payment error reference",id:"payments.error_card.reference.copied.label"})),p=()=>{a.error.reference&&o(a.error.reference)};return(k,E)=>(e.openBlock(),e.createBlock(u._sfc_main,{status:"error",title:s.value.title},{default:e.withCtx(()=>[e.createElementVNode("div",T,[e.createVNode(e.unref(n._sfc_main),{variant:"body-xs",color:"subtle",class:"mt-3"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(s.value.message),1)]),_:1}),s.value.isReloadButtonVisible?(e.openBlock(),e.createBlock(e.unref(l._sfc_main),{key:0,type:"button",intent:"secondary",onClick:d},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(r)({defaultMessage:"Try again",description:"Retry button text when an error has happened during a payment",id:"payments.retry_button.label"})),1)]),_:1})):e.createCommentVNode("",!0),t.error.reference?(e.openBlock(),e.createElementBlock("div",v,[e.createVNode(e.unref(n._sfc_main),{variant:"body-xs",color:"subtle"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(r)({defaultMessage:"Share this reference with support if the problem continues",description:"Explains what the reference below a failed payment is for",id:"payments.error_card.reference.description"})),1)]),_:1}),e.createElementVNode("div",C,[e.createVNode(e.unref(n._sfc_main),{variant:"body-xs",tag:"span",class:"select-all font-mono"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.error.reference),1)]),_:1}),e.createVNode(e.unref(_._sfc_main),{type:"button",intent:"subtle",size:"sm",icon:e.unref(i)?"check":"content_copy","aria-label":c.value,tooltip:e.unref(i)?m.value:c.value,onClick:p},null,8,["icon","aria-label","tooltip"])])])):e.createCommentVNode("",!0)])]),_:1},8,["title"]))}});exports._sfc_main=y;exports._sfc_main$1=M;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
const e=require("vue"),n=require("./Button.vue.es-BzkuglKw.js"),a=require("./Section.vue.es-Bbt0RITt.js"),c=require("./customElements-DUMRMFQ5.js"),r={class:"flex flex-col items-center py-10"},i=e.defineComponent({__name:"PaymentFeedbackCard",props:{status:{default:"success",type:String},title:{type:String}},setup(t){return(s,l)=>(e.openBlock(),e.createBlock(e.unref(a._sfc_main),null,{default:e.withCtx(()=>[e.createElementVNode("div",r,[e.createVNode(e.unref(n._sfc_main$1),{icon:t.status==="success"?"check_circle":"error",class:e.normalizeClass({"text-green-400":t.status==="success","text-red-600":t.status==="error"}),size:"lg"},null,8,["icon","class"]),e.createVNode(e.unref(c._sfc_main),{variant:"heading-3",tag:"span",class:"mt-2"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.title),1)]),_:1}),s.$slots.default?(e.openBlock(),e.createBlock(e.unref(c._sfc_main),{key:0,tag:"div",variant:"body-sm"},{default:e.withCtx(()=>[e.renderSlot(s.$slots,"default")]),_:3})):e.createCommentVNode("",!0)])]),_:3}))}});exports._sfc_main=i;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./PaymentHistoryBlock.vue_vue_type_script_setup_true_lang-ALI5f0py.js");exports.default=e._sfc_main;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
const e=require("vue"),o=require("./PaymentMethod.vue.es-D0D9jW8s.js"),c=require("./formatting.es-C72Nsrmh.js"),m=require("./Chip.vue.es-B2jjzIOc.js"),_=require("./Section.vue.es-Bbt0RITt.js"),n=require("./customElements-DUMRMFQ5.js"),d={class:"sv-payment-history"},l={class:"sv-payment-history__items flex flex-col-reverse gap-1"},y={class:"sv-payment-history__item-header mb-2 flex items-center justify-between"},u=e.defineComponent({__name:"PaymentHistoryBlock",props:{paymentAttempts:{type:Array},customer:{type:Object}},setup(s){const{$t:a,formatDate:i}=n.useIntl(),r={AUTHORIZED:"success",CANCELLED:"danger",ERROR:"danger",PENDING:"warning",PENDING_REFUND:"warning",REFUNDED:"warning",CHARGED_BACK:"warning",REFUSED:"danger"};return(f,p)=>(e.openBlock(),e.createElementBlock("div",d,[e.createVNode(e.unref(n._sfc_main),{tag:"h2",variant:"heading-3",class:"sv-payment-history__title"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(a)({defaultMessage:"Payment history",description:"Title for the payment history block on the invoice details page",id:"sdk.invoice_details.payment_history.title"})),1)]),_:1}),e.createElementVNode("div",l,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.paymentAttempts,t=>(e.openBlock(),e.createBlock(e.unref(_._sfc_main),{key:t.id,class:"sv-payment-history__item mt-1 md:mt-2"},{default:e.withCtx(()=>[e.createElementVNode("div",y,[e.createVNode(e.unref(n._sfc_main),{variant:"caps-heading",class:"sv-payment-history__item-title"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(a)({defaultMessage:"Payment attempt",description:"Title for the payment attempt block",id:"sdk.invoice_details.payment_history.payment_attempt"})),1)]),_:1}),e.createVNode(e.unref(m._sfc_main),{class:"sv-payment-history__item-status",intent:r[t.result]},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(c.formatEnum)(t.result)),1)]),_:2},1032,["intent"])]),t.payment_method_details?(e.openBlock(),e.createBlock(e.unref(o._sfc_main),{key:0,class:"sv-payment-history__payment-method","payment-method":t.payment_method_details},{description:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(i)({date:t.created_at,format:"dateTime",offsetType:"offsetted",timezone:s.customer.timezone})),1)]),_:2},1032,["payment-method"])):e.createCommentVNode("",!0)]),_:2},1024))),128))])]))}});exports._sfc_main=u;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./PaymentIntegrationForm.vue_vue_type_script_setup_true_lang-B-viSd_i.js");exports.default=e._sfc_main;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
const t=require("vue"),E=require("./FormMessage.vue.es-dqATjC2N.js"),$=require("./customElements-DUMRMFQ5.js"),F=require("./useExperimentalFeature-CGIkgFR4.js"),I=e=>{var i;return((i=e.integration.payment_gateway)==null?void 0:i.variant)==="ADYEN"},b=e=>{var i;return((i=e.integration.payment_gateway)==null?void 0:i.variant)==="STRIPE"},S=({selectedIntegration:e,paymentMethodOption:i})=>{var r,s;return e===((s=(r=i.integration)==null?void 0:r.payment_gateway)==null?void 0:s.variant)},w=(e,{excludeExpressPaymentMethods:i=!1}={})=>{var r;return I(e)?F.getAdyenDropInPaymentMethods(e,{excludeExpressPaymentMethods:i}).length>0:b(e)?!!((r=e.integration.payment_gateway.stripe)!=null&&r.public_key):!1},C=(e,i={})=>e.some(r=>w(r,i)),N=t.defineComponent({__name:"PaymentIntegrationForm",props:{customerId:{type:String},variant:{type:String},context:{type:Object},paymentMethodOptions:{type:Array},countryCode:{type:String},invoiceId:{type:String},amount:{type:Object},selectedOption:{type:String},email:{type:String},name:{type:String},validateOnSubmit:{type:Function},forceStorePaymentMethod:{type:Boolean},storePaymentMethod:{type:Boolean,default:void 0},redirectsOnSuccess:{type:Boolean},billingEntityName:{type:String}},emits:["select","payment-failed","payment-success","invalid","ready"],setup(e,{expose:i,emit:r}){const s=t.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./PaymentIntegrationFormStripe-CoLmAzas.js")).then(n=>n.default)),P=t.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./PaymentIntegrationFormAdyen-B-v-4nlj.js")).then(n=>n.default)),l=e,c=r;i({submit:h});const{$t:k}=$.useIntl(),y=t.ref(),u=t.computed(()=>{var n,a;return y.value??((a=(n=l.paymentMethodOptions[0])==null?void 0:n.integration.payment_gateway)==null?void 0:a.variant)}),v=t.ref(new Map),d=t.ref(!1),g=({paymentGatewayVariant:n,paymentMethodType:a})=>{d.value=!1,y.value=n,c("select",{paymentGatewayVariant:n,paymentMethodType:a})},f=n=>a=>{var o;return v.value.set((o=n.integration.payment_gateway)==null?void 0:o.variant,a)},B=n=>{n==="NO_PAYMENT_METHOD"&&(d.value=!0),c("invalid",n)};function h(){var a;if(!u.value){d.value=!0,(a=l.validateOnSubmit)==null||a.call(l),c("invalid");return}const n=v.value.get(u.value);if(!n){c("invalid");return}n.submit()}return(n,a)=>(t.openBlock(),t.createElementBlock(t.Fragment,null,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.paymentMethodOptions,o=>(t.openBlock(),t.createElementBlock(t.Fragment,{key:o.integration.id},[t.unref(I)(o)?(t.openBlock(),t.createBlock(t.unref(P),{key:0,ref_for:!0,ref:f(o),context:e.context,"payment-method-option-response-entry":o,"country-code":e.countryCode,"customer-id":e.customerId,variant:e.variant,amount:e.amount,"invoice-id":e.invoiceId,selected:t.unref(S)({selectedIntegration:u.value,paymentMethodOption:o}),"validate-on-submit":e.validateOnSubmit,"force-store-payment-method":e.forceStorePaymentMethod,"store-payment-method":e.storePaymentMethod,"redirects-on-success":e.redirectsOnSuccess,"billing-entity-name":e.billingEntityName,onSelect:g,onPaymentFailed:a[0]||(a[0]=m=>n.$emit("payment-failed",m)),onPaymentSuccess:a[1]||(a[1]=m=>n.$emit("payment-success")),onInvalid:B,onReady:a[2]||(a[2]=m=>n.$emit("ready"))},null,8,["context","payment-method-option-response-entry","country-code","customer-id","variant","amount","invoice-id","selected","validate-on-submit","force-store-payment-method","store-payment-method","redirects-on-success","billing-entity-name"])):t.unref(b)(o)?(t.openBlock(),t.createBlock(t.unref(s),{key:1,ref_for:!0,ref:f(o),context:e.context,"payment-method-option-response-entry":o,"country-code":e.countryCode,"customer-id":e.customerId,variant:e.variant,amount:e.amount,"invoice-id":e.invoiceId,selected:t.unref(S)({selectedIntegration:u.value,paymentMethodOption:o}),email:e.email,name:e.name,"validate-on-submit":e.validateOnSubmit,"force-store-payment-method":e.forceStorePaymentMethod,"store-payment-method":e.storePaymentMethod,"redirects-on-success":e.redirectsOnSuccess,"billing-entity-name":e.billingEntityName,onSelect:g,onPaymentFailed:a[3]||(a[3]=m=>n.$emit("payment-failed",m)),onPaymentSuccess:a[4]||(a[4]=m=>n.$emit("payment-success")),onInvalid:a[5]||(a[5]=m=>n.$emit("invalid")),onReady:a[6]||(a[6]=m=>n.$emit("ready"))},null,8,["context","payment-method-option-response-entry","country-code","customer-id","variant","amount","invoice-id","selected","email","name","validate-on-submit","force-store-payment-method","store-payment-method","redirects-on-success","billing-entity-name"])):t.createCommentVNode("",!0)],64))),128)),d.value?(t.openBlock(),t.createBlock(t.unref(E._sfc_main),{key:0,variant:"error",class:"mt-2"},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(t.unref(k)({defaultMessage:"Select a payment method",id:"payment_integration_form.select_payment_method_error",description:"Error shown when no payment method is selected"})),1)]),_:1})):t.createCommentVNode("",!0)],64))}});exports._sfc_main=N;exports.hasRenderablePaymentIntegration=C;
|
|
@@ -1,154 +0,0 @@
|
|
|
1
|
-
import { defineComponent as p, defineAsyncComponent as h, ref as v, computed as B, openBlock as s, createElementBlock as g, Fragment as f, renderList as x, unref as m, createBlock as S, createCommentVNode as w, withCtx as D, createTextVNode as O, toDisplayString as T } from "vue";
|
|
2
|
-
import { _ as M } from "./FormMessage.vue.es-jG3fQZms.mjs";
|
|
3
|
-
import { a as j } from "./customElements-B58FcXIN.mjs";
|
|
4
|
-
import { g as Y } from "./useExperimentalFeature-BciA3Ok9.mjs";
|
|
5
|
-
const k = (e) => {
|
|
6
|
-
var i;
|
|
7
|
-
return ((i = e.integration.payment_gateway) == null ? void 0 : i.variant) === "ADYEN";
|
|
8
|
-
}, N = (e) => {
|
|
9
|
-
var i;
|
|
10
|
-
return ((i = e.integration.payment_gateway) == null ? void 0 : i.variant) === "STRIPE";
|
|
11
|
-
}, E = ({
|
|
12
|
-
selectedIntegration: e,
|
|
13
|
-
paymentMethodOption: i
|
|
14
|
-
}) => {
|
|
15
|
-
var o, d;
|
|
16
|
-
return e === ((d = (o = i.integration) == null ? void 0 : o.payment_gateway) == null ? void 0 : d.variant);
|
|
17
|
-
}, H = (e, { excludeExpressPaymentMethods: i = !1 } = {}) => {
|
|
18
|
-
var o;
|
|
19
|
-
return k(e) ? Y(e, { excludeExpressPaymentMethods: i }).length > 0 : N(e) ? !!((o = e.integration.payment_gateway.stripe) != null && o.public_key) : !1;
|
|
20
|
-
}, J = (e, i = {}) => e.some(
|
|
21
|
-
(o) => H(o, i)
|
|
22
|
-
), K = /* @__PURE__ */ p({
|
|
23
|
-
__name: "PaymentIntegrationForm",
|
|
24
|
-
props: {
|
|
25
|
-
customerId: { type: String },
|
|
26
|
-
variant: { type: String },
|
|
27
|
-
context: { type: Object },
|
|
28
|
-
paymentMethodOptions: { type: Array },
|
|
29
|
-
countryCode: { type: String },
|
|
30
|
-
invoiceId: { type: String },
|
|
31
|
-
amount: { type: Object },
|
|
32
|
-
selectedOption: { type: String },
|
|
33
|
-
email: { type: String },
|
|
34
|
-
name: { type: String },
|
|
35
|
-
validateOnSubmit: { type: Function },
|
|
36
|
-
forceStorePaymentMethod: { type: Boolean },
|
|
37
|
-
storePaymentMethod: { type: Boolean, default: void 0 },
|
|
38
|
-
redirectsOnSuccess: { type: Boolean },
|
|
39
|
-
billingEntityName: { type: String }
|
|
40
|
-
},
|
|
41
|
-
emits: ["select", "payment-failed", "payment-success", "invalid", "ready"],
|
|
42
|
-
setup(e, { expose: i, emit: o }) {
|
|
43
|
-
const d = h(
|
|
44
|
-
() => import("./PaymentIntegrationFormStripe-Ds0BXt89.mjs").then(
|
|
45
|
-
(t) => t.default
|
|
46
|
-
)
|
|
47
|
-
), A = h(
|
|
48
|
-
() => import("./PaymentIntegrationFormAdyen-Yr8p5Fly.mjs").then(
|
|
49
|
-
(t) => t.default
|
|
50
|
-
)
|
|
51
|
-
), l = e, c = o;
|
|
52
|
-
i({ submit: R });
|
|
53
|
-
const { $t: C } = j(), I = v(), y = B(
|
|
54
|
-
() => {
|
|
55
|
-
var t, n;
|
|
56
|
-
return I.value ?? ((n = (t = l.paymentMethodOptions[0]) == null ? void 0 : t.integration.payment_gateway) == null ? void 0 : n.variant);
|
|
57
|
-
}
|
|
58
|
-
), b = v(/* @__PURE__ */ new Map()), u = v(!1), P = ({
|
|
59
|
-
paymentGatewayVariant: t,
|
|
60
|
-
paymentMethodType: n
|
|
61
|
-
}) => {
|
|
62
|
-
u.value = !1, I.value = t, c("select", { paymentGatewayVariant: t, paymentMethodType: n });
|
|
63
|
-
}, $ = (t) => (n) => {
|
|
64
|
-
var a;
|
|
65
|
-
return b.value.set((a = t.integration.payment_gateway) == null ? void 0 : a.variant, n);
|
|
66
|
-
}, F = (t) => {
|
|
67
|
-
t === "NO_PAYMENT_METHOD" && (u.value = !0), c("invalid", t);
|
|
68
|
-
};
|
|
69
|
-
function R() {
|
|
70
|
-
var n;
|
|
71
|
-
if (!y.value) {
|
|
72
|
-
u.value = !0, (n = l.validateOnSubmit) == null || n.call(l), c("invalid");
|
|
73
|
-
return;
|
|
74
|
-
}
|
|
75
|
-
const t = b.value.get(y.value);
|
|
76
|
-
if (!t) {
|
|
77
|
-
c("invalid");
|
|
78
|
-
return;
|
|
79
|
-
}
|
|
80
|
-
t.submit();
|
|
81
|
-
}
|
|
82
|
-
return (t, n) => (s(), g(f, null, [
|
|
83
|
-
(s(!0), g(f, null, x(e.paymentMethodOptions, (a) => (s(), g(f, {
|
|
84
|
-
key: a.integration.id
|
|
85
|
-
}, [
|
|
86
|
-
m(k)(a) ? (s(), S(m(A), {
|
|
87
|
-
key: 0,
|
|
88
|
-
ref_for: !0,
|
|
89
|
-
ref: $(a),
|
|
90
|
-
context: e.context,
|
|
91
|
-
"payment-method-option-response-entry": a,
|
|
92
|
-
"country-code": e.countryCode,
|
|
93
|
-
"customer-id": e.customerId,
|
|
94
|
-
variant: e.variant,
|
|
95
|
-
amount: e.amount,
|
|
96
|
-
"invoice-id": e.invoiceId,
|
|
97
|
-
selected: m(E)({ selectedIntegration: y.value, paymentMethodOption: a }),
|
|
98
|
-
"validate-on-submit": e.validateOnSubmit,
|
|
99
|
-
"force-store-payment-method": e.forceStorePaymentMethod,
|
|
100
|
-
"store-payment-method": e.storePaymentMethod,
|
|
101
|
-
"redirects-on-success": e.redirectsOnSuccess,
|
|
102
|
-
"billing-entity-name": e.billingEntityName,
|
|
103
|
-
onSelect: P,
|
|
104
|
-
onPaymentFailed: n[0] || (n[0] = (r) => t.$emit("payment-failed", r)),
|
|
105
|
-
onPaymentSuccess: n[1] || (n[1] = (r) => t.$emit("payment-success")),
|
|
106
|
-
onInvalid: F,
|
|
107
|
-
onReady: n[2] || (n[2] = (r) => t.$emit("ready"))
|
|
108
|
-
}, null, 8, ["context", "payment-method-option-response-entry", "country-code", "customer-id", "variant", "amount", "invoice-id", "selected", "validate-on-submit", "force-store-payment-method", "store-payment-method", "redirects-on-success", "billing-entity-name"])) : m(N)(a) ? (s(), S(m(d), {
|
|
109
|
-
key: 1,
|
|
110
|
-
ref_for: !0,
|
|
111
|
-
ref: $(a),
|
|
112
|
-
context: e.context,
|
|
113
|
-
"payment-method-option-response-entry": a,
|
|
114
|
-
"country-code": e.countryCode,
|
|
115
|
-
"customer-id": e.customerId,
|
|
116
|
-
variant: e.variant,
|
|
117
|
-
amount: e.amount,
|
|
118
|
-
"invoice-id": e.invoiceId,
|
|
119
|
-
selected: m(E)({ selectedIntegration: y.value, paymentMethodOption: a }),
|
|
120
|
-
email: e.email,
|
|
121
|
-
name: e.name,
|
|
122
|
-
"validate-on-submit": e.validateOnSubmit,
|
|
123
|
-
"force-store-payment-method": e.forceStorePaymentMethod,
|
|
124
|
-
"store-payment-method": e.storePaymentMethod,
|
|
125
|
-
"redirects-on-success": e.redirectsOnSuccess,
|
|
126
|
-
"billing-entity-name": e.billingEntityName,
|
|
127
|
-
onSelect: P,
|
|
128
|
-
onPaymentFailed: n[3] || (n[3] = (r) => t.$emit("payment-failed", r)),
|
|
129
|
-
onPaymentSuccess: n[4] || (n[4] = (r) => t.$emit("payment-success")),
|
|
130
|
-
onInvalid: n[5] || (n[5] = (r) => t.$emit("invalid")),
|
|
131
|
-
onReady: n[6] || (n[6] = (r) => t.$emit("ready"))
|
|
132
|
-
}, null, 8, ["context", "payment-method-option-response-entry", "country-code", "customer-id", "variant", "amount", "invoice-id", "selected", "email", "name", "validate-on-submit", "force-store-payment-method", "store-payment-method", "redirects-on-success", "billing-entity-name"])) : w("", !0)
|
|
133
|
-
], 64))), 128)),
|
|
134
|
-
u.value ? (s(), S(m(M), {
|
|
135
|
-
key: 0,
|
|
136
|
-
variant: "error",
|
|
137
|
-
class: "mt-2"
|
|
138
|
-
}, {
|
|
139
|
-
default: D(() => [
|
|
140
|
-
O(T(m(C)({
|
|
141
|
-
defaultMessage: "Select a payment method",
|
|
142
|
-
id: "payment_integration_form.select_payment_method_error",
|
|
143
|
-
description: "Error shown when no payment method is selected"
|
|
144
|
-
})), 1)
|
|
145
|
-
]),
|
|
146
|
-
_: 1
|
|
147
|
-
})) : w("", !0)
|
|
148
|
-
], 64));
|
|
149
|
-
}
|
|
150
|
-
});
|
|
151
|
-
export {
|
|
152
|
-
K as _,
|
|
153
|
-
J as h
|
|
154
|
-
};
|
|
@@ -1,98 +0,0 @@
|
|
|
1
|
-
Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("vue"),re=require("./useService-H7BjLg8P.js"),N=require("./customElements-DUMRMFQ5.js"),F=require("./PaymentErrorCard.vue_vue_type_script_setup_true_lang-Dg4rn1cm.js"),ie=require("./payments-CS7_YcOW.js"),U=require("./url-vloPOiXd.js"),de=require("./paymentMethods-Cw-i95mM.js"),y=require("./useExperimentalFeature-CGIkgFR4.js"),se=require("./adyenSdk-BP2XXzeJ.js"),Y=require("./paymentFailure-Cki8c5BX.js"),ce=".adyen-checkout__payment-method--sepadirectdebit .adyen-checkout__payment-method__details__content";function ue(u){return(u==null?void 0:u.querySelector(ce))??null}function me(u,p){return!!u&&!!p&&!u.contains(p)}const pe=u=>{let p={};return u==="TOKENIZE"&&(p={"en-US":{payButton:"Add payment method",confirmPurchase:"Add payment method"},"fr-FR":{payButton:"Ajouter un moyen de paiement",confirmPurchase:"Ajouter un moyen de paiement"},"de-DE":{payButton:"Zahlungsmethode hinzufügen",confirmPurchase:"Zahlungsmethode hinzufügen"},"it-IT":{payButton:"Aggiungi metodo di pagamento",confirmPurchase:"Aggiungi metodo di pagamento"},"es-ES":{payButton:"Añadir método de pago",confirmPurchase:"Añadir método de pago"},"nl-NL":{payButton:"Betaalmethode toevoegen",confirmPurchase:"Betaalmethode toevoegen"},"pt-BR":{payButton:"Adicionar método de pagamento",confirmPurchase:"Adicionar método de pagamento"},"pt-PT":{payButton:"Adicionar método de pagamento",confirmPurchase:"Adicionar método de pagamento"},"pl-PL":{payButton:"Dodaj metodę płatności",confirmPurchase:"Dodaj metodę płatności"},"ru-RU":{payButton:"Добавить способ оплаты",confirmPurchase:"Добавить способ оплаты"},"sv-SE":{payButton:"Lägg till betalningsmetod",confirmPurchase:"Lägg till betalningsmetod"},"da-DK":{payButton:"Tilføj betalingsmetode",confirmPurchase:"Tilføj betalingsmetode"},"fi-FI":{payButton:"Lisää maksutapa",confirmPurchase:"Lisää maksutapa"},"no-NO":{payButton:"Legg til betalingsmetode",confirmPurchase:"Legg til betalingsmetode"},"cs-CZ":{payButton:"Přidat platební metodu",confirmPurchase:"Přidat platební metodu"},"hu-HU":{payButton:"Fizetési mód hozzáadása",confirmPurchase:"Fizetési mód hozzáadása"},"ro-RO":{payButton:"Adăugați metodă de plată",confirmPurchase:"Adăugați metodă de plată"},"ja-JP":{payButton:"支払い方法を追加",confirmPurchase:"支払い方法を追加"},"ko-KR":{payButton:"결제 수단 추가",confirmPurchase:"결제 수단 추가"},"zh-CN":{payButton:"添加支付方式",confirmPurchase:"添加支付方式"},"zh-TW":{payButton:"新增付款方式",confirmPurchase:"新增付款方式"},ar:{payButton:"إضافة وسيلة دفع",confirmPurchase:"إضافة وسيلة دفع"},"hr-HR":{payButton:"Dodajte način plačanja",confirmPurchase:"Dodajte način plačanja"},"el-GR":{payButton:"Προσθήκη μεθόδου πληρωμής",confirmPurchase:"Προσθήκη μεθόδου πληρωμής"},"sk-SK":{payButton:"Pridať spôsob platby",confirmPurchase:"Pridať spôsob platby"},"sl-SI":{payButton:"Dodajte način plačanja",confirmPurchase:"Dodajte način plačanja"},"bg-BG":{payButton:"Добавяне на начин на плащане",confirmPurchase:"Добавяне на начин на плащане"},"ca-ES":{payButton:"Afegir mètode de pagament",confirmPurchase:"Afegir mètode de pagament"},"et-EE":{payButton:"Lisa makseviis",confirmPurchase:"Lisa makseviis"},"lv-LV":{payButton:"Pievienot maksājuma veidu",confirmPurchase:"Pievienot maksājuma veidu"},"lt-LT":{payButton:"Pridėti mokėjimo metodą",confirmPurchase:"Pridėti mokėjimo metodą"}}),p},ye={class:"sv-sepa-mandate mt-3"},le=n.defineComponent({__name:"SepaMandateNotice",props:{billingEntityName:{type:String}},setup(u){const p=u,{$t:g}=N.useIntl(),i=n.computed(()=>g({defaultMessage:"SEPA Direct Debit mandate — recurring payments",description:"Title of the SEPA direct debit mandate shown inside the SEPA payment form",id:"payments.sepa_mandate.title"})),b=n.computed(()=>p.billingEntityName?g({defaultMessage:"By confirming this mandate, you authorise {billingEntityName} to instruct your bank to collect payments from your account, and you authorise your bank to carry out those instructions.",description:"SEPA direct debit mandate authorisation, naming the billing entity",id:"payments.sepa_mandate.authorisation"},{billingEntityName:p.billingEntityName}):g({defaultMessage:"By confirming this mandate, you authorise us to instruct your bank to collect payments from your account, and you authorise your bank to carry out those instructions.",description:"SEPA direct debit mandate authorisation, where the billing entity is not known",id:"payments.sepa_mandate.authorisation_unnamed"})),a=n.computed(()=>p.billingEntityName?g({defaultMessage:"This bank account will be used automatically to pay subsequent invoices from {billingEntityName} until you cancel this mandate.",description:"Explains that the SEPA mandate covers later invoices, naming the billing entity",id:"payments.sepa_mandate.recurrence"},{billingEntityName:p.billingEntityName}):g({defaultMessage:"This bank account will be used automatically to pay subsequent invoices until you cancel this mandate.",description:"Explains that the SEPA mandate covers later invoices, where the billing entity is not known",id:"payments.sepa_mandate.recurrence_unnamed"})),l=n.computed(()=>g({defaultMessage:"As part of your rights, you're entitled to a refund from your bank under the terms and conditions of your agreement with your bank. You must claim a refund within 8 weeks from the date your account was debited. You can request a statement from your bank explaining your rights.",description:"SEPA direct debit mandate refund rights, held against the payer's own bank",id:"payments.sepa_mandate.refund_rights"}));return(h,v)=>(n.openBlock(),n.createElementBlock("div",ye,[n.createVNode(n.unref(N._sfc_main),{tag:"p",variant:"body-xs",class:"font-semibold"},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(i.value),1)]),_:1}),n.createVNode(n.unref(N._sfc_main),{tag:"p",variant:"body-xs",color:"subtle"},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(b.value)+" "+n.toDisplayString(a.value)+" "+n.toDisplayString(l.value),1)]),_:1})]))}}),T="ADYEN",he=n.defineComponent({__name:"PaymentIntegrationFormAdyen",props:{context:{type:Object},countryCode:{type:String},customerId:{type:String},invoiceId:{type:String},paymentMethodOptionResponseEntry:{type:Object},variant:{type:String},selected:{type:Boolean},amount:{type:Object},validateOnSubmit:{type:Function,default:()=>Promise.resolve(!0)},forceStorePaymentMethod:{type:Boolean},storePaymentMethod:{type:Boolean,default:void 0},redirectsOnSuccess:{type:Boolean},billingEntityName:{type:String}},emits:["select","payment-failed","payment-success","invalid","ready"],setup(u,{expose:p,emit:g}){let i=null,b=null;const a=u,l=g;p({submit:V});const h=n.ref(),v=n.ref(null),A=n.ref(null);let _;const R=n.ref(!1),P=n.ref(),d=N.useLogger(),{locale:j}=N.useIntl(),{authorizePayment:Z,getPaymentDetails:z}=ie.createPaymentsService(),{tokenizePaymentMethod:G}=de.createPaymentMethodsService(),O=y.useExperimentalFeature(),M=n.computed(()=>{var e;return y.getAdyenDropInPaymentMethods(a.paymentMethodOptionResponseEntry,{excludeExpressPaymentMethods:!!((e=O==null?void 0:O.value)!=null&&e["express-checkout"])})}),S=n.computed(()=>M.value.length>0);function m(e){return Y.createPaymentFailureContext({gateway:T,paymentAcceptorId:a.paymentMethodOptionResponseEntry.payment_acceptor.id,variant:a.variant,invoiceId:a.invoiceId,customerId:a.customerId,...e})}function E(e){const t=Y.createPaymentFailureError(e);P.value=t,l("payment-failed",t)}function V(){if(!(i!=null&&i.isValid)){if(i&&!i.activePaymentMethod){l("invalid","NO_PAYMENT_METHOD");return}i==null||i.showValidation(),l("invalid");return}try{i.submit()}catch(e){d.error("ADYEN_SUBMIT_FAILED","Failed to submit Adyen drop-in",m({reason:"ADYEN_SUBMIT_FAILED",cause:e}),e),E({code:a.variant==="TOKENIZE"?"TOKENIZE_FAILED":"AUTHORIZATION_FAILED",message:"Failed to submit Adyen drop-in",error:e})}}async function K(){const e=y.toMinorUnitAmount(a.amount),t=M.value;return{checkoutConfig:{amount:e,clientKey:y.getAdyenClientKeyFromPaymentMethodOptionsResponse(a.paymentMethodOptionResponseEntry),environment:y.getAdyenEnvironmentFromPaymentMethodOptionsResponse(a.paymentMethodOptionResponseEntry,d),locale:j,translations:pe(a.variant),countryCode:a.countryCode,analytics:{enabled:!1},paymentMethodsResponse:{paymentMethods:t},onSubmit:J,onAdditionalDetails:X,onPaymentCompleted:ne,onPaymentFailed:te,onError:ae,showPayButton:!1},dropInConfig:{disableFinalAnimation:!0,paymentMethodsConfiguration:{card:{hasHolderName:!0,holderNameRequired:!0,enableStoreDetails:!a.forceStorePaymentMethod&&a.storePaymentMethod===void 0&&a.variant==="AUTHORIZE"},paypal:{intent:e.value>0?"authorize":"tokenize",showPayButton:!0}},openFirstPaymentMethod:a.selected,onSelect:({props:{type:r}})=>{r&&l("select",{paymentMethodType:r,paymentGatewayVariant:"ADYEN"})},onReady:()=>l("ready")}}}function H(){return Promise.all([se.loadAdyenSdk(),Promise.resolve().then(()=>require("./adyen-BJfC7N6f.js")).then(e=>e.default)])}async function D(){if(await L(),P.value=void 0,!S.value){const{payment_acceptor:e,integration:t}=a.paymentMethodOptionResponseEntry;d.warn("PAYMENT_INTEGRATION_NOT_RENDERABLE","No Adyen payment methods to offer",{fingerprint:["PAYMENT_INTEGRATION_NOT_RENDERABLE",e.id],paymentAcceptorId:e.id,integrationId:t.id,...a.invoiceId?{invoiceId:a.invoiceId}:{}});return}if(await n.nextTick(),!!h.value)try{const[e,t]=await H(),{checkoutConfig:r,dropInConfig:o}=await K();b=await e.AdyenCheckout(r),i=new e.Dropin(b,{...o,paymentMethodComponents:e.dropInPaymentMethodComponents}).mount(h.value),Q(t),q()}catch(e){d.error("PAYMENT_INTEGRATION_INITIALIZATION_FAILED","Failed to mount Adyen web drop-in",m({reason:"ADYEN_DROP_IN_MOUNT_FAILED",cause:e}),e),E({code:"PAYMENT_INTEGRATION_INITIALIZATION_FAILED",message:"Failed to mount Adyen web drop-in",error:e})}}function C(){const e=ue(h.value);if(me(e,v.value)){A.value=null,n.nextTick(()=>A.value=e);return}A.value=e}function q(){_==null||_.disconnect(),h.value&&(_=new MutationObserver(()=>C()),_.observe(h.value,{childList:!0,subtree:!0}),C())}function $(){_==null||_.disconnect(),_=void 0,A.value=null}async function L(){$(),i&&(i.unmount(),i=null),h.value&&(h.value.innerHTML="")}function Q(e){var r;const t=(r=h.value)==null?void 0:r.getRootNode();if(t instanceof ShadowRoot){const o=document.createElement("style");o.textContent=e,t.appendChild(o);const s=document.createElement("style");s.textContent=`
|
|
2
|
-
:host {
|
|
3
|
-
--adyen-sdk-color-background-secondary: transparent;
|
|
4
|
-
--adyen-sdk-color-background-primary: rgb(243 244 246 / 0.5);
|
|
5
|
-
--adyen-sdk-color-outline-secondary: #e5e7eb;
|
|
6
|
-
--adyen-sdk-color-outline-primary: transparent;
|
|
7
|
-
--adyen-sdk-color-background-always-dark: var(--color-primary-500);
|
|
8
|
-
--adyen-sdk-color-background-inverse-primary-hover: var(--color-primary-600);
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
.adyen-checkout__payment-method__image__wrapper {
|
|
12
|
-
width: 32px;
|
|
13
|
-
height: 32px;
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
.adyen-checkout__payment-method__image {
|
|
17
|
-
height: 32px;
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
.adyen-checkout__input-wrapper,
|
|
21
|
-
.adyen-checkout__input {
|
|
22
|
-
border-color: rgb(229, 231, 235);
|
|
23
|
-
border-radius: var(--adyen-sdk-border-radius-s, 4px);
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
.adyen-checkout__button,
|
|
27
|
-
.adyen-checkout__payment-method {
|
|
28
|
-
border-radius: var(--adyen-sdk-border-radius-s, 4px);
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
.adyen-checkout__payment-method {
|
|
32
|
-
border-color: rgb(229, 231, 235);
|
|
33
|
-
box-shadow: 0 1px 2px 0 rgb(0 0 0 / 0.05);
|
|
34
|
-
transition: box-shadow 0.2s ease-in-out;
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
.adyen-checkout__payment-method--selected {
|
|
38
|
-
box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
.adyen-checkout__payment-method:after {
|
|
42
|
-
transform: scale(0%);
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
.adyen-checkout__paypal__button {
|
|
46
|
-
display: block !important;
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
.adyen-checkout__payment-methods-list {
|
|
50
|
-
gap: 4px;
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
.adyen-checkout__dropdown__list {
|
|
54
|
-
background-color: white;
|
|
55
|
-
border-radius: var(--adyen-sdk-border-radius-s, 4px);
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
.adyen-checkout__payment-method.adyen-checkout__payment-method--selected:after {
|
|
59
|
-
content: '✓';
|
|
60
|
-
width: 20px;
|
|
61
|
-
height: 20px;
|
|
62
|
-
border-radius: 10px;
|
|
63
|
-
background-color: var(--color-primary-600);
|
|
64
|
-
position: absolute;
|
|
65
|
-
top: 14px;
|
|
66
|
-
right: 14px;
|
|
67
|
-
text-align: center;
|
|
68
|
-
line-height: 20px;
|
|
69
|
-
color: white;
|
|
70
|
-
transform: scale(100%);
|
|
71
|
-
font-size: 12px;
|
|
72
|
-
}
|
|
73
|
-
|
|
74
|
-
.adyen-checkout__payment-method__header {
|
|
75
|
-
padding: 8px 16px !important;
|
|
76
|
-
}
|
|
77
|
-
|
|
78
|
-
.adyen-checkout__payment-method__brands {
|
|
79
|
-
align-items: center;
|
|
80
|
-
}
|
|
81
|
-
.adyen-checkout__payment-method__brand-number {
|
|
82
|
-
line-height: 1;
|
|
83
|
-
}
|
|
84
|
-
.adyen-checkout__button__text {
|
|
85
|
-
font-size: 14px;
|
|
86
|
-
}
|
|
87
|
-
.adyen-checkout__store-details {
|
|
88
|
-
background: transparent;
|
|
89
|
-
padding: 0;
|
|
90
|
-
}
|
|
91
|
-
.adyen-checkout__checkbox__input + .adyen-checkout__checkbox__label:after {
|
|
92
|
-
border-color: rgb(229, 231, 235);
|
|
93
|
-
}
|
|
94
|
-
`,a.variant==="AUTHORIZE"&&(s.textContent+=`
|
|
95
|
-
.adyen-checkout__payment-method--cashapp .adyen-checkout-pm-details-wrapper {
|
|
96
|
-
display: none;
|
|
97
|
-
}
|
|
98
|
-
`),t.appendChild(s)}}function w(e,{paymentMethodType:t,actions:r,logFailure:o}){if(e.status==="ACTION_REQUIRED"&&e.action.payment_gateway_variant===T){const s=W(e,t);if(!s){o(e);return}i.handleAction(s),r.resolve({resultCode:e.action.adyen.result_code,action:s});return}if(e.payment.result==="AUTHORIZED"){R.value=!0,r.resolve({resultCode:"Authorised"});return}o(e),r.resolve({resultCode:"Error"})}function J(...e){const[t,r,o]=e;a.validateOnSubmit().then(s=>{if(!s){i==null||i.setStatus("ready"),l("invalid");return}const c=a.paymentMethodOptionResponseEntry.payment_acceptor.id,B={risk_data:y.transformObjectToAdyenObject(t.data.riskData),payment_method:y.transformObjectToAdyenObject(t.data.paymentMethod),browser_info:y.transformObjectToAdyenObject(t.data.browserInfo)};if(a.variant==="AUTHORIZE"){const k=y.createReturnUrl({paymentAcceptorId:a.paymentMethodOptionResponseEntry.payment_acceptor.id,redirectUrl:window.location.href});Z({payment_acceptor_id:c,...a.customerId?{customer_id:a.customerId}:{},payment_gateway_variant:T,adyen:{...B,store_payment_method:a.storePaymentMethod??(a.forceStorePaymentMethod||t.data.storePaymentMethod)},amount:a.amount,...a.context?{context:a.context}:{},return_url:k}).then(f=>w(f,{paymentMethodType:t.data.paymentMethod.type,actions:o,logFailure:I=>d.error("PAYMENT_AUTHORIZATION_FAILED",`Failed payment authorization for payment acceptor with id ${c}`,m({reason:"PAYMENT_AUTHORIZATION_REJECTED",paymentMethodType:t.data.paymentMethod.type,cause:I}),I)})).catch(f=>{d.error("PAYMENT_AUTHORIZATION_FAILED",`Failed payment authorization for payment acceptor with id ${c}`,m({reason:"PAYMENT_AUTHORIZATION_FAILED",paymentMethodType:t.data.paymentMethod.type,cause:f}),f),o.resolve({resultCode:"Error"})});return}if(a.variant==="TOKENIZE"){const k=y.createReturnUrl({paymentAcceptorId:a.paymentMethodOptionResponseEntry.payment_acceptor.id,redirectUrl:window.location.href});if(!a.customerId){d.error("TOKENIZATION_FAILED",`Missing customer id for payment acceptor with id ${c}`,m({reason:"TOKENIZATION_FAILED_NO_CUSTOMER"})),E({code:"TOKENIZE_FAILED",message:"Missing customer id"});return}G({customer_id:a.customerId,payment_acceptor_id:c,payment_gateway_variant:T,adyen:B,return_url:k}).then(f=>w(f,{paymentMethodType:t.data.paymentMethod.type,actions:o,logFailure:I=>d.error("TOKENIZATION_FAILED",`Tokenization failed for payment acceptor with id ${c}`,m({reason:"TOKENIZATION_REJECTED",paymentMethodType:t.data.paymentMethod.type,cause:I}),I)})).catch(f=>{d.error("TOKENIZATION_FAILED",`Tokenization failed for payment acceptor with id ${c}`,m({reason:"TOKENIZATION_FAILED",paymentMethodType:t.data.paymentMethod.type,cause:f}),f),o.resolve({resultCode:"Error"})})}}).catch(s=>{d.error("INTEGRATION_ERROR","Unhandled error in payment submission flow",m({reason:"ADYEN_SUBMISSION_FLOW_FAILED",cause:s}),s)})}function W(e,t){if(e.status!=="ACTION_REQUIRED")return;const r=e.action;if(r.payment_gateway_variant!="ADYEN")return;const o=r.adyen;return{paymentMethodType:(o==null?void 0:o.payment_method_type)??t,method:r.method,url:r.url,data:r.data,type:o==null?void 0:o.action_type,paymentData:o==null?void 0:o.payment_data,sdkData:o==null?void 0:o.sdk_data}}function X(...e){const[t]=e,r=t.data.details,o=t.data.paymentData;if(a.paymentMethodOptionResponseEntry.payment_acceptor.id){x({detailsResult:r?ee(r):void 0,paymentDataResult:o,paymentAcceptorId:a.paymentMethodOptionResponseEntry.payment_acceptor.id});return}d.error("PAYMENT_ACCEPTOR_MISSING","Additional details arrived without a payment acceptor id",m({reason:"PAYMENT_ACCEPTOR_MISSING"})),E({code:"REDIRECT_RESULT_PAYMENT_ACCEPTOR_MISSING",message:"Payment failed",error:e})}function ee(e){return Object.fromEntries(Object.entries(e).filter(([,t])=>t!=null))}function te(...e){const[t]=e;d.error("ADYEN_PAYMENT_FAILED","Adyen reported the payment as failed",m({reason:"ADYEN_PAYMENT_FAILED",extra:{resultCode:t==null?void 0:t.resultCode}}),t),E({code:"AUTHORIZATION_FAILED",message:"Payment failed",error:t})}function ne(...e){const[,t]=e;t==null||t.unmount(),l("payment-success")}function ae(...e){const[t,r]=e;t.name!=="CANCEL"&&(d.error("INTEGRATION_ERROR","The Adyen drop-in reported an error",m({reason:"ADYEN_INTEGRATION_ERROR",cause:t,extra:{adyenErrorName:t.name}}),t),E({code:"UNKNOWN_ERROR",message:"Something went wrong",error:t}),r==null||r.unmount())}function x({detailsResult:e,threeDSResult:t,redirectResult:r,paymentDataResult:o,paymentAcceptorId:s}){z({paymentAcceptorId:s,paymentGatewayVariant:T,adyen:{...e?{details:e}:{},...r?{redirect_result:r}:{},...t?{threeds_result:t}:{},...o?{payment_data:o}:{}}}).then(c=>{if(c.payment_status==="FAILURE"){d.error("PAYMENT_DETAILS_REJECTED","Payment details returned a failed payment",m({reason:"PAYMENT_DETAILS_REJECTED",paymentAcceptorId:s,extra:{paymentStatus:c.payment_status}})),E({code:"AUTHORIZATION_FAILED",message:"Failed getting payment details",error:c});return}if(c.payment_status==="SUCCESS"){l("payment-success");return}}).catch(c=>{d.error("PAYMENT_DETAILS_CALL_FAILED","Failed fetching payment details",m({reason:"PAYMENT_DETAILS_CALL_FAILED",paymentAcceptorId:s,cause:c}),c),E({code:"PAYMENT_DETAILS_CALL_FAILED",message:"Failed fetching payment details",error:c})})}function oe(){const e=U.getQueryParam(y.REDIRECT_RESULT_QUERY_STRING),t=U.getQueryParam(y.PAYMENT_ACCEPTOR_ID_QUERY_STRING);if(e){if(!t){d.error("INVALID_REDIRECT_RESULT","Redirect result is set but payment acceptor id is missing",m({reason:"INVALID_REDIRECT_RESULT"})),E({code:"REDIRECT_RESULT_PAYMENT_ACCEPTOR_MISSING",message:"Redirect result is set but payment acceptor id is missing"});return}x({paymentAcceptorId:t,detailsResult:{redirectResult:decodeURI(e)}})}}return n.onMounted(()=>{D(),oe()}),n.onBeforeUnmount(()=>{L()}),n.watch(()=>a.paymentMethodOptionResponseEntry,(e,t)=>{re.isEqual(e,t)||D()},{deep:!0}),(e,t)=>(n.openBlock(),n.createElementBlock(n.Fragment,null,[R.value?(n.openBlock(),n.createBlock(F._sfc_main,{key:0,variant:u.variant,redirecting:u.redirectsOnSuccess},null,8,["variant","redirecting"])):P.value?(n.openBlock(),n.createBlock(F._sfc_main$1,{key:1,error:P.value},null,8,["error"])):n.createCommentVNode("",!0),S.value?(n.openBlock(),n.createElementBlock("div",{key:2,ref_key:"dropInContainerRef",ref:h},null,512)):n.createCommentVNode("",!0),A.value?(n.openBlock(),n.createBlock(n.Teleport,{key:3,to:A.value},[n.createElementVNode("div",{ref_key:"sepaNoticeRef",ref:v},[n.createVNode(le,{"billing-entity-name":u.billingEntityName},null,8,["billing-entity-name"])],512)],8,["to"])):n.createCommentVNode("",!0)],64))}});exports.default=he;
|
|
@@ -1,102 +0,0 @@
|
|
|
1
|
-
Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("vue"),j=require("./useService-H7BjLg8P.js"),N=require("./useExperimentalFeature-CGIkgFR4.js"),w=require("./PaymentErrorCard.vue_vue_type_script_setup_true_lang-Dg4rn1cm.js"),H=require("./payments-CS7_YcOW.js"),z=require("./paymentMethods-Cw-i95mM.js"),O=require("./url-vloPOiXd.js"),q=require("./customElements-DUMRMFQ5.js"),C=require("./paymentFailure-Cki8c5BX.js"),F="https://js.stripe.com/dahlia/stripe.js",Y=`<!DOCTYPE html>
|
|
2
|
-
<html>
|
|
3
|
-
<head>
|
|
4
|
-
<meta charset="UTF-8">
|
|
5
|
-
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
6
|
-
<style>
|
|
7
|
-
* { box-sizing: border-box; margin: 0; padding: 0; }
|
|
8
|
-
body { overflow: hidden; }
|
|
9
|
-
</style>
|
|
10
|
-
</head>
|
|
11
|
-
<body>
|
|
12
|
-
<div id="stripe-root"></div>
|
|
13
|
-
<script src="${F}"><\/script>
|
|
14
|
-
<script>
|
|
15
|
-
(function () {
|
|
16
|
-
let stripe, elements, countryCode, email, name, parentOrigin;
|
|
17
|
-
|
|
18
|
-
window.addEventListener('message', function (event) {
|
|
19
|
-
if (!event.data || typeof event.data !== 'object') return;
|
|
20
|
-
if (event.source !== window.parent) return;
|
|
21
|
-
|
|
22
|
-
if (event.data.type === 'stripe:init') {
|
|
23
|
-
parentOrigin = event.origin;
|
|
24
|
-
countryCode = event.data.countryCode;
|
|
25
|
-
email = event.data.email;
|
|
26
|
-
name = event.data.name;
|
|
27
|
-
stripe = Stripe(event.data.publicKey);
|
|
28
|
-
elements = stripe.elements(event.data.options);
|
|
29
|
-
const paymentElement = elements.create('payment', { layout: { type: 'accordion', defaultCollapsed: false }, wallets: event.data.options.wallets, fields: event.data.options.fields });
|
|
30
|
-
|
|
31
|
-
paymentElement.on('ready', function () {
|
|
32
|
-
parent.postMessage({ type: 'stripe:ready' }, parentOrigin);
|
|
33
|
-
});
|
|
34
|
-
|
|
35
|
-
paymentElement.on('change', function (e) {
|
|
36
|
-
parent.postMessage({ type: 'stripe:change', paymentMethodType: e.value.type }, parentOrigin);
|
|
37
|
-
});
|
|
38
|
-
|
|
39
|
-
paymentElement.on('loaderror', function (e) {
|
|
40
|
-
parent.postMessage({
|
|
41
|
-
type: 'stripe:loaderror',
|
|
42
|
-
error: { message: e.error.message, type: e.error.type }
|
|
43
|
-
}, parentOrigin);
|
|
44
|
-
});
|
|
45
|
-
|
|
46
|
-
paymentElement.mount('#stripe-root');
|
|
47
|
-
|
|
48
|
-
new ResizeObserver(function () {
|
|
49
|
-
parent.postMessage({
|
|
50
|
-
type: 'stripe:resize',
|
|
51
|
-
height: document.documentElement.scrollHeight
|
|
52
|
-
}, parentOrigin);
|
|
53
|
-
}).observe(document.documentElement);
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
if (event.data.type === 'stripe:submit') {
|
|
57
|
-
if (!elements || !parentOrigin || event.origin !== parentOrigin) return;
|
|
58
|
-
const submitEmail = 'email' in event.data ? event.data.email : email;
|
|
59
|
-
const submitName = 'name' in event.data ? event.data.name : name;
|
|
60
|
-
elements.submit().then(function (submitResult) {
|
|
61
|
-
if (submitResult.error) {
|
|
62
|
-
parent.postMessage({
|
|
63
|
-
type: 'stripe:submit:error',
|
|
64
|
-
error: {
|
|
65
|
-
message: submitResult.error.message,
|
|
66
|
-
type: submitResult.error.type,
|
|
67
|
-
code: submitResult.error.code
|
|
68
|
-
}
|
|
69
|
-
}, parentOrigin);
|
|
70
|
-
return;
|
|
71
|
-
}
|
|
72
|
-
const billingDetails = {};
|
|
73
|
-
if (countryCode) billingDetails.address = { country: countryCode };
|
|
74
|
-
if (submitEmail) billingDetails.email = submitEmail;
|
|
75
|
-
if (submitName) billingDetails.name = submitName;
|
|
76
|
-
const tokenParams = Object.keys(billingDetails).length
|
|
77
|
-
? { payment_method_data: { billing_details: billingDetails } }
|
|
78
|
-
: {};
|
|
79
|
-
stripe.createConfirmationToken({ elements: elements, params: tokenParams }).then(function (tokenResult) {
|
|
80
|
-
if (tokenResult.error) {
|
|
81
|
-
parent.postMessage({
|
|
82
|
-
type: 'stripe:submit:error',
|
|
83
|
-
error: {
|
|
84
|
-
message: tokenResult.error.message,
|
|
85
|
-
type: tokenResult.error.type,
|
|
86
|
-
code: tokenResult.error.code
|
|
87
|
-
}
|
|
88
|
-
}, parentOrigin);
|
|
89
|
-
return;
|
|
90
|
-
}
|
|
91
|
-
parent.postMessage({
|
|
92
|
-
type: 'stripe:submit:success',
|
|
93
|
-
confirmationTokenId: tokenResult.confirmationToken.id
|
|
94
|
-
}, parentOrigin);
|
|
95
|
-
});
|
|
96
|
-
});
|
|
97
|
-
}
|
|
98
|
-
});
|
|
99
|
-
})();
|
|
100
|
-
<\/script>
|
|
101
|
-
</body>
|
|
102
|
-
</html>`,G=["src","height"],Q=n.defineComponent({__name:"PaymentIntegrationFormStripeFrame",props:{publicKey:{type:String},options:{type:Object},countryCode:{type:String},email:{type:String},name:{type:String}},emits:["ready","change","loaderror","submit-success","submit-error"],setup(p,{expose:f,emit:R}){const t=p,s=R;f({triggerSubmit:h});const m=n.ref(),y=n.ref(0),E=n.ref();function A(){var o,r;(r=(o=m.value)==null?void 0:o.contentWindow)==null||r.postMessage({type:"stripe:init",publicKey:t.publicKey,options:t.options,countryCode:t.countryCode,email:t.email,name:t.name},"*")}function h(){var o,r;(r=(o=m.value)==null?void 0:o.contentWindow)==null||r.postMessage({type:"stripe:submit",email:t.email,name:t.name},"*")}const I={api_connection_error:!0,api_error:!0,authentication_error:!0,card_error:!0,idempotency_error:!0,invalid_request_error:!0,rate_limit_error:!0,validation_error:!0};function c(o){return typeof o=="string"&&Object.hasOwn(I,o)}function S(o){return typeof o=="object"&&o!==null}function b(o){if(!m.value||o.source!==m.value.contentWindow||!S(o.data))return;const r=o.data,v=r.type;if(!(typeof v!="string"||!v.startsWith("stripe:")))switch(v){case"stripe:ready":s("ready");break;case"stripe:change":s("change",typeof r.paymentMethodType=="string"?r.paymentMethodType:"card");break;case"stripe:loaderror":{const d=S(r.error)?r.error:{};s("loaderror",{message:typeof d.message=="string"?d.message:void 0,type:c(d.type)?d.type:void 0});break}case"stripe:resize":typeof r.height=="number"&&(y.value=r.height);break;case"stripe:submit:success":typeof r.confirmationTokenId=="string"&&s("submit-success",r.confirmationTokenId);break;case"stripe:submit:error":{const d=S(r.error)?r.error:{};s("submit-error",{message:typeof d.message=="string"?d.message:void 0,type:c(d.type)?d.type:void 0,code:typeof d.code=="string"?d.code:void 0});break}}}return n.onMounted(()=>{const o=new Blob([Y],{type:"text/html"});E.value=URL.createObjectURL(o),window.addEventListener("message",b)}),n.onBeforeUnmount(()=>{window.removeEventListener("message",b),E.value&&URL.revokeObjectURL(E.value)}),n.watch(()=>t.options,(o,r)=>{j.isEqual(o,r)||A()},{deep:!0}),(o,r)=>(n.openBlock(),n.createElementBlock("iframe",{ref_key:"iframeRef",ref:m,src:E.value,height:y.value||void 0,frameborder:"0",style:{width:"100%",display:"block",border:"none"},title:"Payment form",onLoad:A},null,40,G))}}),D={link:"never"},M={variables:{borderRadius:"4px",colorBackground:"rgba(243, 244, 246, 0.5)"},rules:{".TermsText":{fontSize:"14px"},".Input":{backgroundColor:"rgba(243, 244, 246, 0.5)",fontSize:"14px",borderColor:"rgb(229, 231, 235)"}}};function W(p,f){return{billingDetails:{address:{country:"never"},...p?{email:"never"}:{},...f?{name:"never"}:{}}}}function $({amount:p,email:f,name:R,variant:t,storePaymentMethod:s=!1}){const m=p.currency.toLowerCase(),y=W(f,R);return t==="TOKENIZE"?{mode:"setup",currency:m,setup_future_usage:"off_session",wallets:D,fields:y,appearance:M}:{mode:"payment",currency:m,amount:N.toMinorUnitAmount(p).value,...s?{setup_future_usage:"off_session"}:{},wallets:D,fields:y,appearance:M}}const T="STRIPE",V=n.defineComponent({__name:"PaymentIntegrationFormStripe",props:{email:{type:String},name:{type:String},countryCode:{type:String},customerId:{type:String},invoiceId:{type:String},paymentMethodOptionResponseEntry:{type:Object},variant:{type:String},selected:{type:Boolean},amount:{type:Object},validateOnSubmit:{type:Function,default:()=>Promise.resolve(!0)},context:{type:Object},forceStorePaymentMethod:{type:Boolean},storePaymentMethod:{type:Boolean},redirectsOnSuccess:{type:Boolean},billingEntityName:{type:String}},emits:["select","payment-failed","payment-success","invalid","ready"],setup(p,{expose:f,emit:R}){const t=p,s=R;f({submit:v});const m=n.ref(!1),y=n.ref(),E=n.ref(),A=n.computed(()=>t.storePaymentMethod??t.forceStorePaymentMethod??!1),h=n.computed(()=>$({amount:t.amount,email:t.email,name:t.name,variant:t.variant,storePaymentMethod:A.value})),I=n.ref(null),c=q.useLogger(),{authorizePayment:S}=H.createPaymentsService(),{tokenizePaymentMethod:b}=z.createPaymentMethodsService(),o=n.computed(()=>{var e,a;return(a=(e=t.paymentMethodOptionResponseEntry.integration.payment_gateway)==null?void 0:e.stripe)==null?void 0:a.public_key});function r(e){return C.createPaymentFailureContext({gateway:T,paymentAcceptorId:t.paymentMethodOptionResponseEntry.payment_acceptor.id,variant:t.variant,invoiceId:t.invoiceId,customerId:t.customerId,...e})}function v(){d().catch(e=>{c.error("STRIPE_SUBMIT_FAILED","Unexpected error during Stripe submission",r({reason:"STRIPE_SUBMIT_FAILED",cause:e}),e)})}async function d(){if(!await t.validateOnSubmit()||!E.value){s("invalid");return}E.value.triggerSubmit()}function L(e){if(e.type==="validation_error"){s("invalid");return}c.error("STRIPE_CONFIRMATION_TOKEN_FAILED","Stripe submission failed",r({reason:"STRIPE_CONFIRMATION_TOKEN_FAILED",cause:e}),e),l({code:t.variant==="TOKENIZE"?"TOKENIZE_FAILED":"AUTHORIZATION_FAILED",message:e.message??"Stripe submission failed",error:e})}function k(e){return new Promise((a,u)=>{if(window.Stripe){a(window.Stripe(e));return}const i=document.createElement("script");i.src=F,i.onload=()=>{if(!window.Stripe){u(new Error("Stripe not available after script load"));return}a(window.Stripe(e))},i.onerror=()=>u(new Error("Failed to load Stripe.js")),document.head.appendChild(i)})}async function U(){if(I.value)return I.value;const e=o.value;if(!e)throw new Error("Missing Stripe public key");const a=await k(e);return I.value=a,a}async function x(e){const a=t.paymentMethodOptionResponseEntry.payment_acceptor.id,u=N.createReturnUrl({paymentAcceptorId:a,redirectUrl:window.location.href});if(t.variant==="AUTHORIZE"){try{const i=await S({payment_acceptor_id:a,...t.customerId?{customer_id:t.customerId}:{},payment_gateway_variant:T,stripe:{confirmation_token_id:e},amount:t.amount,...t.context&&t.context.type!=="CHARGE_ON_DEMAND"?{context:t.context}:{},return_url:u});await P(i)}catch(i){c.error("PAYMENT_AUTHORIZATION_FAILED",`Failed payment authorization for payment acceptor with id ${a}`,r({reason:"PAYMENT_AUTHORIZATION_FAILED",cause:i}),i),l({code:"AUTHORIZATION_FAILED",message:"Payment authorization failed",error:i})}return}if(t.variant==="TOKENIZE"){if(!t.customerId){c.error("TOKENIZATION_FAILED",`Missing customer id for payment acceptor with id ${a}`,r({reason:"TOKENIZATION_FAILED_NO_CUSTOMER"})),l({code:"TOKENIZE_FAILED",message:"Missing customer id"});return}try{const i=await b({customer_id:t.customerId,payment_acceptor_id:a,payment_gateway_variant:T,stripe:{confirmation_token_id:e},return_url:u});await P(i)}catch(i){c.error("TOKENIZATION_FAILED",`Tokenization failed for payment acceptor with id ${a}`,r({reason:"TOKENIZATION_FAILED",cause:i}),i),l({code:"TOKENIZE_FAILED",message:"Tokenization failed",error:i})}}}async function P(e){var a;if(e.status==="ACTION_REQUIRED"&&e.action.payment_gateway_variant===T){const u=e.action.client_secret||((a=e.action.data)==null?void 0:a.client_secret);if(!u){c.error("STRIPE_ACTION_FAILED","Missing client_secret in Stripe ACTION_REQUIRED response",r({reason:"STRIPE_ACTION_MISSING_CLIENT_SECRET",extra:{paymentStatus:e.status}})),l({code:"AUTHORIZATION_FAILED",message:"Payment action failed",error:e});return}let i;try{i=await U()}catch(g){c.error("STRIPE_ACTION_FAILED","Failed to load Stripe.js",r({reason:"STRIPE_SDK_LOAD_FAILED",cause:g}),g),l({code:"AUTHORIZATION_FAILED",message:"Payment action failed",error:g});return}const{error:_}=await i.handleNextAction({clientSecret:u});if(_){c.error("STRIPE_ACTION_FAILED","Stripe handleNextAction failed",r({reason:"STRIPE_NEXT_ACTION_FAILED",cause:_,extra:{stripeErrorCode:_.code,stripeErrorType:_.type}}),_),l({code:"AUTHORIZATION_FAILED",message:"Payment action failed",error:_});return}m.value=!0,s("payment-success");return}if(e.status==="SUCCESS"){m.value=!0,s("payment-success");return}c.error("STRIPE_ACTION_FAILED","Unexpected payment result status",r({reason:"STRIPE_UNEXPECTED_PAYMENT_STATUS",extra:{paymentStatus:e.status}})),l({code:"AUTHORIZATION_FAILED",message:"Payment failed",error:e})}async function Z(){const e=t.paymentMethodOptionResponseEntry.payment_acceptor.id;if(O.getQueryParam(N.PAYMENT_ACCEPTOR_ID_QUERY_STRING)!==e)return;const u=O.getQueryParam("redirect_status"),i=O.getQueryParam("payment_intent_client_secret"),_=O.getQueryParam("setup_intent_client_secret");if(!u||!i&&!_)return;if(u==="succeeded"){m.value=!0,s("payment-success");return}const g=new globalThis.Error(`Stripe redirect returned status: ${u}`);c.error("STRIPE_REDIRECT_RETURN_FAILED","Stripe redirect returned non-succeeded status",r({reason:"STRIPE_REDIRECT_RETURN_FAILED",extra:{redirectStatus:u}}),g),l({code:"AUTHORIZATION_FAILED",message:"Payment failed",error:g})}function B(){s("select",{paymentMethodType:"card",paymentGatewayVariant:T}),s("ready")}function K(e){c.error("PAYMENT_INTEGRATION_INITIALIZATION_FAILED","Failed to load the Stripe payment form",r({reason:"STRIPE_FORM_LOAD_FAILED",cause:e,extra:{stripeErrorType:e.type}}),e),l({code:"PAYMENT_INTEGRATION_INITIALIZATION_FAILED",message:e.message??"Failed to load payment form",error:e})}function l(e){const a=C.createPaymentFailureError(e);y.value=a,s("payment-failed",a)}return n.onMounted(()=>{Z().catch(e=>{c.error("STRIPE_REDIRECT_RETURN_FAILED","handleRedirectReturn threw unexpectedly",r({reason:"STRIPE_REDIRECT_RETURN_THREW",cause:e}),e)})}),n.onBeforeUnmount(()=>{I.value=null}),(e,a)=>m.value?(n.openBlock(),n.createBlock(w._sfc_main,{key:0,variant:p.variant,redirecting:p.redirectsOnSuccess},null,8,["variant","redirecting"])):y.value?(n.openBlock(),n.createBlock(w._sfc_main$1,{key:1,error:y.value},null,8,["error"])):o.value?(n.openBlock(),n.createBlock(Q,{key:2,ref_key:"frameRef",ref:E,"public-key":o.value,options:h.value,"country-code":p.countryCode,email:p.email,name:p.name,onReady:B,onChange:a[0]||(a[0]=u=>s("select",{paymentMethodType:u,paymentGatewayVariant:T})),onLoaderror:K,onSubmitSuccess:x,onSubmitError:L},null,8,["public-key","options","country-code","email","name"])):n.createCommentVNode("",!0)}});exports.default=V;
|