Best approach for meeting Success Criterion 1.4.13 Content on Hover or Focus via ESC key

Hi all,

When we consider a SCR technique for meeting Success Criterion 
1.4.13("Using the ESC key to close content on hover or focus"), I am 
just wondering what the most elegant way would be to implement closing 
via pressing ESC to close whatever popup menu or custom tool tip happens 
to be open on a page (assuming there would always only be one 
hover/focus object at the time that needs closing via ESC). Would one 
need to register the container's display status in some popup variable 
and add a document.keydown functi|on to close whatever container is in 
that variable? is it safe if ESC is consumed by that action or should it 
bubble? Or is there some better way? If there any simple vanilla code 
out there for that, please let me know (or point to that). (This should 
not be read as an indication that I am ready to pick up this technique, 
my JS skills are not great - others are welcome to do so, it seems at 
first sight pretty straightforeward.)
|

|Detlev
|

||||

-- 
Detlev Fischer
Testkreis
Werderstr. 34, 20144 Hamburg

Mobil +49 (0)157 57 57 57 45

http://www.testkreis.de
Beratung, Tests und Schulungen für barrierefreie Websites



---
Diese E-Mail wurde von Avast Antivirus-Software auf Viren geprüft.
https://www.avast.com/antivirus

Received on Friday, 24 August 2018 10:00:43 UTC