WebAIM - Web Accessibility In Mind

E-mail List Archives

Re: empty list item

for

From: Jukka K. Korpela
Date: Jan 6, 2009 11:45AM


Patrick H. Lauke wrote:

> Unless I'm mistaken (can't test at the moment), screenreaders are
> likely to announce those empty list items. So, if you have
>
> <ul>
> <li>one</li>
> <li>two</li>
> <li></li>
> </ul>
>
> a screenreader would likely announce that there's a list with 3 items.
> This is likely to cause confusion or annoyance, I'd say.

That would be rather comparable to how common visual browsers render such
constructs: they display a bullet on a line of its own. This looks like an
error and indeed tends to cause confusion, annoyance, or suspicions.

If there is some need for something like an empty list item, there's
probably some placeholder text that could be put there, to prevent the
mystery effect. For example, <li>(to be added)</li>.

--
Yucca, http://www.cs.tut.fi/~jkorpela/