@solvimon/solvimon-web 0.1.0-alpha.21 → 0.1.0-alpha.23
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 +3 -0
- package/dist/{AddPaymentMethodPane.vue_vue_type_script_setup_true_lang-DJCMa2Lz.mjs → AddPaymentMethodPane.vue_vue_type_script_setup_true_lang-B70SyWOB.mjs} +6 -6
- package/dist/{AddPaymentMethodPane.vue_vue_type_script_setup_true_lang-B9WTpz0k.js → AddPaymentMethodPane.vue_vue_type_script_setup_true_lang-jXClPW91.js} +1 -1
- package/dist/Alert.vue.es-RyK53a2P.js +1 -0
- package/dist/Alert.vue.es-lIiAWf2S.mjs +146 -0
- package/dist/{Avatar.vue.es-ChcLSNaN.mjs → Avatar.vue.es-2E3laNRb.mjs} +1 -1
- package/dist/{Avatar.vue.es-CJw5z7Uu.js → Avatar.vue.es-DdJreyr_.js} +1 -1
- package/dist/{BillingInformation.vue_vue_type_script_setup_true_lang-CTQ5RMtx.js → BillingInformation.vue_vue_type_script_setup_true_lang-ConpyC8n.js} +1 -1
- package/dist/{BillingInformation.vue_vue_type_script_setup_true_lang-DApMAncl.mjs → BillingInformation.vue_vue_type_script_setup_true_lang-D5EoBLhj.mjs} +4 -4
- package/dist/{Button.vue.es-VQCd3V3C.mjs → Button.vue.es-BJEy-e9C.mjs} +1 -1
- package/dist/{Button.vue.es-BWl37nzm.js → Button.vue.es-CJNxYacb.js} +1 -1
- package/dist/Checkout.entry.ce-BfLlnQyb.js +1 -0
- package/dist/{Checkout.entry.ce-DRHqEFd7.mjs → Checkout.entry.ce-CQkrWscC.mjs} +1397 -1302
- package/dist/{Chip.vue.es-CXG8o1Qf.mjs → Chip.vue.es-DGbc4L_D.mjs} +2 -2
- package/dist/{Chip.vue.es-DUgjuRWm.js → Chip.vue.es-DLQ4QEPo.js} +1 -1
- package/dist/{ContextMenu.vue.es-BllxeDTt.js → ContextMenu.vue.es-Bd2kmeVq.js} +1 -1
- package/dist/{ContextMenu.vue.es-C6TKlSXs.mjs → ContextMenu.vue.es-DL1M7pcr.mjs} +4 -4
- package/dist/{CustomerBillingInformation.vue.es-CKQH_ds0.mjs → CustomerBillingInformation.vue.es-CE94ASC3.mjs} +2 -2
- package/dist/{CustomerBillingInformation.vue.es-CMCZ-lIM.js → CustomerBillingInformation.vue.es-hiFzB43w.js} +1 -1
- package/dist/{CustomerPaymentMethods.vue_vue_type_script_setup_true_lang-n097Xf1H.js → CustomerPaymentMethods.vue_vue_type_script_setup_true_lang-BE21tqgW.js} +1 -1
- package/dist/{CustomerPaymentMethods.vue_vue_type_script_setup_true_lang-BxwllXwU.mjs → CustomerPaymentMethods.vue_vue_type_script_setup_true_lang-Bhih7rPR.mjs} +5 -5
- package/dist/{CustomerWalletBalances.vue_vue_type_script_setup_true_lang-CtaoLbrM.mjs → CustomerWalletBalances.vue_vue_type_script_setup_true_lang-C5zc9n64.mjs} +486 -502
- package/dist/CustomerWalletBalances.vue_vue_type_script_setup_true_lang-D018AmFA.js +1 -0
- package/dist/{DividerText.vue.es-Bomiy4if.mjs → DividerText.vue.es-CFZUQ62L.mjs} +1 -1
- package/dist/{DividerText.vue.es-BBdydUy_.js → DividerText.vue.es-CvCgHHXN.js} +1 -1
- package/dist/{EmptyStatePlaceholder.vue_vue_type_script_setup_true_lang-C9elbdbF.mjs → EmptyStatePlaceholder.vue_vue_type_script_setup_true_lang-YcaBJDzx.mjs} +4 -4
- package/dist/{EmptyStatePlaceholder.vue_vue_type_script_setup_true_lang-DXO9xpFT.js → EmptyStatePlaceholder.vue_vue_type_script_setup_true_lang-jTJGN4jb.js} +1 -1
- package/dist/{ErrorNotification.vue.es-C6ngWAVU.mjs → ErrorNotification.vue.es-B3mvv79S.mjs} +2 -2
- package/dist/ErrorNotification.vue.es-DI2B7WiR.js +1 -0
- package/dist/IconButton.vue.es-Dp8h4YOx.js +1 -0
- package/dist/IconButton.vue.es-GLcGhoHC.mjs +56 -0
- package/dist/{IconTitle.vue.es-Bbusc4wK.mjs → IconTitle.vue.es-CzuPQtOX.mjs} +3 -3
- package/dist/{IconTitle.vue.es-D-q6w2E-.js → IconTitle.vue.es-DN9r6nfK.js} +1 -1
- package/dist/{Input.vue.es-AY1c0Rui.mjs → Input.vue.es-5Cq8a7oH.mjs} +2 -2
- package/dist/{Input.vue.es-BN95nPBw.js → Input.vue.es-DM81HeVv.js} +1 -1
- package/dist/{InvoiceDetailsBlock.vue_vue_type_script_setup_true_lang-1WjSbPEP.mjs → InvoiceDetailsBlock.vue_vue_type_script_setup_true_lang-D75LSIL8.mjs} +2 -2
- package/dist/{InvoiceDetailsBlock.vue_vue_type_script_setup_true_lang-qiBCPY8l.js → InvoiceDetailsBlock.vue_vue_type_script_setup_true_lang-w8w52LcV.js} +1 -1
- package/dist/InvoiceEntryView.vue_vue_type_script_setup_true_lang-DB5h39LA.js +1 -0
- package/dist/{InvoiceEntryView.vue_vue_type_script_setup_true_lang-D99nuBRE.mjs → InvoiceEntryView.vue_vue_type_script_setup_true_lang-dRLsZPNh.mjs} +3 -3
- package/dist/{InvoiceSummary.vue.es-Bs5c2Ovx.mjs → InvoiceSummary.vue.es-DbtqsTuP.mjs} +692 -705
- package/dist/InvoiceSummary.vue.es-Qy99kLZs.js +1 -0
- package/dist/{Modal.vue.es-Chi6_MH_.js → Modal.vue.es-DgLl6XBV.js} +1 -1
- package/dist/{Modal.vue.es-DSkC4eMv.mjs → Modal.vue.es-Z2DWAN2u.mjs} +5 -5
- package/dist/PaymentErrorCard.vue_vue_type_script_setup_true_lang-DBm51C7c.js +1 -0
- package/dist/PaymentErrorCard.vue_vue_type_script_setup_true_lang-DYuFPIqs.mjs +294 -0
- package/dist/{PaymentFeedbackCard.vue_vue_type_script_setup_true_lang-Db6jAkqD.js → PaymentFeedbackCard.vue_vue_type_script_setup_true_lang-BNZ9-GW1.js} +1 -1
- package/dist/{PaymentFeedbackCard.vue_vue_type_script_setup_true_lang-DVif_ME8.mjs → PaymentFeedbackCard.vue_vue_type_script_setup_true_lang-CcdhYTB1.mjs} +3 -3
- package/dist/{PaymentHistoryBlock-budeR7ep.mjs → PaymentHistoryBlock-CjP_514k.mjs} +1 -1
- package/dist/{PaymentHistoryBlock-DGJ_PiVq.js → PaymentHistoryBlock-DS1j-8m-.js} +1 -1
- package/dist/{PaymentHistoryBlock.vue_vue_type_script_setup_true_lang-Dv-3suBX.js → PaymentHistoryBlock.vue_vue_type_script_setup_true_lang-CSTfMB8U.js} +1 -1
- package/dist/{PaymentHistoryBlock.vue_vue_type_script_setup_true_lang-C28ofG7N.mjs → PaymentHistoryBlock.vue_vue_type_script_setup_true_lang-Dr2jtJhK.mjs} +4 -4
- package/dist/{PaymentIntegrationForm-DqqGcEP1.js → PaymentIntegrationForm-80b19Lkq.js} +1 -1
- package/dist/{PaymentIntegrationForm-Crrhar96.mjs → PaymentIntegrationForm-CpOZUf-W.mjs} +1 -1
- package/dist/{PaymentIntegrationForm.vue_vue_type_script_setup_true_lang-C4bk0m8g.mjs → PaymentIntegrationForm.vue_vue_type_script_setup_true_lang-BgztoQH5.mjs} +3 -3
- package/dist/{PaymentIntegrationForm.vue_vue_type_script_setup_true_lang-CcEEdHQJ.js → PaymentIntegrationForm.vue_vue_type_script_setup_true_lang-DKXhthkA.js} +1 -1
- package/dist/{PaymentIntegrationFormAdyen-DM-xMcm0.mjs → PaymentIntegrationFormAdyen-BQcgDcik.mjs} +281 -204
- package/dist/PaymentIntegrationFormAdyen-DElXsJ96.js +98 -0
- package/dist/PaymentIntegrationFormStripe-CMwLqOe6.js +102 -0
- package/dist/{PaymentIntegrationFormStripe-yBm4KnpV.mjs → PaymentIntegrationFormStripe-Dx1H3fZ2.mjs} +249 -178
- package/dist/{PaymentMethod.vue.es-BdMcKq8_.mjs → PaymentMethod.vue.es-EhRCfeax.mjs} +3 -3
- package/dist/{PaymentMethod.vue.es-Ctw9Es1g.js → PaymentMethod.vue.es-pLCCzVxN.js} +1 -1
- package/dist/{PaymentMethodForm-BQ5TVHlS.js → PaymentMethodForm-Bw2e1tXo.js} +1 -1
- package/dist/{PaymentMethodForm-C1bIGX10.mjs → PaymentMethodForm-D3OY8zK5.mjs} +1 -1
- package/dist/{PaymentMethodForm.vue_vue_type_script_setup_true_lang-V88bCeDt.js → PaymentMethodForm.vue_vue_type_script_setup_true_lang-DHXw6qD0.js} +1 -1
- package/dist/{PaymentMethodForm.vue_vue_type_script_setup_true_lang-5KKkuVt5.mjs → PaymentMethodForm.vue_vue_type_script_setup_true_lang-vGprVPpn.mjs} +5 -5
- package/dist/{PaymentMethodsList.vue_vue_type_script_setup_true_lang-B_207kq5.js → PaymentMethodsList.vue_vue_type_script_setup_true_lang-CdT1YyeU.js} +1 -1
- package/dist/{PaymentMethodsList.vue_vue_type_script_setup_true_lang-CnmZ9dvP.mjs → PaymentMethodsList.vue_vue_type_script_setup_true_lang-D7b0HhDc.mjs} +6 -6
- package/dist/PlanCustomizationEditor-BQqkgmzL.mjs +877 -0
- package/dist/PlanCustomizationEditor-RC8kj2rC.js +1 -0
- package/dist/{PricingGroupRangeInput.vue.es-D82XvoC_.js → PricingGroupRangeInput.vue.es-ClkE98ML.js} +2 -2
- package/dist/{PricingGroupRangeInput.vue.es-Bnb-ARie.mjs → PricingGroupRangeInput.vue.es-DNsiUZyT.mjs} +4 -4
- package/dist/{PricingGroupSingleEditor.vue_vue_type_script_setup_true_lang-CxMkCmti.js → PricingGroupSingleEditor.vue_vue_type_script_setup_true_lang-BJfQLRcS.js} +1 -1
- package/dist/{PricingGroupSingleEditor.vue_vue_type_script_setup_true_lang-skQMgHEL.mjs → PricingGroupSingleEditor.vue_vue_type_script_setup_true_lang-CURXAgMT.mjs} +5 -5
- package/dist/RadioGroupExtended.vue.es-Dk9xdj76.js +1 -0
- package/dist/{RadioGroupExtended.vue.es-WDbo_yj1.mjs → RadioGroupExtended.vue.es-vUqn2ZUP.mjs} +3 -3
- package/dist/{Section.vue.es-By1JltGi.mjs → Section.vue.es-C2_topx4.mjs} +1 -1
- package/dist/{Section.vue.es-DuK52y67.js → Section.vue.es-Cybk1Nb8.js} +1 -1
- package/dist/{SecurePaymentsKPI.vue_vue_type_script_setup_true_lang-CS3KIkPL.mjs → SecurePaymentsKPI.vue_vue_type_script_setup_true_lang-C9q_qwjt.mjs} +6 -6
- package/dist/{SecurePaymentsKPI.vue_vue_type_script_setup_true_lang-Ct3ZNq-j.js → SecurePaymentsKPI.vue_vue_type_script_setup_true_lang-DIgVzXLg.js} +1 -1
- package/dist/{SubscriptionSchedules-DDCjVEbG.mjs → SubscriptionSchedules-BlCU_xc5.mjs} +1 -1
- package/dist/{SubscriptionSchedules-DEjIERyF.js → SubscriptionSchedules-CNTg_oRy.js} +1 -1
- package/dist/SubscriptionSchedules.vue_vue_type_script_setup_true_lang-6LbR_Vni.js +1 -0
- package/dist/{SubscriptionSchedules.vue_vue_type_script_setup_true_lang-JAedXFzq.mjs → SubscriptionSchedules.vue_vue_type_script_setup_true_lang-Cf3Dy8Yn.mjs} +1655 -1620
- package/dist/{SubscriptionSummary.vue_vue_type_script_setup_true_lang-D-Fa54M6.js → SubscriptionSummary.vue_vue_type_script_setup_true_lang-BijBAdqp.js} +1 -1
- package/dist/{SubscriptionSummary.vue_vue_type_script_setup_true_lang-DVMS4gJQ.mjs → SubscriptionSummary.vue_vue_type_script_setup_true_lang-CjzjchsS.mjs} +3 -3
- package/dist/{SubscriptionsList.vue_vue_type_script_setup_true_lang-BckZJtOc.mjs → SubscriptionsList.vue_vue_type_script_setup_true_lang-CxdrAanb.mjs} +7 -7
- package/dist/{SubscriptionsList.vue_vue_type_script_setup_true_lang-DiXmEjUD.js → SubscriptionsList.vue_vue_type_script_setup_true_lang-Dz4s3CH_.js} +1 -1
- package/dist/{TooltipParagraph.vue.es-DYu2ReL7.mjs → TooltipParagraph.vue.es-Fu9Od3Vr.mjs} +1 -1
- package/dist/{TooltipParagraph.vue.es-sTgWAgcd.js → TooltipParagraph.vue.es-OX6bAWP9.js} +1 -1
- package/dist/{TrialChip.vue.es-Cl-9_pdr.js → TrialChip.vue.es-CbjdkR4i.js} +1 -1
- package/dist/{TrialChip.vue.es-DX53r0ku.mjs → TrialChip.vue.es-c7tZOIW3.mjs} +2 -2
- package/dist/{cn.es-DjnGlmqV.mjs → cn.es-C8Ogac5T.mjs} +2 -2
- package/dist/{cn.es-CNvIP217.js → cn.es-lC4_Xd0R.js} +1 -1
- package/dist/components/BillingInformation/BillingInformation.cjs +1 -1
- package/dist/components/BillingInformation/BillingInformation.mjs +5 -5
- package/dist/components/BillingInformationForm/BillingInformationForm.cjs +1 -1
- package/dist/components/BillingInformationForm/BillingInformationForm.mjs +7 -7
- package/dist/components/CustomerPaymentMethods/CustomerPaymentMethods.cjs +1 -1
- package/dist/components/CustomerPaymentMethods/CustomerPaymentMethods.mjs +5 -5
- package/dist/components/Invoice/Invoice.cjs +1 -1
- package/dist/components/Invoice/Invoice.mjs +10 -10
- package/dist/components/InvoiceDetails/InvoiceDetails.cjs +1 -1
- package/dist/components/InvoiceDetails/InvoiceDetails.mjs +4 -4
- package/dist/components/InvoiceHeader/InvoiceHeader.cjs +1 -1
- package/dist/components/InvoiceHeader/InvoiceHeader.mjs +8 -8
- package/dist/components/InvoicesList/InvoicesList.cjs +1 -1
- package/dist/components/InvoicesList/InvoicesList.mjs +4 -4
- package/dist/components/PaymentHistory/PaymentHistory.cjs +1 -1
- package/dist/components/PaymentHistory/PaymentHistory.mjs +9 -9
- package/dist/components/PaymentMethodForm/PaymentMethodForm.cjs +1 -1
- package/dist/components/PaymentMethodForm/PaymentMethodForm.mjs +6 -6
- package/dist/components/SubscriptionSchedules/SubscriptionSchedules.cjs +1 -1
- package/dist/components/SubscriptionSchedules/SubscriptionSchedules.mjs +5 -5
- package/dist/components/SubscriptionsList/SubscriptionsList.cjs +1 -1
- package/dist/components/SubscriptionsList/SubscriptionsList.mjs +6 -6
- package/dist/components/WalletBalances/WalletBalances.cjs +1 -1
- package/dist/components/WalletBalances/WalletBalances.mjs +4 -4
- package/dist/core/index.cjs +1 -1
- package/dist/core/index.mjs +26 -23
- package/dist/{customElements-Bt8PbjIn.js → customElements-BYIdPSzQ.js} +43 -19
- package/dist/{customElements-Com2NiGU.mjs → customElements-Df6dGrN-.mjs} +603 -572
- package/dist/{customer-CKgMJEgv.mjs → customer-DmsKYpVi.mjs} +1 -1
- package/dist/{customer-Q4JGfVfq.js → customer-DoLHZuMG.js} +1 -1
- package/dist/{de-DE-DqLD4IX2.js → de-DE-BSlbAnPE.js} +1 -1
- package/dist/{de-DE-CVCmzlNH.mjs → de-DE-Bgm9bnmp.mjs} +21 -0
- package/dist/{de-DE-Ds_yJLS3.js → de-DE-CAL9Mji2.js} +1 -1
- package/dist/{de-DE-DBO5f-Eu.mjs → de-DE-DXsG-vXA.mjs} +13 -8
- package/dist/{en-US-CvFmmI_O.js → en-US-9xdcz3T5.js} +1 -1
- package/dist/{en-US-3UmnS23B.mjs → en-US-C939IZ5i.mjs} +13 -8
- package/dist/{en-US-DVR9O7b_.mjs → en-US-E86eRIxh.mjs} +21 -0
- package/dist/{en-US-C51ILrVv.js → en-US-_xe5H4TQ.js} +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.mjs +1 -1
- package/dist/{invoices-CV9iAUHf.mjs → invoices-CrO6p4Ms.mjs} +8 -5
- package/dist/invoices-mw87cNTS.js +1 -0
- package/dist/{it-IT-CxBRisRm.mjs → it-IT-BxpwB3oJ.mjs} +8 -3
- package/dist/it-IT-DT3rfjOY.js +1 -0
- package/dist/{it-IT-Dxw59eR_.js → it-IT-QFQ1Ajbb.js} +1 -1
- package/dist/{it-IT-CDMnnFKZ.mjs → it-IT-co1BfV5s.mjs} +23 -2
- package/dist/{nl-NL-Btbfd9p2.js → nl-NL-CJXJC1bx.js} +1 -1
- package/dist/nl-NL-DfkhOJKc.js +1 -0
- package/dist/{nl-NL-o3UvtSNg.mjs → nl-NL-Drv2E66B.mjs} +21 -0
- package/dist/{nl-NL-BWGkVweu.mjs → nl-NL-na2I4aiP.mjs} +8 -3
- package/dist/paymentFailure-Bh60UhxA.mjs +47 -0
- package/dist/paymentFailure-Cki8c5BX.js +1 -0
- package/dist/{paymentMethods-BuwoJ1y9.mjs → paymentMethods-BNQbW_f1.mjs} +1 -1
- package/dist/{paymentMethods-ChWAwDSF.js → paymentMethods-CQdhZwq4.js} +1 -1
- package/dist/{payments-DGckugN0.js → payments-KTjVHqOa.js} +1 -1
- package/dist/{payments-C_cMXQzE.mjs → payments-VS_N2xpJ.mjs} +1 -1
- package/dist/pricingItemConfigs.es-D4aYkYcf.js +1 -0
- package/dist/{pricingItemConfigs.es-DMf1e6y7.mjs → pricingItemConfigs.es-ORxsk_YS.mjs} +23 -22
- package/dist/pricingPlanSchedule-BM8vsKkV.js +1 -0
- package/dist/pricingPlanSchedule-BPrS2WRd.mjs +132 -0
- package/dist/screens/Checkout/Checkout.cjs +1 -1
- package/dist/screens/Checkout/Checkout.mjs +2 -2
- package/dist/screens/CustomerOverview/CustomerOverview.cjs +1 -1
- package/dist/screens/CustomerOverview/CustomerOverview.mjs +21 -21
- package/dist/screens/PayInvoice/PayInvoice.cjs +1 -1
- package/dist/screens/PayInvoice/PayInvoice.mjs +14 -14
- package/dist/screens/PaymentMethodsManagement/PaymentMethodsManagement.cjs +1 -1
- package/dist/screens/PaymentMethodsManagement/PaymentMethodsManagement.mjs +10 -10
- package/dist/screens/SubscriptionDetails/SubscriptionDetails.cjs +1 -1
- package/dist/screens/SubscriptionDetails/SubscriptionDetails.mjs +21 -21
- package/dist/screens/SubscriptionManagement/SubscriptionManagement.cjs +1 -1
- package/dist/screens/SubscriptionManagement/SubscriptionManagement.mjs +20 -20
- package/dist/sessionReference-3h-6FdrC.mjs +43 -0
- package/dist/sessionReference-m_6Rp4X1.js +1 -0
- package/dist/{subscription-CvfAEJeP.mjs → subscription-CrVOr5MF.mjs} +1 -1
- package/dist/{subscription-9GORG-Gt.js → subscription-ZA62t4E9.js} +1 -1
- package/dist/subscriptions-Dugd-oZ1.js +1 -0
- package/dist/{subscriptions-B5VqRayX.mjs → subscriptions-U4xg2CO1.mjs} +2 -2
- package/dist/types/components/customer/CheckoutForm/CheckoutForm.types.d.ts +1 -0
- package/dist/types/components/providers/LoggerProvider/LoggerProvider.lib.d.ts +2 -0
- package/dist/types/components/providers/LoggerProvider/LoggerProvider.types.d.ts +10 -1
- package/dist/types/components/subscriptions/PlanCustomizationForm/PlanCustomizationEditor.types.d.ts +1 -0
- package/dist/types/components/subscriptions/PlanCustomizationForm/UnitsEditor.types.d.ts +6 -0
- package/dist/types/components/subscriptions/PlanCustomizationForm/UnitsEditorItem.types.d.ts +6 -0
- package/dist/types/composables/useInvoicePreview.types.d.ts +1 -0
- package/dist/types/public/components/Invoice/Invoice.types.d.ts +1 -1
- package/dist/types/public/components/InvoiceHeader/InvoiceHeader.types.d.ts +1 -1
- package/dist/types/public/screens/PayInvoice/PayInvoice.types.d.ts +1 -1
- package/dist/types/types/errors.d.ts +5 -0
- package/dist/{useActionDispatchProvider-B54GYEY7.js → useActionDispatchProvider-CTyDGRX8.js} +1 -1
- package/dist/{useActionDispatchProvider-e2lQXTid.mjs → useActionDispatchProvider-DyQbRCxR.mjs} +1 -1
- package/dist/{useCustomer-BJwJ9BkJ.js → useCustomer-BXI5Vmit.js} +1 -1
- package/dist/{useCustomer-CC9zxV6c.mjs → useCustomer-dcmU1539.mjs} +1 -1
- package/dist/useCustomerFormLabels-BC1WfqWo.mjs +968 -0
- package/dist/useCustomerFormLabels-Ct6vD_b8.js +1 -0
- package/dist/{useExperimentalFeature-B0IFn3Uw.mjs → useExperimentalFeature-4Y-ppDr7.mjs} +1 -1
- package/dist/{useExperimentalFeature-8Mzpj5wc.js → useExperimentalFeature-9-p9_nP6.js} +1 -1
- package/dist/{useInvoiceData-6mHUZC9a.mjs → useInvoiceData-B2Z9aD2w.mjs} +2 -2
- package/dist/{useInvoiceData-Bblwdl0f.js → useInvoiceData-CGvtl7Ai.js} +1 -1
- package/dist/{useInvoicesList-_U1-tn9_.js → useInvoicesList-Ba0GO8p-.js} +1 -1
- package/dist/{useInvoicesList-B5H5JfvY.mjs → useInvoicesList-DJPznhig.mjs} +7 -7
- package/dist/{useLoadInitialData-CezlvhBV.js → useLoadInitialData-BO9ZsSsF.js} +1 -1
- package/dist/{useLoadInitialData-ux_wpNiR.mjs → useLoadInitialData-CWyI3_RR.mjs} +1 -1
- package/dist/{usePaymentMethodAvailability-CkR4TwoV.mjs → usePaymentMethodAvailability-DqIvkjLF.mjs} +4 -4
- package/dist/{usePaymentMethodAvailability-DRwrBdto.js → usePaymentMethodAvailability-bkmDrPXY.js} +1 -1
- package/dist/{usePaymentMethodOptions-B6GIM9q4.js → usePaymentMethodOptions-BPBVGNDg.js} +1 -1
- package/dist/{usePaymentMethodOptions-BfnLBZOo.mjs → usePaymentMethodOptions-MSEp39xQ.mjs} +1 -1
- package/dist/{usePaymentMethods-GFmQRp0X.js → usePaymentMethods-BAOtOJZD.js} +1 -1
- package/dist/{usePaymentMethods-C3QfLSrP.mjs → usePaymentMethods-U7gnZ0F5.mjs} +1 -1
- package/dist/{usePayments-BkwGyZT0.mjs → usePayments-Dq2V6bTV.mjs} +6 -6
- package/dist/{usePayments-SQF_V7oL.js → usePayments-G-HpKpK8.js} +1 -1
- package/dist/{usePortal-BdM7hDge.js → usePortal-BplmMkBG.js} +1 -1
- package/dist/{usePortal-DDG9b6FI.mjs → usePortal-CMHV-ShD.mjs} +1 -1
- package/dist/{useSubscription-Q4C2DPhw.js → useSubscription-CvB8ROBt.js} +1 -1
- package/dist/{useSubscription-BJJYHYgr.mjs → useSubscription-V53WsZwQ.mjs} +1 -1
- package/dist/{useTimePeriod.es-pepm2TpV.js → useTimePeriod.es-CtCTu9cz.js} +1 -1
- package/dist/{useTimePeriod.es-9tZvAhyb.mjs → useTimePeriod.es-D31Zl1MJ.mjs} +1 -1
- package/dist/wallets.es-CNIMW5ay.js +1 -0
- package/dist/wallets.es-eH2C2ygn.mjs +102 -0
- package/package.json +2 -1
- package/dist/Checkout.entry.ce-BTVuGyNq.js +0 -1
- package/dist/CustomerWalletBalances.vue_vue_type_script_setup_true_lang-C_yKvYtG.js +0 -1
- package/dist/ErrorNotification.vue.es-0ZC_DozN.js +0 -1
- package/dist/IconButton.vue.es-DAR7e8NA.mjs +0 -198
- package/dist/IconButton.vue.es-DGLIdHkR.js +0 -1
- package/dist/InvoiceEntryView.vue_vue_type_script_setup_true_lang-BXTInmf9.js +0 -1
- package/dist/InvoiceSummary.vue.es-B0MPR0oI.js +0 -1
- package/dist/PaymentErrorCard.vue_vue_type_script_setup_true_lang-Draz_8Ts.js +0 -1
- package/dist/PaymentErrorCard.vue_vue_type_script_setup_true_lang-vD88j_U7.mjs +0 -144
- package/dist/PaymentIntegrationFormAdyen-DronjwO3.js +0 -98
- package/dist/PaymentIntegrationFormStripe-ybM6wirp.js +0 -102
- package/dist/PlanCustomizationEditor-CCOTD6Qu.mjs +0 -769
- package/dist/PlanCustomizationEditor-CiZnVCM6.js +0 -1
- package/dist/RadioGroupExtended.vue.es-B1YtLNKG.js +0 -1
- package/dist/SubscriptionSchedules.vue_vue_type_script_setup_true_lang-BlX0W6lw.js +0 -1
- package/dist/component-5wqcK7yz.mjs +0 -8
- package/dist/component-B7ZDyqBp.js +0 -1
- package/dist/invoices-CvpL4rv5.js +0 -1
- package/dist/it-IT-CFEfSpPH.js +0 -1
- package/dist/nl-NL-jtVgF3jx.js +0 -1
- package/dist/pricingItemConfigs.es-DlybwIh1.js +0 -1
- package/dist/pricingPlanSchedule-COfmWv_o.js +0 -1
- package/dist/pricingPlanSchedule-J1nb9pCu.mjs +0 -129
- package/dist/subscriptions-X0Ciw8z3.js +0 -1
- package/dist/useCustomerFormLabels-72Pxw8X5.js +0 -1
- package/dist/useCustomerFormLabels-V2YuYMLU.mjs +0 -930
|
@@ -1,46 +1,47 @@
|
|
|
1
|
-
import { unref as t, inject as
|
|
2
|
-
import { I as
|
|
3
|
-
import { u as
|
|
4
|
-
import { b as
|
|
5
|
-
import { _ as
|
|
6
|
-
import { _ as
|
|
7
|
-
import { c as
|
|
8
|
-
import { c as
|
|
9
|
-
import { A as
|
|
10
|
-
import { c as
|
|
11
|
-
import { a as
|
|
12
|
-
import { c as
|
|
13
|
-
import { g as
|
|
14
|
-
import { u as
|
|
15
|
-
import { o as
|
|
16
|
-
import { u as
|
|
17
|
-
import { u as
|
|
18
|
-
import { c as
|
|
19
|
-
import { a as
|
|
20
|
-
import { g as
|
|
21
|
-
import { P as
|
|
22
|
-
import { u as
|
|
23
|
-
import { g as
|
|
24
|
-
import { _ as
|
|
25
|
-
import { _ as
|
|
26
|
-
import { _ as
|
|
27
|
-
import { _ as
|
|
28
|
-
import { c as
|
|
29
|
-
import { b as
|
|
30
|
-
import { _ as
|
|
31
|
-
import { _ as
|
|
32
|
-
import { _ as
|
|
33
|
-
import { _ as
|
|
34
|
-
import { _ as
|
|
35
|
-
import { u as
|
|
36
|
-
import { _ as
|
|
37
|
-
import { _ as
|
|
38
|
-
import { l as
|
|
39
|
-
import { c as
|
|
40
|
-
import {
|
|
41
|
-
import {
|
|
42
|
-
import {
|
|
43
|
-
|
|
1
|
+
import { unref as t, inject as qt, ref as V, computed as b, onMounted as Oe, toRaw as Jt, watch as we, defineComponent as ce, openBlock as _, createBlock as O, withCtx as I, createElementVNode as T, createVNode as E, createTextVNode as F, toDisplayString as U, useModel as ei, createElementBlock as W, withModifiers as $e, Fragment as _e, createCommentVNode as B, createSlots as Je, normalizeClass as be, mergeModels as vt, renderSlot as We, nextTick as He, mergeProps as ft, withDirectives as ti, withKeys as _t, vShow as ii, defineAsyncComponent as Mt } from "vue";
|
|
2
|
+
import { I as oi, b as Me, u as ve, _ as se, d as ni, e as ai } from "./customElements-Df6dGrN-.mjs";
|
|
3
|
+
import { u as Lt } from "./useTimePeriod.es-D31Zl1MJ.mjs";
|
|
4
|
+
import { b as ze, f as Ie } from "./formatting.es-RclXHhKo.mjs";
|
|
5
|
+
import { _ as Ae, a as je } from "./Button.vue.es-BJEy-e9C.mjs";
|
|
6
|
+
import { _ as ri } from "./ErrorNotification.vue.es-B3mvv79S.mjs";
|
|
7
|
+
import { c as li } from "./countryData.es-BegoD-cZ.mjs";
|
|
8
|
+
import { c as si } from "./subscriptions-U4xg2CO1.mjs";
|
|
9
|
+
import { A as De } from "./error-BHVZJGwD.mjs";
|
|
10
|
+
import { c as ci, _ as ui } from "./TrialChip.vue.es-c7tZOIW3.mjs";
|
|
11
|
+
import { a as di } from "./useService-Bh47bllz.mjs";
|
|
12
|
+
import { c as pi } from "./invoices-CrO6p4Ms.mjs";
|
|
13
|
+
import { g as Ne, b as Tt, e as mi } from "./pricingPlanSchedule-BPrS2WRd.mjs";
|
|
14
|
+
import { u as gi, r as ht, e as yi, a as Re, _ as vi } from "./index-BPU8tIml.mjs";
|
|
15
|
+
import { o as fi, u as _i, _ as Mi, a as hi } from "./useCustomerFormLabels-BC1WfqWo.mjs";
|
|
16
|
+
import { u as bi } from "./useWatchDebounced-DT5IicPp.mjs";
|
|
17
|
+
import { u as Ii } from "./usePaymentMethodOptions-MSEp39xQ.mjs";
|
|
18
|
+
import { c as et, a as Ai, d as Pi } from "./subscription-CrVOr5MF.mjs";
|
|
19
|
+
import { a as Di, b as wt } from "./pricing-DLOeiAIB.mjs";
|
|
20
|
+
import { g as Te, s as Ni } from "./url-DwiuKYpu.mjs";
|
|
21
|
+
import { P as Ei, e as Ci, c as bt, d as xi } from "./adyen-CvsH5fok.mjs";
|
|
22
|
+
import { u as Li } from "./usePortal-CMHV-ShD.mjs";
|
|
23
|
+
import { g as Ti } from "./getCountryNameByCode.es-BDHua7VM.mjs";
|
|
24
|
+
import { _ as It } from "./Expand.vue.es-BleuAfDz.mjs";
|
|
25
|
+
import { _ as ye } from "./Input.vue.es-5Cq8a7oH.mjs";
|
|
26
|
+
import { _ as ge } from "./Section.vue.es-C2_topx4.mjs";
|
|
27
|
+
import { _ as wi } from "./Alert.vue.es-lIiAWf2S.mjs";
|
|
28
|
+
import { c as Si } from "./customer-DmsKYpVi.mjs";
|
|
29
|
+
import { b as Oi, c as ki, a as zi, _ as Ze } from "./EmptyStatePlaceholder.vue_vue_type_script_setup_true_lang-YcaBJDzx.mjs";
|
|
30
|
+
import { _ as ji, T as Ri, a as Bi } from "./TooltipParagraph.vue.es-Fu9Od3Vr.mjs";
|
|
31
|
+
import { _ as $i } from "./PaymentFeedbackCard.vue_vue_type_script_setup_true_lang-CcdhYTB1.mjs";
|
|
32
|
+
import { _ as At } from "./Chip.vue.es-DGbc4L_D.mjs";
|
|
33
|
+
import { _ as Ui, a as Vi } from "./SecurePaymentsKPI.vue_vue_type_script_setup_true_lang-C9q_qwjt.mjs";
|
|
34
|
+
import { _ as Fi } from "./SubscriptionSummary.vue_vue_type_script_setup_true_lang-CjzjchsS.mjs";
|
|
35
|
+
import { u as St } from "./useViewport-BgdA2PPt.mjs";
|
|
36
|
+
import { _ as fe } from "./Skeleton.vue_vue_type_script_setup_true_lang-DRLoYWGY.mjs";
|
|
37
|
+
import { _ as Gi } from "./DividerText.vue.es-CFZUQ62L.mjs";
|
|
38
|
+
import { l as Ve } from "./adyenSdk-B01MB9Ia.mjs";
|
|
39
|
+
import { c as Yi } from "./payments-VS_N2xpJ.mjs";
|
|
40
|
+
import { c as Ki } from "./paymentFailure-Bh60UhxA.mjs";
|
|
41
|
+
import { C as Qi } from "./ContentWithAsideLayout-Bnbsq8_5.mjs";
|
|
42
|
+
import { u as Hi } from "./cn.es-C8Ogac5T.mjs";
|
|
43
|
+
import { a as Zi } from "./sessionReference-3h-6FdrC.mjs";
|
|
44
|
+
const Xi = {
|
|
44
45
|
AT: "Austria",
|
|
45
46
|
BE: "Belgium",
|
|
46
47
|
BG: "Bulgaria",
|
|
@@ -69,10 +70,10 @@ const Qi = {
|
|
|
69
70
|
SI: "Slovenia",
|
|
70
71
|
SK: "Slovakia"
|
|
71
72
|
};
|
|
72
|
-
function
|
|
73
|
-
return Object.keys(
|
|
73
|
+
function Ot(e) {
|
|
74
|
+
return Object.keys(Xi).includes(e);
|
|
74
75
|
}
|
|
75
|
-
function
|
|
76
|
+
function Pt(e, i) {
|
|
76
77
|
var o = Object.keys(e);
|
|
77
78
|
if (Object.getOwnPropertySymbols) {
|
|
78
79
|
var n = Object.getOwnPropertySymbols(e);
|
|
@@ -82,18 +83,18 @@ function At(e, i) {
|
|
|
82
83
|
}
|
|
83
84
|
return o;
|
|
84
85
|
}
|
|
85
|
-
function
|
|
86
|
+
function Se(e) {
|
|
86
87
|
for (var i = 1; i < arguments.length; i++) {
|
|
87
88
|
var o = arguments[i] != null ? arguments[i] : {};
|
|
88
|
-
i % 2 ?
|
|
89
|
-
|
|
90
|
-
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(o)) :
|
|
89
|
+
i % 2 ? Pt(Object(o), !0).forEach(function(n) {
|
|
90
|
+
Wi(e, n, o[n]);
|
|
91
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(o)) : Pt(Object(o)).forEach(function(n) {
|
|
91
92
|
Object.defineProperty(e, n, Object.getOwnPropertyDescriptor(o, n));
|
|
92
93
|
});
|
|
93
94
|
}
|
|
94
95
|
return e;
|
|
95
96
|
}
|
|
96
|
-
function
|
|
97
|
+
function Wi(e, i, o) {
|
|
97
98
|
return i in e ? Object.defineProperty(e, i, {
|
|
98
99
|
value: o,
|
|
99
100
|
enumerable: !0,
|
|
@@ -101,87 +102,87 @@ function Hi(e, i, o) {
|
|
|
101
102
|
writable: !0
|
|
102
103
|
}) : e[i] = o, e;
|
|
103
104
|
}
|
|
104
|
-
function
|
|
105
|
+
function Ue(e) {
|
|
105
106
|
return typeof e == "function";
|
|
106
107
|
}
|
|
107
|
-
function
|
|
108
|
+
function qe(e) {
|
|
108
109
|
return e !== null && typeof e == "object" && !Array.isArray(e);
|
|
109
110
|
}
|
|
110
111
|
function Fe(e) {
|
|
111
|
-
return
|
|
112
|
+
return Ue(e.$validator) ? Se({}, e) : {
|
|
112
113
|
$validator: e
|
|
113
114
|
};
|
|
114
115
|
}
|
|
115
|
-
function
|
|
116
|
+
function kt(e) {
|
|
116
117
|
return typeof e == "object" ? e.$valid : e;
|
|
117
118
|
}
|
|
118
|
-
function
|
|
119
|
+
function zt(e) {
|
|
119
120
|
return e.$validator || e;
|
|
120
121
|
}
|
|
121
|
-
function
|
|
122
|
-
if (!
|
|
123
|
-
if (!
|
|
122
|
+
function qi(e, i) {
|
|
123
|
+
if (!qe(e)) throw new Error(`[@vuelidate/validators]: First parameter to "withParams" should be an object, provided ${typeof e}`);
|
|
124
|
+
if (!qe(i) && !Ue(i)) throw new Error("[@vuelidate/validators]: Validator must be a function or object with $validator parameter");
|
|
124
125
|
const o = Fe(i);
|
|
125
|
-
return o.$params =
|
|
126
|
+
return o.$params = Se(Se({}, o.$params || {}), e), o;
|
|
126
127
|
}
|
|
127
|
-
function
|
|
128
|
-
if (!
|
|
129
|
-
if (!
|
|
128
|
+
function Ji(e, i) {
|
|
129
|
+
if (!Ue(e) && typeof t(e) != "string") throw new Error(`[@vuelidate/validators]: First parameter to "withMessage" should be string or a function returning a string, provided ${typeof e}`);
|
|
130
|
+
if (!qe(i) && !Ue(i)) throw new Error("[@vuelidate/validators]: Validator must be a function or object with $validator parameter");
|
|
130
131
|
const o = Fe(i);
|
|
131
132
|
return o.$message = e, o;
|
|
132
133
|
}
|
|
133
|
-
function
|
|
134
|
+
function eo(e) {
|
|
134
135
|
let i = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : [];
|
|
135
136
|
const o = Fe(e);
|
|
136
|
-
return
|
|
137
|
+
return Se(Se({}, o), {}, {
|
|
137
138
|
$async: !0,
|
|
138
139
|
$watchTargets: i
|
|
139
140
|
});
|
|
140
141
|
}
|
|
141
|
-
function
|
|
142
|
+
function to(e) {
|
|
142
143
|
return {
|
|
143
144
|
$validator(i) {
|
|
144
145
|
for (var o = arguments.length, n = new Array(o > 1 ? o - 1 : 0), a = 1; a < o; a++)
|
|
145
146
|
n[a - 1] = arguments[a];
|
|
146
|
-
return t(i).reduce((l,
|
|
147
|
-
const
|
|
148
|
-
let [
|
|
149
|
-
const
|
|
150
|
-
let [
|
|
151
|
-
const
|
|
152
|
-
if (
|
|
153
|
-
let
|
|
154
|
-
const
|
|
155
|
-
typeof
|
|
147
|
+
return t(i).reduce((l, c, m) => {
|
|
148
|
+
const u = Object.entries(c).reduce((N, v) => {
|
|
149
|
+
let [M, A] = v;
|
|
150
|
+
const d = e[M] || {}, L = Object.entries(d).reduce((k, p) => {
|
|
151
|
+
let [C, x] = p;
|
|
152
|
+
const Q = zt(x).call(this, A, c, m, ...n), s = kt(Q);
|
|
153
|
+
if (k.$data[C] = Q, k.$data.$invalid = !s || !!k.$data.$invalid, k.$data.$error = k.$data.$invalid, !s) {
|
|
154
|
+
let P = x.$message || "";
|
|
155
|
+
const q = x.$params || {};
|
|
156
|
+
typeof P == "function" && (P = P({
|
|
156
157
|
$pending: !1,
|
|
157
|
-
$invalid: !
|
|
158
|
-
$params:
|
|
158
|
+
$invalid: !s,
|
|
159
|
+
$params: q,
|
|
159
160
|
$model: A,
|
|
160
|
-
$response:
|
|
161
|
-
})),
|
|
162
|
-
$property:
|
|
163
|
-
$message:
|
|
164
|
-
$params:
|
|
165
|
-
$response:
|
|
161
|
+
$response: Q
|
|
162
|
+
})), k.$errors.push({
|
|
163
|
+
$property: M,
|
|
164
|
+
$message: P,
|
|
165
|
+
$params: q,
|
|
166
|
+
$response: Q,
|
|
166
167
|
$model: A,
|
|
167
168
|
$pending: !1,
|
|
168
|
-
$validator:
|
|
169
|
+
$validator: C
|
|
169
170
|
});
|
|
170
171
|
}
|
|
171
172
|
return {
|
|
172
|
-
$valid:
|
|
173
|
-
$data:
|
|
174
|
-
$errors:
|
|
173
|
+
$valid: k.$valid && s,
|
|
174
|
+
$data: k.$data,
|
|
175
|
+
$errors: k.$errors
|
|
175
176
|
};
|
|
176
177
|
}, {
|
|
177
178
|
$valid: !0,
|
|
178
179
|
$data: {},
|
|
179
180
|
$errors: []
|
|
180
181
|
});
|
|
181
|
-
return
|
|
182
|
-
$valid:
|
|
183
|
-
$data:
|
|
184
|
-
$errors:
|
|
182
|
+
return N.$data[M] = L.$data, N.$errors[M] = L.$errors, {
|
|
183
|
+
$valid: N.$valid && L.$valid,
|
|
184
|
+
$data: N.$data,
|
|
185
|
+
$errors: N.$errors
|
|
185
186
|
};
|
|
186
187
|
}, {
|
|
187
188
|
$valid: !0,
|
|
@@ -189,9 +190,9 @@ function qi(e) {
|
|
|
189
190
|
$errors: {}
|
|
190
191
|
});
|
|
191
192
|
return {
|
|
192
|
-
$valid: l.$valid &&
|
|
193
|
-
$data: l.$data.concat(
|
|
194
|
-
$errors: l.$errors.concat(
|
|
193
|
+
$valid: l.$valid && u.$valid,
|
|
194
|
+
$data: l.$data.concat(u.$data),
|
|
195
|
+
$errors: l.$errors.concat(u.$errors)
|
|
195
196
|
};
|
|
196
197
|
}, {
|
|
197
198
|
$valid: !0,
|
|
@@ -207,7 +208,7 @@ function qi(e) {
|
|
|
207
208
|
}
|
|
208
209
|
};
|
|
209
210
|
}
|
|
210
|
-
const
|
|
211
|
+
const jt = (e) => {
|
|
211
212
|
if (e = t(e), Array.isArray(e)) return !!e.length;
|
|
212
213
|
if (e == null)
|
|
213
214
|
return !1;
|
|
@@ -220,39 +221,39 @@ const Ot = (e) => {
|
|
|
220
221
|
return !1;
|
|
221
222
|
}
|
|
222
223
|
return !!String(e).length;
|
|
223
|
-
},
|
|
224
|
-
function
|
|
224
|
+
}, io = (e) => (e = t(e), Array.isArray(e) ? e.length : typeof e == "object" ? Object.keys(e).length : String(e).length);
|
|
225
|
+
function he() {
|
|
225
226
|
for (var e = arguments.length, i = new Array(e), o = 0; o < e; o++)
|
|
226
227
|
i[o] = arguments[o];
|
|
227
|
-
return (n) => (n = t(n), !
|
|
228
|
+
return (n) => (n = t(n), !jt(n) || i.every((a) => (a.lastIndex = 0, a.test(n))));
|
|
228
229
|
}
|
|
229
|
-
var
|
|
230
|
+
var oo = /* @__PURE__ */ Object.freeze({
|
|
230
231
|
__proto__: null,
|
|
231
|
-
forEach:
|
|
232
|
-
len:
|
|
232
|
+
forEach: to,
|
|
233
|
+
len: io,
|
|
233
234
|
normalizeValidatorObject: Fe,
|
|
234
|
-
regex:
|
|
235
|
-
req:
|
|
235
|
+
regex: he,
|
|
236
|
+
req: jt,
|
|
236
237
|
unwrap: t,
|
|
237
|
-
unwrapNormalizedValidator:
|
|
238
|
-
unwrapValidatorResponse:
|
|
239
|
-
withAsync:
|
|
240
|
-
withMessage:
|
|
241
|
-
withParams:
|
|
238
|
+
unwrapNormalizedValidator: zt,
|
|
239
|
+
unwrapValidatorResponse: kt,
|
|
240
|
+
withAsync: eo,
|
|
241
|
+
withMessage: Ji,
|
|
242
|
+
withParams: qi
|
|
242
243
|
});
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
const
|
|
247
|
-
|
|
248
|
-
const
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
function
|
|
253
|
-
return !!
|
|
244
|
+
he(/^[a-zA-Z]*$/);
|
|
245
|
+
he(/^[a-zA-Z0-9]*$/);
|
|
246
|
+
he(/^\d*(\.\d+)?$/);
|
|
247
|
+
const no = /^(?:[A-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[A-z0-9!#$%&'*+/=?^_`{|}~-]+)*|"(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21\x23-\x5b\x5d-\x7f]|[\x01-\x09\x0b\x0c\x0e-\x7f])*")@(?:(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9]{2,}(?:[a-z0-9-]*[a-z0-9])?|\[(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?|[a-z0-9-]*[a-z0-9]:(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21-\x5a\x53-\x7f]|\\[\x01-\x09\x0b\x0c\x0e-\x7f])+)\])$/i;
|
|
248
|
+
he(no);
|
|
249
|
+
const ao = /^(?:(?:(?:https?|ftp):)?\/\/)(?:\S+(?::\S*)?@)?(?:(?!(?:10|127)(?:\.\d{1,3}){3})(?!(?:169\.254|192\.168)(?:\.\d{1,3}){2})(?!172\.(?:1[6-9]|2\d|3[0-1])(?:\.\d{1,3}){2})(?:[1-9]\d?|1\d\d|2[01]\d|22[0-3])(?:\.(?:1?\d{1,2}|2[0-4]\d|25[0-5])){2}(?:\.(?:[1-9]\d?|1\d\d|2[0-4]\d|25[0-4]))|(?:(?:[a-z0-9\u00a1-\uffff][a-z0-9\u00a1-\uffff_-]{0,62})?[a-z0-9\u00a1-\uffff]\.)+(?:[a-z\u00a1-\uffff]{2,}\.?))(?::\d{2,5})?(?:[/?#]\S*)?$/i;
|
|
250
|
+
he(ao);
|
|
251
|
+
he(/(^[0-9]*$)|(^-[0-9]+$)/);
|
|
252
|
+
he(/^[-]?\d*(\.\d+)?$/);
|
|
253
|
+
function Ge(e) {
|
|
254
|
+
return !!li.find((i) => i.key === e);
|
|
254
255
|
}
|
|
255
|
-
const
|
|
256
|
+
const Rt = {
|
|
256
257
|
AT: {
|
|
257
258
|
regex: /^ATU\d{8}$/,
|
|
258
259
|
prefix: "AT",
|
|
@@ -423,13 +424,13 @@ const zt = {
|
|
|
423
424
|
prefix: "XI",
|
|
424
425
|
example: "XI123456789"
|
|
425
426
|
}
|
|
426
|
-
},
|
|
427
|
+
}, ro = (e) => !e || typeof e != "string" || e.trim() === "" ? !0 : Object.values(Rt).some((i) => i.regex.test(e)), lo = ({ $model: e }) => {
|
|
427
428
|
if (!e || typeof e != "string" || e.trim() === "")
|
|
428
429
|
return "";
|
|
429
|
-
const i =
|
|
430
|
+
const i = qt(oi, null);
|
|
430
431
|
if (!i)
|
|
431
432
|
return "Invalid tax ID";
|
|
432
|
-
const { formatMessage: o } = i, n = Object.values(
|
|
433
|
+
const { formatMessage: o } = i, n = Object.values(Rt).find(
|
|
433
434
|
(a) => e.toUpperCase().startsWith(a.prefix.toUpperCase())
|
|
434
435
|
);
|
|
435
436
|
return n ? o(
|
|
@@ -444,34 +445,34 @@ const zt = {
|
|
|
444
445
|
id: "taxId.invalid",
|
|
445
446
|
description: "Error message when tax ID is invalid"
|
|
446
447
|
});
|
|
447
|
-
},
|
|
448
|
+
}, tt = oo.withMessage(lo, ro), so = "preview", co = "NL", Bt = (e) => {
|
|
448
449
|
var i, o;
|
|
449
450
|
if ("organization" in e)
|
|
450
451
|
return (i = e.organization) == null ? void 0 : i.registered_address;
|
|
451
452
|
if ("individual" in e)
|
|
452
453
|
return (o = e.individual) == null ? void 0 : o.residential_address;
|
|
453
|
-
},
|
|
454
|
-
const i =
|
|
454
|
+
}, uo = (e) => {
|
|
455
|
+
const i = Bt(e);
|
|
455
456
|
return {
|
|
456
457
|
...(i == null ? void 0 : i.line1) && { line1: i.line1 },
|
|
457
458
|
...(i == null ? void 0 : i.line2) && { line2: i.line2 },
|
|
458
459
|
...(i == null ? void 0 : i.city) && { city: i.city },
|
|
459
460
|
...(i == null ? void 0 : i.state) && { state: i.state },
|
|
460
|
-
country: (i == null ? void 0 : i.country) ||
|
|
461
|
+
country: (i == null ? void 0 : i.country) || co,
|
|
461
462
|
...(i == null ? void 0 : i.postal_code) && { postal_code: i.postal_code }
|
|
462
463
|
};
|
|
463
|
-
},
|
|
464
|
+
}, po = (e) => {
|
|
464
465
|
var n, a;
|
|
465
|
-
const i =
|
|
466
|
+
const i = uo(e), o = e.type ?? "INDIVIDUAL";
|
|
466
467
|
if (o === "ORGANIZATION") {
|
|
467
|
-
const l = "organization" in e ? e.organization : void 0,
|
|
468
|
+
const l = "organization" in e ? e.organization : void 0, c = (a = (n = l == null ? void 0 : l.tax_ids) == null ? void 0 : n[0]) == null ? void 0 : a.id;
|
|
468
469
|
return {
|
|
469
470
|
type: o,
|
|
470
471
|
organization: {
|
|
471
|
-
legal_name: (l == null ? void 0 : l.legal_name) ||
|
|
472
|
+
legal_name: (l == null ? void 0 : l.legal_name) || so,
|
|
472
473
|
registered_address: i,
|
|
473
|
-
...
|
|
474
|
-
tax_id:
|
|
474
|
+
...c && {
|
|
475
|
+
tax_id: tt.$validator(c, {}, {}) ? c : void 0
|
|
475
476
|
}
|
|
476
477
|
}
|
|
477
478
|
};
|
|
@@ -482,7 +483,7 @@ const zt = {
|
|
|
482
483
|
residential_address: i
|
|
483
484
|
}
|
|
484
485
|
};
|
|
485
|
-
},
|
|
486
|
+
}, mo = {
|
|
486
487
|
AD: "EUR",
|
|
487
488
|
AE: "AED",
|
|
488
489
|
AF: "AFN",
|
|
@@ -730,121 +731,123 @@ const zt = {
|
|
|
730
731
|
ZA: "ZAR",
|
|
731
732
|
ZM: "ZMW",
|
|
732
733
|
ZW: "ZWL"
|
|
733
|
-
},
|
|
734
|
+
}, go = (e) => {
|
|
734
735
|
if (e)
|
|
735
|
-
return
|
|
736
|
-
},
|
|
736
|
+
return mo[e];
|
|
737
|
+
}, $t = ({
|
|
737
738
|
country: e,
|
|
738
739
|
pricingCurrencySettings: i,
|
|
739
740
|
fallbackCurrency: o
|
|
740
741
|
}) => {
|
|
741
|
-
const n =
|
|
742
|
+
const n = go(e), a = (i == null ? void 0 : i.pricing_currencies) ?? [];
|
|
742
743
|
return n && a.includes(n) ? n : (i == null ? void 0 : i.default_pricing_currency) ?? o ?? n;
|
|
743
|
-
},
|
|
744
|
-
const { getInvoicePreview: e } =
|
|
744
|
+
}, yo = () => {
|
|
745
|
+
const { getInvoicePreview: e } = pi(), i = Me(), o = V(), n = V(), a = V(), l = V({}), c = V(De.Initial), m = V({}), u = V(), N = (M) => `${M.type}:${M.value}`;
|
|
745
746
|
return {
|
|
746
747
|
loadInvoicePreview: async ({
|
|
747
|
-
subscription:
|
|
748
|
+
subscription: M,
|
|
748
749
|
subscriptionStartAt: A,
|
|
749
|
-
customer:
|
|
750
|
-
seatsValues:
|
|
751
|
-
|
|
752
|
-
|
|
750
|
+
customer: d = {},
|
|
751
|
+
seatsValues: L,
|
|
752
|
+
unitsValues: k,
|
|
753
|
+
enabledPricingIds: p,
|
|
754
|
+
promotionCode: C
|
|
753
755
|
}) => {
|
|
754
|
-
var
|
|
755
|
-
const
|
|
756
|
-
|
|
757
|
-
const
|
|
758
|
-
pricingPlanScheduleInfos:
|
|
756
|
+
var g, h, w, j, H, Y;
|
|
757
|
+
const x = po(d);
|
|
758
|
+
c.value = De.Loading;
|
|
759
|
+
const R = Ne({
|
|
760
|
+
pricingPlanScheduleInfos: M.pricing_plan_schedule_infos,
|
|
759
761
|
type: "DEFAULT"
|
|
760
|
-
}),
|
|
761
|
-
country: (
|
|
762
|
-
pricingCurrencySettings:
|
|
763
|
-
fallbackCurrency:
|
|
762
|
+
}), Q = (g = R == null ? void 0 : R.pricing_plan_version) == null ? void 0 : g.pricing_currency_settings, s = (((h = Q == null ? void 0 : Q.pricing_currencies) == null ? void 0 : h.length) ?? 0) > 1, P = ((j = (w = R == null ? void 0 : R.pricing_plan_version) == null ? void 0 : w.billing_period_settings) == null ? void 0 : j.billing_periods) ?? [], q = P.length > 1, te = P.length > 0 ? P.map(({ period: G }) => G) : M.billing_period ? [M.billing_period] : [], f = $t({
|
|
763
|
+
country: (H = Bt(d)) == null ? void 0 : H.country,
|
|
764
|
+
pricingCurrencySettings: Q,
|
|
765
|
+
fallbackCurrency: M.billing_currency
|
|
764
766
|
});
|
|
765
|
-
if (!
|
|
767
|
+
if (!te.length) {
|
|
766
768
|
i.warn("INVOICE_PREVIEW_SKIPPED", "No billing period to preview an invoice for", {
|
|
767
|
-
subscriptionId:
|
|
768
|
-
}),
|
|
769
|
+
subscriptionId: M.id
|
|
770
|
+
}), c.value = De.Done;
|
|
769
771
|
return;
|
|
770
772
|
}
|
|
771
|
-
const
|
|
772
|
-
var
|
|
773
|
-
const
|
|
774
|
-
enabledPricings:
|
|
775
|
-
pricing_id:
|
|
773
|
+
const y = M.billing_period ? N(M.billing_period) : N(te[0]), r = te.map(async (G) => {
|
|
774
|
+
var ie;
|
|
775
|
+
const ae = N(G), Z = Tt({
|
|
776
|
+
enabledPricings: p == null ? void 0 : p.map((J) => ({
|
|
777
|
+
pricing_id: J
|
|
776
778
|
})),
|
|
777
|
-
seatsValues:
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
|
|
779
|
+
seatsValues: L,
|
|
780
|
+
unitsValues: k,
|
|
781
|
+
pricingPlanScheduleInfos: M.pricing_plan_schedule_infos,
|
|
782
|
+
pricingCurrency: s ? f : void 0,
|
|
783
|
+
billingPeriod: q ? G : void 0
|
|
781
784
|
}) ?? [];
|
|
782
|
-
if (
|
|
783
|
-
const
|
|
784
|
-
({ pricing_plan_schedule:
|
|
785
|
-
)) == null ? void 0 :
|
|
786
|
-
if (
|
|
787
|
-
const
|
|
788
|
-
({ pricing_plan_schedule_id:
|
|
785
|
+
if (C) {
|
|
786
|
+
const J = (ie = M.pricing_plan_schedule_infos.find(
|
|
787
|
+
({ pricing_plan_schedule: ee }) => ee.type === "DEFAULT"
|
|
788
|
+
)) == null ? void 0 : ie.id;
|
|
789
|
+
if (J) {
|
|
790
|
+
const ee = Z.find(
|
|
791
|
+
({ pricing_plan_schedule_id: oe }) => oe === J
|
|
789
792
|
);
|
|
790
|
-
|
|
791
|
-
pricing_plan_schedule_id:
|
|
792
|
-
promotion_codes: [
|
|
793
|
+
ee ? ee.promotion_codes = [C] : Z.push({
|
|
794
|
+
pricing_plan_schedule_id: J,
|
|
795
|
+
promotion_codes: [C]
|
|
793
796
|
});
|
|
794
797
|
}
|
|
795
798
|
}
|
|
796
|
-
const
|
|
797
|
-
pricingPlanSubscriptionId:
|
|
799
|
+
const re = {
|
|
800
|
+
pricingPlanSubscriptionId: M.id,
|
|
798
801
|
startAt: A,
|
|
799
|
-
customizations:
|
|
800
|
-
customer:
|
|
801
|
-
},
|
|
802
|
-
if (
|
|
803
|
-
return { periodKey:
|
|
804
|
-
|
|
805
|
-
...
|
|
806
|
-
[
|
|
802
|
+
customizations: Z,
|
|
803
|
+
customer: x
|
|
804
|
+
}, ne = m.value[ae];
|
|
805
|
+
if (ne && di(re, ne))
|
|
806
|
+
return { periodKey: ae, response: void 0 };
|
|
807
|
+
m.value = {
|
|
808
|
+
...m.value,
|
|
809
|
+
[ae]: re
|
|
807
810
|
};
|
|
808
|
-
const
|
|
809
|
-
return { periodKey:
|
|
811
|
+
const $ = await e(re);
|
|
812
|
+
return { periodKey: ae, response: $ };
|
|
810
813
|
});
|
|
811
814
|
try {
|
|
812
|
-
const
|
|
815
|
+
const G = {
|
|
813
816
|
...l.value
|
|
814
|
-
},
|
|
815
|
-
({ pricing_plan_schedule:
|
|
816
|
-
),
|
|
817
|
-
({ pricing_plan_schedule:
|
|
818
|
-
)) == null ? void 0 :
|
|
819
|
-
|
|
820
|
-
var
|
|
821
|
-
if (
|
|
822
|
-
|
|
823
|
-
new Date(
|
|
824
|
-
new Date(
|
|
817
|
+
}, ae = await Promise.all(r), Z = M.pricing_plan_schedule_infos.find(
|
|
818
|
+
({ pricing_plan_schedule: ne }) => ne.type === "TRIAL"
|
|
819
|
+
), re = (Y = M.pricing_plan_schedule_infos.find(
|
|
820
|
+
({ pricing_plan_schedule: ne }) => ne.type === "DEFAULT"
|
|
821
|
+
)) == null ? void 0 : Y.id;
|
|
822
|
+
ae.forEach(({ periodKey: ne, response: $ }) => {
|
|
823
|
+
var ee;
|
|
824
|
+
if (!$) return;
|
|
825
|
+
u.value = (ee = $.invoice_infos.at(-1)) == null ? void 0 : ee.pricing_plan_schedule_id, Z && (n.value = $.first_invoice, Z.start_at && Z.end_at && (o.value = ci(
|
|
826
|
+
new Date(Z.start_at),
|
|
827
|
+
new Date(Z.end_at)
|
|
825
828
|
)));
|
|
826
|
-
const
|
|
827
|
-
({ pricing_plan_schedule_id:
|
|
828
|
-
),
|
|
829
|
-
|
|
830
|
-
}), l.value =
|
|
831
|
-
} catch (
|
|
832
|
-
throw
|
|
829
|
+
const ie = $.invoice_infos.find(
|
|
830
|
+
({ pricing_plan_schedule_id: oe }) => oe === re
|
|
831
|
+
), J = ie == null ? void 0 : ie.invoices[0];
|
|
832
|
+
J && (G[ne] = J);
|
|
833
|
+
}), l.value = G, a.value = G[y];
|
|
834
|
+
} catch (G) {
|
|
835
|
+
throw c.value = De.Failed, i.error("INVOICE_PREVIEW_FAILED", "Failed to load invoice preview", {}, G), G;
|
|
833
836
|
} finally {
|
|
834
|
-
|
|
837
|
+
c.value = De.Done;
|
|
835
838
|
}
|
|
836
839
|
},
|
|
837
840
|
invoicePreview: a,
|
|
838
841
|
invoicePreviewByBillingPeriod: l,
|
|
839
842
|
trialInvoicePreview: n,
|
|
840
843
|
trialPeriod: o,
|
|
841
|
-
lastPreviewScheduleId:
|
|
842
|
-
isPending: b(() =>
|
|
844
|
+
lastPreviewScheduleId: u,
|
|
845
|
+
isPending: b(() => c.value === De.Loading)
|
|
843
846
|
};
|
|
844
|
-
},
|
|
847
|
+
}, Dt = ["email", "country"], Ut = "GENERIC_TAX_ID", Nt = {
|
|
845
848
|
US: ["addressLine1", "postalCode"],
|
|
846
849
|
CA: ["state"]
|
|
847
|
-
},
|
|
850
|
+
}, vo = (e) => !e || !Nt[e] ? Dt : [...Nt[e], ...Dt], Et = (e) => {
|
|
848
851
|
const i = {
|
|
849
852
|
...e.addressLine1 && { line1: e.addressLine1 },
|
|
850
853
|
...e.addressLine2 && { line2: e.addressLine2 },
|
|
@@ -859,7 +862,7 @@ const zt = {
|
|
|
859
862
|
legal_name: e.companyLegalName ?? "",
|
|
860
863
|
registered_address: i,
|
|
861
864
|
...e.companyVatNumber && {
|
|
862
|
-
tax_ids: [{ id: e.companyVatNumber, type:
|
|
865
|
+
tax_ids: [{ id: e.companyVatNumber, type: Ut }]
|
|
863
866
|
}
|
|
864
867
|
}
|
|
865
868
|
} : {
|
|
@@ -869,7 +872,7 @@ const zt = {
|
|
|
869
872
|
}
|
|
870
873
|
};
|
|
871
874
|
};
|
|
872
|
-
function
|
|
875
|
+
function fo() {
|
|
873
876
|
return {
|
|
874
877
|
/**
|
|
875
878
|
* Get geolocation information from the user
|
|
@@ -879,66 +882,70 @@ function go() {
|
|
|
879
882
|
}
|
|
880
883
|
};
|
|
881
884
|
}
|
|
882
|
-
function
|
|
885
|
+
function _o({
|
|
883
886
|
initialState: e,
|
|
884
887
|
onRequiredFieldChange: i
|
|
885
888
|
}) {
|
|
886
|
-
const o = V(
|
|
887
|
-
const
|
|
888
|
-
o.value =
|
|
889
|
+
const o = V(Be(e)), n = V(Be(e)), a = (v) => {
|
|
890
|
+
const M = Be({ ...Jt(o.value), ...v });
|
|
891
|
+
o.value = M, n.value = structuredClone(M);
|
|
889
892
|
}, l = b(
|
|
890
|
-
() =>
|
|
891
|
-
),
|
|
893
|
+
() => vo(o.value.country)
|
|
894
|
+
), c = (v) => l.value.includes(v), m = gi(
|
|
892
895
|
{
|
|
893
|
-
email: { required:
|
|
894
|
-
country: { required:
|
|
895
|
-
state: { required:
|
|
896
|
-
addressLine1: { required:
|
|
897
|
-
postalCode: { required:
|
|
898
|
-
companyLegalName:
|
|
899
|
-
companyVatNumber: { taxId:
|
|
896
|
+
email: { required: ht, email: yi },
|
|
897
|
+
country: { required: ht },
|
|
898
|
+
state: { required: Re(() => c("state")) },
|
|
899
|
+
addressLine1: { required: Re(() => c("addressLine1")) },
|
|
900
|
+
postalCode: { required: Re(() => c("postalCode")) },
|
|
901
|
+
companyLegalName: Re(o.value.type === "ORGANIZATION"),
|
|
902
|
+
companyVatNumber: { taxId: tt }
|
|
900
903
|
},
|
|
901
904
|
o
|
|
902
|
-
),
|
|
903
|
-
|
|
904
|
-
o.value.country =
|
|
905
|
+
), u = (v) => {
|
|
906
|
+
v || fo().getGeoLocation().then(({ country: M }) => {
|
|
907
|
+
o.value.country = M;
|
|
905
908
|
});
|
|
906
|
-
},
|
|
907
|
-
const A =
|
|
908
|
-
if (
|
|
909
|
-
if (["type", "companyVatNumber"].includes(
|
|
910
|
-
i(
|
|
909
|
+
}, N = (v, M) => {
|
|
910
|
+
const A = fi({ from: M, to: v }), d = Object.keys(A).find(Mo);
|
|
911
|
+
if (d) {
|
|
912
|
+
if (["type", "companyVatNumber"].includes(d)) {
|
|
913
|
+
i(v);
|
|
911
914
|
return;
|
|
912
915
|
}
|
|
913
|
-
if (
|
|
914
|
-
i(
|
|
916
|
+
if (d === "seatsValues") {
|
|
917
|
+
i(v);
|
|
915
918
|
return;
|
|
916
919
|
}
|
|
917
|
-
if (
|
|
918
|
-
i(
|
|
920
|
+
if (d === "unitsValues") {
|
|
921
|
+
i(v);
|
|
919
922
|
return;
|
|
920
923
|
}
|
|
921
|
-
if (
|
|
922
|
-
i(
|
|
924
|
+
if (d === "enabledPricingIds") {
|
|
925
|
+
i(v);
|
|
926
|
+
return;
|
|
927
|
+
}
|
|
928
|
+
if (d !== "email" && c(d)) {
|
|
929
|
+
i(v);
|
|
923
930
|
return;
|
|
924
931
|
}
|
|
925
932
|
}
|
|
926
933
|
};
|
|
927
|
-
return
|
|
928
|
-
await
|
|
929
|
-
}),
|
|
934
|
+
return Oe(async () => {
|
|
935
|
+
await u(e == null ? void 0 : e.country);
|
|
936
|
+
}), bi(
|
|
930
937
|
() => JSON.parse(JSON.stringify(o.value)),
|
|
931
|
-
|
|
938
|
+
N,
|
|
932
939
|
{ debounce: 200 }
|
|
933
940
|
), {
|
|
934
941
|
form: o,
|
|
935
|
-
validation:
|
|
936
|
-
getIsFieldRequired:
|
|
942
|
+
validation: m,
|
|
943
|
+
getIsFieldRequired: c,
|
|
937
944
|
updateInitialState: a,
|
|
938
945
|
initialState: n
|
|
939
946
|
};
|
|
940
947
|
}
|
|
941
|
-
const
|
|
948
|
+
const Be = (e = {}) => ({
|
|
942
949
|
email: void 0,
|
|
943
950
|
country: void 0,
|
|
944
951
|
type: "INDIVIDUAL",
|
|
@@ -953,44 +960,60 @@ const Re = (e = {}) => ({
|
|
|
953
960
|
state: void 0,
|
|
954
961
|
companyVatNumber: void 0,
|
|
955
962
|
seatsValues: void 0,
|
|
963
|
+
unitsValues: void 0,
|
|
956
964
|
enabledPricingIds: void 0,
|
|
957
965
|
...e
|
|
958
966
|
});
|
|
959
|
-
function
|
|
960
|
-
return e in
|
|
967
|
+
function Mo(e) {
|
|
968
|
+
return e in Be();
|
|
961
969
|
}
|
|
962
|
-
function
|
|
963
|
-
const o = i ?? [], n =
|
|
970
|
+
function ho(e, i = void 0) {
|
|
971
|
+
const o = i ?? [], n = et(e);
|
|
964
972
|
for (const a of n)
|
|
965
973
|
if (["EXACTLY_ONE", "AT_LEAST_ONE"].includes(a.selection_constraint)) {
|
|
966
|
-
const l = a.pricings.map((
|
|
967
|
-
if (i != null && i.some((
|
|
974
|
+
const l = a.pricings.map((c) => c.id);
|
|
975
|
+
if (i != null && i.some((c) => l.includes(c)))
|
|
968
976
|
continue;
|
|
969
977
|
o.push(a.pricings[0].id);
|
|
970
978
|
}
|
|
971
979
|
return o;
|
|
972
980
|
}
|
|
973
|
-
function
|
|
974
|
-
return
|
|
981
|
+
function bo(e) {
|
|
982
|
+
return et(e).some(
|
|
975
983
|
(o) => o.selection_constraint === "EXACTLY_ONE" || o.selection_constraint === "AT_LEAST_ONE"
|
|
976
984
|
);
|
|
977
985
|
}
|
|
978
|
-
function
|
|
979
|
-
const i =
|
|
986
|
+
function Io(e) {
|
|
987
|
+
const i = Di(e.pricing_plan_schedule_infos), o = et(e);
|
|
980
988
|
return i.some((n) => n.product_type === "ADDON") || o.some((n) => n.object_type === "ADDON");
|
|
981
989
|
}
|
|
982
|
-
const
|
|
990
|
+
const Ct = (e) => (e ?? []).flatMap(
|
|
983
991
|
(i) => i.configs ?? []
|
|
984
|
-
),
|
|
992
|
+
), Vt = (e) => [
|
|
985
993
|
...e.configs ?? [],
|
|
986
|
-
...
|
|
994
|
+
...Ct(e.billing_period_configs),
|
|
987
995
|
...(e.pricing_currency_configs ?? []).flatMap((i) => [
|
|
988
996
|
...i.configs ?? [],
|
|
989
|
-
...
|
|
997
|
+
...Ct(i.billing_period_configs)
|
|
990
998
|
])
|
|
991
999
|
];
|
|
992
|
-
function
|
|
993
|
-
|
|
1000
|
+
function wa({
|
|
1001
|
+
pricings: e,
|
|
1002
|
+
pricingItemConfigId: i
|
|
1003
|
+
}) {
|
|
1004
|
+
var l, c;
|
|
1005
|
+
const o = e.flatMap((m) => m.items ?? []).find((m) => {
|
|
1006
|
+
var u;
|
|
1007
|
+
return (u = m.configs) == null ? void 0 : u.some((N) => N.id === i);
|
|
1008
|
+
}), n = (l = o == null ? void 0 : o.configs) == null ? void 0 : l.find((m) => m.id === i), a = (c = o == null ? void 0 : o.product_items) == null ? void 0 : c[0];
|
|
1009
|
+
return {
|
|
1010
|
+
config: n,
|
|
1011
|
+
productItem: a
|
|
1012
|
+
};
|
|
1013
|
+
}
|
|
1014
|
+
const Ao = "1";
|
|
1015
|
+
function Po(e) {
|
|
1016
|
+
const i = wt(e).flatMap((o) => o.items ?? []).flatMap(Vt);
|
|
994
1017
|
return new Map(
|
|
995
1018
|
i.flatMap(
|
|
996
1019
|
(o) => {
|
|
@@ -1000,44 +1023,67 @@ function Io(e) {
|
|
|
1000
1023
|
)
|
|
1001
1024
|
);
|
|
1002
1025
|
}
|
|
1003
|
-
function
|
|
1026
|
+
function Do(e) {
|
|
1004
1027
|
var n;
|
|
1005
1028
|
const i = (n = e == null ? void 0 : e.pricing_plan_schedule) == null ? void 0 : n.seats_values;
|
|
1006
1029
|
if (!e || !(i != null && i.length))
|
|
1007
1030
|
return;
|
|
1008
|
-
const o = e.pricing_plan_version ?
|
|
1031
|
+
const o = e.pricing_plan_version ? Po(e) : /* @__PURE__ */ new Map();
|
|
1032
|
+
return i.map(({ pricing_item_config_id: a, number: l }) => ({
|
|
1033
|
+
pricing_item_config_id: a,
|
|
1034
|
+
number: l || o.get(a) || Ao
|
|
1035
|
+
}));
|
|
1036
|
+
}
|
|
1037
|
+
const No = "1";
|
|
1038
|
+
function Eo(e) {
|
|
1039
|
+
const i = wt(e).flatMap((o) => o.items ?? []).flatMap(Vt);
|
|
1040
|
+
return new Map(
|
|
1041
|
+
i.flatMap(
|
|
1042
|
+
(o) => {
|
|
1043
|
+
var n;
|
|
1044
|
+
return (n = o.default_units) != null && n.number ? [[o.id, o.default_units.number]] : [];
|
|
1045
|
+
}
|
|
1046
|
+
)
|
|
1047
|
+
);
|
|
1048
|
+
}
|
|
1049
|
+
function Co(e) {
|
|
1050
|
+
var n;
|
|
1051
|
+
const i = (n = e == null ? void 0 : e.pricing_plan_schedule) == null ? void 0 : n.units;
|
|
1052
|
+
if (!e || !(i != null && i.length))
|
|
1053
|
+
return;
|
|
1054
|
+
const o = e.pricing_plan_version ? Eo(e) : /* @__PURE__ */ new Map();
|
|
1009
1055
|
return i.map(({ pricing_item_config_id: a, number: l }) => ({
|
|
1010
1056
|
pricing_item_config_id: a,
|
|
1011
|
-
number: l || o.get(a) ||
|
|
1057
|
+
number: l || o.get(a) || No
|
|
1012
1058
|
}));
|
|
1013
1059
|
}
|
|
1014
|
-
const
|
|
1015
|
-
function
|
|
1060
|
+
const Xe = "solvimon_checkout_redirect_state";
|
|
1061
|
+
function xo({
|
|
1016
1062
|
initialCountry: e,
|
|
1017
1063
|
initialEmail: i,
|
|
1018
1064
|
subscriptionId: o,
|
|
1019
1065
|
enabledPricingIds: n
|
|
1020
1066
|
}) {
|
|
1021
|
-
const a =
|
|
1067
|
+
const a = Me(), l = (() => {
|
|
1022
1068
|
if (e) {
|
|
1023
|
-
if (
|
|
1069
|
+
if (Ge(e)) return e;
|
|
1024
1070
|
a.error("INVALID_COUNTRY_CODE", `invalid country code provided: "${e}"`);
|
|
1025
1071
|
}
|
|
1026
|
-
})(),
|
|
1072
|
+
})(), c = (() => {
|
|
1027
1073
|
if (i) {
|
|
1028
1074
|
if (/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(i)) return i;
|
|
1029
1075
|
a.error("INVALID_EMAIL", `invalid email provided: "${i}"`);
|
|
1030
1076
|
}
|
|
1031
|
-
})(),
|
|
1077
|
+
})(), m = V(!1), u = V(), { getSubscription: N } = si(), v = yo(), M = b(() => u.value && s.form.value.country && te.value), {
|
|
1032
1078
|
paymentMethodOptions: A,
|
|
1033
|
-
get:
|
|
1034
|
-
isPending:
|
|
1035
|
-
error:
|
|
1036
|
-
} =
|
|
1079
|
+
get: d,
|
|
1080
|
+
isPending: L,
|
|
1081
|
+
error: k
|
|
1082
|
+
} = Ii(), p = async (y, r) => {
|
|
1037
1083
|
try {
|
|
1038
|
-
await
|
|
1039
|
-
subscriptionId:
|
|
1040
|
-
country:
|
|
1084
|
+
await d({
|
|
1085
|
+
subscriptionId: u.value.id,
|
|
1086
|
+
country: y,
|
|
1041
1087
|
amount: r
|
|
1042
1088
|
});
|
|
1043
1089
|
} catch {
|
|
@@ -1045,143 +1091,150 @@ function Po({
|
|
|
1045
1091
|
"PAYMENT_METHOD_OPTIONS_LOAD_FAILED",
|
|
1046
1092
|
"Failed to load the payment methods the checkout can offer",
|
|
1047
1093
|
{},
|
|
1048
|
-
|
|
1094
|
+
k.value
|
|
1049
1095
|
);
|
|
1050
1096
|
}
|
|
1051
|
-
},
|
|
1052
|
-
const { country:
|
|
1053
|
-
!
|
|
1054
|
-
},
|
|
1055
|
-
const
|
|
1056
|
-
return
|
|
1057
|
-
subscription:
|
|
1058
|
-
customer:
|
|
1059
|
-
seatsValues:
|
|
1060
|
-
|
|
1061
|
-
|
|
1097
|
+
}, C = b(() => k.value !== null), x = () => {
|
|
1098
|
+
const { country: y } = s.form.value;
|
|
1099
|
+
!u.value || !y || !te.value || p(y, te.value);
|
|
1100
|
+
}, R = () => {
|
|
1101
|
+
const y = s.form.value;
|
|
1102
|
+
return v.loadInvoicePreview({
|
|
1103
|
+
subscription: u.value,
|
|
1104
|
+
customer: Et(y),
|
|
1105
|
+
seatsValues: y.seatsValues,
|
|
1106
|
+
unitsValues: y.unitsValues,
|
|
1107
|
+
enabledPricingIds: y.enabledPricingIds ?? n,
|
|
1108
|
+
promotionCode: y.promotionCode
|
|
1062
1109
|
});
|
|
1063
|
-
},
|
|
1064
|
-
const r =
|
|
1065
|
-
return await
|
|
1066
|
-
subscription:
|
|
1067
|
-
customer:
|
|
1110
|
+
}, Q = async (y) => {
|
|
1111
|
+
const r = y.promotionCode ?? s.form.value.promotionCode, g = y.enabledPricingIds ?? s.form.value.enabledPricingIds, h = { ...s.form.value, ...y };
|
|
1112
|
+
return await v.loadInvoicePreview({
|
|
1113
|
+
subscription: u.value,
|
|
1114
|
+
customer: Et(h),
|
|
1068
1115
|
seatsValues: h.seatsValues,
|
|
1069
|
-
|
|
1116
|
+
unitsValues: h.unitsValues,
|
|
1117
|
+
enabledPricingIds: g,
|
|
1070
1118
|
promotionCode: r
|
|
1071
1119
|
}), {
|
|
1072
|
-
trialInvoicePreview:
|
|
1073
|
-
invoicePreview:
|
|
1120
|
+
trialInvoicePreview: v.trialInvoicePreview.value,
|
|
1121
|
+
invoicePreview: v.invoicePreview.value
|
|
1074
1122
|
};
|
|
1075
|
-
},
|
|
1123
|
+
}, s = _o({
|
|
1076
1124
|
initialState: {
|
|
1077
1125
|
country: l,
|
|
1078
|
-
email:
|
|
1126
|
+
email: c
|
|
1079
1127
|
},
|
|
1080
1128
|
onRequiredFieldChange: () => {
|
|
1081
|
-
|
|
1129
|
+
u.value && R().catch(() => {
|
|
1082
1130
|
});
|
|
1083
1131
|
}
|
|
1084
|
-
}),
|
|
1085
|
-
var
|
|
1086
|
-
const
|
|
1132
|
+
}), P = async () => {
|
|
1133
|
+
var j, H, Y, G;
|
|
1134
|
+
const y = await N({
|
|
1087
1135
|
id: o,
|
|
1088
1136
|
expanded: !0
|
|
1089
|
-
}), r =
|
|
1090
|
-
pricingPlanScheduleInfos:
|
|
1137
|
+
}), r = Ne({
|
|
1138
|
+
pricingPlanScheduleInfos: y.pricing_plan_schedule_infos,
|
|
1091
1139
|
type: "DEFAULT"
|
|
1092
|
-
}),
|
|
1093
|
-
|
|
1094
|
-
...
|
|
1095
|
-
billing_period:
|
|
1140
|
+
}), g = (G = (Y = (H = (j = r == null ? void 0 : r.pricing_plan_version) == null ? void 0 : j.billing_period_settings) == null ? void 0 : H.billing_periods) == null ? void 0 : Y[0]) == null ? void 0 : G.period;
|
|
1141
|
+
u.value = {
|
|
1142
|
+
...y,
|
|
1143
|
+
billing_period: g ?? y.billing_period
|
|
1096
1144
|
};
|
|
1097
|
-
const h =
|
|
1098
|
-
|
|
1099
|
-
...
|
|
1100
|
-
enabledPricingIds:
|
|
1101
|
-
...h ? { seatsValues: h } : {}
|
|
1145
|
+
const h = Do(r), w = Co(r);
|
|
1146
|
+
s.updateInitialState({
|
|
1147
|
+
...s.form.value,
|
|
1148
|
+
enabledPricingIds: ho(y, n),
|
|
1149
|
+
...h ? { seatsValues: h } : {},
|
|
1150
|
+
...w ? { unitsValues: w } : {}
|
|
1102
1151
|
});
|
|
1103
|
-
},
|
|
1104
|
-
var
|
|
1105
|
-
const
|
|
1106
|
-
...
|
|
1107
|
-
...
|
|
1108
|
-
...
|
|
1152
|
+
}, q = b(() => {
|
|
1153
|
+
var Z, re, ne, $, ie, J, ee, oe, ue;
|
|
1154
|
+
const y = s.form.value.firstName || s.form.value.infix || s.form.value.lastName ? {
|
|
1155
|
+
...s.form.value.firstName ? { first_name: s.form.value.firstName } : {},
|
|
1156
|
+
...s.form.value.infix ? { infix: s.form.value.infix } : {},
|
|
1157
|
+
...s.form.value.lastName ? { last_name: s.form.value.lastName } : {}
|
|
1109
1158
|
} : {}, r = {
|
|
1110
|
-
...
|
|
1111
|
-
line1:
|
|
1159
|
+
...s.form.value.addressLine1 && {
|
|
1160
|
+
line1: s.form.value.addressLine1
|
|
1112
1161
|
},
|
|
1113
|
-
...
|
|
1114
|
-
line2:
|
|
1162
|
+
...s.form.value.addressLine2 && {
|
|
1163
|
+
line2: s.form.value.addressLine2
|
|
1115
1164
|
},
|
|
1116
|
-
...
|
|
1117
|
-
...
|
|
1118
|
-
postal_code:
|
|
1165
|
+
...s.form.value.city && { city: s.form.value.city },
|
|
1166
|
+
...s.form.value.postalCode && {
|
|
1167
|
+
postal_code: s.form.value.postalCode
|
|
1119
1168
|
},
|
|
1120
|
-
...
|
|
1121
|
-
country:
|
|
1122
|
-
},
|
|
1123
|
-
pricingPlanScheduleInfos: ((
|
|
1169
|
+
...s.form.value.state && { state: s.form.value.state },
|
|
1170
|
+
country: s.form.value.country ?? ""
|
|
1171
|
+
}, g = Ne({
|
|
1172
|
+
pricingPlanScheduleInfos: ((Z = u.value) == null ? void 0 : Z.pricing_plan_schedule_infos) ?? [],
|
|
1124
1173
|
type: "DEFAULT"
|
|
1125
|
-
}), h = (
|
|
1126
|
-
enabledPricings: (
|
|
1127
|
-
pricing_id:
|
|
1174
|
+
}), h = (re = g == null ? void 0 : g.pricing_plan_version) == null ? void 0 : re.pricing_currency_settings, w = (((ne = h == null ? void 0 : h.pricing_currencies) == null ? void 0 : ne.length) ?? 0) > 1, H = (((ie = ($ = g == null ? void 0 : g.pricing_plan_version) == null ? void 0 : $.billing_period_settings) == null ? void 0 : ie.billing_periods) ?? []).length > 1, Y = Tt({
|
|
1175
|
+
enabledPricings: (J = s.form.value.enabledPricingIds) == null ? void 0 : J.map((de) => ({
|
|
1176
|
+
pricing_id: de
|
|
1128
1177
|
})),
|
|
1129
|
-
seatsValues:
|
|
1130
|
-
|
|
1131
|
-
|
|
1132
|
-
|
|
1133
|
-
|
|
1134
|
-
|
|
1135
|
-
|
|
1136
|
-
|
|
1178
|
+
seatsValues: s.form.value.seatsValues,
|
|
1179
|
+
unitsValues: s.form.value.unitsValues,
|
|
1180
|
+
pricingPlanScheduleInfos: ((ee = u.value) == null ? void 0 : ee.pricing_plan_schedule_infos) ?? [],
|
|
1181
|
+
pricingCurrency: w ? (oe = u.value) == null ? void 0 : oe.billing_currency : void 0,
|
|
1182
|
+
billingPeriod: H ? (ue = u.value) == null ? void 0 : ue.billing_period : void 0
|
|
1183
|
+
}), G = s.form.value.promotionCode, ae = G && u.value ? (() => {
|
|
1184
|
+
var Ce, ke, xe;
|
|
1185
|
+
const de = Y ? [...Y] : [], pe = ((Ce = de[0]) == null ? void 0 : Ce.pricing_plan_schedule_id) ?? ((xe = Ne({
|
|
1186
|
+
pricingPlanScheduleInfos: ((ke = u.value) == null ? void 0 : ke.pricing_plan_schedule_infos) ?? [],
|
|
1137
1187
|
type: "DEFAULT"
|
|
1138
|
-
})) == null ? void 0 :
|
|
1139
|
-
if (!
|
|
1140
|
-
return
|
|
1141
|
-
const
|
|
1142
|
-
({ pricing_plan_schedule_id:
|
|
1188
|
+
})) == null ? void 0 : xe.id);
|
|
1189
|
+
if (!pe)
|
|
1190
|
+
return Y;
|
|
1191
|
+
const Ee = de.find(
|
|
1192
|
+
({ pricing_plan_schedule_id: le }) => le === pe
|
|
1143
1193
|
);
|
|
1144
|
-
if (
|
|
1145
|
-
|
|
1194
|
+
if (Ee)
|
|
1195
|
+
Ee.promotion_codes = [G];
|
|
1146
1196
|
else {
|
|
1147
|
-
const
|
|
1148
|
-
|
|
1149
|
-
pricing_plan_schedule_id:
|
|
1150
|
-
...(
|
|
1151
|
-
enabled_pricings:
|
|
1197
|
+
const le = Y == null ? void 0 : Y[0];
|
|
1198
|
+
de.push({
|
|
1199
|
+
pricing_plan_schedule_id: pe,
|
|
1200
|
+
...(le == null ? void 0 : le.enabled_pricings) && {
|
|
1201
|
+
enabled_pricings: le.enabled_pricings
|
|
1202
|
+
},
|
|
1203
|
+
...(le == null ? void 0 : le.seats_values) && {
|
|
1204
|
+
seats_values: le.seats_values
|
|
1152
1205
|
},
|
|
1153
|
-
...(
|
|
1154
|
-
|
|
1206
|
+
...(le == null ? void 0 : le.units) && {
|
|
1207
|
+
units: le.units
|
|
1155
1208
|
},
|
|
1156
|
-
promotion_codes: [
|
|
1209
|
+
promotion_codes: [G]
|
|
1157
1210
|
});
|
|
1158
1211
|
}
|
|
1159
|
-
return
|
|
1160
|
-
})() :
|
|
1212
|
+
return de;
|
|
1213
|
+
})() : Y;
|
|
1161
1214
|
return {
|
|
1162
1215
|
type: "INIT_PRICING_PLAN_SUBSCRIPTION",
|
|
1163
1216
|
init_pricing_plan_subscription: {
|
|
1164
1217
|
template_pricing_plan_subscription_id: o,
|
|
1165
|
-
...
|
|
1166
|
-
pricing_plan_schedule_customizations:
|
|
1218
|
+
...ae && {
|
|
1219
|
+
pricing_plan_schedule_customizations: ae
|
|
1167
1220
|
},
|
|
1168
1221
|
customer_details: {
|
|
1169
|
-
email:
|
|
1170
|
-
type:
|
|
1171
|
-
...
|
|
1222
|
+
email: s.form.value.email ?? "",
|
|
1223
|
+
type: s.form.value.type,
|
|
1224
|
+
...s.form.value.type === "INDIVIDUAL" ? {
|
|
1172
1225
|
individual: {
|
|
1173
1226
|
residential_address: r,
|
|
1174
|
-
...
|
|
1227
|
+
...y ? { name: y } : {}
|
|
1175
1228
|
}
|
|
1176
1229
|
} : {
|
|
1177
1230
|
organization: {
|
|
1178
1231
|
registered_address: r,
|
|
1179
|
-
legal_name:
|
|
1180
|
-
...
|
|
1232
|
+
legal_name: s.form.value.companyLegalName ?? "",
|
|
1233
|
+
...s.form.value.companyVatNumber && tt.$validator(s.form.value.companyVatNumber, {}, {}) ? {
|
|
1181
1234
|
tax_ids: [
|
|
1182
1235
|
{
|
|
1183
|
-
id:
|
|
1184
|
-
type:
|
|
1236
|
+
id: s.form.value.companyVatNumber,
|
|
1237
|
+
type: Ut
|
|
1185
1238
|
}
|
|
1186
1239
|
]
|
|
1187
1240
|
} : {}
|
|
@@ -1191,31 +1244,31 @@ function Po({
|
|
|
1191
1244
|
}
|
|
1192
1245
|
};
|
|
1193
1246
|
}), te = b(() => {
|
|
1194
|
-
var
|
|
1195
|
-
return ((
|
|
1247
|
+
var y, r;
|
|
1248
|
+
return ((y = v.trialInvoicePreview.value) == null ? void 0 : y.invoice_amount_including_tax) ?? ((r = v.invoicePreview.value) == null ? void 0 : r.invoice_amount_including_tax);
|
|
1196
1249
|
});
|
|
1197
|
-
|
|
1198
|
-
[() =>
|
|
1199
|
-
([
|
|
1200
|
-
!
|
|
1250
|
+
we(
|
|
1251
|
+
[() => s.form.value.country, te],
|
|
1252
|
+
([y, r]) => {
|
|
1253
|
+
!u.value || !y || !r || p(y, r);
|
|
1201
1254
|
}
|
|
1202
1255
|
);
|
|
1203
|
-
function
|
|
1204
|
-
sessionStorage.setItem(
|
|
1256
|
+
function f() {
|
|
1257
|
+
sessionStorage.setItem(Xe, JSON.stringify(s.form.value));
|
|
1205
1258
|
}
|
|
1206
|
-
return
|
|
1207
|
-
const
|
|
1208
|
-
|
|
1209
|
-
const
|
|
1210
|
-
let
|
|
1211
|
-
if (
|
|
1259
|
+
return Oe(async () => {
|
|
1260
|
+
const y = Te("redirect_status"), r = !!Te(Ei), g = !!Te("payment_intent_client_secret") || !!Te("setup_intent_client_secret");
|
|
1261
|
+
y === "succeeded" && r && g && (m.value = !0);
|
|
1262
|
+
const w = sessionStorage.getItem(Xe);
|
|
1263
|
+
let j = null;
|
|
1264
|
+
if (w)
|
|
1212
1265
|
try {
|
|
1213
|
-
|
|
1266
|
+
j = JSON.parse(w);
|
|
1214
1267
|
} catch {
|
|
1215
1268
|
}
|
|
1216
|
-
|
|
1269
|
+
j && s.updateInitialState(j);
|
|
1217
1270
|
try {
|
|
1218
|
-
await
|
|
1271
|
+
await P();
|
|
1219
1272
|
} catch (H) {
|
|
1220
1273
|
throw a.error(
|
|
1221
1274
|
"SUBSCRIPTION_LOAD_FAILED",
|
|
@@ -1225,99 +1278,99 @@ function Po({
|
|
|
1225
1278
|
), H;
|
|
1226
1279
|
}
|
|
1227
1280
|
try {
|
|
1228
|
-
await
|
|
1281
|
+
await R();
|
|
1229
1282
|
} catch {
|
|
1230
1283
|
}
|
|
1231
|
-
|
|
1232
|
-
}),
|
|
1233
|
-
|
|
1234
|
-
(
|
|
1235
|
-
|
|
1284
|
+
j && (s.updateInitialState(j), sessionStorage.removeItem(Xe));
|
|
1285
|
+
}), we(
|
|
1286
|
+
M,
|
|
1287
|
+
(y) => {
|
|
1288
|
+
y && x();
|
|
1236
1289
|
},
|
|
1237
1290
|
{ once: !0 }
|
|
1238
1291
|
), {
|
|
1239
1292
|
/** What the host configured, once anything unusable has been dropped and reported. */
|
|
1240
|
-
validatedEmail:
|
|
1293
|
+
validatedEmail: c,
|
|
1241
1294
|
validatedCountry: l,
|
|
1242
|
-
invoicePreview:
|
|
1243
|
-
invoicePreviewByBillingPeriod:
|
|
1244
|
-
trialInvoicePreview:
|
|
1245
|
-
trialPeriod:
|
|
1246
|
-
loadInvoicePreview:
|
|
1247
|
-
updateInvoicePreviewOnBillingInformationChange:
|
|
1248
|
-
lastPreviewScheduleId:
|
|
1295
|
+
invoicePreview: v.invoicePreview,
|
|
1296
|
+
invoicePreviewByBillingPeriod: v.invoicePreviewByBillingPeriod,
|
|
1297
|
+
trialInvoicePreview: v.trialInvoicePreview,
|
|
1298
|
+
trialPeriod: v.trialPeriod,
|
|
1299
|
+
loadInvoicePreview: R,
|
|
1300
|
+
updateInvoicePreviewOnBillingInformationChange: Q,
|
|
1301
|
+
lastPreviewScheduleId: v.lastPreviewScheduleId,
|
|
1249
1302
|
paymentMethodOptions: A,
|
|
1250
|
-
hasPaymentMethodOptionsError:
|
|
1251
|
-
retryPaymentMethodOptions:
|
|
1252
|
-
isPaymentMethodsPending:
|
|
1253
|
-
isInvoicePreviewPending:
|
|
1254
|
-
subscription:
|
|
1255
|
-
checkoutForm:
|
|
1256
|
-
authorizationContext:
|
|
1257
|
-
isPaid:
|
|
1303
|
+
hasPaymentMethodOptionsError: C,
|
|
1304
|
+
retryPaymentMethodOptions: x,
|
|
1305
|
+
isPaymentMethodsPending: L,
|
|
1306
|
+
isInvoicePreviewPending: v.isPending,
|
|
1307
|
+
subscription: u,
|
|
1308
|
+
checkoutForm: s,
|
|
1309
|
+
authorizationContext: q,
|
|
1310
|
+
isPaid: m,
|
|
1258
1311
|
amount: te,
|
|
1259
|
-
saveFormStateForRedirect:
|
|
1312
|
+
saveFormStateForRedirect: f
|
|
1260
1313
|
};
|
|
1261
1314
|
}
|
|
1262
|
-
function
|
|
1315
|
+
function Lo({
|
|
1263
1316
|
checkoutForm: e,
|
|
1264
1317
|
updateInvoicePreviewOnBillingInformationChange: i,
|
|
1265
1318
|
formatErrorMessage: o,
|
|
1266
1319
|
onInvalidPromotionCode: n,
|
|
1267
1320
|
onApplyError: a
|
|
1268
1321
|
}) {
|
|
1269
|
-
const l =
|
|
1270
|
-
|
|
1271
|
-
},
|
|
1272
|
-
const
|
|
1273
|
-
if (
|
|
1274
|
-
|
|
1322
|
+
const l = Me(), c = V(!1), m = V(null), u = (A, d) => {
|
|
1323
|
+
m.value = o ? o({ action: A, error: d }) : A === "apply" ? "Promotion code could not be applied. Please try again." : "Promotion code could not be removed. Please try again.";
|
|
1324
|
+
}, N = (A) => To(A) && A.field === "promotion_codes", v = async (A) => {
|
|
1325
|
+
const d = A == null ? void 0 : A.trim();
|
|
1326
|
+
if (d) {
|
|
1327
|
+
m.value = null, e.form.value.promotionCode = d, c.value = !0;
|
|
1275
1328
|
try {
|
|
1276
1329
|
await i({
|
|
1277
|
-
promotionCode:
|
|
1330
|
+
promotionCode: d
|
|
1278
1331
|
});
|
|
1279
|
-
} catch (
|
|
1280
|
-
l.capture(
|
|
1332
|
+
} catch (L) {
|
|
1333
|
+
l.capture(L, {
|
|
1281
1334
|
code: "PROMOTION_CODE_APPLY_FAILED",
|
|
1282
1335
|
message: "Failed to apply promotion code"
|
|
1283
|
-
}),
|
|
1336
|
+
}), u("apply", L), a == null || a(), N(L) && (n == null || n()), await M({ suppressError: !0, preserveErrorMessage: !0 });
|
|
1284
1337
|
} finally {
|
|
1285
|
-
|
|
1338
|
+
c.value = !1;
|
|
1286
1339
|
}
|
|
1287
1340
|
}
|
|
1288
|
-
},
|
|
1341
|
+
}, M = async ({
|
|
1289
1342
|
suppressError: A = !1,
|
|
1290
|
-
preserveErrorMessage:
|
|
1343
|
+
preserveErrorMessage: d = !1
|
|
1291
1344
|
} = {}) => {
|
|
1292
|
-
|
|
1345
|
+
d || (m.value = null), delete e.form.value.promotionCode, c.value = !0;
|
|
1293
1346
|
try {
|
|
1294
1347
|
await i({});
|
|
1295
|
-
} catch (
|
|
1296
|
-
l.capture(
|
|
1348
|
+
} catch (L) {
|
|
1349
|
+
l.capture(L, {
|
|
1297
1350
|
code: "PROMOTION_CODE_REMOVE_FAILED",
|
|
1298
1351
|
message: "Failed to remove promotion code"
|
|
1299
|
-
}), A ||
|
|
1352
|
+
}), A || u("remove", L);
|
|
1300
1353
|
} finally {
|
|
1301
|
-
|
|
1354
|
+
c.value = !1;
|
|
1302
1355
|
}
|
|
1303
1356
|
};
|
|
1304
1357
|
return {
|
|
1305
|
-
applyPromotionCode:
|
|
1306
|
-
removePromotionCode:
|
|
1307
|
-
isPromotionCodePending:
|
|
1308
|
-
promotionCodeErrorMessage:
|
|
1358
|
+
applyPromotionCode: v,
|
|
1359
|
+
removePromotionCode: M,
|
|
1360
|
+
isPromotionCodePending: c,
|
|
1361
|
+
promotionCodeErrorMessage: m
|
|
1309
1362
|
};
|
|
1310
1363
|
}
|
|
1311
|
-
function
|
|
1364
|
+
function To(e) {
|
|
1312
1365
|
return typeof e == "object" && e !== null && "field" in e;
|
|
1313
1366
|
}
|
|
1314
|
-
function
|
|
1367
|
+
function wo({
|
|
1315
1368
|
subscription: e,
|
|
1316
1369
|
promotionCode: i,
|
|
1317
1370
|
appliedPromotionCode: o,
|
|
1318
1371
|
applyPromotionCode: n
|
|
1319
1372
|
}) {
|
|
1320
|
-
|
|
1373
|
+
we(
|
|
1321
1374
|
e,
|
|
1322
1375
|
(a) => {
|
|
1323
1376
|
a && i && (o.value = i, n(i));
|
|
@@ -1325,13 +1378,13 @@ function Eo({
|
|
|
1325
1378
|
{ once: !0 }
|
|
1326
1379
|
);
|
|
1327
1380
|
}
|
|
1328
|
-
const
|
|
1381
|
+
const So = { class: "flex items-center gap-2" }, Oo = /* @__PURE__ */ ce({
|
|
1329
1382
|
__name: "TaxIDCheckNotice",
|
|
1330
1383
|
props: {
|
|
1331
1384
|
taxIdValidationResult: { type: Object }
|
|
1332
1385
|
},
|
|
1333
1386
|
setup(e) {
|
|
1334
|
-
const i = e, { formatMessage: o } =
|
|
1387
|
+
const i = e, { formatMessage: o } = ve(), n = b(() => i.taxIdValidationResult.valid === "VALID"), a = b(() => n.value ? o({
|
|
1335
1388
|
defaultMessage: "VAT number is valid.",
|
|
1336
1389
|
id: "tax_check.valid_vat_number",
|
|
1337
1390
|
description: "The message shown when the VAT number is valid"
|
|
@@ -1340,15 +1393,15 @@ const Co = { class: "flex items-center gap-2" }, xo = /* @__PURE__ */ se({
|
|
|
1340
1393
|
id: "tax_check.invalid_vat_number",
|
|
1341
1394
|
description: "The message shown when the VAT number is invalid"
|
|
1342
1395
|
}));
|
|
1343
|
-
return (l,
|
|
1396
|
+
return (l, c) => (_(), O(t(wi), {
|
|
1344
1397
|
type: n.value ? "success" : "danger",
|
|
1345
1398
|
icon: !1
|
|
1346
1399
|
}, {
|
|
1347
1400
|
default: I(() => [
|
|
1348
|
-
|
|
1349
|
-
|
|
1401
|
+
T("div", So, [
|
|
1402
|
+
E(t(se), { variant: "body-xs" }, {
|
|
1350
1403
|
default: I(() => [
|
|
1351
|
-
|
|
1404
|
+
F(U(a.value), 1)
|
|
1352
1405
|
]),
|
|
1353
1406
|
_: 1
|
|
1354
1407
|
})
|
|
@@ -1358,17 +1411,17 @@ const Co = { class: "flex items-center gap-2" }, xo = /* @__PURE__ */ se({
|
|
|
1358
1411
|
}, 8, ["type"]));
|
|
1359
1412
|
}
|
|
1360
1413
|
});
|
|
1361
|
-
function
|
|
1362
|
-
const { checkTaxID: i } =
|
|
1363
|
-
var
|
|
1364
|
-
return ((
|
|
1365
|
-
}), a = b(() => e.value.companyLegalName ?? ""), l = b(() => e.value.country),
|
|
1414
|
+
function ko(e) {
|
|
1415
|
+
const { checkTaxID: i } = Si(), o = V(void 0), n = b(() => {
|
|
1416
|
+
var M;
|
|
1417
|
+
return ((M = e.value.companyVatNumber) == null ? void 0 : M.trim()) ?? "";
|
|
1418
|
+
}), a = b(() => e.value.companyLegalName ?? ""), l = b(() => e.value.country), c = V(!1), m = b(() => Ot(l.value ?? "")), u = b(
|
|
1366
1419
|
() => !!(n.value && a.value && l.value)
|
|
1367
|
-
),
|
|
1368
|
-
async function
|
|
1369
|
-
var
|
|
1370
|
-
if (!(!
|
|
1371
|
-
|
|
1420
|
+
), N = b(() => m.value && n.value);
|
|
1421
|
+
async function v() {
|
|
1422
|
+
var M;
|
|
1423
|
+
if (!(!u.value || !m.value || !l.value)) {
|
|
1424
|
+
c.value = !0;
|
|
1372
1425
|
try {
|
|
1373
1426
|
const A = await i({
|
|
1374
1427
|
type: "ORGANIZATION",
|
|
@@ -1380,24 +1433,24 @@ function Lo(e) {
|
|
|
1380
1433
|
}
|
|
1381
1434
|
}
|
|
1382
1435
|
});
|
|
1383
|
-
(
|
|
1436
|
+
(M = A == null ? void 0 : A.data) != null && M.length ? o.value = A.data[0] : o.value = void 0;
|
|
1384
1437
|
} finally {
|
|
1385
|
-
|
|
1438
|
+
c.value = !1;
|
|
1386
1439
|
}
|
|
1387
1440
|
}
|
|
1388
1441
|
}
|
|
1389
1442
|
return {
|
|
1390
|
-
runTaxIDCheck:
|
|
1443
|
+
runTaxIDCheck: v,
|
|
1391
1444
|
taxIdValidationData: o,
|
|
1392
|
-
isTaxIDCheckPending:
|
|
1393
|
-
isTaxIDCheckEnabled:
|
|
1394
|
-
showViesCheckNotice:
|
|
1395
|
-
isSelectedCountryEU:
|
|
1445
|
+
isTaxIDCheckPending: c,
|
|
1446
|
+
isTaxIDCheckEnabled: u,
|
|
1447
|
+
showViesCheckNotice: N,
|
|
1448
|
+
isSelectedCountryEU: m
|
|
1396
1449
|
};
|
|
1397
1450
|
}
|
|
1398
|
-
const
|
|
1451
|
+
const zo = { class: "grid grid-cols-1 gap-1" }, jo = { class: "grid grid-cols-1 gap-2" }, Ro = { key: 0 }, Bo = { class: "mt-2 flex flex-col gap-3" }, $o = { class: "grid grid-cols-3 gap-2" }, Uo = { key: 0 }, Vo = { class: "mt-4 grid grid-cols-1 gap-3" }, Fo = "checkout-form", Go = /* @__PURE__ */ ce({
|
|
1399
1452
|
__name: "CheckoutForm",
|
|
1400
|
-
props: /* @__PURE__ */
|
|
1453
|
+
props: /* @__PURE__ */ vt({
|
|
1401
1454
|
validation: { type: null },
|
|
1402
1455
|
initialState: { type: Object },
|
|
1403
1456
|
readOnlyEmail: { type: String },
|
|
@@ -1409,89 +1462,89 @@ const wo = { class: "grid grid-cols-1 gap-1" }, To = { class: "grid grid-cols-1
|
|
|
1409
1462
|
modelValue: { required: !0 },
|
|
1410
1463
|
modelModifiers: {}
|
|
1411
1464
|
}),
|
|
1412
|
-
emits: /* @__PURE__ */
|
|
1465
|
+
emits: /* @__PURE__ */ vt(["submit"], ["update:modelValue"]),
|
|
1413
1466
|
setup(e) {
|
|
1414
|
-
const i = e, o = V(!1), n =
|
|
1467
|
+
const i = e, o = V(!1), n = ei(e, "modelValue"), a = b({
|
|
1415
1468
|
get: () => n.value.type === "ORGANIZATION",
|
|
1416
|
-
set: (
|
|
1417
|
-
n.value.type =
|
|
1469
|
+
set: (p) => {
|
|
1470
|
+
n.value.type = p ? "ORGANIZATION" : "INDIVIDUAL";
|
|
1418
1471
|
}
|
|
1419
|
-
}), l = b(() => n.value.type === "ORGANIZATION"),
|
|
1472
|
+
}), l = b(() => n.value.type === "ORGANIZATION"), c = b({
|
|
1420
1473
|
get: () => n.value.country,
|
|
1421
|
-
set: (
|
|
1422
|
-
n.value.country =
|
|
1474
|
+
set: (p) => {
|
|
1475
|
+
n.value.country = p && Ge(p) ? p : void 0;
|
|
1423
1476
|
}
|
|
1424
|
-
}),
|
|
1477
|
+
}), m = b(() => n.value.country !== "US"), { isTaxIDCheckEnabled: u, isTaxIDCheckPending: N, taxIdValidationData: v, runTaxIDCheck: M } = ko(n), { $t: A } = ve(), d = _i(), L = (p) => i.getIsFieldRequired(p) ? "" : " " + A({
|
|
1425
1478
|
defaultMessage: "(optional)",
|
|
1426
1479
|
id: "checkout.optional_suffix.label",
|
|
1427
1480
|
description: "The suffix for optional fields in the checkout form"
|
|
1428
|
-
}),
|
|
1429
|
-
() => n.value.country ?
|
|
1481
|
+
}), k = b(
|
|
1482
|
+
() => n.value.country ? Ti(n.value.country) : void 0
|
|
1430
1483
|
);
|
|
1431
|
-
return (
|
|
1432
|
-
id:
|
|
1433
|
-
onSubmit:
|
|
1484
|
+
return (p, C) => (_(), W("form", {
|
|
1485
|
+
id: Fo,
|
|
1486
|
+
onSubmit: C[12] || (C[12] = $e((x) => p.$emit("submit", n.value), ["prevent"]))
|
|
1434
1487
|
}, [
|
|
1435
|
-
|
|
1436
|
-
|
|
1437
|
-
title: t(
|
|
1488
|
+
T("div", zo, [
|
|
1489
|
+
E(t(ge), {
|
|
1490
|
+
title: t(d).contactInformationTitle
|
|
1438
1491
|
}, {
|
|
1439
1492
|
default: I(() => [
|
|
1440
|
-
|
|
1441
|
-
e.readOnly ? (
|
|
1442
|
-
|
|
1493
|
+
T("div", jo, [
|
|
1494
|
+
e.readOnly ? (_(), W(_e, { key: 0 }, [
|
|
1495
|
+
E(t(se), {
|
|
1443
1496
|
variant: "body",
|
|
1444
1497
|
tag: "span",
|
|
1445
1498
|
weight: "semibold",
|
|
1446
1499
|
"no-spacing": ""
|
|
1447
1500
|
}, {
|
|
1448
1501
|
default: I(() => [
|
|
1449
|
-
|
|
1502
|
+
F(U(n.value.email), 1)
|
|
1450
1503
|
]),
|
|
1451
1504
|
_: 1
|
|
1452
1505
|
}),
|
|
1453
|
-
|
|
1506
|
+
E(t(se), {
|
|
1454
1507
|
variant: "body-sm",
|
|
1455
1508
|
tag: "span",
|
|
1456
1509
|
color: "subtle",
|
|
1457
1510
|
"no-spacing": ""
|
|
1458
1511
|
}, {
|
|
1459
1512
|
default: I(() => [
|
|
1460
|
-
|
|
1513
|
+
F(U(k.value), 1)
|
|
1461
1514
|
]),
|
|
1462
1515
|
_: 1
|
|
1463
1516
|
})
|
|
1464
|
-
], 64)) : (
|
|
1465
|
-
|
|
1517
|
+
], 64)) : (_(), W(_e, { key: 1 }, [
|
|
1518
|
+
E(t(ye), {
|
|
1466
1519
|
modelValue: n.value.email,
|
|
1467
|
-
"onUpdate:modelValue":
|
|
1520
|
+
"onUpdate:modelValue": C[0] || (C[0] = (x) => n.value.email = x),
|
|
1468
1521
|
required: "",
|
|
1469
1522
|
type: "email",
|
|
1470
1523
|
name: "email",
|
|
1471
1524
|
disabled: !!e.readOnlyEmail,
|
|
1472
|
-
label: t(
|
|
1473
|
-
placeholder: t(
|
|
1525
|
+
label: t(d).emailLabel,
|
|
1526
|
+
placeholder: t(d).emailPlaceholder + L("email"),
|
|
1474
1527
|
error: e.validation.value.email.$errors
|
|
1475
1528
|
}, null, 8, ["modelValue", "disabled", "label", "placeholder", "error"]),
|
|
1476
|
-
|
|
1477
|
-
"single-model-value":
|
|
1478
|
-
"onUpdate:singleModelValue":
|
|
1529
|
+
E(t(Mi), {
|
|
1530
|
+
"single-model-value": c.value,
|
|
1531
|
+
"onUpdate:singleModelValue": C[3] || (C[3] = (x) => c.value = x),
|
|
1479
1532
|
required: "",
|
|
1480
1533
|
name: "country",
|
|
1481
|
-
label: t(
|
|
1534
|
+
label: t(d).countryLabel + L("country"),
|
|
1482
1535
|
error: e.validation.value.country.$errors
|
|
1483
1536
|
}, {
|
|
1484
1537
|
"label-suffix": I(() => [
|
|
1485
|
-
!o.value && !e.isBillingInformationMandatory ? (
|
|
1538
|
+
!o.value && !e.isBillingInformationMandatory ? (_(), O(t(Ae), {
|
|
1486
1539
|
key: 0,
|
|
1487
1540
|
size: "xs",
|
|
1488
1541
|
intent: "subtle",
|
|
1489
1542
|
"icon-prefix": "add",
|
|
1490
1543
|
class: "py-0.5",
|
|
1491
|
-
onClick:
|
|
1544
|
+
onClick: C[1] || (C[1] = (x) => o.value = !0)
|
|
1492
1545
|
}, {
|
|
1493
1546
|
default: I(() => [
|
|
1494
|
-
|
|
1547
|
+
F(U(t(A)({
|
|
1495
1548
|
defaultMessage: "More billing details",
|
|
1496
1549
|
description: "Label of the button in the checkout that lets you fill out all billing details",
|
|
1497
1550
|
id: "checkout.billing_details.add_billing_details_button.label"
|
|
@@ -1499,16 +1552,16 @@ const wo = { class: "grid grid-cols-1 gap-1" }, To = { class: "grid grid-cols-1
|
|
|
1499
1552
|
]),
|
|
1500
1553
|
_: 1
|
|
1501
1554
|
})) : B("", !0),
|
|
1502
|
-
o.value && !e.isBillingInformationMandatory ? (
|
|
1555
|
+
o.value && !e.isBillingInformationMandatory ? (_(), O(t(Ae), {
|
|
1503
1556
|
key: 1,
|
|
1504
1557
|
size: "sm",
|
|
1505
1558
|
intent: "subtle",
|
|
1506
1559
|
"icon-prefix": "close",
|
|
1507
1560
|
class: "py-0.5",
|
|
1508
|
-
onClick:
|
|
1561
|
+
onClick: C[2] || (C[2] = (x) => o.value = !1)
|
|
1509
1562
|
}, {
|
|
1510
1563
|
default: I(() => [
|
|
1511
|
-
|
|
1564
|
+
F(U(t(A)({
|
|
1512
1565
|
defaultMessage: "Remove billing details",
|
|
1513
1566
|
id: "checkout.billing_details.remove_billing_details_button.label",
|
|
1514
1567
|
description: "Label of the button in the checkout that lets you remove the billing details"
|
|
@@ -1521,15 +1574,15 @@ const wo = { class: "grid grid-cols-1 gap-1" }, To = { class: "grid grid-cols-1
|
|
|
1521
1574
|
}, 8, ["single-model-value", "label", "error"])
|
|
1522
1575
|
], 64))
|
|
1523
1576
|
]),
|
|
1524
|
-
|
|
1577
|
+
E(t(It), {
|
|
1525
1578
|
"is-open": o.value || !!e.isBillingInformationMandatory
|
|
1526
1579
|
}, {
|
|
1527
1580
|
default: I(() => [
|
|
1528
|
-
o.value || e.isBillingInformationMandatory ? (
|
|
1529
|
-
|
|
1530
|
-
|
|
1581
|
+
o.value || e.isBillingInformationMandatory ? (_(), W("div", Ro, [
|
|
1582
|
+
T("div", Bo, [
|
|
1583
|
+
E(t(ye), {
|
|
1531
1584
|
modelValue: n.value.addressLine1,
|
|
1532
|
-
"onUpdate:modelValue":
|
|
1585
|
+
"onUpdate:modelValue": C[4] || (C[4] = (x) => n.value.addressLine1 = x),
|
|
1533
1586
|
name: "address_line_1",
|
|
1534
1587
|
label: t(A)({
|
|
1535
1588
|
defaultMessage: "Billing address",
|
|
@@ -1540,39 +1593,39 @@ const wo = { class: "grid grid-cols-1 gap-1" }, To = { class: "grid grid-cols-1
|
|
|
1540
1593
|
defaultMessage: "Address line 1...",
|
|
1541
1594
|
id: "checkout.address.line1.placeholder",
|
|
1542
1595
|
description: "Address line 1 of the customer address in the checkout form"
|
|
1543
|
-
}) +
|
|
1596
|
+
}) + L("addressLine1"),
|
|
1544
1597
|
required: "",
|
|
1545
1598
|
error: e.validation.value.addressLine1.$errors
|
|
1546
1599
|
}, null, 8, ["modelValue", "label", "placeholder", "error"]),
|
|
1547
|
-
|
|
1600
|
+
E(t(ye), {
|
|
1548
1601
|
modelValue: n.value.addressLine2,
|
|
1549
|
-
"onUpdate:modelValue":
|
|
1602
|
+
"onUpdate:modelValue": C[5] || (C[5] = (x) => n.value.addressLine2 = x),
|
|
1550
1603
|
name: "address_line_2",
|
|
1551
1604
|
placeholder: t(A)({
|
|
1552
1605
|
defaultMessage: "Address line 2...",
|
|
1553
1606
|
id: "checkout.address.line2.placeholder",
|
|
1554
1607
|
description: "Address line 2 of the customer address in the checkout form"
|
|
1555
|
-
}) +
|
|
1608
|
+
}) + L("addressLine2")
|
|
1556
1609
|
}, null, 8, ["modelValue", "placeholder"]),
|
|
1557
|
-
|
|
1558
|
-
|
|
1610
|
+
T("div", $o, [
|
|
1611
|
+
E(t(ye), {
|
|
1559
1612
|
modelValue: n.value.postalCode,
|
|
1560
|
-
"onUpdate:modelValue":
|
|
1613
|
+
"onUpdate:modelValue": C[6] || (C[6] = (x) => n.value.postalCode = x),
|
|
1561
1614
|
name: "postal_code",
|
|
1562
|
-
placeholder: t(
|
|
1615
|
+
placeholder: t(d).postalCodePlaceholder + L("postalCode"),
|
|
1563
1616
|
error: e.validation.value.addressLine1.$errors
|
|
1564
1617
|
}, null, 8, ["modelValue", "placeholder", "error"]),
|
|
1565
|
-
|
|
1618
|
+
E(t(ye), {
|
|
1566
1619
|
modelValue: n.value.city,
|
|
1567
|
-
"onUpdate:modelValue":
|
|
1620
|
+
"onUpdate:modelValue": C[7] || (C[7] = (x) => n.value.city = x),
|
|
1568
1621
|
name: "city",
|
|
1569
|
-
placeholder: t(
|
|
1622
|
+
placeholder: t(d).cityPlaceholder + L("city")
|
|
1570
1623
|
}, null, 8, ["modelValue", "placeholder"]),
|
|
1571
|
-
|
|
1624
|
+
E(t(ye), {
|
|
1572
1625
|
modelValue: n.value.state,
|
|
1573
|
-
"onUpdate:modelValue":
|
|
1626
|
+
"onUpdate:modelValue": C[8] || (C[8] = (x) => n.value.state = x),
|
|
1574
1627
|
name: "state",
|
|
1575
|
-
placeholder: t(
|
|
1628
|
+
placeholder: t(d).statePlaceholder + L("state"),
|
|
1576
1629
|
error: e.validation.value.state.$errors
|
|
1577
1630
|
}, null, 8, ["modelValue", "placeholder", "error"])
|
|
1578
1631
|
])
|
|
@@ -1584,49 +1637,49 @@ const wo = { class: "grid grid-cols-1 gap-1" }, To = { class: "grid grid-cols-1
|
|
|
1584
1637
|
]),
|
|
1585
1638
|
_: 1
|
|
1586
1639
|
}, 8, ["title"]),
|
|
1587
|
-
e.readOnly ? B("", !0) : (
|
|
1640
|
+
e.readOnly ? B("", !0) : (_(), O(t(ge), { key: 0 }, {
|
|
1588
1641
|
default: I(() => [
|
|
1589
|
-
|
|
1642
|
+
E(hi, {
|
|
1590
1643
|
modelValue: a.value,
|
|
1591
|
-
"onUpdate:modelValue":
|
|
1644
|
+
"onUpdate:modelValue": C[9] || (C[9] = (x) => a.value = x),
|
|
1592
1645
|
"no-spacing": "",
|
|
1593
1646
|
class: "!flex"
|
|
1594
1647
|
}, null, 8, ["modelValue"]),
|
|
1595
|
-
|
|
1648
|
+
E(t(It), { "is-open": l.value }, {
|
|
1596
1649
|
default: I(() => [
|
|
1597
|
-
l.value ? (
|
|
1598
|
-
|
|
1599
|
-
|
|
1650
|
+
l.value ? (_(), W("div", Uo, [
|
|
1651
|
+
T("div", Vo, [
|
|
1652
|
+
E(t(ye), {
|
|
1600
1653
|
modelValue: n.value.companyLegalName,
|
|
1601
|
-
"onUpdate:modelValue":
|
|
1654
|
+
"onUpdate:modelValue": C[10] || (C[10] = (x) => n.value.companyLegalName = x),
|
|
1602
1655
|
required: "",
|
|
1603
1656
|
name: "legal_name",
|
|
1604
|
-
label: t(
|
|
1605
|
-
placeholder: t(
|
|
1657
|
+
label: t(d).legalNameLabel,
|
|
1658
|
+
placeholder: t(d).legalNamePlaceholder
|
|
1606
1659
|
}, null, 8, ["modelValue", "label", "placeholder"]),
|
|
1607
|
-
|
|
1660
|
+
m.value ? (_(), O(t(ye), {
|
|
1608
1661
|
key: 0,
|
|
1609
1662
|
modelValue: n.value.companyVatNumber,
|
|
1610
|
-
"onUpdate:modelValue":
|
|
1663
|
+
"onUpdate:modelValue": C[11] || (C[11] = (x) => n.value.companyVatNumber = x),
|
|
1611
1664
|
name: "vat_number",
|
|
1612
1665
|
"input-class": "focus:outline-none focus:ring-0",
|
|
1613
|
-
label: t(
|
|
1614
|
-
placeholder: t(
|
|
1666
|
+
label: t(d).vatNumberLabel,
|
|
1667
|
+
placeholder: t(d).vatNumberPlaceholder,
|
|
1615
1668
|
error: e.validation.value.companyVatNumber.$errors,
|
|
1616
1669
|
"suffix-class": "px-2 border-l-0"
|
|
1617
|
-
},
|
|
1618
|
-
t(
|
|
1670
|
+
}, Je({ _: 2 }, [
|
|
1671
|
+
t(Ot)(n.value.country ?? "") ? {
|
|
1619
1672
|
name: "suffix",
|
|
1620
1673
|
fn: I(() => [
|
|
1621
|
-
|
|
1674
|
+
E(t(Ae), {
|
|
1622
1675
|
type: "button",
|
|
1623
1676
|
size: "sm",
|
|
1624
1677
|
intent: "secondary",
|
|
1625
|
-
disabled: !t(
|
|
1626
|
-
onClick: t(
|
|
1678
|
+
disabled: !t(u) || t(N) || e.validation.value.companyVatNumber.$invalid,
|
|
1679
|
+
onClick: t(M)
|
|
1627
1680
|
}, {
|
|
1628
1681
|
default: I(() => [
|
|
1629
|
-
|
|
1682
|
+
F(U(t(A)({
|
|
1630
1683
|
defaultMessage: "Check",
|
|
1631
1684
|
id: "checkout.vat_number.check_button.label",
|
|
1632
1685
|
description: "The label for the check button in the checkout form"
|
|
@@ -1638,11 +1691,11 @@ const wo = { class: "grid grid-cols-1 gap-1" }, To = { class: "grid grid-cols-1
|
|
|
1638
1691
|
key: "0"
|
|
1639
1692
|
} : void 0
|
|
1640
1693
|
]), 1032, ["modelValue", "label", "placeholder", "error"])) : B("", !0),
|
|
1641
|
-
t(
|
|
1694
|
+
t(v) ? (_(), W("div", {
|
|
1642
1695
|
key: 1,
|
|
1643
|
-
class:
|
|
1696
|
+
class: be({ "opacity-75": t(N) })
|
|
1644
1697
|
}, [
|
|
1645
|
-
|
|
1698
|
+
E(Oo, { "tax-id-validation-result": t(v) }, null, 8, ["tax-id-validation-result"])
|
|
1646
1699
|
], 2)) : B("", !0)
|
|
1647
1700
|
])
|
|
1648
1701
|
])) : B("", !0)
|
|
@@ -1655,10 +1708,10 @@ const wo = { class: "grid grid-cols-1 gap-1" }, To = { class: "grid grid-cols-1
|
|
|
1655
1708
|
])
|
|
1656
1709
|
], 32));
|
|
1657
1710
|
}
|
|
1658
|
-
}),
|
|
1711
|
+
}), Yo = {
|
|
1659
1712
|
key: 0,
|
|
1660
1713
|
class: "flex items-center"
|
|
1661
|
-
},
|
|
1714
|
+
}, Ko = ["innerHTML"], Qo = ["innerHTML"], Ho = /* @__PURE__ */ ce({
|
|
1662
1715
|
__name: "CheckoutTitle",
|
|
1663
1716
|
props: {
|
|
1664
1717
|
trialPeriod: { type: Object },
|
|
@@ -1670,20 +1723,20 @@ const wo = { class: "grid grid-cols-1 gap-1" }, To = { class: "grid grid-cols-1
|
|
|
1670
1723
|
subscriptionStartDate: { type: Date }
|
|
1671
1724
|
},
|
|
1672
1725
|
setup(e) {
|
|
1673
|
-
const { $t: i } =
|
|
1674
|
-
return (o, n) => (
|
|
1675
|
-
|
|
1676
|
-
|
|
1726
|
+
const { $t: i } = ve();
|
|
1727
|
+
return (o, n) => (_(), W("div", null, [
|
|
1728
|
+
T("div", null, [
|
|
1729
|
+
E(t(se), {
|
|
1677
1730
|
variant: "heading-1",
|
|
1678
1731
|
class: "inline-block"
|
|
1679
1732
|
}, {
|
|
1680
1733
|
default: I(() => [
|
|
1681
|
-
|
|
1734
|
+
F(U(e.trialStartDate ? e.subscriptionName : t(i)({
|
|
1682
1735
|
defaultMessage: "Pay and subscribe",
|
|
1683
1736
|
id: "checkout.page_title",
|
|
1684
1737
|
description: "The title of the checkout page"
|
|
1685
|
-
})) +
|
|
1686
|
-
e.trialPeriod ? (
|
|
1738
|
+
})) + U(" "), 1),
|
|
1739
|
+
e.trialPeriod ? (_(), O(t(ui), {
|
|
1687
1740
|
key: 0,
|
|
1688
1741
|
"trial-period": e.trialPeriod,
|
|
1689
1742
|
size: "lg",
|
|
@@ -1693,13 +1746,13 @@ const wo = { class: "grid grid-cols-1 gap-1" }, To = { class: "grid grid-cols-1
|
|
|
1693
1746
|
_: 1
|
|
1694
1747
|
})
|
|
1695
1748
|
]),
|
|
1696
|
-
|
|
1749
|
+
E(t(se), {
|
|
1697
1750
|
variant: "body-sm",
|
|
1698
1751
|
color: "subtle",
|
|
1699
1752
|
"no-spacing": ""
|
|
1700
1753
|
}, {
|
|
1701
1754
|
default: I(() => [
|
|
1702
|
-
e.countryCode ? (
|
|
1755
|
+
e.countryCode ? (_(), W("span", {
|
|
1703
1756
|
key: 1,
|
|
1704
1757
|
innerHTML: e.trialStartDate ? t(i)(
|
|
1705
1758
|
{
|
|
@@ -1708,10 +1761,10 @@ const wo = { class: "grid grid-cols-1 gap-1" }, To = { class: "grid grid-cols-1
|
|
|
1708
1761
|
description: "The description of the trial period"
|
|
1709
1762
|
},
|
|
1710
1763
|
{
|
|
1711
|
-
price: t(
|
|
1764
|
+
price: t(Ie)(e.amount),
|
|
1712
1765
|
// @ts-expect-error formatjs does not support this type yet
|
|
1713
1766
|
startDate: e.subscriptionStartDate,
|
|
1714
|
-
period_name: t(
|
|
1767
|
+
period_name: t(ze)(e.billingPeriod, {
|
|
1715
1768
|
short: !0,
|
|
1716
1769
|
hideValueForExactPeriods: !0
|
|
1717
1770
|
}),
|
|
@@ -1725,8 +1778,8 @@ const wo = { class: "grid grid-cols-1 gap-1" }, To = { class: "grid grid-cols-1
|
|
|
1725
1778
|
description: "The description of the subscription"
|
|
1726
1779
|
},
|
|
1727
1780
|
{
|
|
1728
|
-
price: t(
|
|
1729
|
-
period_name: t(
|
|
1781
|
+
price: t(Ie)(e.amount),
|
|
1782
|
+
period_name: t(ze)(e.billingPeriod, {
|
|
1730
1783
|
short: !0,
|
|
1731
1784
|
hideValueForExactPeriods: !0
|
|
1732
1785
|
}),
|
|
@@ -1734,14 +1787,14 @@ const wo = { class: "grid grid-cols-1 gap-1" }, To = { class: "grid grid-cols-1
|
|
|
1734
1787
|
strong: (a) => `<strong>${a}</strong>`
|
|
1735
1788
|
}
|
|
1736
1789
|
)
|
|
1737
|
-
}, null, 8,
|
|
1738
|
-
|
|
1790
|
+
}, null, 8, Qo)) : (_(), W("span", Yo, [
|
|
1791
|
+
E(t(ji), { "is-dark-mode": "" }, {
|
|
1739
1792
|
tooltip: I(() => [
|
|
1740
|
-
|
|
1793
|
+
E(t(Ri), null, {
|
|
1741
1794
|
default: I(() => [
|
|
1742
|
-
|
|
1795
|
+
E(t(Bi), null, {
|
|
1743
1796
|
default: I(() => [
|
|
1744
|
-
|
|
1797
|
+
F(U(t(i)({
|
|
1745
1798
|
defaultMessage: "Will be determined by billing information",
|
|
1746
1799
|
description: "Tooltip content for the invoice preview when taxes are not determined by billing information",
|
|
1747
1800
|
id: "invoice_preview.taxes_not_determined_by_billing_information_tooltip"
|
|
@@ -1754,7 +1807,7 @@ const wo = { class: "grid grid-cols-1 gap-1" }, To = { class: "grid grid-cols-1
|
|
|
1754
1807
|
})
|
|
1755
1808
|
]),
|
|
1756
1809
|
default: I(() => [
|
|
1757
|
-
|
|
1810
|
+
E(t(Oi), {
|
|
1758
1811
|
"width-class": "w-10",
|
|
1759
1812
|
"height-class": "h-4",
|
|
1760
1813
|
shade: "darker",
|
|
@@ -1763,7 +1816,7 @@ const wo = { class: "grid grid-cols-1 gap-1" }, To = { class: "grid grid-cols-1
|
|
|
1763
1816
|
]),
|
|
1764
1817
|
_: 1
|
|
1765
1818
|
}),
|
|
1766
|
-
|
|
1819
|
+
T("span", {
|
|
1767
1820
|
innerHTML: e.trialStartDate ? t(i)(
|
|
1768
1821
|
{
|
|
1769
1822
|
defaultMessage: "per {period_name} starting, {startDate, date, long}",
|
|
@@ -1773,7 +1826,7 @@ const wo = { class: "grid grid-cols-1 gap-1" }, To = { class: "grid grid-cols-1
|
|
|
1773
1826
|
{
|
|
1774
1827
|
// @ts-expect-error formatjs does not support this type yet
|
|
1775
1828
|
startDate: e.subscriptionStartDate,
|
|
1776
|
-
period_name: t(
|
|
1829
|
+
period_name: t(ze)(e.billingPeriod, {
|
|
1777
1830
|
short: !0,
|
|
1778
1831
|
hideValueForExactPeriods: !0
|
|
1779
1832
|
})
|
|
@@ -1785,20 +1838,20 @@ const wo = { class: "grid grid-cols-1 gap-1" }, To = { class: "grid grid-cols-1
|
|
|
1785
1838
|
description: "The description of the subscription, while the price is still being determined"
|
|
1786
1839
|
},
|
|
1787
1840
|
{
|
|
1788
|
-
period_name: t(
|
|
1841
|
+
period_name: t(ze)(e.billingPeriod, {
|
|
1789
1842
|
short: !0,
|
|
1790
1843
|
hideValueForExactPeriods: !0
|
|
1791
1844
|
})
|
|
1792
1845
|
}
|
|
1793
1846
|
)
|
|
1794
|
-
}, null, 8,
|
|
1847
|
+
}, null, 8, Ko)
|
|
1795
1848
|
]))
|
|
1796
1849
|
]),
|
|
1797
1850
|
_: 1
|
|
1798
1851
|
})
|
|
1799
1852
|
]));
|
|
1800
1853
|
}
|
|
1801
|
-
}),
|
|
1854
|
+
}), Zo = (e) => {
|
|
1802
1855
|
var i;
|
|
1803
1856
|
return ((i = e.periods) == null ? void 0 : i.some(
|
|
1804
1857
|
(o) => o.groups.some(
|
|
@@ -1806,23 +1859,23 @@ const wo = { class: "grid grid-cols-1 gap-1" }, To = { class: "grid grid-cols-1
|
|
|
1806
1859
|
var a;
|
|
1807
1860
|
return (a = n.lines) == null ? void 0 : a.some(
|
|
1808
1861
|
(l) => l.product_items.some(
|
|
1809
|
-
(
|
|
1862
|
+
(c) => c.model_type === "USAGE_BASED"
|
|
1810
1863
|
)
|
|
1811
1864
|
);
|
|
1812
1865
|
}
|
|
1813
1866
|
)
|
|
1814
1867
|
)) ?? !1;
|
|
1815
|
-
},
|
|
1868
|
+
}, Xo = { class: "flex min-h-96 w-full items-center justify-center" }, Wo = { class: "max-w-sm" }, qo = /* @__PURE__ */ ce({
|
|
1816
1869
|
__name: "CheckoutNotAvailable",
|
|
1817
1870
|
setup(e) {
|
|
1818
|
-
const { $t: i } =
|
|
1871
|
+
const { $t: i } = ve(), o = () => {
|
|
1819
1872
|
window.location.reload();
|
|
1820
1873
|
};
|
|
1821
|
-
return (n, a) => (
|
|
1822
|
-
|
|
1823
|
-
|
|
1874
|
+
return (n, a) => (_(), W("div", Xo, [
|
|
1875
|
+
T("div", Wo, [
|
|
1876
|
+
E(t(se), { variant: "heading-1" }, {
|
|
1824
1877
|
default: I(() => [
|
|
1825
|
-
|
|
1878
|
+
F(U(t(i)({
|
|
1826
1879
|
defaultMessage: "Checkout not available",
|
|
1827
1880
|
id: "checkout.not_available.title",
|
|
1828
1881
|
description: "The title of the checkout not available page"
|
|
@@ -1830,26 +1883,26 @@ const wo = { class: "grid grid-cols-1 gap-1" }, To = { class: "grid grid-cols-1
|
|
|
1830
1883
|
]),
|
|
1831
1884
|
_: 1
|
|
1832
1885
|
}),
|
|
1833
|
-
|
|
1886
|
+
E(t(se), {
|
|
1834
1887
|
variant: "body-sm",
|
|
1835
1888
|
color: "subtle"
|
|
1836
1889
|
}, {
|
|
1837
1890
|
default: I(() => [
|
|
1838
|
-
|
|
1891
|
+
F(U(t(i)({
|
|
1839
1892
|
defaultMessage: "The checkout is currently not available.",
|
|
1840
1893
|
id: "checkout.not_available.description",
|
|
1841
1894
|
description: "The description of the checkout not available page"
|
|
1842
1895
|
})) + " ", 1),
|
|
1843
|
-
|
|
1896
|
+
T("a", {
|
|
1844
1897
|
href: "#",
|
|
1845
1898
|
class: "text-primary-900 hover:underline",
|
|
1846
1899
|
onClick: $e(o, ["prevent"])
|
|
1847
|
-
},
|
|
1900
|
+
}, U(t(i)({
|
|
1848
1901
|
defaultMessage: "Reload",
|
|
1849
1902
|
id: "checkout.not_available.reload_button",
|
|
1850
1903
|
description: "The label of the reload button"
|
|
1851
1904
|
})), 1),
|
|
1852
|
-
|
|
1905
|
+
F(" " + U(t(i)({
|
|
1853
1906
|
defaultMessage: "this page to try again, or contact customer support.",
|
|
1854
1907
|
id: "checkout.not_available.contact_support_message",
|
|
1855
1908
|
description: "The message shown when the user wants to contact customer support"
|
|
@@ -1860,12 +1913,12 @@ const wo = { class: "grid grid-cols-1 gap-1" }, To = { class: "grid grid-cols-1
|
|
|
1860
1913
|
])
|
|
1861
1914
|
]));
|
|
1862
1915
|
}
|
|
1863
|
-
}),
|
|
1916
|
+
}), Jo = /* @__PURE__ */ ce({
|
|
1864
1917
|
__name: "SubscriptionPaymentCompletedCard",
|
|
1865
1918
|
emits: ["continue-to-merchant"],
|
|
1866
1919
|
setup(e) {
|
|
1867
|
-
const { $t: i } =
|
|
1868
|
-
return (o, n) => (
|
|
1920
|
+
const { $t: i } = ve();
|
|
1921
|
+
return (o, n) => (_(), O($i, {
|
|
1869
1922
|
status: "success",
|
|
1870
1923
|
title: t(i)({
|
|
1871
1924
|
defaultMessage: "Payment successful",
|
|
@@ -1874,13 +1927,13 @@ const wo = { class: "grid grid-cols-1 gap-1" }, To = { class: "grid grid-cols-1
|
|
|
1874
1927
|
})
|
|
1875
1928
|
}, {
|
|
1876
1929
|
default: I(() => [
|
|
1877
|
-
|
|
1930
|
+
E(t(se), {
|
|
1878
1931
|
variant: "body-xs",
|
|
1879
1932
|
color: "subtle",
|
|
1880
1933
|
tag: "span"
|
|
1881
1934
|
}, {
|
|
1882
1935
|
default: I(() => [
|
|
1883
|
-
|
|
1936
|
+
F(U(t(i)({
|
|
1884
1937
|
defaultMessage: "Thank you for subscribing.",
|
|
1885
1938
|
id: "subscription_payment_completed_card.thank_you_for_subscribing",
|
|
1886
1939
|
description: "The text shown after a successful message before a redirect"
|
|
@@ -1892,48 +1945,48 @@ const wo = { class: "grid grid-cols-1 gap-1" }, To = { class: "grid grid-cols-1
|
|
|
1892
1945
|
_: 1
|
|
1893
1946
|
}, 8, ["title"]));
|
|
1894
1947
|
}
|
|
1895
|
-
}),
|
|
1948
|
+
}), en = { class: "flex items-start" }, tn = { class: "flex grow flex-col" }, on = { class: "flex items-center gap-1" }, nn = { class: "ml-4 flex items-center self-center" }, an = /* @__PURE__ */ ce({
|
|
1896
1949
|
__name: "PricingGroupContent",
|
|
1897
1950
|
props: {
|
|
1898
1951
|
name: { type: String },
|
|
1899
1952
|
description: { type: String }
|
|
1900
1953
|
},
|
|
1901
1954
|
setup(e) {
|
|
1902
|
-
return (i, o) => (
|
|
1903
|
-
|
|
1904
|
-
|
|
1905
|
-
|
|
1955
|
+
return (i, o) => (_(), W("div", en, [
|
|
1956
|
+
T("div", tn, [
|
|
1957
|
+
T("div", on, [
|
|
1958
|
+
E(t(se), {
|
|
1906
1959
|
tag: "span",
|
|
1907
1960
|
variant: "body-sm",
|
|
1908
1961
|
weight: "semibold"
|
|
1909
1962
|
}, {
|
|
1910
1963
|
default: I(() => [
|
|
1911
|
-
|
|
1964
|
+
F(U(e.name), 1)
|
|
1912
1965
|
]),
|
|
1913
1966
|
_: 1
|
|
1914
1967
|
}),
|
|
1915
|
-
|
|
1968
|
+
We(i.$slots, "badge")
|
|
1916
1969
|
]),
|
|
1917
|
-
|
|
1970
|
+
E(t(se), {
|
|
1918
1971
|
tag: "span",
|
|
1919
1972
|
variant: "body-xs",
|
|
1920
1973
|
color: "subtle"
|
|
1921
1974
|
}, {
|
|
1922
1975
|
default: I(() => [
|
|
1923
|
-
|
|
1976
|
+
F(U(e.description), 1)
|
|
1924
1977
|
]),
|
|
1925
1978
|
_: 1
|
|
1926
1979
|
})
|
|
1927
1980
|
]),
|
|
1928
|
-
|
|
1929
|
-
|
|
1981
|
+
T("div", nn, [
|
|
1982
|
+
We(i.$slots, "default")
|
|
1930
1983
|
])
|
|
1931
1984
|
]));
|
|
1932
1985
|
}
|
|
1933
|
-
}),
|
|
1986
|
+
}), rn = { class: "sv-order-summary__body grid grid-cols-1 gap-1" }, ln = { class: "px-3 py-2" }, sn = { class: "sv-order-summary__billing-period flex flex-col gap-3" }, cn = { class: "px-3 py-2" }, un = {
|
|
1934
1987
|
key: 3,
|
|
1935
1988
|
class: "sv-order-summary__items"
|
|
1936
|
-
},
|
|
1989
|
+
}, xt = /* @__PURE__ */ ce({
|
|
1937
1990
|
__name: "OrderSummary",
|
|
1938
1991
|
props: {
|
|
1939
1992
|
subscription: { type: Object },
|
|
@@ -1953,26 +2006,26 @@ const wo = { class: "grid grid-cols-1 gap-1" }, To = { class: "grid grid-cols-1
|
|
|
1953
2006
|
},
|
|
1954
2007
|
emits: ["billing-period-change"],
|
|
1955
2008
|
setup(e, { emit: i }) {
|
|
1956
|
-
const o = e, n = i, { $t: a } =
|
|
2009
|
+
const o = e, n = i, { $t: a } = ve(), { map: l, formatTimePeriod: c } = Lt(), { isMobileViewport: m } = St(), u = b(() => m.value ? "sm" : "xs"), N = (r) => `${r.type}:${r.value}`, v = ["DAY", "WEEK", "MONTH", "YEAR"], M = (r) => v.includes(r), A = (r) => {
|
|
1957
2010
|
if (!r)
|
|
1958
2011
|
return;
|
|
1959
|
-
const [
|
|
1960
|
-
if (!(!
|
|
1961
|
-
return { type:
|
|
1962
|
-
},
|
|
2012
|
+
const [g, h] = r.split(":"), w = Number(h);
|
|
2013
|
+
if (!(!w || !M(g)))
|
|
2014
|
+
return { type: g, value: w };
|
|
2015
|
+
}, d = b({
|
|
1963
2016
|
get: () => {
|
|
1964
2017
|
const r = o.subscription.billing_period;
|
|
1965
2018
|
return r ? `${r.type}:${r.value}` : void 0;
|
|
1966
2019
|
},
|
|
1967
2020
|
set: (r) => {
|
|
1968
2021
|
if (!r) return;
|
|
1969
|
-
const [
|
|
1970
|
-
|
|
2022
|
+
const [g, h] = r.split(":"), w = Number(h);
|
|
2023
|
+
w && M(g) && n("billing-period-change", { type: g, value: w });
|
|
1971
2024
|
}
|
|
1972
|
-
}),
|
|
1973
|
-
var
|
|
1974
|
-
const
|
|
1975
|
-
if (!
|
|
2025
|
+
}), L = (r) => {
|
|
2026
|
+
var w, j, H, Y;
|
|
2027
|
+
const g = (Y = (H = (j = (w = o.invoicePreviewByBillingPeriod) == null ? void 0 : w[N(r)]) == null ? void 0 : j.periods) == null ? void 0 : H[0]) == null ? void 0 : Y.amount_including_tax;
|
|
2028
|
+
if (!g)
|
|
1976
2029
|
return;
|
|
1977
2030
|
const h = r.type === "MONTH" && r.value === 3 ? a({
|
|
1978
2031
|
defaultMessage: "/quarter",
|
|
@@ -1985,7 +2038,7 @@ const wo = { class: "grid grid-cols-1 gap-1" }, To = { class: "grid grid-cols-1
|
|
|
1985
2038
|
description: "Period label for billing cycles"
|
|
1986
2039
|
},
|
|
1987
2040
|
{
|
|
1988
|
-
period:
|
|
2041
|
+
period: c(r, {
|
|
1989
2042
|
prefix: !1,
|
|
1990
2043
|
hideValueForExactPeriods: !0
|
|
1991
2044
|
})
|
|
@@ -1998,91 +2051,91 @@ const wo = { class: "grid grid-cols-1 gap-1" }, To = { class: "grid grid-cols-1
|
|
|
1998
2051
|
description: "Billing period option sublabel showing price per period"
|
|
1999
2052
|
},
|
|
2000
2053
|
{
|
|
2001
|
-
amount:
|
|
2054
|
+
amount: Ie(g),
|
|
2002
2055
|
period: h
|
|
2003
2056
|
}
|
|
2004
2057
|
);
|
|
2005
|
-
},
|
|
2006
|
-
var
|
|
2007
|
-
return (
|
|
2008
|
-
},
|
|
2009
|
-
if (!
|
|
2058
|
+
}, k = (r) => {
|
|
2059
|
+
var g, h, w, j;
|
|
2060
|
+
return (j = (w = (h = (g = o.invoicePreviewByBillingPeriod) == null ? void 0 : g[N(r)]) == null ? void 0 : h.periods) == null ? void 0 : w[0]) == null ? void 0 : j.amount_including_tax;
|
|
2061
|
+
}, p = (r) => Number(r.quantity), C = (r, g) => {
|
|
2062
|
+
if (!g)
|
|
2010
2063
|
return;
|
|
2011
|
-
const
|
|
2064
|
+
const w = {
|
|
2012
2065
|
DAY: 365,
|
|
2013
2066
|
WEEK: 52,
|
|
2014
2067
|
MONTH: 12,
|
|
2015
2068
|
YEAR: 1
|
|
2016
|
-
}[r.type] / Math.max(r.value ?? 1, 1),
|
|
2017
|
-
if (Number.isFinite(
|
|
2069
|
+
}[r.type] / Math.max(r.value ?? 1, 1), j = p(g) * w;
|
|
2070
|
+
if (Number.isFinite(j))
|
|
2018
2071
|
return {
|
|
2019
|
-
quantity:
|
|
2020
|
-
currency:
|
|
2072
|
+
quantity: j.toFixed(2),
|
|
2073
|
+
currency: g.currency
|
|
2021
2074
|
};
|
|
2022
|
-
},
|
|
2023
|
-
if (!r || !
|
|
2075
|
+
}, x = (r, g) => {
|
|
2076
|
+
if (!r || !g)
|
|
2024
2077
|
return;
|
|
2025
|
-
const h =
|
|
2078
|
+
const h = p(r) - p(g);
|
|
2026
2079
|
if (!(!Number.isFinite(h) || h <= 0))
|
|
2027
2080
|
return {
|
|
2028
2081
|
quantity: h.toFixed(2),
|
|
2029
2082
|
currency: r.currency
|
|
2030
2083
|
};
|
|
2031
|
-
},
|
|
2084
|
+
}, R = (r) => {
|
|
2032
2085
|
if (!r)
|
|
2033
2086
|
return;
|
|
2034
|
-
const
|
|
2087
|
+
const g = a(
|
|
2035
2088
|
{
|
|
2036
2089
|
defaultMessage: "Save {amount}",
|
|
2037
2090
|
id: "checkout.order_summary_block.billing_period.save_badge.prefix",
|
|
2038
2091
|
description: "First line for the savings badge label"
|
|
2039
2092
|
},
|
|
2040
|
-
{ amount:
|
|
2093
|
+
{ amount: Ie(r) }
|
|
2041
2094
|
), h = a({
|
|
2042
2095
|
defaultMessage: "/year",
|
|
2043
2096
|
id: "checkout.order_summary_block.billing_period.save_badge.suffix",
|
|
2044
2097
|
description: "Second line for the savings badge label"
|
|
2045
2098
|
});
|
|
2046
|
-
return `${
|
|
2047
|
-
},
|
|
2048
|
-
var
|
|
2049
|
-
const r =
|
|
2099
|
+
return `${g}${h}`;
|
|
2100
|
+
}, Q = b(() => {
|
|
2101
|
+
var Z, re, ne;
|
|
2102
|
+
const r = Ne({
|
|
2050
2103
|
pricingPlanScheduleInfos: o.subscription.pricing_plan_schedule_infos ?? [],
|
|
2051
2104
|
type: "DEFAULT"
|
|
2052
|
-
}),
|
|
2053
|
-
|
|
2054
|
-
},
|
|
2055
|
-
var
|
|
2056
|
-
(
|
|
2057
|
-
var
|
|
2058
|
-
(
|
|
2059
|
-
(
|
|
2060
|
-
), (
|
|
2061
|
-
var
|
|
2062
|
-
(
|
|
2063
|
-
(
|
|
2105
|
+
}), g = ((re = (Z = r == null ? void 0 : r.pricing_plan_version) == null ? void 0 : Z.billing_period_settings) == null ? void 0 : re.billing_periods) ?? [], h = /* @__PURE__ */ new Map(), w = ($) => {
|
|
2106
|
+
$ && h.set(N($), $);
|
|
2107
|
+
}, j = ($) => {
|
|
2108
|
+
var ie;
|
|
2109
|
+
(ie = $ == null ? void 0 : $.items) == null || ie.forEach((J) => {
|
|
2110
|
+
var ee, oe;
|
|
2111
|
+
(ee = J.billing_period_configs) == null || ee.forEach(
|
|
2112
|
+
(ue) => w(ue.billing_period)
|
|
2113
|
+
), (oe = J.pricing_currency_configs) == null || oe.forEach((ue) => {
|
|
2114
|
+
var de;
|
|
2115
|
+
(de = ue.billing_period_configs) == null || de.forEach(
|
|
2116
|
+
(pe) => w(pe.billing_period)
|
|
2064
2117
|
);
|
|
2065
2118
|
});
|
|
2066
2119
|
});
|
|
2067
2120
|
};
|
|
2068
|
-
if ((((
|
|
2069
|
-
var
|
|
2070
|
-
(
|
|
2071
|
-
(
|
|
2072
|
-
var
|
|
2073
|
-
return (
|
|
2121
|
+
if ((((ne = r == null ? void 0 : r.pricing_plan_version) == null ? void 0 : ne.pricing_categories) ?? []).forEach(($) => {
|
|
2122
|
+
var ie, J;
|
|
2123
|
+
(ie = $.pricings) == null || ie.forEach((ee) => j(ee)), (J = $.pricing_groups) == null || J.forEach(
|
|
2124
|
+
(ee) => {
|
|
2125
|
+
var oe;
|
|
2126
|
+
return (oe = ee.pricings) == null ? void 0 : oe.forEach((ue) => j(ue));
|
|
2074
2127
|
}
|
|
2075
2128
|
);
|
|
2076
2129
|
}), !h.size)
|
|
2077
2130
|
return [];
|
|
2078
|
-
const
|
|
2079
|
-
(
|
|
2131
|
+
const Y = g.map(($) => h.get(N($.period))).filter(($) => !!$), G = new Set(Y.map(N)), ae = [...h.values()].filter(
|
|
2132
|
+
($) => !G.has(N($))
|
|
2080
2133
|
);
|
|
2081
|
-
return [
|
|
2082
|
-
}),
|
|
2083
|
-
const r =
|
|
2084
|
-
return
|
|
2085
|
-
const
|
|
2134
|
+
return [...Y, ...ae];
|
|
2135
|
+
}), s = b(() => {
|
|
2136
|
+
const r = Q.value[Q.value.length - 1], g = r ? C(r, k(r)) : void 0;
|
|
2137
|
+
return Q.value.map((w) => {
|
|
2138
|
+
const j = w.type === "MONTH" && w.value === 3 ? a({
|
|
2086
2139
|
defaultMessage: "Billed quarterly",
|
|
2087
2140
|
id: "checkout.order_summary_block.billing_period.quarterly",
|
|
2088
2141
|
description: "Billing period option label for quarterly billing"
|
|
@@ -2092,52 +2145,52 @@ const wo = { class: "grid grid-cols-1 gap-1" }, To = { class: "grid grid-cols-1
|
|
|
2092
2145
|
id: "checkout.order_summary_block.billing_period.label",
|
|
2093
2146
|
description: "Billing period option label for the selected period"
|
|
2094
2147
|
},
|
|
2095
|
-
{ period: l.value[
|
|
2096
|
-
), H =
|
|
2148
|
+
{ period: l.value[w.type].full }
|
|
2149
|
+
), H = k(w), Y = C(w, H), G = r && w.type === r.type && w.value === r.value ? void 0 : x(Y, g), ae = R(G);
|
|
2097
2150
|
return {
|
|
2098
|
-
label:
|
|
2099
|
-
subLabel:
|
|
2100
|
-
labelSuffixComponent:
|
|
2101
|
-
component:
|
|
2151
|
+
label: j,
|
|
2152
|
+
subLabel: L(w),
|
|
2153
|
+
labelSuffixComponent: ae ? {
|
|
2154
|
+
component: At,
|
|
2102
2155
|
props: {
|
|
2103
2156
|
color: "primary",
|
|
2104
|
-
content:
|
|
2105
|
-
size:
|
|
2157
|
+
content: ae,
|
|
2158
|
+
size: u.value,
|
|
2106
2159
|
class: "whitespace-nowrap text-left leading-tight"
|
|
2107
2160
|
}
|
|
2108
2161
|
} : void 0,
|
|
2109
|
-
hidden:
|
|
2110
|
-
value: `${
|
|
2162
|
+
hidden: d.value === `${w.type}:${w.value}`,
|
|
2163
|
+
value: `${w.type}:${w.value}`
|
|
2111
2164
|
};
|
|
2112
2165
|
});
|
|
2113
|
-
}),
|
|
2114
|
-
const r =
|
|
2166
|
+
}), P = b(() => {
|
|
2167
|
+
const r = s.value, g = r[0], h = r[r.length - 1];
|
|
2115
2168
|
return {
|
|
2116
|
-
smallestPeriod:
|
|
2169
|
+
smallestPeriod: g == null ? void 0 : g.value,
|
|
2117
2170
|
biggestPeriod: h == null ? void 0 : h.value
|
|
2118
2171
|
};
|
|
2119
|
-
}),
|
|
2120
|
-
() =>
|
|
2172
|
+
}), q = b(
|
|
2173
|
+
() => s.value.find((r) => r.value === P.value.biggestPeriod)
|
|
2121
2174
|
), te = b(
|
|
2122
|
-
() =>
|
|
2123
|
-
),
|
|
2124
|
-
var
|
|
2125
|
-
const r =
|
|
2126
|
-
if (!
|
|
2175
|
+
() => s.value.find((r) => r.value === d.value)
|
|
2176
|
+
), f = b(() => {
|
|
2177
|
+
var Z, re, ne, $, ie, J, ee, oe;
|
|
2178
|
+
const r = s.value, g = r[r.length - 1], h = d.value;
|
|
2179
|
+
if (!g || !h || h === g.value)
|
|
2127
2180
|
return "";
|
|
2128
|
-
const
|
|
2129
|
-
if (!
|
|
2181
|
+
const w = A(g.value);
|
|
2182
|
+
if (!w)
|
|
2130
2183
|
return "";
|
|
2131
|
-
const
|
|
2132
|
-
if (!H ||
|
|
2184
|
+
const j = ($ = (ne = (re = (Z = o.invoicePreviewByBillingPeriod) == null ? void 0 : Z[g.value]) == null ? void 0 : re.periods) == null ? void 0 : ne[0]) == null ? void 0 : $.amount_including_tax, H = A(h), Y = (oe = (ee = (J = (ie = o.invoicePreviewByBillingPeriod) == null ? void 0 : ie[h]) == null ? void 0 : J.periods) == null ? void 0 : ee[0]) == null ? void 0 : oe.amount_including_tax;
|
|
2185
|
+
if (!H || !Y)
|
|
2133
2186
|
return "";
|
|
2134
|
-
const
|
|
2135
|
-
return
|
|
2136
|
-
}),
|
|
2137
|
-
const { smallestPeriod:
|
|
2138
|
-
|
|
2187
|
+
const G = C(H, Y), ae = C(w, j);
|
|
2188
|
+
return R(x(G, ae)) ?? "";
|
|
2189
|
+
}), y = (r) => {
|
|
2190
|
+
const { smallestPeriod: g, biggestPeriod: h } = P.value;
|
|
2191
|
+
d.value = r ? h : g;
|
|
2139
2192
|
};
|
|
2140
|
-
return (r,
|
|
2193
|
+
return (r, g) => (_(), O(t(ge), {
|
|
2141
2194
|
class: "sv-order-summary",
|
|
2142
2195
|
"no-border": "",
|
|
2143
2196
|
"no-spacing": "",
|
|
@@ -2149,13 +2202,13 @@ const wo = { class: "grid grid-cols-1 gap-1" }, To = { class: "grid grid-cols-1
|
|
|
2149
2202
|
})
|
|
2150
2203
|
}, {
|
|
2151
2204
|
default: I(() => [
|
|
2152
|
-
|
|
2153
|
-
|
|
2205
|
+
T("div", rn, [
|
|
2206
|
+
E(t(ge), {
|
|
2154
2207
|
"no-spacing": "",
|
|
2155
2208
|
class: "sv-order-summary__subscription"
|
|
2156
2209
|
}, {
|
|
2157
2210
|
default: I(() => [
|
|
2158
|
-
e.subscription ? (
|
|
2211
|
+
e.subscription ? (_(), O(Fi, {
|
|
2159
2212
|
key: 0,
|
|
2160
2213
|
avatar: e.avatar,
|
|
2161
2214
|
invoice: e.invoice,
|
|
@@ -2167,36 +2220,36 @@ const wo = { class: "grid grid-cols-1 gap-1" }, To = { class: "grid grid-cols-1
|
|
|
2167
2220
|
]),
|
|
2168
2221
|
_: 1
|
|
2169
2222
|
}),
|
|
2170
|
-
|
|
2223
|
+
s.value.length === 2 ? (_(), O(t(ge), {
|
|
2171
2224
|
key: 0,
|
|
2172
2225
|
"no-spacing": "",
|
|
2173
|
-
"content-classes":
|
|
2226
|
+
"content-classes": d.value === P.value.biggestPeriod ? "border-primary-500" : void 0
|
|
2174
2227
|
}, {
|
|
2175
2228
|
default: I(() => {
|
|
2176
2229
|
var h;
|
|
2177
2230
|
return [
|
|
2178
|
-
|
|
2179
|
-
|
|
2180
|
-
|
|
2231
|
+
T("div", ln, [
|
|
2232
|
+
T("div", sn, [
|
|
2233
|
+
q.value ? (_(), O(an, {
|
|
2181
2234
|
key: 0,
|
|
2182
|
-
name:
|
|
2235
|
+
name: q.value.label,
|
|
2183
2236
|
description: ((h = te.value) == null ? void 0 : h.subLabel) ?? ""
|
|
2184
|
-
},
|
|
2237
|
+
}, Je({
|
|
2185
2238
|
default: I(() => [
|
|
2186
|
-
|
|
2187
|
-
"model-value":
|
|
2188
|
-
"onUpdate:modelValue":
|
|
2239
|
+
E(t(vi), {
|
|
2240
|
+
"model-value": d.value === P.value.biggestPeriod,
|
|
2241
|
+
"onUpdate:modelValue": y
|
|
2189
2242
|
}, null, 8, ["model-value"])
|
|
2190
2243
|
]),
|
|
2191
2244
|
_: 2
|
|
2192
2245
|
}, [
|
|
2193
|
-
|
|
2246
|
+
f.value ? {
|
|
2194
2247
|
name: "badge",
|
|
2195
2248
|
fn: I(() => [
|
|
2196
|
-
|
|
2249
|
+
E(t(At), {
|
|
2197
2250
|
intent: "brand",
|
|
2198
|
-
content:
|
|
2199
|
-
size:
|
|
2251
|
+
content: f.value,
|
|
2252
|
+
size: u.value,
|
|
2200
2253
|
class: "whitespace-nowrap text-left leading-tight"
|
|
2201
2254
|
}, null, 8, ["content", "size"])
|
|
2202
2255
|
]),
|
|
@@ -2208,31 +2261,31 @@ const wo = { class: "grid grid-cols-1 gap-1" }, To = { class: "grid grid-cols-1
|
|
|
2208
2261
|
];
|
|
2209
2262
|
}),
|
|
2210
2263
|
_: 1
|
|
2211
|
-
}, 8, ["content-classes"])) :
|
|
2264
|
+
}, 8, ["content-classes"])) : s.value.length > 2 ? (_(), O(t(Ui), {
|
|
2212
2265
|
key: 1,
|
|
2213
|
-
"single-model-value":
|
|
2214
|
-
"onUpdate:singleModelValue":
|
|
2266
|
+
"single-model-value": d.value,
|
|
2267
|
+
"onUpdate:singleModelValue": g[0] || (g[0] = (h) => d.value = h),
|
|
2215
2268
|
class: "sv-order-summary__billing-period",
|
|
2216
|
-
options:
|
|
2269
|
+
options: s.value,
|
|
2217
2270
|
size: "xl",
|
|
2218
2271
|
"has-large-dropdown": "",
|
|
2219
2272
|
"show-sub-label-in-input": "",
|
|
2220
2273
|
"show-suffix-in-closed-input": ""
|
|
2221
2274
|
}, null, 8, ["single-model-value", "options"])) : B("", !0),
|
|
2222
|
-
e.isUsageBased ? (
|
|
2275
|
+
e.isUsageBased ? (_(), O(t(ge), {
|
|
2223
2276
|
key: 2,
|
|
2224
2277
|
"no-spacing": "",
|
|
2225
2278
|
class: "sv-order-summary__usage"
|
|
2226
2279
|
}, {
|
|
2227
2280
|
default: I(() => [
|
|
2228
|
-
|
|
2229
|
-
|
|
2281
|
+
T("div", cn, [
|
|
2282
|
+
E(t(se), {
|
|
2230
2283
|
"no-spacing": "",
|
|
2231
2284
|
variant: "body-sm",
|
|
2232
2285
|
color: "subtle"
|
|
2233
2286
|
}, {
|
|
2234
2287
|
default: I(() => [
|
|
2235
|
-
|
|
2288
|
+
F(U(t(a)({
|
|
2236
2289
|
defaultMessage: "+ Usage",
|
|
2237
2290
|
id: "checkout.invoice_preview.usage_based_message",
|
|
2238
2291
|
description: "The message shown for the usage based invoice preview"
|
|
@@ -2244,15 +2297,15 @@ const wo = { class: "grid grid-cols-1 gap-1" }, To = { class: "grid grid-cols-1
|
|
|
2244
2297
|
]),
|
|
2245
2298
|
_: 1
|
|
2246
2299
|
})) : B("", !0),
|
|
2247
|
-
e.invoice && e.variant !== "products-inline" ? (
|
|
2248
|
-
|
|
2300
|
+
e.invoice && e.variant !== "products-inline" ? (_(), W("div", un, [
|
|
2301
|
+
E(t(ki), {
|
|
2249
2302
|
invoice: e.invoice,
|
|
2250
|
-
"wrapper-component": t(
|
|
2303
|
+
"wrapper-component": t(ge)
|
|
2251
2304
|
}, null, 8, ["invoice", "wrapper-component"])
|
|
2252
2305
|
])) : B("", !0),
|
|
2253
|
-
|
|
2306
|
+
E(t(ge), { class: "sv-order-summary__totals" }, {
|
|
2254
2307
|
default: I(() => [
|
|
2255
|
-
e.invoice ? (
|
|
2308
|
+
e.invoice ? (_(), O(t(zi), {
|
|
2256
2309
|
key: 0,
|
|
2257
2310
|
class: "sv-order-summary__invoice-preview",
|
|
2258
2311
|
variant: e.variant === "products-inline" ? "default" : "without-products",
|
|
@@ -2262,14 +2315,14 @@ const wo = { class: "grid grid-cols-1 gap-1" }, To = { class: "grid grid-cols-1
|
|
|
2262
2315
|
collapsible: e.collapsible,
|
|
2263
2316
|
"is-preview-without-taxes": !e.countryCode,
|
|
2264
2317
|
"is-customer-facing": ""
|
|
2265
|
-
}, null, 8, ["variant", "invoice", "trial-invoice", "is-paid", "collapsible", "is-preview-without-taxes"])) : (
|
|
2318
|
+
}, null, 8, ["variant", "invoice", "trial-invoice", "is-paid", "collapsible", "is-preview-without-taxes"])) : (_(), O(t(se), {
|
|
2266
2319
|
key: 1,
|
|
2267
2320
|
variant: "body-sm",
|
|
2268
2321
|
color: "subtle",
|
|
2269
2322
|
class: "sv-order-summary__empty"
|
|
2270
2323
|
}, {
|
|
2271
2324
|
default: I(() => [
|
|
2272
|
-
|
|
2325
|
+
F(U(t(a)({
|
|
2273
2326
|
defaultMessage: "Please select a country first",
|
|
2274
2327
|
description: "The message shown for the invoice preview when no country is set",
|
|
2275
2328
|
id: "checkout.invoice_preview.no_country_selected_message"
|
|
@@ -2286,10 +2339,10 @@ const wo = { class: "grid grid-cols-1 gap-1" }, To = { class: "grid grid-cols-1
|
|
|
2286
2339
|
}, 8, ["title"]));
|
|
2287
2340
|
}
|
|
2288
2341
|
});
|
|
2289
|
-
async function
|
|
2290
|
-
const { AdyenCheckout: o } = await
|
|
2342
|
+
async function Ft(e, i) {
|
|
2343
|
+
const { AdyenCheckout: o } = await Ve();
|
|
2291
2344
|
return o(
|
|
2292
|
-
|
|
2345
|
+
Ci({
|
|
2293
2346
|
locale: e.locale,
|
|
2294
2347
|
amount: e.amount,
|
|
2295
2348
|
countryCode: e.countryCode,
|
|
@@ -2298,40 +2351,40 @@ async function Bt(e, i) {
|
|
|
2298
2351
|
})
|
|
2299
2352
|
);
|
|
2300
2353
|
}
|
|
2301
|
-
function
|
|
2354
|
+
function Gt({
|
|
2302
2355
|
props: e,
|
|
2303
2356
|
create: i,
|
|
2304
2357
|
onMissingButton: o,
|
|
2305
2358
|
onMountFailed: n,
|
|
2306
2359
|
afterMount: a
|
|
2307
2360
|
}) {
|
|
2308
|
-
const l = V(),
|
|
2309
|
-
const
|
|
2361
|
+
const l = V(), c = Me(), m = async () => {
|
|
2362
|
+
const u = await Ft(e, c), N = await i(u);
|
|
2310
2363
|
if (!l.value) {
|
|
2311
2364
|
o();
|
|
2312
2365
|
return;
|
|
2313
2366
|
}
|
|
2314
2367
|
try {
|
|
2315
|
-
await
|
|
2316
|
-
} catch (
|
|
2317
|
-
n(
|
|
2368
|
+
await N.isAvailable(), N.mount(l.value), a == null || a();
|
|
2369
|
+
} catch (v) {
|
|
2370
|
+
n(v);
|
|
2318
2371
|
}
|
|
2319
2372
|
};
|
|
2320
|
-
return
|
|
2321
|
-
|
|
2373
|
+
return Oe(() => {
|
|
2374
|
+
m();
|
|
2322
2375
|
}), { buttonRef: l };
|
|
2323
2376
|
}
|
|
2324
|
-
const
|
|
2377
|
+
const dn = {
|
|
2325
2378
|
key: 0,
|
|
2326
2379
|
id: "svg-logo",
|
|
2327
2380
|
viewBox: "0 0 35 15",
|
|
2328
2381
|
class: "h-[44px]"
|
|
2329
|
-
},
|
|
2382
|
+
}, pn = {
|
|
2330
2383
|
key: 1,
|
|
2331
2384
|
src: "data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTAxcHgiIGhlaWdodD0iMzIiIHZpZXdCb3g9IjAgMCAxMDEgMzIiIHByZXNlcnZlQXNwZWN0UmF0aW89InhNaW5ZTWluIG1lZXQiIHhtbG5zPSJodHRwOiYjeDJGOyYjeDJGO3d3dy53My5vcmcmI3gyRjsyMDAwJiN4MkY7c3ZnIj48cGF0aCBmaWxsPSIjMDAzMDg3IiBkPSJNIDEyLjIzNyAyLjggTCA0LjQzNyAyLjggQyAzLjkzNyAyLjggMy40MzcgMy4yIDMuMzM3IDMuNyBMIDAuMjM3IDIzLjcgQyAwLjEzNyAyNC4xIDAuNDM3IDI0LjQgMC44MzcgMjQuNCBMIDQuNTM3IDI0LjQgQyA1LjAzNyAyNC40IDUuNTM3IDI0IDUuNjM3IDIzLjUgTCA2LjQzNyAxOC4xIEMgNi41MzcgMTcuNiA2LjkzNyAxNy4yIDcuNTM3IDE3LjIgTCAxMC4wMzcgMTcuMiBDIDE1LjEzNyAxNy4yIDE4LjEzNyAxNC43IDE4LjkzNyA5LjggQyAxOS4yMzcgNy43IDE4LjkzNyA2IDE3LjkzNyA0LjggQyAxNi44MzcgMy41IDE0LjgzNyAyLjggMTIuMjM3IDIuOCBaIE0gMTMuMTM3IDEwLjEgQyAxMi43MzcgMTIuOSAxMC41MzcgMTIuOSA4LjUzNyAxMi45IEwgNy4zMzcgMTIuOSBMIDguMTM3IDcuNyBDIDguMTM3IDcuNCA4LjQzNyA3LjIgOC43MzcgNy4yIEwgOS4yMzcgNy4yIEMgMTAuNjM3IDcuMiAxMS45MzcgNy4yIDEyLjYzNyA4IEMgMTMuMTM3IDguNCAxMy4zMzcgOS4xIDEzLjEzNyAxMC4xIFoiPjwvcGF0aD48cGF0aCBmaWxsPSIjMDAzMDg3IiBkPSJNIDM1LjQzNyAxMCBMIDMxLjczNyAxMCBDIDMxLjQzNyAxMCAzMS4xMzcgMTAuMiAzMS4xMzcgMTAuNSBMIDMwLjkzNyAxMS41IEwgMzAuNjM3IDExLjEgQyAyOS44MzcgOS45IDI4LjAzNyA5LjUgMjYuMjM3IDkuNSBDIDIyLjEzNyA5LjUgMTguNjM3IDEyLjYgMTcuOTM3IDE3IEMgMTcuNTM3IDE5LjIgMTguMDM3IDIxLjMgMTkuMzM3IDIyLjcgQyAyMC40MzcgMjQgMjIuMTM3IDI0LjYgMjQuMDM3IDI0LjYgQyAyNy4zMzcgMjQuNiAyOS4yMzcgMjIuNSAyOS4yMzcgMjIuNSBMIDI5LjAzNyAyMy41IEMgMjguOTM3IDIzLjkgMjkuMjM3IDI0LjMgMjkuNjM3IDI0LjMgTCAzMy4wMzcgMjQuMyBDIDMzLjUzNyAyNC4zIDM0LjAzNyAyMy45IDM0LjEzNyAyMy40IEwgMzYuMTM3IDEwLjYgQyAzNi4yMzcgMTAuNCAzNS44MzcgMTAgMzUuNDM3IDEwIFogTSAzMC4zMzcgMTcuMiBDIDI5LjkzNyAxOS4zIDI4LjMzNyAyMC44IDI2LjEzNyAyMC44IEMgMjUuMDM3IDIwLjggMjQuMjM3IDIwLjUgMjMuNjM3IDE5LjggQyAyMy4wMzcgMTkuMSAyMi44MzcgMTguMiAyMy4wMzcgMTcuMiBDIDIzLjMzNyAxNS4xIDI1LjEzNyAxMy42IDI3LjIzNyAxMy42IEMgMjguMzM3IDEzLjYgMjkuMTM3IDE0IDI5LjczNyAxNC42IEMgMzAuMjM3IDE1LjMgMzAuNDM3IDE2LjIgMzAuMzM3IDE3LjIgWiI+PC9wYXRoPjxwYXRoIGZpbGw9IiMwMDMwODciIGQ9Ik0gNTUuMzM3IDEwIEwgNTEuNjM3IDEwIEMgNTEuMjM3IDEwIDUwLjkzNyAxMC4yIDUwLjczNyAxMC41IEwgNDUuNTM3IDE4LjEgTCA0My4zMzcgMTAuOCBDIDQzLjIzNyAxMC4zIDQyLjczNyAxMCA0Mi4zMzcgMTAgTCAzOC42MzcgMTAgQyAzOC4yMzcgMTAgMzcuODM3IDEwLjQgMzguMDM3IDEwLjkgTCA0Mi4xMzcgMjMgTCAzOC4yMzcgMjguNCBDIDM3LjkzNyAyOC44IDM4LjIzNyAyOS40IDM4LjczNyAyOS40IEwgNDIuNDM3IDI5LjQgQyA0Mi44MzcgMjkuNCA0My4xMzcgMjkuMiA0My4zMzcgMjguOSBMIDU1LjgzNyAxMC45IEMgNTYuMTM3IDEwLjYgNTUuODM3IDEwIDU1LjMzNyAxMCBaIj48L3BhdGg+PHBhdGggZmlsbD0iIzAwOWNkZSIgZD0iTSA2Ny43MzcgMi44IEwgNTkuOTM3IDIuOCBDIDU5LjQzNyAyLjggNTguOTM3IDMuMiA1OC44MzcgMy43IEwgNTUuNzM3IDIzLjYgQyA1NS42MzcgMjQgNTUuOTM3IDI0LjMgNTYuMzM3IDI0LjMgTCA2MC4zMzcgMjQuMyBDIDYwLjczNyAyNC4zIDYxLjAzNyAyNCA2MS4wMzcgMjMuNyBMIDYxLjkzNyAxOCBDIDYyLjAzNyAxNy41IDYyLjQzNyAxNy4xIDYzLjAzNyAxNy4xIEwgNjUuNTM3IDE3LjEgQyA3MC42MzcgMTcuMSA3My42MzcgMTQuNiA3NC40MzcgOS43IEMgNzQuNzM3IDcuNiA3NC40MzcgNS45IDczLjQzNyA0LjcgQyA3Mi4yMzcgMy41IDcwLjMzNyAyLjggNjcuNzM3IDIuOCBaIE0gNjguNjM3IDEwLjEgQyA2OC4yMzcgMTIuOSA2Ni4wMzcgMTIuOSA2NC4wMzcgMTIuOSBMIDYyLjgzNyAxMi45IEwgNjMuNjM3IDcuNyBDIDYzLjYzNyA3LjQgNjMuOTM3IDcuMiA2NC4yMzcgNy4yIEwgNjQuNzM3IDcuMiBDIDY2LjEzNyA3LjIgNjcuNDM3IDcuMiA2OC4xMzcgOCBDIDY4LjYzNyA4LjQgNjguNzM3IDkuMSA2OC42MzcgMTAuMSBaIj48L3BhdGg+PHBhdGggZmlsbD0iIzAwOWNkZSIgZD0iTSA5MC45MzcgMTAgTCA4Ny4yMzcgMTAgQyA4Ni45MzcgMTAgODYuNjM3IDEwLjIgODYuNjM3IDEwLjUgTCA4Ni40MzcgMTEuNSBMIDg2LjEzNyAxMS4xIEMgODUuMzM3IDkuOSA4My41MzcgOS41IDgxLjczNyA5LjUgQyA3Ny42MzcgOS41IDc0LjEzNyAxMi42IDczLjQzNyAxNyBDIDczLjAzNyAxOS4yIDczLjUzNyAyMS4zIDc0LjgzNyAyMi43IEMgNzUuOTM3IDI0IDc3LjYzNyAyNC42IDc5LjUzNyAyNC42IEMgODIuODM3IDI0LjYgODQuNzM3IDIyLjUgODQuNzM3IDIyLjUgTCA4NC41MzcgMjMuNSBDIDg0LjQzNyAyMy45IDg0LjczNyAyNC4zIDg1LjEzNyAyNC4zIEwgODguNTM3IDI0LjMgQyA4OS4wMzcgMjQuMyA4OS41MzcgMjMuOSA4OS42MzcgMjMuNCBMIDkxLjYzNyAxMC42IEMgOTEuNjM3IDEwLjQgOTEuMzM3IDEwIDkwLjkzNyAxMCBaIE0gODUuNzM3IDE3LjIgQyA4NS4zMzcgMTkuMyA4My43MzcgMjAuOCA4MS41MzcgMjAuOCBDIDgwLjQzNyAyMC44IDc5LjYzNyAyMC41IDc5LjAzNyAxOS44IEMgNzguNDM3IDE5LjEgNzguMjM3IDE4LjIgNzguNDM3IDE3LjIgQyA3OC43MzcgMTUuMSA4MC41MzcgMTMuNiA4Mi42MzcgMTMuNiBDIDgzLjczNyAxMy42IDg0LjUzNyAxNCA4NS4xMzcgMTQuNiBDIDg1LjczNyAxNS4zIDg1LjkzNyAxNi4yIDg1LjczNyAxNy4yIFoiPjwvcGF0aD48cGF0aCBmaWxsPSIjMDA5Y2RlIiBkPSJNIDk1LjMzNyAzLjMgTCA5Mi4xMzcgMjMuNiBDIDkyLjAzNyAyNCA5Mi4zMzcgMjQuMyA5Mi43MzcgMjQuMyBMIDk1LjkzNyAyNC4zIEMgOTYuNDM3IDI0LjMgOTYuOTM3IDIzLjkgOTcuMDM3IDIzLjQgTCAxMDAuMjM3IDMuNSBDIDEwMC4zMzcgMy4xIDEwMC4wMzcgMi44IDk5LjYzNyAyLjggTCA5Ni4wMzcgMi44IEMgOTUuNjM3IDIuOCA5NS40MzcgMyA5NS4zMzcgMy4zIFoiPjwvcGF0aD48L3N2Zz4",
|
|
2332
2385
|
role: "presentation",
|
|
2333
2386
|
class: "h-[22px]"
|
|
2334
|
-
},
|
|
2387
|
+
}, it = /* @__PURE__ */ ce({
|
|
2335
2388
|
__name: "ExpressPaymentMethodButton",
|
|
2336
2389
|
props: {
|
|
2337
2390
|
type: { type: String }
|
|
@@ -2361,18 +2414,18 @@ const rn = {
|
|
|
2361
2414
|
return;
|
|
2362
2415
|
}
|
|
2363
2416
|
});
|
|
2364
|
-
function
|
|
2417
|
+
function c() {
|
|
2365
2418
|
n("click");
|
|
2366
2419
|
}
|
|
2367
|
-
return (
|
|
2420
|
+
return (m, u) => (_(), O(t(Ae), {
|
|
2368
2421
|
size: "lg",
|
|
2369
2422
|
"aria-label": a.value,
|
|
2370
|
-
class:
|
|
2371
|
-
onClick:
|
|
2423
|
+
class: be([l.value, "!block h-11 w-full bg-center bg-no-repeat"]),
|
|
2424
|
+
onClick: c
|
|
2372
2425
|
}, {
|
|
2373
2426
|
default: I(() => [
|
|
2374
|
-
o.type === "applepay" ? (
|
|
2375
|
-
|
|
2427
|
+
o.type === "applepay" ? (_(), W("svg", dn, [...u[0] || (u[0] = [
|
|
2428
|
+
T("svg", {
|
|
2376
2429
|
id: "svg-logo",
|
|
2377
2430
|
x: "0",
|
|
2378
2431
|
y: "3.85",
|
|
@@ -2383,28 +2436,28 @@ const rn = {
|
|
|
2383
2436
|
version: "1.1",
|
|
2384
2437
|
xmlns: "http://www.w3.org/2000/svg"
|
|
2385
2438
|
}, [
|
|
2386
|
-
|
|
2387
|
-
|
|
2439
|
+
T("title", null, "Apple Logo"),
|
|
2440
|
+
T("g", {
|
|
2388
2441
|
stroke: "none",
|
|
2389
2442
|
"stroke-width": "1",
|
|
2390
2443
|
fill: "none",
|
|
2391
2444
|
"fill-rule": "evenodd"
|
|
2392
2445
|
}, [
|
|
2393
|
-
|
|
2394
|
-
|
|
2395
|
-
|
|
2396
|
-
|
|
2397
|
-
|
|
2398
|
-
|
|
2446
|
+
T("g", { fill: "#FFF" }, [
|
|
2447
|
+
T("path", { d: "M19.4028,5.5674 C20.6008,4.0684 21.4138,2.0564 21.1998,0.0004 C19.4458,0.0874 17.3058,1.1574 16.0668,2.6564 C14.9538,3.9414 13.9688,6.0374 14.2258,8.0074 C16.1948,8.1784 18.1618,7.0244 19.4028,5.5674" }),
|
|
2448
|
+
T("path", { d: "M21.1772,8.3926 C18.3182,8.2226 15.8872,10.0156 14.5212,10.0156 C13.1552,10.0156 11.0642,8.4786 8.8022,8.5196 C5.8592,8.5626 3.1282,10.2276 1.6342,12.8746 C-1.4378,18.1696 0.8232,26.0246 3.8112,30.3376 C5.2622,32.4716 7.0102,34.8206 9.3142,34.7366 C11.4912,34.6506 12.3442,33.3266 14.9902,33.3266 C17.6352,33.3266 18.4042,34.7366 20.7082,34.6936 C23.0972,34.6506 24.5922,32.5586 26.0422,30.4226 C27.7072,27.9906 28.3882,25.6426 28.4312,25.5126 C28.3882,25.4706 23.8232,23.7186 23.7812,18.4676 C23.7382,14.0706 27.3652,11.9786 27.5362,11.8496 C25.4882,8.8196 22.2872,8.4786 21.1772,8.3926" }),
|
|
2449
|
+
T("path", { d: "M85.5508,43.0381 L85.5508,39.1991 C85.8628,39.2421 86.6158,39.2871 87.0158,39.2871 C89.2138,39.2871 90.4558,38.3551 91.2108,35.9581 L91.6548,34.5371 L83.2428,11.2321 L88.4368,11.2321 L94.2958,30.1421 L94.4068,30.1421 L100.2668,11.2321 L105.3278,11.2321 L96.6048,35.7141 C94.6078,41.3291 92.3208,43.1721 87.4828,43.1721 C87.1048,43.1721 85.8838,43.1271 85.5508,43.0381" }),
|
|
2450
|
+
T("path", { d: "M42.6499,19.3555 L48.3549,19.3555 C52.6829,19.3555 55.1469,17.0255 55.1469,12.9855 C55.1469,8.9455 52.6829,6.6375 48.3769,6.6375 L42.6499,6.6375 L42.6499,19.3555 Z M49.6869,2.4425 C55.9009,2.4425 60.2289,6.7265 60.2289,12.9625 C60.2289,19.2225 55.8129,23.5285 49.5309,23.5285 L42.6499,23.5285 L42.6499,34.4705 L37.6779,34.4705 L37.6779,2.4425 L49.6869,2.4425 Z" }),
|
|
2451
|
+
T("path", { d: "M76.5547,25.7705 L76.5547,23.9715 L71.0287,24.3275 C67.9207,24.5275 66.3007,25.6815 66.3007,27.7015 C66.3007,29.6545 67.9887,30.9195 70.6287,30.9195 C74.0027,30.9195 76.5547,28.7665 76.5547,25.7705 M61.4617,27.8345 C61.4617,23.7285 64.5917,21.3755 70.3627,21.0205 L76.5547,20.6425 L76.5547,18.8675 C76.5547,16.2705 74.8457,14.8495 71.8057,14.8495 C69.2967,14.8495 67.4777,16.1375 67.0997,18.1125 L62.6167,18.1125 C62.7497,13.9615 66.6567,10.9435 71.9387,10.9435 C77.6207,10.9435 81.3267,13.9175 81.3267,18.5345 L81.3267,34.4705 L76.7327,34.4705 L76.7327,30.6305 L76.6217,30.6305 C75.3127,33.1395 72.4267,34.7145 69.2967,34.7145 C64.6807,34.7145 61.4617,31.9625 61.4617,27.8345" })
|
|
2399
2452
|
])
|
|
2400
2453
|
])
|
|
2401
2454
|
], -1)
|
|
2402
|
-
])])) : o.type === "paypal" ? (
|
|
2455
|
+
])])) : o.type === "paypal" ? (_(), W("img", pn)) : B("", !0)
|
|
2403
2456
|
]),
|
|
2404
2457
|
_: 1
|
|
2405
2458
|
}, 8, ["aria-label", "class"]));
|
|
2406
2459
|
}
|
|
2407
|
-
}),
|
|
2460
|
+
}), mn = { class: "absolute h-[1px] w-[1px] overflow-hidden opacity-0" }, gn = "ADYEN", yn = /* @__PURE__ */ ce({
|
|
2408
2461
|
__name: "ExpressPaymentMethodApplePay",
|
|
2409
2462
|
props: {
|
|
2410
2463
|
onBillingInformationChange: { type: Function },
|
|
@@ -2417,8 +2470,17 @@ const rn = {
|
|
|
2417
2470
|
},
|
|
2418
2471
|
emits: ["ready", "update-billing-information"],
|
|
2419
2472
|
setup(e, { emit: i }) {
|
|
2420
|
-
const o = e, n = i, a = V(), l =
|
|
2421
|
-
|
|
2473
|
+
const o = e, n = i, a = V(), l = Me(), { authorizePayment: c } = Yi(), m = o.paymentMethodOptionsResponse.payment_acceptor.id;
|
|
2474
|
+
function u(p) {
|
|
2475
|
+
return Ki({
|
|
2476
|
+
gateway: "ADYEN",
|
|
2477
|
+
paymentAcceptorId: m,
|
|
2478
|
+
paymentMethodType: "applepay",
|
|
2479
|
+
...p
|
|
2480
|
+
});
|
|
2481
|
+
}
|
|
2482
|
+
const N = async () => {
|
|
2483
|
+
const { ApplePay: p } = await Ve(), C = await Ft(o, l), x = new p(C, {
|
|
2422
2484
|
isExpress: !0,
|
|
2423
2485
|
recurringPaymentRequest: {
|
|
2424
2486
|
paymentDescription: o.billingInformation.description,
|
|
@@ -2443,7 +2505,7 @@ const rn = {
|
|
|
2443
2505
|
type: "final",
|
|
2444
2506
|
paymentTiming: "recurring",
|
|
2445
2507
|
recurringPaymentStartDate: o.billingInformation.regular.startDate,
|
|
2446
|
-
...
|
|
2508
|
+
...v(
|
|
2447
2509
|
o.billingInformation.regular.interval ?? { type: "MONTH", value: 1 }
|
|
2448
2510
|
)
|
|
2449
2511
|
}
|
|
@@ -2451,100 +2513,111 @@ const rn = {
|
|
|
2451
2513
|
},
|
|
2452
2514
|
requiredBillingContactFields: ["postalAddress"],
|
|
2453
2515
|
requiredShippingContactFields: ["email"],
|
|
2454
|
-
onPaymentMethodSelected: async (
|
|
2455
|
-
var
|
|
2456
|
-
const { invoicePreview:
|
|
2457
|
-
...((
|
|
2458
|
-
postal_code:
|
|
2516
|
+
onPaymentMethodSelected: async (R, Q, s) => {
|
|
2517
|
+
var f, y, r, g, h, w, j;
|
|
2518
|
+
const { invoicePreview: P, trialInvoicePreview: q } = await o.onBillingInformationChange({
|
|
2519
|
+
...((f = s.paymentMethod.billingContact) == null ? void 0 : f.postalCode) && {
|
|
2520
|
+
postal_code: s.paymentMethod.billingContact.postalCode
|
|
2459
2521
|
},
|
|
2460
|
-
...((
|
|
2461
|
-
city:
|
|
2522
|
+
...((y = s.paymentMethod.billingContact) == null ? void 0 : y.locality) && {
|
|
2523
|
+
city: s.paymentMethod.billingContact.locality
|
|
2462
2524
|
},
|
|
2463
|
-
...
|
|
2464
|
-
country:
|
|
2525
|
+
...d((r = s.paymentMethod.billingContact) == null ? void 0 : r.countryCode) && {
|
|
2526
|
+
country: d((g = s.paymentMethod.billingContact) == null ? void 0 : g.countryCode)
|
|
2465
2527
|
}
|
|
2466
|
-
}),
|
|
2528
|
+
}), te = q ? q.invoice_amount_including_tax.quantity.toString() : P.invoice_amount_including_tax.quantity.toString();
|
|
2467
2529
|
n("update-billing-information", {
|
|
2468
|
-
postal_code: (
|
|
2469
|
-
city: (
|
|
2470
|
-
country: (
|
|
2471
|
-
}),
|
|
2530
|
+
postal_code: (h = s.paymentMethod.billingContact) == null ? void 0 : h.postalCode,
|
|
2531
|
+
city: (w = s.paymentMethod.billingContact) == null ? void 0 : w.locality,
|
|
2532
|
+
country: (j = s.paymentMethod.billingContact) == null ? void 0 : j.countryCode
|
|
2533
|
+
}), R({
|
|
2472
2534
|
newTotal: {
|
|
2473
2535
|
label: o.billingInformation.regular.label,
|
|
2474
|
-
amount:
|
|
2536
|
+
amount: te,
|
|
2475
2537
|
type: "final"
|
|
2476
2538
|
}
|
|
2477
2539
|
});
|
|
2478
2540
|
},
|
|
2479
|
-
onError: (
|
|
2480
|
-
l.error(
|
|
2541
|
+
onError: (R) => {
|
|
2542
|
+
l.error(
|
|
2543
|
+
"APPLE_PAY_ERROR",
|
|
2544
|
+
"Apple Pay error",
|
|
2545
|
+
u({ reason: "APPLE_PAY_ERROR", cause: R }),
|
|
2546
|
+
R
|
|
2547
|
+
);
|
|
2481
2548
|
},
|
|
2482
|
-
onAuthorized: async (
|
|
2549
|
+
onAuthorized: async (R, Q) => {
|
|
2550
|
+
var s;
|
|
2483
2551
|
try {
|
|
2484
|
-
|
|
2485
|
-
|
|
2486
|
-
|
|
2487
|
-
|
|
2488
|
-
|
|
2489
|
-
|
|
2490
|
-
billingAddress: N.billingAddress
|
|
2552
|
+
const P = R.authorizedEvent;
|
|
2553
|
+
l.info("APPLE_PAY_AUTHORIZED", "Apple Pay authorized", {
|
|
2554
|
+
paymentAcceptorId: m,
|
|
2555
|
+
hasPaymentMethod: !!P.payment.token.paymentMethod,
|
|
2556
|
+
hasPaymentData: !!P.payment.token.paymentData,
|
|
2557
|
+
hasBillingContact: !!P.payment.billingContact
|
|
2491
2558
|
});
|
|
2492
|
-
const
|
|
2493
|
-
|
|
2559
|
+
const q = P.payment.billingContact, te = R.billingAddress;
|
|
2560
|
+
q ? n(
|
|
2494
2561
|
"update-billing-information",
|
|
2495
|
-
|
|
2496
|
-
) :
|
|
2562
|
+
M(q)
|
|
2563
|
+
) : te && n(
|
|
2497
2564
|
"update-billing-information",
|
|
2498
|
-
|
|
2565
|
+
A(te)
|
|
2499
2566
|
);
|
|
2500
|
-
const
|
|
2501
|
-
payment_method:
|
|
2502
|
-
|
|
2567
|
+
const f = {
|
|
2568
|
+
payment_method: bt(
|
|
2569
|
+
P.payment.token.paymentMethod
|
|
2503
2570
|
),
|
|
2504
|
-
browser_info:
|
|
2505
|
-
|
|
2571
|
+
browser_info: bt(
|
|
2572
|
+
P.payment.token.paymentData
|
|
2506
2573
|
)
|
|
2507
|
-
}
|
|
2508
|
-
|
|
2509
|
-
const te = Ei({
|
|
2510
|
-
paymentAcceptorId: M,
|
|
2574
|
+
}, y = xi({
|
|
2575
|
+
paymentAcceptorId: m,
|
|
2511
2576
|
redirectUrl: window.location.href
|
|
2512
|
-
})
|
|
2513
|
-
|
|
2514
|
-
|
|
2515
|
-
amount: o.amount
|
|
2516
|
-
});
|
|
2517
|
-
const v = await s({
|
|
2518
|
-
payment_acceptor_id: M,
|
|
2519
|
-
payment_gateway_variant: cn,
|
|
2577
|
+
}), r = await c({
|
|
2578
|
+
payment_acceptor_id: m,
|
|
2579
|
+
payment_gateway_variant: gn,
|
|
2520
2580
|
adyen: {
|
|
2521
|
-
...
|
|
2581
|
+
...f,
|
|
2522
2582
|
store_payment_method: !0
|
|
2523
2583
|
// Required for recurring payments
|
|
2524
2584
|
},
|
|
2525
2585
|
amount: o.amount,
|
|
2526
|
-
return_url:
|
|
2586
|
+
return_url: y
|
|
2527
2587
|
});
|
|
2528
2588
|
if (l.info("APPLE_PAY_API_RESPONSE", "Payment API response received", {
|
|
2529
|
-
|
|
2530
|
-
|
|
2531
|
-
}),
|
|
2532
|
-
l.error(
|
|
2533
|
-
|
|
2534
|
-
|
|
2589
|
+
paymentAcceptorId: m,
|
|
2590
|
+
status: r.status
|
|
2591
|
+
}), r.status === "FAILURE") {
|
|
2592
|
+
l.error(
|
|
2593
|
+
"APPLE_PAY_AUTHORIZATION_FAILED",
|
|
2594
|
+
"Payment authorization failed",
|
|
2595
|
+
u({
|
|
2596
|
+
reason: "APPLE_PAY_AUTHORIZATION_REJECTED",
|
|
2597
|
+
extra: { paymentStatus: r.status }
|
|
2598
|
+
})
|
|
2599
|
+
), Q.reject();
|
|
2535
2600
|
return;
|
|
2536
2601
|
}
|
|
2537
|
-
if (
|
|
2538
|
-
l.warn(
|
|
2539
|
-
|
|
2540
|
-
|
|
2602
|
+
if (r.status === "ACTION_REQUIRED") {
|
|
2603
|
+
l.warn(
|
|
2604
|
+
"APPLE_PAY_ACTION_REQUIRED",
|
|
2605
|
+
"Payment requires additional action",
|
|
2606
|
+
u({
|
|
2607
|
+
reason: "APPLE_PAY_ACTION_REQUIRED",
|
|
2608
|
+
extra: { actionType: (s = r.action) == null ? void 0 : s.method }
|
|
2609
|
+
})
|
|
2610
|
+
), Q.reject();
|
|
2541
2611
|
return;
|
|
2542
2612
|
}
|
|
2543
|
-
l.info("APPLE_PAY_SUCCESS", "Apple Pay payment successful, resolving"),
|
|
2544
|
-
} catch (
|
|
2545
|
-
l.error(
|
|
2546
|
-
|
|
2547
|
-
|
|
2613
|
+
l.info("APPLE_PAY_SUCCESS", "Apple Pay payment successful, resolving"), Q.resolve();
|
|
2614
|
+
} catch (P) {
|
|
2615
|
+
l.error(
|
|
2616
|
+
"APPLE_PAY_AUTHORIZATION_FAILED",
|
|
2617
|
+
"Apple Pay authorization failed",
|
|
2618
|
+
u({ reason: "APPLE_PAY_AUTHORIZATION_FAILED", cause: P }),
|
|
2619
|
+
P
|
|
2620
|
+
), Q.reject();
|
|
2548
2621
|
}
|
|
2549
2622
|
}
|
|
2550
2623
|
});
|
|
@@ -2553,56 +2626,56 @@ const rn = {
|
|
|
2553
2626
|
return;
|
|
2554
2627
|
}
|
|
2555
2628
|
try {
|
|
2556
|
-
await
|
|
2557
|
-
} catch (
|
|
2558
|
-
l.error("APPLE_PAY_ERROR", "Apple Pay not available on this device", {},
|
|
2629
|
+
await x.isAvailable(), x.mount(a.value), n("ready");
|
|
2630
|
+
} catch (R) {
|
|
2631
|
+
l.error("APPLE_PAY_ERROR", "Apple Pay not available on this device", {}, R);
|
|
2559
2632
|
}
|
|
2560
|
-
},
|
|
2561
|
-
if (!
|
|
2633
|
+
}, v = (p) => {
|
|
2634
|
+
if (!p.value)
|
|
2562
2635
|
return;
|
|
2563
|
-
let
|
|
2564
|
-
if (
|
|
2636
|
+
let C = p.value ?? 1, x = p.type.toLowerCase();
|
|
2637
|
+
if (p.type === "WEEK" && (x = "day", C = p.value * 7), x === "day" || x === "month" || x === "year" || x === "hour" || x === "minute")
|
|
2565
2638
|
return {
|
|
2566
|
-
recurringPaymentIntervalUnit:
|
|
2567
|
-
recurringPaymentIntervalCount:
|
|
2639
|
+
recurringPaymentIntervalUnit: x,
|
|
2640
|
+
recurringPaymentIntervalCount: C
|
|
2568
2641
|
};
|
|
2569
|
-
},
|
|
2570
|
-
postal_code:
|
|
2571
|
-
city:
|
|
2572
|
-
country:
|
|
2573
|
-
}),
|
|
2574
|
-
postal_code:
|
|
2575
|
-
city:
|
|
2576
|
-
country:
|
|
2577
|
-
}),
|
|
2578
|
-
var
|
|
2579
|
-
const
|
|
2580
|
-
if (
|
|
2581
|
-
const
|
|
2642
|
+
}, M = (p) => ({
|
|
2643
|
+
postal_code: p.postalCode,
|
|
2644
|
+
city: p.locality,
|
|
2645
|
+
country: p.countryCode
|
|
2646
|
+
}), A = (p) => ({
|
|
2647
|
+
postal_code: p.postalCode,
|
|
2648
|
+
city: p.city,
|
|
2649
|
+
country: p.country
|
|
2650
|
+
}), d = (p) => p && L(p) ? p : void 0, L = (p) => Ge(p), k = () => {
|
|
2651
|
+
var C;
|
|
2652
|
+
const p = (C = a.value) == null ? void 0 : C.querySelector("apple-pay-button");
|
|
2653
|
+
if (p) {
|
|
2654
|
+
const x = new MouseEvent("click", {
|
|
2582
2655
|
bubbles: !0,
|
|
2583
2656
|
cancelable: !0,
|
|
2584
2657
|
view: window
|
|
2585
2658
|
});
|
|
2586
|
-
|
|
2659
|
+
p.dispatchEvent(x);
|
|
2587
2660
|
}
|
|
2588
2661
|
};
|
|
2589
|
-
return
|
|
2590
|
-
|
|
2591
|
-
}), (
|
|
2592
|
-
e.isVisible ? (
|
|
2662
|
+
return Oe(() => {
|
|
2663
|
+
N();
|
|
2664
|
+
}), (p, C) => (_(), W(_e, null, [
|
|
2665
|
+
e.isVisible ? (_(), O(it, {
|
|
2593
2666
|
key: 0,
|
|
2594
2667
|
type: "applepay",
|
|
2595
|
-
onClick:
|
|
2668
|
+
onClick: k
|
|
2596
2669
|
})) : B("", !0),
|
|
2597
|
-
|
|
2598
|
-
|
|
2670
|
+
T("div", mn, [
|
|
2671
|
+
T("div", {
|
|
2599
2672
|
ref_key: "applePayButtonRef",
|
|
2600
2673
|
ref: a
|
|
2601
2674
|
}, null, 512)
|
|
2602
2675
|
])
|
|
2603
2676
|
], 64));
|
|
2604
2677
|
}
|
|
2605
|
-
}),
|
|
2678
|
+
}), vn = { class: "relative overflow-hidden" }, fn = /* @__PURE__ */ ce({
|
|
2606
2679
|
__name: "ExpressPaymentMethodPaypal",
|
|
2607
2680
|
props: {
|
|
2608
2681
|
amount: { type: Object },
|
|
@@ -2614,18 +2687,18 @@ const rn = {
|
|
|
2614
2687
|
},
|
|
2615
2688
|
emits: ["ready", "update-billing-information"],
|
|
2616
2689
|
setup(e, { emit: i }) {
|
|
2617
|
-
const o = e, n = i, a =
|
|
2690
|
+
const o = e, n = i, a = Me(), { buttonRef: l } = Gt({
|
|
2618
2691
|
props: o,
|
|
2619
2692
|
onMissingButton: () => a.error(
|
|
2620
2693
|
"EXPRESS_CHECKOUT_PAYPAL_ERROR",
|
|
2621
2694
|
"The PayPal button reference is not found and cannot be mounted"
|
|
2622
2695
|
),
|
|
2623
|
-
onMountFailed: (
|
|
2624
|
-
error:
|
|
2696
|
+
onMountFailed: (c) => a.error("EXPRESS_CHECKOUT_PAYPAL_ERROR", "Failed mounting PayPal express button", {
|
|
2697
|
+
error: c
|
|
2625
2698
|
}),
|
|
2626
|
-
create: async (
|
|
2627
|
-
const { PayPal:
|
|
2628
|
-
return new
|
|
2699
|
+
create: async (c) => {
|
|
2700
|
+
const { PayPal: m } = await Ve();
|
|
2701
|
+
return new m(c, {
|
|
2629
2702
|
isExpress: !0,
|
|
2630
2703
|
blockPayPalPayLaterButton: !0,
|
|
2631
2704
|
blockPayPalCreditButton: !0,
|
|
@@ -2639,20 +2712,20 @@ const rn = {
|
|
|
2639
2712
|
});
|
|
2640
2713
|
}
|
|
2641
2714
|
});
|
|
2642
|
-
return (
|
|
2643
|
-
e.isVisible ? (
|
|
2715
|
+
return (c, m) => (_(), W("div", vn, [
|
|
2716
|
+
e.isVisible ? (_(), O(it, {
|
|
2644
2717
|
key: 0,
|
|
2645
2718
|
type: "paypal",
|
|
2646
2719
|
class: "w-full"
|
|
2647
2720
|
})) : B("", !0),
|
|
2648
|
-
|
|
2721
|
+
T("div", {
|
|
2649
2722
|
ref_key: "paypalButtonRef",
|
|
2650
2723
|
ref: l,
|
|
2651
2724
|
class: "absolute inset-0 opacity-[0.0001]"
|
|
2652
2725
|
}, null, 512)
|
|
2653
2726
|
]));
|
|
2654
2727
|
}
|
|
2655
|
-
}),
|
|
2728
|
+
}), _n = { class: "absolute h-[1px] w-[1px] overflow-hidden opacity-0" }, Mn = /* @__PURE__ */ ce({
|
|
2656
2729
|
__name: "ExpressPaymentMethodGooglePay",
|
|
2657
2730
|
props: {
|
|
2658
2731
|
amount: { type: Object },
|
|
@@ -2664,52 +2737,53 @@ const rn = {
|
|
|
2664
2737
|
},
|
|
2665
2738
|
emits: ["ready", "update-billing-information"],
|
|
2666
2739
|
setup(e, { emit: i }) {
|
|
2667
|
-
const o = e, n = i, a =
|
|
2740
|
+
const o = e, n = i, a = Me(), { buttonRef: l } = Gt({
|
|
2668
2741
|
props: o,
|
|
2669
2742
|
onMissingButton: () => a.error(
|
|
2670
2743
|
"EXPRESS_CHECKOUT_GOOGLE_PAY_ERROR",
|
|
2671
2744
|
"The Google Pay button reference is not found and cannot be mounted"
|
|
2672
2745
|
),
|
|
2673
|
-
onMountFailed: (
|
|
2746
|
+
onMountFailed: (m) => a.error(
|
|
2674
2747
|
"EXPRESS_CHECKOUT_GOOGLE_PAY_ERROR",
|
|
2675
2748
|
"Failed mounting Google Pay express button",
|
|
2676
|
-
{
|
|
2749
|
+
{},
|
|
2750
|
+
m
|
|
2677
2751
|
),
|
|
2678
|
-
create: async (
|
|
2679
|
-
const { GooglePay:
|
|
2680
|
-
return new
|
|
2752
|
+
create: async (m) => {
|
|
2753
|
+
const { GooglePay: u } = await Ve();
|
|
2754
|
+
return new u(m, { isExpress: !0 });
|
|
2681
2755
|
},
|
|
2682
2756
|
afterMount: () => n("ready")
|
|
2683
|
-
}),
|
|
2684
|
-
var
|
|
2685
|
-
const
|
|
2686
|
-
if (
|
|
2687
|
-
const
|
|
2757
|
+
}), c = () => {
|
|
2758
|
+
var u;
|
|
2759
|
+
const m = (u = l.value) == null ? void 0 : u.querySelector("#gpay-button-online-api-id");
|
|
2760
|
+
if (m) {
|
|
2761
|
+
const N = new MouseEvent("click", {
|
|
2688
2762
|
bubbles: !0,
|
|
2689
2763
|
cancelable: !0,
|
|
2690
2764
|
view: window
|
|
2691
2765
|
});
|
|
2692
|
-
|
|
2766
|
+
m.dispatchEvent(N);
|
|
2693
2767
|
}
|
|
2694
2768
|
};
|
|
2695
|
-
return (
|
|
2696
|
-
e.isVisible ? (
|
|
2769
|
+
return (m, u) => (_(), W(_e, null, [
|
|
2770
|
+
e.isVisible ? (_(), O(it, {
|
|
2697
2771
|
key: 0,
|
|
2698
2772
|
type: "googlepay",
|
|
2699
|
-
onClick:
|
|
2773
|
+
onClick: c
|
|
2700
2774
|
})) : B("", !0),
|
|
2701
|
-
|
|
2702
|
-
|
|
2775
|
+
T("div", _n, [
|
|
2776
|
+
T("div", {
|
|
2703
2777
|
ref_key: "googlePayButtonRef",
|
|
2704
2778
|
ref: l
|
|
2705
2779
|
}, null, 512)
|
|
2706
2780
|
])
|
|
2707
2781
|
], 64));
|
|
2708
2782
|
}
|
|
2709
|
-
}),
|
|
2783
|
+
}), hn = {
|
|
2710
2784
|
key: 0,
|
|
2711
2785
|
class: "mt-4n"
|
|
2712
|
-
},
|
|
2786
|
+
}, bn = { class: "mb-2" }, In = { class: "grid grid-cols-6 gap-1 md:gap-2" }, An = { class: "mt-4 h-4" }, Pn = 2, Dn = /* @__PURE__ */ ce({
|
|
2713
2787
|
__name: "ExpressPaymentMethods",
|
|
2714
2788
|
props: {
|
|
2715
2789
|
amount: { type: Object },
|
|
@@ -2721,131 +2795,131 @@ const rn = {
|
|
|
2721
2795
|
},
|
|
2722
2796
|
emits: ["update-billing-information"],
|
|
2723
2797
|
setup(e) {
|
|
2724
|
-
const i = ["applepay"], o = e, { $t: n } =
|
|
2725
|
-
var
|
|
2798
|
+
const i = ["applepay"], o = e, { $t: n } = ve(), a = V(!1), l = V(!1), c = V(!1), m = b(() => {
|
|
2799
|
+
var d;
|
|
2726
2800
|
if (i.includes("applepay"))
|
|
2727
|
-
return (
|
|
2728
|
-
(
|
|
2729
|
-
var
|
|
2730
|
-
return (
|
|
2731
|
-
(
|
|
2801
|
+
return (d = o.paymentMethodsOptionsResponse) == null ? void 0 : d.find(
|
|
2802
|
+
(L) => {
|
|
2803
|
+
var k;
|
|
2804
|
+
return (k = L.options) == null ? void 0 : k.some(
|
|
2805
|
+
(p) => p.name.toLowerCase() === "apple pay" && p.payment_gateway_variant === "ADYEN"
|
|
2732
2806
|
);
|
|
2733
2807
|
}
|
|
2734
2808
|
);
|
|
2735
|
-
}),
|
|
2736
|
-
var
|
|
2809
|
+
}), u = b(() => {
|
|
2810
|
+
var d;
|
|
2737
2811
|
if (i.includes("paypal"))
|
|
2738
|
-
return (
|
|
2739
|
-
(
|
|
2740
|
-
var
|
|
2741
|
-
return (
|
|
2742
|
-
(
|
|
2812
|
+
return (d = o.paymentMethodsOptionsResponse) == null ? void 0 : d.find(
|
|
2813
|
+
(L) => {
|
|
2814
|
+
var k;
|
|
2815
|
+
return (k = L.options) == null ? void 0 : k.some(
|
|
2816
|
+
(p) => p.name.toLowerCase() === "paypal" && p.payment_gateway_variant === "ADYEN"
|
|
2743
2817
|
);
|
|
2744
2818
|
}
|
|
2745
2819
|
);
|
|
2746
|
-
}),
|
|
2747
|
-
var
|
|
2820
|
+
}), N = b(() => {
|
|
2821
|
+
var d;
|
|
2748
2822
|
if (i.includes("googlepay"))
|
|
2749
|
-
return (
|
|
2750
|
-
(
|
|
2751
|
-
var
|
|
2752
|
-
return (
|
|
2753
|
-
(
|
|
2823
|
+
return (d = o.paymentMethodsOptionsResponse) == null ? void 0 : d.find(
|
|
2824
|
+
(L) => {
|
|
2825
|
+
var k;
|
|
2826
|
+
return (k = L.options) == null ? void 0 : k.some(
|
|
2827
|
+
(p) => p.name.toLowerCase() === "google pay" && p.payment_gateway_variant === "ADYEN"
|
|
2754
2828
|
);
|
|
2755
2829
|
}
|
|
2756
2830
|
);
|
|
2757
|
-
}),
|
|
2758
|
-
var
|
|
2759
|
-
if (((
|
|
2831
|
+
}), v = b(() => !!(m.value || N.value || u.value)), M = b(() => {
|
|
2832
|
+
var p;
|
|
2833
|
+
if (((p = o.paymentMethodsOptionsResponse) == null ? void 0 : p.length) === 0)
|
|
2760
2834
|
return !1;
|
|
2761
|
-
const
|
|
2762
|
-
return
|
|
2763
|
-
}), A = b(() =>
|
|
2764
|
-
return (
|
|
2765
|
-
|
|
2766
|
-
|
|
2835
|
+
const d = !m.value || a.value, L = !N.value || l.value, k = !u.value || c.value;
|
|
2836
|
+
return d && L && k;
|
|
2837
|
+
}), A = b(() => M.value ? (m.value ? 1 : 0) + (N.value ? 1 : 0) + (u.value ? 1 : 0) : Pn);
|
|
2838
|
+
return (d, L) => v.value ? (_(), W("div", hn, [
|
|
2839
|
+
T("div", bn, [
|
|
2840
|
+
M.value ? (_(), O(t(se), {
|
|
2767
2841
|
key: 1,
|
|
2768
2842
|
variant: "heading-3",
|
|
2769
2843
|
tag: "h2"
|
|
2770
2844
|
}, {
|
|
2771
2845
|
default: I(() => [
|
|
2772
|
-
|
|
2846
|
+
F(U(t(n)({
|
|
2773
2847
|
defaultMessage: "Subscribe instantly with",
|
|
2774
2848
|
id: "checkout.express_payment_methods.title",
|
|
2775
2849
|
description: "The title of the express payment methods block in the checkout form"
|
|
2776
2850
|
})), 1)
|
|
2777
2851
|
]),
|
|
2778
2852
|
_: 1
|
|
2779
|
-
})) : (
|
|
2853
|
+
})) : (_(), O(fe, {
|
|
2780
2854
|
key: 0,
|
|
2781
2855
|
variant: "title"
|
|
2782
2856
|
}))
|
|
2783
2857
|
]),
|
|
2784
|
-
|
|
2785
|
-
|
|
2786
|
-
|
|
2787
|
-
|
|
2858
|
+
T("div", In, [
|
|
2859
|
+
M.value ? B("", !0) : (_(), W(_e, { key: 0 }, [
|
|
2860
|
+
E(fe, { class: "col-span-3 h-11" }),
|
|
2861
|
+
E(fe, { class: "col-span-3 h-11" })
|
|
2788
2862
|
], 64)),
|
|
2789
|
-
|
|
2790
|
-
class:
|
|
2791
|
-
hidden: !
|
|
2863
|
+
T("div", {
|
|
2864
|
+
class: be(["col-span-3 md:col-span-2", {
|
|
2865
|
+
hidden: !m.value,
|
|
2792
2866
|
"!col-span-6": A.value === 1,
|
|
2793
2867
|
"md:!col-span-3": A.value === 2,
|
|
2794
2868
|
"!col-span-6 md:!col-span-2": A.value === 3
|
|
2795
2869
|
}])
|
|
2796
2870
|
}, [
|
|
2797
|
-
|
|
2871
|
+
m.value ? (_(), O(yn, {
|
|
2798
2872
|
key: 0,
|
|
2799
2873
|
amount: e.amount,
|
|
2800
2874
|
"billing-information": e.billingInformation,
|
|
2801
2875
|
"country-code": e.countryCode,
|
|
2802
2876
|
locale: e.locale,
|
|
2803
|
-
"is-visible":
|
|
2804
|
-
"payment-method-options-response":
|
|
2877
|
+
"is-visible": M.value,
|
|
2878
|
+
"payment-method-options-response": m.value,
|
|
2805
2879
|
"on-billing-information-change": e.onBillingInformationChange,
|
|
2806
|
-
onReady:
|
|
2807
|
-
onUpdateBillingInformation:
|
|
2880
|
+
onReady: L[0] || (L[0] = (k) => a.value = !0),
|
|
2881
|
+
onUpdateBillingInformation: L[1] || (L[1] = (k) => d.$emit("update-billing-information", k))
|
|
2808
2882
|
}, null, 8, ["amount", "billing-information", "country-code", "locale", "is-visible", "payment-method-options-response", "on-billing-information-change"])) : B("", !0)
|
|
2809
2883
|
], 2),
|
|
2810
|
-
|
|
2811
|
-
class:
|
|
2812
|
-
hidden: !
|
|
2884
|
+
T("div", {
|
|
2885
|
+
class: be(["col-span-3 md:col-span-2", {
|
|
2886
|
+
hidden: !N.value,
|
|
2813
2887
|
"col-span-6 md:col-span-6": A.value === 1,
|
|
2814
2888
|
"md:!col-span-3": A.value === 2
|
|
2815
2889
|
}])
|
|
2816
2890
|
}, [
|
|
2817
|
-
|
|
2891
|
+
N.value ? (_(), O(Mn, {
|
|
2818
2892
|
key: 0,
|
|
2819
2893
|
amount: e.amount,
|
|
2820
2894
|
"billing-information": e.billingInformation,
|
|
2821
2895
|
"country-code": e.countryCode,
|
|
2822
2896
|
locale: e.locale,
|
|
2823
|
-
"is-visible":
|
|
2824
|
-
"payment-method-options-response":
|
|
2825
|
-
onReady:
|
|
2897
|
+
"is-visible": M.value,
|
|
2898
|
+
"payment-method-options-response": N.value,
|
|
2899
|
+
onReady: L[2] || (L[2] = (k) => l.value = !0)
|
|
2826
2900
|
}, null, 8, ["amount", "billing-information", "country-code", "locale", "is-visible", "payment-method-options-response"])) : B("", !0)
|
|
2827
2901
|
], 2),
|
|
2828
|
-
|
|
2829
|
-
class:
|
|
2830
|
-
hidden: !
|
|
2902
|
+
T("div", {
|
|
2903
|
+
class: be(["col-span-3 md:col-span-2", {
|
|
2904
|
+
hidden: !u.value,
|
|
2831
2905
|
"col-span-6 md:col-span-6": A.value === 1,
|
|
2832
2906
|
"md:!col-span-3": A.value === 2
|
|
2833
2907
|
}])
|
|
2834
2908
|
}, [
|
|
2835
|
-
|
|
2909
|
+
u.value ? (_(), O(fn, {
|
|
2836
2910
|
key: 0,
|
|
2837
2911
|
amount: e.amount,
|
|
2838
2912
|
"billing-information": e.billingInformation,
|
|
2839
2913
|
"country-code": e.countryCode,
|
|
2840
2914
|
locale: e.locale,
|
|
2841
|
-
"is-visible":
|
|
2842
|
-
"payment-method-options-response":
|
|
2843
|
-
onReady:
|
|
2915
|
+
"is-visible": M.value,
|
|
2916
|
+
"payment-method-options-response": u.value,
|
|
2917
|
+
onReady: L[3] || (L[3] = (k) => c.value = !0)
|
|
2844
2918
|
}, null, 8, ["amount", "billing-information", "country-code", "locale", "is-visible", "payment-method-options-response"])) : B("", !0)
|
|
2845
2919
|
], 2)
|
|
2846
2920
|
]),
|
|
2847
|
-
|
|
2848
|
-
|
|
2921
|
+
T("div", An, [
|
|
2922
|
+
M.value ? (_(), O(t(Gi), {
|
|
2849
2923
|
key: 1,
|
|
2850
2924
|
text: t(n)({
|
|
2851
2925
|
defaultMessage: "Or",
|
|
@@ -2853,17 +2927,17 @@ const rn = {
|
|
|
2853
2927
|
description: "The text of the divider text in the express payment methods block in the checkout form"
|
|
2854
2928
|
}),
|
|
2855
2929
|
"text-position": "center"
|
|
2856
|
-
}, null, 8, ["text"])) : (
|
|
2930
|
+
}, null, 8, ["text"])) : (_(), O(fe, {
|
|
2857
2931
|
key: 0,
|
|
2858
2932
|
variant: "divider-text"
|
|
2859
2933
|
}))
|
|
2860
2934
|
])
|
|
2861
2935
|
])) : B("", !0);
|
|
2862
2936
|
}
|
|
2863
|
-
}),
|
|
2937
|
+
}), Nn = ["aria-expanded", "aria-label"], En = { class: "flex w-full cursor-pointer flex-row items-center justify-between gap-3 px-3 py-2" }, Cn = { class: "flex flex-row items-center gap-2" }, xn = ["onKeydown"], Ln = ["aria-label"], Tn = { class: "flex w-full cursor-pointer flex-row items-center justify-between gap-3 px-3 py-2" }, wn = { class: "flex flex-row items-center gap-2" }, Sn = {
|
|
2864
2938
|
class: "sr-only",
|
|
2865
2939
|
"aria-live": "polite"
|
|
2866
|
-
},
|
|
2940
|
+
}, On = /* @__PURE__ */ ce({
|
|
2867
2941
|
inheritAttrs: !1,
|
|
2868
2942
|
__name: "PromotionCodeSection",
|
|
2869
2943
|
props: {
|
|
@@ -2871,13 +2945,13 @@ const rn = {
|
|
|
2871
2945
|
},
|
|
2872
2946
|
emits: ["update:appliedCode", "apply", "remove"],
|
|
2873
2947
|
setup(e, { emit: i }) {
|
|
2874
|
-
const { $t: o } =
|
|
2948
|
+
const { $t: o } = ve(), n = e, a = i, l = V(!1), c = V(""), m = V(""), u = V(null), N = V(null), v = Hi("promotion-code-"), M = `${v}-label`, A = `${v}-panel`, d = b(() => n.promotionCode !== null && n.promotionCode !== ""), L = b(() => c.value.trim().length > 0), k = b(
|
|
2875
2949
|
() => n.promotionCode ?? o({
|
|
2876
2950
|
defaultMessage: "Promotion applied",
|
|
2877
2951
|
id: "checkout.promotion_code.applied_label",
|
|
2878
2952
|
description: "Fallback label for an applied promotion code in checkout"
|
|
2879
2953
|
})
|
|
2880
|
-
),
|
|
2954
|
+
), p = b(
|
|
2881
2955
|
() => l.value ? o({
|
|
2882
2956
|
defaultMessage: "Collapse promotion code input",
|
|
2883
2957
|
id: "checkout.promotion_code.collapse_aria_label",
|
|
@@ -2887,119 +2961,119 @@ const rn = {
|
|
|
2887
2961
|
id: "checkout.promotion_code.expand_aria_label",
|
|
2888
2962
|
description: "Aria label for the promotion code toggle button in checkout, while the input is closed"
|
|
2889
2963
|
})
|
|
2890
|
-
),
|
|
2964
|
+
), C = b(
|
|
2891
2965
|
() => o({
|
|
2892
2966
|
defaultMessage: "Apply promotion code",
|
|
2893
2967
|
id: "checkout.promotion_code.apply_aria_label",
|
|
2894
2968
|
description: "Aria label for the promotion code apply button in checkout"
|
|
2895
2969
|
})
|
|
2896
|
-
),
|
|
2970
|
+
), x = b(
|
|
2897
2971
|
() => o({
|
|
2898
2972
|
defaultMessage: "Remove promotion code",
|
|
2899
2973
|
id: "checkout.promotion_code.remove_aria_label",
|
|
2900
2974
|
description: "Aria label for the promotion code remove button in checkout"
|
|
2901
2975
|
})
|
|
2902
|
-
),
|
|
2903
|
-
|
|
2904
|
-
}, R = () => {
|
|
2905
|
-
var f;
|
|
2906
|
-
const v = (f = E.value) == null ? void 0 : f.querySelector("input");
|
|
2907
|
-
v instanceof HTMLInputElement && v.focus();
|
|
2908
|
-
}, u = () => {
|
|
2909
|
-
l.value && (l.value = !1);
|
|
2910
|
-
}, T = () => {
|
|
2911
|
-
c.value || (l.value = !l.value);
|
|
2976
|
+
), R = () => {
|
|
2977
|
+
c.value = "";
|
|
2912
2978
|
}, Q = () => {
|
|
2913
|
-
|
|
2979
|
+
var y;
|
|
2980
|
+
const f = (y = N.value) == null ? void 0 : y.querySelector("input");
|
|
2981
|
+
f instanceof HTMLInputElement && f.focus();
|
|
2982
|
+
}, s = () => {
|
|
2983
|
+
l.value && (l.value = !1);
|
|
2984
|
+
}, P = () => {
|
|
2985
|
+
d.value || (l.value = !l.value);
|
|
2986
|
+
}, q = () => {
|
|
2987
|
+
if (!L.value)
|
|
2914
2988
|
return;
|
|
2915
|
-
const
|
|
2916
|
-
a("update:appliedCode",
|
|
2989
|
+
const f = c.value.trim();
|
|
2990
|
+
a("update:appliedCode", f), a("apply", f), m.value = o({
|
|
2917
2991
|
defaultMessage: "Promotion code applied",
|
|
2918
2992
|
id: "checkout.promotion_code.applied_status",
|
|
2919
2993
|
description: "Aria live message when a promotion code is applied in checkout"
|
|
2920
2994
|
}), l.value = !1;
|
|
2921
2995
|
}, te = () => {
|
|
2922
|
-
a("update:appliedCode", null), a("remove"),
|
|
2996
|
+
a("update:appliedCode", null), a("remove"), m.value = o({
|
|
2923
2997
|
defaultMessage: "Promotion code removed",
|
|
2924
2998
|
id: "checkout.promotion_code.removed_status",
|
|
2925
2999
|
description: "Aria live message when a promotion code is removed in checkout"
|
|
2926
|
-
}),
|
|
2927
|
-
var
|
|
2928
|
-
(
|
|
3000
|
+
}), R(), He(() => {
|
|
3001
|
+
var f;
|
|
3002
|
+
(f = u.value) == null || f.focus();
|
|
2929
3003
|
});
|
|
2930
3004
|
};
|
|
2931
|
-
return
|
|
2932
|
-
if (!
|
|
2933
|
-
|
|
2934
|
-
var
|
|
2935
|
-
(
|
|
3005
|
+
return we(l, (f) => {
|
|
3006
|
+
if (!f) {
|
|
3007
|
+
R(), He(() => {
|
|
3008
|
+
var y;
|
|
3009
|
+
(y = u.value) == null || y.focus();
|
|
2936
3010
|
});
|
|
2937
3011
|
return;
|
|
2938
3012
|
}
|
|
2939
|
-
|
|
2940
|
-
|
|
3013
|
+
He(() => {
|
|
3014
|
+
Q();
|
|
2941
3015
|
});
|
|
2942
|
-
}),
|
|
3016
|
+
}), we(
|
|
2943
3017
|
() => n.promotionCode,
|
|
2944
|
-
(
|
|
2945
|
-
|
|
3018
|
+
(f) => {
|
|
3019
|
+
f || R();
|
|
2946
3020
|
}
|
|
2947
|
-
), (
|
|
2948
|
-
|
|
3021
|
+
), (f, y) => (_(), W(_e, null, [
|
|
3022
|
+
d.value ? (_(), O(t(ge), ft({ key: 1 }, f.$attrs, {
|
|
2949
3023
|
"no-border": "",
|
|
2950
3024
|
"no-spacing": "",
|
|
2951
3025
|
"content-background": "none",
|
|
2952
3026
|
class: "relative w-full"
|
|
2953
3027
|
}), {
|
|
2954
3028
|
default: I(() => [
|
|
2955
|
-
|
|
3029
|
+
T("button", {
|
|
2956
3030
|
type: "button",
|
|
2957
3031
|
class: "w-full rounded border border-primary-900 bg-white",
|
|
2958
|
-
"aria-label":
|
|
3032
|
+
"aria-label": x.value,
|
|
2959
3033
|
onClick: te
|
|
2960
3034
|
}, [
|
|
2961
|
-
|
|
2962
|
-
|
|
2963
|
-
|
|
2964
|
-
|
|
3035
|
+
T("div", Tn, [
|
|
3036
|
+
T("div", wn, [
|
|
3037
|
+
E(t(je), { icon: "local_activity" }),
|
|
3038
|
+
E(t(se), {
|
|
2965
3039
|
variant: "body-sm",
|
|
2966
3040
|
class: "font-semibold"
|
|
2967
3041
|
}, {
|
|
2968
3042
|
default: I(() => [
|
|
2969
|
-
|
|
3043
|
+
F(U(k.value), 1)
|
|
2970
3044
|
]),
|
|
2971
3045
|
_: 1
|
|
2972
3046
|
})
|
|
2973
3047
|
]),
|
|
2974
|
-
|
|
3048
|
+
E(t(je), { icon: "close" })
|
|
2975
3049
|
])
|
|
2976
|
-
], 8,
|
|
3050
|
+
], 8, Ln)
|
|
2977
3051
|
]),
|
|
2978
3052
|
_: 1
|
|
2979
|
-
}, 16)) : (
|
|
3053
|
+
}, 16)) : (_(), O(t(ge), ft({ key: 0 }, f.$attrs, {
|
|
2980
3054
|
"no-spacing": "",
|
|
2981
3055
|
class: "relative w-full"
|
|
2982
3056
|
}), {
|
|
2983
3057
|
default: I(() => [
|
|
2984
|
-
|
|
3058
|
+
T("button", {
|
|
2985
3059
|
ref_key: "toggleRef",
|
|
2986
|
-
ref:
|
|
3060
|
+
ref: u,
|
|
2987
3061
|
type: "button",
|
|
2988
3062
|
class: "w-full",
|
|
2989
3063
|
"aria-expanded": l.value,
|
|
2990
3064
|
"aria-controls": A,
|
|
2991
|
-
"aria-label":
|
|
2992
|
-
onClick:
|
|
3065
|
+
"aria-label": p.value,
|
|
3066
|
+
onClick: P
|
|
2993
3067
|
}, [
|
|
2994
|
-
|
|
2995
|
-
|
|
2996
|
-
|
|
2997
|
-
|
|
2998
|
-
id:
|
|
3068
|
+
T("div", En, [
|
|
3069
|
+
T("div", Cn, [
|
|
3070
|
+
E(t(je), { icon: "local_activity" }),
|
|
3071
|
+
E(t(se), {
|
|
3072
|
+
id: M,
|
|
2999
3073
|
variant: "body-sm"
|
|
3000
3074
|
}, {
|
|
3001
3075
|
default: I(() => [
|
|
3002
|
-
|
|
3076
|
+
F(U(t(o)({
|
|
3003
3077
|
defaultMessage: "Add promotion code",
|
|
3004
3078
|
id: "checkout.promotion_code.add_label",
|
|
3005
3079
|
description: "Label for adding a promotion code in checkout"
|
|
@@ -3008,23 +3082,23 @@ const rn = {
|
|
|
3008
3082
|
_: 1
|
|
3009
3083
|
})
|
|
3010
3084
|
]),
|
|
3011
|
-
|
|
3085
|
+
E(t(je), {
|
|
3012
3086
|
icon: l.value ? "remove" : "add"
|
|
3013
3087
|
}, null, 8, ["icon"])
|
|
3014
3088
|
])
|
|
3015
|
-
], 8,
|
|
3016
|
-
|
|
3089
|
+
], 8, Nn),
|
|
3090
|
+
ti(T("div", {
|
|
3017
3091
|
id: A,
|
|
3018
3092
|
ref_key: "panelRef",
|
|
3019
|
-
ref:
|
|
3093
|
+
ref: N,
|
|
3020
3094
|
role: "region",
|
|
3021
|
-
"aria-labelledby":
|
|
3095
|
+
"aria-labelledby": M,
|
|
3022
3096
|
class: "flex w-full flex-row items-center gap-2 overflow-hidden border-t px-3 py-2",
|
|
3023
|
-
onKeydown:
|
|
3097
|
+
onKeydown: _t($e(s, ["prevent"]), ["esc"])
|
|
3024
3098
|
}, [
|
|
3025
|
-
|
|
3026
|
-
modelValue:
|
|
3027
|
-
"onUpdate:modelValue":
|
|
3099
|
+
E(t(ye), {
|
|
3100
|
+
modelValue: c.value,
|
|
3101
|
+
"onUpdate:modelValue": y[0] || (y[0] = (r) => c.value = r),
|
|
3028
3102
|
placeholder: t(o)({
|
|
3029
3103
|
defaultMessage: "Promotion code",
|
|
3030
3104
|
id: "checkout.promotion_code.placeholder",
|
|
@@ -3036,17 +3110,17 @@ const rn = {
|
|
|
3036
3110
|
description: "Aria label for promotion code input in checkout"
|
|
3037
3111
|
}),
|
|
3038
3112
|
class: "w-full",
|
|
3039
|
-
onKeydown:
|
|
3113
|
+
onKeydown: _t($e(q, ["prevent"]), ["enter"])
|
|
3040
3114
|
}, null, 8, ["modelValue", "placeholder", "aria-label", "onKeydown"]),
|
|
3041
|
-
|
|
3115
|
+
E(t(Ae), {
|
|
3042
3116
|
type: "button",
|
|
3043
|
-
disabled: !
|
|
3044
|
-
"aria-label":
|
|
3045
|
-
"aria-disabled": !
|
|
3046
|
-
onClick:
|
|
3117
|
+
disabled: !L.value,
|
|
3118
|
+
"aria-label": C.value,
|
|
3119
|
+
"aria-disabled": !L.value,
|
|
3120
|
+
onClick: q
|
|
3047
3121
|
}, {
|
|
3048
3122
|
default: I(() => [
|
|
3049
|
-
|
|
3123
|
+
F(U(t(o)({
|
|
3050
3124
|
defaultMessage: "Apply",
|
|
3051
3125
|
id: "checkout.promotion_code.apply_button",
|
|
3052
3126
|
description: "Button label for applying a promotion code in checkout"
|
|
@@ -3054,225 +3128,241 @@ const rn = {
|
|
|
3054
3128
|
]),
|
|
3055
3129
|
_: 1
|
|
3056
3130
|
}, 8, ["disabled", "aria-label", "aria-disabled"])
|
|
3057
|
-
], 40,
|
|
3058
|
-
[
|
|
3131
|
+
], 40, xn), [
|
|
3132
|
+
[ii, l.value]
|
|
3059
3133
|
])
|
|
3060
3134
|
]),
|
|
3061
3135
|
_: 1
|
|
3062
3136
|
}, 16)),
|
|
3063
|
-
|
|
3137
|
+
T("span", Sn, U(m.value), 1)
|
|
3064
3138
|
], 64));
|
|
3065
3139
|
}
|
|
3066
|
-
}),
|
|
3140
|
+
}), kn = { class: "sv-checkout__header" }, zn = { class: "sv-checkout__payment-methods" }, jn = {
|
|
3067
3141
|
key: 0,
|
|
3068
3142
|
class: "sv-checkout__payment-methods-body"
|
|
3069
|
-
},
|
|
3143
|
+
}, Rn = {
|
|
3070
3144
|
key: 3,
|
|
3071
3145
|
class: "sv-checkout__payment-form"
|
|
3072
|
-
},
|
|
3146
|
+
}, Bn = { class: "sv-checkout__order-summary" }, $n = { class: "flex flex-col gap-2" }, Un = /* @__PURE__ */ ce({
|
|
3073
3147
|
__name: "Checkout",
|
|
3074
3148
|
props: {
|
|
3075
3149
|
configuration: { type: Object }
|
|
3076
3150
|
},
|
|
3077
3151
|
emits: ["error", "ready"],
|
|
3078
3152
|
setup(e, { emit: i }) {
|
|
3079
|
-
var
|
|
3080
|
-
const o =
|
|
3081
|
-
() => import("./PaymentIntegrationForm-
|
|
3082
|
-
), n =
|
|
3083
|
-
() => import("./PlanCustomizationEditor-
|
|
3084
|
-
), a = e, l = i,
|
|
3085
|
-
if (
|
|
3086
|
-
throw
|
|
3087
|
-
|
|
3153
|
+
var lt, st, ct, ut, dt, pt, mt, gt, yt;
|
|
3154
|
+
const o = Mt(
|
|
3155
|
+
() => import("./PaymentIntegrationForm-CpOZUf-W.mjs")
|
|
3156
|
+
), n = Mt(
|
|
3157
|
+
() => import("./PlanCustomizationEditor-BQqkgmzL.mjs")
|
|
3158
|
+
), a = e, l = i, c = b(() => a.configuration), m = V(), u = V(), N = Me(), { $t: v, locale: M } = ve(), { formatTimePeriod: A } = Lt(), d = Li(), { isMobileViewport: L } = St();
|
|
3159
|
+
if (N.info("COMPONENT_INITIALIZED", "Checkout component initialized"), ((lt = d.value) == null ? void 0 : lt.type) !== "INIT_PRICING_PLAN_SUBSCRIPTION")
|
|
3160
|
+
throw N.error("INVALID_TOKEN", "Invalid token"), Error("Invalid token");
|
|
3161
|
+
d.value.status === "REVOKED" && (m.value = {
|
|
3088
3162
|
code: "RESOURCE_REVOKED",
|
|
3089
|
-
message: `Portal url with resource id "${
|
|
3090
|
-
},
|
|
3091
|
-
const
|
|
3092
|
-
validatedEmail:
|
|
3093
|
-
validatedCountry:
|
|
3094
|
-
paymentMethodOptions:
|
|
3095
|
-
hasPaymentMethodOptionsError:
|
|
3096
|
-
retryPaymentMethodOptions:
|
|
3097
|
-
subscription:
|
|
3098
|
-
isPaymentMethodsPending:
|
|
3163
|
+
message: `Portal url with resource id "${d.value.id}" is revoked`
|
|
3164
|
+
}, N.error("RESOURCE_REVOKED", `Portal url with resource id "${d.value.id}" is revoked`));
|
|
3165
|
+
const k = (ct = (st = d.value) == null ? void 0 : st.init_pricing_plan_subscription) == null ? void 0 : ct.pricing_plan_subscription_id, p = (dt = (ut = d.value) == null ? void 0 : ut.init_pricing_plan_subscription) == null ? void 0 : dt.success_url, {
|
|
3166
|
+
validatedEmail: C,
|
|
3167
|
+
validatedCountry: x,
|
|
3168
|
+
paymentMethodOptions: R,
|
|
3169
|
+
hasPaymentMethodOptionsError: Q,
|
|
3170
|
+
retryPaymentMethodOptions: s,
|
|
3171
|
+
subscription: P,
|
|
3172
|
+
isPaymentMethodsPending: q,
|
|
3099
3173
|
isInvoicePreviewPending: te,
|
|
3100
|
-
checkoutForm:
|
|
3101
|
-
invoicePreview:
|
|
3174
|
+
checkoutForm: f,
|
|
3175
|
+
invoicePreview: y,
|
|
3102
3176
|
invoicePreviewByBillingPeriod: r,
|
|
3103
|
-
trialInvoicePreview:
|
|
3177
|
+
trialInvoicePreview: g,
|
|
3104
3178
|
trialPeriod: h,
|
|
3105
|
-
authorizationContext:
|
|
3106
|
-
isPaid:
|
|
3179
|
+
authorizationContext: w,
|
|
3180
|
+
isPaid: j,
|
|
3107
3181
|
amount: H,
|
|
3108
|
-
loadInvoicePreview:
|
|
3109
|
-
updateInvoicePreviewOnBillingInformationChange:
|
|
3110
|
-
saveFormStateForRedirect:
|
|
3111
|
-
} =
|
|
3112
|
-
initialCountry: (
|
|
3113
|
-
initialEmail: (
|
|
3114
|
-
subscriptionId:
|
|
3115
|
-
enabledPricingIds: (
|
|
3116
|
-
}),
|
|
3117
|
-
var
|
|
3118
|
-
await
|
|
3119
|
-
},
|
|
3120
|
-
|
|
3121
|
-
},
|
|
3122
|
-
() =>
|
|
3123
|
-
),
|
|
3124
|
-
() =>
|
|
3125
|
-
),
|
|
3126
|
-
get: () =>
|
|
3127
|
-
set: (
|
|
3128
|
-
|
|
3182
|
+
loadInvoicePreview: Y,
|
|
3183
|
+
updateInvoicePreviewOnBillingInformationChange: G,
|
|
3184
|
+
saveFormStateForRedirect: ae
|
|
3185
|
+
} = xo({
|
|
3186
|
+
initialCountry: (pt = a.configuration) == null ? void 0 : pt.countryCode,
|
|
3187
|
+
initialEmail: (mt = a.configuration) == null ? void 0 : mt.email,
|
|
3188
|
+
subscriptionId: k,
|
|
3189
|
+
enabledPricingIds: (gt = a.configuration) == null ? void 0 : gt.enabledPricingIds
|
|
3190
|
+
}), Z = V(!1), re = async () => {
|
|
3191
|
+
var D;
|
|
3192
|
+
await f.validation.value.$validate(), !f.validation.value.$invalid && (Z.value = !0, ae(), (D = u.value) == null || D.submit());
|
|
3193
|
+
}, ne = () => {
|
|
3194
|
+
Z.value = !1;
|
|
3195
|
+
}, $ = async () => (await f.validation.value.$validate(), !f.validation.value.$invalid), ie = b(() => !!g.value), J = b(
|
|
3196
|
+
() => y.value ? Zo(y.value) : !1
|
|
3197
|
+
), ee = b(
|
|
3198
|
+
() => f.form.value.country && ["US", "CA"].includes(f.form.value.country) || !1
|
|
3199
|
+
), oe = b({
|
|
3200
|
+
get: () => f.form.value.enabledPricingIds ?? [],
|
|
3201
|
+
set: (D) => {
|
|
3202
|
+
f.form.value.enabledPricingIds = D;
|
|
3129
3203
|
}
|
|
3130
|
-
}),
|
|
3131
|
-
() =>
|
|
3132
|
-
pricingPlanScheduleInfos:
|
|
3204
|
+
}), ue = b(
|
|
3205
|
+
() => P.value ? Ne({
|
|
3206
|
+
pricingPlanScheduleInfos: P.value.pricing_plan_schedule_infos,
|
|
3133
3207
|
type: "DEFAULT"
|
|
3134
3208
|
}) : void 0
|
|
3135
|
-
),
|
|
3136
|
-
var
|
|
3137
|
-
if (!
|
|
3209
|
+
), de = b(() => {
|
|
3210
|
+
var S, z;
|
|
3211
|
+
if (!P.value)
|
|
3138
3212
|
return;
|
|
3139
|
-
const
|
|
3140
|
-
return
|
|
3141
|
-
country:
|
|
3142
|
-
pricingCurrencySettings:
|
|
3143
|
-
fallbackCurrency:
|
|
3213
|
+
const D = (z = (S = ue.value) == null ? void 0 : S.pricing_plan_version) == null ? void 0 : z.pricing_currency_settings;
|
|
3214
|
+
return $t({
|
|
3215
|
+
country: f.form.value.country,
|
|
3216
|
+
pricingCurrencySettings: D,
|
|
3217
|
+
fallbackCurrency: P.value.billing_currency
|
|
3144
3218
|
});
|
|
3145
|
-
}),
|
|
3146
|
-
if (!
|
|
3219
|
+
}), pe = b(() => {
|
|
3220
|
+
if (!ue.value || !P.value)
|
|
3147
3221
|
return /* @__PURE__ */ new Set();
|
|
3148
|
-
const
|
|
3149
|
-
pricingPlanScheduleInfo:
|
|
3150
|
-
}),
|
|
3151
|
-
return
|
|
3152
|
-
|
|
3153
|
-
}),
|
|
3154
|
-
}),
|
|
3222
|
+
const D = mi({
|
|
3223
|
+
pricingPlanScheduleInfo: ue.value
|
|
3224
|
+
}), S = de.value, z = P.value.billing_period, X = /* @__PURE__ */ new Set();
|
|
3225
|
+
return D.forEach((K, me) => {
|
|
3226
|
+
S && K.currency !== S || z && K.billingPeriod && (K.billingPeriod.type !== z.type || K.billingPeriod.value !== z.value) || X.add(me);
|
|
3227
|
+
}), X;
|
|
3228
|
+
}), Ee = b({
|
|
3229
|
+
get: () => {
|
|
3230
|
+
const D = f.form.value.seatsValues ?? [], S = pe.value;
|
|
3231
|
+
return S.size ? D.filter(({ pricing_item_config_id: z }) => S.has(z)) : D;
|
|
3232
|
+
},
|
|
3233
|
+
set: (D) => {
|
|
3234
|
+
const S = f.form.value.seatsValues ?? [], z = pe.value;
|
|
3235
|
+
if (!z.size) {
|
|
3236
|
+
f.form.value.seatsValues = D;
|
|
3237
|
+
return;
|
|
3238
|
+
}
|
|
3239
|
+
const X = S.filter(
|
|
3240
|
+
({ pricing_item_config_id: K }) => !z.has(K)
|
|
3241
|
+
);
|
|
3242
|
+
f.form.value.seatsValues = X.concat(D);
|
|
3243
|
+
}
|
|
3244
|
+
}), Ce = b({
|
|
3155
3245
|
get: () => {
|
|
3156
|
-
const
|
|
3157
|
-
return
|
|
3246
|
+
const D = f.form.value.unitsValues ?? [], S = pe.value;
|
|
3247
|
+
return S.size ? D.filter(({ pricing_item_config_id: z }) => S.has(z)) : D;
|
|
3158
3248
|
},
|
|
3159
|
-
set: (
|
|
3160
|
-
const
|
|
3161
|
-
if (!
|
|
3162
|
-
|
|
3249
|
+
set: (D) => {
|
|
3250
|
+
const S = f.form.value.unitsValues ?? [], z = pe.value;
|
|
3251
|
+
if (!z.size) {
|
|
3252
|
+
f.form.value.unitsValues = D;
|
|
3163
3253
|
return;
|
|
3164
3254
|
}
|
|
3165
|
-
const
|
|
3166
|
-
({ pricing_item_config_id:
|
|
3255
|
+
const X = S.filter(
|
|
3256
|
+
({ pricing_item_config_id: K }) => !z.has(K)
|
|
3167
3257
|
);
|
|
3168
|
-
|
|
3258
|
+
f.form.value.unitsValues = X.concat(D);
|
|
3169
3259
|
}
|
|
3170
|
-
}),
|
|
3171
|
-
var
|
|
3172
|
-
return
|
|
3260
|
+
}), ke = b(() => {
|
|
3261
|
+
var D, S, z, X, K;
|
|
3262
|
+
return g.value ? v(
|
|
3173
3263
|
{
|
|
3174
3264
|
defaultMessage: "{discounted_amount} for {trial_period}, then {subscription_amount}/{billing_period} until canceled, starting {start_date, date, ::MMMMd}.",
|
|
3175
3265
|
id: "checkout.agreement.trial",
|
|
3176
3266
|
description: "The agreement for the trial period"
|
|
3177
3267
|
},
|
|
3178
3268
|
{
|
|
3179
|
-
discounted_amount:
|
|
3269
|
+
discounted_amount: g.value.tax_summary.total_amount.quantity === "0.00" ? v({
|
|
3180
3270
|
defaultMessage: "Free",
|
|
3181
3271
|
id: "checkout.agreement.trial.free",
|
|
3182
3272
|
description: "The free amount for the trial period"
|
|
3183
|
-
}) :
|
|
3273
|
+
}) : Ie(g.value.tax_summary.total_amount),
|
|
3184
3274
|
trial_period: A(h.value, { short: !0 }),
|
|
3185
|
-
subscription_amount:
|
|
3186
|
-
((
|
|
3275
|
+
subscription_amount: Ie(
|
|
3276
|
+
((D = y.value) == null ? void 0 : D.tax_summary.total_amount) ?? {
|
|
3187
3277
|
quantity: "0.00",
|
|
3188
3278
|
currency: "EUR"
|
|
3189
3279
|
}
|
|
3190
3280
|
),
|
|
3191
3281
|
billing_period: A(
|
|
3192
|
-
((
|
|
3282
|
+
((S = y.value) == null ? void 0 : S.billing_period) ?? { type: "MONTH", value: 1 },
|
|
3193
3283
|
{ short: !0, singular: !0, hideValueForExactPeriods: !0 }
|
|
3194
3284
|
),
|
|
3195
3285
|
// @ts-expect-error formatjs does not support this type yet
|
|
3196
|
-
start_date: new Date(
|
|
3286
|
+
start_date: new Date(Pe.value)
|
|
3197
3287
|
}
|
|
3198
|
-
) :
|
|
3288
|
+
) : v(
|
|
3199
3289
|
{
|
|
3200
3290
|
defaultMessage: "{subscription_amount}/{billing_period} until canceled, starting {start_date, date, long}.",
|
|
3201
3291
|
id: "checkout.agreement.subscription",
|
|
3202
3292
|
description: "The agreement for the subscription"
|
|
3203
3293
|
},
|
|
3204
3294
|
{
|
|
3205
|
-
subscription_amount: (
|
|
3295
|
+
subscription_amount: (z = y.value) != null && z.tax_summary.total_amount ? Ie((X = y.value) == null ? void 0 : X.tax_summary.total_amount) : "",
|
|
3206
3296
|
billing_period: A(
|
|
3207
|
-
((
|
|
3297
|
+
((K = y.value) == null ? void 0 : K.billing_period) ?? { type: "MONTH", value: 1 },
|
|
3208
3298
|
{ short: !0, singular: !0, hideValueForExactPeriods: !0 }
|
|
3209
3299
|
),
|
|
3210
3300
|
// @ts-expect-error formatjs does not support this type yet
|
|
3211
|
-
start_date: new Date(
|
|
3301
|
+
start_date: new Date(Pe.value)
|
|
3212
3302
|
}
|
|
3213
3303
|
);
|
|
3214
|
-
}),
|
|
3215
|
-
var
|
|
3216
|
-
if (!
|
|
3304
|
+
}), xe = b(() => {
|
|
3305
|
+
var S;
|
|
3306
|
+
if (!y.value)
|
|
3217
3307
|
return;
|
|
3218
|
-
const
|
|
3219
|
-
subscription:
|
|
3220
|
-
fallback:
|
|
3308
|
+
const D = Ai({
|
|
3309
|
+
subscription: P.value,
|
|
3310
|
+
fallback: v({
|
|
3221
3311
|
defaultMessage: "Subscription",
|
|
3222
3312
|
description: "The fallback name for when no subscription name can be determined",
|
|
3223
3313
|
id: "customer_overview.subscriptions_block.fallback_subscription_name"
|
|
3224
3314
|
})
|
|
3225
3315
|
});
|
|
3226
3316
|
return {
|
|
3227
|
-
description:
|
|
3317
|
+
description: D,
|
|
3228
3318
|
managementURL: "https://www.solvimon.com/account/billing",
|
|
3229
|
-
agreement:
|
|
3230
|
-
...
|
|
3319
|
+
agreement: ke.value,
|
|
3320
|
+
...g.value && h.value && {
|
|
3231
3321
|
trial: {
|
|
3232
|
-
label:
|
|
3322
|
+
label: v({
|
|
3233
3323
|
defaultMessage: "Trial",
|
|
3234
3324
|
id: "checkout.trial.label",
|
|
3235
3325
|
description: "The label of the trial"
|
|
3236
3326
|
}),
|
|
3237
|
-
amount:
|
|
3238
|
-
startDate:
|
|
3239
|
-
endDate:
|
|
3327
|
+
amount: g.value.tax_summary.total_amount,
|
|
3328
|
+
startDate: Ye.value ? new Date(Ye.value) : void 0,
|
|
3329
|
+
endDate: ot.value ? new Date(ot.value) : void 0
|
|
3240
3330
|
}
|
|
3241
3331
|
},
|
|
3242
3332
|
regular: {
|
|
3243
|
-
label:
|
|
3244
|
-
amount:
|
|
3245
|
-
startDate:
|
|
3246
|
-
interval: ((
|
|
3333
|
+
label: D,
|
|
3334
|
+
amount: y.value.tax_summary.total_amount,
|
|
3335
|
+
startDate: Pe.value ? new Date(Pe.value) : void 0,
|
|
3336
|
+
interval: ((S = P.value) == null ? void 0 : S.billing_period) ?? { type: "MONTH", value: 1 }
|
|
3247
3337
|
}
|
|
3248
3338
|
};
|
|
3249
|
-
}),
|
|
3250
|
-
const { country:
|
|
3251
|
-
|
|
3252
|
-
...
|
|
3253
|
-
...
|
|
3339
|
+
}), le = (D) => Ge(D), Yt = (D) => {
|
|
3340
|
+
const { country: S, ...z } = D;
|
|
3341
|
+
f.updateInitialState({
|
|
3342
|
+
...z,
|
|
3343
|
+
...S && le(S) ? { country: S } : {}
|
|
3254
3344
|
});
|
|
3255
|
-
},
|
|
3256
|
-
var
|
|
3257
|
-
const
|
|
3258
|
-
return
|
|
3259
|
-
}),
|
|
3260
|
-
var
|
|
3261
|
-
const
|
|
3262
|
-
return
|
|
3263
|
-
}),
|
|
3264
|
-
var
|
|
3265
|
-
const
|
|
3266
|
-
return
|
|
3267
|
-
}),
|
|
3268
|
-
applyPromotionCode:
|
|
3269
|
-
removePromotionCode:
|
|
3270
|
-
isPromotionCodePending:
|
|
3271
|
-
promotionCodeErrorMessage:
|
|
3272
|
-
} =
|
|
3273
|
-
checkoutForm:
|
|
3274
|
-
updateInvoicePreviewOnBillingInformationChange:
|
|
3275
|
-
formatErrorMessage: ({ action:
|
|
3345
|
+
}, Kt = b(() => !(C && x)), Ye = b(() => {
|
|
3346
|
+
var z, X, K;
|
|
3347
|
+
const D = (X = (z = g.value) == null ? void 0 : z.periods) == null ? void 0 : X[0], S = (K = Ke.value) == null ? void 0 : K.trialStartDate;
|
|
3348
|
+
return D != null && D.start_at ? new Date(D.start_at) : S;
|
|
3349
|
+
}), Ke = b(() => Pi(P.value)), ot = b(() => {
|
|
3350
|
+
var z, X, K;
|
|
3351
|
+
const D = (X = (z = g.value) == null ? void 0 : z.periods) == null ? void 0 : X[0], S = (K = Ke.value) == null ? void 0 : K.trialEndDate;
|
|
3352
|
+
return D != null && D.end_at ? new Date(D.end_at) : S;
|
|
3353
|
+
}), Pe = b(() => {
|
|
3354
|
+
var z, X, K;
|
|
3355
|
+
const D = (X = (z = y.value) == null ? void 0 : z.periods) == null ? void 0 : X[0], S = (K = Ke.value) == null ? void 0 : K.subscriptionStartDate;
|
|
3356
|
+
return D != null && D.start_at ? new Date(D.start_at) : S;
|
|
3357
|
+
}), Qt = b(() => !!(f.form.value.seatsValues && f.form.value.seatsValues.length > 0 || f.form.value.unitsValues && f.form.value.unitsValues.length > 0 || P.value && bo(P.value) || P.value && Io(P.value))), Le = V(null), {
|
|
3358
|
+
applyPromotionCode: nt,
|
|
3359
|
+
removePromotionCode: Ht,
|
|
3360
|
+
isPromotionCodePending: Zt,
|
|
3361
|
+
promotionCodeErrorMessage: Qe
|
|
3362
|
+
} = Lo({
|
|
3363
|
+
checkoutForm: f,
|
|
3364
|
+
updateInvoicePreviewOnBillingInformationChange: G,
|
|
3365
|
+
formatErrorMessage: ({ action: D }) => v(D === "apply" ? {
|
|
3276
3366
|
defaultMessage: "Promotion code could not be applied. Please try again.",
|
|
3277
3367
|
id: "checkout.promotion_code.apply_failed",
|
|
3278
3368
|
description: "Error message when applying a promotion code in checkout failed"
|
|
@@ -3282,66 +3372,66 @@ const rn = {
|
|
|
3282
3372
|
description: "Error message when removing a promotion code in checkout failed"
|
|
3283
3373
|
}),
|
|
3284
3374
|
onInvalidPromotionCode: () => {
|
|
3285
|
-
|
|
3375
|
+
Le.value = null;
|
|
3286
3376
|
},
|
|
3287
3377
|
onApplyError: () => {
|
|
3288
|
-
|
|
3378
|
+
Le.value = null;
|
|
3289
3379
|
}
|
|
3290
3380
|
});
|
|
3291
|
-
|
|
3292
|
-
subscription:
|
|
3293
|
-
promotionCode: (
|
|
3294
|
-
appliedPromotionCode:
|
|
3295
|
-
applyPromotionCode:
|
|
3381
|
+
wo({
|
|
3382
|
+
subscription: P,
|
|
3383
|
+
promotionCode: (yt = a.configuration) == null ? void 0 : yt.couponCode,
|
|
3384
|
+
appliedPromotionCode: Le,
|
|
3385
|
+
applyPromotionCode: nt
|
|
3296
3386
|
});
|
|
3297
|
-
const
|
|
3298
|
-
|
|
3299
|
-
},
|
|
3387
|
+
const at = () => {
|
|
3388
|
+
p && Ni(p);
|
|
3389
|
+
}, Xt = b(
|
|
3300
3390
|
() => {
|
|
3301
|
-
var
|
|
3302
|
-
return !((
|
|
3391
|
+
var D;
|
|
3392
|
+
return !((D = a.configuration) != null && D.onPaymentSuccess) && !!p;
|
|
3303
3393
|
}
|
|
3304
|
-
),
|
|
3305
|
-
var
|
|
3306
|
-
if (
|
|
3394
|
+
), Wt = () => {
|
|
3395
|
+
var D;
|
|
3396
|
+
if (j.value = !0, Qe.value = null, (D = a.configuration) != null && D.onPaymentSuccess) {
|
|
3307
3397
|
a.configuration.onPaymentSuccess();
|
|
3308
3398
|
return;
|
|
3309
3399
|
}
|
|
3310
|
-
if (
|
|
3311
|
-
|
|
3400
|
+
if (p) {
|
|
3401
|
+
at();
|
|
3312
3402
|
return;
|
|
3313
3403
|
}
|
|
3314
|
-
},
|
|
3315
|
-
|
|
3316
|
-
...
|
|
3317
|
-
billing_period:
|
|
3318
|
-
},
|
|
3404
|
+
}, rt = (D) => {
|
|
3405
|
+
P.value && (P.value = {
|
|
3406
|
+
...P.value,
|
|
3407
|
+
billing_period: D
|
|
3408
|
+
}, Y());
|
|
3319
3409
|
};
|
|
3320
|
-
return
|
|
3410
|
+
return Oe(() => {
|
|
3321
3411
|
l("ready");
|
|
3322
|
-
}), (
|
|
3412
|
+
}), (D, S) => m.value ? (_(), O(qo, {
|
|
3323
3413
|
key: 0,
|
|
3324
3414
|
class: "sv-checkout sv-root sv-screen sv-checkout--error"
|
|
3325
|
-
})) : (
|
|
3415
|
+
})) : (_(), O(t(Qi), {
|
|
3326
3416
|
key: 1,
|
|
3327
|
-
class:
|
|
3417
|
+
class: be(["sv-checkout sv-root sv-screen", { "sv-checkout--paid": t(j) }])
|
|
3328
3418
|
}, {
|
|
3329
3419
|
header: I(() => [
|
|
3330
|
-
|
|
3331
|
-
|
|
3420
|
+
T("div", kn, [
|
|
3421
|
+
E(fe, { class: "min-h-[52px] w-96" }, {
|
|
3332
3422
|
default: I(() => {
|
|
3333
|
-
var
|
|
3423
|
+
var z, X, K;
|
|
3334
3424
|
return [
|
|
3335
|
-
t(
|
|
3425
|
+
t(y) && t(P) && Pe.value ? (_(), O(Ho, {
|
|
3336
3426
|
key: 0,
|
|
3337
3427
|
class: "sv-checkout__title",
|
|
3338
|
-
"trial-start-date":
|
|
3428
|
+
"trial-start-date": Ye.value,
|
|
3339
3429
|
"trial-period": t(h),
|
|
3340
|
-
"subscription-start-date":
|
|
3341
|
-
"subscription-name": ((
|
|
3342
|
-
amount: (
|
|
3343
|
-
"billing-period": (
|
|
3344
|
-
"country-code": t(
|
|
3430
|
+
"subscription-start-date": Pe.value,
|
|
3431
|
+
"subscription-name": ((z = t(P)) == null ? void 0 : z.name) ?? "",
|
|
3432
|
+
amount: (X = t(y)) == null ? void 0 : X.invoice_amount_including_tax,
|
|
3433
|
+
"billing-period": (K = t(P)) == null ? void 0 : K.billing_period,
|
|
3434
|
+
"country-code": t(f).form.value.country
|
|
3345
3435
|
}, null, 8, ["trial-start-date", "trial-period", "subscription-start-date", "subscription-name", "amount", "billing-period", "country-code"])) : B("", !0)
|
|
3346
3436
|
];
|
|
3347
3437
|
}),
|
|
@@ -3350,79 +3440,82 @@ const rn = {
|
|
|
3350
3440
|
])
|
|
3351
3441
|
]),
|
|
3352
3442
|
content: I(() => {
|
|
3353
|
-
var
|
|
3443
|
+
var z, X, K;
|
|
3354
3444
|
return [
|
|
3355
|
-
t(
|
|
3445
|
+
t(j) ? (_(), O(Jo, {
|
|
3356
3446
|
key: 0,
|
|
3357
3447
|
class: "sv-checkout__completed-payment",
|
|
3358
|
-
onContinueToMerchant:
|
|
3359
|
-
})) : (
|
|
3360
|
-
t(
|
|
3448
|
+
onContinueToMerchant: at
|
|
3449
|
+
})) : (_(), W(_e, { key: 1 }, [
|
|
3450
|
+
t(P) && t(L) ? (_(), O(xt, {
|
|
3361
3451
|
key: 0,
|
|
3362
3452
|
class: "sv-checkout__mobile-order-summary",
|
|
3363
|
-
subscription: t(
|
|
3364
|
-
invoice: t(
|
|
3453
|
+
subscription: t(P),
|
|
3454
|
+
invoice: t(y),
|
|
3365
3455
|
"invoice-preview-by-billing-period": t(r),
|
|
3366
|
-
"trial-invoice": t(
|
|
3367
|
-
"enabled-pricing-ids":
|
|
3456
|
+
"trial-invoice": t(g),
|
|
3457
|
+
"enabled-pricing-ids": oe.value,
|
|
3368
3458
|
"trial-period": t(h),
|
|
3369
|
-
avatar: (
|
|
3370
|
-
"is-paid": t(
|
|
3371
|
-
"is-usage-based":
|
|
3372
|
-
"is-preview-and-payment-methods-pending": t(
|
|
3373
|
-
"country-code": t(
|
|
3459
|
+
avatar: (z = c.value) == null ? void 0 : z.avatar,
|
|
3460
|
+
"is-paid": t(j),
|
|
3461
|
+
"is-usage-based": J.value,
|
|
3462
|
+
"is-preview-and-payment-methods-pending": t(q) || t(te),
|
|
3463
|
+
"country-code": t(f).form.value.country,
|
|
3374
3464
|
collapsible: "collapsed",
|
|
3375
3465
|
variant: "products-inline",
|
|
3376
|
-
onBillingPeriodChange:
|
|
3466
|
+
onBillingPeriodChange: rt
|
|
3377
3467
|
}, null, 8, ["subscription", "invoice", "invoice-preview-by-billing-period", "trial-invoice", "enabled-pricing-ids", "trial-period", "avatar", "is-paid", "is-usage-based", "is-preview-and-payment-methods-pending", "country-code"])) : B("", !0),
|
|
3378
|
-
|
|
3468
|
+
Qt.value && t(P) ? (_(), O(t(n), {
|
|
3379
3469
|
key: 1,
|
|
3380
|
-
"seats-values":
|
|
3381
|
-
"onUpdate:seatsValues":
|
|
3382
|
-
"
|
|
3383
|
-
"onUpdate:
|
|
3470
|
+
"seats-values": Ee.value,
|
|
3471
|
+
"onUpdate:seatsValues": S[0] || (S[0] = (me) => Ee.value = me),
|
|
3472
|
+
"units-values": Ce.value,
|
|
3473
|
+
"onUpdate:unitsValues": S[1] || (S[1] = (me) => Ce.value = me),
|
|
3474
|
+
"enabled-pricing-ids": oe.value,
|
|
3475
|
+
"onUpdate:enabledPricingIds": S[2] || (S[2] = (me) => oe.value = me),
|
|
3384
3476
|
class: "sv-checkout__plan-customization",
|
|
3385
|
-
subscription: t(
|
|
3386
|
-
"initial-seats-values": (
|
|
3387
|
-
"
|
|
3388
|
-
|
|
3389
|
-
|
|
3390
|
-
|
|
3477
|
+
subscription: t(P),
|
|
3478
|
+
"initial-seats-values": (X = t(f).initialState) == null ? void 0 : X.value.seatsValues,
|
|
3479
|
+
"initial-units-values": (K = t(f).initialState) == null ? void 0 : K.value.unitsValues,
|
|
3480
|
+
"billing-period": t(P).billing_period,
|
|
3481
|
+
currency: de.value
|
|
3482
|
+
}, null, 8, ["seats-values", "units-values", "enabled-pricing-ids", "subscription", "initial-seats-values", "initial-units-values", "billing-period", "currency"])) : B("", !0),
|
|
3483
|
+
t(f).form.value.country && t(H) && xe.value ? (_(), O(Dn, {
|
|
3391
3484
|
key: 2,
|
|
3392
3485
|
class: "sv-checkout__express-payment-methods",
|
|
3393
3486
|
amount: t(H),
|
|
3394
|
-
"country-code": t(
|
|
3395
|
-
locale: t(
|
|
3396
|
-
"payment-methods-options-response": t(
|
|
3397
|
-
"billing-information":
|
|
3398
|
-
"on-billing-information-change": t(
|
|
3399
|
-
onUpdateBillingInformation:
|
|
3487
|
+
"country-code": t(f).form.value.country,
|
|
3488
|
+
locale: t(M),
|
|
3489
|
+
"payment-methods-options-response": t(R) ?? [],
|
|
3490
|
+
"billing-information": xe.value,
|
|
3491
|
+
"on-billing-information-change": t(G),
|
|
3492
|
+
onUpdateBillingInformation: Yt
|
|
3400
3493
|
}, null, 8, ["amount", "country-code", "locale", "payment-methods-options-response", "billing-information", "on-billing-information-change"])) : B("", !0),
|
|
3401
|
-
|
|
3402
|
-
modelValue: t(
|
|
3403
|
-
"onUpdate:modelValue":
|
|
3494
|
+
E(Go, {
|
|
3495
|
+
modelValue: t(f).form.value,
|
|
3496
|
+
"onUpdate:modelValue": S[3] || (S[3] = (me) => t(f).form.value = me),
|
|
3404
3497
|
class: "sv-checkout__customer-form",
|
|
3405
|
-
validation: t(
|
|
3406
|
-
"read-only-email": t(
|
|
3407
|
-
"show-customer-info-on-top":
|
|
3408
|
-
"is-billing-information-mandatory":
|
|
3409
|
-
"get-is-field-required": t(
|
|
3410
|
-
"read-only": t(
|
|
3498
|
+
validation: t(f).validation,
|
|
3499
|
+
"read-only-email": t(C),
|
|
3500
|
+
"show-customer-info-on-top": Kt.value || t(j),
|
|
3501
|
+
"is-billing-information-mandatory": ee.value,
|
|
3502
|
+
"get-is-field-required": t(f).getIsFieldRequired,
|
|
3503
|
+
"read-only": t(j)
|
|
3411
3504
|
}, null, 8, ["modelValue", "validation", "read-only-email", "show-customer-info-on-top", "is-billing-information-mandatory", "get-is-field-required", "read-only"]),
|
|
3412
|
-
|
|
3413
|
-
|
|
3505
|
+
T("div", zn, [
|
|
3506
|
+
E(fe, {
|
|
3414
3507
|
variant: "section",
|
|
3415
3508
|
class: "min-h-[130px]"
|
|
3416
3509
|
}, {
|
|
3417
3510
|
default: I(() => [
|
|
3418
|
-
!t(
|
|
3419
|
-
|
|
3511
|
+
!t(q) || t(q) && t(R).length > 0 ? (_(), W("div", jn, [
|
|
3512
|
+
E(t(se), {
|
|
3420
3513
|
variant: "heading-3",
|
|
3421
3514
|
tag: "h2",
|
|
3422
3515
|
class: "sv-checkout__payment-methods-title mb-2"
|
|
3423
3516
|
}, {
|
|
3424
3517
|
default: I(() => [
|
|
3425
|
-
|
|
3518
|
+
F(U(t(v)({
|
|
3426
3519
|
defaultMessage: "Payment method",
|
|
3427
3520
|
id: "checkout.payment_method_block.title",
|
|
3428
3521
|
description: "The title of the payment method block in the checkout form"
|
|
@@ -3430,35 +3523,35 @@ const rn = {
|
|
|
3430
3523
|
]),
|
|
3431
3524
|
_: 1
|
|
3432
3525
|
}),
|
|
3433
|
-
t(
|
|
3526
|
+
t(f).form.value.country ? t(Q) ? (_(), O(Ze, {
|
|
3434
3527
|
key: 1,
|
|
3435
3528
|
class: "sv-checkout__payment-methods-error",
|
|
3436
3529
|
icon: "error"
|
|
3437
3530
|
}, {
|
|
3438
3531
|
title: I(() => [
|
|
3439
|
-
|
|
3532
|
+
F(U(t(v)({
|
|
3440
3533
|
defaultMessage: "Could not load payment methods",
|
|
3441
3534
|
id: "checkout.payment_method_block.load_failed_title",
|
|
3442
3535
|
description: "The title shown when the payment methods failed to load"
|
|
3443
3536
|
})), 1)
|
|
3444
3537
|
]),
|
|
3445
3538
|
message: I(() => [
|
|
3446
|
-
|
|
3539
|
+
F(U(t(v)({
|
|
3447
3540
|
defaultMessage: "Check your connection and try again.",
|
|
3448
3541
|
id: "checkout.payment_method_block.load_failed_message",
|
|
3449
3542
|
description: "The message shown when the payment methods failed to load"
|
|
3450
3543
|
})), 1)
|
|
3451
3544
|
]),
|
|
3452
3545
|
action: I(() => [
|
|
3453
|
-
|
|
3546
|
+
E(t(Ae), {
|
|
3454
3547
|
type: "button",
|
|
3455
3548
|
intent: "secondary",
|
|
3456
3549
|
size: "sm",
|
|
3457
3550
|
class: "sv-action sv-action--secondary sv-checkout__payment-methods-retry",
|
|
3458
|
-
onClick: t(
|
|
3551
|
+
onClick: t(s)
|
|
3459
3552
|
}, {
|
|
3460
3553
|
default: I(() => [
|
|
3461
|
-
|
|
3554
|
+
F(U(t(v)({
|
|
3462
3555
|
defaultMessage: "Try again",
|
|
3463
3556
|
id: "checkout.payment_method_block.load_failed_retry_button.label",
|
|
3464
3557
|
description: "The label of the button that loads the payment methods again"
|
|
@@ -3468,54 +3561,54 @@ const rn = {
|
|
|
3468
3561
|
}, 8, ["onClick"])
|
|
3469
3562
|
]),
|
|
3470
3563
|
_: 1
|
|
3471
|
-
})) : t(
|
|
3564
|
+
})) : t(R).length === 0 ? (_(), O(Ze, {
|
|
3472
3565
|
key: 2,
|
|
3473
3566
|
class: "sv-checkout__payment-methods-empty",
|
|
3474
3567
|
icon: "credit_card_off"
|
|
3475
3568
|
}, {
|
|
3476
3569
|
title: I(() => [
|
|
3477
|
-
|
|
3570
|
+
F(U(t(v)({
|
|
3478
3571
|
defaultMessage: "No payment methods available",
|
|
3479
3572
|
id: "checkout.payment_method_block.no_payment_methods_available_title",
|
|
3480
3573
|
description: "The title shown when there are no available payment methods"
|
|
3481
3574
|
})), 1)
|
|
3482
3575
|
]),
|
|
3483
3576
|
_: 1
|
|
3484
|
-
})) : t(H) && t(
|
|
3485
|
-
|
|
3486
|
-
class:
|
|
3577
|
+
})) : t(H) && t(f).form.value.country ? (_(), W("div", Rn, [
|
|
3578
|
+
T("div", {
|
|
3579
|
+
class: be({ "pointer-events-none opacity-60": Z.value })
|
|
3487
3580
|
}, [
|
|
3488
|
-
|
|
3581
|
+
E(t(o), {
|
|
3489
3582
|
ref_key: "paymentIntegrationFormRef",
|
|
3490
|
-
ref:
|
|
3491
|
-
"country-code": t(
|
|
3492
|
-
context: t(
|
|
3583
|
+
ref: u,
|
|
3584
|
+
"country-code": t(f).form.value.country,
|
|
3585
|
+
context: t(w),
|
|
3493
3586
|
amount: t(H),
|
|
3494
|
-
email: t(
|
|
3587
|
+
email: t(f).form.value.email,
|
|
3495
3588
|
variant: "AUTHORIZE",
|
|
3496
|
-
"payment-method-options": t(
|
|
3497
|
-
"validate-on-submit":
|
|
3498
|
-
"redirects-on-success":
|
|
3589
|
+
"payment-method-options": t(R) ?? [],
|
|
3590
|
+
"validate-on-submit": $,
|
|
3591
|
+
"redirects-on-success": Xt.value,
|
|
3499
3592
|
"force-store-payment-method": "",
|
|
3500
|
-
onPaymentSuccess:
|
|
3501
|
-
onPaymentFailed:
|
|
3502
|
-
onReady:
|
|
3593
|
+
onPaymentSuccess: Wt,
|
|
3594
|
+
onPaymentFailed: ne,
|
|
3595
|
+
onReady: S[4] || (S[4] = (me) => l("ready"))
|
|
3503
3596
|
}, null, 8, ["country-code", "context", "amount", "email", "payment-method-options", "redirects-on-success"])
|
|
3504
3597
|
], 2)
|
|
3505
|
-
])) : B("", !0) : (
|
|
3598
|
+
])) : B("", !0) : (_(), O(Ze, {
|
|
3506
3599
|
key: 0,
|
|
3507
3600
|
class: "sv-checkout__payment-methods-empty",
|
|
3508
3601
|
icon: "captive_portal"
|
|
3509
3602
|
}, {
|
|
3510
3603
|
title: I(() => [
|
|
3511
|
-
|
|
3604
|
+
F(U(t(v)({
|
|
3512
3605
|
defaultMessage: "Select your billing country",
|
|
3513
3606
|
id: "checkout.payment_method_block.no_country_selected_title",
|
|
3514
3607
|
description: "The title shown when no country is selected"
|
|
3515
3608
|
})), 1)
|
|
3516
3609
|
]),
|
|
3517
3610
|
message: I(() => [
|
|
3518
|
-
|
|
3611
|
+
F(U(t(v)({
|
|
3519
3612
|
defaultMessage: "Payment methods will be shown after you select the billing country.",
|
|
3520
3613
|
id: "checkout.payment_method_block.no_country_selected_message",
|
|
3521
3614
|
description: "The message shown when no country is selected"
|
|
@@ -3532,65 +3625,65 @@ const rn = {
|
|
|
3532
3625
|
];
|
|
3533
3626
|
}),
|
|
3534
3627
|
aside: I(() => [
|
|
3535
|
-
|
|
3536
|
-
|
|
3628
|
+
T("div", Bn, [
|
|
3629
|
+
E(fe, {
|
|
3537
3630
|
variant: "section",
|
|
3538
3631
|
class: "min-h-[220px]"
|
|
3539
3632
|
}, {
|
|
3540
3633
|
default: I(() => {
|
|
3541
|
-
var
|
|
3634
|
+
var z;
|
|
3542
3635
|
return [
|
|
3543
|
-
t(
|
|
3636
|
+
t(P) && t(y) ? (_(), O(xt, {
|
|
3544
3637
|
key: 0,
|
|
3545
|
-
subscription: t(
|
|
3546
|
-
invoice: t(
|
|
3638
|
+
subscription: t(P),
|
|
3639
|
+
invoice: t(y),
|
|
3547
3640
|
"invoice-preview-by-billing-period": t(r),
|
|
3548
|
-
"trial-invoice": t(
|
|
3549
|
-
"enabled-pricing-ids":
|
|
3641
|
+
"trial-invoice": t(g),
|
|
3642
|
+
"enabled-pricing-ids": oe.value,
|
|
3550
3643
|
"trial-period": t(h),
|
|
3551
|
-
"country-code": t(
|
|
3552
|
-
avatar: (
|
|
3553
|
-
"is-paid": t(
|
|
3554
|
-
"is-usage-based":
|
|
3555
|
-
"is-preview-and-payment-methods-pending": t(
|
|
3556
|
-
onBillingPeriodChange:
|
|
3644
|
+
"country-code": t(f).form.value.country,
|
|
3645
|
+
avatar: (z = c.value) == null ? void 0 : z.avatar,
|
|
3646
|
+
"is-paid": t(j),
|
|
3647
|
+
"is-usage-based": J.value,
|
|
3648
|
+
"is-preview-and-payment-methods-pending": t(q) || t(te),
|
|
3649
|
+
onBillingPeriodChange: rt
|
|
3557
3650
|
}, null, 8, ["subscription", "invoice", "invoice-preview-by-billing-period", "trial-invoice", "enabled-pricing-ids", "trial-period", "country-code", "avatar", "is-paid", "is-usage-based", "is-preview-and-payment-methods-pending"])) : B("", !0)
|
|
3558
3651
|
];
|
|
3559
3652
|
}),
|
|
3560
3653
|
_: 1
|
|
3561
3654
|
})
|
|
3562
3655
|
]),
|
|
3563
|
-
t(
|
|
3564
|
-
|
|
3656
|
+
t(j) ? B("", !0) : (_(), W(_e, { key: 0 }, [
|
|
3657
|
+
E(On, {
|
|
3565
3658
|
class: "sv-checkout__promotion-code",
|
|
3566
|
-
"promotion-code":
|
|
3567
|
-
"onUpdate:appliedCode":
|
|
3568
|
-
onRemove: t(
|
|
3569
|
-
onApply: t(
|
|
3659
|
+
"promotion-code": Le.value,
|
|
3660
|
+
"onUpdate:appliedCode": S[5] || (S[5] = (z) => Le.value = z),
|
|
3661
|
+
onRemove: t(Ht),
|
|
3662
|
+
onApply: t(nt)
|
|
3570
3663
|
}, null, 8, ["promotion-code", "onRemove", "onApply"]),
|
|
3571
|
-
t(
|
|
3664
|
+
t(Qe) ? (_(), O(t(ri), {
|
|
3572
3665
|
key: 0,
|
|
3573
3666
|
class: "sv-checkout__promotion-error mt-2",
|
|
3574
|
-
title: t(
|
|
3667
|
+
title: t(Qe)
|
|
3575
3668
|
}, null, 8, ["title"])) : B("", !0),
|
|
3576
|
-
|
|
3577
|
-
|
|
3669
|
+
T("div", $n, [
|
|
3670
|
+
E(fe, { class: "sv-checkout__submit-skeleton min-h-[44px]" }, {
|
|
3578
3671
|
default: I(() => [
|
|
3579
|
-
t(
|
|
3672
|
+
t(y) ? (_(), O(t(Ae), {
|
|
3580
3673
|
key: 0,
|
|
3581
3674
|
type: "button",
|
|
3582
3675
|
size: "lg",
|
|
3583
3676
|
class: "sv-action sv-action--primary sv-action--full-width sv-checkout__submit w-full",
|
|
3584
|
-
disabled: t(
|
|
3585
|
-
loading:
|
|
3586
|
-
onClick:
|
|
3677
|
+
disabled: t(Zt) || t(R).length === 0 || Z.value,
|
|
3678
|
+
loading: Z.value,
|
|
3679
|
+
onClick: re
|
|
3587
3680
|
}, {
|
|
3588
3681
|
default: I(() => [
|
|
3589
|
-
|
|
3682
|
+
F(U(ie.value ? t(v)({
|
|
3590
3683
|
defaultMessage: "Start trial",
|
|
3591
3684
|
id: "checkout.pay_and_subscribe_button_trial.label",
|
|
3592
3685
|
description: "The label of the start trial button in the checkout form"
|
|
3593
|
-
}) : t(
|
|
3686
|
+
}) : t(v)({
|
|
3594
3687
|
defaultMessage: "Pay and subscribe",
|
|
3595
3688
|
id: "checkout.pay_and_subscribe_button.label",
|
|
3596
3689
|
description: "The label of the pay and subscribe button in the checkout form"
|
|
@@ -3601,14 +3694,14 @@ const rn = {
|
|
|
3601
3694
|
]),
|
|
3602
3695
|
_: 1
|
|
3603
3696
|
}),
|
|
3604
|
-
|
|
3697
|
+
E(Vi, { "payment-method-options": t(R) }, null, 8, ["payment-method-options"])
|
|
3605
3698
|
])
|
|
3606
3699
|
], 64))
|
|
3607
3700
|
]),
|
|
3608
3701
|
_: 1
|
|
3609
3702
|
}, 8, ["class"]));
|
|
3610
3703
|
}
|
|
3611
|
-
}),
|
|
3704
|
+
}), Vn = /* @__PURE__ */ ce({
|
|
3612
3705
|
__name: "Checkout.entry",
|
|
3613
3706
|
props: {
|
|
3614
3707
|
environment: { type: String },
|
|
@@ -3629,31 +3722,31 @@ const rn = {
|
|
|
3629
3722
|
},
|
|
3630
3723
|
emits: ["error", "ready"],
|
|
3631
3724
|
setup(e, { emit: i }) {
|
|
3632
|
-
var
|
|
3633
|
-
const o =
|
|
3634
|
-
return (
|
|
3635
|
-
entry:
|
|
3725
|
+
var c;
|
|
3726
|
+
const o = Zi("checkout"), n = e, a = i, l = ((c = n.configuration) == null ? void 0 : c.couponCode) ?? Te("coupon_code") ?? void 0;
|
|
3727
|
+
return (m, u) => (_(), O(t(ni), {
|
|
3728
|
+
entry: m.$props,
|
|
3636
3729
|
"component-name": t(o),
|
|
3637
3730
|
"allowed-portal-types": ["INIT_PRICING_PLAN_SUBSCRIPTION"],
|
|
3638
|
-
onError:
|
|
3731
|
+
onError: u[1] || (u[1] = (N) => m.$emit("error", N))
|
|
3639
3732
|
}, {
|
|
3640
3733
|
default: I(() => {
|
|
3641
|
-
var
|
|
3734
|
+
var N, v, M, A, d;
|
|
3642
3735
|
return [
|
|
3643
|
-
|
|
3736
|
+
E(Un, {
|
|
3644
3737
|
configuration: {
|
|
3645
|
-
avatar: (
|
|
3646
|
-
email: (
|
|
3738
|
+
avatar: (v = (N = e.branding) == null ? void 0 : N.emblem) == null ? void 0 : v.public_url,
|
|
3739
|
+
email: (M = e.configuration) == null ? void 0 : M.email,
|
|
3647
3740
|
countryCode: (A = e.configuration) == null ? void 0 : A.countryCode,
|
|
3648
|
-
enabledPricingIds: (
|
|
3741
|
+
enabledPricingIds: (d = e.configuration) == null ? void 0 : d.enabledPricingIds,
|
|
3649
3742
|
couponCode: t(l)
|
|
3650
3743
|
},
|
|
3651
|
-
onReady:
|
|
3652
|
-
},
|
|
3653
|
-
|
|
3744
|
+
onReady: u[0] || (u[0] = (L) => a("ready"))
|
|
3745
|
+
}, Je({ _: 2 }, [
|
|
3746
|
+
m.$slots["terms-and-conditions"] ? {
|
|
3654
3747
|
name: "terms-and-conditions",
|
|
3655
3748
|
fn: I(() => [
|
|
3656
|
-
|
|
3749
|
+
We(m.$slots, "terms-and-conditions")
|
|
3657
3750
|
]),
|
|
3658
3751
|
key: "0"
|
|
3659
3752
|
} : void 0
|
|
@@ -3663,12 +3756,14 @@ const rn = {
|
|
|
3663
3756
|
_: 3
|
|
3664
3757
|
}, 8, ["entry", "component-name"]));
|
|
3665
3758
|
}
|
|
3666
|
-
}), { define:
|
|
3667
|
-
|
|
3759
|
+
}), { define: Sa } = ai(
|
|
3760
|
+
Vn,
|
|
3668
3761
|
"checkout"
|
|
3669
3762
|
);
|
|
3670
3763
|
export {
|
|
3671
|
-
|
|
3672
|
-
|
|
3673
|
-
|
|
3764
|
+
Ao as F,
|
|
3765
|
+
an as _,
|
|
3766
|
+
No as a,
|
|
3767
|
+
Sa as d,
|
|
3768
|
+
wa as g
|
|
3674
3769
|
};
|