bkardell / common-panel

An effort to define a new element with clear semantics and separation
14 stars 3 forks source link

Remove aria-controls from basic panel prototype #3

Closed LJWatson closed 9 years ago

LJWatson commented 9 years ago

Suggest removing aria-controls from the common-panel-header div in the basic panel example. The header doesn't control the panel content (interacting with the header doesn't cause a change to the panel content).

bkardell commented 9 years ago

Currently what I have here is a constant recipe, but that might be not enough...

It's, at least theoretically possible that one could set attributes or properties for collapsing or removing a panel at runtime. We should be clear in the spec and make sure we create some IDL definition about whether those are [Reflect]. if we decide that those attributes should take effect if set later (I kind of think they should because, for example, you could place a panel into a panelset to add a tab - like you do in your browser and then it automatically has to become expandable/collapsable)

@LjWatson, I assume what we're saying is that if you have either attribute set the aria-controls is correct, otherwise it's not?

LJWatson commented 9 years ago

For the prototype panels that have expand/collapse capability, aria-controls would be appropriate. It needs to be applied to the focusable element that is the control though, rather than its parent container.

bkardell commented 9 years ago

so, the header part is focusable and it is the thing which says 'aria-controls' and that points to the content part which is also focusable and is the thing being aria-hidden/aria-expanded... Is that right?