Permalink
Browse files

fix(dropdown): prevent toggle click from closing in collapsed navbar (#…

…1475)

Fixes #1474
  • Loading branch information...
tmorehouse committed Dec 17, 2017
1 parent 534b4b7 commit 24ef1e6b2a94981d302da3a05ed790a9b46afa32
Showing with 3 additions and 1 deletion.
  1. +3 −1 src/mixins/dropdown.js
@@ -135,6 +135,7 @@ export default {
}
// Disable totally Popper.js for Dropdown in Navbar
/* istnbul ignore next: can't test popper in JSDOM */
if (!this.inNavbar) {
if (typeof Popper === 'undefined') {
warn('b-dropdown: Popper.js not found. Falling back to CSS positioning.')
@@ -173,7 +174,7 @@ export default {
}
this._popper = null
},
getPopperConfig () {
getPopperConfig /* istanbul ignore next: can't test popper in JSDOM */ () {
let placement = AttachmentMap.BOTTOM
if (this.dropup && this.right) {
// dropup + right
@@ -257,6 +258,7 @@ export default {
return
}
evt.preventDefault()
evt.stopPropagation()
if (this.disabled) {
this.visible = false
return

0 comments on commit 24ef1e6

Please sign in to comment.