Index: include.preload.js |
diff --git a/include.preload.js b/include.preload.js |
index 02661d39c86ace26fcddea8395726dddf7018df8..5a6146b930f5b862eb8fbc855816198de6af723c 100644 |
--- a/include.preload.js |
+++ b/include.preload.js |
@@ -150,10 +150,17 @@ function checkCollapse(element) |
{ |
function collapseElement() |
{ |
+ var propertyName = "display"; |
+ var propertyValue = "none"; |
if (element.localName == "frame") |
- element.style.setProperty("visibility", "hidden", "important"); |
- else |
- element.style.setProperty("display", "none", "important"); |
+ { |
+ propertyName = "visibility"; |
+ propertyValue = "hidden"; |
+ } |
+ |
+ if (element.style.getPropertyValue(propertyName) !== propertyValue || |
+ element.style.getPropertyPriority(propertyName) !== "important") |
+ element.style.setProperty(propertyName, propertyValue, "important"); |
} |
if (collapse && !element._collapsed) |