Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TTS readaloud: aria-label on generic elements with overridden ARIA role, still speaks element textual content #1717

Open
danielweck opened this issue Jul 4, 2022 · 4 comments

Comments

@danielweck
Copy link
Member

(aria-label should take precedence, just as AT/screen readers do)

@pkra
Copy link

pkra commented Jul 7, 2022

(aria-label should take precedence, just as AT/screen readers do)

But please be aware that aria-label is not allowed for all roles, cf. the exclude list at https://w3c.github.io/aria/#aria-label. It's a common authoring error ito add aria-label attributes when they aren't allowed.

In that case, browsers should ignore aria-label when building the accessibility tree and thus AT would not have access to it. (And the reality is much more complicated still.)

@danielweck
Copy link
Member Author

Ha ha, sounds like a sweet rabbit hole. Thanks for letting us know :)

@pkra
Copy link

pkra commented Jul 7, 2022

Indeed. There are a couple of JS libraries that effectively implement the accname spec. IIRC none of them are perfect, e.g. I don't think anyone tries to figure out the "true" role since browsers have no getComputedRole API (yet).

@danielweck
Copy link
Member Author

Related issue: readium/r2-navigator-js#76

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants