Permalink
Browse files

Support on___Capture

  • Loading branch information...
zvictor committed Jan 8, 2019
1 parent 5eafa5f commit a7a9e58fcc49dcc6a82e24d8aaf2efcc4492c513
Showing with 11 additions and 3 deletions.
  1. +11 −3 index.js
@@ -125,10 +125,18 @@ function handlers(set, props = {}, args) {
handleUp(e)
}

return {
onMouseDown: props.mouse ? onDown : undefined,
onTouchStart: props.touch ? onDown : undefined,
const output = {}
const capture = props.passive.capture ? 'Capture' : ''

if (props.mouse) {
output[`onMouseDown${capture}`] = onDown
}

if (props.touch) {
output[`onTouchStart${capture}`] = onDown
}

return output
}

class Gesture extends React.Component {

0 comments on commit a7a9e58

Please sign in to comment.