[wp-trac] [WordPress Trac] #35206: Allow theme authors to control white space between menu items

WordPress Trac noreply at wordpress.org
Tue Sep 6 09:05:48 UTC 2016


#35206: Allow theme authors to control white space between menu items
--------------------------------------+----------------------------
 Reporter:  peterwilsoncc             |       Owner:  peterwilsoncc
     Type:  enhancement               |      Status:  closed
 Priority:  normal                    |   Milestone:  4.7
Component:  Menus                     |     Version:
 Severity:  normal                    |  Resolution:  fixed
 Keywords:  has-unit-tests has-patch  |     Focuses:  template
--------------------------------------+----------------------------
Changes (by peterwilsoncc):

 * status:  assigned => closed
 * resolution:   => fixed


Comment:

 In [changeset:"38523"]:
 {{{
 #!CommitTicketReference repository="" revision="38523"
 Menus: Add white space option to `wp_nav_menu()` and `wp_list_pages()`.

 Adds an `item_spacing` option to the arguments array for the functions
 `wp_nav_menu()`, `wp_list_pages()`, and `wp_page_menu()`. `item_spacing`
 is a boolean accepting either `preserve` or `discard`.

 Previously, certain CSS choices could result in a site's layout changing
 if `wp_nav_menu()` fell back to the default `wp_list_pages()` due to
 differences in the whitespace within the HTML. The new argument ensures a
 function outputs consistant HTML while maintaining backward compatibility.

 Fixes #35206.
 }}}

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


More information about the wp-trac mailing list