Skip to content

Commit e86c260

Browse files
committed
If we're inside a navbar, don't do anything when the navbar is collapsed.
1 parent a9f63c1 commit e86c260

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

Diff for: bootstrap-hover-dropdown.js

+6
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,12 @@
9595
});
9696

9797
function openDropdown(event) {
98+
if($this.parents(".navbar").find(".navbar-toggle").is(":visible")) {
99+
// If we're inside a navbar, don't do anything when the
100+
// navbar is collapsed, as it makes the navbar pretty unusable.
101+
return;
102+
}
103+
98104
// clear dropdown timeout here so it doesnt close before it should
99105
window.clearTimeout(timeout);
100106
// restart hover timer

0 commit comments

Comments
 (0)