Skip to content

Fix: theme showcase "More" menu renders on the wrong side (DOTTHEM-370)#111661

Open
devNigel wants to merge 1 commit into
trunkfrom
fix/dotthem-370-more-menu-wrong-side
Open

Fix: theme showcase "More" menu renders on the wrong side (DOTTHEM-370)#111661
devNigel wants to merge 1 commit into
trunkfrom
fix/dotthem-370-more-menu-wrong-side

Conversation

@devNigel

@devNigel devNigel commented Jun 13, 2026

Copy link
Copy Markdown

Fixes DOTTHEM-370

Proposed Changes

  • Remove popoverProps={ { className: classes } } from the "More" overflow Dropdown in ResponsiveToolbarGroup's DropdownGroup.

Why are these changes being made?

On the logged-in theme showcase, clicking More in the category filter opened the hidden-categories menu on the opposite side of the screen from the button.

The menu is a @wordpress/components Dropdown/Popover. The popoverProps className applied the toolbar container classes (responsive-toolbar-group__dropdown etc.) directly onto the floating popover, which made it lay out at the full container width (~1440px in a 1800px viewport) instead of sizing to its menu content. A full-width popover with the default bottom-start placement overflows the viewport to the right, so floating-ui's shift middleware slides it all the way across to keep it on screen — landing it on the far side, away from the toggle.

Dropping that className lets the popover size to its content and anchor correctly under the More button. The popover renders inside the toolbar container (its offset parent is the container), so the existing menu-item styling continues to apply through descendant selectors — no theming is lost.

This className was introduced in #110552; this change effectively reverts that one line, which was the regression source.

Testing Instructions

  1. Log in and open the theme showcase (/themes or /themes/sitename.wordpress.com )
  2. Narrow the browser window until the category row overflows and a More button appears at the end.
  3. Click More.
  4. Before: the menu appears on the opposite side of the screen. After: the menu opens directly under the More button, sized to its content.

Verified live on a local Calypso dev server (logged-in showcase, 1800px viewport): the popover width dropped from ~1439px to its content width and it now renders under the toggle.

Reviewer input requested: please confirm in dark mode and on a site-specific showcase. Reasoning suggests theming is unaffected (popover stays inside the themed container), but I verified light mode only.

Screenshots

Before:

image

After:

image

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?
  • For UI changes, have you tested the affected components in dark mode?
  • Have you tested accessibility for your changes? (Keyboard/popover behaviour is unchanged; only the popover's width/placement is affected.)

Note: Opening this PR auto-flips DOTTHEM-370 to "In Progress" in Linear. This is a Bug Blitz contribution that is review-ready, not actively being worked by the owning team.

The "More" overflow menu in ResponsiveToolbarGroup opened on the
opposite side of the screen from its toggle button on the logged-in
theme showcase.

The popover was given the toolbar container's classes via
popoverProps, which made it lay out at the full container width.
A full-width popover with bottom-start placement overflows the
viewport, so floating-ui's shift middleware slid it across to the
far side. Dropping that className lets the popover size to its
content and anchor under the "More" button. The popover renders
inside the toolbar container, so menu-item theming still applies
through descendant selectors.

Fixes DOTTHEM-370

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@matticbot

Copy link
Copy Markdown
Contributor

This PR modifies the release build for the following Calypso Apps:

For info about this notification, see here: PCYsg-OT6-p2

  • help-center
  • notifications

To test WordPress.com changes, run install-plugin.sh $pluginSlug fix/dotthem-370-more-menu-wrong-side on your sandbox.

@devNigel devNigel marked this pull request as ready for review June 13, 2026 10:26
@devNigel devNigel requested a review from andrea-sdl June 13, 2026 10:28
@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 Jun 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

[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.

2 participants