[webkit-dev] Adding <main> element to WebCore
jcraig at apple.com
Thu Nov 29 17:08:51 PST 2012
On Nov 27, 2012, at 4:22 PM, Ian Hickson <ian at hixie.ch> wrote:
> ARIA is used by very few authors, and those authors are, by and large,
> much more competent than average. ARIA therefore tends to be used to a
> much higher level of quality than most elements.
Yet this is part of the problem. One of the reasons most of the Web is not very accessible is because you have to be an expert in order to code an accessible site. Part of the goal of HTML 5 (and WebKit for that matter) should be to make it easy for authors to include accessibility support without having to think about it.
> [<main>] would probably be used about as well, maybe a little less well than
> [<article>, <header>, <aside>] because the idea of what is "main" varies from author to author (e.g.
> in the sites you analysed on the WHATWG list, as well as in many that
> others have mentioned before, id="main" and id="content" often include
> things like some navigation, some headers, some sidebars, some footers).
This is valid, but if that's the worst case scenario, it's still exactly as good as the best-case scenario when there is no <main> element, so I don't really consider this to be much of an opposition. Besides, the "scooby doo" method could apply in those cases. If a <main> element contains <article>, <header>, <aside> or otherwise non-main content, browsers can it from what constitutes the "main" content.
More importantly, the <main> element gives us a node on which to hang the landmark AXSubrole: AXApplicationMain which enables landmark navigation in supporting screen readers like VoiceOver.
> The use case for e.g. <header> is mainly one of maintenance and styling:
> lots of people style their headers very specifically. In general it
> doesn't matter if one author marks his navigation as being part of his
> header and another marks his navigation using <nav>; the result is the
> same: they are clearly marked in the source, they can be styled, and they
> can be skipped. If one author doesn't use it, or even if most authors use
> it incorrectly, it doesn't mean that other authors can't use it.
> The use case for <main> is accessibility navigation.
It isn't true that the *only* use case is for accessibility. <main> is just as useful as a organizational maintenance and CSS styling hook as the <header> or <nav> elements.
> If authors use it
> incorrectly, the feature *doesn't work*. The element becomes pointless.
This is also not true. Whether or not the <main> element contained other non-main content, the end effect is more or less the same. Screen reader users using landmark navigation would jump to the beginning of the first piece of content in the <main> element. Nested landmarks work fine, too. I don't think this argument is valid.
> This is like the difference between <a href=""> and <img longdesc="">.
Please don't dredge that one up. I'm a vocal opponent of @longdesc, but this is nothing like @longdesc.
> If many authors use
> longdesc="" incorrectly, however, it means users who try to use the
> feature quickly stop expecting it to work and they give up and even pages
> that use it correctly lose out.
Regarding @longdesc, I agree, but relating this problem to <main> is FUD. Main is not some external content to be forgotten; it's just a tag surrounding the "main" contents of the page. Even if there are slightly differing views of what constitutes the main content, you still get mostly useful semantic, styling, and accessibility benefits from <main>
More information about the webkit-dev