role="list", Safari and VoiceOver

Hi,

Some time ago I came across this blog post: https://www.scottohara.me/blog/2019/01/12/lists-and-safari.html and this tweet: https://twitter.com/rogerjohansson/status/1083600157076324352

Since then I'm adding role="list" to the lists that have list-style: none applied.

However, the w3c validator show a warning: "The list role is unnecessary for element ul."

In the web design agency I'm working I'm asked to produce error/warning free html code.

So my questions are:

- Which CSS properties/values remove list semantics apart from list-style: none? For example: does display: flex remove list semantics?
- What's your approach around this issue? Do you use role="list" on lists with list-style: none?
- Since O'Hara's post is from 2019, I wonder if VoiceOver/Safari approach is still the same.

Thanks.

--
Bernat Lleonart

Enviat amb h [ProtonMail](https://protonmail.com/) correu segur.

Received on Friday, 29 April 2022 14:27:03 UTC