WebAIM - Web Accessibility In Mind

E-mail List Archives

Re: Alert on search results update

for

From: tim.harshbarger
Date: Jun 26, 2023 5:37AM


This is just my own opinion about this, but hopefully it might help at least a little bit.

"Is the screen reader speaking too much information" very often tends to be a usability question rather than just an accessibility question. if you are uncertain how to proceed in making this accessible, I suggest setting aside any usability questions and just ffocusing on the accessibility questions alone. You can address the usability questions later.

One thing I will try to do is list out what might be the fundamental or basic information that is conveyed visually. What I am trying to figure out is what information is essential fto allow someone to interact with this widget successfully.

here are some of the things I find on my list.

* When the user starts typing, the widget visually conveys that typing will display results.
* The visual appearance of the list gives the user some general idea of how many results there might be--maybe not the exact number but whether there is none, 3, or more than 10 or 20.
* The user has some idea of how to select the results or to make progress with the widget in getting a desired result.

For me, that means some of the basic accessibility questions I need to answer are.

* How will the screen reader user know typing in the field displays results?
* How will the screen reader user know what keyboard interactions to use to select a result.
* How wil the screen reader get a general idea of how many results there currently are. particularly whether there are no results, a single result, or a lot of results.
* How will the screen reader know that using this widget successfully requires selecting on one of these options and they won't have another way to complete this step.

If you are not sure if this is everything or maybe even includes things that are unnecessary, ask yourself the question "If this information were visually missing from the interface, would it negatively impact visual users?"

After this, I would look at what HTML and ARIA features might help answer the question. I would also look at any additional accessibility techniques.

One additional technique I might use in this situation if I ended up using aria-live regions is to delay the speaking of messages. This is a technique I prefer to use if messages are being generated in response to keyboard entry.

The idea is that you use setTimeout to schedule the message to be spoken slightly later. However, if the user continues to press keys that alter what information is being provided, I then clear the timeout for that old message so it is never spoken. The advantage of this technique which is based on debouncing means that the user isn't flooded with messages. I typically set the timeout for less than a second--I try to just make it long enough so that the pause likely indicates the user has stopped typing for the moment so they can figure out what to do next but not so long that they move on without hearing the message.

After you answer the key accessibility questions, you can then go back and try to answer any usability questions. The benefit of doing this is that any answers to usability questions will be a bit easier to answer because you know what the accessibility requirements are.

Additionally when you get into answering usability questions, keep in mind that one of the best ways to answer these questions is with user testing. Some times you do have to rely on expert opinions which is ok, but just realize that as expert as the opinions are they are opinions.

Again there is nothing wrong with relying on expert opinions--especially if user testing is not possible. However, also realize that even those of us who are experts learn new things constantly whenever we get to participate in user testing.

Thanks!
Tim