Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

H5 resize down from left side will move item to the right #1599

Closed
riccardinhocala opened this issue Jan 29, 2021 · 1 comment · Fixed by #1607
Closed

H5 resize down from left side will move item to the right #1599

riccardinhocala opened this issue Jan 29, 2021 · 1 comment · Fixed by #1607
Labels

Comments

@riccardinhocala
Copy link

Subject of the issue

If the GridItem is in the 12th (and last) column, when resize with sw handler, this action trigger both drag and resize. In this way the GridItem go out from the gridstack

Your environment

gridstack v3.2.0, HTML5

Steps to reproduce

demo: https://jsfiddle.net/rob4e7z6/
resize from bottom left the last GridItem
chrome-capture
.

Expected behavior

What happens with resize from bottom right. The GridItem may set his width and not drag

Actual behavior

It will trigger both drag and resize. In this way the GridItem go out from the gridstack

@adumesny
Copy link
Member

adumesny commented Jan 29, 2021

funny I fixed a similar issue when resizing from the left past the maxWidth did also move the object couple weeks ago (see #1330). Guess I didn't take a look sizing it below minWidth (1 in this case). Don't need to be column 12, it will move right instead of stop when min sized.

one of the reason I changed to only resize bottom right in the demos - always though left side resize was odd anyway and can have all sort of harder to fix side effects.

Note: jq version works

@adumesny adumesny changed the title Drag event starts if resize from sw, in last right column resize down from left side will move item to the right Jan 29, 2021
@adumesny adumesny changed the title resize down from left side will move item to the right H5 resize down from left side will move item to the right Feb 3, 2021
@adumesny adumesny closed this as completed Feb 3, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants