Skip to content

Conversation

@miguelpeixe
Copy link
Member

@miguelpeixe miguelpeixe commented Nov 14, 2025

All Submissions:

Changes proposed in this Pull Request:

NPPD-959

The subscription tier modal is currently restricting the purchase of any subscription that the reader already owns. This PR changes that behavior to check if the subscription is limited.

The warning notice should still render if not limited.

Limited Not Limited
image image

The subscription limit will also be automatically applied in the context of a grouped product.

How to test the changes in this Pull Request:

  1. If you don't have one, create a variable subscription product without any purchase limit
  2. Add this product a grouped product with another subscription product
  3. Add a Checkout Button block to a page targeting the product (allow readers to select the variation) and the grouped product
  4. As a reader, purchase the product
  5. Click the checkout button to purchase the product again, and confirm that you are presented with a warning notice, but can move forward
  6. Click the grouped product checkout button and confirm the behavior is the same
  7. Edit the product to limit the purchase:
image
  1. As the reader, start the checkout flow and confirm that you get the same warning, but now with a button to view your active subscription
  2. Do the same with the grouped product checkout button and confirm the behavior is the same

Other information:

  • Have you added an explanation of what your changes do and why you'd like us to include them?
  • Have you written new tests for your changes, as applicable?
  • Have you successfully ran tests with your changes locally?

@miguelpeixe miguelpeixe changed the title fix(subscription-modal): limiter and giftable handling fix(subscription-modal): limited subscriptions Nov 24, 2025
@miguelpeixe miguelpeixe self-assigned this Nov 24, 2025
@miguelpeixe miguelpeixe marked this pull request as ready for review November 24, 2025 18:46
@miguelpeixe miguelpeixe requested a review from a team as a code owner November 24, 2025 18:46
@miguelpeixe miguelpeixe added the [Status] Needs Review The issue or pull request needs to be reviewed label Nov 24, 2025
Copy link
Contributor

@dkoo dkoo left a comment

Choose a reason for hiding this comment

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

This is working! Maybe we should also align the "subscription limit" message in the Blocks repo with same message and link to view/manage the subscription? This message is the one shown when the Checkout Button block is tied directly to a limited variation or simple product.

Screenshot 2025-11-25 at 11 13 57 AM

@github-actions github-actions bot added [Status] Approved The pull request has been reviewed and is ready to merge and removed [Status] Needs Review The issue or pull request needs to be reviewed labels Nov 25, 2025
@miguelpeixe
Copy link
Member Author

Good call! I'll set a PR up soon

Thanks for the review

@miguelpeixe miguelpeixe merged commit 715f3c9 into trunk Nov 25, 2025
9 checks passed
@miguelpeixe miguelpeixe deleted the fix/subscription-tier-modal-purchasable-gift branch November 25, 2025 20:51
@github-actions
Copy link

Hey @miguelpeixe, good job getting this PR merged! 🎉

Now, the needs-changelog label has been added to it.

Please check if this PR needs to be included in the "Upcoming Changes" and "Release Notes" doc. If it doesn't, simply remove the label.

If it does, please add an entry to our shared document, with screenshots and testing instructions if applicable, then remove the label.

Thank you! ❤️

matticbot pushed a commit that referenced this pull request Nov 27, 2025
# [6.26.0-alpha.1](v6.25.1...v6.26.0-alpha.1) (2025-11-27)

### Bug Fixes

