@solvimon/solvimon-web 0.1.0-alpha.24 → 0.1.0-alpha.26
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 +14 -11
- package/dist/{AddPaymentMethodPane.vue_vue_type_script_setup_true_lang-DW10rozs.mjs → AddPaymentMethodPane.vue_vue_type_script_setup_true_lang-DcrLNA_x.mjs} +6 -6
- package/dist/{AddPaymentMethodPane.vue_vue_type_script_setup_true_lang-jWthTJk-.js → AddPaymentMethodPane.vue_vue_type_script_setup_true_lang-DwbIiJBY.js} +1 -1
- package/dist/{Avatar.vue.es-nr8srGuK.js → Avatar.vue.es-Bm6MCMAL.js} +1 -1
- package/dist/{Avatar.vue.es-DzjFvLuK.mjs → Avatar.vue.es-BqQHvLGA.mjs} +1 -1
- package/dist/{BillingInformation.vue_vue_type_script_setup_true_lang-C1prOJay.js → BillingInformation.vue_vue_type_script_setup_true_lang-0JHnqIpC.js} +1 -1
- package/dist/{BillingInformation.vue_vue_type_script_setup_true_lang-BptcwJMr.mjs → BillingInformation.vue_vue_type_script_setup_true_lang-BFza7Nf9.mjs} +8 -8
- package/dist/{Button.vue.es-PbJFK8z7.mjs → Button.vue.es-C32_baQN.mjs} +1 -1
- package/dist/{Button.vue.es-TCF-bvDF.js → Button.vue.es-qGvnOKnK.js} +1 -1
- package/dist/ChargeOnDemandModal-CIiI74ls.mjs +983 -0
- package/dist/ChargeOnDemandModal-DIQaGnRs.js +1 -0
- package/dist/Checkout.entry.ce-8EcavNgT.js +2 -0
- package/dist/{Checkout.entry.ce-DHFx5Vnb.mjs → Checkout.entry.ce-BA5ljKj8.mjs} +1562 -1538
- package/dist/{Chip.vue.es-DpcOM3Ai.mjs → Chip.vue.es-CKCOY5T6.mjs} +2 -2
- package/dist/{Chip.vue.es-CAoisngJ.js → Chip.vue.es-D60gTbfe.js} +1 -1
- package/dist/{ContextMenu.vue.es-kzZ3JJHG.js → ContextMenu.vue.es-C7KI8Gz6.js} +1 -1
- package/dist/{ContextMenu.vue.es-tAuFp-6i.mjs → ContextMenu.vue.es-Da-lAmTl.mjs} +10 -10
- package/dist/{CustomerBillingInformation.vue.es-BQSl9q6W.mjs → CustomerBillingInformation.vue.es-BxBQt4Q0.mjs} +2 -2
- package/dist/{CustomerBillingInformation.vue.es-Nac6HgLo.js → CustomerBillingInformation.vue.es-bFUx81Ig.js} +1 -1
- package/dist/{CustomerPaymentMethods.vue_vue_type_script_setup_true_lang-R47ln7Wb.mjs → CustomerPaymentMethods.vue_vue_type_script_setup_true_lang-BcTZgshS.mjs} +6 -6
- package/dist/{CustomerPaymentMethods.vue_vue_type_script_setup_true_lang-BOLf-U0A.js → CustomerPaymentMethods.vue_vue_type_script_setup_true_lang-C0lJ_ESU.js} +1 -1
- package/dist/{CustomerWalletBalances.vue_vue_type_script_setup_true_lang-CaNXS48v.mjs → CustomerWalletBalances.vue_vue_type_script_setup_true_lang-DkbQ2MiR.mjs} +908 -891
- package/dist/CustomerWalletBalances.vue_vue_type_script_setup_true_lang-hBo2Y2mJ.js +1 -0
- package/dist/{DividerText.vue.es-LJ2kZakb.js → DividerText.vue.es-BF3gnr4e.js} +1 -1
- package/dist/{DividerText.vue.es-CSE7a-T0.mjs → DividerText.vue.es-DKl3FnDJ.mjs} +1 -1
- package/dist/{EmptyStatePlaceholder.vue_vue_type_script_setup_true_lang-DeotDsFP.mjs → EmptyStatePlaceholder.vue_vue_type_script_setup_true_lang-C3QYra1x.mjs} +4 -4
- package/dist/{EmptyStatePlaceholder.vue_vue_type_script_setup_true_lang-GNPyrcAQ.js → EmptyStatePlaceholder.vue_vue_type_script_setup_true_lang-cSQeqr0A.js} +1 -1
- package/dist/{ErrorNotification.vue.es-BF6swP7o.js → ErrorNotification.vue.es-BX9dHEc-.js} +1 -1
- package/dist/{ErrorNotification.vue.es-CVUuIt8Z.mjs → ErrorNotification.vue.es-rRKgmkzV.mjs} +1 -1
- package/dist/{IconButton.vue.es-CB1lIPao.js → IconButton.vue.es-Bwdfu-jm.js} +1 -1
- package/dist/{IconButton.vue.es-DGflbWFk.mjs → IconButton.vue.es-UlqwNPAX.mjs} +2 -2
- package/dist/{IconTitle.vue.es-BsdjyGlQ.mjs → IconTitle.vue.es-CK9k69tV.mjs} +3 -3
- package/dist/{IconTitle.vue.es-CMO8EyQl.js → IconTitle.vue.es-Cei98MBw.js} +1 -1
- package/dist/{Input.vue.es-CREdT4nB.js → Input.vue.es-B47l_feL.js} +1 -1
- package/dist/{Input.vue.es-BFbiFXsU.mjs → Input.vue.es-D9IjIWc-.mjs} +2 -2
- package/dist/{InvoiceDetailsBlock.vue_vue_type_script_setup_true_lang-BZ4D_-7E.js → InvoiceDetailsBlock.vue_vue_type_script_setup_true_lang-DKlPrxQS.js} +1 -1
- package/dist/{InvoiceDetailsBlock.vue_vue_type_script_setup_true_lang-Btv0rRk4.mjs → InvoiceDetailsBlock.vue_vue_type_script_setup_true_lang-DUfJl07Y.mjs} +2 -2
- package/dist/{InvoiceEntryView.vue_vue_type_script_setup_true_lang-CrZq0d1M.mjs → InvoiceEntryView.vue_vue_type_script_setup_true_lang-D9Rtgapa.mjs} +2 -2
- package/dist/{InvoiceEntryView.vue_vue_type_script_setup_true_lang-j-cNIRD_.js → InvoiceEntryView.vue_vue_type_script_setup_true_lang-DlJ6lELc.js} +1 -1
- package/dist/InvoiceSummary.vue.es-DBnR9Hs7.js +1 -0
- package/dist/{InvoiceSummary.vue.es-JtOIQ6SJ.mjs → InvoiceSummary.vue.es-DQ4KvTaw.mjs} +576 -565
- package/dist/{Modal.vue.es-BbdtdxsO.js → Modal.vue.es-8LN4gBh0.js} +1 -1
- package/dist/{Modal.vue.es-jT61xK_A.mjs → Modal.vue.es-B9xMiyn3.mjs} +5 -5
- package/dist/{PaymentErrorCard.vue_vue_type_script_setup_true_lang-BBoZVnsK.js → PaymentErrorCard.vue_vue_type_script_setup_true_lang-B1yGKkWN.js} +1 -1
- package/dist/{PaymentErrorCard.vue_vue_type_script_setup_true_lang-Dan29qmH.mjs → PaymentErrorCard.vue_vue_type_script_setup_true_lang-BVzL2PGe.mjs} +4 -4
- package/dist/{PaymentFeedbackCard.vue_vue_type_script_setup_true_lang-D34fD3Io.js → PaymentFeedbackCard.vue_vue_type_script_setup_true_lang-DSGf6uFP.js} +1 -1
- package/dist/{PaymentFeedbackCard.vue_vue_type_script_setup_true_lang-BJZHkTqA.mjs → PaymentFeedbackCard.vue_vue_type_script_setup_true_lang-nLTPnH4j.mjs} +3 -3
- package/dist/{PaymentHistoryBlock-quvnCSFV.mjs → PaymentHistoryBlock-DYa99P1M.mjs} +1 -1
- package/dist/{PaymentHistoryBlock-Dw2wOiAI.js → PaymentHistoryBlock-Ds93gNvh.js} +1 -1
- package/dist/{PaymentHistoryBlock.vue_vue_type_script_setup_true_lang-C0XIdBbx.js → PaymentHistoryBlock.vue_vue_type_script_setup_true_lang-CBZhXQfC.js} +1 -1
- package/dist/{PaymentHistoryBlock.vue_vue_type_script_setup_true_lang-5ckQd9eQ.mjs → PaymentHistoryBlock.vue_vue_type_script_setup_true_lang-D0KnSy0y.mjs} +4 -4
- package/dist/{PaymentIntegrationForm-D1oJREmH.js → PaymentIntegrationForm-B_Db4DG1.js} +1 -1
- package/dist/{PaymentIntegrationForm-CQjUZi22.mjs → PaymentIntegrationForm-UWoyZgsR.mjs} +1 -1
- package/dist/PaymentIntegrationForm.vue_vue_type_script_setup_true_lang-C0J37ZVe.js +1 -0
- package/dist/PaymentIntegrationForm.vue_vue_type_script_setup_true_lang-J15IDbMc.mjs +154 -0
- package/dist/{PaymentIntegrationFormAdyen-CyZk9ofV.mjs → PaymentIntegrationFormAdyen-D4qfNtZ_.mjs} +217 -197
- package/dist/PaymentIntegrationFormAdyen-HeA9XIj-.js +98 -0
- package/dist/{PaymentIntegrationFormStripe-D-GaLHwc.mjs → PaymentIntegrationFormStripe-BIiMCWlV.mjs} +247 -220
- package/dist/PaymentIntegrationFormStripe-DUCJTIAq.js +102 -0
- package/dist/PaymentMethod.vue.es-CJcSZ9lN.js +1 -0
- package/dist/{PaymentMethod.vue.es-C0j580g7.mjs → PaymentMethod.vue.es-CKu5nApX.mjs} +168 -148
- package/dist/{PaymentMethodForm-CDV5LR8i.js → PaymentMethodForm-1d0YIGOu.js} +1 -1
- package/dist/{PaymentMethodForm-Bf2Ps6eV.mjs → PaymentMethodForm-B05sHWcW.mjs} +1 -1
- package/dist/PaymentMethodForm.vue_vue_type_script_setup_true_lang-BDm8l_6N.js +1 -0
- package/dist/{PaymentMethodForm.vue_vue_type_script_setup_true_lang-BqPu7CYA.mjs → PaymentMethodForm.vue_vue_type_script_setup_true_lang-D1yIYsb_.mjs} +45 -41
- package/dist/{PaymentMethodsList.vue_vue_type_script_setup_true_lang-BIX0k7-q.js → PaymentMethodsList.vue_vue_type_script_setup_true_lang-BE4S26JX.js} +1 -1
- package/dist/{PaymentMethodsList.vue_vue_type_script_setup_true_lang-9MUPbgWM.mjs → PaymentMethodsList.vue_vue_type_script_setup_true_lang-DGpXRtp4.mjs} +6 -6
- package/dist/PlanCustomizationEditor-CEMP_Dhz.js +1 -0
- package/dist/PlanCustomizationEditor-CpZeilm5.mjs +694 -0
- package/dist/{PricingGroupRangeInput.vue.es-CP7-dmxS.mjs → PricingGroupRangeInput.vue.es-CJpvUP3-.mjs} +4 -4
- package/dist/{PricingGroupRangeInput.vue.es-BchXhunH.js → PricingGroupRangeInput.vue.es-DZSJ5Mz0.js} +1 -1
- package/dist/PricingGroupSingleEditor.vue_vue_type_script_setup_true_lang-DJ81eUJX.mjs +141 -0
- package/dist/PricingGroupSingleEditor.vue_vue_type_script_setup_true_lang-jrkraJMu.js +1 -0
- package/dist/{RadioGroupExtended.vue.es-_QMReyZ8.mjs → RadioGroupExtended.vue.es-BalV7gwp.mjs} +2 -2
- package/dist/{RadioGroupExtended.vue.es-Cf5R1P9a.js → RadioGroupExtended.vue.es-Dt6LH9Yh.js} +1 -1
- package/dist/{Section.vue.es-KRsHeFoT.mjs → Section.vue.es-D7eiXUbk.mjs} +1 -1
- package/dist/{Section.vue.es-CBZx5x53.js → Section.vue.es-zVXBHAL6.js} +1 -1
- package/dist/{SecurePaymentsKPI.vue_vue_type_script_setup_true_lang-UdGQMJGY.js → SecurePaymentsKPI.vue_vue_type_script_setup_true_lang-BdjYFrVC.js} +1 -1
- package/dist/{SecurePaymentsKPI.vue_vue_type_script_setup_true_lang-BVELHoUj.mjs → SecurePaymentsKPI.vue_vue_type_script_setup_true_lang-DudMRVka.mjs} +6 -6
- package/dist/Skeleton.vue_vue_type_script_setup_true_lang-D4sbq9nA.js +1 -0
- package/dist/{Skeleton.vue_vue_type_script_setup_true_lang-DRLoYWGY.mjs → Skeleton.vue_vue_type_script_setup_true_lang-D60YtA9z.mjs} +5 -5
- package/dist/StepInput.vue.es-C3Zm6Wc9.mjs +199 -0
- package/dist/StepInput.vue.es-mAnuCuDQ.js +1 -0
- package/dist/SubscriptionDetails.entry.ce-D4CsSoR9.js +1 -0
- package/dist/SubscriptionDetails.entry.ce-WEimiOex.mjs +1057 -0
- package/dist/{SubscriptionSchedules-1ikoGncQ.js → SubscriptionSchedules-Cm5Dt-1H.js} +1 -1
- package/dist/{SubscriptionSchedules-B6b6xf-E.mjs → SubscriptionSchedules-DrrEAPlx.mjs} +1 -1
- package/dist/{SubscriptionSchedules.vue_vue_type_script_setup_true_lang-Dv2bP9vv.mjs → SubscriptionSchedules.vue_vue_type_script_setup_true_lang-DHp_KtbF.mjs} +2284 -2341
- package/dist/SubscriptionSchedules.vue_vue_type_script_setup_true_lang-t2Awijf5.js +1 -0
- package/dist/{SubscriptionSummary.vue_vue_type_script_setup_true_lang-DvYZvTV9.mjs → SubscriptionSummary.vue_vue_type_script_setup_true_lang-3VYfm6Hm.mjs} +3 -3
- package/dist/{SubscriptionSummary.vue_vue_type_script_setup_true_lang-DZKl0Zxp.js → SubscriptionSummary.vue_vue_type_script_setup_true_lang-B41qZmcL.js} +1 -1
- package/dist/{SubscriptionsList.vue_vue_type_script_setup_true_lang-DTjZcOhj.js → SubscriptionsList.vue_vue_type_script_setup_true_lang-Bu-_clEa.js} +1 -1
- package/dist/{SubscriptionsList.vue_vue_type_script_setup_true_lang-DmeIKMYI.mjs → SubscriptionsList.vue_vue_type_script_setup_true_lang-DFU0IULg.mjs} +8 -8
- package/dist/{TooltipParagraph.vue.es-nGFfHF1A.mjs → TooltipParagraph.vue.es-BXbOJmjr.mjs} +3 -3
- package/dist/TooltipParagraph.vue.es-Cph6zT31.js +1 -0
- package/dist/{TrialChip.vue.es-DhC5Bpmy.js → TrialChip.vue.es-C_wgHGuN.js} +1 -1
- package/dist/{TrialChip.vue.es-eKgO6an3.mjs → TrialChip.vue.es-C_yRujip.mjs} +2 -2
- package/dist/{cn.es-BD7Afj5Q.mjs → cn.es-CGa6b2Lt.mjs} +2 -2
- package/dist/{cn.es-BLE3T5Rx.js → cn.es-D9YMDvG2.js} +1 -1
- package/dist/components/BillingInformation/BillingInformation.cjs +1 -1
- package/dist/components/BillingInformation/BillingInformation.mjs +4 -4
- package/dist/components/BillingInformationForm/BillingInformationForm.cjs +1 -1
- package/dist/components/BillingInformationForm/BillingInformationForm.mjs +246 -230
- package/dist/components/CustomerPaymentMethods/CustomerPaymentMethods.cjs +1 -1
- package/dist/components/CustomerPaymentMethods/CustomerPaymentMethods.mjs +4 -4
- package/dist/components/Invoice/Invoice.cjs +1 -1
- package/dist/components/Invoice/Invoice.mjs +201 -212
- 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 +2 -2
- package/dist/components/InvoicesList/InvoicesList.cjs +1 -1
- package/dist/components/InvoicesList/InvoicesList.mjs +3 -3
- package/dist/components/PaymentHistory/PaymentHistory.cjs +1 -1
- package/dist/components/PaymentHistory/PaymentHistory.mjs +4 -4
- package/dist/components/PaymentMethodForm/PaymentMethodForm.cjs +1 -1
- package/dist/components/PaymentMethodForm/PaymentMethodForm.mjs +5 -5
- package/dist/components/SubscriptionSchedules/SubscriptionSchedules.cjs +1 -1
- package/dist/components/SubscriptionSchedules/SubscriptionSchedules.mjs +4 -4
- package/dist/components/SubscriptionsList/SubscriptionsList.cjs +1 -1
- package/dist/components/SubscriptionsList/SubscriptionsList.mjs +5 -5
- package/dist/components/WalletBalances/WalletBalances.cjs +1 -1
- package/dist/components/WalletBalances/WalletBalances.mjs +3 -3
- package/dist/{customElements-CSzbVZIH.js → customElements-C963-LtW.js} +36 -32
- package/dist/{customElements-DT1YyL4O.mjs → customElements-D5DAoHRI.mjs} +231 -196
- package/dist/{customer-Cq4fF__H.mjs → customer-DKa1B2vp.mjs} +4 -4
- package/dist/{customer-CJonIvSm.js → customer-TE1FnGT0.js} +1 -1
- package/dist/{de-DE-BSlbAnPE.js → de-DE-B4TUdnUf.js} +1 -1
- package/dist/{de-DE-CyvjSD9b.mjs → de-DE-CLfzTbbX.mjs} +39 -6
- package/dist/de-DE-DaBBl-Ak.js +1 -0
- package/dist/{de-DE-DXsG-vXA.mjs → de-DE-jkW2dJrX.mjs} +28 -14
- package/dist/en-US-BNevqm0M.js +1 -0
- package/dist/{en-US-xQrWj8qI.mjs → en-US-D6SGRAch.mjs} +39 -6
- package/dist/en-US-J85TQRI8.js +1 -0
- package/dist/{en-US-C939IZ5i.mjs → en-US-SDhjlY_v.mjs} +20 -5
- package/dist/formControl-ODrpUvcA.js +1 -0
- package/dist/{index-BPU8tIml.mjs → formControl-dX7l8o3c.mjs} +160 -143
- package/dist/icon-sprite.svg.es-BZIz7-0d.mjs +4 -0
- package/dist/icon-sprite.svg.es-Ds6lDf5p.js +1 -0
- package/dist/index.cjs +1 -1
- package/dist/index.mjs +4 -4
- package/dist/{invoices-EamWI_jz.js → invoices-ClqTWYF9.js} +1 -1
- package/dist/{invoices-CVZOfEOY.mjs → invoices-DJTwftJv.mjs} +1 -1
- package/dist/it-IT-BkPbTueL.js +1 -0
- package/dist/{it-IT-DT3rfjOY.js → it-IT-CSYvGmpT.js} +1 -1
- package/dist/{it-IT-BxpwB3oJ.mjs → it-IT-CaaFToGB.mjs} +20 -6
- package/dist/{it-IT-C09oObBM.mjs → it-IT-Cym1UvvK.mjs} +39 -6
- package/dist/{nl-NL-DfkhOJKc.js → nl-NL-CpE4IgwO.js} +1 -1
- package/dist/{nl-NL-na2I4aiP.mjs → nl-NL-D0MQKaql.mjs} +34 -20
- package/dist/{nl-NL-BhNND_yi.mjs → nl-NL-D0c4x5C0.mjs} +39 -6
- package/dist/nl-NL-jIfAVGv0.js +1 -0
- package/dist/paymentMethods-AL2U_byg.js +1 -0
- package/dist/{paymentMethods-By1SebnO.mjs → paymentMethods-CWzJhcWK.mjs} +16 -14
- package/dist/{payments-Dnjg9Se4.js → payments-BmiHMlQt.js} +1 -1
- package/dist/{payments-BYZLQTJ-.mjs → payments-aXyfylwk.mjs} +6 -6
- package/dist/pricing.es-C07bgEZx.js +1 -0
- package/dist/pricing.es-QYWrKMUJ.mjs +30 -0
- package/dist/pricingPlanSchedules-BD4GIP_F.mjs +32 -0
- package/dist/pricingPlanSchedules-BfsMSvN0.js +1 -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 +10 -10
- package/dist/screens/PayInvoice/PayInvoice.cjs +1 -1
- package/dist/screens/PayInvoice/PayInvoice.mjs +57 -55
- package/dist/screens/PaymentMethodsManagement/PaymentMethodsManagement.cjs +1 -1
- package/dist/screens/PaymentMethodsManagement/PaymentMethodsManagement.mjs +9 -9
- package/dist/screens/SubscriptionDetails/SubscriptionDetails.cjs +1 -1
- package/dist/screens/SubscriptionDetails/SubscriptionDetails.mjs +3 -769
- package/dist/screens/SubscriptionManagement/SubscriptionManagement.cjs +1 -1
- package/dist/screens/SubscriptionManagement/SubscriptionManagement.mjs +243 -270
- package/dist/{subscription-CrVOr5MF.mjs → subscription-D1yHKUNc.mjs} +2 -2
- package/dist/{subscriptions-BKER9RUc.js → subscriptions-Cm83ckfl.js} +1 -1
- package/dist/{subscriptions-Gj3KgCZz.mjs → subscriptions-cnR5fnf7.mjs} +1 -1
- package/dist/types/components/{wallets/WalletModalShell.types.d.ts → payments/OnDemandPaymentModalShell/OnDemandPaymentModalShell.types.d.ts} +3 -3
- package/dist/types/components/payments/PaymentIntegrationForm/PaymentIntegrationForm.types.d.ts +5 -0
- package/dist/types/components/payments/PaymentIntegrationFormStripe/PaymentIntegrationFormStripeFrame.types.d.ts +5 -9
- package/dist/types/components/providers/ActionDispatchProvider/ActionDispatchProvider.vue.d.ts +7 -11
- package/dist/types/components/providers/AuthProvider/AuthProvider.vue.d.ts +7 -11
- package/dist/types/components/providers/ConfigProvider/ConfigProvider.vue.d.ts +7 -11
- package/dist/types/components/providers/CssOverridesProvider/CssOverridesProvider.vue.d.ts +7 -11
- package/dist/types/components/providers/EntryProvider/EntryProvider.vue.d.ts +7 -11
- package/dist/types/components/providers/ErrorBoundary/ErrorBoundary.vue.d.ts +7 -11
- package/dist/types/components/providers/ExperimentalFeatureProvider/ExperimentalFeatureProvider.vue.d.ts +7 -11
- package/dist/types/components/providers/HostElementProvider/HostElementProvider.vue.d.ts +7 -11
- package/dist/types/components/providers/LoggerProvider/LoggerProvider.types.d.ts +2 -2
- package/dist/types/components/providers/LoggerProvider/LoggerProvider.vue.d.ts +7 -11
- package/dist/types/components/providers/PortalProvider/PortalProvider.vue.d.ts +7 -11
- package/dist/types/components/providers/Provider/Provider.vue.d.ts +7 -11
- package/dist/types/components/providers/TeleportProvider/TeleportProvider.vue.d.ts +7 -11
- package/dist/types/components/providers/TranslationProvider/TranslationOverride.vue.d.ts +7 -11
- package/dist/types/components/providers/TranslationProvider/TranslationProvider.vue.d.ts +7 -11
- package/dist/types/components/subscriptions/ChargeOnDemandModal/ChargeOnDemandModal.types.d.ts +21 -0
- package/dist/types/components/subscriptions/OnDemandItemsCard/OnDemandItemsCard.types.d.ts +7 -0
- package/dist/types/public/screens/SubscriptionDetails/SubscriptionDetails.configuration.types.d.ts +27 -0
- package/dist/types/public/screens/SubscriptionDetails/SubscriptionDetails.entry.types.d.ts +1 -1
- package/dist/types/public/screens/SubscriptionDetails/SubscriptionDetails.types.d.ts +6 -5
- package/dist/types/services/paymentMethods.types.d.ts +4 -2
- package/dist/types/services/requests.types.d.ts +5 -0
- package/dist/types/vendor/@solvimon/solvimon-types/index.d.ts +5 -0
- package/dist/types/vendor/@solvimon/solvimon-types/types/AgentContext.d.ts +3 -0
- package/dist/types/vendor/@solvimon/solvimon-types/types/ApprovalPolicies.d.ts +6 -1
- package/dist/types/vendor/@solvimon/solvimon-types/types/ChargeOnDemandPricingItems.d.ts +23 -0
- package/dist/types/vendor/@solvimon/solvimon-types/types/CustomFields.d.ts +16 -4
- package/dist/types/vendor/@solvimon/solvimon-types/types/Embeddable.d.ts +8 -0
- package/dist/types/vendor/@solvimon/solvimon-types/types/Invoice.d.ts +21 -6
- package/dist/types/vendor/@solvimon/solvimon-types/types/OAuth.d.ts +28 -0
- package/dist/types/vendor/@solvimon/solvimon-types/types/PaymentAcceptor.d.ts +2 -1
- package/dist/types/vendor/@solvimon/solvimon-types/types/Permission.d.ts +1 -1
- package/dist/types/vendor/@solvimon/solvimon-types/types/Platform.d.ts +6 -1
- package/dist/types/vendor/@solvimon/solvimon-types/types/Portal.d.ts +5 -0
- package/dist/types/vendor/@solvimon/solvimon-types/types/PricingItemConfig.d.ts +5 -0
- package/dist/types/vendor/@solvimon/solvimon-types/types/PricingPlanGroups.d.ts +31 -0
- package/dist/types/vendor/@solvimon/solvimon-types/types/PricingPlanSchedule.d.ts +9 -1
- package/dist/types/vendor/@solvimon/solvimon-types/types/PricingPlanScheduleInfo.d.ts +1 -1
- package/dist/types/vendor/@solvimon/solvimon-types/types/PricingPlanSubscription.d.ts +3 -3
- package/dist/types/vendor/@solvimon/solvimon-types/types/PricingPlans.d.ts +3 -0
- package/dist/types/vendor/@solvimon/solvimon-types/types/Product.d.ts +2 -0
- package/dist/types/vendor/@solvimon/solvimon-types/types/ProductItem.d.ts +2 -0
- package/dist/types/vendor/@solvimon/solvimon-types/types/QuoteTemplates.d.ts +2 -0
- package/dist/types/vendor/@solvimon/solvimon-types/types/ResourceStatus.d.ts +1 -1
- package/dist/types/vendor/@solvimon/solvimon-types/types/SeatAssignment.d.ts +22 -0
- package/dist/types/vendor/@solvimon/solvimon-types/types/Wallet.d.ts +6 -0
- package/dist/types/vendor/@solvimon/solvimon-types/types/Workflows.d.ts +128 -1
- package/dist/{useActionDispatchProvider-DDHrhy3i.js → useActionDispatchProvider-CHkVQMaE.js} +1 -1
- package/dist/{useActionDispatchProvider-MjTckd4f.mjs → useActionDispatchProvider-DDYqIh3r.mjs} +1 -1
- package/dist/{useCustomer-BW0DBEJh.js → useCustomer-DGYtowRy.js} +1 -1
- package/dist/{useCustomer-CxnF7r8Z.mjs → useCustomer-XZKWsolE.mjs} +1 -1
- package/dist/{useCustomerFormLabels-zPc8QrwJ.mjs → useCustomerFormLabels-CcnkJLcB.mjs} +6 -6
- package/dist/useCustomerFormLabels-DAZziqYt.js +1 -0
- package/dist/{useExperimentalFeature-9teNYGuP.js → useExperimentalFeature-COOU6IZd.js} +1 -1
- package/dist/{useExperimentalFeature-NsSDg-e3.mjs → useExperimentalFeature-ierhOt9Q.mjs} +1 -1
- package/dist/{useInvoiceData-GQwk6fl4.mjs → useInvoiceData-BEK-7msA.mjs} +3 -3
- package/dist/{useInvoiceData-DvV2AsgC.js → useInvoiceData-CQRn8l9C.js} +1 -1
- package/dist/{useInvoicesList-Xnth6s6U.js → useInvoicesList-BQkKyyXa.js} +1 -1
- package/dist/{useInvoicesList-CGmFSQSg.mjs → useInvoicesList-C4I118KM.mjs} +7 -7
- package/dist/{useLoadInitialData-BvvaWeAe.mjs → useLoadInitialData-CR0kbYw8.mjs} +1 -1
- package/dist/{useLoadInitialData-Cjkc70u-.js → useLoadInitialData-CrKnBZs_.js} +1 -1
- package/dist/{usePaymentMethodAvailability-DKyscbom.js → usePaymentMethodAvailability-Ci6LeYKt.js} +1 -1
- package/dist/{usePaymentMethodAvailability-BWaaj3N3.mjs → usePaymentMethodAvailability-ZH-m3B-A.mjs} +12 -12
- package/dist/{usePaymentMethodOptions-l-wVAmIW.mjs → usePaymentMethodOptions-Ciifjo6c.mjs} +15 -13
- package/dist/usePaymentMethodOptions-Cqe92ZBn.js +1 -0
- package/dist/{usePaymentMethods-DvQVnsSV.mjs → usePaymentMethods-B-OKRyKd.mjs} +1 -1
- package/dist/{usePaymentMethods-BDFVB-kK.js → usePaymentMethods-BKwrl82-.js} +1 -1
- package/dist/usePayments-Bauj16B-.js +1 -0
- package/dist/{usePayments-D_dyuf6S.mjs → usePayments-CV85OV8V.mjs} +46 -41
- package/dist/{usePortal-BU4ibdWq.js → usePortal-DSLImEfr.js} +1 -1
- package/dist/{usePortal-Br5lYuPT.mjs → usePortal-H8Tv2TnZ.mjs} +1 -1
- package/dist/{useSubscription-DRBUt9H5.js → useSubscription-BiYNJT2e.js} +1 -1
- package/dist/{useSubscription-CqRae2I9.mjs → useSubscription-DqnxWNKg.mjs} +1 -1
- package/dist/{useTimePeriod.es-BxIGnCAP.mjs → useTimePeriod.es-B22-fno3.mjs} +1 -1
- package/dist/{useTimePeriod.es-DDos3-EH.js → useTimePeriod.es-D2aiyfd-.js} +1 -1
- package/dist/useWatchDebounced-B8iX7ykx.js +1 -0
- package/dist/useWatchDebounced-BHlBPcXB.mjs +20 -0
- package/package.json +11 -8
- package/dist/Checkout.entry.ce-D8O4qJ24.js +0 -2
- package/dist/CustomerWalletBalances.vue_vue_type_script_setup_true_lang-D_jcV7VG.js +0 -1
- package/dist/InvoiceSummary.vue.es-BOnvORpf.js +0 -1
- package/dist/PaymentIntegrationForm.vue_vue_type_script_setup_true_lang-De7h9-fH.js +0 -1
- package/dist/PaymentIntegrationForm.vue_vue_type_script_setup_true_lang-DnBLj1wZ.mjs +0 -141
- package/dist/PaymentIntegrationFormAdyen-BQXXwpUK.js +0 -98
- package/dist/PaymentIntegrationFormStripe-Bs4F7oK_.js +0 -102
- package/dist/PaymentMethod.vue.es-CXV_ThBY.js +0 -1
- package/dist/PaymentMethodForm.vue_vue_type_script_setup_true_lang-BwsRDlQJ.js +0 -1
- package/dist/PlanCustomizationEditor-0kEXoOcM.js +0 -1
- package/dist/PlanCustomizationEditor-Dv69xPbX.mjs +0 -877
- package/dist/PricingGroupSingleEditor.vue_vue_type_script_setup_true_lang-DmVJ2JQE.mjs +0 -131
- package/dist/PricingGroupSingleEditor.vue_vue_type_script_setup_true_lang-YsI__d0V.js +0 -1
- package/dist/Skeleton.vue_vue_type_script_setup_true_lang-DypW8aNJ.js +0 -1
- package/dist/SubscriptionSchedules.vue_vue_type_script_setup_true_lang-Cd56tuZb.js +0 -1
- package/dist/TooltipParagraph.vue.es-7IQdU3Tf.js +0 -1
- package/dist/de-DE-DXsDvO5y.js +0 -1
- package/dist/en-US-9xdcz3T5.js +0 -1
- package/dist/en-US-DHdI11k9.js +0 -1
- package/dist/icon-sprite.svg.es-Bt21fMEt.mjs +0 -4
- package/dist/icon-sprite.svg.es-Dauis9LS.js +0 -1
- package/dist/index-DwueOtPi.js +0 -1
- package/dist/it-IT-CcRIzP1A.js +0 -1
- package/dist/nl-NL-5PrgQl8q.js +0 -1
- package/dist/paymentMethods-Bwym8l9a.js +0 -1
- package/dist/types/components/subscriptions/SubscriptionManagement/SubscriptionManagement.types.d.ts +0 -47
- package/dist/useCustomerFormLabels-C773h3J0.js +0 -1
- package/dist/usePaymentMethodOptions-DuXKS36F.js +0 -1
- package/dist/usePayments-CIJocDhR.js +0 -1
- package/dist/useWatchDebounced-CAU1WI1P.js +0 -1
- package/dist/useWatchDebounced-DT5IicPp.mjs +0 -14
|
@@ -0,0 +1,199 @@
|
|
|
1
|
+
import { defineComponent as V, createPropsRestProxy as E, computed as d, openBlock as c, createBlock as m, unref as I, mergeProps as S, withCtx as u, createTextVNode as N, toDisplayString as w, useModel as D, ref as q, onMounted as A, watch as P, createSlots as U, createVNode as b, normalizeClass as x, createElementVNode as g, createCommentVNode as h, renderSlot as j, mergeModels as F } from "vue";
|
|
2
|
+
import { _ as z } from "./IconButton.vue.es-UlqwNPAX.mjs";
|
|
3
|
+
import { _ as H } from "./Input.vue.es-D9IjIWc-.mjs";
|
|
4
|
+
import { _ as y } from "./customElements-D5DAoHRI.mjs";
|
|
5
|
+
import { _ as L } from "./Chip.vue.es-CKCOY5T6.mjs";
|
|
6
|
+
const G = /* @__PURE__ */ V({
|
|
7
|
+
__name: "DeltaChip",
|
|
8
|
+
props: {
|
|
9
|
+
oldValue: {},
|
|
10
|
+
newValue: {},
|
|
11
|
+
intent: { default: "neutral" },
|
|
12
|
+
content: {},
|
|
13
|
+
removable: { type: Boolean },
|
|
14
|
+
size: {},
|
|
15
|
+
variant: {},
|
|
16
|
+
textClass: {},
|
|
17
|
+
tag: {},
|
|
18
|
+
hasChipBefore: { type: Boolean },
|
|
19
|
+
hasChipAfter: { type: Boolean }
|
|
20
|
+
},
|
|
21
|
+
setup(e) {
|
|
22
|
+
const t = E(e, ["oldValue", "newValue", "intent"]), a = d(() => {
|
|
23
|
+
const o = e.newValue - e.oldValue;
|
|
24
|
+
return `${o >= 0 ? "+" : ""}${o}`;
|
|
25
|
+
});
|
|
26
|
+
return (o, f) => (c(), m(I(L), S(t, {
|
|
27
|
+
intent: e.intent,
|
|
28
|
+
class: "pointer-events-none select-none"
|
|
29
|
+
}), {
|
|
30
|
+
default: u(() => [
|
|
31
|
+
N(w(a.value), 1)
|
|
32
|
+
]),
|
|
33
|
+
_: 1
|
|
34
|
+
}, 16, ["intent"]));
|
|
35
|
+
}
|
|
36
|
+
}), J = { class: "flex items-center gap-1.5" }, Y = /* @__PURE__ */ V({
|
|
37
|
+
__name: "StepInput",
|
|
38
|
+
props: /* @__PURE__ */ F({
|
|
39
|
+
step: { default: 1 },
|
|
40
|
+
min: { default: 0 },
|
|
41
|
+
max: {},
|
|
42
|
+
initialValue: { default: 1 },
|
|
43
|
+
unitName: {},
|
|
44
|
+
showDelta: { type: Boolean, default: !1 },
|
|
45
|
+
size: { default: "md" },
|
|
46
|
+
name: {},
|
|
47
|
+
required: { type: Boolean },
|
|
48
|
+
label: {},
|
|
49
|
+
error: {},
|
|
50
|
+
disabled: { type: Boolean, default: !1 }
|
|
51
|
+
}, {
|
|
52
|
+
modelValue: { required: !0 },
|
|
53
|
+
modelModifiers: {}
|
|
54
|
+
}),
|
|
55
|
+
emits: ["update:modelValue"],
|
|
56
|
+
setup(e) {
|
|
57
|
+
const t = e, a = D(e, "modelValue"), o = q(null), f = d(() => {
|
|
58
|
+
if (t.unitName)
|
|
59
|
+
return t.unitName[a.value === 1 ? "singular" : "plural"];
|
|
60
|
+
}), $ = () => {
|
|
61
|
+
t.max && a.value + t.step > t.max || (a.value += t.step);
|
|
62
|
+
}, B = () => {
|
|
63
|
+
a.value - t.step < t.min || (a.value -= t.step);
|
|
64
|
+
};
|
|
65
|
+
function p(l) {
|
|
66
|
+
var n;
|
|
67
|
+
const s = (n = o.value) == null ? void 0 : n.el;
|
|
68
|
+
if (!s) return;
|
|
69
|
+
const i = parseInt(`${l}`);
|
|
70
|
+
a.value = i, s.innerText = `${i}`, s.focus();
|
|
71
|
+
const v = document.createRange();
|
|
72
|
+
v.selectNodeContents(s), v.collapse(!1);
|
|
73
|
+
const r = window.getSelection();
|
|
74
|
+
r == null || r.removeAllRanges(), r == null || r.addRange(v);
|
|
75
|
+
}
|
|
76
|
+
const C = (l) => {
|
|
77
|
+
const n = l.target;
|
|
78
|
+
n instanceof HTMLElement && !Number.isNaN(parseInt(n.innerText)) && p(n.innerText);
|
|
79
|
+
}, T = () => {
|
|
80
|
+
var l;
|
|
81
|
+
const n = (l = o.value) == null ? void 0 : l.el;
|
|
82
|
+
if (!n) return;
|
|
83
|
+
const s = parseInt(n.innerText);
|
|
84
|
+
(Number.isNaN(s) || s < t.min) && (a.value = t.min, n.innerText = `${t.min}`);
|
|
85
|
+
}, M = d(() => t.disabled ? !1 : t.max ? a.value + t.step < t.max : !0), R = d(() => t.disabled ? !1 : a.value - t.step >= t.min);
|
|
86
|
+
function k() {
|
|
87
|
+
var l;
|
|
88
|
+
const n = (l = o.value) == null ? void 0 : l.el;
|
|
89
|
+
if (!n) return;
|
|
90
|
+
n.focus();
|
|
91
|
+
const s = document.createRange();
|
|
92
|
+
s.selectNodeContents(n);
|
|
93
|
+
const i = window.getSelection();
|
|
94
|
+
i == null || i.removeAllRanges(), i == null || i.addRange(s);
|
|
95
|
+
}
|
|
96
|
+
return A(() => {
|
|
97
|
+
var l;
|
|
98
|
+
const n = (l = o.value) == null ? void 0 : l.el;
|
|
99
|
+
n && (n.innerText = `${a.value}`);
|
|
100
|
+
}), P(
|
|
101
|
+
() => a.value,
|
|
102
|
+
(l) => {
|
|
103
|
+
var n, s;
|
|
104
|
+
((s = (n = o.value) == null ? void 0 : n.el) == null ? void 0 : s.innerText) !== `${l}` && p(l);
|
|
105
|
+
}
|
|
106
|
+
), (l, n) => (c(), m(H, {
|
|
107
|
+
modelValue: a.value,
|
|
108
|
+
"onUpdate:modelValue": n[0] || (n[0] = (s) => a.value = s),
|
|
109
|
+
type: "number",
|
|
110
|
+
class: "text-transparent [appearance:textfield] [&::-webkit-inner-spin-button]:appearance-none [&::-webkit-outer-spin-button]:appearance-none",
|
|
111
|
+
"prefix-class": {
|
|
112
|
+
"!px-0 w-5": e.size === "sm",
|
|
113
|
+
"!px-0 w-6": e.size === "md",
|
|
114
|
+
"!px-0 w-7": e.size === "lg"
|
|
115
|
+
},
|
|
116
|
+
"suffix-class": {
|
|
117
|
+
"!px-0 w-5": e.size === "sm",
|
|
118
|
+
"!px-0 w-6": e.size === "md",
|
|
119
|
+
"!px-0 w-7": e.size === "lg"
|
|
120
|
+
},
|
|
121
|
+
size: e.size,
|
|
122
|
+
label: e.label,
|
|
123
|
+
disabled: e.disabled,
|
|
124
|
+
name: e.name,
|
|
125
|
+
required: e.required,
|
|
126
|
+
error: e.error
|
|
127
|
+
}, U({
|
|
128
|
+
prefix: u(() => [
|
|
129
|
+
g("div", {
|
|
130
|
+
class: "absolute inset-0 flex items-center justify-center",
|
|
131
|
+
onMousedown: k
|
|
132
|
+
}, [
|
|
133
|
+
g("div", J, [
|
|
134
|
+
b(y, {
|
|
135
|
+
ref_key: "contentEditableRef",
|
|
136
|
+
ref: o,
|
|
137
|
+
tag: "span",
|
|
138
|
+
variant: e.size === "sm" ? "body" : "body-lg",
|
|
139
|
+
contenteditable: !e.disabled,
|
|
140
|
+
class: x(["outline-none", { "pointer-events-none select-none": e.disabled }]),
|
|
141
|
+
weight: "semibold",
|
|
142
|
+
onInput: C,
|
|
143
|
+
onBlur: T
|
|
144
|
+
}, null, 8, ["variant", "contenteditable", "class"]),
|
|
145
|
+
f.value ? (c(), m(y, {
|
|
146
|
+
key: 0,
|
|
147
|
+
tag: "span",
|
|
148
|
+
color: "subtle",
|
|
149
|
+
class: "pointer-events-none select-none"
|
|
150
|
+
}, {
|
|
151
|
+
default: u(() => [
|
|
152
|
+
N(w(" ") + w(f.value), 1)
|
|
153
|
+
]),
|
|
154
|
+
_: 1
|
|
155
|
+
})) : h("", !0),
|
|
156
|
+
e.showDelta ? (c(), m(G, {
|
|
157
|
+
key: 1,
|
|
158
|
+
"old-value": t.initialValue,
|
|
159
|
+
"new-value": a.value,
|
|
160
|
+
class: "pointer-events-none ml-0.5 select-none"
|
|
161
|
+
}, null, 8, ["old-value", "new-value"])) : h("", !0)
|
|
162
|
+
])
|
|
163
|
+
], 32),
|
|
164
|
+
b(z, {
|
|
165
|
+
disabled: !R.value,
|
|
166
|
+
type: "button",
|
|
167
|
+
intent: "subtle",
|
|
168
|
+
size: "sm",
|
|
169
|
+
class: x(["!h-full select-none rounded-br-none rounded-tr-none", { "!w-7": e.size === "lg", "!w-5": e.size === "sm", "!w-6": e.size === "md" }]),
|
|
170
|
+
icon: "remove",
|
|
171
|
+
onMousedown: B
|
|
172
|
+
}, null, 8, ["disabled", "class"])
|
|
173
|
+
]),
|
|
174
|
+
suffix: u(() => [
|
|
175
|
+
b(z, {
|
|
176
|
+
disabled: !M.value,
|
|
177
|
+
type: "button",
|
|
178
|
+
intent: "subtle",
|
|
179
|
+
size: "sm",
|
|
180
|
+
class: x(["!h-full select-none rounded-bl-none rounded-tl-none", { "!w-7": e.size === "lg", "!w-5": e.size === "sm", "!w-6": e.size === "md" }]),
|
|
181
|
+
icon: "add",
|
|
182
|
+
onMousedown: $
|
|
183
|
+
}, null, 8, ["disabled", "class"])
|
|
184
|
+
]),
|
|
185
|
+
_: 2
|
|
186
|
+
}, [
|
|
187
|
+
l.$slots.helper ? {
|
|
188
|
+
name: "helper",
|
|
189
|
+
fn: u(() => [
|
|
190
|
+
j(l.$slots, "helper")
|
|
191
|
+
]),
|
|
192
|
+
key: "0"
|
|
193
|
+
} : void 0
|
|
194
|
+
]), 1032, ["modelValue", "prefix-class", "suffix-class", "size", "label", "disabled", "name", "required", "error"]));
|
|
195
|
+
}
|
|
196
|
+
});
|
|
197
|
+
export {
|
|
198
|
+
Y as _
|
|
199
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const e=require("vue"),f=require("./IconButton.vue.es-Bwdfu-jm.js"),V=require("./Input.vue.es-B47l_feL.js"),v=require("./customElements-C963-LtW.js"),C=require("./Chip.vue.es-D60gTbfe.js"),N=e.defineComponent({__name:"DeltaChip",props:{oldValue:{},newValue:{},intent:{default:"neutral"},content:{},removable:{type:Boolean},size:{},variant:{},textClass:{},tag:{},hasChipBefore:{type:Boolean},hasChipAfter:{type:Boolean}},setup(n){const l=e.createPropsRestProxy(n,["oldValue","newValue","intent"]),o=e.computed(()=>{const i=n.newValue-n.oldValue;return`${i>=0?"+":""}${i}`});return(i,d)=>(e.openBlock(),e.createBlock(e.unref(C._sfc_main),e.mergeProps(l,{intent:n.intent,class:"pointer-events-none select-none"}),{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(o.value),1)]),_:1},16,["intent"]))}}),y={class:"flex items-center gap-1.5"},B=e.defineComponent({__name:"StepInput",props:e.mergeModels({step:{default:1},min:{default:0},max:{},initialValue:{default:1},unitName:{},showDelta:{type:Boolean,default:!1},size:{default:"md"},name:{},required:{type:Boolean},label:{},error:{},disabled:{type:Boolean,default:!1}},{modelValue:{required:!0},modelModifiers:{}}),emits:["update:modelValue"],setup(n){const l=n,o=e.useModel(n,"modelValue"),i=e.ref(null),d=e.computed(()=>{if(l.unitName)return l.unitName[o.value===1?"singular":"plural"]}),b=()=>{l.max&&o.value+l.step>l.max||(o.value+=l.step)},x=()=>{o.value-l.step<l.min||(o.value-=l.step)};function m(a){var t;const s=(t=i.value)==null?void 0:t.el;if(!s)return;const u=parseInt(`${a}`);o.value=u,s.innerText=`${u}`,s.focus();const c=document.createRange();c.selectNodeContents(s),c.collapse(!1);const r=window.getSelection();r==null||r.removeAllRanges(),r==null||r.addRange(c)}const p=a=>{const t=a.target;t instanceof HTMLElement&&!Number.isNaN(parseInt(t.innerText))&&m(t.innerText)},w=()=>{var a;const t=(a=i.value)==null?void 0:a.el;if(!t)return;const s=parseInt(t.innerText);(Number.isNaN(s)||s<l.min)&&(o.value=l.min,t.innerText=`${l.min}`)},g=e.computed(()=>l.disabled?!1:l.max?o.value+l.step<l.max:!0),h=e.computed(()=>l.disabled?!1:o.value-l.step>=l.min);function z(){var a;const t=(a=i.value)==null?void 0:a.el;if(!t)return;t.focus();const s=document.createRange();s.selectNodeContents(t);const u=window.getSelection();u==null||u.removeAllRanges(),u==null||u.addRange(s)}return e.onMounted(()=>{var a;const t=(a=i.value)==null?void 0:a.el;t&&(t.innerText=`${o.value}`)}),e.watch(()=>o.value,a=>{var t,s;((s=(t=i.value)==null?void 0:t.el)==null?void 0:s.innerText)!==`${a}`&&m(a)}),(a,t)=>(e.openBlock(),e.createBlock(V._sfc_main,{modelValue:o.value,"onUpdate:modelValue":t[0]||(t[0]=s=>o.value=s),type:"number",class:"text-transparent [appearance:textfield] [&::-webkit-inner-spin-button]:appearance-none [&::-webkit-outer-spin-button]:appearance-none","prefix-class":{"!px-0 w-5":n.size==="sm","!px-0 w-6":n.size==="md","!px-0 w-7":n.size==="lg"},"suffix-class":{"!px-0 w-5":n.size==="sm","!px-0 w-6":n.size==="md","!px-0 w-7":n.size==="lg"},size:n.size,label:n.label,disabled:n.disabled,name:n.name,required:n.required,error:n.error},e.createSlots({prefix:e.withCtx(()=>[e.createElementVNode("div",{class:"absolute inset-0 flex items-center justify-center",onMousedown:z},[e.createElementVNode("div",y,[e.createVNode(v._sfc_main,{ref_key:"contentEditableRef",ref:i,tag:"span",variant:n.size==="sm"?"body":"body-lg",contenteditable:!n.disabled,class:e.normalizeClass(["outline-none",{"pointer-events-none select-none":n.disabled}]),weight:"semibold",onInput:p,onBlur:w},null,8,["variant","contenteditable","class"]),d.value?(e.openBlock(),e.createBlock(v._sfc_main,{key:0,tag:"span",color:"subtle",class:"pointer-events-none select-none"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(" ")+e.toDisplayString(d.value),1)]),_:1})):e.createCommentVNode("",!0),n.showDelta?(e.openBlock(),e.createBlock(N,{key:1,"old-value":l.initialValue,"new-value":o.value,class:"pointer-events-none ml-0.5 select-none"},null,8,["old-value","new-value"])):e.createCommentVNode("",!0)])],32),e.createVNode(f._sfc_main,{disabled:!h.value,type:"button",intent:"subtle",size:"sm",class:e.normalizeClass(["!h-full select-none rounded-br-none rounded-tr-none",{"!w-7":n.size==="lg","!w-5":n.size==="sm","!w-6":n.size==="md"}]),icon:"remove",onMousedown:x},null,8,["disabled","class"])]),suffix:e.withCtx(()=>[e.createVNode(f._sfc_main,{disabled:!g.value,type:"button",intent:"subtle",size:"sm",class:e.normalizeClass(["!h-full select-none rounded-bl-none rounded-tl-none",{"!w-7":n.size==="lg","!w-5":n.size==="sm","!w-6":n.size==="md"}]),icon:"add",onMousedown:b},null,8,["disabled","class"])]),_:2},[a.$slots.helper?{name:"helper",fn:e.withCtx(()=>[e.renderSlot(a.$slots,"helper")]),key:"0"}:void 0]),1032,["modelValue","prefix-class","suffix-class","size","label","disabled","name","required","error"]))}});exports._sfc_main=B;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const e=require("vue"),F=require("./Alert.vue.es-RyK53a2P.js"),D=require("./Button.vue.es-qGvnOKnK.js"),L=require("./ErrorNotification.vue.es-BX9dHEc-.js"),m=require("./customElements-C963-LtW.js"),j=require("./ContentWithAsideLayout-RSdKXqAf.js"),O=require("./useActionDispatchProvider-CHkVQMaE.js"),E=require("./subscription-ZA62t4E9.js"),$=require("./CustomerWalletBalances.vue_vue_type_script_setup_true_lang-hBo2Y2mJ.js"),W=require("./CustomerPaymentMethods.vue_vue_type_script_setup_true_lang-C0lJ_ESU.js"),Y=require("./EmptyStatePlaceholder.vue_vue_type_script_setup_true_lang-cSQeqr0A.js"),z=require("./Skeleton.vue_vue_type_script_setup_true_lang-D4sbq9nA.js"),M=require("./Section.vue.es-zVXBHAL6.js"),X=require("./pricing-BVAld27Y.js"),P=require("./formatting.es-C72Nsrmh.js"),G=require("./PaymentMethod.vue.es-CJcSZ9lN.js"),H=require("./Modal.vue.es-8LN4gBh0.js"),Z=require("./subscriptions-Cm83ckfl.js"),J=require("./SubscriptionSummary.vue_vue_type_script_setup_true_lang-B41qZmcL.js"),K=require("./api.es-duCDtZD9.js"),Q=require("./useIncrementalLoading-CaWOE8Xl.js"),ee=require("./paymentMethods-AL2U_byg.js"),te=require("./error-CmduqgVq.js"),ne=require("./useSubscription-BiYNJT2e.js"),ie=require("./useCustomer-DGYtowRy.js"),ae=require("./usePaymentMethods-BKwrl82-.js"),oe=require("./useLoadInitialData-CrKnBZs_.js"),se=require("./pricingPlanSchedules-BfsMSvN0.js"),re=require("./useService-H7BjLg8P.js"),ce=require("./pricingPlanSchedule-BM8vsKkV.js"),A=require("./getComposedString.es-haS4bAj7.js"),q=require("./pricing.es-C07bgEZx.js"),le=require("./pricingItemConfigs.es-D4aYkYcf.js"),de=require("./sessionReference-m_6Rp4X1.js"),R=()=>{const{$t:t}=m.useIntl();return{getPriceLabel:n=>{if(!n.price)return;const i=P.formatAmount(n.price);return n.priceType==="FIXED"?i:t({defaultMessage:"{price} per unit",description:"The listed price of an on-demand item charged per unit",id:"charge_on_demand.item.price_per_unit"},{price:i})}}};function ue({subscription:t}){const{dispatchAction:a}=O.useActionDispatchProvider(),n=e.computed(()=>{if(!t.value)return!1;const l=t.value.inactive_periods;return!l||l.length===0}),i=e.computed(()=>{var g;const l=(g=t.value)==null?void 0:g.inactive_periods;return Array.isArray(l)&&l.length>0}),o=e.ref();return{isCancellable:n,isRenewable:i,pendingVariant:o,cancel:()=>{t.value&&(o.value="CANCEL")},renew:()=>{t.value&&(o.value="RENEW")},dismiss:()=>{o.value=void 0},manage:()=>{t.value&&a({action:"manage-subscription",data:{subscriptionId:t.value.id}})}}}function pe(t){var i,o,s,c,r,f,l;const a=(s=(o=(i=t.items)==null?void 0:i[0])==null?void 0:o.configs)==null?void 0:s[0],n=(r=(c=a==null?void 0:a.details)==null?void 0:c.bands)==null?void 0:r[0];return{amount:(n==null?void 0:n.amount)??(n==null?void 0:n.fixed_amount),billingPeriod:((f=a==null?void 0:a.details)==null?void 0:f.pricing_period)??((l=a==null?void 0:a.details)==null?void 0:l.billing_period)}}function me(t){var i,o,s;const a=new Set((((i=t.pricing_plan_schedule)==null?void 0:i.enabled_pricings)??[]).map(({pricing_id:c})=>c));return a.size===0?[]:(((s=(o=t.pricing_plan_version)==null?void 0:o.pricing_categories)==null?void 0:s.flatMap(c=>c.pricing_groups??[]))??[]).flatMap(c=>(c.pricings??[]).filter(r=>a.has(r.id)).map(r=>({pricingId:r.id,pricingGroupId:c.id,groupName:c.name,name:X.getNameFromPricing(r)||c.name,...pe(r)})))}const fe={class:"sv-enabled-pricings-list__item-body flex items-center gap-4"},ge={class:"sv-enabled-pricings-list__item-content grow"},be=e.defineComponent({__name:"EnabledPricingsListItem",props:{entry:{type:Object}},emits:["upgrade"],setup(t){const a=t,{$t:n}=m.useIntl(),i=e.computed(()=>{const{amount:o,billingPeriod:s}=a.entry;if(o)return s?n({defaultMessage:"{amount} per {period}",id:"enabled_pricings_list.item.price",description:'The recurring price of an enabled pricing, e.g. "€ 100,00 per month"'},{amount:P.formatAmount(o),period:P.formatBillingPeriod(s,{short:!0,hideValueForExactPeriods:!0})}):P.formatAmount(o)});return(o,s)=>(e.openBlock(),e.createBlock(e.unref(M._sfc_main),{class:"sv-enabled-pricings-list__item"},{default:e.withCtx(()=>[e.createElementVNode("div",fe,[e.createElementVNode("div",ge,[e.createVNode(e.unref(m._sfc_main),{tag:"span",variant:"body-xs",color:"subtle",class:"sv-enabled-pricings-list__item-group"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.entry.groupName),1)]),_:1}),e.createVNode(e.unref(m._sfc_main),{tag:"h3",variant:"heading-3","no-spacing":"",class:"sv-enabled-pricings-list__item-name"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.entry.name),1)]),_:1}),i.value?(e.openBlock(),e.createBlock(e.unref(m._sfc_main),{key:0,tag:"span",variant:"body-sm",color:"subtle",class:"sv-enabled-pricings-list__item-price"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(i.value),1)]),_:1})):e.createCommentVNode("",!0)]),e.createVNode(e.unref(D._sfc_main),{intent:"secondary",class:"sv-action sv-action--secondary sv-enabled-pricings-list__item-upgrade shrink-0",type:"button",size:"xs",onClick:s[0]||(s[0]=c=>o.$emit("upgrade",t.entry))},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(n)({defaultMessage:"Upgrade",id:"enabled_pricings_list.item.upgrade_button.label",description:"Label for the button that changes which pricing is enabled for a group"})),1)]),_:1})])]),_:1}))}}),he={class:"sv-enabled-pricings-list__items grid grid-cols-1 gap-2"},_e=e.defineComponent({__name:"EnabledPricingsList",props:{pricingPlanSchedule:{type:Object}},emits:["upgrade"],setup(t){const a=t,{$t:n}=m.useIntl(),i=e.computed(()=>me(a.pricingPlanSchedule));return(o,s)=>i.value.length>0?(e.openBlock(),e.createBlock(e.unref(M._sfc_main),{key:0,class:"sv-enabled-pricings-list","content-background":"none","no-border":"","no-spacing":"",title:e.unref(n)({defaultMessage:"Upgrades",id:"enabled_pricings_list.title",description:"Title for the block listing the pricings enabled on a subscription"})},{default:e.withCtx(()=>[e.createElementVNode("div",he,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,c=>(e.openBlock(),e.createBlock(be,{key:c.pricingId,entry:c,onUpgrade:s[0]||(s[0]=r=>o.$emit("upgrade",r))},null,8,["entry"]))),128))])]),_:1},8,["title"])):e.createCommentVNode("",!0)}}),ve={class:"sv-on-demand-items-card__items grid grid-cols-1 gap-1"},ye={key:0,class:"sv-on-demand-items-card__more"},T=2,we=e.defineComponent({__name:"OnDemandItemsCard",props:{items:{type:Array}},emits:["order"],setup(t){const a=t,{$t:n}=m.useIntl(),{getPriceLabel:i}=R(),o=e.computed(()=>a.items.slice(0,T).map(c=>({item:c,priceLabel:i(c)}))),s=e.computed(()=>Math.max(a.items.length-T,0));return(c,r)=>(e.openBlock(),e.createBlock(e.unref(M._sfc_main),{class:"sv-on-demand-items-card","content-background":"none","no-border":"","no-spacing":"",title:e.unref(n)({defaultMessage:"Available on demand items",id:"on_demand_items_card.title",description:"Title for the block that offers the on-demand items of a subscription"})},{right:e.withCtx(()=>[e.createVNode(e.unref(D._sfc_main),{class:"sv-action sv-action--secondary sv-on-demand-items-card__order",type:"button",size:"sm",intent:"secondary",onClick:r[0]||(r[0]=f=>c.$emit("order"))},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(n)({defaultMessage:"Purchase",id:"on_demand_items_card.order_button.label",description:"Label for the button that opens the on-demand order form"})),1)]),_:1})]),default:e.withCtx(()=>[e.createElementVNode("ul",ve,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.value,({item:f,priceLabel:l})=>(e.openBlock(),e.createElementBlock("li",{key:f.pricingItemId,class:"sv-on-demand-items-card__item"},[e.createVNode(e.unref(M._sfc_main),{"no-spacing":"","content-classes":"flex flex-col px-4 py-3"},{default:e.withCtx(()=>[e.createVNode(e.unref(m._sfc_main),{tag:"span",weight:"semibold","no-spacing":"",class:"sv-on-demand-items-card__item-name break-words"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(f.name),1)]),_:2},1024),l?(e.openBlock(),e.createBlock(e.unref(m._sfc_main),{key:0,tag:"span",variant:"body-sm",color:"subtle","no-spacing":"",class:"sv-on-demand-items-card__item-price"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(l),1)]),_:2},1024)):e.createCommentVNode("",!0)]),_:2},1024)]))),128)),s.value>0?(e.openBlock(),e.createElementBlock("li",ye,[e.createVNode(e.unref(M._sfc_main),{"no-spacing":"","content-classes":"px-4 py-3 text-center"},{default:e.withCtx(()=>[e.createVNode(e.unref(m._sfc_main),{tag:"span",weight:"semibold",color:"secondary","no-spacing":""},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(n)({defaultMessage:"+ {count} available",id:"on_demand_items_card.more_available",description:"Shown below the first on-demand items with the number of items not listed"},{count:String(s.value)})),1)]),_:1})]),_:1})])):e.createCommentVNode("",!0)])]),_:1},8,["title"]))}});function Ce({variant:t,renewableUntil:a,billingPeriodEndsAt:n}){const{$t:i}=m.useIntl(),o=e.computed(()=>t.value==="RENEW"),s=e.computed(()=>o.value?i({defaultMessage:"Renew subscription",description:"Title of the renew subscription confirmation modal",id:"subscription_cancellation_modal.renew.title"}):i({defaultMessage:"Cancel subscription",description:"Title of the cancel subscription confirmation modal",id:"subscription_cancellation_modal.cancel.title"})),c=e.computed(()=>o.value?a.value?i({defaultMessage:"You can renew your subscription until {date}. After this period you can only create a new subscription.",description:"Explanation of the deadline for undoing a cancellation, shown in the renew subscription modal",id:"subscription_cancellation_modal.renew.explanation_with_date"},{date:a.value}):i({defaultMessage:"Your subscription will continue as before, and billing will resume on its usual schedule.",description:"Explanation of what happens when a cancellation is undone, shown in the renew subscription modal when no end date is known",id:"subscription_cancellation_modal.renew.explanation"}):n.value?i({defaultMessage:"Your subscription will be canceled, but you’ll continue to have access until {date}.",description:"Explanation of what happens when a running subscription is cancelled, naming the date access ends, shown in the cancel subscription modal",id:"subscription_cancellation_modal.cancel.explanation_with_date"},{date:n.value}):i({defaultMessage:"Your subscription will be canceled, but you’ll continue to have access until the end of the billing period.",description:"Explanation of what happens when a running subscription is cancelled, shown in the cancel subscription modal",id:"subscription_cancellation_modal.cancel.explanation"})),r=e.computed(()=>o.value?i({defaultMessage:"Renew subscription",description:"Label of the confirm button in the renew subscription modal",id:"subscription_cancellation_modal.renew.confirm_button.label"}):i({defaultMessage:"Cancel subscription",description:"Label of the confirm button in the cancel subscription modal",id:"subscription_cancellation_modal.cancel.confirm_button.label"})),f=e.computed(()=>i({defaultMessage:"Cancel",description:"Label of the button that dismisses the cancellation modal",id:"subscription_cancellation_modal.cancel_button.label"})),l=e.computed(()=>o.value?i({defaultMessage:"We could not renew your subscription. Please try again.",description:"Error shown when undoing a cancellation fails",id:"subscription_cancellation_modal.renew.error"}):i({defaultMessage:"We could not cancel your subscription. Please try again.",description:"Error shown when cancelling a subscription fails",id:"subscription_cancellation_modal.cancel.error"}));return{title:s,explanation:c,confirmButtonText:r,cancelButtonText:f,errorMessage:l}}const Se=50;function ke(){const{getPaymentMethods:t}=ee.createPaymentMethodsService(),a=e.shallowRef();return{paymentMethod:a,get:async({customerId:i,paymentMethodId:o})=>{const s=await K.getPaginatedFullList(async c=>{const r=await t({customerId:i,pagination:{page:c,pageSize:Se}});if(!Q.isApiSuccessCollectionResponse(r))throw new Error("Could not load the customer’s payment methods.");return r});return a.value=s.data.find(({id:c})=>c===o),a.value}}}const Be={class:"sv-subscription-cancellation-modal sv-subscription-cancellation-modal__body flex flex-col gap-3"},xe={key:0,class:"sv-subscription-cancellation-modal__meta flex flex-wrap items-center gap-x-6 gap-y-2 px-3 pb-2"},Ie={key:0,class:"sv-subscription-cancellation-modal__renews flex gap-1"},Me=e.defineComponent({__name:"SubscriptionCancellationModal",props:{showModal:{type:Boolean},variant:{type:null},subscription:{type:Object},avatar:{type:String}},emits:["confirmed","close"],setup(t,{emit:a}){const n=t,i=a,{$t:o,formatDate:s}=m.useIntl(),c=m.useLogger(),{setSubscriptionCancellation:r}=Z.createSubscriptionsService(),f=e.computed(()=>n.variant),l=e.computed(()=>{var d;const p=((d=n.subscription)==null?void 0:d.inactive_periods)??[],u=p.find(({type:h})=>h==="CANCEL")??p[0];if(u)return s({date:u.start_at,format:"date",offsetType:"local"})}),g=e.computed(()=>{var u,d;const p=(d=(u=n.subscription)==null?void 0:u.next_invoice)==null?void 0:d.invoice_date;if(p)return s({date:p,format:"date",offsetType:"local"})}),v=g,k=e.computed(()=>{var p,u;return(((u=(p=E.getMostRecentScheduleInfo(n.subscription))==null?void 0:p.pricing_plan_schedule)==null?void 0:u.enabled_pricings)??[]).map(({pricing_id:d})=>d).filter(d=>!!d)}),{title:C,explanation:B,confirmButtonText:_,cancelButtonText:x,errorMessage:S}=Ce({variant:f,renewableUntil:l,billingPeriodEndsAt:g}),{paymentMethod:y,get:I}=ke();e.watch([()=>n.showModal,()=>{var p;return(p=n.subscription)==null?void 0:p.payment_method_id},()=>{var p;return(p=n.subscription)==null?void 0:p.customer_id}],([p,u,d])=>{var h;!p||!u||!d||u!==((h=y.value)==null?void 0:h.id)&&I({customerId:d,paymentMethodId:u}).catch(()=>{})},{immediate:!0});const b=e.ref(!1),w=e.ref(!1);e.watch(()=>n.showModal,p=>{p&&(w.value=!1)});const N=async()=>{if(!(!n.subscription||!n.variant||b.value)){b.value=!0,w.value=!1;try{await r({id:n.subscription.id,variant:n.variant}),i("confirmed"),i("close")}catch(p){c.error("SUBSCRIPTION_CANCELLATION_FAILED","Failed to change the cancellation state of a subscription",{variant:n.variant},p),w.value=!0}finally{b.value=!1}}},V=()=>{b.value||i("close")};return(p,u)=>(e.openBlock(),e.createBlock(e.unref(H.Modal),{size:"md","show-modal":t.showModal,title:e.unref(C),"confirm-button-text":e.unref(_),"cancel-button-text":e.unref(x),"is-loading":b.value,"no-click-away":b.value,"no-backdrop-close":b.value,onConfirm:N,onClose:V},{body:e.withCtx(()=>[e.createElementVNode("div",Be,[e.createVNode(e.unref(m._sfc_main),{variant:"body-sm",color:"subtle",tag:"p",class:"sv-subscription-cancellation-modal__explanation"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(B)),1)]),_:1}),t.subscription?(e.openBlock(),e.createBlock(e.unref(M._sfc_main),{key:0,"no-spacing":"",class:"sv-subscription-cancellation-modal__subscription"},{default:e.withCtx(()=>[e.createVNode(J._sfc_main,{subscription:t.subscription,avatar:t.avatar,"enabled-pricing-ids":k.value},null,8,["subscription","avatar","enabled-pricing-ids"]),e.unref(v)||e.unref(y)?(e.openBlock(),e.createElementBlock("div",xe,[e.unref(v)?(e.openBlock(),e.createElementBlock("div",Ie,[e.createVNode(e.unref(m._sfc_main),{tag:"span",variant:"body-xs",color:"secondary",weight:"semibold"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(o)({defaultMessage:"Renews",description:"Label before the date the subscription renews, shown in the cancel subscription modal",id:"subscription_cancellation_modal.renews_label"})),1)]),_:1}),e.createVNode(e.unref(m._sfc_main),{tag:"span",variant:"body-xs",color:"secondary"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(v)),1)]),_:1})])):e.createCommentVNode("",!0),e.unref(y)?(e.openBlock(),e.createBlock(e.unref(G._sfc_main),{key:1,variant:"condensed",class:"sv-subscription-cancellation-modal__payment-method","payment-method":e.unref(y)},null,8,["payment-method"])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)]),_:1})):e.createCommentVNode("",!0),w.value?(e.openBlock(),e.createBlock(e.unref(L._sfc_main),{key:1,class:"sv-subscription-cancellation-modal__error sv-error",title:e.unref(S)},null,8,["title"])):e.createCommentVNode("",!0)])]),_:1},8,["show-modal","title","confirm-button-text","cancel-button-text","is-loading","no-click-away","no-backdrop-close"]))}}),Ne={class:"sv-subscription-details__header flex flex-col gap-2 md:flex-row md:items-center"},Pe=e.defineComponent({__name:"SubscriptionDetails",props:{subscription:{type:Object},schedulesData:{type:Array},customer:{type:Object},paymentMethods:{type:Array},walletBalances:{default:()=>[],type:Array},onDemandItems:{default:()=>[],type:Array},onDemandScheduleId:{type:String},hasWalletBalancesError:{type:Boolean},avatar:{type:String},canViewCreatedInvoice:{type:Boolean},isLoading:{type:Boolean},error:{type:null}},emits:["top-up-charged","auto-top-up-saved","auto-top-up-cancelled","payment-method-stored","subscription-changed","invoice-created"],setup(t,{emit:a}){const n=e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./SubscriptionSchedules-Cm5Dt-1H.js"))),i=e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./ChargeOnDemandModal-DIQaGnRs.js"))),o=t,s=a,{dispatchAction:c}=O.useActionDispatchProvider(),{$t:r}=m.useIntl(),{isCancellable:f,isRenewable:l,pendingVariant:g,cancel:v,renew:k,dismiss:C,manage:B}=ue({subscription:e.toRef(o,"subscription")}),_=e.ref();e.watch(g,u=>{u&&(_.value=void 0)});const x=()=>{_.value=g.value,s("subscription-changed")},S=e.computed(()=>{if(_.value)return _.value==="RENEW"?r({defaultMessage:"Your subscription has been renewed.",id:"subscription_details.renew_success",description:"Confirmation shown after a cancellation has been undone"}):r({defaultMessage:"Your subscription has been cancelled. You keep access until the end of the billing period.",id:"subscription_details.cancel_success",description:"Confirmation shown after a subscription has been cancelled"})}),y=e.computed(()=>E.getMostRecentScheduleInfo(o.subscription)),I=e.computed(()=>(o.paymentMethods??[]).find(({id:u})=>{var d;return u===((d=o.subscription)==null?void 0:d.payment_method_id)})),b=e.computed(()=>o.subscription?[o.subscription]:[]),w=e.ref(!1),N=e.ref(!1),V=()=>{N.value=!0,w.value=!0},p=e.computed(()=>E.getSubscriptionName({subscription:o.subscription,fallback:r({defaultMessage:"Subscription details",id:"subscription_details.title",description:"Title for the subscription details page"})}));return(u,d)=>(e.openBlock(),e.createBlock(e.unref(j.ContentWithAsideLayout),{class:"sv-subscription-details sv-root sv-screen"},{header:e.withCtx(()=>[e.createElementVNode("div",Ne,[e.createVNode(e.unref(m._sfc_main),{variant:"heading-2",tag:"h1",class:"sv-subscription-details__title grow"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(p.value),1)]),_:1}),e.unref(l)?(e.openBlock(),e.createBlock(e.unref(D._sfc_main),{key:0,intent:"secondary",class:"sv-action sv-action--secondary sv-subscription-details__renew w-full md:w-auto",type:"button",onClick:e.unref(k)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(r)({defaultMessage:"Renew subscription",id:"subscription_details.renew_button.label",description:"Label for the renew subscription button on the subscription details page"})),1)]),_:1},8,["onClick"])):e.createCommentVNode("",!0),e.unref(f)?(e.openBlock(),e.createBlock(e.unref(D._sfc_main),{key:1,intent:"secondary",class:"sv-action sv-action--secondary sv-subscription-details__cancel w-full md:w-auto",type:"button",onClick:e.unref(v)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(r)({defaultMessage:"Cancel subscription",id:"subscription_details.cancel_button.label",description:"Label for the cancel subscription button on the subscription details page"})),1)]),_:1},8,["onClick"])):e.createCommentVNode("",!0)])]),content:e.withCtx(()=>[S.value?(e.openBlock(),e.createBlock(e.unref(F._sfc_main),{key:0,class:"sv-subscription-details__cancellation-success",type:"success",title:S.value},null,8,["title"])):e.createCommentVNode("",!0),t.error?(e.openBlock(),e.createBlock(e.unref(L._sfc_main),{key:1,class:"sv-subscription-details__error sv-error",title:e.unref(r)({defaultMessage:"Unable to load this subscription. Please try again later.",id:"subscription_details.load_error",description:"Error message shown when the subscription cannot be loaded on the subscription details page"})},null,8,["title"])):t.isLoading?(e.openBlock(),e.createBlock(z._sfc_main,{key:2,variant:"section",class:"min-h-[220px]"})):t.subscription?(e.openBlock(),e.createBlock(e.unref(n),{key:3,class:"sv-subscription-details__schedules","schedules-data":t.schedulesData??[],configuration:{subscriptionId:t.subscription.id},"is-loading":t.isLoading},null,8,["schedules-data","configuration","is-loading"])):(e.openBlock(),e.createBlock(Y._sfc_main,{key:4,class:"sv-subscription-details__empty-state",icon:"receipt_long"},{title:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(r)({defaultMessage:"Subscription not found",id:"subscription_details.empty_state.title",description:"Title shown when the requested subscription does not exist"})),1)]),message:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(r)({defaultMessage:"This subscription is no longer available.",id:"subscription_details.empty_state.message",description:"Message shown when the requested subscription does not exist"})),1)]),_:1}))]),aside:e.withCtx(()=>[e.createVNode($._sfc_main,{class:"sv-subscription-details__wallet-balances","has-error":!!t.hasWalletBalancesError,"is-loading":t.isLoading,"wallet-balances":t.walletBalances,"show-top-up-button":"",customer:t.customer,"payment-methods":t.paymentMethods,subscriptions:b.value,onTopUpCharged:d[0]||(d[0]=h=>u.$emit("top-up-charged")),onAutoTopUpSaved:d[1]||(d[1]=h=>u.$emit("auto-top-up-saved")),onAutoTopUpCancelled:d[2]||(d[2]=h=>u.$emit("auto-top-up-cancelled")),onPaymentMethodStored:d[3]||(d[3]=h=>u.$emit("payment-method-stored"))},null,8,["has-error","is-loading","wallet-balances","customer","payment-methods","subscriptions"]),!t.isLoading&&t.onDemandItems.length>0?(e.openBlock(),e.createBlock(we,{key:0,items:t.onDemandItems,class:"sv-subscription-details__on-demand-items",onOrder:V},null,8,["items"])):e.createCommentVNode("",!0),y.value?(e.openBlock(),e.createBlock(_e,{key:1,class:"sv-subscription-details__upgrades","pricing-plan-schedule":y.value,onUpgrade:e.unref(B)},null,8,["pricing-plan-schedule","onUpgrade"])):e.createCommentVNode("",!0),I.value?(e.openBlock(),e.createBlock(W._sfc_main,{key:2,class:"sv-subscription-details__payment-method","is-loading":t.isLoading,"payment-methods":[I.value],configuration:{showViewAllButton:!1,showAddButton:!1}},null,8,["is-loading","payment-methods"])):e.createCommentVNode("",!0),N.value&&t.subscription&&t.onDemandScheduleId?(e.openBlock(),e.createBlock(e.unref(i),{key:3,"show-modal":w.value,subscription:t.subscription,"schedule-id":t.onDemandScheduleId,items:t.onDemandItems,customer:t.customer,"payment-methods":t.paymentMethods,"can-view-created-invoice":t.canViewCreatedInvoice,onClose:d[4]||(d[4]=h=>w.value=!1),onPaymentMethodStored:d[5]||(d[5]=h=>u.$emit("payment-method-stored")),onInvoiceCreated:d[6]||(d[6]=h=>u.$emit("invoice-created",h)),onViewInvoice:d[7]||(d[7]=h=>e.unref(c)({action:"view-invoice",data:{invoiceId:h}}))},null,8,["show-modal","subscription","schedule-id","items","customer","payment-methods","can-view-created-invoice"])):e.createCommentVNode("",!0),e.createVNode(Me,{"show-modal":!!e.unref(g),variant:e.unref(g),subscription:t.subscription,avatar:t.avatar,onConfirmed:x,onClose:e.unref(C)},null,8,["show-modal","variant","subscription","avatar","onClose"])]),_:1}))}}),De=["FIXED","FLAT"],Ve=(t,a)=>{var i;const n=(i=t.details.bands)==null?void 0:i[0];return a==="FIXED"?n==null?void 0:n.fixed_amount:n==null?void 0:n.amount},U=t=>typeof t=="number"&&Number.isInteger(t)&&t>=1,Ee=t=>{var n;const a=Number((n=t.default_units)==null?void 0:n.number);return U(a)?a:1},Ae=t=>{const a=t.flatMap(q.getAllPricings);return{productItems:new Map(a.flatMap(n=>n.items??[]).flatMap(n=>n.product_items??[]).map(({id:n,name:i})=>[n,i])),products:new Map(a.flatMap(n=>n.products??[]).map(({id:n,name:i})=>[n,i]))}},Te=(t,a,n)=>A.getComposedString(a.product_item_ids.map(i=>n.productItems.get(i)))||t.name||A.getComposedString(t.product_ids.map(i=>n.products.get(i)))||"",Le=(t,a,n)=>{var s,c;const i=(s=a.configs)==null?void 0:s.find(r=>r.on_demand);if(!i||(c=i.wallet_grants)!=null&&c.length||!le.hasOneOfPricingTypes(i,De))return;const o=i.details.pricing_type==="FIXED"?"FIXED":"FLAT";return{pricingItemId:a.id,pricingItemConfigId:i.id,name:Te(t,a,n),priceType:o,price:Ve(i,o),defaultUnits:Ee(i)}},Oe=(t,{pricingPlanVersions:a=[]}={})=>{const n=Ae(a);return q.getAllPricings(t).flatMap(i=>(i.items??[]).flatMap(o=>Le(i,o,n)??[]))},$e=(t,a)=>{const n=new Set((a.payment_acceptors??[]).flatMap(i=>{var o;return((o=i.payment_gateway)==null?void 0:o.integration_id)??[]}));return t.filter(i=>i.status==="ACTIVE"&&!!i.integration_id&&n.has(i.integration_id)).sort((i,o)=>+(o.id===a.payment_method_id)-+(i.id===a.payment_method_id))},qe=(t,a)=>t.flatMap(({pricingItemId:n,units:i})=>{const o=a.find(s=>s.pricingItemId===n);return o?o.priceType==="FLAT"&&i!==void 0?[{pricing_item_id:n,units:{number:String(i)}}]:[{pricing_item_id:n}]:[]});function Re({subscription:t}){const{getOnDemandPricingItems:a}=se.createPricingPlanSchedulesService(),n=m.useLogger(),{data:i,execute:o,error:s}=re.useService({service:a}),c=e.computed(()=>{var l;return((l=t.value)==null?void 0:l.variant)==="DEFAULT"?ce.getActiveDefaultScheduleInfo(t.value.pricing_plan_schedule_infos):void 0}),r=e.computed(()=>{var l;return(l=c.value)==null?void 0:l.id});return e.watch(r,l=>{l&&o({scheduleId:l}).catch(()=>n.error("ON_DEMAND_ITEMS_LOAD_FAILED","Failed to load the on-demand items of the subscription",{scheduleId:l},s.value))},{immediate:!0}),{items:e.computed(()=>{var l,g;return r.value&&((l=i.value)==null?void 0:l.pricing_plan_schedule_id)===r.value?Oe(i.value,{pricingPlanVersions:(g=t.value)==null?void 0:g.pricing_plan_schedule_infos.map(v=>v.pricing_plan_version)}):[]}),scheduleId:r}}const Ue=e.defineComponent({__name:"SubscriptionDetails.entry.view",props:{configuration:{type:Object},environment:{type:String},locale:{type:String},dateLocale:{type:String},messages:{type:Object},primaryColor:{type:String},secondaryColor:{type:String},isShadowRoot:{type:Boolean},experimentalFeatures:{type:Array},logLevel:{type:String},onLog:{type:Function},allowedPortalTypes:{type:Array},portalObject:{type:Object},cssOverrides:{type:[String,Array]},branding:{type:Object}},setup(t){const a=t,n=a.portalObject.customer_id,{subscription:i,withPlanData:o,get:s,error:c}=ne.useSubscription({subscriptionId:a.configuration.subscriptionId}),{customer:r,get:f}=ie.useCustomer({customerId:n}),{items:l,fetchAll:g}=ae.usePaymentMethods({customerId:n}),{walletBalances:v,apiStatus:k,fetch:C}=$.useCustomerWalletBalances({customerId:n}),{isLoading:B}=oe.useLoadInitialData(s(),f.execute(),g(),C()),{items:_,scheduleId:x}=Re({subscription:i}),S=e.computed(()=>i.value?o(i.value):[]),y=e.computed(()=>{var b;return((b=v.value)==null?void 0:b.wallet_balances)??[]}),I=e.computed(()=>k.value===te.ApiStatus.Failed);return(b,w)=>e.renderSlot(b.$slots,"default",{subscription:e.unref(i),schedulesData:S.value,customer:e.unref(r),paymentMethods:e.unref(l),walletBalances:y.value,onDemandItems:e.unref(_),onDemandScheduleId:e.unref(x),hasWalletBalancesError:I.value,isLoading:e.unref(B),error:e.unref(c),refreshWalletBalances:e.unref(C),refreshPaymentMethods:e.unref(g),refreshSubscription:e.unref(s)})}});function Fe({invoice:t,configuration:a}){var n;(n=a.onInvoiceCreated)==null||n.call(a,{invoiceId:t.id,paymentStatus:t.payment_status})}const je=e.defineComponent({__name:"SubscriptionDetails.entry",props:{configuration:{type:Object},environment:{type:String},locale:{type:String},dateLocale:{type:String},messages:{type:Object},primaryColor:{type:String},secondaryColor:{type:String},isShadowRoot:{type:Boolean},experimentalFeatures:{type:Array},logLevel:{type:String},onLog:{type:Function},allowedPortalTypes:{type:Array},portalObject:{type:Object},cssOverrides:{type:[String,Array]},branding:{type:Object}},setup(t){const a=de.getComponentName("subscription-details"),n=t;return(i,o)=>(e.openBlock(),e.createBlock(e.unref(m._sfc_main$1),{entry:i.$props,"component-name":e.unref(a),"allowed-portal-types":["CUSTOMER"],onError:o[1]||(o[1]=s=>i.$emit("error",s))},{default:e.withCtx(()=>[e.createVNode(Ue,e.normalizeProps(e.guardReactiveProps(i.$props)),{default:e.withCtx(({subscription:s,schedulesData:c,customer:r,paymentMethods:f,walletBalances:l,onDemandItems:g,onDemandScheduleId:v,hasWalletBalancesError:k,isLoading:C,error:B,refreshWalletBalances:_,refreshPaymentMethods:x,refreshSubscription:S})=>[e.createVNode(Pe,{subscription:s,"schedules-data":c,customer:r,avatar:t.configuration.avatar,"can-view-created-invoice":t.configuration.canViewCreatedInvoice,"payment-methods":f,"wallet-balances":l,"on-demand-items":g,"on-demand-schedule-id":v,"has-wallet-balances-error":k,"is-loading":C,error:B,onTopUpCharged:_,onAutoTopUpSaved:_,onAutoTopUpCancelled:_,onPaymentMethodStored:x,onSubscriptionChanged:S,onInvoiceCreated:o[0]||(o[0]=y=>e.unref(Fe)({invoice:y,configuration:n.configuration}))},null,8,["subscription","schedules-data","customer","avatar","can-view-created-invoice","payment-methods","wallet-balances","on-demand-items","on-demand-schedule-id","has-wallet-balances-error","is-loading","error","onTopUpCharged","onAutoTopUpSaved","onAutoTopUpCancelled","onPaymentMethodStored","onSubscriptionChanged"])]),_:1},16)]),_:1},8,["entry","component-name"]))}}),{define:We}=m.createSolvimonElement(je,"subscription-details");exports.defineSolvimonSubscriptionDetails=We;exports.getPayablePaymentMethods=$e;exports.isOrderableUnits=U;exports.toChargePricingItems=qe;exports.useChargeOnDemandPriceLabel=R;
|