{"action":"created","issue":{"url":"https://api.github.com/repos/lmgonzalves/jelly/issues/4","repository_url":"https://api.github.com/repos/lmgonzalves/jelly","labels_url":"https://api.github.com/repos/lmgonzalves/jelly/issues/4/labels{/name}","comments_url":"https://api.github.com/repos/lmgonzalves/jelly/issues/4/comments","events_url":"https://api.github.com/repos/lmgonzalves/jelly/issues/4/events","html_url":"https://github.com/lmgonzalves/jelly/issues/4","id":350970971,"node_id":"MDU6SXNzdWUzNTA5NzA5NzE=","number":4,"title":"Cannot preventDefault() onDragStart with react-alice-carousel","user":{"login":"P-Henoch","id":12370103,"node_id":"MDQ6VXNlcjEyMzcwMTAz","avatar_url":"https://avatars0.githubusercontent.com/u/12370103?v=4","gravatar_id":"","url":"https://api.github.com/users/P-Henoch","html_url":"https://github.com/P-Henoch","followers_url":"https://api.github.com/users/P-Henoch/followers","following_url":"https://api.github.com/users/P-Henoch/following{/other_user}","gists_url":"https://api.github.com/users/P-Henoch/gists{/gist_id}","starred_url":"https://api.github.com/users/P-Henoch/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/P-Henoch/subscriptions","organizations_url":"https://api.github.com/users/P-Henoch/orgs","repos_url":"https://api.github.com/users/P-Henoch/repos","events_url":"https://api.github.com/users/P-Henoch/events{/privacy}","received_events_url":"https://api.github.com/users/P-Henoch/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2018-08-15T21:18:10Z","updated_at":"2018-08-16T18:52:35Z","closed_at":"2018-08-16T18:52:35Z","author_association":"NONE","body":"My component is use as an item in a `react-alice-carousel`. When dragging my carousel, I'm trying to prevent `Link` to be clicked. It seems that using `Jelly` makes `onDragStart` event not fired or fired when dragging very quickly. Using a canvas with stroke() makes `onDragStart` event fired no matter what\r\n```\r\nimport React from 'react';\r\nimport Tilt from 'react-tilt';\r\nimport { Link } from 'react-router-dom';\r\nimport Jelly from 'jelly.js';\r\nimport { canvasOptions } from '../../../utils/utils';\r\n\r\nclass NightySvg extends React.Component {\r\n  componentDidMount() {\r\n    new Jelly(this.canvas.current, canvasOptions('#nightyPath'));\r\n    // const ctx = this.canvas.current.getContext(\"2d\");\r\n    // ctx.beginPath();\r\n    // ctx.moveTo(20,20);\r\n    // ctx.lineTo(20,100);\r\n    // ctx.lineTo(70,100);\r\n    // ctx.stroke();\r\n  }\r\n\r\n  canvas = React.createRef();\r\n\r\n  handleDrag(e) {\r\n    e.preventDefault();\r\n  }\r\n\r\n  render() {\r\n    return (\r\n      <div onDragStart={this.handleDrag}>\r\n        <svg width=\"289px\" height=\"306px\" version=\"1.1\" xmlns=\"http://www.w3.org/2000/svg\" display=\"none\">\r\n          <path id=\"nightyPath\" d=\"M90.652...\" />\r\n        </svg>\r\n        <Link className=\"menuNav-item\" to=\"/nighty\">\r\n          <Tilt className=\"Tilt\" options={{ max: 25 }}>\r\n            <div className=\"tiltContent\">\r\n              <div>\r\n                <span className=\"menuNumber\">01</span>\r\n                <div>nighty</div>\r\n                <canvas draggable=\"true\" ref={this.canvas}\r\n                className=\"nightyCanvas Tilt-inner\" width=\"289px\" height=\"306px\" />\r\n              </div>\r\n            </div>\r\n          </Tilt>\r\n        </Link>\r\n      </div>\r\n    );\r\n  }\r\n}\r\n\r\nexport default NightySvg;\r\n\r\n```"},"comment":{"url":"https://api.github.com/repos/lmgonzalves/jelly/issues/comments/413648582","html_url":"https://github.com/lmgonzalves/jelly/issues/4#issuecomment-413648582","issue_url":"https://api.github.com/repos/lmgonzalves/jelly/issues/4","id":413648582,"node_id":"MDEyOklzc3VlQ29tbWVudDQxMzY0ODU4Mg==","user":{"login":"P-Henoch","id":12370103,"node_id":"MDQ6VXNlcjEyMzcwMTAz","avatar_url":"https://avatars0.githubusercontent.com/u/12370103?v=4","gravatar_id":"","url":"https://api.github.com/users/P-Henoch","html_url":"https://github.com/P-Henoch","followers_url":"https://api.github.com/users/P-Henoch/followers","following_url":"https://api.github.com/users/P-Henoch/following{/other_user}","gists_url":"https://api.github.com/users/P-Henoch/gists{/gist_id}","starred_url":"https://api.github.com/users/P-Henoch/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/P-Henoch/subscriptions","organizations_url":"https://api.github.com/users/P-Henoch/orgs","repos_url":"https://api.github.com/users/P-Henoch/repos","events_url":"https://api.github.com/users/P-Henoch/events{/privacy}","received_events_url":"https://api.github.com/users/P-Henoch/received_events","type":"User","site_admin":false},"created_at":"2018-08-16T18:52:35Z","updated_at":"2018-08-16T18:52:35Z","author_association":"NONE","body":"It's working well, Thank you!"}}
{"actor":{"display_login":"P-Henoch"}}