* **content-gifting:** ux tweaks and other fixes ([#4318](#4318)) ([952dd83](952dd83))
* **contrib-meter:** ensure percentage follows bar progress when using linear style ([#4320](#4320)) ([cbe8665](cbe8665))
* hide Content Gate CPT from WP Admin menu ([#4321](#4321)) ([70bbe7e](70bbe7e))
* make some Collections spacing more specific to archive pages ([#4293](#4293)) ([21daeaf](21daeaf))
* **media:** move default image UI to Advanced Settings ([#4296](#4296)) ([a22f06d](a22f06d))
* **modal-checkout:** prevent session reload after new customer account ([#4310](#4310)) ([89208fc](89208fc))
* **my-account:** add payment method query var ([#4325](#4325)) ([a7f2cb1](a7f2cb1))
* **my-account:** select font size ([#4324](#4324)) ([31a48c0](31a48c0))
* repeat button block styles in collections for WP 6.9 ([#4319](#4319)) ([6e3c5f8](6e3c5f8))
* **subscription-modal:** limited subscriptions ([#4309](#4309)) ([715f3c9](715f3c9))

### Features

* add autocomplete + token + multiselect component ([#4289](#4289)) ([84a8eda](84a8eda))
* **content-gifting:** custom article link expiration ([#4313](#4313)) ([c00f054](c00f054))
* listen to gforms events for newsletters ([#4312](#4312)) ([2f0e0e3](2f0e0e3))
* **my-account:** add "Product" column to the Subscriptions page ([#4323](#4323)) ([ba91e4c](ba91e4c))
@matticbot
Copy link
Contributor

🎉 This PR is included in version 6.26.0-alpha.1 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

matticbot pushed a commit that referenced this pull request Dec 2, 2025
# [6.27.0-alpha.1](v6.26.0...v6.27.0-alpha.1) (2025-12-02)

### Bug Fixes

* **content-gifting:** ux tweaks and other fixes ([#4318](#4318)) ([952dd83](952dd83))
* **contrib-meter:** ensure percentage follows bar progress when using linear style ([#4320](#4320)) ([cbe8665](cbe8665))
* hide Content Gate CPT from WP Admin menu ([#4321](#4321)) ([70bbe7e](70bbe7e))
* make some Collections spacing more specific to archive pages ([#4293](#4293)) ([21daeaf](21daeaf))
* **media:** move default image UI to Advanced Settings ([#4296](#4296)) ([a22f06d](a22f06d))
* **modal-checkout:** prevent session reload after new customer account ([#4310](#4310)) ([89208fc](89208fc))
* **my-account:** add payment method query var ([#4325](#4325)) ([a7f2cb1](a7f2cb1))
* **my-account:** select font size ([#4324](#4324)) ([31a48c0](31a48c0))
* repeat button block styles in collections for WP 6.9 ([#4319](#4319)) ([6e3c5f8](6e3c5f8))
* **subscription-modal:** limited subscriptions ([#4309](#4309)) ([715f3c9](715f3c9))

### Features

* add autocomplete + token + multiselect component ([#4289](#4289)) ([84a8eda](84a8eda))
* **content-gifting:** custom article link expiration ([#4313](#4313)) ([c00f054](c00f054))
* listen to gforms events for newsletters ([#4312](#4312)) ([2f0e0e3](2f0e0e3))
* **my-account:** add "Product" column to the Subscriptions page ([#4323](#4323)) ([ba91e4c](ba91e4c))
@matticbot
Copy link
Contributor

🎉 This PR is included in version 6.27.0-alpha.1 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

matticbot pushed a commit that referenced this pull request Dec 8, 2025
# [6.27.0](v6.26.4...v6.27.0) (2025-12-08)

### Bug Fixes

* **content-gifting:** ux tweaks and other fixes ([#4318](#4318)) ([952dd83](952dd83))
* **contrib-meter:** ensure percentage follows bar progress when using linear style ([#4320](#4320)) ([cbe8665](cbe8665))
* hide Content Gate CPT from WP Admin menu ([#4321](#4321)) ([70bbe7e](70bbe7e))
* make some Collections spacing more specific to archive pages ([#4293](#4293)) ([21daeaf](21daeaf))
* **media:** move default image UI to Advanced Settings ([#4296](#4296)) ([a22f06d](a22f06d))
* **modal-checkout:** prevent session reload after new customer account ([#4310](#4310)) ([89208fc](89208fc))
* **my-account:** add payment method query var ([#4325](#4325)) ([a7f2cb1](a7f2cb1))
* **my-account:** select font size ([#4324](#4324)) ([31a48c0](31a48c0))
* repeat button block styles in collections for WP 6.9 ([#4319](#4319)) ([6e3c5f8](6e3c5f8))
* **subscription-modal:** limited subscriptions ([#4309](#4309)) ([715f3c9](715f3c9))

### Features

* add autocomplete + token + multiselect component ([#4289](#4289)) ([84a8eda](84a8eda))
* **content-gifting:** custom article link expiration ([#4313](#4313)) ([c00f054](c00f054))
* listen to gforms events for newsletters ([#4312](#4312)) ([2f0e0e3](2f0e0e3))
* **my-account:** add "Product" column to the Subscriptions page ([#4323](#4323)) ([ba91e4c](ba91e4c))
@matticbot
Copy link
Contributor

🎉 This PR is included in version 6.27.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

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

Labels

released on @alpha released [Status] Approved The pull request has been reviewed and is ready to merge

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants