We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 57c6511 + 6ae9378 commit ba681fcCopy full SHA for ba681fc
src/gridstack.js
@@ -673,6 +673,9 @@
673
this.grid = new GridStackEngine(this.opts.width, function(nodes, detachNode) {
674
detachNode = typeof detachNode === 'undefined' ? true : detachNode;
675
var maxHeight = 0;
676
+ _.each(this.nodes, function(n) {
677
+ maxHeight = Math.max(maxHeight, n.y + n.height);
678
+ });
679
_.each(nodes, function(n) {
680
if (detachNode && n._id === null) {
681
if (n.el) {
@@ -684,7 +687,6 @@
684
687
.attr('data-gs-y', n.y)
685
688
.attr('data-gs-width', n.width)
686
689
.attr('data-gs-height', n.height);
- maxHeight = Math.max(maxHeight, n.y + n.height);
690
}
691
});
692
self._updateStyles(maxHeight + 10);
0 commit comments