Skip to content

Commit

Permalink
Revert "Using component-tap-event to more accurately distinguish betw…
Browse files Browse the repository at this point in the history
…een scrolls and taps on touch devices"

This reverts commit 3b7c57f.
  • Loading branch information
Aaria Carter-Weir committed Aug 29, 2019
1 parent b95c5d8 commit e74c57f
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 17 deletions.
10 changes: 1 addition & 9 deletions lib/v-click-outside.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
import tap from 'component-tap-event'

const HAS_WINDOWS = typeof window !== 'undefined'
const HAS_NAVIGATOR = typeof navigator !== 'undefined'
const IS_TOUCH =
Expand Down Expand Up @@ -38,19 +36,13 @@ function onEvent({ el, event, handler, middleware }) {
}

function createInstance({ el, events, handler, middleware }) {
const instance = {
return {
el,
eventHandlers: events.map((eventName) => ({
event: eventName,
handler: (event) => onEvent({ event, el, handler, middleware }),
})),
}

if (IS_TOUCH) {
instance.eventHandlers.handler = tap(handler)
}

return instance
}

function removeInstance(el) {
Expand Down
5 changes: 0 additions & 5 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 0 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,5 @@
},
"engines": {
"node": ">=6"
},
"dependencies": {
"component-tap-event": "^1.1.4"
}
}

0 comments on commit e74c57f

Please sign in to comment.