Remove MP2 migration code from the welcome wizard
[MAILPOET-4376]
This commit is contained in:
@@ -1,29 +0,0 @@
|
||||
import PropTypes from 'prop-types';
|
||||
import { MailPoet } from 'mailpoet';
|
||||
import { Button } from '../../common';
|
||||
import { Heading } from '../../common/typography/heading/heading';
|
||||
|
||||
function WelcomeWizardMigratedUserStep(props) {
|
||||
return (
|
||||
<>
|
||||
<Heading level={1}>
|
||||
{MailPoet.I18n.t('welcomeWizardLetsStartTitle')}
|
||||
</Heading>
|
||||
|
||||
<div className="mailpoet-gap" />
|
||||
<p>{MailPoet.I18n.t('welcomeWizardSenderMigratedUserText')}</p>
|
||||
<div className="mailpoet-gap" />
|
||||
<div className="mailpoet-gap" />
|
||||
|
||||
<Button isFullWidth onClick={props.next} type="button">
|
||||
{MailPoet.I18n.t('continue')}
|
||||
</Button>
|
||||
</>
|
||||
);
|
||||
}
|
||||
|
||||
WelcomeWizardMigratedUserStep.propTypes = {
|
||||
next: PropTypes.func.isRequired,
|
||||
};
|
||||
|
||||
export { WelcomeWizardMigratedUserStep };
|
@@ -19,13 +19,9 @@ export const redirectToNextStep = (history, finishWizard, currentStep) => {
|
||||
};
|
||||
|
||||
export const mapStepNumberToStepName = (stepNumber) => {
|
||||
const shouldSetSender = !window.is_mp2_migration_complete;
|
||||
if (stepNumber === 1 && shouldSetSender) {
|
||||
if (stepNumber === 1) {
|
||||
return 'WelcomeWizardSenderStep';
|
||||
}
|
||||
if (stepNumber === 1 && !shouldSetSender) {
|
||||
return 'WelcomeWizardMigratedUserStep';
|
||||
}
|
||||
if (stepNumber === 2) {
|
||||
return 'WelcomeWizardUsageTrackingStep';
|
||||
}
|
||||
|
@@ -4,7 +4,6 @@ import { partial } from 'underscore';
|
||||
|
||||
import { MailPoet } from 'mailpoet';
|
||||
import { WelcomeWizardSenderStep } from './steps/sender_step.jsx';
|
||||
import { WelcomeWizardMigratedUserStep } from './steps/migrated_user_step.jsx';
|
||||
import { WelcomeWizardUsageTrackingStep } from './steps/usage_tracking_step.jsx';
|
||||
import { WelcomeWizardPitchMSSStep } from './steps/pitch_mss_step.jsx';
|
||||
import { WooCommerceController } from './woocommerce_controller.jsx';
|
||||
@@ -118,14 +117,6 @@ function WelcomeWizardStepsController(props) {
|
||||
</WelcomeWizardStepLayout>
|
||||
) : null}
|
||||
|
||||
{stepName === 'WelcomeWizardMigratedUserStep' ? (
|
||||
<WelcomeWizardStepLayout
|
||||
illustrationUrl={window.wizard_sender_illustration_url}
|
||||
>
|
||||
<WelcomeWizardMigratedUserStep next={() => redirect(step)} />
|
||||
</WelcomeWizardStepLayout>
|
||||
) : null}
|
||||
|
||||
{stepName === 'WelcomeWizardUsageTrackingStep' ? (
|
||||
<WelcomeWizardStepLayout
|
||||
illustrationUrl={window.wizard_tracking_illustration_url}
|
||||
|
@@ -4,7 +4,6 @@ namespace MailPoet\AdminPages\Pages;
|
||||
|
||||
use MailPoet\AdminPages\PageRenderer;
|
||||
use MailPoet\Config\Menu;
|
||||
use MailPoet\Config\MP2Migrator;
|
||||
use MailPoet\Features\FeaturesController;
|
||||
use MailPoet\Services\Bridge;
|
||||
use MailPoet\Settings\SettingsController;
|
||||
@@ -50,7 +49,6 @@ class WelcomeWizard {
|
||||
public function render() {
|
||||
if ((bool)(defined('DOING_AJAX') && DOING_AJAX)) return;
|
||||
$data = [
|
||||
'is_mp2_migration_complete' => (bool)$this->settings->get(MP2Migrator::MIGRATION_COMPLETE_SETTING_KEY),
|
||||
'is_woocommerce_active' => $this->woocommerceHelper->isWooCommerceActive(),
|
||||
'finish_wizard_url' => $this->wp->adminUrl('admin.php?page=' . Menu::MAIN_PAGE_SLUG),
|
||||
'sender' => $this->settings->get('sender'),
|
||||
|
@@ -7,7 +7,6 @@
|
||||
var wizard_tracking_illustration_url = '<%= cdn_url('welcome-wizard/tracking.20200623.png') %>';
|
||||
var wizard_woocommerce_illustration_url = '<%= cdn_url('welcome-wizard/woocommerce.20200623.png') %>';
|
||||
var wizard_MSS_pitch_illustration_url = '<%= cdn_url('welcome-wizard/illu-pitch-mss.20190912.png') %>';
|
||||
var is_mp2_migration_complete = <%= json_encode(is_mp2_migration_complete) %>;
|
||||
var is_woocommerce_active = <%= json_encode(is_woocommerce_active) %>;
|
||||
var finish_wizard_url = '<%= finish_wizard_url %>';
|
||||
var sender_data = <%= json_encode(sender) %>;
|
||||
@@ -34,7 +33,6 @@
|
||||
<%= localize({
|
||||
'welcomeWizardLetsStartTitle': __('Welcome! Let’s get you started on the right foot.'),
|
||||
'welcomeWizardSenderText': __('Who is the sender of the emails you’ll be creating with MailPoet?'),
|
||||
'welcomeWizardSenderMigratedUserText': __('We have a few things to tell you before you begin to ensure you have a good experience.'),
|
||||
'welcomeWizardUsageTrackingStepTitle': __('Help MailPoet improve with anonymous usage tracking.'),
|
||||
'welcomeWizardUsageTrackingStepSubTitle': __('Data we don’t gather:'),
|
||||
'welcomeWizardUsageTrackingStepTrackingLabel': __('Do you want to share anonymous data and help us improve the plugin? We appreciate your help!'),
|
||||
|
Reference in New Issue
Block a user