[wp-trac] [WordPress Trac] #63549: Twenty Twenty-One: Line-height inconsistency in List Item blocks between editor and frontend (was: Twenty Twenty-One: Line-height inconsistency in List Item blocks between editor and frontend due to reset styles – follow-up to #60196)
WordPress Trac
noreply at wordpress.org
Mon Jun 9 21:18:37 UTC 2025
#63549: Twenty Twenty-One: Line-height inconsistency in List Item blocks between
editor and frontend
---------------------------+---------------------
Reporter: rishabhwp | Owner: (none)
Type: defect (bug) | Status: new
Priority: normal | Milestone: 6.9
Component: Bundled Theme | Version: 6.4
Severity: normal | Resolution:
Keywords: has-patch | Focuses: css
---------------------------+---------------------
Changes (by sabernhardt):
* version: => 6.4
* milestone: Awaiting Review => 6.9
Old description:
> This ticket is a follow-up to
> [#60196](https://core.trac.wordpress.org/ticket/60196), which fixed
> margin differences between the editor and frontend. However, there's
> still a noticeable spacing issue due to a mismatch in `line-height`.
>
> As mentioned in the comment
> (https://core.trac.wordpress.org/ticket/60196#comment:10), the editor
> sets `line-height` on the `<html>` tag, while the iframe used in the
> editor applies `line-height: normal` on the `<body>`. This causes the
> text spacing in the editor to look slightly different from the frontend.
>
> === Backend Editor
> [[Image(https://i.postimg.cc/k5j8rX9J/backend.png)]]
>
> === Frontend
> [[Image(https://i.postimg.cc/50TC076D/frontend.png)]]
New description:
This ticket is a follow-up to #60196, which fixed margin differences
between the editor and frontend. However, there's still a noticeable
spacing issue due to a mismatch in `line-height`.
As mentioned in comment:10:ticket:60196, the editor sets `line-height` on
the `<html>` tag, while the iframe used in the editor applies `line-
height: normal` on the `<body>`. This causes the text spacing in the
editor to look slightly different from the frontend.
=== Backend Editor
[[Image(https://i.postimg.cc/k5j8rX9J/backend.png)]]
=== Frontend
[[Image(https://i.postimg.cc/50TC076D/frontend.png)]]
--
Comment:
Thanks for creating the ticket and a patch!
Version: 6.4 stopped converting `html` and `body` selectors to `.editor-
styles-wrapper` in the printed style tag.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/63549#comment:2>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list