Skip to content
Snippets Groups Projects
Commit 46d6cb73 authored by Robin Appelman's avatar Robin Appelman
Browse files

Don't set the dialog content height to a zero or negative value

parent 541495b1
No related branches found
No related tags found
No related merge requests found
......@@ -160,10 +160,16 @@
}
this.parent = this.$dialog.parent().length > 0 ? this.$dialog.parent() : $('body');
content_height = Math.min(content_height, this.parent.height()-20);
this.element.css({
height: content_height + 'px',
width: this.$dialog.innerWidth()-20 + 'px'
});
if (content_height> 0) {
this.element.css({
height: content_height + 'px',
width: this.$dialog.innerWidth()-20 + 'px'
});
} else {
this.element.css({
width : this.$dialog.innerWidth() - 20 + 'px'
});
}
},
_createOverlay: function() {
if(!this.options.modal) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment