Skip to content

Settings: Point the Writing links to Features behind the settings flag - #55012

Merged
dhasilva merged 2 commits into
trunkfrom
update/settings-writing-links-to-features
Nov 16, 2026
Merged

dhasilva merged 2 commits into
trunkfrom
update/settings-writing-links-to-features

Conversation

@dhasilva

@dhasilva dhasilva commented Nov 16, 2026 •

Copy link
Copy Markdown
Contributor

Fixes JETPACK-3730

Proposed changes

Behind the my-jetpack-settings-consolidation flag (off by default). With the flag off nothing changes.

With the flag on, the Settings app hides its Writing tab for admins (#54891). Two links still pointed to it. Now they go to My Jetpack › Features:

  • "Turn on Jetpack Blocks" in the block editor (Unavailable_Blocks::get_editor_data() fixUrl): when the Blocks module is off, a Jetpack block in the editor shows this button. It now opens Features searched for the Blocks module.
    • The search uses the module's translated name. Features searches translated names, never slugs, so the literal blocks would miss the row on non-English sites.
    • Only users who can manage modules see the button. Disconnected sites keep their link to the connection screen.
  • The wpcomsh notice on Settings › Writing:
    • Before: "Visit Jetpack Settings for more writing settings powered by Jetpack.", linking to admin.php?page=jetpack#/writing.
    • After, with the flag on: "Visit My Jetpack › Features for more writing settings powered by Jetpack.", linking to admin.php?page=my-jetpack#/features.
  • Sites where the host hides My Jetpack (Atomic Personal and Premium) keep both old links, since Settings stays there.
  • The redirect map's two /writing entries now note that they apply with the flag off.

No screenshots: the editor button looks the same (only its target changes), and the notice's new text is above.

Related product discussion/links

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

No.

Testing instructions

Turn the flag on with a snippet: add_filter( 'jetpack_feature_flag_enabled_my-jetpack-settings-consolidation', '__return_true' );

Block editor (self-hosted or Atomic, connected, as an admin):

  1. Add a Jetpack block from the Blocks module, such as Business Hours, to a post and save it.
  2. Turn off Blocks in Jetpack › My Jetpack › Features (Writing group).
  3. Reopen the post. The block says "This block is unavailable because Jetpack Blocks is turned off…" with a Turn on Jetpack Blocks button.
  4. Click it: My Jetpack › Features opens filtered to the Blocks row. On a non-English site, the filter is the module's translated name and still finds the row.
  5. Remove the snippet and reload the post: the same button opens Jetpack › Settings › Writing, as before.

wpcomsh notice (Atomic Business running this branch's wpcomsh):

  1. Go to Settings › Writing. If you dismissed the notice before, delete the wpcom_writing_features_notice_dismissed option first.
  2. With the flag on, the notice reads "Visit My Jetpack › Features for more writing settings powered by Jetpack." and links there. With the flag off, it reads and links as before.

Automated: jp docker phpunit jetpack -- --filter=Unavailable_Blocks covers flag off, flag on, the host hiding My Jetpack, and a disconnected site.

The wpcomsh notice file has no unit tests: wpcomsh's suite doesn't load My Jetpack. Both of its branches were checked with a throwaway test against a WordPress install that loads it, and the steps above cover them, hence the Covered by non-unit tests label.

🤖 Generated with Claude Code

dhasilva and others added 2 commits November 16, 2026 13:38
With settings consolidation on, the editor's "Turn on Jetpack Blocks"
link searches My Jetpack › Features for the Blocks module, and the
wpcomsh notice on Settings › Writing links to Features. The search uses
the module's translated name, since Features matches translated names.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ABKQhWcG89Ca835d23UqyF
@github-actions

github-actions Bot commented Nov 16, 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 or WordPress.com Site Helper), and enable the update/settings-writing-links-to-features branch.
  • To test on Simple, run the following command on your sandbox:
bin/jetpack-downloader test jetpack update/settings-writing-links-to-features

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 added [Plugin] Jetpack Issues about the Jetpack plugin. https://wordpress.org/plugins/jetpack/ [Plugin] Wpcomsh [Tests] Includes Tests labels Nov 16, 2026
@github-actions

github-actions Bot commented Nov 16, 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:

The Jetpack plugin has different release cadences depending on the platform:

  • WordPress.com Simple releases happen as soon as you deploy your changes after merging this PR (PCYsg-Jjm-p2).
  • WoA releases happen weekly.
  • Releases to self-hosted sites happen monthly:
    • Scheduled release: December 8, 2026
    • Code freeze: December 7, 2026

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


Wpcomsh plugin:

  • Next scheduled release: Atomic deploys happen twice daily on weekdays (p9o2xV-2EN-p2)

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

@dhasilva
dhasilva marked this pull request as ready for review November 16, 2026 16:49
@dhasilva dhasilva added [Status] Needs Review This PR is ready for review. and removed [Status] In Progress labels Nov 16, 2026
@jp-launch-control

jp-launch-control Bot commented Nov 16, 2026 •

Copy link
Copy Markdown

Code Coverage Summary

Coverage changed in 2 files.

File Coverage Δ% Δ Uncovered
projects/plugins/wpcomsh/notices/feature-moved-to-jetpack-notices.php 0/36 (0.00%) 0.00% 5 💔
projects/plugins/jetpack/src/class-unavailable-blocks.php 54/78 (69.23%) 1.66% 0 💚

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 .

@CGastrell CGastrell 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.

LGTM.

Question: Features also reads ?feature=<slug>, which opens that feature's modal. Would admin.php?page=my-jetpack#/features?feature=blocks work here? It would not depend on the translated module name. I could not confirm that blocks is a feature slug in Features, so the search link may be the only option. class-unavailable-blocks.php#L237-L246

@dhasilva dhasilva 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 Nov 16, 2026
@dhasilva

Copy link
Copy Markdown
Contributor Author

?feature=blocks wouldn't work, as you suspected:

  • ?feature= only opens the modal for a grid card. content.tsx looks the slug up in states, which comes from useFeatureStates( mainFeatures ). Blocks is a More Features row (the Writing group in get_module_groups()), so ?feature=blocks opens nothing.
  • I also checked ?module_tag=blocks. The Blocks tag is translated too (_x( 'blocks', 'Module Tag' ), and get_translated_modules() maps tags through jetpack_get_module_i18n_tag), so it has the same locale problem.

A locale-independent link would need an untranslated search term on the module, so the translated name stays.

Separately, the coverage check failed on the wpcomsh notice file, which has never had tests (wpcomsh's suite doesn't load My Jetpack). I added the Covered by non-unit tests label and a line in the description.

Generated by Claude.

@dhasilva
dhasilva merged commit 5fe363e into trunk Nov 16, 2026
103 checks passed
@dhasilva
dhasilva deleted the update/settings-writing-links-to-features branch November 16, 2026 18:31
@github-actions github-actions Bot added [Status] UI Changes Add this to PRs that change the UI so documentation can be updated. and removed [Status] Needs Review This PR is ready for review. labels Nov 16, 2026
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 [Plugin] Jetpack Issues about the Jetpack plugin. https://wordpress.org/plugins/jetpack/ [Plugin] Wpcomsh [Status] UI Changes Add this to PRs that change the UI so documentation can be updated. [Tests] Includes Tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants