We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent eb04f36 commit f695a01Copy full SHA for f695a01
web_src/js/utils/dom.js
@@ -237,10 +237,5 @@ export function initSubmitEventPolyfill() {
237
export function isVisible(element) {
238
if (!element) return false;
239
240
- const style = window.getComputedStyle(element);
241
- return style.width !== '0' &&
242
- style.height !== '0' &&
243
- style.opacity !== '0' &&
244
- style.display !== 'none' &&
245
- style.visibility !== 'hidden';
+ return Boolean(element.offsetWidth || element.offsetHeight || element.getClientRects().length);
246
}
0 commit comments