Fix publish-box button layout on classic editor (WP 7.0+)#504
Open
enricobattocchi wants to merge 1 commit into
Open
Fix publish-box button layout on classic editor (WP 7.0+)#504enricobattocchi wants to merge 1 commit into
enricobattocchi wants to merge 1 commit into
Conversation
WordPress 7.0 changed #major-publishing-actions to display: flex with flex-wrap: nowrap, which placed "Copy to a new draft" and "Rewrite & Republish" on the same row as Move to Trash and Update, shrinking all four. Scope flex-wrap: wrap to that container only when our buttons are present (via :has()) and give each duplicate button flex-basis: 100% so it claims its own row. The properties are no-ops on WP 6.9 where the parent is not a flex container, keeping the previous layout intact there. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Member
Author
|
They are going probably to fix it on the WP side, so let's wait before moving that forward. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Context
#major-publishing-actionsa flex row, so our Copy / Rewrite links ended up squeezed onto the same row as Move to Trash and Update.Summary
This PR can be summarized in the following changelog entry:
Relevant technical choices:
:has()-scopedflex-wrap: wrapon the core container plusflex-basis: 100%on our two buttons. No-op on WP 6.9 (parent isn't flex), no version check needed.Test instructions
Test instructions for the acceptance test before the PR gets merged
Relevant test scenarios
Classic editor only; block editor sidebar untouched.
Test instructions for QA when the code is in the RC
QA can test this PR by following these steps:
Impact check
UI changes
Documentation
Quality assurance
Innovation
innovationlabel and noted the work hours.Fixes #