🔗ally.is.validArea
Determines if an <area>
element is properly used via <map>
by an <img>
.
🔗Usage
var element = document.getElementById('victim');
var isValidArea = ally.is.validArea(element);
🔗Arguments
Name | Type | Default | Description |
---|---|---|---|
element | HTMLElement | required | The Element to test. |
🔗Returns
Boolean, true
if the element is focus relevant.
🔗Throws
TypeError
if element
argument is not of type HTMLElement
.
🔗Changes
- Since
v#master
the<img usemap="#…" …>
is resolved in the same document<map>
is from (e.g. within an iframe) - Since
v#master
the existence of thehref
attribute is considered.
🔗Notes
NOTE: Firefox only allows fully loaded images to reference image maps
NOTE: Multiple use of same image map hides elements from tabbing sequence - Gecko 1116126