Skip to content

My Jetpack: Finish the onboarding setup wizard - #52775

Open
adampickering wants to merge 13 commits into
trunkfrom
add/my-jetpack-onboarding-steps
Open

adampickering wants to merge 13 commits into
trunkfrom
add/my-jetpack-onboarding-steps

Conversation

@adampickering

@adampickering adampickering commented Sep 24, 2026 •

Copy link
Copy Markdown
Contributor

Fixes #

Proposed changes

This is now the whole onboarding wizard in one PR, so it can be tested and reviewed as final code. It builds on #52765 (merged) and folds in #52844 (the animation), #52842 (tracking), #53750 (lazy loading) and #53880 (the WordPress 7.0 fix), plus the design-system changes from @simison's review. Everything is behind the my-jetpack-onboarding-wizard flag. With the flag off, the only change is a smaller onboarding bundle. The wizard only runs when the Jetpack plugin is active, since the features step switches Jetpack modules. Sites with only standalone plugins keep the single connect screen.

The steps

Step 2, "What's this site for?" The answer reorders the feature list. "Something else" opens a free-text field.

Step 3, the feature list. Six modules: Stats, Forms, Brute Force Protection, Activity Log, Newsletter, Downtime Monitor. Each switch starts at what the site already runs, so nothing changes unless the user moves one. A module the host forces shows a locked switch. Continue waits until the module list has loaded. They're Jetpack modules, not My Jetpack feature cards: the Protect card would install the standalone Protect plugin, Downtime Monitor has no card, and modules give all six one control with names and descriptions from Jetpack itself.

Step 4, the finish. It reports what each switch actually did, read back from the requests. A module that failed gets "Some features need another look" and says so in its own row. "Nothing changed on your site" is only for a run that moved nothing and runs nothing; otherwise it's "You're all set", with a line saying what setup switched on or off.

The panel. A "publish everywhere" composition (everywhere.tsx) beside the site question and a "data in" one (data-in.tsx) beside the feature list. Both build in once and settle, since looping beside a form with no pause control would fail WCAG 2.2.2. Reduced motion gets finished frames. The start step keeps the Jetpack mark drawing in, and the finish step has no panel.

A run survives a reload. The step, answers and switches are held in sessionStorage and read back through clampStep(), so a corrupt value can't land on a step that doesn't exist. It never reopens the finish step, and goes back to the connect step if the user is no longer connected. Every control waits while modules are being switched or the user is on the way out, so nothing settles twice.

The full-window layout is the wizard's own. The takeover styles hang off a jetpack-onboarding-wizard body class the wizard sets while it's open, so the single connect screen (flag off, or the fallback below) keeps trunk's styles and scrolls.

Built from the design system

The switches are the @wordpress/ui Switch. They and the green buttons get their colour from a ThemeProvider seeded #008710 (--jp-green-50) instead of overriding @wordpress/ui internals. The rail head, the finish screen and the connected notice lay out with Stack, and the finish summary is a Card rendered as a list. Continue keeps one small override for its disabled state: the generated pair is 2.7:1, and it keeps the 4.2:1 one.

Loading only when the flag is on

Every site loads the onboarding bundle, flag or not, and the wizard's art alone is about 270 KB, which @kraftbj caught. The wizard now loads with React.lazy as its own onboarding-wizard.js chunk, only when the flag is on. With the flag off, here's what the onboarding screen loads (production build, gzipped in brackets):

File trunk This PR
onboarding.js 262,199 B (62,143) 105,468 B (38,650)

With the flag on, onboarding-wizard.js (540,762 B, 149,347 gzipped) and onboarding-wizard.css (23,592 B) load after it. That chunk carries the wizard, its art, @wordpress/ui and the bundled @wordpress/theme, and onboarding.asset.php no longer depends on wp-theme.

  • public-path.ts is the first module of the onboarding entry and sets webpack's public path from a new webpackPublicPath initial-state value, the way Comments and Forms do, since webpack's 'auto' guess breaks when another plugin combines scripts.
  • If the chunk fails to load, the page logs why and falls back to the single connect screen. Once the site is registered, that fallback keeps "Skip setup", because with the flag on My Jetpack keeps sending a site-only connection back to onboarding and the single screen alone has no way out. While the chunk loads, the window shows the wizard's dark shell.

WordPress 7.0

