Re: Lists inside nav necessary?

The spec is clear about the ul element. It can even be completely empty to mark a place where multiple items might be - or one or none.

“
Permitted content       Zero or more <li><https://developer.mozilla.org/en-US/docs/Web/HTML/Element/li>, <script><https://developer.mozilla.org/en-US/docs/Web/HTML/Element/script> and <template><https://developer.mozilla.org/en-US/docs/Web/HTML/Element/template> elements.

And this makes completely sense. Think of a real world example:

A shopping list is a shopping list, even if there is no item on it yet.

--
Mit freundlichen Grüßen

Marc Haunschild
www.mhis.de

Am 11.06.2020 um 19:31 schrieb Guy Hickling <guy.hickling@gmail.com>:


There have been several mentions of lists of one item, a single item enclosed in a <ul> element. I fail this under SC1.3.1 because it is a fundamentally illogical structure that cannot show visually on a page. A list is by definition more than one item. Certainly screen reader users do not want a single link to be announced by "List of one item" followed by "end of list" afterwards; that is just useless noise for them. Sometimes of course it happens due to a search finding only one result, which is understandable, but developers frequently do it in other situations for no reason at all.

A common case of two links in a list is the "Previous" and "Next" links often seen in page navigation, as in pages in a sequential process. I am inclined to advocate putting them in a <ul> list element (all inside a <nav> element as well), and I do usually raise an issue for that. @Léonie, I would be interested in what you think of that and other short two item lists, since you made the  comment on this thread about lists in general.

Another very common scenario is a menu in the page footer followed by a copyright notice (with or without a link embedded in it), and the notice is often included in the list. The copyright actually has nothing to do with a list of links for the site navigation. I wouldn't include the copyright link in the <nav> element either, for a similar reason.

As to Jonathan's comment, "It seems like no matter which side I fall on an issue there is always someone saying I am either against the average user or an activist.", I know the feeling. Just try getting any kind of improvement or correction through in the WCAG 2.2 work! It has become impossible to achieve any kind of change to the proposed new SCs. It seems to me the default response on all issues raised is to immediately defend the current WG wording at all costs, and never mind bad logic, even bad grammar, or any attempts to make the new success criteria more understandable to the people (designers and developers) that will have to use them. So far as I can see the original aim of trying to do the very best for disabled people is clouded over by an auto-resistance to change. (Or maybe it is simply a dislike, these days, of the public comments process and comments coming from outside the WG?)

Unfortunately I think it is storing up a list of problems that a11y consultants are going to find difficult to defend or explain in the future. Which is a crying shame because the WCAG 2.1 project was managed totally differently.

Regards,
Guy Hickling

Received on Friday, 12 June 2020 06:36:20 UTC