wp-calypso icon indicating copy to clipboard operation
wp-calypso copied to clipboard

Use wp-admin Blaze link for Classic sites

Open DustyReagan opened this issue 1 year ago • 2 comments

Related to https://github.com/Automattic/dotcom-forge/issues/5724

[!WARNING]
https://github.com/Automattic/jetpack/pull/35724 needs to roll out before this PR is merged so the wp-admin Blaze link will work.

[!WARNING]
https://github.com/Automattic/jetpack/pull/35724 puts the wp-admin/tools.php?page=advertising page behind a proxy check. This PR places the update links behind the layout/dotcom-nav-redesign feature flag. This means for rollout, the proxy needs to be removed first before the feature flag is enabled. Otherwise, these links will point to a broken page.

Proposed Changes

  • Dynamically set the links to Blaze so that Classic admin sites are linked to wp-admin Blaze page and "Default" admin sites are linked to the Calypso Blaze page.

There are 3 link updates in this PR

  • "View advertising campaigns" in https://wpcalypso.wordpress.com/purchases/subscriptions/[site_slug]
  • "Create campaign" in the promo card on https://wpcalypso.wordpress.com/home/[site_slug]
  • "Promote with Blaze" in the "Quick links" on https://wpcalypso.wordpress.com/home/[site_slug]
Screenshot 2024-02-22 at 11 45 43 AM Screenshot 2024-02-22 at 11 44 58 AM

Testing Instructions

  • With this PR loaded
  • Click the links above on a Classic admin style site. They should link to wp-admin Blaze.
  • Click the links above on a Default admin style site. They should link to Calypso Blaze.

Pre-merge Checklist

  • [ ] Has the general commit checklist been followed? (PCYsg-hS-p2)
  • [ ] https://wpcalypso.wordpress.com/devdocs/docs/testing/index.md 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)?

DustyReagan avatar Feb 22 '24 17:02 DustyReagan

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

Sections (~305 bytes added 📈 [gzipped])

name            parsed_size           gzip_size
site-purchases       +680 B  (+0.0%)     +140 B  (+0.0%)
home                 +659 B  (+0.0%)     +165 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.

matticbot avatar Feb 22 '24 17:02 matticbot

https://github.com/Automattic/jetpack/pull/35724 needs to roll out before this PR is merged so the wp-admin Blaze link will work.

This has been deployed to Atomic sites. I'm merging this PR!

fushar avatar Feb 29 '24 03:02 fushar