Commit c2a6782c authored by Dylan Weiss's avatar Dylan Weiss
Browse files

Merge branch 'develop'

parents a286851c ff31cb7b
...@@ -9,7 +9,8 @@ ...@@ -9,7 +9,8 @@
}, },
"scripts": { "scripts": {
"build": "grunt ; doctoc ./README.md ; doctoc ./doc/README.md ; doctoc ./doc/CHANGES.md", "build": "grunt ; doctoc ./README.md ; doctoc ./doc/README.md ; doctoc ./doc/CHANGES.md",
"test": "grunt lint && karma start karma.conf.js" "test": "grunt lint && karma start karma.conf.js",
"lint": "grunt lint"
}, },
"keywords": [ "keywords": [
"gridstack", "gridstack",
......
...@@ -1033,9 +1033,13 @@ ...@@ -1033,9 +1033,13 @@
return; return;
} }
var height = this.grid.getGridHeight(); var height = this.grid.getGridHeight();
var minHeight = parseInt(this.container.css('min-height')) / this.cellHeight(); // check for css min height. Each row is cellHeight + verticalMargin, until last one which has no margin below
if (height < minHeight) { var cssMinHeight = parseInt(this.container.css('min-height'));
height = minHeight; if (cssMinHeight > 0) {
var minHeight = (cssMinHeight + this.opts.verticalMargin) / (this.cellHeight() + this.opts.verticalMargin);
if (height < minHeight) {
height = minHeight;
}
} }
this.container.attr('data-gs-current-height', height); this.container.attr('data-gs-current-height', height);
if (!this.opts.cellHeight) { if (!this.opts.cellHeight) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment