Skip to content

Conversation

OperKH
Copy link

@OperKH OperKH commented Jan 5, 2018

No description provided.

Copy link

@WORMSS WORMSS left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This will allow people to choose what they want to use.

v-click-outside.capture="hide"

unbind: function (el, binding, vNode) {
// Remove Event Listeners
!isServer(vNode) && document.removeEventListener('click', el.__vueClickOutside__.handler)
!isServer(vNode) && document.removeEventListener('click', el.__vueClickOutside__.handler, true)
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
!isServer(vNode) && document.removeEventListener('click', el.__vueClickOutside__.handler, true)
!isServer(vNode) && document.removeEventListener('click', el.__vueClickOutside__.handler, !!binding.modifiers.capture)

callback: binding.value
}
!isServer(vNode) && document.addEventListener('click', handler)
!isServer(vNode) && document.addEventListener('click', handler, true)
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
!isServer(vNode) && document.addEventListener('click', handler, true)
!isServer(vNode) && document.addEventListener('click', handler, !!binding.modifiers.capture)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants