[wp-trac] [WordPress Trac] #35206: Allow theme authors to control white space between menu items
WordPress Trac
noreply at wordpress.org
Wed Dec 30 11:47:26 UTC 2015
#35206: Allow theme authors to control white space between menu items
------------------------------------------+------------------------------
Reporter: peterwilsoncc | Owner:
Type: enhancement | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Menus | Version:
Severity: normal | Resolution:
Keywords: needs-unit-tests needs-patch | Focuses: template
------------------------------------------+------------------------------
Comment (by afercia):
Replying to [comment:5 peterwilsoncc]:
> * have `wp_nav_menu` remain whitespace consistent when it falls back to
the page listing (they currently differ)
Yep, this was one of the concerns that #27762 tried to address. Totally
agree these two functions should have a consistent white space handling :)
For example, the CSS hack mentioned in #35107 to have justified menu items
won't work when the menu fallbacks to `wp_page_menu()`.
About the second issue, yes [https://css-tricks.com/fighting-the-space-
between-inline-block-elements/ there are a number of ways to fight white
space using CSS only], including using Flexbox, but they all have
drawbacks. It's almost 2016 and still the only reliable way to do this is
controlling the markup output, waiting for [http://dev.w3.org/csswg/css-
text-4/#white-space-collapsing white-space-collapsing in CSS4].
Software should make things easy and solve this kind of issues for you, so
I'd agree with @peterwilsoncc about introducing a simple way (maybe an
argument?) to remove white space.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/35206#comment:6>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list