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

Seller experience: Make options requirement aware of current site plan #60711

Merged

Conversation

nelsonec87
Copy link
Contributor

@nelsonec87 nelsonec87 commented Feb 1, 2022

Changes proposed in this Pull Request

  • Changed the simple path requirement (it's not free)
  • Show a different message when the current site already fulfils the requirement.

Testing instructions

  • Access start/setup-site/intent?siteSlug=<SITE SLUG>&flags=seller-experience (which enables the seller-experience feature flag)

  • Click the "Start Selling" button

  • Click "Continue"

  • Check the new view

  • With Free plan:
    image

  • Paid Plan:
    image

  • Business or eCommerce plans:
    image

  • The link should take you to the plans page.

Fixes #60710

@nelsonec87 nelsonec87 added the [Feature Group] Customer Seller Experience The customer experience when purchasing services or products. label Feb 1, 2022
@nelsonec87 nelsonec87 requested a review from a team February 1, 2022 16:38
@nelsonec87 nelsonec87 self-assigned this Feb 1, 2022
@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 Feb 1, 2022
@matticbot
Copy link
Contributor

matticbot commented Feb 1, 2022

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

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

name                                    parsed_size           gzip_size
async-load-signup-steps-store-features       +342 B  (+0.4%)     +123 B  (+0.5%)

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.

@kwight
Copy link
Contributor

kwight commented Feb 1, 2022

Let's also handle the case when users have already paid for a plan – any paid plan for simple, the business plan for Woo: #60710 (comment)

@nelsonec87 nelsonec87 changed the title Seller experience: Fixed requirement for using Playment block Seller experience: Make options requirement aware of current site plan Feb 2, 2022
@nelsonec87
Copy link
Contributor Author

I've used a ternary operator inside the component markup because the logic is simple and it seems easy to read.
Does anyone feel differently about it?

{ isPaidPlan
	? translate( 'Included in your plan' )
	: translate( 'Requires a {{a}}paid plan{{/a}}', {
			components: {
				a: <a href={ `/plans/${ siteSlug }` } />,
			},
	} ) }

@kwight
Copy link
Contributor

kwight commented Feb 2, 2022

I've used a ternary operator inside the component markup because the logic is simple and it seems easy to read.

Sure, looks good. 👍

Copy link
Contributor

@kwight kwight left a comment

Choose a reason for hiding this comment

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

Tests Great! I tried three sites: free, Premium, and Business, and got the variations I expected. ✨

Just tidy up the chaining and sort the failed test, then 🚢

@nelsonec87 nelsonec87 merged commit 37ebdac into trunk Feb 2, 2022
@nelsonec87 nelsonec87 deleted the fix/seller-experience-requirement-for-simple-option branch February 2, 2022 20:49
@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 Feb 2, 2022
@a8ci18n
Copy link

a8ci18n commented Feb 2, 2022

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

Thank you @nelsonec87 for including a screenshot in the description! This is really helpful for our translators.

@a8ci18n
Copy link

a8ci18n commented Feb 11, 2022

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

Thank you @nelsonec87 for including a screenshot in the description! This is really helpful for our translators.

@a8ci18n
Copy link

a8ci18n commented Feb 25, 2022

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
[Feature Group] Customer Seller Experience The customer experience when purchasing services or products.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Seller Experience: The simple path is not free.
4 participants