Add Drag & Drop events (manually creating it with enter/exit is buggy)
Right now the only way to create drag & drop functionality is like this:
Pointer down on target sets
isDragging
value totrue
When
isDragging === true
align target to pointeron pointer up or exit, set
isDragging
tofalse
This works alright, but is cumbersome and is pretty finicky. When you drag too fast or if you keep dragging until you're off the hit area, you can run into issues. Sometimes it doesn't clock the exit event which can cause strange behavior. See this video where it's dragging even when the pointer is up and how the distance between the pointer and the drag element drifts the more I drag:
The smaller the draggable item, the more likely you are to run into issues.
Solution
Build out-of-the-box drag/drop events into Rive that account for things like fast pointer movement, pointer up outside of the Rive artboard area.
HI
Good workaround, thanks.