-
Notifications
You must be signed in to change notification settings - Fork 799
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
AI Assistant: tier plans upgrade nudge update #34254
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 appearing at the bottom of this PR are passing or skipped. Jetpack plugin: The Jetpack plugin has different release cadences depending on the platform:
If you have any questions about the release process, please ask in the #jetpack-releases channel on Slack. |
projects/plugins/jetpack/extensions/blocks/ai-assistant/components/upgrade-prompt/index.tsx
Outdated
Show resolved
Hide resolved
Co-authored-by: Douglas Henri <dhasilva@users.noreply.github.com>
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.
LGTM
Adjust UpgradeNudge for tier plans usage
Fixes #33361
Proposed changes:
This PR adds the tier plans flag to conditionally compose UpgradeNudge component accordingly.
Other information:
Does this pull request change what data or activity we track or use?
No
Testing instructions:
Work against the sandbox, it's easier to mock situations. Checkout D126642-code (maybe rebase it locally on your sandbox to make sure it works). Follow instructions on the diff, make sure you sandbox the store and API as well.
Enable tier plans on both local and sandbox:
add_filter( 'jetpack_ai_tier_plans_enabled', '__return_true' );
Go to the editor. Dispatch the action to force the UpgradeNudge (see it both on the AI assistant prompt and in the excerpt (beta) inspector).
Change
nextTier.limit
to see the UpgradeNudge changes on the UI. If you have sandboxed properly, you should be able to checkout the suggested tier.Change
nextTier
tonull
to see the contact suggestion. See that the mailto link functions properly.If you disable the tier plans filter, you should be back at the regular usage of the nudge and checkouts.