Sha256: 7b211fa3fa9c7989d46ad396348e7dce30059471255186db42413cae001f414d
Contents?: true
Size: 484 Bytes
Versions: 26
Compression:
Stored size: 484 Bytes
Contents
import { getWindow } from './getWindow.js'; function isVisible(element) { const window = getWindow(element); for(let el = element; el === null || el === void 0 ? void 0 : el.ownerDocument; el = el.parentElement){ const { display, visibility } = window.getComputedStyle(el); if (display === 'none') { return false; } if (visibility === 'hidden') { return false; } } return true; } export { isVisible };
Version data entries
26 entries across 26 versions & 1 rubygems