gwt-material
gwt-material copied to clipboard
MaterialImage Type Material Box throws an JS-Exception
Hi, the Material-Box throws a JS-Exception if I zoom out. This Error occurs in the Demo too and is thrown from the materialiceJSDebug.js because the ancestorsChanged is undefined.
// Remove overflow overrides on ancestors
ancestorsChanged.css('overflow', '');
The Problem occurs in the Codes above this Line
// Find ancestor with overflow: hidden; and remove it
ancestorsChanged = undefined;
ancestor = placeholder[0].parentNode;
var count = 0;
while (ancestor !== null && !$(ancestor).is(document)) {
var curr = $(ancestor);
if (curr.css('overflow') === 'hidden') {
curr.css('overflow', 'visible');
if (ancestorsChanged === undefined) {
ancestorsChanged = curr;
}
else {
ancestorsChanged = ancestorsChanged.add(curr);
}
}
ancestor = ancestor.parentNode;
}
Problem can be solved with:
// Remove overflow overrides on ancestors
if (ancestorsChanged !== undefined) {
ancestorsChanged.css('overflow', '');
}
Is it possible to fix this Error?
This could be a Materialize internal issue, will take a look if there are related issue about this.
IMHO we should wait for the official release of Materialize 1.0 for there internal fixes.