Feature Description
When a user leaves the RRM express setup incomplete, show a notification at the top of the Site Kit dashboard prompting them to resume the setup. It reads the abandoned CTAs from the RRM user settings and routes back into the express flow.
For reference, see the Resuming abandoned setup section in the design doc. See Figma design.
Do not alter or remove anything below. The following sections will be managed by moderators only.
Acceptance criteria
- A new notification shows at the top of the dashboard, behind the
rrmExpressSetup flag.
- It shows when the user has an incomplete newsletter signup RRM express setup (read via the new RRM user setting introduced in #13007), and is hidden otherwise.
- To determine if the setup was incomplete, the user setting is to be compared with the list of configured CTAs for the publication.
- The copy matches the Figma design:
- Title: "You’re just a few steps away from collecting reader emails!"
- Description: "It looks like you haven't finished setting up your newsletter sign-up form. Resume the setup to complete it and publish it to your site."
- Primary CTA: "Show me".
- Secondary CTA: "Got it".
- The primary CTA ("Show me") resumes the express setup, routing to
?expressSetup=true&cta=<cta> for the abandoned CTA (e.g. newsletter-signup).
- The secondary CTA ("Got it") dismisses the notification.
Implementation Brief
Test Coverage
- Add tests for
ResumeRRMExpressSetup notification and cover all the cases.
- Add stories for
ResumeRRMExpressSetup notification in storybook.
QA Brief
- Set up Site Kit and enable Reader Revenue Manager.
- Enable the
rrmExpressSetup feature flag.
- On the Dashboard no abandoned setup notification should appear.
- In the developer console run:
await googlesitekit.data.dispatch("core/user").removeDismissedItems( 'initial-setup-notification-timeout' )
await googlesitekit.data
.dispatch("modules/reader-revenue-manager")
.saveUserSettings({ lastActionedExpressSetups: { 'newsletter-signup': 1784964854 } });
- Refresh, the notice should appear (other notices may need to be dismissed first).
- Disable the
rrmExpressSetup feature flag, the notice should no longer appear.
- Re-enable the flag and return to the dashboard.
- Clicking Show me should navigate to
/wp-admin/admin.php?page=googlesitekit-dashboard&slug=reader-revenue-manager&reAuth=true&expressSetup=true&cta=newsletter-signup, with the cta parameter.
- Clicking Got it should dismiss the notice and it should not re-appear on refresh.
- Reset or sign in as a different admin so that the notice is no longer dismissed.
- In the developer console run:
await googlesitekit.data.dispatch("core/user").removeDismissedItems( 'initial-setup-notification-timeout' )
- In WP CLI, run the following to simulate a CTA being configured (there is no other method to set configured CTAs yet):
wp eval '(new \Google\Site_Kit\Modules\Reader_Revenue_Manager\Settings(new \Google\Site_Kit\Core\Storage\Options(\Google\Site_Kit\Plugin::instance()->context())))->merge(["configuredCTAs"=>["qa-newsletter"=>"newsletter-signup"]]);'
- The notice should no longer appear.
Changelog entry
- Add a dashboard notification prompting users to resume an abandoned Reader Revenue Manager express setup.
Feature Description
When a user leaves the RRM express setup incomplete, show a notification at the top of the Site Kit dashboard prompting them to resume the setup. It reads the abandoned CTAs from the RRM user settings and routes back into the express flow.
For reference, see the Resuming abandoned setup section in the design doc. See Figma design.
Do not alter or remove anything below. The following sections will be managed by moderators only.
Acceptance criteria
rrmExpressSetupflag.?expressSetup=true&cta=<cta>for the abandoned CTA (e.g.newsletter-signup).Implementation Brief
assets/js/modules/reader-revenue-manager/components/dashboard/andassets/js/modules/reader-revenue-manager/notifications/:ResumeRRMExpressSetup) for abandoned express setup and register it alongside the existing RRM dashboard notifications.assets/js/modules/reader-revenue-manager/constants.jsand register it inassets/js/modules/reader-revenue-manager/notifications/index.jswithNOTIFICATION_AREAS.DASHBOARD_TOPandVIEW_CONTEXT_MAIN_DASHBOARD.rrmExpressSetupflag in the notification requirement logic so it is never queued when the flag is disabled.NoticeNotification, so the copy can match the design without introducing custom dismissal behavior.getUserRRMSettingsselector (Add REST controller and datastore infrastructure for RRM user settings #13008).lastActionedExpressSetupsfrom that setting.lastActionedExpressSetupsagainst the configured CTA list for the current RRM publication:?expressSetup=true&cta=<cta>for the abandoned CTA.checkRequirements.Test Coverage
ResumeRRMExpressSetupnotification and cover all the cases.ResumeRRMExpressSetupnotification in storybook.QA Brief
rrmExpressSetupfeature flag.rrmExpressSetupfeature flag, the notice should no longer appear./wp-admin/admin.php?page=googlesitekit-dashboard&slug=reader-revenue-manager&reAuth=true&expressSetup=true&cta=newsletter-signup, with thectaparameter.Changelog entry