Make toolbar dropdown submenu links tappable. See #25972, props ninnypants.
git-svn-id: https://develop.svn.wordpress.org/trunk@26716 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
6384a83e5f
commit
3cf585f1d3
@ -1000,7 +1000,6 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
#wpadminbar .ab-top-menu > .menupop li > .ab-sub-wrapper {
|
#wpadminbar .ab-top-menu > .menupop li > .ab-sub-wrapper {
|
||||||
display: inline-block;
|
|
||||||
margin: 0;
|
margin: 0;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
top: auto;
|
top: auto;
|
||||||
|
@ -20,10 +20,14 @@ if ( typeof(jQuery) != 'undefined' ) {
|
|||||||
adminbar.find('li.menupop').on('click.wp-mobile-hover', function(e) {
|
adminbar.find('li.menupop').on('click.wp-mobile-hover', function(e) {
|
||||||
var el = $(this);
|
var el = $(this);
|
||||||
|
|
||||||
if ( !el.hasClass('hover') ) {
|
if ( el.parent().is('#wp-admin-bar-root-default') && !el.hasClass('hover') ) {
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
adminbar.find('li.menupop.hover').removeClass('hover');
|
adminbar.find('li.menupop.hover').removeClass('hover');
|
||||||
el.addClass('hover');
|
el.addClass('hover');
|
||||||
|
} else if ( !el.hasClass('hover') ) {
|
||||||
|
e.stopPropagation();
|
||||||
|
e.preventDefault();
|
||||||
|
el.addClass('hover');
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( unbind ) {
|
if ( unbind ) {
|
||||||
|
Loading…
Reference in New Issue
Block a user