-
Notifications
You must be signed in to change notification settings - Fork 834
Payments: add a default scenario for our upgrade nudges #31986
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Are you an Automattician? Please test your changes on all WordPress.com environments to help mitigate accidental explosions.
Interested in more tips and information?
|
Thank you for your PR! When contributing to Jetpack, we have a few suggestions that can help us test and review your patch:
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 🤖 The e2e test report can be found here. Please note that it can take a few minutes after the e2e tests checks are complete for the report to be available. Once your PR is ready for review, check one last time that all required checks (other than "Required review") appearing at the bottom of this PR are passing or skipped. Jetpack plugin:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should the switch case statements be using break
here? If I'm using a donations
block for example, it currently falls through to the default for readMoreUrl
.
See #31986 (review) Co-authored-by: samiff <samiff@users.noreply.github.com>
Well yes that would help, wouldn't it? :) Done in 9ee7b91 |
I'm going to dismiss this review because the fix was implemented. Thanks for taking a look, Sami!
* Payments: add a default scenario for our upgrade nudges Fixes #31982 * Add missing break statements See Automattic/jetpack#31986 (review) Co-authored-by: samiff <samiff@users.noreply.github.com> --------- Co-authored-by: samiff <samiff@users.noreply.github.com> Committed via a GitHub action: https://github.com/Automattic/jetpack/actions/runs/5654131963
* Payments: add a default scenario for our upgrade nudges Fixes #31982 * Add missing break statements See Automattic/jetpack#31986 (review) Co-authored-by: samiff <samiff@users.noreply.github.com> --------- Co-authored-by: samiff <samiff@users.noreply.github.com> Committed via a GitHub action: https://github.com/Automattic/jetpack/actions/runs/5654131963
#31986) * Payments: add a default scenario for our upgrade nudges Fixes #31982 * Add missing break statements See #31986 (review) Co-authored-by: samiff <samiff@users.noreply.github.com> --------- Co-authored-by: samiff <samiff@users.noreply.github.com>
Fixes #31982
Proposed changes:
We currently have the following logic for the support doc link in the Stripe connection nudge banner:
For the Payments buttons:
For the Donations block:
For the Premium Content block as well as any other block (this ends up being the default):
That last, default behavior seems to be the problem here, because we have at least one other block name,
recurring-payments
, that is not handled here. This PR fixes that by setting up a default.Other information:
Jetpack product discussion
Does this pull request change what data or activity we track or use?
Testing instructions:
This can be tested on WordPress.com Simple and on self-hosted, on a site where you have not tested those blocks before and have not connected your site to a Stripe account. In that scenario: