@solvimon/solvimon-web 0.1.0-alpha.22 → 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.
Files changed (204) hide show
  1. package/README.md +3 -0
  2. package/dist/{AddPaymentMethodPane.vue_vue_type_script_setup_true_lang-DFv-awxb.mjs → AddPaymentMethodPane.vue_vue_type_script_setup_true_lang-B70SyWOB.mjs} +6 -6
  3. package/dist/{AddPaymentMethodPane.vue_vue_type_script_setup_true_lang-Co3XAxaY.js → AddPaymentMethodPane.vue_vue_type_script_setup_true_lang-jXClPW91.js} +1 -1
  4. package/dist/Alert.vue.es-RyK53a2P.js +1 -0
  5. package/dist/Alert.vue.es-lIiAWf2S.mjs +146 -0
  6. package/dist/{Avatar.vue.es-DNJ-jexx.mjs → Avatar.vue.es-2E3laNRb.mjs} +1 -1
  7. package/dist/{Avatar.vue.es-D42J_izE.js → Avatar.vue.es-DdJreyr_.js} +1 -1
  8. package/dist/{BillingInformation.vue_vue_type_script_setup_true_lang-BEVkWJXT.js → BillingInformation.vue_vue_type_script_setup_true_lang-ConpyC8n.js} +1 -1
  9. package/dist/{BillingInformation.vue_vue_type_script_setup_true_lang-D1uVidXk.mjs → BillingInformation.vue_vue_type_script_setup_true_lang-D5EoBLhj.mjs} +4 -4
  10. package/dist/{Button.vue.es-Dz-2L8dJ.mjs → Button.vue.es-BJEy-e9C.mjs} +1 -1
  11. package/dist/{Button.vue.es-M_jXZda4.js → Button.vue.es-CJNxYacb.js} +1 -1
  12. package/dist/Checkout.entry.ce-BfLlnQyb.js +1 -0
  13. package/dist/{Checkout.entry.ce-B5-0AM67.mjs → Checkout.entry.ce-CQkrWscC.mjs} +1095 -1073
  14. package/dist/{Chip.vue.es-DMK9C78d.mjs → Chip.vue.es-DGbc4L_D.mjs} +2 -2
  15. package/dist/{Chip.vue.es-G8doKsZb.js → Chip.vue.es-DLQ4QEPo.js} +1 -1
  16. package/dist/{ContextMenu.vue.es-B3Rz6Ojk.js → ContextMenu.vue.es-Bd2kmeVq.js} +1 -1
  17. package/dist/{ContextMenu.vue.es-CzkkNoJG.mjs → ContextMenu.vue.es-DL1M7pcr.mjs} +4 -4
  18. package/dist/{CustomerBillingInformation.vue.es-Db6bN2RZ.mjs → CustomerBillingInformation.vue.es-CE94ASC3.mjs} +2 -2
  19. package/dist/{CustomerBillingInformation.vue.es-BmtU9Pk0.js → CustomerBillingInformation.vue.es-hiFzB43w.js} +1 -1
  20. package/dist/{CustomerPaymentMethods.vue_vue_type_script_setup_true_lang-BGHaTx1A.js → CustomerPaymentMethods.vue_vue_type_script_setup_true_lang-BE21tqgW.js} +1 -1
  21. package/dist/{CustomerPaymentMethods.vue_vue_type_script_setup_true_lang-fESZVyPe.mjs → CustomerPaymentMethods.vue_vue_type_script_setup_true_lang-Bhih7rPR.mjs} +5 -5
  22. package/dist/{CustomerWalletBalances.vue_vue_type_script_setup_true_lang-DdMHG1_Y.mjs → CustomerWalletBalances.vue_vue_type_script_setup_true_lang-C5zc9n64.mjs} +15 -15
  23. package/dist/CustomerWalletBalances.vue_vue_type_script_setup_true_lang-D018AmFA.js +1 -0
  24. package/dist/{DividerText.vue.es-IK2fns6f.mjs → DividerText.vue.es-CFZUQ62L.mjs} +1 -1
  25. package/dist/{DividerText.vue.es-D-QxT2OD.js → DividerText.vue.es-CvCgHHXN.js} +1 -1
  26. package/dist/{EmptyStatePlaceholder.vue_vue_type_script_setup_true_lang-lhJnqrrh.mjs → EmptyStatePlaceholder.vue_vue_type_script_setup_true_lang-YcaBJDzx.mjs} +4 -4
  27. package/dist/{EmptyStatePlaceholder.vue_vue_type_script_setup_true_lang-CM_8Asmw.js → EmptyStatePlaceholder.vue_vue_type_script_setup_true_lang-jTJGN4jb.js} +1 -1
  28. package/dist/{ErrorNotification.vue.es-BGckEwHf.mjs → ErrorNotification.vue.es-B3mvv79S.mjs} +2 -2
  29. package/dist/ErrorNotification.vue.es-DI2B7WiR.js +1 -0
  30. package/dist/IconButton.vue.es-Dp8h4YOx.js +1 -0
  31. package/dist/IconButton.vue.es-GLcGhoHC.mjs +56 -0
  32. package/dist/{IconTitle.vue.es-BmX68uJx.mjs → IconTitle.vue.es-CzuPQtOX.mjs} +3 -3
  33. package/dist/{IconTitle.vue.es-CmR2xoeu.js → IconTitle.vue.es-DN9r6nfK.js} +1 -1
  34. package/dist/{Input.vue.es-BGPELaZU.mjs → Input.vue.es-5Cq8a7oH.mjs} +2 -2
  35. package/dist/{Input.vue.es-CTOrmrcB.js → Input.vue.es-DM81HeVv.js} +1 -1
  36. package/dist/{InvoiceDetailsBlock.vue_vue_type_script_setup_true_lang-CMEOOuSU.mjs → InvoiceDetailsBlock.vue_vue_type_script_setup_true_lang-D75LSIL8.mjs} +2 -2
  37. package/dist/{InvoiceDetailsBlock.vue_vue_type_script_setup_true_lang-bheNAKzK.js → InvoiceDetailsBlock.vue_vue_type_script_setup_true_lang-w8w52LcV.js} +1 -1
  38. package/dist/{InvoiceEntryView.vue_vue_type_script_setup_true_lang-Xo9BR6AD.js → InvoiceEntryView.vue_vue_type_script_setup_true_lang-DB5h39LA.js} +1 -1
  39. package/dist/{InvoiceEntryView.vue_vue_type_script_setup_true_lang-avhwysNq.mjs → InvoiceEntryView.vue_vue_type_script_setup_true_lang-dRLsZPNh.mjs} +2 -2
  40. package/dist/{InvoiceSummary.vue.es-BWLiwlNs.mjs → InvoiceSummary.vue.es-DbtqsTuP.mjs} +7 -7
  41. package/dist/{InvoiceSummary.vue.es-hpG8Tq1D.js → InvoiceSummary.vue.es-Qy99kLZs.js} +1 -1
  42. package/dist/{Modal.vue.es-BD4vUaOQ.js → Modal.vue.es-DgLl6XBV.js} +1 -1
  43. package/dist/{Modal.vue.es-B_G8NQS2.mjs → Modal.vue.es-Z2DWAN2u.mjs} +5 -5
  44. package/dist/PaymentErrorCard.vue_vue_type_script_setup_true_lang-DBm51C7c.js +1 -0
  45. package/dist/PaymentErrorCard.vue_vue_type_script_setup_true_lang-DYuFPIqs.mjs +294 -0
  46. package/dist/{PaymentFeedbackCard.vue_vue_type_script_setup_true_lang-DIJbzWMV.js → PaymentFeedbackCard.vue_vue_type_script_setup_true_lang-BNZ9-GW1.js} +1 -1
  47. package/dist/{PaymentFeedbackCard.vue_vue_type_script_setup_true_lang-DuorCFo9.mjs → PaymentFeedbackCard.vue_vue_type_script_setup_true_lang-CcdhYTB1.mjs} +3 -3
  48. package/dist/{PaymentHistoryBlock-ComJzB3H.mjs → PaymentHistoryBlock-CjP_514k.mjs} +1 -1
  49. package/dist/{PaymentHistoryBlock-DSHW_eW1.js → PaymentHistoryBlock-DS1j-8m-.js} +1 -1
  50. package/dist/{PaymentHistoryBlock.vue_vue_type_script_setup_true_lang-DUN0Hf2v.js → PaymentHistoryBlock.vue_vue_type_script_setup_true_lang-CSTfMB8U.js} +1 -1
  51. package/dist/{PaymentHistoryBlock.vue_vue_type_script_setup_true_lang-hjtksV2D.mjs → PaymentHistoryBlock.vue_vue_type_script_setup_true_lang-Dr2jtJhK.mjs} +4 -4
  52. package/dist/{PaymentIntegrationForm-CwfCLnKt.js → PaymentIntegrationForm-80b19Lkq.js} +1 -1
  53. package/dist/{PaymentIntegrationForm-CH5B6BY5.mjs → PaymentIntegrationForm-CpOZUf-W.mjs} +1 -1
  54. package/dist/{PaymentIntegrationForm.vue_vue_type_script_setup_true_lang-BqYk4_T9.mjs → PaymentIntegrationForm.vue_vue_type_script_setup_true_lang-BgztoQH5.mjs} +3 -3
  55. package/dist/{PaymentIntegrationForm.vue_vue_type_script_setup_true_lang-DzSQC951.js → PaymentIntegrationForm.vue_vue_type_script_setup_true_lang-DKXhthkA.js} +1 -1
  56. package/dist/{PaymentIntegrationFormAdyen-DfN7cPYZ.mjs → PaymentIntegrationFormAdyen-BQcgDcik.mjs} +281 -204
  57. package/dist/PaymentIntegrationFormAdyen-DElXsJ96.js +98 -0
  58. package/dist/PaymentIntegrationFormStripe-CMwLqOe6.js +102 -0
  59. package/dist/{PaymentIntegrationFormStripe-CBsXDuhy.mjs → PaymentIntegrationFormStripe-Dx1H3fZ2.mjs} +249 -178
  60. package/dist/{PaymentMethod.vue.es-DkQdPXfk.mjs → PaymentMethod.vue.es-EhRCfeax.mjs} +3 -3
  61. package/dist/{PaymentMethod.vue.es-D18g-QB4.js → PaymentMethod.vue.es-pLCCzVxN.js} +1 -1
  62. package/dist/{PaymentMethodForm-DK8ntFA0.js → PaymentMethodForm-Bw2e1tXo.js} +1 -1
  63. package/dist/{PaymentMethodForm-CpIZKfPH.mjs → PaymentMethodForm-D3OY8zK5.mjs} +1 -1
  64. package/dist/{PaymentMethodForm.vue_vue_type_script_setup_true_lang-D7fDguwa.js → PaymentMethodForm.vue_vue_type_script_setup_true_lang-DHXw6qD0.js} +1 -1
  65. package/dist/{PaymentMethodForm.vue_vue_type_script_setup_true_lang-C1tGJsay.mjs → PaymentMethodForm.vue_vue_type_script_setup_true_lang-vGprVPpn.mjs} +5 -5
  66. package/dist/{PaymentMethodsList.vue_vue_type_script_setup_true_lang-H3vrPllf.js → PaymentMethodsList.vue_vue_type_script_setup_true_lang-CdT1YyeU.js} +1 -1
  67. package/dist/{PaymentMethodsList.vue_vue_type_script_setup_true_lang-C6BcIkEV.mjs → PaymentMethodsList.vue_vue_type_script_setup_true_lang-D7b0HhDc.mjs} +6 -6
  68. package/dist/{PlanCustomizationEditor-0zCXN-cv.mjs → PlanCustomizationEditor-BQqkgmzL.mjs} +9 -9
  69. package/dist/PlanCustomizationEditor-RC8kj2rC.js +1 -0
  70. package/dist/{PricingGroupRangeInput.vue.es-QnpfHxaY.js → PricingGroupRangeInput.vue.es-ClkE98ML.js} +2 -2
  71. package/dist/{PricingGroupRangeInput.vue.es-8_5nfZDI.mjs → PricingGroupRangeInput.vue.es-DNsiUZyT.mjs} +4 -4
  72. package/dist/{PricingGroupSingleEditor.vue_vue_type_script_setup_true_lang-CGJhKKNL.js → PricingGroupSingleEditor.vue_vue_type_script_setup_true_lang-BJfQLRcS.js} +1 -1
  73. package/dist/{PricingGroupSingleEditor.vue_vue_type_script_setup_true_lang-t6h1j6WD.mjs → PricingGroupSingleEditor.vue_vue_type_script_setup_true_lang-CURXAgMT.mjs} +5 -5
  74. package/dist/RadioGroupExtended.vue.es-Dk9xdj76.js +1 -0
  75. package/dist/{RadioGroupExtended.vue.es-C92xlCFQ.mjs → RadioGroupExtended.vue.es-vUqn2ZUP.mjs} +3 -3
  76. package/dist/{Section.vue.es-DQ5H7mqW.mjs → Section.vue.es-C2_topx4.mjs} +1 -1
  77. package/dist/{Section.vue.es-Btff-cLY.js → Section.vue.es-Cybk1Nb8.js} +1 -1
  78. package/dist/{SecurePaymentsKPI.vue_vue_type_script_setup_true_lang-DKsunuGT.mjs → SecurePaymentsKPI.vue_vue_type_script_setup_true_lang-C9q_qwjt.mjs} +6 -6
  79. package/dist/{SecurePaymentsKPI.vue_vue_type_script_setup_true_lang-BfvX14E3.js → SecurePaymentsKPI.vue_vue_type_script_setup_true_lang-DIgVzXLg.js} +1 -1
  80. package/dist/{SubscriptionSchedules-Dc0rUnnf.mjs → SubscriptionSchedules-BlCU_xc5.mjs} +1 -1
  81. package/dist/{SubscriptionSchedules-pzNsego6.js → SubscriptionSchedules-CNTg_oRy.js} +1 -1
  82. package/dist/SubscriptionSchedules.vue_vue_type_script_setup_true_lang-6LbR_Vni.js +1 -0
  83. package/dist/{SubscriptionSchedules.vue_vue_type_script_setup_true_lang-Brs9qDs5.mjs → SubscriptionSchedules.vue_vue_type_script_setup_true_lang-Cf3Dy8Yn.mjs} +12 -12
  84. package/dist/{SubscriptionSummary.vue_vue_type_script_setup_true_lang-s5_uhyuB.js → SubscriptionSummary.vue_vue_type_script_setup_true_lang-BijBAdqp.js} +1 -1
  85. package/dist/{SubscriptionSummary.vue_vue_type_script_setup_true_lang-C1mkIPMr.mjs → SubscriptionSummary.vue_vue_type_script_setup_true_lang-CjzjchsS.mjs} +2 -2
  86. package/dist/{SubscriptionsList.vue_vue_type_script_setup_true_lang-DSoNs7Xx.mjs → SubscriptionsList.vue_vue_type_script_setup_true_lang-CxdrAanb.mjs} +6 -6
  87. package/dist/{SubscriptionsList.vue_vue_type_script_setup_true_lang-CFmCJK8M.js → SubscriptionsList.vue_vue_type_script_setup_true_lang-Dz4s3CH_.js} +1 -1
  88. package/dist/{TooltipParagraph.vue.es-CIedcXGT.mjs → TooltipParagraph.vue.es-Fu9Od3Vr.mjs} +1 -1
  89. package/dist/{TooltipParagraph.vue.es-BaqCDjl8.js → TooltipParagraph.vue.es-OX6bAWP9.js} +1 -1
  90. package/dist/{TrialChip.vue.es-BzNI94k0.js → TrialChip.vue.es-CbjdkR4i.js} +1 -1
  91. package/dist/{TrialChip.vue.es-DkBuMNr_.mjs → TrialChip.vue.es-c7tZOIW3.mjs} +2 -2
  92. package/dist/{cn.es-BGqYNPM3.mjs → cn.es-C8Ogac5T.mjs} +2 -2
  93. package/dist/{cn.es-CvmLj7KH.js → cn.es-lC4_Xd0R.js} +1 -1
  94. package/dist/components/BillingInformation/BillingInformation.cjs +1 -1
  95. package/dist/components/BillingInformation/BillingInformation.mjs +5 -5
  96. package/dist/components/BillingInformationForm/BillingInformationForm.cjs +1 -1
  97. package/dist/components/BillingInformationForm/BillingInformationForm.mjs +7 -7
  98. package/dist/components/CustomerPaymentMethods/CustomerPaymentMethods.cjs +1 -1
  99. package/dist/components/CustomerPaymentMethods/CustomerPaymentMethods.mjs +5 -5
  100. package/dist/components/Invoice/Invoice.cjs +1 -1
  101. package/dist/components/Invoice/Invoice.mjs +10 -10
  102. package/dist/components/InvoiceDetails/InvoiceDetails.cjs +1 -1
  103. package/dist/components/InvoiceDetails/InvoiceDetails.mjs +4 -4
  104. package/dist/components/InvoiceHeader/InvoiceHeader.cjs +1 -1
  105. package/dist/components/InvoiceHeader/InvoiceHeader.mjs +8 -8
  106. package/dist/components/InvoicesList/InvoicesList.cjs +1 -1
  107. package/dist/components/InvoicesList/InvoicesList.mjs +4 -4
  108. package/dist/components/PaymentHistory/PaymentHistory.cjs +1 -1
  109. package/dist/components/PaymentHistory/PaymentHistory.mjs +9 -9
  110. package/dist/components/PaymentMethodForm/PaymentMethodForm.cjs +1 -1
  111. package/dist/components/PaymentMethodForm/PaymentMethodForm.mjs +6 -6
  112. package/dist/components/SubscriptionSchedules/SubscriptionSchedules.cjs +1 -1
  113. package/dist/components/SubscriptionSchedules/SubscriptionSchedules.mjs +5 -5
  114. package/dist/components/SubscriptionsList/SubscriptionsList.cjs +1 -1
  115. package/dist/components/SubscriptionsList/SubscriptionsList.mjs +6 -6
  116. package/dist/components/WalletBalances/WalletBalances.cjs +1 -1
  117. package/dist/components/WalletBalances/WalletBalances.mjs +4 -4
  118. package/dist/core/index.cjs +1 -1
  119. package/dist/core/index.mjs +26 -23
  120. package/dist/{customElements-Vox1PB6G.js → customElements-BYIdPSzQ.js} +10 -10
  121. package/dist/{customElements-CSE7dwUr.mjs → customElements-Df6dGrN-.mjs} +354 -353
  122. package/dist/{customer-5krPxZ8i.mjs → customer-DmsKYpVi.mjs} +1 -1
  123. package/dist/{customer-Dsq-Moea.js → customer-DoLHZuMG.js} +1 -1
  124. package/dist/{de-DE-DsFtpLsx.mjs → de-DE-Bgm9bnmp.mjs} +19 -0
  125. package/dist/{de-DE-C3DzP1nj.js → de-DE-CAL9Mji2.js} +1 -1
  126. package/dist/{en-US-DvkvbV0p.mjs → en-US-E86eRIxh.mjs} +19 -0
  127. package/dist/{en-US-X_pSFsNm.js → en-US-_xe5H4TQ.js} +1 -1
  128. package/dist/index.cjs +1 -1
  129. package/dist/index.mjs +1 -1
  130. package/dist/{invoices-DRgfpkJ6.mjs → invoices-CrO6p4Ms.mjs} +1 -1
  131. package/dist/{invoices-xOV2YaEV.js → invoices-mw87cNTS.js} +1 -1
  132. package/dist/{it-IT-YBtHAao1.js → it-IT-QFQ1Ajbb.js} +1 -1
  133. package/dist/{it-IT-TE7oqvXa.mjs → it-IT-co1BfV5s.mjs} +21 -2
  134. package/dist/{nl-NL-C8wnyKju.js → nl-NL-CJXJC1bx.js} +1 -1
  135. package/dist/{nl-NL-Di3-JArV.mjs → nl-NL-Drv2E66B.mjs} +19 -0
  136. package/dist/paymentFailure-Bh60UhxA.mjs +47 -0
  137. package/dist/paymentFailure-Cki8c5BX.js +1 -0
  138. package/dist/{paymentMethods-PmkHYomw.mjs → paymentMethods-BNQbW_f1.mjs} +1 -1
  139. package/dist/{paymentMethods-CRDIw9lz.js → paymentMethods-CQdhZwq4.js} +1 -1
  140. package/dist/{payments-jAgXhdp_.js → payments-KTjVHqOa.js} +1 -1
  141. package/dist/{payments-Dvqh6CGW.mjs → payments-VS_N2xpJ.mjs} +1 -1
  142. package/dist/screens/Checkout/Checkout.cjs +1 -1
  143. package/dist/screens/Checkout/Checkout.mjs +2 -2
  144. package/dist/screens/CustomerOverview/CustomerOverview.cjs +1 -1
  145. package/dist/screens/CustomerOverview/CustomerOverview.mjs +20 -20
  146. package/dist/screens/PayInvoice/PayInvoice.cjs +1 -1
  147. package/dist/screens/PayInvoice/PayInvoice.mjs +12 -12
  148. package/dist/screens/PaymentMethodsManagement/PaymentMethodsManagement.cjs +1 -1
  149. package/dist/screens/PaymentMethodsManagement/PaymentMethodsManagement.mjs +10 -10
  150. package/dist/screens/SubscriptionDetails/SubscriptionDetails.cjs +1 -1
  151. package/dist/screens/SubscriptionDetails/SubscriptionDetails.mjs +20 -20
  152. package/dist/screens/SubscriptionManagement/SubscriptionManagement.cjs +1 -1
  153. package/dist/screens/SubscriptionManagement/SubscriptionManagement.mjs +19 -19
  154. package/dist/sessionReference-3h-6FdrC.mjs +43 -0
  155. package/dist/sessionReference-m_6Rp4X1.js +1 -0
  156. package/dist/subscriptions-Dugd-oZ1.js +1 -0
  157. package/dist/{subscriptions-XDyI2Cqm.mjs → subscriptions-U4xg2CO1.mjs} +2 -2
  158. package/dist/types/components/providers/LoggerProvider/LoggerProvider.lib.d.ts +2 -0
  159. package/dist/types/components/providers/LoggerProvider/LoggerProvider.types.d.ts +10 -1
  160. package/dist/types/types/errors.d.ts +5 -0
  161. package/dist/{useActionDispatchProvider-CNAuaHdm.js → useActionDispatchProvider-CTyDGRX8.js} +1 -1
  162. package/dist/{useActionDispatchProvider-B8-oycQk.mjs → useActionDispatchProvider-DyQbRCxR.mjs} +1 -1
  163. package/dist/{useCustomer-DSx-wN-6.js → useCustomer-BXI5Vmit.js} +1 -1
  164. package/dist/{useCustomer-CP8eWUZV.mjs → useCustomer-dcmU1539.mjs} +1 -1
  165. package/dist/{useCustomerFormLabels-DW6jnDYH.mjs → useCustomerFormLabels-BC1WfqWo.mjs} +5 -5
  166. package/dist/{useCustomerFormLabels-TVTgy0MT.js → useCustomerFormLabels-Ct6vD_b8.js} +1 -1
  167. package/dist/{useExperimentalFeature-BvE_EOX-.mjs → useExperimentalFeature-4Y-ppDr7.mjs} +1 -1
  168. package/dist/{useExperimentalFeature-CC-DrIcL.js → useExperimentalFeature-9-p9_nP6.js} +1 -1
  169. package/dist/{useInvoiceData-D8ds05CX.mjs → useInvoiceData-B2Z9aD2w.mjs} +2 -2
  170. package/dist/{useInvoiceData-CRRPdXc6.js → useInvoiceData-CGvtl7Ai.js} +1 -1
  171. package/dist/{useInvoicesList-DIfQcvER.js → useInvoicesList-Ba0GO8p-.js} +1 -1
  172. package/dist/{useInvoicesList-SJU5YWBQ.mjs → useInvoicesList-DJPznhig.mjs} +7 -7
  173. package/dist/{useLoadInitialData-DsabgMLZ.js → useLoadInitialData-BO9ZsSsF.js} +1 -1
  174. package/dist/{useLoadInitialData-MUljS38K.mjs → useLoadInitialData-CWyI3_RR.mjs} +1 -1
  175. package/dist/{usePaymentMethodAvailability-D0NUanyF.mjs → usePaymentMethodAvailability-DqIvkjLF.mjs} +4 -4
  176. package/dist/{usePaymentMethodAvailability-Bt7P9InI.js → usePaymentMethodAvailability-bkmDrPXY.js} +1 -1
  177. package/dist/{usePaymentMethodOptions-cT1o-BA1.js → usePaymentMethodOptions-BPBVGNDg.js} +1 -1
  178. package/dist/{usePaymentMethodOptions-B7JYkGsw.mjs → usePaymentMethodOptions-MSEp39xQ.mjs} +1 -1
  179. package/dist/{usePaymentMethods-DNVw2eVg.js → usePaymentMethods-BAOtOJZD.js} +1 -1
  180. package/dist/{usePaymentMethods-CpzqXQUT.mjs → usePaymentMethods-U7gnZ0F5.mjs} +1 -1
  181. package/dist/{usePayments-Gx9kBvNB.mjs → usePayments-Dq2V6bTV.mjs} +6 -6
  182. package/dist/{usePayments-D9Eo-uBk.js → usePayments-G-HpKpK8.js} +1 -1
  183. package/dist/{usePortal-DsebXdhx.js → usePortal-BplmMkBG.js} +1 -1
  184. package/dist/{usePortal-3VCZwSUE.mjs → usePortal-CMHV-ShD.mjs} +1 -1
  185. package/dist/{useSubscription-K_gP9TeX.js → useSubscription-CvB8ROBt.js} +1 -1
  186. package/dist/{useSubscription-DnL1wVh1.mjs → useSubscription-V53WsZwQ.mjs} +1 -1
  187. package/dist/{useTimePeriod.es-CmltiTE-.js → useTimePeriod.es-CtCTu9cz.js} +1 -1
  188. package/dist/{useTimePeriod.es-DMtKzcoB.mjs → useTimePeriod.es-D31Zl1MJ.mjs} +1 -1
  189. package/package.json +2 -1
  190. package/dist/Checkout.entry.ce-C52gkrNZ.js +0 -1
  191. package/dist/CustomerWalletBalances.vue_vue_type_script_setup_true_lang-Cnlbp0om.js +0 -1
  192. package/dist/ErrorNotification.vue.es-Cd2UKPAz.js +0 -1
  193. package/dist/IconButton.vue.es-BTAkuFsm.js +0 -1
  194. package/dist/IconButton.vue.es-C4dQEQAc.mjs +0 -198
  195. package/dist/PaymentErrorCard.vue_vue_type_script_setup_true_lang-BnilyGBO.mjs +0 -144
  196. package/dist/PaymentErrorCard.vue_vue_type_script_setup_true_lang-CSv-Luvz.js +0 -1
  197. package/dist/PaymentIntegrationFormAdyen-Q48aDXR7.js +0 -98
  198. package/dist/PaymentIntegrationFormStripe-BSEqarl7.js +0 -102
  199. package/dist/PlanCustomizationEditor-XpofGULc.js +0 -1
  200. package/dist/RadioGroupExtended.vue.es-Cb1iD73r.js +0 -1
  201. package/dist/SubscriptionSchedules.vue_vue_type_script_setup_true_lang-nmVRb6hj.js +0 -1
  202. package/dist/component-5wqcK7yz.mjs +0 -8
  203. package/dist/component-B7ZDyqBp.js +0 -1
  204. package/dist/subscriptions-fJcj88X9.js +0 -1
@@ -0,0 +1,98 @@
1
+ Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("vue"),X=require("./useService-H7BjLg8P.js"),C=require("./customElements-BYIdPSzQ.js"),S=require("./PaymentErrorCard.vue_vue_type_script_setup_true_lang-DBm51C7c.js"),ee=require("./payments-KTjVHqOa.js"),L=require("./url-BNKStNY9.js"),te=require("./paymentMethods-CQdhZwq4.js"),u=require("./adyen-Druit6gz.js"),ne=require("./adyenSdk-BP2XXzeJ.js"),ae=require("./useExperimentalFeature-9-p9_nP6.js"),B=require("./paymentFailure-Cki8c5BX.js"),oe=h=>{let f={};return h==="TOKENIZE"&&(f={"en-US":{payButton:"Add payment method",confirmPurchase:"Add payment method"},"fr-FR":{payButton:"Ajouter un moyen de paiement",confirmPurchase:"Ajouter un moyen de paiement"},"de-DE":{payButton:"Zahlungsmethode hinzufügen",confirmPurchase:"Zahlungsmethode hinzufügen"},"it-IT":{payButton:"Aggiungi metodo di pagamento",confirmPurchase:"Aggiungi metodo di pagamento"},"es-ES":{payButton:"Añadir método de pago",confirmPurchase:"Añadir método de pago"},"nl-NL":{payButton:"Betaalmethode toevoegen",confirmPurchase:"Betaalmethode toevoegen"},"pt-BR":{payButton:"Adicionar método de pagamento",confirmPurchase:"Adicionar método de pagamento"},"pt-PT":{payButton:"Adicionar método de pagamento",confirmPurchase:"Adicionar método de pagamento"},"pl-PL":{payButton:"Dodaj metodę płatności",confirmPurchase:"Dodaj metodę płatności"},"ru-RU":{payButton:"Добавить способ оплаты",confirmPurchase:"Добавить способ оплаты"},"sv-SE":{payButton:"Lägg till betalningsmetod",confirmPurchase:"Lägg till betalningsmetod"},"da-DK":{payButton:"Tilføj betalingsmetode",confirmPurchase:"Tilføj betalingsmetode"},"fi-FI":{payButton:"Lisää maksutapa",confirmPurchase:"Lisää maksutapa"},"no-NO":{payButton:"Legg til betalingsmetode",confirmPurchase:"Legg til betalingsmetode"},"cs-CZ":{payButton:"Přidat platební metodu",confirmPurchase:"Přidat platební metodu"},"hu-HU":{payButton:"Fizetési mód hozzáadása",confirmPurchase:"Fizetési mód hozzáadása"},"ro-RO":{payButton:"Adăugați metodă de plată",confirmPurchase:"Adăugați metodă de plată"},"ja-JP":{payButton:"支払い方法を追加",confirmPurchase:"支払い方法を追加"},"ko-KR":{payButton:"결제 수단 추가",confirmPurchase:"결제 수단 추가"},"zh-CN":{payButton:"添加支付方式",confirmPurchase:"添加支付方式"},"zh-TW":{payButton:"新增付款方式",confirmPurchase:"新增付款方式"},ar:{payButton:"إضافة وسيلة دفع",confirmPurchase:"إضافة وسيلة دفع"},"hr-HR":{payButton:"Dodajte način plačanja",confirmPurchase:"Dodajte način plačanja"},"el-GR":{payButton:"Προσθήκη μεθόδου πληρωμής",confirmPurchase:"Προσθήκη μεθόδου πληρωμής"},"sk-SK":{payButton:"Pridať spôsob platby",confirmPurchase:"Pridať spôsob platby"},"sl-SI":{payButton:"Dodajte način plačanja",confirmPurchase:"Dodajte način plačanja"},"bg-BG":{payButton:"Добавяне на начин на плащане",confirmPurchase:"Добавяне на начин на плащане"},"ca-ES":{payButton:"Afegir mètode de pagament",confirmPurchase:"Afegir mètode de pagament"},"et-EE":{payButton:"Lisa makseviis",confirmPurchase:"Lisa makseviis"},"lv-LV":{payButton:"Pievienot maksājuma veidu",confirmPurchase:"Pievienot maksājuma veidu"},"lt-LT":{payButton:"Pridėti mokėjimo metodą",confirmPurchase:"Pridėti mokėjimo metodą"}}),f},A="ADYEN",re=r.defineComponent({__name:"PaymentIntegrationFormAdyen",props:{context:{type:Object},countryCode:{type:String},customerId:{type:String},invoiceId:{type:String},paymentMethodOptionResponseEntry:{type:Object},variant:{type:String},selected:{type:Boolean},amount:{type:Object},validateOnSubmit:{type:Function,default:()=>Promise.resolve(!0)},forceStorePaymentMethod:{type:Boolean},storePaymentMethod:{type:Boolean,default:void 0},redirectsOnSuccess:{type:Boolean}},emits:["select","payment-failed","payment-success","ready"],setup(h,{expose:f,emit:x}){let p=null,P=null;const n=h,_=x;f({submit:j});const l=r.ref(),N=r.ref(!1),I=r.ref(),i=C.useLogger(),{locale:F}=C.useIntl(),{authorizePayment:w,getPaymentDetails:U}=ee.createPaymentsService(),{tokenizePaymentMethod:Y}=te.createPaymentMethodsService(),T=ae.useExperimentalFeature(),O=r.computed(()=>{var e;return u.getAdyenDropInPaymentMethods(n.paymentMethodOptionResponseEntry,{excludeExpressPaymentMethods:!!((e=T==null?void 0:T.value)!=null&&e["express-checkout"])})}),R=r.computed(()=>O.value.length>0);function s(e){return B.createPaymentFailureContext({gateway:A,paymentAcceptorId:n.paymentMethodOptionResponseEntry.payment_acceptor.id,variant:n.variant,invoiceId:n.invoiceId,customerId:n.customerId,...e})}function y(e){const t=B.createPaymentFailureError(e);I.value=t,_("payment-failed",t)}function j(){try{p==null||p.submit()}catch(e){i.error("ADYEN_SUBMIT_FAILED","Failed to submit Adyen drop-in",s({reason:"ADYEN_SUBMIT_FAILED",cause:e}),e)}}async function Z(){const e=u.toMinorUnitAmount(n.amount),t=O.value;return{checkoutConfig:{amount:e,clientKey:u.getAdyenClientKeyFromPaymentMethodOptionsResponse(n.paymentMethodOptionResponseEntry),environment:u.getAdyenEnvironmentFromPaymentMethodOptionsResponse(n.paymentMethodOptionResponseEntry,i),locale:F,translations:oe(n.variant),countryCode:n.countryCode,analytics:{enabled:!1},paymentMethodsResponse:{paymentMethods:t},onSubmit:K,onAdditionalDetails:q,onPaymentCompleted:Q,onPaymentFailed:$,onError:J,showPayButton:!1},dropInConfig:{disableFinalAnimation:!0,paymentMethodsConfiguration:{card:{hasHolderName:!0,holderNameRequired:!0,enableStoreDetails:!n.forceStorePaymentMethod&&n.storePaymentMethod===void 0&&n.variant==="AUTHORIZE"},paypal:{intent:e.value>0?"authorize":"tokenize",showPayButton:!0}},openFirstPaymentMethod:n.selected,onSelect:({props:{type:o}})=>{o&&_("select",{paymentMethodType:o,paymentGatewayVariant:"ADYEN"})},onReady:()=>_("ready")}}}function z(){return Promise.all([ne.loadAdyenSdk(),Promise.resolve().then(()=>require("./adyen-BJfC7N6f.js")).then(e=>e.default)])}async function v(){if(await M(),I.value=void 0,!R.value){const{payment_acceptor:e,integration:t}=n.paymentMethodOptionResponseEntry;i.warn("PAYMENT_INTEGRATION_NOT_RENDERABLE","No Adyen payment methods to offer",{fingerprint:["PAYMENT_INTEGRATION_NOT_RENDERABLE",e.id],paymentAcceptorId:e.id,integrationId:t.id,...n.invoiceId?{invoiceId:n.invoiceId}:{}});return}if(await r.nextTick(),!!l.value)try{const[e,t]=await z(),{checkoutConfig:o,dropInConfig:a}=await Z();P=await e.AdyenCheckout(o),p=new e.Dropin(P,{...a,paymentMethodComponents:e.dropInPaymentMethodComponents}).mount(l.value),G(t)}catch(e){i.error("PAYMENT_INTEGRATION_INITIALIZATION_FAILED","Failed to mount Adyen web drop-in",s({reason:"ADYEN_DROP_IN_MOUNT_FAILED",cause:e}),e),y({code:"PAYMENT_INTEGRATION_INITIALIZATION_FAILED",message:"Failed to mount Adyen web drop-in",error:e})}}async function M(){p&&(p.unmount(),p=null),l.value&&(l.value.innerHTML="")}function G(e){var o;const t=(o=l.value)==null?void 0:o.getRootNode();if(t instanceof ShadowRoot){const a=document.createElement("style");a.textContent=e,t.appendChild(a);const d=document.createElement("style");d.textContent=`
2
+ :host {
3
+ --adyen-sdk-color-background-secondary: transparent;
4
+ --adyen-sdk-color-background-primary: rgb(243 244 246 / 0.5);
5
+ --adyen-sdk-color-outline-secondary: #e5e7eb;
6
+ --adyen-sdk-color-outline-primary: transparent;
7
+ --adyen-sdk-color-background-always-dark: var(--color-primary-500);
8
+ --adyen-sdk-color-background-inverse-primary-hover: var(--color-primary-600);
9
+ }
10
+
11
+ .adyen-checkout__payment-method__image__wrapper {
12
+ width: 32px;
13
+ height: 32px;
14
+ }
15
+
16
+ .adyen-checkout__payment-method__image {
17
+ height: 32px;
18
+ }
19
+
20
+ .adyen-checkout__input-wrapper,
21
+ .adyen-checkout__input {
22
+ border-color: rgb(229, 231, 235);
23
+ border-radius: var(--adyen-sdk-border-radius-s, 4px);
24
+ }
25
+
26
+ .adyen-checkout__button,
27
+ .adyen-checkout__payment-method {
28
+ border-radius: var(--adyen-sdk-border-radius-s, 4px);
29
+ }
30
+
31
+ .adyen-checkout__payment-method {
32
+ border-color: rgb(229, 231, 235);
33
+ box-shadow: 0 1px 2px 0 rgb(0 0 0 / 0.05);
34
+ transition: box-shadow 0.2s ease-in-out;
35
+ }
36
+
37
+ .adyen-checkout__payment-method--selected {
38
+ box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
39
+ }
40
+
41
+ .adyen-checkout__payment-method:after {
42
+ transform: scale(0%);
43
+ }
44
+
45
+ .adyen-checkout__paypal__button {
46
+ display: block !important;
47
+ }
48
+
49
+ .adyen-checkout__payment-methods-list {
50
+ gap: 4px;
51
+ }
52
+
53
+ .adyen-checkout__dropdown__list {
54
+ background-color: white;
55
+ border-radius: var(--adyen-sdk-border-radius-s, 4px);
56
+ }
57
+
58
+ .adyen-checkout__payment-method.adyen-checkout__payment-method--selected:after {
59
+ content: '✓';
60
+ width: 20px;
61
+ height: 20px;
62
+ border-radius: 10px;
63
+ background-color: var(--color-primary-600);
64
+ position: absolute;
65
+ top: 14px;
66
+ right: 14px;
67
+ text-align: center;
68
+ line-height: 20px;
69
+ color: white;
70
+ transform: scale(100%);
71
+ font-size: 12px;
72
+ }
73
+
74
+ .adyen-checkout__payment-method__header {
75
+ padding: 8px 16px !important;
76
+ }
77
+
78
+ .adyen-checkout__payment-method__brands {
79
+ align-items: center;
80
+ }
81
+ .adyen-checkout__payment-method__brand-number {
82
+ line-height: 1;
83
+ }
84
+ .adyen-checkout__button__text {
85
+ font-size: 14px;
86
+ }
87
+ .adyen-checkout__store-details {
88
+ background: transparent;
89
+ padding: 0;
90
+ }
91
+ .adyen-checkout__checkbox__input + .adyen-checkout__checkbox__label:after {
92
+ border-color: rgb(229, 231, 235);
93
+ }
94
+ `,n.variant==="AUTHORIZE"&&(d.textContent+=`
95
+ .adyen-checkout__payment-method--cashapp .adyen-checkout-pm-details-wrapper {
96
+ display: none;
97
+ }
98
+ `),t.appendChild(d)}}function b(e,{paymentMethodType:t,actions:o,logFailure:a}){if(e.status==="ACTION_REQUIRED"&&e.action.payment_gateway_variant===A){const d=H(e,t);if(!d){a(e);return}p.handleAction(d),o.resolve({resultCode:e.action.adyen.result_code,action:d});return}if(e.payment.result==="AUTHORIZED"){N.value=!0,o.resolve({resultCode:"Authorised"});return}a(e),o.resolve({resultCode:"Error"})}function K(...e){const[t,o,a]=e;n.validateOnSubmit().then(d=>{if(!d)return;const c=n.paymentMethodOptionResponseEntry.payment_acceptor.id,D={risk_data:u.transformObjectToAdyenObject(t.data.riskData),payment_method:u.transformObjectToAdyenObject(t.data.paymentMethod),browser_info:u.transformObjectToAdyenObject(t.data.browserInfo)};if(n.variant==="AUTHORIZE"){const g=u.createReturnUrl({paymentAcceptorId:n.paymentMethodOptionResponseEntry.payment_acceptor.id,redirectUrl:window.location.href});w({payment_acceptor_id:c,...n.customerId?{customer_id:n.customerId}:{},payment_gateway_variant:A,adyen:{...D,store_payment_method:n.storePaymentMethod??(n.forceStorePaymentMethod||t.data.storePaymentMethod)},amount:n.amount,...n.context?{context:n.context}:{},return_url:g}).then(m=>b(m,{paymentMethodType:t.data.paymentMethod.type,actions:a,logFailure:E=>i.error("PAYMENT_AUTHORIZATION_FAILED",`Failed payment authorization for payment acceptor with id ${c}`,s({reason:"PAYMENT_AUTHORIZATION_REJECTED",paymentMethodType:t.data.paymentMethod.type,cause:E}),E)})).catch(m=>{i.error("PAYMENT_AUTHORIZATION_FAILED",`Failed payment authorization for payment acceptor with id ${c}`,s({reason:"PAYMENT_AUTHORIZATION_FAILED",paymentMethodType:t.data.paymentMethod.type,cause:m}),m),a.resolve({resultCode:"Error"})});return}if(n.variant==="TOKENIZE"){const g=u.createReturnUrl({paymentAcceptorId:n.paymentMethodOptionResponseEntry.payment_acceptor.id,redirectUrl:window.location.href});if(!n.customerId){i.error("TOKENIZATION_FAILED",`Missing customer id for payment acceptor with id ${c}`,s({reason:"TOKENIZATION_FAILED_NO_CUSTOMER"})),y({code:"TOKENIZE_FAILED",message:"Missing customer id"});return}Y({customer_id:n.customerId,payment_acceptor_id:c,payment_gateway_variant:A,adyen:D,return_url:g}).then(m=>b(m,{paymentMethodType:t.data.paymentMethod.type,actions:a,logFailure:E=>i.error("TOKENIZATION_FAILED",`Tokenization failed for payment acceptor with id ${c}`,s({reason:"TOKENIZATION_REJECTED",paymentMethodType:t.data.paymentMethod.type,cause:E}),E)})).catch(m=>{i.error("TOKENIZATION_FAILED",`Tokenization failed for payment acceptor with id ${c}`,s({reason:"TOKENIZATION_FAILED",paymentMethodType:t.data.paymentMethod.type,cause:m}),m),a.resolve({resultCode:"Error"})})}}).catch(d=>{i.error("INTEGRATION_ERROR","Unhandled error in payment submission flow",s({reason:"ADYEN_SUBMISSION_FLOW_FAILED",cause:d}),d)})}function H(e,t){if(e.status!=="ACTION_REQUIRED")return;const o=e.action;if(o.payment_gateway_variant!="ADYEN")return;const a=o.adyen;return{paymentMethodType:(a==null?void 0:a.payment_method_type)??t,method:o.method,url:o.url,data:o.data,type:a==null?void 0:a.action_type,paymentData:a==null?void 0:a.payment_data,sdkData:a==null?void 0:a.sdk_data}}function q(...e){const[t]=e,o=t.data.details,a=t.data.paymentData;if(n.paymentMethodOptionResponseEntry.payment_acceptor.id){k({detailsResult:o?V(o):void 0,paymentDataResult:a,paymentAcceptorId:n.paymentMethodOptionResponseEntry.payment_acceptor.id});return}i.error("PAYMENT_ACCEPTOR_MISSING","Additional details arrived without a payment acceptor id",s({reason:"PAYMENT_ACCEPTOR_MISSING"})),y({code:"REDIRECT_RESULT_PAYMENT_ACCEPTOR_MISSING",message:"Payment failed",error:e})}function V(e){return Object.fromEntries(Object.entries(e).filter(([,t])=>t!=null))}function $(...e){const[t]=e;i.error("ADYEN_PAYMENT_FAILED","Adyen reported the payment as failed",s({reason:"ADYEN_PAYMENT_FAILED",extra:{resultCode:t==null?void 0:t.resultCode}}),t),y({code:"AUTHORIZATION_FAILED",message:"Payment failed",error:t})}function Q(...e){const[,t]=e;t==null||t.unmount(),_("payment-success")}function J(...e){const[t,o]=e;t.name!=="CANCEL"&&(i.error("INTEGRATION_ERROR","The Adyen drop-in reported an error",s({reason:"ADYEN_INTEGRATION_ERROR",cause:t,extra:{adyenErrorName:t.name}}),t),y({code:"UNKNOWN_ERROR",message:"Something went wrong",error:t}),o==null||o.unmount())}function k({detailsResult:e,threeDSResult:t,redirectResult:o,paymentDataResult:a,paymentAcceptorId:d}){U({paymentAcceptorId:d,paymentGatewayVariant:A,adyen:{...e?{details:e}:{},...o?{redirect_result:o}:{},...t?{threeds_result:t}:{},...a?{payment_data:a}:{}}}).then(c=>{if(c.payment_status==="FAILURE"){i.error("PAYMENT_DETAILS_REJECTED","Payment details returned a failed payment",s({reason:"PAYMENT_DETAILS_REJECTED",paymentAcceptorId:d,extra:{paymentStatus:c.payment_status}})),y({code:"AUTHORIZATION_FAILED",message:"Failed getting payment details",error:c});return}if(c.payment_status==="SUCCESS"){_("payment-success");return}}).catch(c=>{i.error("PAYMENT_DETAILS_CALL_FAILED","Failed fetching payment details",s({reason:"PAYMENT_DETAILS_CALL_FAILED",paymentAcceptorId:d,cause:c}),c),y({code:"PAYMENT_DETAILS_CALL_FAILED",message:"Failed fetching payment details",error:c})})}function W(){const e=L.getQueryParam(u.REDIRECT_RESULT_QUERY_STRING),t=L.getQueryParam(u.PAYMENT_ACCEPTOR_ID_QUERY_STRING);if(e){if(!t){i.error("INVALID_REDIRECT_RESULT","Redirect result is set but payment acceptor id is missing",s({reason:"INVALID_REDIRECT_RESULT"})),y({code:"REDIRECT_RESULT_PAYMENT_ACCEPTOR_MISSING",message:"Redirect result is set but payment acceptor id is missing"});return}k({paymentAcceptorId:t,detailsResult:{redirectResult:decodeURI(e)}})}}return r.onMounted(()=>{v(),W()}),r.onBeforeUnmount(()=>{M()}),r.watch(()=>n.paymentMethodOptionResponseEntry,(e,t)=>{X.isEqual(e,t)||v()},{deep:!0}),(e,t)=>(r.openBlock(),r.createElementBlock(r.Fragment,null,[N.value?(r.openBlock(),r.createBlock(S._sfc_main,{key:0,variant:h.variant,redirecting:h.redirectsOnSuccess},null,8,["variant","redirecting"])):I.value?(r.openBlock(),r.createBlock(S._sfc_main$1,{key:1,error:I.value},null,8,["error"])):r.createCommentVNode("",!0),R.value?(r.openBlock(),r.createElementBlock("div",{key:2,ref_key:"dropInContainerRef",ref:l},null,512)):r.createCommentVNode("",!0)],64))}});exports.default=re;
@@ -0,0 +1,102 @@
1
+ Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("vue"),K=require("./useService-H7BjLg8P.js"),O=require("./adyen-Druit6gz.js"),P=require("./PaymentErrorCard.vue_vue_type_script_setup_true_lang-DBm51C7c.js"),j=require("./payments-KTjVHqOa.js"),H=require("./paymentMethods-CQdhZwq4.js"),v=require("./url-BNKStNY9.js"),z=require("./customElements-BYIdPSzQ.js"),N=require("./paymentFailure-Cki8c5BX.js"),D="https://js.stripe.com/dahlia/stripe.js",q=`<!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <meta charset="UTF-8">
5
+ <meta name="viewport" content="width=device-width, initial-scale=1">
6
+ <style>
7
+ * { box-sizing: border-box; margin: 0; padding: 0; }
8
+ body { overflow: hidden; }
9
+ </style>
10
+ </head>
11
+ <body>
12
+ <div id="stripe-root"></div>
13
+ <script src="${D}"><\/script>
14
+ <script>
15
+ (function () {
16
+ let stripe, elements, countryCode, email, name, parentOrigin;
17
+
18
+ window.addEventListener('message', function (event) {
19
+ if (!event.data || typeof event.data !== 'object') return;
20
+ if (event.source !== window.parent) return;
21
+
22
+ if (event.data.type === 'stripe:init') {
23
+ parentOrigin = event.origin;
24
+ countryCode = event.data.countryCode;
25
+ email = event.data.email;
26
+ name = event.data.name;
27
+ stripe = Stripe(event.data.publicKey);
28
+ elements = stripe.elements(event.data.options);
29
+ const paymentElement = elements.create('payment', { layout: { type: 'accordion', defaultCollapsed: false }, wallets: event.data.options.wallets, fields: event.data.options.fields });
30
+
31
+ paymentElement.on('ready', function () {
32
+ parent.postMessage({ type: 'stripe:ready' }, parentOrigin);
33
+ });
34
+
35
+ paymentElement.on('change', function (e) {
36
+ parent.postMessage({ type: 'stripe:change', paymentMethodType: e.value.type }, parentOrigin);
37
+ });
38
+
39
+ paymentElement.on('loaderror', function (e) {
40
+ parent.postMessage({
41
+ type: 'stripe:loaderror',
42
+ error: { message: e.error.message, type: e.error.type }
43
+ }, parentOrigin);
44
+ });
45
+
46
+ paymentElement.mount('#stripe-root');
47
+
48
+ new ResizeObserver(function () {
49
+ parent.postMessage({
50
+ type: 'stripe:resize',
51
+ height: document.documentElement.scrollHeight
52
+ }, parentOrigin);
53
+ }).observe(document.documentElement);
54
+ }
55
+
56
+ if (event.data.type === 'stripe:submit') {
57
+ if (!elements || !parentOrigin || event.origin !== parentOrigin) return;
58
+ const submitEmail = 'email' in event.data ? event.data.email : email;
59
+ const submitName = 'name' in event.data ? event.data.name : name;
60
+ elements.submit().then(function (submitResult) {
61
+ if (submitResult.error) {
62
+ parent.postMessage({
63
+ type: 'stripe:submit:error',
64
+ error: {
65
+ message: submitResult.error.message,
66
+ type: submitResult.error.type,
67
+ code: submitResult.error.code
68
+ }
69
+ }, parentOrigin);
70
+ return;
71
+ }
72
+ const billingDetails = {};
73
+ if (countryCode) billingDetails.address = { country: countryCode };
74
+ if (submitEmail) billingDetails.email = submitEmail;
75
+ if (submitName) billingDetails.name = submitName;
76
+ const tokenParams = Object.keys(billingDetails).length
77
+ ? { payment_method_data: { billing_details: billingDetails } }
78
+ : {};
79
+ stripe.createConfirmationToken({ elements: elements, params: tokenParams }).then(function (tokenResult) {
80
+ if (tokenResult.error) {
81
+ parent.postMessage({
82
+ type: 'stripe:submit:error',
83
+ error: {
84
+ message: tokenResult.error.message,
85
+ type: tokenResult.error.type,
86
+ code: tokenResult.error.code
87
+ }
88
+ }, parentOrigin);
89
+ return;
90
+ }
91
+ parent.postMessage({
92
+ type: 'stripe:submit:success',
93
+ confirmationTokenId: tokenResult.confirmationToken.id
94
+ }, parentOrigin);
95
+ });
96
+ });
97
+ }
98
+ });
99
+ })();
100
+ <\/script>
101
+ </body>
102
+ </html>`,Y=["src","height"],G=n.defineComponent({__name:"PaymentIntegrationFormStripeFrame",props:{publicKey:{type:String},options:{type:Object},countryCode:{type:String},email:{type:String},name:{type:String}},emits:["ready","change","loaderror","submit-success","submit-error"],setup(m,{expose:I,emit:A}){const t=m,u=A;I({triggerSubmit:b});const d=n.ref(),l=n.ref(0),_=n.ref();function S(){var s,o;(o=(s=d.value)==null?void 0:s.contentWindow)==null||o.postMessage({type:"stripe:init",publicKey:t.publicKey,options:t.options,countryCode:t.countryCode,email:t.email,name:t.name},"*")}function b(){var s,o;(o=(s=d.value)==null?void 0:s.contentWindow)==null||o.postMessage({type:"stripe:submit",email:t.email,name:t.name},"*")}function f(s){return typeof s=="object"&&s!==null}function p(s){if(!d.value||s.source!==d.value.contentWindow||!f(s.data))return;const o=s.data,g=o.type;if(!(typeof g!="string"||!g.startsWith("stripe:")))switch(g){case"stripe:ready":u("ready");break;case"stripe:change":u("change",typeof o.paymentMethodType=="string"?o.paymentMethodType:"card");break;case"stripe:loaderror":{const a=f(o.error)?o.error:{};u("loaderror",{message:typeof a.message=="string"?a.message:void 0,type:typeof a.type=="string"?a.type:void 0});break}case"stripe:resize":typeof o.height=="number"&&(l.value=o.height);break;case"stripe:submit:success":typeof o.confirmationTokenId=="string"&&u("submit-success",o.confirmationTokenId);break;case"stripe:submit:error":{const a=f(o.error)?o.error:{};u("submit-error",{message:typeof a.message=="string"?a.message:void 0,type:typeof a.type=="string"?a.type:void 0,code:typeof a.code=="string"?a.code:void 0});break}}}return n.onMounted(()=>{const s=new Blob([q],{type:"text/html"});_.value=URL.createObjectURL(s),window.addEventListener("message",p)}),n.onBeforeUnmount(()=>{window.removeEventListener("message",p),_.value&&URL.revokeObjectURL(_.value)}),n.watch(()=>t.options,(s,o)=>{K.isEqual(s,o)||S()},{deep:!0}),(s,o)=>(n.openBlock(),n.createElementBlock("iframe",{ref_key:"iframeRef",ref:d,src:_.value,height:l.value||void 0,frameborder:"0",style:{width:"100%",display:"block",border:"none"},title:"Payment form",onLoad:S},null,40,Y))}}),w={link:"never"},C={variables:{borderRadius:"4px",colorBackground:"rgba(243, 244, 246, 0.5)"},rules:{".TermsText":{fontSize:"14px"},".Input":{backgroundColor:"rgba(243, 244, 246, 0.5)",fontSize:"14px",borderColor:"rgb(229, 231, 235)"}}};function Q(m,I){return{billingDetails:{address:{country:"never"},...m?{email:"never"}:{},...I?{name:"never"}:{}}}}function W({amount:m,email:I,name:A,variant:t,storePaymentMethod:u=!1}){const d=m.currency.toLowerCase(),l=Q(I,A);return t==="TOKENIZE"?{mode:"setup",currency:d,setup_future_usage:"off_session",wallets:w,fields:l,appearance:C}:{mode:"payment",currency:d,amount:O.toMinorUnitAmount(m).value,...u?{setup_future_usage:"off_session"}:{},wallets:w,fields:l,appearance:C}}const R="STRIPE",$=n.defineComponent({__name:"PaymentIntegrationFormStripe",props:{email:{type:String},name:{type:String},countryCode:{type:String},customerId:{type:String},invoiceId:{type:String},paymentMethodOptionResponseEntry:{type:Object},variant:{type:String},selected:{type:Boolean},amount:{type:Object},validateOnSubmit:{type:Function,default:()=>Promise.resolve(!0)},context:{type:Object},forceStorePaymentMethod:{type:Boolean},storePaymentMethod:{type:Boolean},redirectsOnSuccess:{type:Boolean}},emits:["select","payment-failed","payment-success","ready"],setup(m,{expose:I,emit:A}){const t=m,u=A;I({submit:M});const d=n.ref(!1),l=n.ref(),_=n.ref(),S=n.computed(()=>t.storePaymentMethod??t.forceStorePaymentMethod??!1),b=n.computed(()=>W({amount:t.amount,email:t.email,name:t.name,variant:t.variant,storePaymentMethod:S.value})),f=n.ref(null),p=z.useLogger(),{authorizePayment:s}=j.createPaymentsService(),{tokenizePaymentMethod:o}=H.createPaymentMethodsService(),g=n.computed(()=>{var e,r;return(r=(e=t.paymentMethodOptionResponseEntry.integration.payment_gateway)==null?void 0:e.stripe)==null?void 0:r.public_key});function a(e){return N.createPaymentFailureContext({gateway:R,paymentAcceptorId:t.paymentMethodOptionResponseEntry.payment_acceptor.id,variant:t.variant,invoiceId:t.invoiceId,customerId:t.customerId,...e})}function M(){L().catch(e=>{p.error("STRIPE_SUBMIT_FAILED","Unexpected error during Stripe submission",a({reason:"STRIPE_SUBMIT_FAILED",cause:e}),e)})}async function L(){var r;await t.validateOnSubmit()&&((r=_.value)==null||r.triggerSubmit())}function F(e){return new Promise((r,c)=>{if(window.Stripe){r(window.Stripe(e));return}const i=document.createElement("script");i.src=D,i.onload=()=>{if(!window.Stripe){c(new Error("Stripe not available after script load"));return}r(window.Stripe(e))},i.onerror=()=>c(new Error("Failed to load Stripe.js")),document.head.appendChild(i)})}async function k(){if(f.value)return f.value;const e=g.value;if(!e)throw new Error("Missing Stripe public key");const r=await F(e);return f.value=r,r}async function U(e){const r=t.paymentMethodOptionResponseEntry.payment_acceptor.id,c=O.createReturnUrl({paymentAcceptorId:r,redirectUrl:window.location.href});if(t.variant==="AUTHORIZE"){try{const i=await s({payment_acceptor_id:r,...t.customerId?{customer_id:t.customerId}:{},payment_gateway_variant:R,stripe:{confirmation_token_id:e},amount:t.amount,...t.context&&t.context.type!=="CHARGE_ON_DEMAND"?{context:t.context}:{},return_url:c});await h(i)}catch(i){p.error("PAYMENT_AUTHORIZATION_FAILED",`Failed payment authorization for payment acceptor with id ${r}`,a({reason:"PAYMENT_AUTHORIZATION_FAILED",cause:i}),i),y({code:"AUTHORIZATION_FAILED",message:"Payment authorization failed",error:i})}return}if(t.variant==="TOKENIZE"){if(!t.customerId){p.error("TOKENIZATION_FAILED",`Missing customer id for payment acceptor with id ${r}`,a({reason:"TOKENIZATION_FAILED_NO_CUSTOMER"})),y({code:"TOKENIZE_FAILED",message:"Missing customer id"});return}try{const i=await o({customer_id:t.customerId,payment_acceptor_id:r,payment_gateway_variant:R,stripe:{confirmation_token_id:e},return_url:c});await h(i)}catch(i){p.error("TOKENIZATION_FAILED",`Tokenization failed for payment acceptor with id ${r}`,a({reason:"TOKENIZATION_FAILED",cause:i}),i),y({code:"TOKENIZE_FAILED",message:"Tokenization failed",error:i})}}}async function h(e){var r;if(e.status==="ACTION_REQUIRED"&&e.action.payment_gateway_variant===R){const c=e.action.client_secret||((r=e.action.data)==null?void 0:r.client_secret);if(!c){p.error("STRIPE_ACTION_FAILED","Missing client_secret in Stripe ACTION_REQUIRED response",a({reason:"STRIPE_ACTION_MISSING_CLIENT_SECRET",extra:{paymentStatus:e.status}})),y({code:"AUTHORIZATION_FAILED",message:"Payment action failed",error:e});return}let i;try{i=await k()}catch(T){p.error("STRIPE_ACTION_FAILED","Failed to load Stripe.js",a({reason:"STRIPE_SDK_LOAD_FAILED",cause:T}),T),y({code:"AUTHORIZATION_FAILED",message:"Payment action failed",error:T});return}const{error:E}=await i.handleNextAction({clientSecret:c});if(E){p.error("STRIPE_ACTION_FAILED","Stripe handleNextAction failed",a({reason:"STRIPE_NEXT_ACTION_FAILED",cause:E,extra:{stripeErrorCode:E.code,stripeErrorType:E.type}}),E),y({code:"AUTHORIZATION_FAILED",message:"Payment action failed",error:E});return}d.value=!0,u("payment-success");return}if(e.status==="SUCCESS"){d.value=!0,u("payment-success");return}p.error("STRIPE_ACTION_FAILED","Unexpected payment result status",a({reason:"STRIPE_UNEXPECTED_PAYMENT_STATUS",extra:{paymentStatus:e.status}})),y({code:"AUTHORIZATION_FAILED",message:"Payment failed",error:e})}async function x(){const e=t.paymentMethodOptionResponseEntry.payment_acceptor.id;if(v.getQueryParam(O.PAYMENT_ACCEPTOR_ID_QUERY_STRING)!==e)return;const c=v.getQueryParam("redirect_status"),i=v.getQueryParam("payment_intent_client_secret"),E=v.getQueryParam("setup_intent_client_secret");if(!c||!i&&!E)return;if(c==="succeeded"){d.value=!0,u("payment-success");return}const T=new globalThis.Error(`Stripe redirect returned status: ${c}`);p.error("STRIPE_REDIRECT_RETURN_FAILED","Stripe redirect returned non-succeeded status",a({reason:"STRIPE_REDIRECT_RETURN_FAILED",extra:{redirectStatus:c}}),T),y({code:"AUTHORIZATION_FAILED",message:"Payment failed",error:T})}function Z(){u("select",{paymentMethodType:"card",paymentGatewayVariant:R}),u("ready")}function B(e){p.error("PAYMENT_INTEGRATION_INITIALIZATION_FAILED","Failed to load the Stripe payment form",a({reason:"STRIPE_FORM_LOAD_FAILED",cause:e,extra:{stripeErrorType:e.type}}),e),y({code:"PAYMENT_INTEGRATION_INITIALIZATION_FAILED",message:e.message??"Failed to load payment form",error:e})}function y(e){const r=N.createPaymentFailureError(e);l.value=r,u("payment-failed",r)}return n.onMounted(()=>{x().catch(e=>{p.error("STRIPE_REDIRECT_RETURN_FAILED","handleRedirectReturn threw unexpectedly",a({reason:"STRIPE_REDIRECT_RETURN_THREW",cause:e}),e)})}),n.onBeforeUnmount(()=>{f.value=null}),(e,r)=>d.value?(n.openBlock(),n.createBlock(P._sfc_main,{key:0,variant:m.variant,redirecting:m.redirectsOnSuccess},null,8,["variant","redirecting"])):l.value?(n.openBlock(),n.createBlock(P._sfc_main$1,{key:1,error:l.value},null,8,["error"])):g.value?(n.openBlock(),n.createBlock(G,{key:2,ref_key:"frameRef",ref:_,"public-key":g.value,options:b.value,"country-code":m.countryCode,email:m.email,name:m.name,onReady:Z,onChange:r[0]||(r[0]=c=>u("select",{paymentMethodType:c,paymentGatewayVariant:R})),onLoaderror:B,onSubmitSuccess:U,onSubmitError:r[1]||(r[1]=c=>n.unref(p).error("STRIPE_CONFIRMATION_TOKEN_FAILED","Stripe submission failed",a({reason:"STRIPE_CONFIRMATION_TOKEN_FAILED",cause:c}),c))},null,8,["public-key","options","country-code","email","name"])):n.createCommentVNode("",!0)}});exports.default=$;