From eac3ccc29a0f0a0ee7f2cecc22fe88d602ae73c3 Mon Sep 17 00:00:00 2001 From: Matt Thomas Date: Wed, 22 Jan 2014 18:37:42 +0000 Subject: [PATCH] Responsive improvements to submenus in the adminbar: - Remove .ab-sub-wrapper rules in the 782px media query, as they're duplicates of the rules set on line 161. - Reposition the arrows for submenus at responsive sizes where the menus are taller. - Set the submenu position to static at smartphone sizes, so it's not positioned outside of its parent (and thus offscreen). Fixes #26720, props undergroundnetwork, iammattthomas. git-svn-id: https://develop.svn.wordpress.org/trunk@27006 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/css/admin-bar.css | 20 +++++++++++++++----- 1 file changed, 15 insertions(+), 5 deletions(-) diff --git a/src/wp-includes/css/admin-bar.css b/src/wp-includes/css/admin-bar.css index 4b165e32bf..d42cc9323c 100644 --- a/src/wp-includes/css/admin-bar.css +++ b/src/wp-includes/css/admin-bar.css @@ -1037,14 +1037,16 @@ html:lang(he-il) .rtl #wpadminbar * { float: right; } - #wpadminbar #wp-admin-bar-my-account .ab-sub-wrapper { - right: 0; - left: auto; - } - .network-admin #wpadminbar ul#wp-admin-bar-top-secondary > li#wp-admin-bar-my-account { margin-right: 0; } + + /* Realign arrows on taller responsive submenus */ + + #wpadminbar .ab-top-secondary .menupop .menupop > .ab-item:before { + top: 10px; + left: 0; + } } /* Smartphone */ @@ -1097,4 +1099,12 @@ html:lang(he-il) .rtl #wpadminbar * { #wpadminbar li#wp-admin-bar-updates { display: none; } + + /* Make submenus full-width at this size */ + + #wpadminbar .ab-top-menu > .menupop li > .ab-sub-wrapper { + position: static; + -webkit-box-shadow: none; + box-shadow: none; + } }