Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature Request: When account email address is updated, remind update WHOIS email #99739

Open
wants to merge 3 commits into
base: trunk
Choose a base branch
from

Conversation

katinthehatsite
Copy link
Contributor

@katinthehatsite katinthehatsite commented Feb 13, 2025

Closes #95673

Proposed Changes

This PR updates the wording for updating the contact information for the domain when the user confirms the change of the email on their account to make it more specific.

Screenshot 2025-02-14 at 11 53 41 AM

Testing Instructions

  • Navigate to the Calypso Live link or pull the changes from this branch
  • Navigate to /me/account
  • Change your email address
  • Confirm the email change in your actual email
  • Observe that after the update you see the notice that says Consider updating your domain's contact email to match your new email address
  • Click on the Update information button
  • Confirm that you are brought to /domains/manage?site=all&action=edit-contact-email

Alternatively:

  • Pull the changes from this branch
  • Apply the following diff:
index 73fbbe8f828..39d58841e80 100644
--- a/client/components/email-verification/index.js
+++ b/client/components/email-verification/index.js
@@ -10,7 +10,8 @@ import { successNotice } from 'calypso/state/notices/actions';
 
 export default function emailVerification( context, next ) {
        const showVerifiedNotice = '1' === context.query.verified;
-       const showNewEmailNotice = '1' === context.query.new_email_result;
+       // const showNewEmailNotice = '1' === context.query.new_email_result;
+       const showNewEmailNotice = true; // Always show for testing
 
        if ( showVerifiedNotice ) {
                context.page.replace( removeQueryArgs( context.canonicalPath, 'verified' ) );
@@ -21,13 +22,15 @@ export default function emailVerification( context, next ) {
                        context.store.dispatch( notice );
                }, 500 ); // A delay is needed here, because the notice state seems to be cleared upon page load
        } else if ( showNewEmailNotice ) {
-               context.page.replace( removeQueryArgs( context.canonicalPath, 'new_email_result' ) );
+               // Commented out for testing
+               // context.page.replace( removeQueryArgs( context.canonicalPath, 'new_email_result' ) );
                setTimeout( () => {
                        const message = i18n.translate(
                                "Email confirmed! Please consider updating your domain's contact email to match your new email address."
                        );
                        const notice = successNotice( message, {
-                               duration: 10000,
+                               duration: null,
+                               isPersistent: true,
                                button: i18n.translate( 'Update information' ),
                                href: '/domains/manage?site=all&action=edit-contact-email',
                                onClick: () => {
  • Navigate to /me/account
  • Observe the notice with the correct wording

Pre-merge Checklist

  • Has the general commit checklist been followed? (PCYsg-hS-p2)
  • Have you written new tests for your changes?
  • Have you tested the feature in Simple (P9HQHe-k8-p2), Atomic (P9HQHe-jW-p2), and self-hosted Jetpack sites (PCYsg-g6b-p2)?
  • Have you checked for TypeScript, React or other console errors?
  • Have you used memoizing on expensive computations? More info in Memoizing with create-selector and Using memoizing selectors and Our Approach to Data
  • Have we added the "[Status] String Freeze" label as soon as any new strings were ready for translation (p4TIVU-5Jq-p2)?
    • For UI changes, have we tested the change in various languages (for example, ES, PT, FR, or DE)? The length of text and words vary significantly between languages.
  • For changes affecting Jetpack: Have we added the "[Status] Needs Privacy Updates" label if this pull request changes what data or activity we track or use (p4TIVU-aUh-p2)?

@katinthehatsite katinthehatsite self-assigned this Feb 13, 2025
@matticbot
Copy link
Contributor

matticbot commented Feb 13, 2025

This PR modifies the release build for the following Calypso Apps:

For info about this notification, see here: PCYsg-OT6-p2

  • notifications
  • wpcom-block-editor

To test WordPress.com changes, run install-plugin.sh $pluginSlug fix/update-wording-for-domain on your sandbox.

@matticbot
Copy link
Contributor

matticbot commented Feb 13, 2025

Here is how your PR affects size of JS and CSS bundles shipped to the user's browser:

App Entrypoints (~74 bytes added 📈 [gzipped])

name        parsed_size           gzip_size
entry-main       +174 B  (+0.0%)      +74 B  (+0.0%)

Common code that is always downloaded and parsed every time the app is loaded, no matter which route is used.

Legend

What is parsed and gzip size?

Parsed Size: Uncompressed size of the JS and CSS files. This much code needs to be parsed and stored in memory.
Gzip Size: Compressed size of the JS and CSS files. This much data needs to be downloaded over network.

Generated by performance advisor bot at iscalypsofastyet.com.

@@ -23,12 +24,20 @@ export default function emailVerification( context, next ) {
context.page.replace( removeQueryArgs( context.canonicalPath, 'new_email_result' ) );
setTimeout( () => {
const message = i18n.translate(
"Email confirmed! Update domains' contact information if necessary."
"Email confirmed! Please consider updating your domain's contact email to match your new email address."
);
const notice = successNotice( message, {
duration: 10000,
button: i18n.translate( 'Update information' ),
href: '/domains/manage?site=all&action=edit-contact-email',
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tested this link that is currently present and it brings you to /domains/manage?site=all&action=edit-contact-email which shows all the domains - either the ones you own or the sites where you are also an admin. I think it might be harder for the user to understand what they need to update in this case. I am wondering if we should somehow pre-filter the domains to only the domains that they own when they click on the current link?

@matticbot matticbot added the [Status] Needs Review The PR is ready for review. This also triggers e2e canary tests and wp-desktop tests automatically. label Feb 14, 2025
@katinthehatsite katinthehatsite requested a review from a team February 14, 2025 11:00
@katinthehatsite
Copy link
Contributor Author

Please review the discussions on the issue before reviewing this PR: #95673

Copy link
Contributor

@bcotrim bcotrim left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍
Tested as described.
My only concern is that the current notification message is quite long for mobile devices and doesn't look very good. Perhaps there is some improvement to be done to the success note for these scenarios with longer messages.
image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Status] Needs Review The PR is ready for review. This also triggers e2e canary tests and wp-desktop tests automatically.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Feature Request: When account email address is updated, offer to update WHOIS email
3 participants