[wp-trac] [WordPress Trac] #60338: WordPress / twentytwentyfour | Using the list block seems to affect the submenu layout negatively

WordPress Trac noreply at wordpress.org
Wed Jan 24 18:04:41 UTC 2024


#60338: WordPress / twentytwentyfour | Using the list block seems to affect the
submenu layout negatively
--------------------------+------------------------
 Reporter:  wilhelm1973   |       Owner:  (none)
     Type:  defect (bug)  |      Status:  closed
 Priority:  normal        |   Milestone:
Component:  Editor        |     Version:  6.4.2
 Severity:  normal        |  Resolution:  duplicate
 Keywords:                |     Focuses:
--------------------------+------------------------
Changes (by sabernhardt):

 * status:  new => closed
 * resolution:   => duplicate
 * component:  Bundled Theme => Editor
 * milestone:  Awaiting Review =>


Comment:

 The padding issue was reported in #58071. I thought it was the same as
 GB36586, or close enough, but maybe this needs its own Gutenberg issue.

 Anyway, this is not a bug in individual themes; it also happens with
 Twenty Twenty-Two. When block styles are printed separately, the
 [https://github.com/WordPress/gutenberg/blob/015d8b5b6c344938ed2d89375388b3a64ff9a661/packages
 /block-library/src/list/style.scss#L5-L7 List block styles] can be placed
 after the Navigation styles. The `ul.has-background` padding has the same
 specificity as the `.wp-block-navigation ul` padding reset, so it needs to
 be printed earlier.

 When block styles are together, the order is correct:
 {{{
 add_filter( 'should_load_separate_core_block_assets', '__return_false', 11
 );
 }}}

 In your own site, however, you may prefer setting the padding to zero in
 Additional CSS or the Global styles:
 {{{
 ul.wp-block-navigation__submenu-container {
   padding: 0;
 }
 }}}

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


More information about the wp-trac mailing list