From 01b498f549485e5365d56c5f13af10f2056c9f39 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jan=20Jakes=CC=8C?= Date: Thu, 30 Jan 2020 11:28:11 +0100 Subject: [PATCH] Remove WooCommerce step from setup wizard [MAILPOET-2619] --- .../js/src/wizard/steps/woo_commerce_step.jsx | 43 ------------------- assets/js/src/wizard/steps_numbers.jsx | 7 --- .../src/wizard/welcome_wizard_controller.jsx | 16 ------- views/welcome_wizard.html | 6 --- 4 files changed, 72 deletions(-) delete mode 100644 assets/js/src/wizard/steps/woo_commerce_step.jsx diff --git a/assets/js/src/wizard/steps/woo_commerce_step.jsx b/assets/js/src/wizard/steps/woo_commerce_step.jsx deleted file mode 100644 index 238bf1f40a..0000000000 --- a/assets/js/src/wizard/steps/woo_commerce_step.jsx +++ /dev/null @@ -1,43 +0,0 @@ -import PropTypes from 'prop-types'; -import React from 'react'; -import MailPoet from 'mailpoet'; - -const WelcomeWizardWooCommerceStep = (props) => ( -
-

{MailPoet.I18n.t('welcomeWizardWooCommerceStepTitle')}

-

- {MailPoet.I18n.t('welcomeWizardHelpingShopOwnersText')} -

-

- {MailPoet.I18n.t('welcomeWizardWooCommerceEmailsText')} -

- WooCommerce email -
- -
-
-); - -WelcomeWizardWooCommerceStep.propTypes = { - next: PropTypes.func.isRequired, - screenshot_src: PropTypes.string.isRequired, - loading: PropTypes.bool.isRequired, -}; - -export default WelcomeWizardWooCommerceStep; diff --git a/assets/js/src/wizard/steps_numbers.jsx b/assets/js/src/wizard/steps_numbers.jsx index b1a1d39826..84c55a6a9b 100644 --- a/assets/js/src/wizard/steps_numbers.jsx +++ b/assets/js/src/wizard/steps_numbers.jsx @@ -1,8 +1,5 @@ export const getStepsCount = () => { let stepsCount = 3; - if (window.is_woocommerce_active) { - stepsCount += 1; - } if (!window.has_mss_key_specified) { stepsCount += 1; } @@ -20,7 +17,6 @@ export const redirectToNextStep = (history, finishWizard, currentStep) => { export const mapStepNumberToStepName = (stepNumber) => { const shouldSetSender = !window.is_mp2_migration_complete; - const isWoocommerceActive = window.is_woocommerce_active; if (stepNumber === 1 && shouldSetSender) { return 'WelcomeWizardSenderStep'; } @@ -33,8 +29,5 @@ export const mapStepNumberToStepName = (stepNumber) => { if (stepNumber === 3) { return 'WelcomeWizardUsageTrackingStep'; } - if (stepNumber === 4 && isWoocommerceActive) { - return 'WelcomeWizardWooCommerceStep'; - } return 'WelcomeWizardPitchMSSStep'; }; diff --git a/assets/js/src/wizard/welcome_wizard_controller.jsx b/assets/js/src/wizard/welcome_wizard_controller.jsx index 01045f277c..8ad846049e 100644 --- a/assets/js/src/wizard/welcome_wizard_controller.jsx +++ b/assets/js/src/wizard/welcome_wizard_controller.jsx @@ -6,7 +6,6 @@ import WelcomeWizardSenderStep from './steps/sender_step.jsx'; import WelcomeWizardMigratedUserStep from './steps/migrated_user_step.jsx'; import WelcomeWizardEmailCourseStep from './steps/email_course_step.jsx'; import WelcomeWizardUsageTrackingStep from './steps/usage_tracking_step.jsx'; -import WelcomeWizardWooCommerceStep from './steps/woo_commerce_step.jsx'; import WelcomeWizardPitchMSSStep from './steps/pitch_mss_step.jsx'; import WelcomeWizardStepLayout from './layout/step_layout.jsx'; @@ -135,21 +134,6 @@ const WelcomeWizardStepsController = (props) => { ) : null} - { stepName === 'WelcomeWizardWooCommerceStep' - ? ( - - redirect(step)} - screenshot_src={window.wizard_woocommerce_box_url} - loading={loading} - /> - - ) : null} - { stepName === 'WelcomeWizardPitchMSSStep' ? ( '; var wizard_email_course_illustration_url = '<%= cdn_url('welcome-wizard/email-course.20190409.png') %>'; var wizard_tracking_illustration_url = '<%= cdn_url('welcome-wizard/tracking.20190409.png') %>'; - var wizard_woocommerce_illustration_url = '<%= cdn_url('welcome-wizard/woocommerce.20190409.png') %>'; - var wizard_woocommerce_box_url = '<%= cdn_url('welcome-wizard/woocommerce-box.20190409.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) %>; @@ -36,7 +34,6 @@ '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:'), -'welcomeWizardWooCommerceStepTitle': __('Automate your WooCommerce emails.'), 'welcomeWizardTrackingText': __('Gathering usage data allows us to make MailPoet better — the way you use MailPoet will be considered as we evaluate new features, judge the quality of an update, or determine if an improvement makes sense.'), 'welcomeWizardTrackingList1': __('Any personal data'), 'welcomeWizardTrackingList2': __('Email addresses'), @@ -44,8 +41,6 @@ 'welcomeWizardTrackingList4': __('Content of your emails'), 'welcomeWizardTrackingList5': __('Open and click rates'), 'welcomeWizardTrackingLink': __('Read more about what we collect.'), -'welcomeWizardHelpingShopOwnersText': __('We’re making it easier for shop owners to send emails to their customers and make more money.'), -'welcomeWizardWooCommerceEmailsText': __('Create a new email to find the WooCommerce type of emails:'), 'welcomeWizardEmailCourseTitle': __('Sign up to our 4-part email course'), 'welcomeWizardEmailCourseText': __('A must for every beginner (in English only)'), 'seeVideoGuide': _x('See video guide', 'A label on a button'), @@ -57,7 +52,6 @@ 'replyToAddress': _x('Reply-to Address', 'A form field label'), 'senderName': _x('From Name', 'A form field label'), 'next': _x('Next', 'A label on a button'), -'gotIt': _x('Got it!', 'A label on a button'), }) %> <% include('mss_pitch_translations.html') %> <% endblock %>