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

Delayed layout shift in wp-admin when upsell banner is injected

Open jeremyfelt opened this issue 1 year ago • 3 comments

Quick summary

👋🏻 There have been a few times recently when I've needed to repetitively shift between the front-end and admin views while testing some workflows.

On the front-end of the site, I'll hover over the site name, click dashboard, and then immediately move my mouse to where I see the "Posts" menu item and click.

But! That click happens milliseconds after a "Free domain available" upsell banner is injected into the menu. The entire navigation shifts down by 56px and I end up in the WordPress.com stats viewer instead of the list of posts.

The site is in development, so I can't show a video of the full front/back end, but here's a clip of the relevant section:

CleanShot 2024-02-15 at 10 02 44 2

Every time I refresh the page, it starts without the upsell banner and then shifts to include it.

Steps to reproduce

  1. Start on https://example.org
  2. Navigate to https://example.org/wp-admin/
  3. Try to click on Posts

What you expected to happen

Ideally, the upsell banner is placed in a way that does not cause layout shift.

Or maybe: I have a way to enable developer mode where I'm not shown upsells while working on others' sites.

What actually happened

The navigation layout shifted.

Impact

One

Available workarounds?

No but the platform is still usable

Platform (Simple and/or Atomic)

No response

Logs or notes

I'm using Firefox 122.0.1 on macOS 12.7.2

jeremyfelt avatar Feb 15 '24 18:02 jeremyfelt

📌 REPRODUCTION RESULTS

  • Tested on Atomic – Replicated

📌 FINDINGS/SCREENSHOTS/VIDEO the sidebar shifts when the free domain credit upsell banner shows up:

https://github.com/Automattic/wp-calypso/assets/14153300/0a8be08d-3dd9-4cef-b110-f9c31e86a943

📌 ACTIONS

  • Triaged

cc @mrfoxtalbot as this could be a low-hanging fruit to raise with folks working on nav redesign.

liviopv avatar Feb 21 '24 16:02 liviopv

If I understand correctly, we are going to do away with the entire unified navigation. Moreover, we're not sure if we're keeping this upsell notice (or where; it'll go).

Could you confirm this, @davemart-in? Thanks!

mrfoxtalbot avatar Feb 22 '24 15:02 mrfoxtalbot

we are going to do away with the entire unified navigation

That is not my understanding at all. :-) Let's sync on this to make sure we're on the same page.

davemart-in avatar Feb 22 '24 15:02 davemart-in