use-gesture icon indicating copy to clipboard operation
use-gesture copied to clipboard

onDragStart values of direction, delta are oftenly [0, 0]

Open megaarmos opened this issue 10 months ago • 0 comments

Describe the bug:

When the onDragStart event is fired, the values for direction and delta are not determined. In rare occasions, they return proper values. Below are the logs when onDragStart is triggered:

onDragStart direction: [0, 0] 
onDragStart delta: [0, 0]

This code is using gestures from @vueuse/gesture. It always works as expected, with the values for direction and delta being determined correctly when onDragStart is fired:

onDragStart direction: [0, -1]
onDragStart delta: [0, -5]

Information:

  • @use-gesture/vanilla: 10.3.1
  • Device: Desktop
  • OS: Windows
  • Browser: Google Chrome

Checklist:

  • [x] I've read the documentation.
  • [x] If this is an issue with drag, I've tried setting touch-action: none to the draggable element.

megaarmos avatar Dec 15 '24 23:12 megaarmos