Skip to content

Commit 0599524

Browse files
committed
nested grid resizeToContentCBCheck() fix
* make sure nested items size they parent item even when in batch mode (eg: load()) otherwise it never happens
1 parent 1f9d0c0 commit 0599524

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

doc/CHANGES.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,7 @@ Change log
129129

130130
## 12.1.1-dev (TBD)
131131
* fix [#3043](https://github.com/gridstack/gridstack.js/issues/3043) fix `opts.animate` again
132+
* fix [#3047](https://github.com/gridstack/gridstack.js/pull/3047) nested grid resizeToContentCBCheck() fix
132133

133134

134135
## 12.1.1 (2024-04-28)

src/gridstack.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1616,7 +1616,7 @@ export class GridStack {
16161616
}
16171617

16181618
// if we're a nested grid inside an sizeToContent item, tell it to resize itself too
1619-
if (parent && !parent.grid.engine.batchMode && Utils.shouldSizeToContent(parent)) {
1619+
if (parent && Utils.shouldSizeToContent(parent)) {
16201620
parent.grid.resizeToContentCBCheck(parent.el);
16211621
}
16221622

0 commit comments

Comments
 (0)