Skip to content

Commit

Permalink
load() sometimes restore incorrectly
Browse files Browse the repository at this point in the history
* fix #2669
ake sure we clear the _orig field as bash mode off retore for flaoting case
  • Loading branch information
adumesny committed Jun 24, 2024
1 parent 621dddd commit ab3340c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions doc/CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,7 @@ Change log
* fix: [#2683](https://github.com/gridstack/gridstack.js/issues/2683) check for fixed grid maxRow during resize
* fix: [#2694](https://github.com/gridstack/gridstack.js/issues/2694) prevent 'r' rotation to items that can't resize (locked, noResize, fixed sizes)
* fix: [#2709](https://github.com/gridstack/gridstack.js/pull/2709) support for multiple drag targets - Thank you [nickfulcher](https://github.com/nickfulcher)
* fix: [#2669](https://github.com/gridstack/gridstack.js/issues/2669) load() sometimes restore incorrectly

## 10.2.0 (2024-06-02)
* feat: [#2682](https://github.com/gridstack/gridstack.js/pull/2682) You can now press 'Esc' to cancel a move|resize, 'r' to rotate during a drag. added `GridStack.rotate()` as well - Thank you John B. for this feature sponsor.
Expand Down
1 change: 1 addition & 0 deletions src/gridstack.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1363,6 +1363,7 @@ export class GridStack {
const widthChanged = (m.w !== undefined && m.w !== n.w);
this.moveNode(n, m);
this.resizeToContentCheck(widthChanged, n); // wait for animation if we changed width
delete n._orig; // clear out original position now that we moved #2669
}
if (m || changed) {
this._writeAttr(el, n);
Expand Down

0 comments on commit ab3340c

Please sign in to comment.