Support setting bounds when dragged element is bigger than the parent
davjhan opened this issue · 0 comments
davjhan commented
The bounds
param breaks short in use cases where the dragged element is bigger than the parent.
For example, imagine a pannable graph of 1000 x 1000
pixels shown in a viewport of 400 x 400
pixels. Here, the bounds = 'parent'
bricks the entire draggable, because mathematically, at least one side must be out of bounds.
Suggestions:
Support something like DragBounds
but where the bounds are relative to the parent's local coordinates instead of the window.
Also, a way to easily implement overscroll would be great.
Thanks!