Multiple Themes: Fix Details (Accordion) Block #7517
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.
Changes proposed in this Pull Request:
Almost all Automattic themes use
normalize.css
to start its file. However, annoyingly, there was a bug innormalize.css
a few years ago which broke thesummary
element. This was fixed in 2016, but it looks like the themes have continued using an outdated version, meaning that lots of themes have been affected. You can learn more about that here: https://css-tricks.com/careful-when-changing-the-display-of-summary/This PR updates the styles of several themes with the corrected changes to
normalize.css
from 2016. This is admittedly a pain because it affects so many themes; I did consider a change in Core, and I might one file later, but the problem is that won't work for any accordions inserted with HTML, which is supported on WordPress.com. There's also no guarantee that Core would accept a fix for a bug caused by themes.As a result, we need to remove
display: block
fromsummary
to fix the Details block in Gutenberg, and also any accordions inserted with HTML.Before:
After:
Related issue(s):
Fixes #7041