The wizard imports ThemeProvider from @wordpress/theme, which the default config takes from core's wp-theme script. On WordPress 7.0 that script exports only privateApis, with ThemeProvider locked inside, so the wizard threw "Element type is invalid" and the page stayed blank. 7.1 added the public export. My Jetpack now bundles @wordpress/theme with bundleWpUiDeps: true, as Boost, Protect and the Jetpack plugin already do. The webpack-config README warns against that option for entries that unlock private APIs from an external wp-* script, and none of My Jetpack's entries do. Since the wizard is lazy-loaded, the extra code ships in its chunk, not in onboarding.js. This was already on trunk from #52765, behind the flag, thanks to @LiamSarsfield for catching it.

Related product discussion/links

Does this pull request change what data or activity we track or use?

Yes, while the my-jetpack-onboarding-wizard flag is on. Every event carries the run's flow_id and the step's slug on top of what useAnalytics already adds.

Event Fires Its own properties
jetpack_my_jetpack_onboarding_wizard_step_view a step becomes visible none
jetpack_my_jetpack_onboarding_click "Get started" is clicked (shared with the single-screen flow) flow: 'wizard'
jetpack_my_jetpack_onboarding_connect_error registration or the hand-off fails error_code
jetpack_my_jetpack_onboarding_wizard_site_type_select an option is chosen site_type
jetpack_my_jetpack_onboarding_wizard_site_type_detail Continue on the site-type step, only for "Something else" length_bucket
jetpack_my_jetpack_onboarding_wizard_module_toggle a switch moves module, enabled
jetpack_my_jetpack_onboarding_wizard_step_complete Continue advances none
jetpack_my_jetpack_onboarding_wizard_apply_result the module switches resolve offered, switched_on (by this run only), failed
jetpack_my_jetpack_onboarding_wizard_complete the user finishes site_type
jetpack_my_jetpack_onboarding_wizard_skip the user skips or leaves none
  • There's no abandonment event. Abandonment is a step_view with no later complete or skip for the same flow_id.
  • A successful connection is calypso_jpc_authorize_success on WordPress.com, which already carries from: jetpack-onboarding-wizard. connect_error stays until CONNECT-502 has the connection package record registration failures itself.
  • The step is a slug, never an index, because a connected site opens on the second step.
  • The run id lives in sessionStorage, so the two halves of a run on either side of WordPress.com can be joined. It ends when the user leaves the wizard, and is none where storage is blocked.
  • What someone types about their own site never leaves the browser. Only a length bucket is sent, and a test checks every call the wizard makes for the text.
  • Tracks silently drops events whose name or property keys miss its rules, so tests check every name and every key a full run records.
  • Tracks only loads once the site has agreed to the terms or has a connected user, so the start screen's events on a fresh install are never sent. The connect step's denominator has to come from the server side.

None of the events are registered yet. They'll be registered once they've fired from a flag-on test site.

It also changes site state: the six modules are switched to match what the user left the switches at, through the same activation queue the rest of My Jetpack uses.

Testing instructions

Build My Jetpack (jp build packages/my-jetpack) and turn the flag on in a mu-plugin:

add_filter( 'jetpack_feature_flag_enabled_my-jetpack-onboarding-wizard', '__return_true' );

Open "Jetpack → My Jetpack" on a disconnected self-hosted site with the Jetpack plugin active, in a window at least 1280px wide, with the Network tab open, and connect.

  • onboarding-wizard.js and onboarding-wizard.css load right after onboarding.js, from the same build/ folder.
  • Step 2. Pick a site type. The panel builds in once and stops. Pick "Something else" and the text field appears.
  • Step 3. Six rows with Jetpack's own names, each switch matching what the site runs. On a fresh site Downtime Monitor starts off, and the list order follows the site type.
  • Turn Downtime Monitor on and continue. The finish screen says setup switched it on, and it really is on (check Jetpack → Settings). Leave everything alone and nothing is switched.
  • Reload mid-run. You stay on the same step with the same answers.
  • Step 4. "You're all set" with each row's real result. "Go to My Jetpack" and "Back to your WordPress site" both finish the run once, however many times you click.
  • Watch window._tkq through the run: one flow_id, step as a slug, and for "Something else" a length_bucket but never a word of what you typed.
  • Turn on Reduce motion in your OS. Both panels render finished, and the finish mark doesn't animate.

On WordPress 7.0 (wp core download --version=7.0 --force, with Gutenberg inactive, since it replaces wp-theme), the wizard renders and the console has no errors. On trunk the page is blank.

Flag off:

  • You get the single "Start with Jetpack for free" screen, and it scrolls in a short window.
  • No onboarding-wizard files load.

Flag on with only a standalone plugin (Boost, Protect…) and no Jetpack plugin: you get the single screen, not the wizard.

jp test js packages/my-jetpack covers the steps, the saved run, the exits, the tracking and the chunk fallback. public-path.ts has no unit test, since it only does something when a browser loads the wizard's chunk, which the steps above check. That's why this PR has the "Covered by non-unit tests" label.

@github-actions

github-actions Bot commented Sep 24, 2026 •

Copy link
Copy Markdown
Contributor

Are you an Automattician? Please test your changes on all WordPress.com environments to help mitigate accidental explosions.

  • To test on WoA, go to the Plugins menu on a WoA dev site. Click on the "Upload" button and follow the upgrade flow to be able to upload, install, and activate the Jetpack Beta plugin. Once the plugin is active, go to Jetpack > Jetpack Beta, select your plugin (Jetpack), and enable the add/my-jetpack-onboarding-steps branch.
  • To test on Simple, run the following command on your sandbox:
bin/jetpack-downloader test jetpack add/my-jetpack-onboarding-steps

Interested in more tips and information?

  • In your local development environment, use the jetpack rsync command to sync your changes to a WoA dev blog.
  • Read more about our development workflow here: PCYsg-eg0-p2
  • Figure out when your changes will be shipped to customers here: PCYsg-eg5-p2

@github-actions

github-actions Bot commented Sep 24, 2026 •

Copy link
Copy Markdown
Contributor

Thank you for your PR!

When contributing to Jetpack, we have a few suggestions that can help us test and review your patch:

  • ✅ Include a description of your PR changes.
  • ✅ Add a "[Status]" label (In Progress, Needs Review, ...).
  • ✅ Add testing instructions.
  • ✅ Specify whether this PR includes any changes to data or privacy.
  • ✅ Add changelog entries to affected projects

This comment will be updated as you work on your PR and make changes. If you think that some of those checks are not needed for your PR, please explain why you think so. Thanks for cooperation 🤖


Follow this PR Review Process:

  1. Ensure all required checks appearing at the bottom of this PR are passing.
  2. Make sure to test your changes on all platforms that it applies to. You're responsible for the quality of the code you ship.
  3. You can use GitHub's Reviewers functionality to request a review.
  4. When it's reviewed and merged, you will be pinged in Slack to deploy the changes to WordPress.com simple once the build is done.

If you have questions about anything, reach out in #jetpack-developers for guidance!


Jetpack plugin:

No scheduled milestone found for this plugin.

If you have any questions about the release process, please ask in the #jetpack-releases channel on Slack.


Backup plugin:

No scheduled milestone found for this plugin.

If you have any questions about the release process, please ask in the #jetpack-releases channel on Slack.


Boost plugin:

No scheduled milestone found for this plugin.

If you have any questions about the release process, please ask in the #jetpack-releases channel on Slack.


Search plugin:

No scheduled milestone found for this plugin.

If you have any questions about the release process, please ask in the #jetpack-releases channel on Slack.


Social plugin:

No scheduled milestone found for this plugin.

If you have any questions about the release process, please ask in the #jetpack-releases channel on Slack.


Starter Plugin plugin:

No scheduled milestone found for this plugin.

If you have any questions about the release process, please ask in the #jetpack-releases channel on Slack.


Protect plugin:

No scheduled milestone found for this plugin.

If you have any questions about the release process, please ask in the #jetpack-releases channel on Slack.


Videopress plugin:

No scheduled milestone found for this plugin.

If you have any questions about the release process, please ask in the #jetpack-releases channel on Slack.


Stats Data plugin:

No scheduled milestone found for this plugin.

If you have any questions about the release process, please ask in the #jetpack-releases channel on Slack.

@jp-launch-control

jp-launch-control Bot commented Sep 24, 2026 •

Copy link
Copy Markdown

Code Coverage Summary

Coverage changed in 12 files. Only the first 5 are listed here.

