Re: ARIA setsize attribute

On Dec 11, 2009, at 7:08 PM, Alexander Surkov wrote:

> I think aria-setsize can be calculated easy enough from aria-level
> attribute for the flat trees like
> 
> <div role="tree">
>  <div role="treeitem" aria-level="1">item1</div>
>  <div role="treeitem" aria-level="2">item1.1</div>
>  <div role="treeitem" aria-level="2">item1.2</div>
> <div role="treeitem" aria-level="1">item2</div>
> </div>

That's because you've completed the set of two. If all the tree items are in the DOM, you're right. It's not a problem, but the same heuristics would not be applicable to subgroups in XHR-loaded or otherwise DOM-loaded trees like this:

<!-- tree's set size ~10,000 -->
<div role="tree">
	<!-- this particular subgroup's set size ~300 --> 
	<!-- currently display only a few items out of the middle of a subset -->
	<div role="treeitem" aria-level="3" aria-posinset="153"> bop </div>
	<div role="treeitem" aria-level="3" aria-posinset="154"> bar </div>
	<div role="treeitem" aria-level="3" aria-posinset="155"> baz </div>
	<div role="treeitem" aria-level="3" aria-posinset="156"> bop </div>
</div>

Received on Saturday, 12 December 2009 03:20:36 UTC