@newskit-render/my-account 7.150.2 → 7.151.1-0edc5ab39.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/Components/Elements/CancellationConfirm/CancellationConfirm.d.ts +16 -0
- package/dist/cjs/Components/Elements/CancellationConfirm/CancellationConfirm.js +64 -0
- package/dist/cjs/Components/Elements/CancellationConfirm/CancellationConfirm.js.map +1 -0
- package/dist/cjs/Components/Elements/CancellationConfirm/index.d.ts +2 -0
- package/dist/cjs/Components/Elements/CancellationConfirm/index.js +6 -0
- package/dist/cjs/Components/Elements/CancellationConfirm/index.js.map +1 -0
- package/dist/cjs/Components/Elements/ForwardButton/ForwardButton.d.ts +1 -1
- package/dist/cjs/Components/Elements/ForwardButton/ForwardButton.js +1 -1
- package/dist/cjs/Components/Elements/ForwardButton/ForwardButton.js.map +1 -1
- package/dist/cjs/Components/Elements/OfferGroup/OfferBody.js +4 -4
- package/dist/cjs/Components/Elements/OfferGroup/OfferBody.js.map +1 -1
- package/dist/cjs/Components/Elements/SunArticleCard/SunArticleCard.d.ts +12 -8
- package/dist/cjs/Components/Elements/SunArticleCard/SunArticleCard.js +48 -12
- package/dist/cjs/Components/Elements/SunArticleCard/SunArticleCard.js.map +1 -1
- package/dist/cjs/Components/Elements/SunArticleGrid/SunArticleGrid.d.ts +2 -2
- package/dist/cjs/Components/Elements/SunArticleGrid/SunArticleGrid.js +2 -3
- package/dist/cjs/Components/Elements/SunArticleGrid/SunArticleGrid.js.map +1 -1
- package/dist/cjs/Components/Elements/SunOfferCard/SunOfferCard.d.ts +12 -7
- package/dist/cjs/Components/Elements/SunOfferCard/SunOfferCard.js +48 -11
- package/dist/cjs/Components/Elements/SunOfferCard/SunOfferCard.js.map +1 -1
- package/dist/cjs/Components/Elements/SunOfferGrid/SunOfferGrid.d.ts +2 -2
- package/dist/cjs/Components/Elements/SunOfferGrid/SunOfferGrid.js +2 -3
- package/dist/cjs/Components/Elements/SunOfferGrid/SunOfferGrid.js.map +1 -1
- package/dist/cjs/Components/Elements/TimesLoading/TimesLoading.d.ts +4 -1
- package/dist/cjs/Components/Elements/TimesLoading/TimesLoading.js +28 -3
- package/dist/cjs/Components/Elements/TimesLoading/TimesLoading.js.map +1 -1
- package/dist/cjs/Components/Sections/CancelSubscription/CancelSubscription.d.ts +1 -1
- package/dist/cjs/Components/Sections/CancelSubscription/CancelSubscription.js +11 -17
- package/dist/cjs/Components/Sections/CancelSubscription/CancelSubscription.js.map +1 -1
- package/dist/cjs/Components/Sections/CancelSubscription/types.d.ts +2 -0
- package/dist/cjs/Components/Sections/CancelSubscriptionDowngrade/CancelSubscriptionDowngrade.d.ts +2 -2
- package/dist/cjs/Components/Sections/CancellationDetails/types.d.ts +2 -2
- package/dist/cjs/Components/Sections/CancellationOffers/CancellationOffers.d.ts +1 -1
- package/dist/cjs/Components/Sections/CancellationOffers/CancellationOffers.js +54 -13
- package/dist/cjs/Components/Sections/CancellationOffers/CancellationOffers.js.map +1 -1
- package/dist/cjs/Components/Sections/CancellationOffers/types.d.ts +29 -4
- package/dist/cjs/Components/Sections/CancellationReasons/CancellationReasons.d.ts +2 -1
- package/dist/cjs/Components/Sections/CancellationReasons/CancellationReasons.js +15 -3
- package/dist/cjs/Components/Sections/CancellationReasons/CancellationReasons.js.map +1 -1
- package/dist/cjs/Components/Sections/CancellationReview/CancellationReview.d.ts +4 -0
- package/dist/cjs/Components/Sections/CancellationReview/CancellationReview.js +148 -0
- package/dist/cjs/Components/Sections/CancellationReview/CancellationReview.js.map +1 -0
- package/dist/cjs/Components/Sections/CancellationReview/index.d.ts +2 -0
- package/dist/cjs/Components/Sections/CancellationReview/index.js +19 -0
- package/dist/cjs/Components/Sections/CancellationReview/index.js.map +1 -0
- package/dist/cjs/Components/Sections/CancellationReview/types.d.ts +23 -0
- package/dist/cjs/Components/Sections/CancellationReview/types.js +3 -0
- package/dist/cjs/Components/Sections/CancellationReview/types.js.map +1 -0
- package/dist/cjs/Components/Sections/ConfirmSubscriptionOffer/ConfirmSubscriptionOffer.d.ts +1 -1
- package/dist/cjs/Components/Sections/ConfirmSubscriptionOffer/ConfirmSubscriptionOffer.js +6 -7
- package/dist/cjs/Components/Sections/ConfirmSubscriptionOffer/ConfirmSubscriptionOffer.js.map +1 -1
- package/dist/cjs/Components/Sections/ConfirmSubscriptionOffer/index.d.ts +2 -0
- package/dist/cjs/Components/Sections/ConfirmSubscriptionOffer/index.js.map +1 -1
- package/dist/cjs/Components/Sections/ContactSupport/ContactSupport.d.ts +2 -0
- package/dist/cjs/Components/Sections/ContactSupport/ContactSupport.js +43 -0
- package/dist/cjs/Components/Sections/ContactSupport/ContactSupport.js.map +1 -0
- package/dist/cjs/Components/Sections/ContactSupport/index.d.ts +2 -0
- package/dist/cjs/Components/Sections/ContactSupport/index.js +19 -0
- package/dist/cjs/Components/Sections/ContactSupport/index.js.map +1 -0
- package/dist/cjs/Components/Sections/ContactSupport/types.d.ts +21 -0
- package/dist/cjs/Components/Sections/ContactSupport/types.js +3 -0
- package/dist/cjs/Components/Sections/ContactSupport/types.js.map +1 -0
- package/dist/cjs/Components/Sections/ContentContainer/ContentContainer.js +4 -7
- package/dist/cjs/Components/Sections/ContentContainer/ContentContainer.js.map +1 -1
- package/dist/cjs/Components/Sections/OfferPreview/OfferPreview.d.ts +30 -0
- package/dist/cjs/Components/Sections/OfferPreview/OfferPreview.js +189 -0
- package/dist/cjs/Components/Sections/OfferPreview/OfferPreview.js.map +1 -0
- package/dist/cjs/Components/Sections/OfferPreview/OfferSummary.d.ts +21 -0
- package/dist/cjs/Components/Sections/OfferPreview/OfferSummary.js +95 -0
- package/dist/cjs/Components/Sections/OfferPreview/OfferSummary.js.map +1 -0
- package/dist/cjs/Components/Sections/OfferPreview/SummaryRow.d.ts +9 -0
- package/dist/cjs/Components/Sections/OfferPreview/SummaryRow.js +38 -0
- package/dist/cjs/Components/Sections/OfferPreview/SummaryRow.js.map +1 -0
- package/dist/cjs/Components/Sections/OfferPreview/index.d.ts +0 -0
- package/dist/cjs/Components/Sections/OfferPreview/index.js +2 -0
- package/dist/cjs/Components/Sections/OfferPreview/index.js.map +1 -0
- package/dist/cjs/Components/Sections/OfferPreview/types.d.ts +0 -0
- package/dist/cjs/Components/Sections/OfferPreview/types.js +2 -0
- package/dist/cjs/Components/Sections/OfferPreview/types.js.map +1 -0
- package/dist/cjs/Components/Sections/SectionContainer/types.d.ts +2 -2
- package/dist/cjs/Components/Sections/UserHub/SubscriptionDetailsSection.d.ts +1 -1
- package/dist/cjs/Components/Sections/UserHub/SubscriptionDetailsSection.js +7 -24
- package/dist/cjs/Components/Sections/UserHub/SubscriptionDetailsSection.js.map +1 -1
- package/dist/cjs/Components/Templates/CancellationStepperRender.d.ts +8 -6
- package/dist/cjs/Components/Templates/CancellationStepperRender.js +59 -21
- package/dist/cjs/Components/Templates/CancellationStepperRender.js.map +1 -1
- package/dist/cjs/Components/Templates/LayoutTemplate.js +29 -1
- package/dist/cjs/Components/Templates/LayoutTemplate.js.map +1 -1
- package/dist/cjs/Components/Templates/NewslettersRender.js +1 -0
- package/dist/cjs/Components/Templates/NewslettersRender.js.map +1 -1
- package/dist/cjs/Components/Templates/SubscriptionAndBillingRender.js +16 -2
- package/dist/cjs/Components/Templates/SubscriptionAndBillingRender.js.map +1 -1
- package/dist/cjs/Components/Templates/SunCancellationFlowRender.js +198 -22
- package/dist/cjs/Components/Templates/SunCancellationFlowRender.js.map +1 -1
- package/dist/cjs/Components/index.d.ts +1 -0
- package/dist/cjs/api/queryHandler.js +29 -14
- package/dist/cjs/api/queryHandler.js.map +1 -1
- package/dist/cjs/context/types.d.ts +11 -3
- package/dist/cjs/context/types.js.map +1 -1
- package/dist/cjs/getProviderProps.js +4 -0
- package/dist/cjs/getProviderProps.js.map +1 -1
- package/dist/cjs/getProviderPropsTimes.js +13 -13
- package/dist/cjs/getProviderPropsTimes.js.map +1 -1
- package/dist/cjs/helpers/apiHandlerUtils.js +1 -0
- package/dist/cjs/helpers/apiHandlerUtils.js.map +1 -1
- package/dist/cjs/helpers/cancellationOffersUtils.d.ts +55 -0
- package/dist/cjs/helpers/cancellationOffersUtils.js +149 -0
- package/dist/cjs/helpers/cancellationOffersUtils.js.map +1 -0
- package/dist/cjs/helpers/cancellationUtils.d.ts +20 -0
- package/dist/cjs/helpers/cancellationUtils.js +110 -1
- package/dist/cjs/helpers/cancellationUtils.js.map +1 -1
- package/dist/cjs/helpers/dataUtils.d.ts +1 -0
- package/dist/cjs/helpers/dataUtils.js +42 -5
- package/dist/cjs/helpers/dataUtils.js.map +1 -1
- package/dist/cjs/helpers/dmccVariant.d.ts +2 -0
- package/dist/cjs/helpers/dmccVariant.js +81 -0
- package/dist/cjs/helpers/dmccVariant.js.map +1 -0
- package/dist/cjs/helpers/featureFlagUtils.js +2 -2
- package/dist/cjs/helpers/featureFlagUtils.js.map +1 -1
- package/dist/cjs/helpers/index.d.ts +4 -0
- package/dist/cjs/helpers/index.js +4 -2
- package/dist/cjs/helpers/index.js.map +1 -1
- package/dist/cjs/helpers/randomizeReasons.d.ts +2 -0
- package/dist/cjs/helpers/randomizeReasons.js +37 -0
- package/dist/cjs/helpers/randomizeReasons.js.map +1 -0
- package/dist/cjs/helpers/stringUtils.d.ts +1 -0
- package/dist/cjs/helpers/stringUtils.js +9 -0
- package/dist/cjs/helpers/stringUtils.js.map +1 -0
- package/dist/cjs/helpers/subscriptionsUtils.d.ts +8 -4
- package/dist/cjs/helpers/subscriptionsUtils.js +15 -8
- package/dist/cjs/helpers/subscriptionsUtils.js.map +1 -1
- package/dist/cjs/index.d.ts +1 -0
- package/dist/cjs/pages/CancellationStepper/CancellationStepper.js +5 -5
- package/dist/cjs/pages/CancellationStepper/CancellationStepper.js.map +1 -1
- package/dist/cjs/pages/CancellationStepper/CancellationStepperContext.js +210 -12
- package/dist/cjs/pages/CancellationStepper/CancellationStepperContext.js.map +1 -1
- package/dist/cjs/pages/SubscriptionAndBilling/Sections/CancelSubscriptionSectionContext.js +3 -0
- package/dist/cjs/pages/SubscriptionAndBilling/Sections/CancelSubscriptionSectionContext.js.map +1 -1
- package/dist/cjs/pages/SubscriptionAndBilling/SubscriptionAndBillingContext.js +1 -0
- package/dist/cjs/pages/SubscriptionAndBilling/SubscriptionAndBillingContext.js.map +1 -1
- package/dist/cjs/pages/SunCancellationFlow/SunCancellationFlowContext.d.ts +36 -0
- package/dist/cjs/pages/SunCancellationFlow/SunCancellationFlowContext.js +55 -12
- package/dist/cjs/pages/SunCancellationFlow/SunCancellationFlowContext.js.map +1 -1
- package/dist/cjs/pages/UserHub/UserHubContext.js +1 -0
- package/dist/cjs/pages/UserHub/UserHubContext.js.map +1 -1
- package/dist/cjs/pages/types.d.ts +4 -0
- package/dist/cjs/queries/getContractPhases.js +1 -1
- package/dist/cjs/queries/getContractPhases.js.map +1 -1
- package/dist/cjs/queries/getIncentivePreview.d.ts +2 -0
- package/dist/cjs/queries/getIncentivePreview.js +11 -0
- package/dist/cjs/queries/getIncentivePreview.js.map +1 -0
- package/dist/cjs/queries/getUserSubscription.js +1 -1
- package/dist/cjs/queries/getUserSubscription.js.map +1 -1
- package/dist/cjs/queries/index.d.ts +2 -0
- package/dist/cjs/queries/index.js +2 -0
- package/dist/cjs/queries/index.js.map +1 -1
- package/dist/cjs/queries/mutateApplyIncentive.d.ts +2 -0
- package/dist/cjs/queries/mutateApplyIncentive.js +11 -0
- package/dist/cjs/queries/mutateApplyIncentive.js.map +1 -0
- package/dist/esm/Components/Elements/CancellationConfirm/CancellationConfirm.d.ts +16 -0
- package/dist/esm/Components/Elements/CancellationConfirm/CancellationConfirm.js +57 -0
- package/dist/esm/Components/Elements/CancellationConfirm/CancellationConfirm.js.map +1 -0
- package/dist/esm/Components/Elements/CancellationConfirm/index.d.ts +2 -0
- package/dist/esm/Components/Elements/CancellationConfirm/index.js +2 -0
- package/dist/esm/Components/Elements/CancellationConfirm/index.js.map +1 -0
- package/dist/esm/Components/Elements/ForwardButton/ForwardButton.d.ts +1 -1
- package/dist/esm/Components/Elements/ForwardButton/ForwardButton.js +1 -1
- package/dist/esm/Components/Elements/ForwardButton/ForwardButton.js.map +1 -1
- package/dist/esm/Components/Elements/OfferGroup/OfferBody.js +4 -4
- package/dist/esm/Components/Elements/OfferGroup/OfferBody.js.map +1 -1
- package/dist/esm/Components/Elements/SunArticleCard/SunArticleCard.d.ts +12 -8
- package/dist/esm/Components/Elements/SunArticleCard/SunArticleCard.js +49 -13
- package/dist/esm/Components/Elements/SunArticleCard/SunArticleCard.js.map +1 -1
- package/dist/esm/Components/Elements/SunArticleGrid/SunArticleGrid.d.ts +2 -2
- package/dist/esm/Components/Elements/SunArticleGrid/SunArticleGrid.js +2 -3
- package/dist/esm/Components/Elements/SunArticleGrid/SunArticleGrid.js.map +1 -1
- package/dist/esm/Components/Elements/SunOfferCard/SunOfferCard.d.ts +12 -7
- package/dist/esm/Components/Elements/SunOfferCard/SunOfferCard.js +49 -12
- package/dist/esm/Components/Elements/SunOfferCard/SunOfferCard.js.map +1 -1
- package/dist/esm/Components/Elements/SunOfferGrid/SunOfferGrid.d.ts +2 -2
- package/dist/esm/Components/Elements/SunOfferGrid/SunOfferGrid.js +2 -3
- package/dist/esm/Components/Elements/SunOfferGrid/SunOfferGrid.js.map +1 -1
- package/dist/esm/Components/Elements/TimesLoading/TimesLoading.d.ts +4 -1
- package/dist/esm/Components/Elements/TimesLoading/TimesLoading.js +28 -3
- package/dist/esm/Components/Elements/TimesLoading/TimesLoading.js.map +1 -1
- package/dist/esm/Components/Sections/CancelSubscription/CancelSubscription.d.ts +1 -1
- package/dist/esm/Components/Sections/CancelSubscription/CancelSubscription.js +11 -17
- package/dist/esm/Components/Sections/CancelSubscription/CancelSubscription.js.map +1 -1
- package/dist/esm/Components/Sections/CancelSubscription/types.d.ts +2 -0
- package/dist/esm/Components/Sections/CancelSubscriptionDowngrade/CancelSubscriptionDowngrade.d.ts +2 -2
- package/dist/esm/Components/Sections/CancellationDetails/types.d.ts +2 -2
- package/dist/esm/Components/Sections/CancellationOffers/CancellationOffers.d.ts +1 -1
- package/dist/esm/Components/Sections/CancellationOffers/CancellationOffers.js +54 -13
- package/dist/esm/Components/Sections/CancellationOffers/CancellationOffers.js.map +1 -1
- package/dist/esm/Components/Sections/CancellationOffers/types.d.ts +29 -4
- package/dist/esm/Components/Sections/CancellationReasons/CancellationReasons.d.ts +2 -1
- package/dist/esm/Components/Sections/CancellationReasons/CancellationReasons.js +13 -2
- package/dist/esm/Components/Sections/CancellationReasons/CancellationReasons.js.map +1 -1
- package/dist/esm/Components/Sections/CancellationReview/CancellationReview.d.ts +4 -0
- package/dist/esm/Components/Sections/CancellationReview/CancellationReview.js +120 -0
- package/dist/esm/Components/Sections/CancellationReview/CancellationReview.js.map +1 -0
- package/dist/esm/Components/Sections/CancellationReview/index.d.ts +2 -0
- package/dist/esm/Components/Sections/CancellationReview/index.js +3 -0
- package/dist/esm/Components/Sections/CancellationReview/index.js.map +1 -0
- package/dist/esm/Components/Sections/CancellationReview/types.d.ts +23 -0
- package/dist/esm/Components/Sections/CancellationReview/types.js +2 -0
- package/dist/esm/Components/Sections/CancellationReview/types.js.map +1 -0
- package/dist/esm/Components/Sections/ConfirmSubscriptionOffer/ConfirmSubscriptionOffer.d.ts +1 -1
- package/dist/esm/Components/Sections/ConfirmSubscriptionOffer/ConfirmSubscriptionOffer.js +6 -7
- package/dist/esm/Components/Sections/ConfirmSubscriptionOffer/ConfirmSubscriptionOffer.js.map +1 -1
- package/dist/esm/Components/Sections/ConfirmSubscriptionOffer/index.d.ts +2 -0
- package/dist/esm/Components/Sections/ConfirmSubscriptionOffer/index.js.map +1 -1
- package/dist/esm/Components/Sections/ContactSupport/ContactSupport.d.ts +2 -0
- package/dist/esm/Components/Sections/ContactSupport/ContactSupport.js +36 -0
- package/dist/esm/Components/Sections/ContactSupport/ContactSupport.js.map +1 -0
- package/dist/esm/Components/Sections/ContactSupport/index.d.ts +2 -0
- package/dist/esm/Components/Sections/ContactSupport/index.js +3 -0
- package/dist/esm/Components/Sections/ContactSupport/index.js.map +1 -0
- package/dist/esm/Components/Sections/ContactSupport/types.d.ts +21 -0
- package/dist/esm/Components/Sections/ContactSupport/types.js +2 -0
- package/dist/esm/Components/Sections/ContactSupport/types.js.map +1 -0
- package/dist/esm/Components/Sections/ContentContainer/ContentContainer.js +5 -8
- package/dist/esm/Components/Sections/ContentContainer/ContentContainer.js.map +1 -1
- package/dist/esm/Components/Sections/OfferPreview/OfferPreview.d.ts +30 -0
- package/dist/esm/Components/Sections/OfferPreview/OfferPreview.js +159 -0
- package/dist/esm/Components/Sections/OfferPreview/OfferPreview.js.map +1 -0
- package/dist/esm/Components/Sections/OfferPreview/OfferSummary.d.ts +21 -0
- package/dist/esm/Components/Sections/OfferPreview/OfferSummary.js +88 -0
- package/dist/esm/Components/Sections/OfferPreview/OfferSummary.js.map +1 -0
- package/dist/esm/Components/Sections/OfferPreview/SummaryRow.d.ts +9 -0
- package/dist/esm/Components/Sections/OfferPreview/SummaryRow.js +31 -0
- package/dist/esm/Components/Sections/OfferPreview/SummaryRow.js.map +1 -0
- package/dist/esm/Components/Sections/OfferPreview/index.d.ts +0 -0
- package/dist/esm/Components/Sections/OfferPreview/index.js +2 -0
- package/dist/esm/Components/Sections/OfferPreview/index.js.map +1 -0
- package/dist/esm/Components/Sections/OfferPreview/types.d.ts +0 -0
- package/dist/esm/Components/Sections/OfferPreview/types.js +2 -0
- package/dist/esm/Components/Sections/OfferPreview/types.js.map +1 -0
- package/dist/esm/Components/Sections/SectionContainer/types.d.ts +2 -2
- package/dist/esm/Components/Sections/UserHub/SubscriptionDetailsSection.d.ts +1 -1
- package/dist/esm/Components/Sections/UserHub/SubscriptionDetailsSection.js +9 -26
- package/dist/esm/Components/Sections/UserHub/SubscriptionDetailsSection.js.map +1 -1
- package/dist/esm/Components/Templates/CancellationStepperRender.d.ts +8 -6
- package/dist/esm/Components/Templates/CancellationStepperRender.js +60 -22
- package/dist/esm/Components/Templates/CancellationStepperRender.js.map +1 -1
- package/dist/esm/Components/Templates/LayoutTemplate.js +6 -1
- package/dist/esm/Components/Templates/LayoutTemplate.js.map +1 -1
- package/dist/esm/Components/Templates/NewslettersRender.js +1 -0
- package/dist/esm/Components/Templates/NewslettersRender.js.map +1 -1
- package/dist/esm/Components/Templates/SubscriptionAndBillingRender.js +16 -2
- package/dist/esm/Components/Templates/SubscriptionAndBillingRender.js.map +1 -1
- package/dist/esm/Components/Templates/SunCancellationFlowRender.js +200 -24
- package/dist/esm/Components/Templates/SunCancellationFlowRender.js.map +1 -1
- package/dist/esm/Components/index.d.ts +1 -0
- package/dist/esm/api/queryHandler.js +29 -14
- package/dist/esm/api/queryHandler.js.map +1 -1
- package/dist/esm/context/types.d.ts +11 -3
- package/dist/esm/context/types.js.map +1 -1
- package/dist/esm/getProviderProps.js +4 -0
- package/dist/esm/getProviderProps.js.map +1 -1
- package/dist/esm/getProviderPropsTimes.js +13 -13
- package/dist/esm/getProviderPropsTimes.js.map +1 -1
- package/dist/esm/helpers/apiHandlerUtils.js +2 -1
- package/dist/esm/helpers/apiHandlerUtils.js.map +1 -1
- package/dist/esm/helpers/cancellationOffersUtils.d.ts +55 -0
- package/dist/esm/helpers/cancellationOffersUtils.js +144 -0
- package/dist/esm/helpers/cancellationOffersUtils.js.map +1 -0
- package/dist/esm/helpers/cancellationUtils.d.ts +20 -0
- package/dist/esm/helpers/cancellationUtils.js +106 -0
- package/dist/esm/helpers/cancellationUtils.js.map +1 -1
- package/dist/esm/helpers/dataUtils.d.ts +1 -0
- package/dist/esm/helpers/dataUtils.js +17 -4
- package/dist/esm/helpers/dataUtils.js.map +1 -1
- package/dist/esm/helpers/dmccVariant.d.ts +2 -0
- package/dist/esm/helpers/dmccVariant.js +76 -0
- package/dist/esm/helpers/dmccVariant.js.map +1 -0
- package/dist/esm/helpers/featureFlagUtils.js +2 -2
- package/dist/esm/helpers/featureFlagUtils.js.map +1 -1
- package/dist/esm/helpers/index.d.ts +4 -0
- package/dist/esm/helpers/index.js +4 -2
- package/dist/esm/helpers/index.js.map +1 -1
- package/dist/esm/helpers/randomizeReasons.d.ts +2 -0
- package/dist/esm/helpers/randomizeReasons.js +33 -0
- package/dist/esm/helpers/randomizeReasons.js.map +1 -0
- package/dist/esm/helpers/stringUtils.d.ts +1 -0
- package/dist/esm/helpers/stringUtils.js +5 -0
- package/dist/esm/helpers/stringUtils.js.map +1 -0
- package/dist/esm/helpers/subscriptionsUtils.d.ts +8 -4
- package/dist/esm/helpers/subscriptionsUtils.js +15 -8
- package/dist/esm/helpers/subscriptionsUtils.js.map +1 -1
- package/dist/esm/index.d.ts +1 -0
- package/dist/esm/pages/CancellationStepper/CancellationStepper.js +5 -5
- package/dist/esm/pages/CancellationStepper/CancellationStepper.js.map +1 -1
- package/dist/esm/pages/CancellationStepper/CancellationStepperContext.js +211 -13
- package/dist/esm/pages/CancellationStepper/CancellationStepperContext.js.map +1 -1
- package/dist/esm/pages/SubscriptionAndBilling/Sections/CancelSubscriptionSectionContext.js +3 -0
- package/dist/esm/pages/SubscriptionAndBilling/Sections/CancelSubscriptionSectionContext.js.map +1 -1
- package/dist/esm/pages/SubscriptionAndBilling/SubscriptionAndBillingContext.js +1 -0
- package/dist/esm/pages/SubscriptionAndBilling/SubscriptionAndBillingContext.js.map +1 -1
- package/dist/esm/pages/SunCancellationFlow/SunCancellationFlowContext.d.ts +36 -0
- package/dist/esm/pages/SunCancellationFlow/SunCancellationFlowContext.js +55 -12
- package/dist/esm/pages/SunCancellationFlow/SunCancellationFlowContext.js.map +1 -1
- package/dist/esm/pages/UserHub/UserHubContext.js +1 -0
- package/dist/esm/pages/UserHub/UserHubContext.js.map +1 -1
- package/dist/esm/pages/types.d.ts +4 -0
- package/dist/esm/queries/getContractPhases.js +1 -1
- package/dist/esm/queries/getContractPhases.js.map +1 -1
- package/dist/esm/queries/getIncentivePreview.d.ts +2 -0
- package/dist/esm/queries/getIncentivePreview.js +8 -0
- package/dist/esm/queries/getIncentivePreview.js.map +1 -0
- package/dist/esm/queries/getUserSubscription.js +1 -1
- package/dist/esm/queries/getUserSubscription.js.map +1 -1
- package/dist/esm/queries/index.d.ts +2 -0
- package/dist/esm/queries/index.js +2 -0
- package/dist/esm/queries/index.js.map +1 -1
- package/dist/esm/queries/mutateApplyIncentive.d.ts +2 -0
- package/dist/esm/queries/mutateApplyIncentive.js +8 -0
- package/dist/esm/queries/mutateApplyIncentive.js.map +1 -0
- package/package.json +4 -4
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.enableDmccVariantOnSpaNavigation = exports.appendDmccVariantParamFromCookie = void 0;
|
|
4
|
+
var getCookie = function (name) {
|
|
5
|
+
var decoded = decodeURIComponent(document.cookie || '');
|
|
6
|
+
var parts = decoded.split(';');
|
|
7
|
+
for (var _i = 0, parts_1 = parts; _i < parts_1.length; _i++) {
|
|
8
|
+
var part = parts_1[_i];
|
|
9
|
+
var _a = part.trim().split('='), key = _a[0], rest = _a.slice(1);
|
|
10
|
+
if (key === name) {
|
|
11
|
+
return rest.join('=');
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
return null;
|
|
15
|
+
};
|
|
16
|
+
var appendDmccVariantParamFromCookie = function () {
|
|
17
|
+
try {
|
|
18
|
+
if (typeof window === 'undefined') {
|
|
19
|
+
return;
|
|
20
|
+
}
|
|
21
|
+
var cookieName = 'dmcc_email_variant';
|
|
22
|
+
var cookieValue = getCookie(cookieName);
|
|
23
|
+
if (!cookieValue) {
|
|
24
|
+
return;
|
|
25
|
+
}
|
|
26
|
+
var url = new URL(window.location.href);
|
|
27
|
+
if (url.searchParams.get(cookieName) === cookieValue) {
|
|
28
|
+
return;
|
|
29
|
+
}
|
|
30
|
+
url.searchParams.set(cookieName, cookieValue);
|
|
31
|
+
window.history.replaceState(window.history.state, '', url.toString());
|
|
32
|
+
}
|
|
33
|
+
catch (_a) {
|
|
34
|
+
// no-op
|
|
35
|
+
}
|
|
36
|
+
};
|
|
37
|
+
exports.appendDmccVariantParamFromCookie = appendDmccVariantParamFromCookie;
|
|
38
|
+
var enableDmccVariantOnSpaNavigation = function () {
|
|
39
|
+
if (typeof window === 'undefined') {
|
|
40
|
+
return;
|
|
41
|
+
}
|
|
42
|
+
var ensure = function () { return (0, exports.appendDmccVariantParamFromCookie)(); };
|
|
43
|
+
// Run once
|
|
44
|
+
ensure();
|
|
45
|
+
// Keep param on browser navigation/hash changes
|
|
46
|
+
var onPopOrHash = function () { return ensure(); };
|
|
47
|
+
window.addEventListener('popstate', onPopOrHash);
|
|
48
|
+
window.addEventListener('hashchange', onPopOrHash);
|
|
49
|
+
// Patch history methods to catch SPA navigations
|
|
50
|
+
var origPush = history.pushState;
|
|
51
|
+
var origReplace = history.replaceState;
|
|
52
|
+
// @ts-ignore
|
|
53
|
+
history.pushState = function () {
|
|
54
|
+
var args = [];
|
|
55
|
+
for (var _i = 0; _i < arguments.length; _i++) {
|
|
56
|
+
args[_i] = arguments[_i];
|
|
57
|
+
}
|
|
58
|
+
var ret = origPush.apply(this, args);
|
|
59
|
+
ensure();
|
|
60
|
+
return ret;
|
|
61
|
+
};
|
|
62
|
+
// @ts-ignore
|
|
63
|
+
history.replaceState = function () {
|
|
64
|
+
var args = [];
|
|
65
|
+
for (var _i = 0; _i < arguments.length; _i++) {
|
|
66
|
+
args[_i] = arguments[_i];
|
|
67
|
+
}
|
|
68
|
+
var ret = origReplace.apply(this, args);
|
|
69
|
+
ensure();
|
|
70
|
+
return ret;
|
|
71
|
+
};
|
|
72
|
+
// Return cleanup
|
|
73
|
+
return function () {
|
|
74
|
+
window.removeEventListener('popstate', onPopOrHash);
|
|
75
|
+
window.removeEventListener('hashchange', onPopOrHash);
|
|
76
|
+
history.pushState = origPush;
|
|
77
|
+
history.replaceState = origReplace;
|
|
78
|
+
};
|
|
79
|
+
};
|
|
80
|
+
exports.enableDmccVariantOnSpaNavigation = enableDmccVariantOnSpaNavigation;
|
|
81
|
+
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IACZ,CAAC,CAAA;IAED,iBAAiB;IACjB,OAAO;QACL,MAAM,CAAC,mBAAmB,CAAC,UAAU,EAAE,WAAW,CAAC,CAAA;QACnD,MAAM,CAAC,mBAAmB,CAAC,YAAY,EAAE,WAAW,CAAC,CAAA;QACrD,OAAO,CAAC,SAAS,GAAG,QAAQ,CAAA;QAC5B,OAAO,CAAC,YAAY,GAAG,WAAW,CAAA;IACpC,CAAC,CAAA;AACH,CAAC,CAAA;AAzCY,QAAA,gCAAgC,oCAyC5C"}
|
|
@@ -76,8 +76,8 @@ var prepareOptimizelyData = function (userData, context) {
|
|
|
76
76
|
}
|
|
77
77
|
var hasConsent = (0, cookiesUtils_1.hasTrackingConsent)(context === null || context === void 0 ? void 0 : context.cookies);
|
|
78
78
|
var subscription = (_b = (_a = userData.user) === null || _a === void 0 ? void 0 : _a.subscriptions) === null || _b === void 0 ? void 0 : _b[0];
|
|
79
|
-
var contractPhase =
|
|
80
|
-
? (0, subscriptionsUtils_1.findActiveContractPhase)(subscription
|
|
79
|
+
var contractPhase = subscription
|
|
80
|
+
? (0, subscriptionsUtils_1.findActiveContractPhase)(subscription)
|
|
81
81
|
: null;
|
|
82
82
|
var hasDiscount = ((_c = subscription === null || subscription === void 0 ? void 0 : subscription.grantedIncentives) === null || _c === void 0 ? void 0 : _c.length)
|
|
83
83
|
? (0, subscriptionsUtils_1.hasActiveOrUpcomingDiscount)(subscription.grantedIncentives)
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"featureFlagUtils.js","sourceRoot":"","sources":["../../../src/helpers/featureFlagUtils.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,uEAAsE;AAEtE,+CAAmD;AACnD,2DAG6B;AAUtB,IAAM,iBAAiB,GAAG,UAC/B,OAA0B,EAC1B,UAA8C;;IAE9C,IAAM,OAAO,GAAG,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,OAAO,C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DAAgD;AAChD,uDAAuD;AACvD,uBAAuB;AAChB,IAAM,UAAU,GAAG,iEAAO,EAKb;;QAJlB,SAAS,eAAA,EACT,GAAG,SAAA,EACH,aAAa,mBAAA,EACb,IAAI,UAAA;;;;;gBAIF,qBAAM,KAAK,CAAC,0BAA0B,EAAE;wBACtC,MAAM,EAAE,MAAM;wBACd,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC;4BACnB,SAAS,WAAA;4BACT,IAAI,MAAA;4BACJ,GAAG,KAAA;4BACH,aAAa,eAAA;yBACd,CAAC;qBACH,CAAC,EAAA;;gBARF,SAQE,CAAA;;;;gBAEF,OAAO,CAAC,KAAK,CAAC,kCAAkC,EAAE,OAAK,CAAC,CAAA;;;;;KAE3D,CAAA;AApBY,QAAA,UAAU,cAoBtB"}
|
|
@@ -16,5 +16,9 @@ export * from './getAppMfaUri';
|
|
|
16
16
|
export * from './callAppMfa';
|
|
17
17
|
export * from './dateUtils';
|
|
18
18
|
export * from './cancellationUtils';
|
|
19
|
+
export * from './cancellationOffersUtils';
|
|
19
20
|
export * from './layoutReflowUtils';
|
|
21
|
+
export * from './dmccVariant';
|
|
20
22
|
export * from './entitlementUtils';
|
|
23
|
+
export * from './randomizeReasons';
|
|
24
|
+
export * from './stringUtils';
|
|
@@ -32,8 +32,10 @@ __exportStar(require("./getAppMfaUri"), exports);
|
|
|
32
32
|
__exportStar(require("./callAppMfa"), exports);
|
|
33
33
|
__exportStar(require("./dateUtils"), exports);
|
|
34
34
|
__exportStar(require("./cancellationUtils"), exports);
|
|
35
|
+
__exportStar(require("./cancellationOffersUtils"), exports);
|
|
35
36
|
__exportStar(require("./layoutReflowUtils"), exports);
|
|
37
|
+
__exportStar(require("./dmccVariant"), exports);
|
|
36
38
|
__exportStar(require("./entitlementUtils"), exports);
|
|
37
|
-
|
|
38
|
-
|
|
39
|
+
__exportStar(require("./randomizeReasons"), exports);
|
|
40
|
+
__exportStar(require("./stringUtils"), exports);
|
|
39
41
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/helpers/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,8CAA2B;AAC3B,kDAA+B;AAC/B,oDAAiC;AACjC,6CAA0B;AAC1B,iDAA8B;AAC9B,iDAA8B;AAC9B,uDAAoC;AACpC,kDAA+B;AAC/B,kDAA+B;AAC/B,iDAA8B;AAC9B,uDAAoC;AACpC,4DAAyC;AACzC,sDAAmC;AACnC,qDAAkC;AAClC,iDAA8B;AAC9B,+CAA4B;AAC5B,8CAA2B;AAC3B,sDAAmC;AACnC,sDAAmC;AACnC,qDAAkC;AAClC,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/helpers/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,8CAA2B;AAC3B,kDAA+B;AAC/B,oDAAiC;AACjC,6CAA0B;AAC1B,iDAA8B;AAC9B,iDAA8B;AAC9B,uDAAoC;AACpC,kDAA+B;AAC/B,kDAA+B;AAC/B,iDAA8B;AAC9B,uDAAoC;AACpC,4DAAyC;AACzC,sDAAmC;AACnC,qDAAkC;AAClC,iDAA8B;AAC9B,+CAA4B;AAC5B,8CAA2B;AAC3B,sDAAmC;AACnC,4DAAyC;AACzC,sDAAmC;AACnC,gDAA6B;AAC7B,qDAAkC;AAClC,qDAAkC;AAClC,gDAA6B"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {
|
|
3
|
+
if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {
|
|
4
|
+
if (ar || !(i in from)) {
|
|
5
|
+
if (!ar) ar = Array.prototype.slice.call(from, 0, i);
|
|
6
|
+
ar[i] = from[i];
|
|
7
|
+
}
|
|
8
|
+
}
|
|
9
|
+
return to.concat(ar || Array.prototype.slice.call(from));
|
|
10
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.randomizeCancellationReasons = void 0;
|
|
13
|
+
var shuffleArray = function (array) {
|
|
14
|
+
var _a;
|
|
15
|
+
var shuffledArray = __spreadArray([], array, true);
|
|
16
|
+
for (var currentIndex = shuffledArray.length - 1; currentIndex > 0; currentIndex--) {
|
|
17
|
+
var randomIndex = Math.floor(Math.random() * (currentIndex + 1));
|
|
18
|
+
_a = [
|
|
19
|
+
shuffledArray[randomIndex],
|
|
20
|
+
shuffledArray[currentIndex],
|
|
21
|
+
], shuffledArray[currentIndex] = _a[0], shuffledArray[randomIndex] = _a[1];
|
|
22
|
+
}
|
|
23
|
+
return shuffledArray;
|
|
24
|
+
};
|
|
25
|
+
var randomizeCancellationReasons = function (reasons) {
|
|
26
|
+
if (!reasons || reasons.length === 0) {
|
|
27
|
+
return [];
|
|
28
|
+
}
|
|
29
|
+
var otherReason = reasons.find(function (reason) { return reason.id === 'other' || reason.label.toLowerCase() === 'other'; });
|
|
30
|
+
var nonOtherReasons = reasons.filter(function (reason) { return reason.id !== 'other' && reason.label.toLowerCase() !== 'other'; });
|
|
31
|
+
// Shuffle non-"Other" reasons
|
|
32
|
+
var shuffledReasons = shuffleArray(nonOtherReasons);
|
|
33
|
+
// Append "Other" at the end if it exists
|
|
34
|
+
return otherReason ? __spreadArray(__spreadArray([], shuffledReasons, true), [otherReason], false) : shuffledReasons;
|
|
35
|
+
};
|
|
36
|
+
exports.randomizeCancellationReasons = randomizeCancellationReasons;
|
|
37
|
+
//# sourceMappingURL=randomizeReasons.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"randomizeReasons.js","sourceRoot":"","sources":["../../../src/helpers/randomizeReasons.ts"],"names":[],"mappings":";;;;;;;;;;;;AAEA,IAAM,YAAY,GAAG,UAAI,KAAU;;IACjC,IAAM,aAAa,qBAAO,KAAK,OAAC,CAAA;IAChC,KACE,IAAI,YAAY,GAAG,aAAa,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 -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.replacePlaceholder = void 0;
|
|
4
|
+
var replacePlaceholder = function (targetString, replacementValue) {
|
|
5
|
+
if (replacementValue === void 0) { replacementValue = ''; }
|
|
6
|
+
return targetString.replace(/##.+##/gm, replacementValue);
|
|
7
|
+
};
|
|
8
|
+
exports.replacePlaceholder = replacePlaceholder;
|
|
9
|
+
//# sourceMappingURL=stringUtils.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"stringUtils.js","sourceRoot":"","sources":["../../../src/helpers/stringUtils.ts"],"names":[],"mappings":";;;AAAO,IAAM,kBAAkB,GAAG,UAChC,YAAoB,EACpB,gBAA6B;IAA7B,iCAAA,EAAA,qBAA6B;IAE7B,OAAO,YAAY,CAAC,OAAO,CAAC,UAAU,EAAE,gBAAgB,CAAC,CAAA;AAC3D,CAAC,CAAA;AALY,QAAA,kBAAkB,sBAK9B"}
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import { Subscriptions } from '../pages/types';
|
|
2
|
-
import {
|
|
2
|
+
import { GrantedIncentives } from '../pages/types';
|
|
3
|
+
import { DetailedFlags } from '@newskit-render/feature-flags';
|
|
4
|
+
import { InvoiceMonthlySummaryBreakdownProps } from 'Components/Sections/CancellationOffers';
|
|
3
5
|
type SubscriptionTypes = Subscriptions[] | null | undefined;
|
|
4
6
|
export declare const sortSubscriptionsByActive: (userSubscriptions: SubscriptionTypes) => Subscriptions[];
|
|
5
7
|
export declare const getFamilyAccountTypes: (userSubscriptions: SubscriptionTypes) => {
|
|
@@ -7,9 +9,11 @@ export declare const getFamilyAccountTypes: (userSubscriptions: SubscriptionType
|
|
|
7
9
|
isUserFamilyAccountPrimaryActive: boolean;
|
|
8
10
|
isUserFamilyAccountSecondary: boolean;
|
|
9
11
|
} | null;
|
|
10
|
-
export declare const isUserPaymentTypeEligibleForZuoraPage: (activeSubscription: Subscriptions) => boolean;
|
|
11
|
-
export declare const findActiveContractPhase: (
|
|
12
|
+
export declare const isUserPaymentTypeEligibleForZuoraPage: (activeSubscription: Subscriptions, featureFlags?: DetailedFlags) => boolean;
|
|
13
|
+
export declare const findActiveContractPhase: (subscription: Subscriptions, usePhasesQuery?: boolean) => import("../pages/types").ContractPhase | {
|
|
14
|
+
type: string | undefined;
|
|
15
|
+
} | undefined;
|
|
12
16
|
export declare const hasActiveOrUpcomingDiscount: (grantedIncentives: GrantedIncentives[]) => boolean;
|
|
13
|
-
export declare const findLatestIncentiveStartDate: (grantedIncentives:
|
|
17
|
+
export declare const findLatestIncentiveStartDate: (grantedIncentives: InvoiceMonthlySummaryBreakdownProps[]) => InvoiceMonthlySummaryBreakdownProps | null;
|
|
14
18
|
export declare const calculateDiscountedPrice: (price: number, discountPercentage?: number | null) => string;
|
|
15
19
|
export {};
|
|
@@ -50,23 +50,30 @@ var getFamilyAccountTypes = function (userSubscriptions) {
|
|
|
50
50
|
};
|
|
51
51
|
};
|
|
52
52
|
exports.getFamilyAccountTypes = getFamilyAccountTypes;
|
|
53
|
-
var isUserPaymentTypeEligibleForZuoraPage = function (activeSubscription) {
|
|
54
|
-
var _a, _b;
|
|
53
|
+
var isUserPaymentTypeEligibleForZuoraPage = function (activeSubscription, featureFlags) {
|
|
54
|
+
var _a, _b, _c;
|
|
55
55
|
var paymentType = ((_b = (_a = activeSubscription === null || activeSubscription === void 0 ? void 0 : activeSubscription.billingDetails) === null || _a === void 0 ? void 0 : _a.paymentMethod) === null || _b === void 0 ? void 0 : _b.type) || '';
|
|
56
56
|
if (!paymentType)
|
|
57
57
|
return false;
|
|
58
58
|
var paymentTypeToLowerCase = paymentType.toLowerCase();
|
|
59
59
|
// Payment type BankTransfer - Direct debit in the UI
|
|
60
60
|
// Payment type CreditCard - Credit/Debit Card in the UI
|
|
61
|
-
if (
|
|
62
|
-
paymentTypeToLowerCase === types_1.PaymentTypes.
|
|
61
|
+
if (!((_c = featureFlags === null || featureFlags === void 0 ? void 0 : featureFlags.enable_payment_method_edit) === null || _c === void 0 ? void 0 : _c.enabled) &&
|
|
62
|
+
(paymentTypeToLowerCase === types_1.PaymentTypes.creditcard ||
|
|
63
|
+
paymentTypeToLowerCase === types_1.PaymentTypes.banktransfer)) {
|
|
63
64
|
return true;
|
|
64
65
|
}
|
|
65
66
|
return false;
|
|
66
67
|
};
|
|
67
68
|
exports.isUserPaymentTypeEligibleForZuoraPage = isUserPaymentTypeEligibleForZuoraPage;
|
|
68
|
-
var findActiveContractPhase = function (
|
|
69
|
-
|
|
69
|
+
var findActiveContractPhase = function (subscription, usePhasesQuery) {
|
|
70
|
+
var _a, _b, _c;
|
|
71
|
+
if (usePhasesQuery === void 0) { usePhasesQuery = false; }
|
|
72
|
+
if (usePhasesQuery) {
|
|
73
|
+
return (_a = subscription.phases) === null || _a === void 0 ? void 0 : _a.find(function (phase) { return phase.active && phase.currentPhase === CURRENT_PHASE_VALUE; });
|
|
74
|
+
}
|
|
75
|
+
var phase = (_c = (_b = subscription.lifeCycleStage) === null || _b === void 0 ? void 0 : _b.split('.')[1]) === null || _c === void 0 ? void 0 : _c.trim();
|
|
76
|
+
return { type: phase };
|
|
70
77
|
};
|
|
71
78
|
exports.findActiveContractPhase = findActiveContractPhase;
|
|
72
79
|
var hasActiveOrUpcomingDiscount = function (grantedIncentives) {
|
|
@@ -94,8 +101,8 @@ var findLatestIncentiveStartDate = function (grantedIncentives) {
|
|
|
94
101
|
if (!(grantedIncentives === null || grantedIncentives === void 0 ? void 0 : grantedIncentives.length))
|
|
95
102
|
return null;
|
|
96
103
|
return grantedIncentives.reduce(function (latest, current) {
|
|
97
|
-
var latestDate = new utc_1.UTCDate(latest.
|
|
98
|
-
var currentDate = new utc_1.UTCDate(current.
|
|
104
|
+
var latestDate = new utc_1.UTCDate(latest.fromDate);
|
|
105
|
+
var currentDate = new utc_1.UTCDate(current.fromDate);
|
|
99
106
|
return (0, isAfter_1.isAfter)(currentDate, latestDate) ? current : latest;
|
|
100
107
|
});
|
|
101
108
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"subscriptionsUtils.js","sourceRoot":"","sources":["../../../src/helpers/subscriptionsUtils.ts"],"names":[],"mappings":";;;;;;;;;;;;AACA,mEAAwE;AAExE,4CAA0C;AAC1C,8DAA4D;AAC5D,8CAA4C;AAC5C,qCAAuC;
|
|
1
|
+
{"version":3,"file":"subscriptionsUtils.js","sourceRoot":"","sources":["../../../src/helpers/subscriptionsUtils.ts"],"names":[],"mappings":";;;;;;;;;;;;AACA,mEAAwE;AAExE,4CAA0C;AAC1C,8DAA4D;AAC5D,8CAA4C;AAC5C,qCAAuC;AAMvC,IAAM,mBAAmB,GAAG,KAAK,CAAA;AACjC,IAAM,0BAA0B,GAAG,WAAW,CAAA;AAC9C,IAAM,QAAQ,GAAG,UAAU,CAAA;AAEpB,IAAM,yBAAyB,GAAG,UACvC,iBAAoC;IAEpC,IAAI,CAAC,CAAA,iBAAiB,aAAjB,iBAAiB,uBAAjB,iBAAiB,CAAE,MAAM,CAAA;QAAE,OAAO,EAAE,CAAA;IAEzC,OAAO,iBAAiB,CAAC,IAAI,CAAC,UAAC,CAAC,EAAE,CAAC;QACjC,4DAA4D;QAE5D,OAAO,CAAC,CAAC,QAAQ,KAAK,CAAC,CAAC,QAAQ;YAC9B,CAAC,CAAC,IAAI,IAAI,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,OAAO,EAAE,GAAG,IAAI,IAAI,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,OAAO,EAAE;YACnE,CAAC,CAAC,CAAC,CAAC,QAAQ;gBACZ,CAAC,CAAC,CAAC,CAAC;gBACJ,CAAC,CAAC,CAAC,CAAA,CAAC,2DAA2D;IACnE,CAAC,CAAC,CAAA;AACJ,CAAC,CAAA;AAdY,QAAA,yBAAyB,6BAcrC;AAEM,IAAM,qBAAqB,GAAG,UAAC,iBAAoC;;IACxE,IAAI,CAAC,CAA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e,GAAG,CAAC,KAAK,CAAC;QAC9B,CAAC,CAAC,eAAe,CAAC,QAAQ,EAAE;QAC5B,CAAC,CAAC,eAAe,CAAC,OAAO,CAAC,CAAC,CAAC,CAAA;AAChC,CAAC,CAAA;AAXY,QAAA,wBAAwB,4BAWpC"}
|
package/dist/cjs/index.d.ts
CHANGED
|
@@ -38,3 +38,4 @@ export * from './Components/Elements/SunArticleCard';
|
|
|
38
38
|
export * from './Components/Elements/SunArticleGrid';
|
|
39
39
|
export { CANCELLATION_EXPERIMENT } from './constants';
|
|
40
40
|
export { type OfferProps } from './Components/Elements/OfferGroup';
|
|
41
|
+
export { ContactMethodListItem } from './Components/Sections/ContactSupport';
|
|
@@ -47,15 +47,15 @@ var CancellationStepperContext_1 = require("./CancellationStepperContext");
|
|
|
47
47
|
var helpers_1 = require("../../helpers");
|
|
48
48
|
var shared_components_1 = require("@newskit-render/shared-components");
|
|
49
49
|
var CancellationStepper = function (_a) {
|
|
50
|
-
var _b, _c
|
|
51
|
-
var customTheme = _a.customTheme, themeDropdownObject = _a.themeDropdownObject, context = _a.context, env = _a.env, user = _a.user,
|
|
50
|
+
var _b, _c;
|
|
51
|
+
var customTheme = _a.customTheme, themeDropdownObject = _a.themeDropdownObject, context = _a.context, env = _a.env, user = _a.user, _d = _a.footer, footer = _d === void 0 ? true : _d, _e = _a.sidebar, sidebar = _e === void 0 ? true : _e, requestHeaders = _a.requestHeaders, featureFlags = _a.featureFlags;
|
|
52
52
|
var contextName = types_1.ContextName.CancellationStepper;
|
|
53
|
-
var activeContractPhase = ((
|
|
54
|
-
? (0, helpers_1.findActiveContractPhase)(user.subscriptions[0]
|
|
53
|
+
var activeContractPhase = ((_b = user === null || user === void 0 ? void 0 : user.subscriptions) === null || _b === void 0 ? void 0 : _b[0])
|
|
54
|
+
? (0, helpers_1.findActiveContractPhase)(user.subscriptions[0])
|
|
55
55
|
: null;
|
|
56
56
|
var contractPhase = (activeContractPhase === null || activeContractPhase === void 0 ? void 0 : activeContractPhase.type) || '';
|
|
57
57
|
var inEmbeddedMode = (0, shared_components_1.checkRequestHeaders)(requestHeaders, shared_components_1.UserPlatform.native_tm_apps);
|
|
58
|
-
var enhancedContext = __assign(__assign({}, (0, lodash_assign_1.default)({}, (0, CancellationStepperContext_1.CancellationStepperContext)((
|
|
58
|
+
var enhancedContext = __assign(__assign({}, (0, lodash_assign_1.default)({}, (0, CancellationStepperContext_1.CancellationStepperContext)((_c = featureFlags === null || featureFlags === void 0 ? void 0 : featureFlags.enable_cancel_subscription) === null || _c === void 0 ? void 0 : _c.variationKey, contractPhase, inEmbeddedMode), context)), { userData: user, env: env, handleError: toastFunctions_1.handleError, handleLoading: toastFunctions_1.handleLoading, handleSuccess: toastFunctions_1.handleSuccess, requestHeaders: requestHeaders, featureFlags: featureFlags });
|
|
59
59
|
return (react_1.default.createElement(Templates_1.default, { context: enhancedContext, customTheme: customTheme, themeDropdownObject: themeDropdownObject, contextName: contextName, footer: footer, sidebar: sidebar },
|
|
60
60
|
react_1.default.createElement(Templates_1.CancellationStepperRender, null)));
|
|
61
61
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CancellationStepper.js","sourceRoot":"","sources":["../../../../src/pages/CancellationStepper/CancellationStepper.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,gDAAyB;AACzB,gEAAkC;AAClC,sEAA8E;AAE9E,+DAIqC;AACrC,6CAAiD;AACjD,2EAAyE;AACzE,yCAAuD;AACvD,uEAG0C;AAEnC,IAAM,mBAAmB,GAAgC,UAAC,EAUhE;;QATC,WAAW,iBAAA,EACX,mBAAmB,yBAAA,EACnB,OAAO,aAAA,EACP,GAAG,SAAA,EACH,IAAI,UAAA,EACJ,cAAa,EAAb,MAAM,mBAAG,IAAI,KAAA,EACb,eAAc,EAAd,OAAO,mBAAG,IAAI,KAAA,EACd,cAAc,oBAAA,EACd,YAAY,kBAAA;IAEZ,IAAM,WAAW,GAAG,mBAAW,CAAC,mBAAmB,CAAA;IACnD,IAAM,mBAAmB,GAAG,CAAA,MAAA,
|
|
1
|
+
{"version":3,"file":"CancellationStepper.js","sourceRoot":"","sources":["../../../../src/pages/CancellationStepper/CancellationStepper.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,gDAAyB;AACzB,gEAAkC;AAClC,sEAA8E;AAE9E,+DAIqC;AACrC,6CAAiD;AACjD,2EAAyE;AACzE,yCAAuD;AACvD,uEAG0C;AAEnC,IAAM,mBAAmB,GAAgC,UAAC,EAUhE;;QATC,WAAW,iBAAA,EACX,mBAAmB,yBAAA,EACnB,OAAO,aAAA,EACP,GAAG,SAAA,EACH,IAAI,UAAA,EACJ,cAAa,EAAb,MAAM,mBAAG,IAAI,KAAA,EACb,eAAc,EAAd,OAAO,mBAAG,IAAI,KAAA,EACd,cAAc,oBAAA,EACd,YAAY,kBAAA;IAEZ,IAAM,WAAW,GAAG,mBAAW,CAAC,mBAAmB,CAAA;IACnD,IAAM,mBAAmB,GAAG,CAAA,MAAA,IAAI,aAAJ,IAAI,uBAAJ,IAAI,CAAE,aAAa,0CAAG,CAAC,CAAC;QAClD,CAAC,CAAC,IAAA,iCAAuB,EAAC,IAAI,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC;QAChD,CAAC,CAAC,IAAI,CAAA;IAER,IAAM,aAAa,GAAG,CAAA,mBAAmB,aAAnB,mBAAmB,uBAAnB,mBAAmB,CAAE,IAAI,KAAI,EAAE,CAAA;IACrD,IAAM,cAAc,GAAG,IAAA,uCAAmB,EACxC,cAAc,EACd,gCAAY,CAAC,cAAc,CAC5B,CAAA;IAED,IAAM,eAAe,yBAChB,IAAA,uBAAM,EACP,EAAE,EACF,IAAA,uDAA0B,EACxB,MAAA,YAAY,aAAZ,YAAY,uBAAZ,YAAY,CAAE,0BAA0B,0CAAE,YAAY,EACtD,aAAa,EACb,cAAc,CACf,EACD,OAAO,CACR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