WebAIM - Web Accessibility In Mind

E-mail List Archives

Re: [External] :Smart search assistants

for

From: Birkir R. Gunnarsson
Date: Jul 15, 2022 1:13AM


Just make sure you include screen reader notification when results are
available. Ideally include the number of results available every time
you type a character. If not possible, at least a notification when
you have results and when you no longer have results, e.g. if you type
lax you might have 4 suggestions but if you type another x, laxx, you
probably have 0.
You can use a visually hidden element using the <output> element to
generate the announcement if you have the number
<label class="sr-only">
<output id="ra"> </output>
results available
</label>
(update the <output> element with a number generates a screen reader
status announcement).

Other than that, make sure you can use arrow down to open the
suggestions, arrows to navigate between suggestions, enter to select a
suggestion and escape to close the list without selecting one.

Selecting a suggestion will either populate the input with the
suggestion text and send your focus back there or execute that search
with that suggestion.

On 7/14/22, glen walker < <EMAIL REMOVED> > wrote:
> Whether you update as you type or after pressing ENTER is really a design
> decision and I would go with what your designers want to do. Hopefully
> they've done (or will do) research on what makes a pleasant user
> experience. It's great if they're asking for your help to make that
> experience accessible.
>
> On Thu, Jul 14, 2022 at 11:41 AM Don Mauck < <EMAIL REMOVED> > wrote:
>
>> I agree, however the designers want the results to happen without pressing
>> the inter key. I've argued this but I'm swimming up-stream on that one.
>>
>>
>>
> > > > >


--
Work hard. Have fun. Make history.