Skip to content
Snippets Groups Projects
Commit c7ab4050 authored by Piotr Gawron's avatar Piotr Gawron
Browse files

jquery outerheight value changed for undefiend elements

parent 2a41e4de
No related branches found
No related tags found
2 merge requests!630WIP: Resolve "The privileges of a new user are not saved in some cases",!464Resolve "upgrade 3rd party libraries"
...@@ -335,14 +335,15 @@ Panel.prototype.onresize = function () { ...@@ -335,14 +335,15 @@ Panel.prototype.onresize = function () {
var self = this; var self = this;
var footerPosition = window.innerHeight; var footerPosition = window.innerHeight;
var footerHeight = Math.max(0, $(".minerva-logo-footer").outerHeight()); var footerHeight = Math.max(0, $(".minerva-logo-footer, .minerva-footer-table").outerHeight());
footerHeight = Math.max(footerHeight, $(".minerva-footer-table").outerHeight());
footerPosition -= footerHeight; footerPosition -= footerHeight;
// compute the width (we can only compute it for visible elements) // compute the width (we can only compute it for visible elements)
var size = 100000; var size = 100000;
console.log(footerPosition, footerHeight);
console.log(footerPosition, footerHeight);
if ($(self.getElement()).is(":visible")) { if ($(self.getElement()).is(":visible")) {
$(".pre-scrollable", self.getElement()).each(function (index, element) { $(".pre-scrollable", self.getElement()).each(function (index, element) {
...@@ -359,6 +360,7 @@ Panel.prototype.onresize = function () { ...@@ -359,6 +360,7 @@ Panel.prototype.onresize = function () {
$(element).css('height', size); $(element).css('height', size);
}); });
} }
console.log(size, $(self.getElement()).hasClass("pre-scrollable"), self.getPanelName());
if ($(self.getElement()).hasClass("pre-scrollable") && $(self.getElement()).is(":visible")) { if ($(self.getElement()).hasClass("pre-scrollable") && $(self.getElement()).is(":visible")) {
$(self.getElement()).css('max-height', size); $(self.getElement()).css('max-height', size);
$(self.getElement()).css('height', size); $(self.getElement()).css('height', size);
......
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