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

A4A > WooPayments: Implement Overview page #101648

Open
wants to merge 1 commit into
base: trunk
Choose a base branch
from

Conversation

yashwin
Copy link
Contributor

@yashwin yashwin commented Mar 20, 2025

Resolves https://github.com/Automattic/automattic-for-agencies-dev/issues/1933

Proposed Changes

This PR implements:

  • Overview page for the WooPayments Commissions.
  • Empty state view for the Dashboard

Why are these changes being made?

  • To show the original empty state always because of the value it adds.

Testing Instructions

  • Open the A4A live link
  • Go to Licenses and delete all the WooPayments licenses assigned to a site
  • Go to WooPayments > Verify you are redirected to the Overview page, and the empty state looks fine by comparing it with staging.

screencapture-agencies-localhost-3000-woopayments-overview-2025-03-20-12_30_05

  • Click the Add WooPayments to site button on the Layout top-right corner or on the first section > Verify you are redirected to Dashboard and a modal is shown after you are redirected > Close the modal > Verify the Dashboard empty state is displayed as shown below. Verify the buttons and links work as expected.

screencapture-agencies-localhost-3000-woopayments-dashboard-2025-03-20-12_30_35

  • Click the Add WooPayments to site button > Select a site and add WooPayments to a site and install/activate the plugin > Go to Dashboard and verify the site is displayed.
  • Visit Overview and click the WooPayments menu > Verify you are now redirected to the Dashboard instead of the Overview page > Also verify that you can view the Overview page.

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 UI changes, have we tested the change in various languages (for example, ES, PT, FR, or DE)? The length of text and words vary significantly between languages.
  • 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)?

@yashwin yashwin requested review from madebynoam and a team March 20, 2025 08:41
@yashwin yashwin self-assigned this Mar 20, 2025
@matticbot matticbot added [Status] Needs Review The PR is ready for review. This also triggers e2e canary tests and wp-desktop tests automatically. labels Mar 20, 2025
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is mostly copied from the empty state component.

@matticbot
Copy link
Contributor

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

App Entrypoints (~15 bytes added 📈 [gzipped])

name        parsed_size           gzip_size
entry-main        +24 B  (+0.0%)      +15 B  (+0.0%)

Common code that is always downloaded and parsed every time the app is loaded, no matter which route is used.

Sections (~902 bytes added 📈 [gzipped])

name                                parsed_size           gzip_size
a8c-for-agencies-woopayments            +4087 B  (+0.4%)     +806 B  (+0.3%)
a8c-for-agencies-team                     +72 B  (+0.0%)      +21 B  (+0.0%)
a8c-for-agencies-referrals                +72 B  (+0.0%)      +25 B  (+0.0%)
a8c-for-agencies-partner-directory        +72 B  (+0.0%)      +19 B  (+0.0%)
a8c-for-agencies-migrations               +72 B  (+0.0%)      +24 B  (+0.0%)
a8c-for-agencies-sites                    +59 B  (+0.0%)      +14 B  (+0.0%)
a8c-for-agencies-settings                 +59 B  (+0.0%)      +14 B  (+0.0%)
a8c-for-agencies-purchases                +59 B  (+0.0%)      +14 B  (+0.0%)
a8c-for-agencies-plugins                  +59 B  (+0.0%)      +14 B  (+0.0%)
a8c-for-agencies-overview                 +59 B  (+0.0%)      +14 B  (+0.0%)
a8c-for-agencies-marketplace              +59 B  (+0.0%)      +14 B  (+0.0%)
a8c-for-agencies-client                   +59 B  (+0.0%)      +14 B  (+0.0%)
a8c-for-agencies-agency-tier              +59 B  (+0.0%)      +14 B  (+0.0%)
a8c-for-agencies                          +59 B  (+0.0%)      +14 B  (+0.0%)
scan                                      +29 B  (+0.0%)      +10 B  (+0.0%)
jetpack-social                            +29 B  (+0.0%)       +9 B  (+0.0%)
jetpack-search                            +29 B  (+0.0%)      +10 B  (+0.0%)
jetpack-cloud-agency-dashboard            +29 B  (+0.0%)       +8 B  (+0.0%)
backup                                    +29 B  (+0.0%)       +9 B  (+0.0%)
a8c-for-agencies-signup                   +29 B  (+0.0%)       +6 B  (+0.0%)
a8c-for-agencies-landing                  +29 B  (+0.0%)      +11 B  (+0.0%)

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

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.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A8c Agencies [Status] Needs Review The PR is ready for review. This also triggers e2e canary tests and wp-desktop tests automatically.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants