diff options
author | Andrew Dolgov <[email protected]> | 2021-03-04 14:53:33 +0300 |
---|---|---|
committer | Andrew Dolgov <[email protected]> | 2021-03-04 14:53:33 +0300 |
commit | b74e31384463541732b622bd5529a18a6100b329 (patch) | |
tree | 56c21952ffd882df1b32efa719e77ae87dab4d87 /js | |
parent | 4fda5ccd0e248750f68b4a9802044d02f84eb7cc (diff) |
use computed style for element.prototype.visible
Diffstat (limited to 'js')
-rwxr-xr-x | js/common.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/js/common.js b/js/common.js index 9c748f9c5..1f8318862 100755 --- a/js/common.js +++ b/js/common.js @@ -100,7 +100,7 @@ Element.prototype.fadeIn = function(display = undefined){ }; Element.prototype.visible = function() { - return this.style.display != "none" && this.offsetHeight != 0 && this.offsetWidth != 0; + return window.getComputedStyle(this).display != "none"; //&& this.offsetHeight != 0 && this.offsetWidth != 0; } Element.visible = function(elem) { |