draggable icon indicating copy to clipboard operation
draggable copied to clipboard

Difficulty dragging items on mobile

Open bzle opened this issue 8 years ago β€’ 14 comments

Unlike on desktop, when on mobile, sometimes it's difficult to get an item to drag. Screen recording: not-dragging.mp4

I've updated my test/sample page with Draggable v0.5: http://fiery-quilt.cloudvent.net/

You can also check out the codepen created by leftdevel: https://codepen.io/anon/pen/WMNqmW Screen recording: https://www.dropbox.com/s/9khvw5f8seeiln3/codepen-not-dragging.mp4?dl=0

bzle avatar Mar 05 '18 23:03 bzle

@bzle Yeah I can see the trouble πŸ˜• have you tried to reduce the drag delay? Current default is 100: https://github.com/Shopify/draggable/blob/master/src/Draggable/Draggable.js#L67

For Example:

new Draggable(containers, {
  delay: 50, // or even 0
})

tsov avatar Mar 05 '18 23:03 tsov

I'll give that a try, though sometimes I give a decent pause before trying to drag... maybe I'm still moving a little bit or something.

bzle avatar Mar 05 '18 23:03 bzle

I have noticed that myself, something to check out for sure! All touch related code is abstracted in our TouchSensor, so will have to dig a little deeper why the delay seems to be longer on touch.

tsov avatar Mar 05 '18 23:03 tsov

Thanks @tsov Setting a very brief delay of 5 seems to be about perfect. If the delay is set to 0, you'll get the "dragging and scrolling" bug every time you start dragging while still moving.

bzle avatar Mar 06 '18 03:03 bzle

If the delay is set to 0, you'll get the "dragging and scrolling" bug every time you start dragging while still moving.

That will be helpful when debugging πŸ‘ thanks for mentioning

tsov avatar Mar 08 '18 03:03 tsov

@bzle could you confirm if this is still an issue for beta.6 ?

tsov avatar Apr 04 '18 18:04 tsov

You should be able to set delay to 0 now, without getting into that weird state

tsov avatar Apr 04 '18 18:04 tsov

@tsov The project I was working on is finished, so I may not be able to test. I'll leave an update if I get the chance to implement beta.6

bzle avatar Apr 09 '18 04:04 bzle

I'll also add (although I'm not sure if its related) that there is a scrolling and dragging issue on the project's homepage https://shopify.github.io/draggable/

ncovercash avatar Apr 09 '18 04:04 ncovercash

@bzle cool cool πŸ‘ For now I may close this issue, until it comes again. Feel free to re-open

@smileytechguy The site may not have been updated to use the latest version of draggable, which means it's missing the scrolling improvements from beta.6. Let's open a separate issue for this πŸ™‚and tackle it soon

tsov avatar Apr 09 '18 13:04 tsov

I updated the site last night - tested and can't find any scrolling issues, but please let me know if it persists!

beefchimi avatar Apr 09 '18 13:04 beefchimi

☝️ This guy πŸ‘Œ

@smileytechguy let us know if the issues persist on the project homepage

tsov avatar Apr 09 '18 13:04 tsov

iOS 11.3 on an iPhone 7 still has this issue, tried clearing cache:

https://www.youtube.com/watch?v=U6s62s9jYVM&feature=youtu.be

ncovercash avatar Apr 09 '18 14:04 ncovercash

@tsov I was able to update the project to beta.6 and set the delay to 0. Issue where dragging and scrolling are both triggered is fixed! Thanks!

bzle avatar Apr 10 '18 17:04 bzle