Skip to content
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

Theme tooltips: sets specific messaging for ecommerce trial plans. #94812

Merged
merged 4 commits into from
Sep 24, 2024

Conversation

cpapazoglou
Copy link
Contributor

@cpapazoglou cpapazoglou commented Sep 23, 2024

Fixes #94748

Proposed Changes

  • Sets specific messaging for trial plan sites when hovering a community or partner theme

Community
This community theme cannot be installed in a trial plan site. Please upgrade your Commerce plan on your site.

Partner
This theme costs %(annualPrice)s per year or %(monthlyPrice)s per month, and cannot be purchased in a trial plan site. Please upgrade your Commerce plan on your site.

Testing Instructions

Commerce Trial Plan

  • Go to wordpress.com/ecommerce
  • Press Get Started and proceed all the way through the flow
  • Go to wordpress.com/themes/:siteSlug
  • Look for themes that require update and hover on "Upgrade and Subscribe". The tooltip should show ecommerce link leading to the checkout page with the ecommerce plan in the cart.
  • Search for "Construction Firm" in the theme filter field.
  • Check the "Upgrade" badge on community themes. The tooltip should show ecommerce link leading to the checkout page with the ecommerce plan in the cart.
  • Both tooltips should denote that the theme isn't available to trial plans.

On a plan lower than business

  • Look for themes that require update and hover on "Upgrade and Subscribe". The tooltip should show business link leading to the checkout page with the business plan in the cart.
  • Search for "Construction Firm" in the theme filter field.
  • Check the "Upgrade" badge on community themes. The tooltip should show business link leading to the checkout page with the business plan in the cart.

Pre-merge Checklist

  • Has the general commit checklist been followed? (PCYsg-hS-p2)
  • Have you written new tests for your changes?
  • Have you tested the feature in Simple (P9HQHe-k8-p2), Atomic (P9HQHe-jW-p2), and self-hosted Jetpack sites (PCYsg-g6b-p2)?
  • Have you checked for TypeScript, React or other console errors?
  • Have you used memoizing on expensive computations? More info in Memoizing with create-selector and Using memoizing selectors and Our Approach to Data
  • Have we added the "[Status] String Freeze" label as soon as any new strings were ready for translation (p4TIVU-5Jq-p2)?
  • For changes affecting Jetpack: Have we added the "[Status] Needs Privacy Updates" label if this pull request changes what data or activity we track or use (p4TIVU-aUh-p2)?

@cpapazoglou
Copy link
Contributor Author

@candy02058912 my approach here is to create different messaging depending on if the site is on trial plan or not, and explaining that those themes are not available in trial plans. What do you think?

@matticbot
Copy link
Contributor

matticbot commented Sep 23, 2024

Here is how your PR affects size of JS and CSS bundles shipped to the user's browser:

Sections (~240 bytes added 📈 [gzipped])

name    parsed_size           gzip_size
themes       +890 B  (+0.1%)     +115 B  (+0.0%)
theme        +890 B  (+0.1%)     +125 B  (+0.1%)

Sections contain code specific for a given set of routes. Is downloaded and parsed only when a particular route is navigated to.

Async-loaded Components (~115 bytes added 📈 [gzipped])

name                                     parsed_size           gzip_size
async-load-signup-steps-theme-selection       +890 B  (+0.2%)     +115 B  (+0.1%)
async-load-design-blocks                      +890 B  (+0.0%)     +115 B  (+0.0%)

React components that are loaded lazily, when a certain part of UI is displayed for the first time.

Legend

What is parsed and gzip size?

Parsed Size: Uncompressed size of the JS and CSS files. This much code needs to be parsed and stored in memory.
Gzip Size: Compressed size of the JS and CSS files. This much data needs to be downloaded over network.

Generated by performance advisor bot at iscalypsofastyet.com.

@matticbot
Copy link
Contributor

This PR modifies the release build for the following Calypso Apps:

For info about this notification, see here: PCYsg-OT6-p2

  • notifications
  • wpcom-block-editor

To test WordPress.com changes, run install-plugin.sh $pluginSlug fix/theme_trial_plan_tooltips on your sandbox.

@ivan-ottinger ivan-ottinger self-requested a review September 24, 2024 08:34
@matticbot matticbot added the [Status] Needs Review The PR is ready for review. This also triggers e2e canary tests and wp-desktop tests automatically. label Sep 24, 2024
Copy link
Contributor

@ivan-ottinger ivan-ottinger left a comment

Choose a reason for hiding this comment

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

Great work! The proposed changes look good and work as expected. The tooltip messages render correctly and the links lead to the checkout page with relevant plans added to the cart.

Partner theme Community theme
Screenshot 2024-09-24 at 11 17 49 Screenshot 2024-09-24 at 11 17 08

Tested with different plans and did not observe any regressions, errors nor warnings.

Approving the PR with two small thoughts:

  • I think we could ask designers for input / confirmation on the new copy.
  • The new translations won't be ready yet. → We could consider adding checks and only display new strings once their translation is ready. However, considering that the current copy in production is incorrect, I think we could skip this step and let the tooltips display in English until they get translated.

@fditrapani
Copy link
Contributor

Thanks for the ping @cpapazoglou. How about this for the copy instead:

Community
This theme can't be installed on a trial site. Please upgrade to the Commerce plan to install this theme.

Partner
This theme costs %(annualPrice)s per year or %(monthlyPrice)s per month, and can't be purchased on a trial site. Please upgrade to the Commerce plan to install this theme.

@cpapazoglou cpapazoglou merged commit 9791495 into trunk Sep 24, 2024
11 checks passed
@cpapazoglou cpapazoglou deleted the fix/theme_trial_plan_tooltips branch September 24, 2024 13:13
@github-actions github-actions bot removed the [Status] Needs Review The PR is ready for review. This also triggers e2e canary tests and wp-desktop tests automatically. label Sep 24, 2024
@a8ci18n
Copy link

a8ci18n commented Sep 24, 2024

This Pull Request is now available for translation here: https://translate.wordpress.com/deliverables/16880624

Some locales (Hebrew, Japanese) have been temporarily machine-translated due to translator availability. All other translations are usually ready within a few days. Untranslated and machine-translated strings will be sent for translation next Monday and are expected to be completed by the following Friday.

Hi @cpapazoglou, could you please edit the description of this PR and add a screenshot for our translators? Ideally it'd include all of the following strings:

  • This theme can't be installed on a trial site. Please upgrade to the <Link>%(ecommercePlanName)s plan</Link> to install this theme.
  • You have a subscription for this theme, but it isn't usable on a trial plan site. Please upgrade to the <link>%(ecommercePlanName)s plan</link> to install this theme.
  • This theme costs %(annualPrice)s per year or %(monthlyPrice)s per month, and can't be purchased on a trial site. Please upgrade to the <Link>%(ecommercePlanName)s plan</Link> to install this theme.

Thank you in advance!

@a8ci18n
Copy link

a8ci18n commented Sep 30, 2024

Translation for this Pull Request has now been finished.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Improve the /themes copy for Commerce Trial plans
5 participants