gridstack / gridstack.js

Build interactive dashboards in minutes.
https://gridstackjs.com
MIT License
6.38k stars 1.27k forks source link

fix issue on failed drag makes the whole grid unresponsive #2672

Closed mustafamilyas closed 2 months ago

mustafamilyas commented 2 months ago

Description

Screenshot 2024-05-02 at 09 16 45 when we drag a widget and fail, it will throw the above error and make all the whole grid unresponsive

Checklist

How to reproduce

sfragis commented 2 months ago

Hi @mustafamilyas and @adumesny, does this PR also fix issue #2667 by any chance?

adumesny commented 2 months ago

@sfragis nothing to do with it.

mustafamilyas commented 2 months ago

@adumesny, apologies for the delay. I've made the adjustments as per your suggestion and tested them on my end. It seems to have resolved the issue at least on my side.

Below, you'll find a JSFiddle and a video demonstrating how to reproduce the error before the changes were made. Let me know if you need further assistance. Thank you!

https://jsfiddle.net/redmaze/jqw25fed/7/ https://www.loom.com/share/c89f4254d3e347d4adcc934d6bd71d74?sid=bc050e16-02a4-4170-aa60-c8b70d9936b1

adumesny commented 2 months ago

that demo is weird. items are places 1x1 first, then 2x1 (to match actual dragged size, what it should be) even if you don't resize the dropped item.