Skip to content

Update Edit homepage banner design and copy #43643

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

Open
wants to merge 8 commits into
base: trunk
Choose a base branch
from

Conversation

xavier-lc
Copy link
Contributor

@xavier-lc xavier-lc commented May 27, 2025

Fixes DSGCOM-91

Proposed changes:

  • Update the banner shown on Pages so users know how to edit their homepage.

Other information:

  • Have you written new tests for your changes, if applicable?
  • Have you checked the E2E test CI results, and verified that your changes do not break them?
  • Have you tested your changes on WordPress.com, if applicable (if so, you'll see a generated comment below with a script to run)?

Jetpack product discussion

Does this pull request change what data or activity we track or use?

Testing instructions:

  • Activate this branch on your sandbox
  • Sandbox widgets.wp.com s0.wp.com s1.wp.com s2.wp.com s3.wp.com
  • On wp-admin, go to Pages
  • Check that you see thew banner
  • Check that clicking on the Edit homepage button takes you to the Site Editor
Before After
image image

@xavier-lc xavier-lc self-assigned this May 27, 2025
Copy link
Contributor

github-actions bot commented May 27, 2025

Are you an Automattician? Please test your changes on all WordPress.com environments to help mitigate accidental explosions.

  • To test on WoA, go to the Plugins menu on a WoA dev site. Click on the "Upload" button and follow the upgrade flow to be able to upload, install, and activate the Jetpack Beta plugin. Once the plugin is active, go to Jetpack > Jetpack Beta, select your plugin (WordPress.com Site Helper), and enable the update/edit-homepage-banner branch.
  • To test on Simple, run the following command on your sandbox:
bin/jetpack-downloader test jetpack-mu-wpcom-plugin update/edit-homepage-banner

Interested in more tips and information?

  • In your local development environment, use the jetpack rsync command to sync your changes to a WoA dev blog.
  • Read more about our development workflow here: PCYsg-eg0-p2
  • Figure out when your changes will be shipped to customers here: PCYsg-eg5-p2

Copy link
Contributor

Thank you for your PR!

When contributing to Jetpack, we have a few suggestions that can help us test and review your patch:

  • ✅ Include a description of your PR changes.
  • 🔴 Add a "[Status]" label (In Progress, Needs Review, ...).
  • 🔴 Add a "[Type]" label (Bug, Enhancement, Janitorial, Task).
  • ✅ Add testing instructions.
  • ✅ Specify whether this PR includes any changes to data or privacy.
  • ✅ Add changelog entries to affected projects

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 🤖


Follow this PR Review Process:

  1. Ensure all required checks appearing at the bottom of this PR are passing.
  2. Make sure to test your changes on all platforms that it applies to. You're responsible for the quality of the code you ship.
  3. You can use GitHub's Reviewers functionality to request a review.
  4. When it's reviewed and merged, you will be pinged in Slack to deploy the changes to WordPress.com simple once the build is done.

If you have questions about anything, reach out in #jetpack-developers for guidance!

@github-actions github-actions bot added the [Status] Needs Author Reply We need more details from you. This label will be auto-added until the PR meets all requirements. label May 27, 2025
Copy link

jp-launch-control bot commented May 27, 2025

Code Coverage Summary

Coverage changed in 1 file.

File Coverage Δ% Δ Uncovered
projects/packages/jetpack-mu-wpcom/src/features/pages/pages-homepage-connection-banner.php 0/46 (0.00%) 0.00% 7 💔

Full summary · PHP report

If appropriate, add one of these labels to override the failing coverage check: Covered by non-unit tests Use to ignore the Code coverage requirement check when E2Es or other non-unit tests cover the code Coverage tests to be added later Use to ignore the Code coverage requirement check when tests will be added in a follow-up PR I don't care about code coverage for this PR Use this label to ignore the check for insufficient code coveage.

@xavier-lc xavier-lc requested a review from a team May 28, 2025 11:00
@jasmussen
Copy link
Member

Looks good at a glance, but is there any way you can use the component, rather than reimplementing it?

Also, is it possible to show in the Site editor pages list too?
2025-05-28 13 24 37 localhost 0592850fc6b0

@@ -8,6 +8,21 @@

/* global jQuery */
( function ( $ ) {
const trackEvent = ( eventName, eventProperties = {} ) => {
Copy link
Contributor

Choose a reason for hiding this comment

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

We have a function for this here: https://github.com/Automattic/jetpack/blob/45f8c2f30d6464e5bee9a2930ee97481fcc40616/projects/packages/jetpack-mu-wpcom/src/common/tracks.js

Do you think it's possible to re-use it in this context?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I managed to get it working with modules, see f6b39d7

@xavier-lc
Copy link
Contributor Author

xavier-lc commented May 28, 2025

Looks good at a glance, but is there any way you can use the component, rather than reimplementing it?

I don't know if it's possible to share a calypso component with jetpack?

Also, is it possible to show in the Site editor pages list too?

I crafted a hacky solution on c99f84b. I don't know if there's a more proper solution for reacting to gutenberg's navigation.

cc @jasmussen

Copy link
Member

jasmussen commented May 29, 2025

I think we should avoid the hacks, for the same reason as avoiding custom CSS. We want to reduce maintenance overhead and use the off the shelf componentry. I should've been clearer, though, what I meant about using a "vanilla notice" as I mentioned in another comment, was use the default WordPress notice, this one: https://developer.wordpress.org/block-editor/reference-guides/components/notice/ (or this)

@xavier-lc
Copy link
Contributor Author

I think we should avoid the hacks, for the same reason as avoiding custom CSS.

Sure, I understand. In any case, I think it's better to put this on hold until the notice design question is solved in the linear issue.

Copy link
Member

What is the notice design question? I don't agree on putting this on hold, and think you can use the existing notice in WordPress.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[mu wpcom Feature] Pages [Package] Jetpack mu wpcom WordPress.com Features [Status] Needs Author Reply We need more details from you. This label will be auto-added until the PR meets all requirements.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants