Skip to content

Make layout compatible with wp7.0#4497

Merged
vytisbulkevicius merged 5 commits into
developmentfrom
bugfix/4496
May 19, 2026
Merged

Make layout compatible with wp7.0#4497
vytisbulkevicius merged 5 commits into
developmentfrom
bugfix/4496

Conversation

@girishpanchal30
Copy link
Copy Markdown
Contributor

Summary

Fixed the layout's style to make it compatible with WordPress 7.0.

Check before Pull Request is ready:

Closes #4496

@girishpanchal30 girishpanchal30 requested a review from Copilot May 12, 2026 12:28
@girishpanchal30 girishpanchal30 added the pr-checklist-skip Allow this Pull Request to skip checklist. label May 12, 2026
@pirate-bot pirate-bot added the pr-checklist-complete The Pull Request checklist is complete. (automatic label) label May 12, 2026
@pirate-bot
Copy link
Copy Markdown
Collaborator

pirate-bot commented May 12, 2026

Plugin build for f0b1660 is ready 🛎️!

Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Adds a WP 7.x compatibility stylesheet intended to fix small admin/customizer layout regressions introduced by WordPress 7 UI changes.

Changes:

  • Enqueue a new WP7-specific admin stylesheet from the Customizer loader on newer WP versions.
  • Add a new assets/scss/wp7.scss entry to the Grunt SASS build and CSS minification pipeline.
  • Introduce WP7 CSS overrides for sizing controls and core UI button/dashicon alignment.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 3 comments.

File Description
inc/customizer/loader.php Enqueues a new admin stylesheet conditionally based on WordPress version.
grunt/sass.js Adds compilation target for assets/scss/wp7.scssassets/css/wp7.css.
grunt/cssmin.js Adds minification target for assets/css/wp7.cssassets/css/wp7.min.css.
assets/scss/wp7.scss New WP7 compatibility CSS overrides affecting Neve controls and .wp-core-ui buttons.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread inc/customizer/loader.php Outdated
Comment thread inc/customizer/loader.php Outdated
Comment thread assets/scss/wp7.scss Outdated
Comment thread assets/scss/wp7.scss Outdated
Comment on lines +1 to +14
.neve-responsive-sizing button.link {
min-height: 40px;
}

.wp-core-ui .button .dashicons,
.wp-core-ui .button-primary .dashicons,
.wp-core-ui .button-secondary .dashicons {
line-height: 1;
}

.wp-core-ui .button-link,
.wp-core-ui .button.button-link {
border: none;
} No newline at end of file
Copy link
Copy Markdown
Contributor

@Soare-Robert-Daniel Soare-Robert-Daniel May 15, 2026

Choose a reason for hiding this comment

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

I am not sure about those changes since you are practically reverting the core styles of .wp-core-ui WP 7.0 at a general level.

I will suggest working with a targeted selector. @abaicus @HardeepAsrani, if you have some feedback about this.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

@Soare-Robert-Daniel, I have implemented as you suggested with the latest commit. Please check it and let me know if any changes are needed.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

The new selectors look nice. We still have a problem since this change is loaded as an extra file. I do not think I saw this before, and not sure if it is a good pattern.

The current CSS, I think, can go directly into the main CSS files

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

The current CSS, I think, can go directly into the main CSS files

For the button styles, we can go with what you suggested. However, the input field height has also been updated to 40px in WP 7.x. Because of that, the buttons in the Customizer for WP 6.x look like this:

image

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

That 40px is a good point. Another version that I am thinking will be to add a special class on the component based on the WP version and some CSS based on it, like some sort of versioning:
CleanShot 2026-05-15 at 17 47 20@2x

But a separate file might be simpler. @abaicus @HardeepAsrani, what do you think?

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

@girishpanchal30 It would be helpful if you could share a screenshot of the final version.

Copy link
Copy Markdown
Contributor Author

@girishpanchal30 girishpanchal30 May 19, 2026

Choose a reason for hiding this comment

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

Customizer link component looks like:
In 6.x:
image

In 7.x:
Screenshot from 2026-05-19 14-24-56

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

@girishpanchal30 the inputs should keep their height from 6.x, same should the button.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

@abaicus I have set the height for input and buttons to 30px (as per 6.x) with the latest commit. Please check it and let me know if any changes are needed.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Sounds good, it should be fine if it looks like it used to before 7.x

Thank you for the changes, @girishpanchal30 👍🏻

@vytisbulkevicius vytisbulkevicius merged commit c8c5974 into development May 19, 2026
15 checks passed
@vytisbulkevicius vytisbulkevicius deleted the bugfix/4496 branch May 19, 2026 13:20
@pirate-bot
Copy link
Copy Markdown
Collaborator

🎉 This PR is included in version 4.2.4 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

@pirate-bot pirate-bot added the released Indicate that an issue has been resolved and released in a particular version of the product. label May 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pr-checklist-complete The Pull Request checklist is complete. (automatic label) pr-checklist-skip Allow this Pull Request to skip checklist. released Indicate that an issue has been resolved and released in a particular version of the product.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants