Permalink
Browse files

fix(dropdown.js): import clickout as a mixin (#896)

  • Loading branch information...
tmorehouse committed Aug 20, 2017
1 parent 9fc726d commit 1ba47e53846c41765229db2a24869fe70b16890c
Showing with 2 additions and 5 deletions.
  1. +2 −5 lib/mixins/dropdown.js
@@ -1,4 +1,4 @@
import clickOut from './clickout';
import clickoutMixin from './clickout';
import listenOnRootMixin from './listen-on-root'
import { from as arrayFrom } from '../utils/array'
@@ -16,7 +16,7 @@ function filterVisible(els) {
const ITEM_SELECTOR = '.dropdown-item:not(.disabled):not([disabled])';
export default {
mixins: [listenOnRootMixin],
mixins: [clickoutMixin, listenOnRootMixin],
props: {
id: {
type: String
@@ -56,8 +56,6 @@ export default {
// Hide when clicked on links
this.listenOnRoot('clicked::link', listener);
},
mounted: clickOut.mounted,
destroyed: clickOut.destroyed,
watch: {
visible(state, old) {
if (state === old) {
@@ -107,7 +105,6 @@ export default {
}
},
methods: {
...clickOut.methods,
noop() {
// Do nothing event handler (used in visible watch)
},

0 comments on commit 1ba47e5

Please sign in to comment.