Search code examples
accessibilitywai-ariascreen-readers

Documentation for ChromeVox reading time durations?


I'm working on an a11y feature to read out time stamps in this format:

<div>3:20</div>

And I'd like that to read as "3 minutes 20 seconds"

My coworker found that if I add an aria label of "0h 3m 20s" to the div, it reads it as "zero hours 3 minutes 20 seconds"

However, if I leave off the hours, it reads "3 meters twenties." Similarly, if I leave off the minutes (1h 20s) it reads "1 h twenties"

Is there any way I can have it read this type of strings without the hours (most are under an hour). In general, is there any sort of documentation for having the screen reader read these kinds of strings? Or is it best practice to just spell out the words in the aria label? Thank you.

FYI I'm using Chromevox.


Solution

  • You have to consider that ChromeVox is not a screenreader used by a lot of people (except some developers). See WebAIM Screenreader survey

    The problem with your question is that it's still possible to find a hack to announce the time in a different format (see answer to your previous question) using some "sr-only" hack but it will never be accessible as long as the visible time is not accessible.

    Nobody can guess that "3:20" means "3 minutes 20 seconds" and not "3 hours 20 minutes". Providing that information for screenreaders should not prevent to provide this information for everyone.

    Using some more accessible notation like "3 min 20" instead of "3:20" would be very helpful and more accessible.

    aria-label won't be of any help for standard screenreaders who won't announce this unless it's on an interactive element (link, button, ...). By the way, using aria-label the best thing would be to write "3 minutes and 20 seconds"