Description
During the meeting where we presented the menu elements proposal for incubation (minutes) (explainer), @scottaohara raised the topic of navigation menu bars (https://www.w3.org/WAI/ARIA/apg/patterns/menubar/examples/menubar-navigation/) being particularly thorny, and being a different beast than what I'll call the "normal menubar" use case, which is described by https://www.w3.org/WAI/ARIA/apg/patterns/menubar/examples/menubar-editor/.
In particular, see these lines from the minutes:
sorvell: navigation is a deep can of worms, people have strong opinions about navigations and menus
...
scott: im going to talk about navigation use case
scott: that is one thats on the apg and is the most contentious
scott: one of the reasons that navigation use case is not preferred is that menuitems are not navigable using screenreaders. theyre meant to be treated like navigation to menus in macos windows etc
scott: as far how theyre used on the web and used for navigation purporses, they can make finding what youre looking for harder for screenreader users because you cant just bring up a list of hyperlink
scott: if the navigation menubar is to go forward, we would need to do work thats never been done before to make this a thing that is not just another way of saying menu
...
scott: i am not opposed to it moving forward, but theres a lot of work moving forward
scott: if its just going to be menu but it has type=nav but no actual difference then we havent helped anyone
Somewhere in the minutes I say:
dom: thanks, i understand why its a big deviation
...but either I was wrong at the time, or I've forgotten. Some of us at Google have been trying to understand how the navigation use case is so different form the "normal (editor example) menubar" use case. Even if we decide navigation is too scary to tackle right away, I still think we need to have this discussion because I fear if we don't design something for this use case, developers will just use the "normal menubar" primitives to achieve this, by stuffing navigating actions/commands in each <menuitem>
, thus ossifying a poor accessibility experience.
So I think we have a few questions, much of which we intend to discuss at the next meeting:
- Why is the navigation use case different?
- The real question here I think is: what would need to be semantically distinct in a
<navbar>
from<normalmenubar>
in order to make<navbar>
suitable for the navigation use case? What's the real delta between these - @scottaohara mentions "they can make finding what youre looking for harder for screenreader users because you cant just bring up a list of hyperlink", but I don't fully understand this. Why can you just "bring up a list of hyperlinks"? In the non-navigation menubar case, we're certainly going to "just bring up a list of menuitems"—does that have the same accessibility concerns?
- The real question here I think is: what would need to be semantically distinct in a
- Is it actually bad if developers manually navigate the page in response to
<menuitem>
clicks? This could be done - Multi-page app vs single-page app: I can imagine developers implementing SPA navigations with a normal menubar that responds to
<menuitem>
activations to swap in new content, since they don't need traditional anchor semantics. Is the "SPA use case" considered the same as the "navigation use case", and would it be a bad outcome if developers this? MPAs and SPAs have the same navigation intent: show new content to the user when they click something, but they do this very differently. Is the "navigation intent" what's scary about the navigation use case? Or is it just the raw-anchor-tags-inside-of-the-menuitem MPA case that's scary about the navigation use case?