Sha256: 8b6837d9d95bec4d7768ad251e186ec03b4bccd018e40d709db33fcf9c83f908
Contents?: true
Size: 602 Bytes
Versions: 104
Compression:
Stored size: 602 Bytes
Contents
const text = axe.commons.text.visibleVirtual(virtualNode, true).toLowerCase(); if (text === '') { return false; } // Get all visible images in the composed tree of the current node const images = axe.utils .querySelectorAll(virtualNode, 'img') // Ignore hidden or role=none/presentation images .filter( ({ actualNode }) => axe.commons.dom.isVisible(actualNode) && !['none', 'presentation'].includes(actualNode.getAttribute('role')) ); // See if any of the images duplicate the node's text return images.some( img => text === axe.commons.text.accessibleTextVirtual(img).toLowerCase() );
Version data entries
104 entries across 104 versions & 1 rubygems