W3C home > Mailing lists > Public > w3c-wai-ig@w3.org > January to March 2017

recommended attribute use in hierarchies?

From: Rich Morin <rdm@cfcl.com>
Date: Sun, 5 Feb 2017 11:42:39 -0800
To: WAI Interest Group <w3c-wai-ig@w3.org>
Message-Id: <85BB1607-BB8C-4709-AD2B-EA53FB06B345@cfcl.com>
I have some newby questions on recommended attribute use in hierarchies.
Although I'm quite willing to generate any number of tags and attributes,
I'd rather not do so without understanding the reasons.

# Background

I'd like the widest possible range of screen readers to respond properly
to hierarchical content (eg, nested lists, headings).  Ideally, the user
should be able to determine the current level, navigate easily between
items, etc.

When I read this page:

  "ARIA in HTML"

I get the impression that UL, LI, H1-H6 tags already supply all the needed
information and that I shouldn't add ARIA attributes such as aria-level=1,
role='list', role='listitem', and role='heading'.  That is, no additional
attributes are either needed or desirable.

However, when I look at this example:

  "File Directory Treeview Example Using Declared Properties" 

I see several ARIA attributes being used in UL and LI elements:

- roles: group, tree, treeitem
- properties: aria-label, aria-level, aria-posinset, aria-setsize, tabindex
- states: aria-expanded

So, I'm quite confused about which attributes I should be including.  To
clarify, I'm happy to include any and all attributes which could be useful:

- I'll be generating the attributes mechanically.
- Bandwidth is unlikely to be an issue.

# Questions

Q: If I'm just generating static headings and lists, what attributes should
   I be including (and why)?

Q: If the example referenced above uses additional attributes, what is the
   reason for this?


http://www.cfcl.com/rdm           Rich Morin           rdm@cfcl.com
http://www.cfcl.com/rdm/resume    San Bruno, CA, USA   +1 650-873-7841

Software system design, development, and documentation
Received on Sunday, 5 February 2017 19:43:12 UTC

This archive was generated by hypermail 2.3.1 : Sunday, 5 February 2017 19:43:14 UTC