You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
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!
The text was updated successfully, but these errors were encountered:
davjhan
changed the title
Support for setting bounds when dragged element is bigger than the parent
Support setting bounds when dragged element is bigger than the parent
May 7, 2023
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 of400 x 400
pixels. Here, thebounds = '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!
The text was updated successfully, but these errors were encountered: