This PR creates a new page to add email forwards, with both the first and later email forward creation supported. The goal is to support adding email forwards from the existing email management page for email forwards, as well as from the new email comparison page that we’re in the process of building.
The page itself is very minimal at present, and reuses the EmailForwardingAddNewCompactList form component, which only supports adding one email forward at a time
One notable feature is that the “Back” button returns the user to the purchase page for the case where the user starts adding an email forward from the new email comparison screen
Another notable item is that when we add an email forward successfully, we redirect the user to the email management page for the relevant domain
Testing instructions
Run this branch locally or via the Calypso live branch
Ensure you have a domain that doesn’t have any email service (which you can buy if needed)
For that domain, navigate to Upgrades -> Emails, and then click on the “Add Email” button to the right of the domain name
You should now be on the email purchase page with the URL of the form /email/:domain/purchase/:site
Add ?flags=emails/new-email-comparison to the URL
Verify that you see the new email comparison page
Next, verify that you see the following text at the bottom of the screen: “Looking for a free email solution? Start with Email Forwarding.”
Switch to monthly billing, and verify that the text is still present
Click on the “Email Forwarding” link
Verify that you’re taken to the “Add New Email Forwards” page at /email/:domain/forwarding/add/:site?source=purchase
Verify that the page looks OK and shows a relevant loading image
Click on the “Back” link in the header
Verify that you’re taken back to the email purchase page
Click on the “Email Forwarding” link at the bottom of the page to get back to the “Add New Email Forwards” page
Try to add a new email forward (and feel free to test the validation, though that hasn’t been touched in this PR) – the “Add” button should only be enabled when the form fields are valid
When the new email forward submission succeeds, verify that you’re redirected to the email management screen for the domain (though it may take a little while to load correctly)
From the email management page, click on the “Add new email forwards” menu item
Verify that you see the “Add New Email Forwards” page
Try to add the same email forward as before
Verify that you get an error message displayed on the same page
Click on the “Back” link in the header
Verify that you’re taken back to the email management screen
Screenshots
New page
Footer link on new email comparison page
Unfortunately, no screenshots were provided by the developer.