- From: Tobias Bengfort <tobias.bengfort@posteo.de>
- Date: Sat, 23 Jul 2016 14:28:14 +0200
- To: WAI IG <w3c-wai-ig@w3.org>
Received on Saturday, 23 July 2016 12:28:47 UTC
Hi, I am not sure where to direct this question, so sorry if this is the wrong channel. I just realized that there is no JavaScript API to access accessibility information. I am focusing on the role, but this probably also applies to other topics. The straight-forward way to get an element's role is `element.getAttribute('role')`. But this does not work for implicit roles. The actual role is calculated anyway by the browser, so I do not see any reason against exposing it as something like `element.role`. Taking this one step further, I guess it could also be useful to use the role in CSS selectors, but that is probably too far away for now. I cannot be the first person thinking about this. Is there any prior discussion that explains why this is not included in any spec? Or is there a spec that I missed? tobias
Received on Saturday, 23 July 2016 12:28:47 UTC