Subject of the issue
grid items slowly vanish (overlap?) if columns are adjusted too quickly then compact is requested. the grid items end up with negative gs-y coordinates. likely due to the column resize animation still being in progress when the math for the compact starts?
Your environment
gridstack-jq.js v4.2.5 on Firefox 89.0; float false; animations enabled.
Steps to reproduce
Fairly simple to reproduce in any project: https://jsfiddle.net/3ryc08as/
Stress test case:
for (let j = 0; j < 5; j++) {
for (let i = 1; i <= 12; i++) {
console.log("gridding at", i);
this.grid.column(i, "moveScale");
this.grid.compact();
}
}
Bonus bug: there's an infinite loop if .column(0) is requested.
Expected behavior
no race conditions between automatic column re-calibration and compaction.
Actual behavior
random subsets of .grid-stack-item elements end up with negative gs-y coordinates. if many column resizing+compaction ops are performed back to back (animation delay problems?), all smaller items eventually get hidden behind the largest item.
Subject of the issue
grid items slowly vanish (overlap?) if columns are adjusted too quickly then compact is requested. the grid items end up with negative
gs-ycoordinates. likely due to the column resize animation still being in progress when the math for the compact starts?Your environment
gridstack-jq.js v4.2.5 on Firefox 89.0; float false; animations enabled.
Steps to reproduce
Fairly simple to reproduce in any project: https://jsfiddle.net/3ryc08as/
Stress test case:
Bonus bug: there's an infinite loop if
.column(0)is requested.Expected behavior
no race conditions between automatic column re-calibration and compaction.
Actual behavior
random subsets of
.grid-stack-itemelements end up with negativegs-ycoordinates. if many column resizing+compaction ops are performed back to back (animation delay problems?), all smaller items eventually get hidden behind the largest item.