File Coverage Δ% Δ Uncovered
projects/packages/my-jetpack/_inc/components/onboarding-screen/wizard/lib.ts 37/38 (97.37%) 2.37% 0 💚
projects/packages/my-jetpack/_inc/components/onboarding-screen/wizard/panel-art.tsx 14/16 (87.50%) -1.39% 0 💚
projects/packages/my-jetpack/_inc/components/onboarding-screen/wizard/steps/start-step.tsx 21/22 (95.45%) 0.22% 0 💚
projects/packages/my-jetpack/_inc/components/onboarding-screen/wizard/wizard.tsx 117/117 (100.00%) 0.00% 0 💚
projects/packages/my-jetpack/src/class-initializer.php 617/735 (83.95%) 0.09% 0 💚

14 files are newly checked for coverage. Only the first 5 are listed here.

File Coverage
projects/packages/my-jetpack/_inc/public-path.ts 0/2 (0.00%) 💔
projects/packages/my-jetpack/_inc/components/onboarding-screen/wizard/use-just-connected.ts 7/10 (70.00%) 💚
projects/packages/my-jetpack/_inc/components/onboarding-screen/wizard/use-saved-run.ts 21/23 (91.30%) 💚
projects/packages/my-jetpack/_inc/components/onboarding-screen/wizard/everywhere.tsx 41/43 (95.35%) 💚
projects/packages/my-jetpack/_inc/components/onboarding-screen/wizard/telemetry.ts 25/26 (96.15%) 💚

Full summary · PHP report · JS report

Coverage check overridden by Covered by non-unit tests Use to ignore the Code coverage requirement check when E2Es or other non-unit tests cover the code .

@kraftbj kraftbj left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

This needs a rebase onto 52765's head before it can land. Trunk's @wordpress/ui 0.24 renamed LinkButton to ButtonLink, so the new uses in finish-step.tsx and wizard.tsx won't build once rebased. The wizard.tsx conflict is only that rename. The failing onboarding e2e test is already fixed on 52765.

Nothing inline blocks merging behind the flag, but I'd want the finish-screen and module-default ones sorted before the flag goes on anywhere. The smoke test mocks use-setup-modules entirely, so the real apply loop, its failure path and the loading state aren't covered. That's how the first few got through.

Minor: the two art files add about 270 KB to the onboarding bundle, which the flag-off screen also loads. Lazy-loading Wizard would keep that out.

Comment thread projects/packages/my-jetpack/_inc/components/onboarding-screen/wizard/wizard.tsx Outdated
Comment thread projects/packages/my-jetpack/_inc/components/onboarding-screen/wizard/lib.ts Outdated
Comment thread projects/packages/my-jetpack/_inc/components/onboarding-screen/wizard/wizard.tsx Outdated
Comment thread projects/packages/my-jetpack/_inc/components/onboarding-screen/wizard/wizard.tsx Outdated
Base automatically changed from add/my-jetpack-onboarding-wizard to trunk October 16, 2026 19:32
@DevinWalker
DevinWalker requested a review from a team as a code owner October 16, 2026 19:32
@github-actions github-actions Bot added [Plugin] Backup A plugin that allows users to save every change and get back online quickly with one-click restores. [Plugin] Boost A feature to speed up the site and improve performance. [Plugin] Jetpack Issues about the Jetpack plugin. https://wordpress.org/plugins/jetpack/ [Plugin] Protect A plugin with features to protect a site: brute force protection, security scanning, and a WAF. [Plugin] Search A plugin to add an instant search modal to your site to help visitors find content faster. [Plugin] Social Issues about the Jetpack Social plugin [Plugin] Starter Plugin labels Oct 16, 2026

@LiamSarsfield LiamSarsfield left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

It works well behind the flag and I like that the module switching goes through requestModuleSwitch and the shared store.

One thing I think worth fixing is the FormToggle import in features-step.tsx. Trunk now runs the use-recommended-components lint rule at error level and that file isn't on the exclude list, so lint will fail once this is rebased.
+1 to the Switch suggestion, as @wordpress/ui 0.24 already ships it. The comment saying it doesn't can go too.

A few non blocking questions.

  • Is it worth checking hasFinishedResolution( 'getJetpackModules' ) in use-setup-modules.ts too? On a reload onto the features step the first render reads as "couldn't be loaded" with Continue enabled.
  • Have you tried the wizard on WordPress 7.0? On 7.0 core's wp-theme only exports privateApis, so I think ThemeProvider ends up undefined. That's from the wizard already on trunk, not this PR.
  • Should the data-in.tsx docblock stop saying the flow keeps looping, now that it runs once?

@simison

simison commented Oct 19, 2026

Copy link
Copy Markdown
Member

Hi! I left some comments from a design system/component usage perspective; mostly small stuff that the agent can likely take care of easily. The SwitchControl would be good to see here instead of the older component. Otherwise, if you're in a time crunch to ship or the new component doesn't work for you yet, the exclusion list can help! Lemme know if need any help with components.

@DevinWalker
DevinWalker force-pushed the add/my-jetpack-onboarding-steps branch from cdaf7c2 to 1daf7e9 Compare October 20, 2026 17:15
@DevinWalker

Copy link
Copy Markdown
Contributor

Thanks @simison and @LiamSarsfield for the reviews! Most of this is in 1daf7e9, and the branch is rebased on trunk so the new lint rule is happy.

@LiamSarsfield on your questions:

  • Good catch on the reload. The module list now waits until the request has finished before it says anything, and there's a test for it.
  • Yes, 7.0 breaks it. Core's wp-theme only exports privateApis there, so ThemeProvider comes back undefined. That code is on trunk already, so I'm fixing it in a separate PR.
  • Fixed the data-in docblock, it runs once now.

@DevinWalker DevinWalker changed the title My Jetpack: the setup wizard's feature and finish steps My Jetpack: Finish the onboarding setup wizard Oct 20, 2026
@DevinWalker DevinWalker added the [Status] Needs Privacy Updates Our support docs will need to be updated to take this change into account label Oct 20, 2026
DevinWalker and others added 13 commits October 20, 2026 12:50
The rest of the onboarding wizard, behind the off-by-default
`my-jetpack-onboarding-wizard` flag:

- Step 2 asks what the site is for, which orders the feature list.
- Step 3 offers six Jetpack modules, each switch starting at what the site
  already runs. Host-forced modules are locked, and Continue waits for the
  list to load.
- Step 4 reports what each switch actually did, failures included.
- An animated panel beside each step, run once rather than looped.
- A run survives a reload, never reopens the finish step, and returns to the
  connect step for a user who is no longer connected.
- The wizard only runs with the Jetpack plugin active, and its window-sized
  takeover styles apply to the wizard alone.

Co-authored-by: Adam Pickering <adam.pickering@a8c.com>
- Derive the reachable step range during render, in place of the two effects
  that raised and lowered the step after a commit.
- One `busy` state for applying and leaving: every control waits while an
  exit is under way, so nothing settles twice and no step moves after it.
- Read the module list only once the user is connected.
- One `tallyResults()` count for the finish screen, one `StepHeading` for
  both question steps, and `.connected` arrives with `.wave`.
- Use `@wordpress/compose`'s media hooks for the parallax.
- Drop dead code: the orphaned `assign-location.ts`, `PanelArt`'s always-true
  `animate` prop, the null finish results, and an unreachable apply check.
…zard

The feature rows use the @wordpress/ui Switch, kept green by a ThemeProvider
seed rather than a components override, and the rail head and finish screen
lay out with Stack. The module list waits for its request to finish before
saying it could not be loaded, and the parallax art and the connection check
get tests.
Tracks events for the wizard funnel, sent only while the flag is on. Every
event carries the run's `flow_id` and the step's slug. What someone types
about their own site never leaves the browser; only a length bucket is sent.
`apply_result` counts what the run changed, a run records one exit, and the
run id works on plain-HTTP wp-admin.

Co-authored-by: Adam Pickering <adam.pickering@a8c.com>
- The step property reads the step's own id, so `stepSlug()` and its tests go.
- `apply_result` counts with the shared `tallyResults()`.
apply() never rejects, so request_failed could never be true. The property-key
check now reads the keys a real run records instead of a hand-kept list, and the
telemetry comments fit the comment budget.
The flag-off onboarding screen every site loads no longer carries the
wizard's code and art. onboarding.js drops from 552,170 to 104,632 bytes
(153,965 to 38,303 gzipped); the wizard, @wordpress/ui and the art now
arrive as onboarding-wizard.js and 97.js only when the
my-jetpack-onboarding-wizard flag is on.

Webpack's public path comes from a new webpackPublicPath initial-state
value, as in Comments and Forms, since 'auto' breaks under script
concatenation. public-path.ts is listed in sideEffects, or webpack drops
the bare import. A chunk that fails to load falls back to the single
connect screen.
public-path.ts is now the first module of the onboarding entry, so it
runs first by construction and needs no sideEffects entry or import-order
rule. Turning off webpack's default vendor split ships the wizard as one
onboarding-wizard.js instead of a second, numbered chunk. The build URL
comes from one helper that get_assets_url() also uses.
A wizard chunk that fails to load now logs why before falling back to
the single connect screen. That fallback keeps the wizard's "Skip setup"
once the site is registered, since with the flag on My Jetpack keeps
sending a site-only connection back to onboarding and the single screen
alone has no way out. While the chunk loads, the window shows the
wizard's dark shell instead of a light blank page.
… from the design system

- Get started, Continue and Go to My Jetpack take their green from a
  ThemeProvider seeded #8710, the same seed the feature switches use,
  instead of overriding @wordpress/ui's internal --wp-ui-button-* colours.
- The generated disabled pair comes from the background ramp, so the seed
  can't move it (2.7:1). Continue, the only one that shows a disabled state,
  keeps the 4.2:1 pair.
- The finish summary is a Card.Root rendered as a list, with Stack rows.
…on WordPress 7.0

The wizard imports ThemeProvider from @wordpress/theme, which was
externalized to core's wp-theme script. WordPress 7.0's wp-theme exports
only privateApis, so ThemeProvider was undefined and the wizard threw on
render. bundleWpUiDeps bundles @wordpress/theme and @wordpress/private-apis,
as Boost, Protect and the Jetpack plugin already do. None of My Jetpack's
webpack entries unlock private APIs from an external wp-* script.
@DevinWalker
DevinWalker force-pushed the add/my-jetpack-onboarding-steps branch from 81d67a3 to 01afcdb Compare October 20, 2026 20:11
@DevinWalker DevinWalker added the Covered by non-unit tests Use to ignore the Code coverage requirement check when E2Es or other non-unit tests cover the code label Oct 20, 2026

@LiamSarsfield LiamSarsfield left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Nice 🚀 the fixes hold up. Bundling @wordpress/theme into the lazy wizard chunk is a neat fix for WordPress 7.0.

Nothing blocks merge from my side, and the WP 7.0 e2e runs pass after the rebase.

Two non-blocking questions.

  • When a switch returns false, should finish-step.tsx say "Couldn't confirm" instead of "Not changed"? The shared store also returns false when the write worked but the refetch failed, or when the queue timed out. That store code isn't new in this PR.
  • If the wizard chunk fails to load, should the fallback in index.tsx hide the connect button for a user who's already connected?

@ederrengifo

ederrengifo commented Oct 21, 2026 •

Copy link
Copy Markdown
Contributor

I wanted to propose something in the context of some recent discussion we had to allow users skip the user connection p1HpG7-yXt. After users click on "Get started" we could show a second step where they can decide to continue with the account connection or skip:

second-step

A few benefits of including something like this:

  • We remove the user connection barrier and give the option to skip it. As it was pointed out in the post, around 45% of non-logged users drop the flow during the registration process, we would giving them a way out.
  • If they choose to skip, we are not forcing users to leave the flow for the connection. They would stays in the plugin.
  • It's an opportunity to add visibility over more advanced solutions beyond the free features.

If we decide to move forward with this or should we address it in a new PR? cc @DevinWalker @adampickering

@adampickering

Copy link
Copy Markdown
Contributor Author

Smoke test and review pass

I tested 01afcdb on a local Docker site (WordPress 7.1.2, Jetpack plugin active, flag on), connected to WordPress.com for real through a tunnel. I also did a review pass of the diff. No blockers. Three things I want to fix before merge, then some smaller ones.

The full flow

1-full-flow.mp4

What worked:

  • Flag on: onboarding-wizard.js and .css load from build/ right after onboarding.js, with no console errors.
  • Flag off: you get the single screen, no wizard files load, and it scrolls in a short window.
  • The switches really change the site. Only the modules that changed get a request.
  • Reloading mid-run keeps the step, the site type and the free text.
  • A double-click on "Go to My Jetpack" sends one onboarding/settled request.
  • Reduced motion shows finished frames. Down to 390px wide, the option list scrolls inside the card.
  • Tracking: one flow_id per run, and step is a slug. "Something else" sends a length_bucket and never the text.
  • All 140 onboarding JS tests pass.

To fix before merge

1. A reload on the finish screen gives the wrong summary.
The restore drops you back on the features step with your saved switches. The site already matches them, so the second Continue reports "Nothing needed changing on this site", and apply_result fires a second time with switched_on: 0. use-saved-run.ts clamps off the finish step to prevent exactly this, but comparing against the site again brings it back.
Fix: save the module states from before the first apply and compare against those, or save the results themselves.

2-reload-misreports.mp4
Before the reload After the reload and Continue
Finish screen: Setup switched on 1 feature Finish screen: Nothing needed changing on this site

2. A switch that worked can be reported as "Not changed".
updateJetpackModuleStatus posts the switch, then re-reads /module/all. If that read fails it returns false, though the POST went through. The 90s queue timeout does the same while the request is still running. In the clip, POST /module/monitor/active returned 200 and I made the follow-up read fail. Monitor is on, but the screen says "Some features need another look" and "Not changed", and failed goes up by one.
Fix: when a switch reports false, re-read that module's state before labelling the row, or say "Couldn't confirm".

3-false-failure.mp4
Finish screen: Some features need another look, Downtime Monitor Not changed

3. The WCAG 2.2.2 claim doesn't hold yet.
The art builds in once and stops, but the four brand-panel__blob gradients loop forever (animation-iteration-count: infinite) beside both forms, with no pause control. Only reduced motion stops them. This PR also made the loops faster: 7, 11, 13 and 17s, down from 17, 19, 23 and 29s on trunk. The clip runs about 30 seconds.
Fix: stop them after about 5s, or add a pause control.

4-background-loops.mp4

Smaller things

  • The step counter disagrees with the rail. A connected site reads "Step 1 of 3" while the rail lists four steps with Connect ticked. A disconnected site reads "of 4".
    Rail: Step 1 of 3 above four steps
  • "· Already on" stays after you switch a module off.
    Newsletter switched off, still reading Already on
  • The art reads "Restoring back backup". It's in the Figma frame, so it needs a re-export.
    Panel art: Restoring back backup
  • apply_result counts what was switched on but not off. Turn-offs only show in the per-switch module_toggle events.
  • If every switch fails, the finish screen still says "The rest are ready".
  • A locked switch gives no reason. Screen readers get a dimmed switch with nothing to explain it. Something like "Managed by your host" would do.
  • While the chunk loads, the screen is an empty dark div with no busy state. Webpack's chunk timeout is 120s, so a hung chunk means up to two minutes of black before the fallback.
  • Two tests pass no matter what. test_wizard_is_disabled_on_wpcom_simple and test_wizard_is_disabled_on_woa never load the mock Jetpack class, so the new class_exists( 'Jetpack' ) gate returns first. Deleting the platform check wouldn't fail them.
  • Flag off isn't quite unchanged. bundleWpUiDeps and the splitChunks change apply to every entry, so header-controls.js and async-notification-bubble build differently too, and onboarding.js picks up a wp-jp-i18n-loader dependency. Nothing unlocks private APIs, so the risk is low, but the description should say so.

Possible, not reproduced

  • Back after leaving the wizard. If bfcache restores the page, isLeaving stays true and every control stays disabled until a reload. Only the start step re-syncs on pageshow.
  • The sessionStorage keys aren't scoped to a site or a user. On a subdirectory multisite, a run started on site A comes back on site B in the same tab, and Continue applies A's switches to B. The restore also doesn't check the shape of choices or wanted.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Covered by non-unit tests Use to ignore the Code coverage requirement check when E2Es or other non-unit tests cover the code [Package] My Jetpack [Plugin] Backup A plugin that allows users to save every change and get back online quickly with one-click restores. [Plugin] Boost A feature to speed up the site and improve performance. [Plugin] Jetpack Issues about the Jetpack plugin. https://wordpress.org/plugins/jetpack/ [Plugin] Protect A plugin with features to protect a site: brute force protection, security scanning, and a WAF. [Plugin] Search A plugin to add an instant search modal to your site to help visitors find content faster. [Plugin] Social Issues about the Jetpack Social plugin [Plugin] Starter Plugin [Plugin] Stats Data [Plugin] VideoPress A standalone plugin to add high-quality VideoPress videos to your site. [Status] Needs Privacy Updates Our support docs will need to be updated to take this change into account [Status] Needs Review This PR is ready for review. [Tests] Includes Tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants