Revert "JS: Do not apply 'menu-hovered' on #layout"
This reverts commit 5443bfe9fa
.
This commit is contained in:
parent
1cf2f767a2
commit
0432b7d50d
|
@ -277,12 +277,17 @@
|
|||
var $flyout = $target.find('.nav-level-2');
|
||||
|
||||
if (! $flyout.length) {
|
||||
$layout.removeClass('menu-hovered');
|
||||
$target.siblings().not($target).removeClass('hover');
|
||||
return;
|
||||
}
|
||||
|
||||
var delay = 300;
|
||||
|
||||
if ($layout.hasClass('menu-hovered')) {
|
||||
delay = 0;
|
||||
}
|
||||
|
||||
setTimeout(function() {
|
||||
try {
|
||||
if (! $target.is(':hover')) {
|
||||
|
@ -290,6 +295,7 @@
|
|||
}
|
||||
} catch(e) { /* Bypass because if IE8 */ }
|
||||
|
||||
$layout.addClass('menu-hovered');
|
||||
$target.siblings().not($target).removeClass('hover');
|
||||
$target.addClass('hover');
|
||||
|
||||
|
@ -319,6 +325,8 @@
|
|||
var $hovered = $('#menu').find('.nav-level-1 > .nav-item.hover');
|
||||
|
||||
if (! $hovered.length) {
|
||||
$layout.removeClass('menu-hovered');
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -329,6 +337,7 @@
|
|||
}
|
||||
} catch(e) { /* Bypass because if IE8 */ };
|
||||
$hovered.removeClass('hover');
|
||||
$layout.removeClass('menu-hovered');
|
||||
}, 600);
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in New Issue