Skip to content

Plugins: turn the Marketplace tab on, and let it work on the Simple site Add Plugins screen - #53169

Merged
rcrdortiz merged 9 commits into
trunkfrom
dotpar-19-simple-personal-premium-and-business-overtake-the-core
Oct 13, 2026
Merged

rcrdortiz merged 9 commits into
trunkfrom
dotpar-19-simple-personal-premium-and-business-overtake-the-core

Conversation

@rcrdortiz

@rcrdortiz rcrdortiz commented Oct 5, 2026 •

Copy link
Copy Markdown
Contributor

Part of DOTPAR-19

Proposed changes

Simple sites are getting a core-style Add Plugins screen at Plugins > Add New Plugin, so they browse plugins the way Atomic sites do. It lives in WordPress.com's own code rather than here: Simple does not ship wp-admin/includes/plugin-install.php, and installing a plugin there means moving the site to Atomic, which WordPress.com handles. That screen fires the same hooks as core's and calls itself the plugin-install screen, so the Marketplace tab and cards from this package attach to it. Four things stood in their way, and this fixes them:

  • Core's install functions are missing on Simple. The cards asked install_plugin_install_status() whether a product is installed. wpcom_marketplace_is_installed() now answers that, and treats the function's absence as nothing installed, which is true on Simple.
  • The details modal only knew plugin-install.php. It now also recognises the plugin-install screen, which is how the Simple page identifies itself.
  • Checkout cannot always complete a purchase on Simple. It drops a Marketplace product from a cart without a plan that includes install-purchased-plugins, and buying one starts the move to Atomic, which Calypso explains first when anything stands in the way. A new wpcom_marketplace_checkout_url filter lets the Simple screen send the purchase through Calypso's plans page, so a plan goes in the same cart, or send it through the product's Calypso page when something blocks the move.
  • Prices could not be fetched on Simple. The connection client answers in-process there, and that path reaches the wpcom/v2 catalog but not the v1.1 products endpoint the cards are priced from, so every card fell back to "Get started". A new wpcom_marketplace_store_products filter lets the Simple screen supply the store's products itself.

It also keeps a product's saving on the same line as its price, on Atomic as well. Core caps that column of the card's bottom strip at 180px for ratings, and a price with its saving needs up to 192px, so "Save 31%" wrapped onto its own line on most cards. That row only shares its line with "Last Updated", so the price now gets whatever that does not need, and never less than core's 180px.

Where the site's plan does not include purchased plugins, the button now says Upgrade and purchase rather than Purchase, since a plan is bought in the same checkout. The longer label wraps onto two lines inside core's 120px button column instead of running over the card's name.

It also turns the Marketplace tab on for every site. The wpcom-plugins-marketplace-tab flag now defaults to on, so the tab and its cards show on the Add Plugins screen of every Atomic site, and of every Simple site once the WordPress.com change is in. The flag stays as an off switch: per site from Tools > Feature Flags (a8c), or for every site by setting its default back.

Apart from the tab going live and the saving fix, nothing changes on Atomic, where a site's plan always includes purchased plugins: the new filters are not used there, and wpcom_marketplace_is_installed() gives the same answer as before wherever core's function exists.

Before and after

The Simple site Add Plugins screen, on a sandboxed Free Simple site, with this change and the WordPress.com one.

Before After
Add New Plugin on a Simple site today The Marketplace tab on the Simple Add Plugins screen, with prices

A Marketplace product's details there:

A Marketplace product's details modal on Simple

Related product discussion/links

  • DOTPAR-19, in the "Simplify choosing and installing plugin for logged-in WordPress users" project.

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

No.

Testing instructions

The wpcom-plugins-marketplace-tab flag is on by default now.

Atomic:

  1. On an Atomic site, go to Plugins > Add New Plugin. The Marketplace tab should be there and open first, without turning anything on.
  2. The Marketplace tab should list the catalog with prices and Purchase buttons, as on trunk, with each Save label on the same line as its price. On a narrow window, where the price and Last Updated no longer fit side by side, the label wraps as it does on trunk.
  3. More Details on a card should open the product's details.
  4. Turn the flag off for the site at Tools > Feature Flags (a8c): the tab should go, and the WordPress.com banner come back.

Simple, together with the WordPress.com change that adds the screen:

  1. On a sandboxed Simple site, go to Plugins > Add New Plugin.
  2. The Marketplace tab should list the catalog with prices. On a site without a plan, each button should say Upgrade and purchase, on two lines, and lead to Calypso's plans page with the product in the cart.
  3. More Details on a Marketplace card should open the product's details, not a WordPress.org error.

…ns are missing

Simple sites draw the Add Plugins screen from their own page, without wp-admin/includes/plugin-install.php and under core's screen id. The cards no longer call install_plugin_install_status() when it is absent, and the details modal recognises that screen.
…re prices

Two filters for the Simple Add Plugins screen in wpcom: wpcom_marketplace_checkout_url, so a purchase checkout cannot complete goes through Calypso, and wpcom_marketplace_store_products, since the in-process API client on Simple cannot reach the v1.1 products endpoint the cards are priced from.
@github-actions

github-actions Bot commented Oct 5, 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!


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.

@github-actions

github-actions Bot commented Oct 5, 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 (WordPress.com Site Helper), and enable the dotpar-19-simple-personal-premium-and-business-overtake-the-core branch.
  • To test on Simple, run the following command on your sandbox:
bin/jetpack-downloader test jetpack-mu-wpcom-plugin dotpar-19-simple-personal-premium-and-business-overtake-the-core

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

@jp-launch-control

jp-launch-control Bot commented Oct 5, 2026 •

Copy link
Copy Markdown

Code Coverage Summary

Coverage changed in 2 files.

File Coverage Δ% Δ Uncovered
projects/packages/jetpack-mu-wpcom/src/features/wpcom-plugins/class-marketplace-catalog.php 198/201 (98.51%) 0.02% 0 💚
projects/packages/jetpack-mu-wpcom/src/features/wpcom-plugins/wpcom-marketplace-tab.php 149/158 (94.30%) 5.87% -8 💚

Full summary · PHP report · JS report

@rcrdortiz
rcrdortiz marked this pull request as ready for review October 5, 2026 15:33
@rcrdortiz rcrdortiz added [Status] Needs Review This PR is ready for review. and removed [Status] In Progress labels Oct 5, 2026
Core caps the strip's left column at 180px for ratings, and a price with
its saving needs up to 192px, so the saving wrapped on most cards. That
row only shares its line with "Last Updated", so give the price whatever
that does not need, and never less than core's 180px.
…sonal-premium-and-business-overtake-the-core
…cks it

A site whose plan does not include purchased plugins can only buy one with
a plan in the same checkout, which a Simple site's checkout URL filter now
adds. "Purchase" read as if the plugin were all it paid for. Its button
says "Upgrade and purchase" there instead, and wraps onto two lines in
core's 120px button column rather than running over the card's name.
Covers both labels. The test runs in its own process: Brain Monkey's stub
of wpcom_site_has_feature() would otherwise stay defined for the rest of
the run and relabel every later button.
The wpcom-plugins-marketplace-tab flag now defaults to on, so the tab and
its cards show on the Add Plugins screen of every Atomic site, and of every
Simple site once WordPress.com's Simple screen is in. The flag stays as an
off switch: per site from Tools > Feature Flags (a8c), or for every site by
setting the default back.

Tests that checked the tab stays out with the flag off now turn it off
themselves instead of relying on the default, and the tab tests register
the flag again, since the feature flags tests reset the registry.
@rcrdortiz rcrdortiz changed the title Plugins: let the Marketplace tab work on the Simple site Add Plugins screen Plugins: turn the Marketplace tab on, and let it work on the Simple site Add Plugins screen Oct 13, 2026
The four entries described parts of one change: the tab going live on every site, Simple included.
@rcrdortiz
rcrdortiz merged commit 0c737b9 into trunk Oct 13, 2026
77 checks passed
@rcrdortiz
rcrdortiz deleted the dotpar-19-simple-personal-premium-and-business-overtake-the-core branch October 13, 2026 15:05
@rcrdortiz rcrdortiz self-assigned this Oct 13, 2026
@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 Oct 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

[mu wpcom Feature] Wpcom Plugins [Package] Jetpack mu wpcom WordPress.com Features [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.

1 participant