[wp-trac] [WordPress Trac] #63549: Twenty Twenty-One: Line-height inconsistency in List Item blocks between editor and frontend

WordPress Trac noreply at wordpress.org
Sun Jun 22 17:20:45 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 has-test-info  |     Focuses:  css
-------------------------------------+---------------------
Changes (by sabernhardt):

 * keywords:  has-patch changes-requested has-test-info => has-patch has-
     test-info


Comment:

 If a ruleset like the margin `revert` in 63549.patch is appropriate for
 all themes, but at zero specificity, that would belong in the Gutenberg
 styles (not the TinyMCE stylesheet). See
 [https://github.com/WordPress/gutenberg/issues/42526 GB42526].

 For this ticket, 8940.diff correctly applies the theme's `line-height` to
 List and Navigation blocks in the editor. If you want to see the List
 blocks match the front-end spacing within the editor, apply **both**
 8940.diff and 8895.diff (or wait until one of them is committed).

 If I had made a patch for this ticket, I would have grouped both the
 `font-family` and `line-height` in one ruleset for `html` and `body`, but
 I am not entirely convinced my way is better than PR 8940.
 {{{
 html,
 body {
         font-family: var(--global--font-secondary);
         line-height: var(--global--line-height-body);
 }

 body {
         --wp--typography--line-height: var(--global--line-height-body);
         color: var(--global--color-primary);
         background-color: var(--global--color-background);
         font-size: var(--global--font-size-base);
         font-weight: normal;
         -moz-osx-font-smoothing: grayscale;
         -webkit-font-smoothing: antialiased;
 }
 }}}

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/63549#comment:8>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list