Update the upgrade modal msg for automation steps
And handle numeric capabilities [MAILPOET-5938]
This commit is contained in:
committed by
Aschepikov
parent
020aee53aa
commit
5d267b1a41
@ -58,6 +58,7 @@ export function InserterPopover(): JSX.Element | null {
|
|||||||
utm_medium: 'upsell_modal',
|
utm_medium: 'upsell_modal',
|
||||||
utm_campaign: 'add_automation_step',
|
utm_campaign: 'add_automation_step',
|
||||||
}}
|
}}
|
||||||
|
data={{ capabilityName: 'automationSteps' }}
|
||||||
>
|
>
|
||||||
{__('You cannot add a new step to the automation.', 'mailpoet')}
|
{__('You cannot add a new step to the automation.', 'mailpoet')}
|
||||||
</PremiumModal>
|
</PremiumModal>
|
||||||
|
@ -145,19 +145,33 @@ export const getUpgradeInfo = (
|
|||||||
// f. User has a license but the feature is not available for the plan.
|
// f. User has a license but the feature is not available for the plan.
|
||||||
if (
|
if (
|
||||||
capabilityName &&
|
capabilityName &&
|
||||||
typeof MailPoet.capabilities[capabilityName] === 'boolean' &&
|
((typeof MailPoet.capabilities[capabilityName] === 'boolean' &&
|
||||||
!MailPoet.capabilities[capabilityName]
|
!MailPoet.capabilities[capabilityName]) ||
|
||||||
|
(typeof MailPoet.capabilities[capabilityName] === 'number' &&
|
||||||
|
MailPoet.capabilities[capabilityName] > 0))
|
||||||
) {
|
) {
|
||||||
let info = __(
|
let info: string;
|
||||||
'Please upgrade your MailPoet plan to gain access to this feature.',
|
|
||||||
'mailpoet',
|
switch (capabilityName) {
|
||||||
);
|
case 'detailedAnalytics':
|
||||||
if (capabilityName === 'detailedAnalytics') {
|
|
||||||
info = __(
|
info = __(
|
||||||
'Upgrade your MailPoet plan to gain detailed insights into how your subscribers engage with your automations and their purchasing behaviors.',
|
'Upgrade your MailPoet plan to gain detailed insights into how your subscribers engage with your automations and their purchasing behaviors.',
|
||||||
'mailpoet',
|
'mailpoet',
|
||||||
);
|
);
|
||||||
|
break;
|
||||||
|
case 'automationSteps':
|
||||||
|
info = __(
|
||||||
|
'Automation journeys are not available in your current plan. Upgrade your MailPoet plan to design personalized journeys with multiple steps and conditional branching logic.',
|
||||||
|
'mailpoet',
|
||||||
|
);
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
info = __(
|
||||||
|
'Please upgrade your MailPoet plan to gain access to this feature.',
|
||||||
|
'mailpoet',
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
return {
|
return {
|
||||||
title: __('Upgrade your MailPoet plan', 'mailpoet'),
|
title: __('Upgrade your MailPoet plan', 'mailpoet'),
|
||||||
info,
|
info,
|
||||||
|
Reference in New Issue
Block a user