Open scottaohara opened 2 years ago
Generally agree that for items that do not allow children (or element children, or not-specific element children) it should be disallowed.
Is it worth also looking at if it should also be disallowed for nesting interactive elements/roles (which are not form controls)?
I also wonder about form
itself. I didn't test, but I'm guessing that a form control that is not inside its form is not going to be included in the form's submission... even if it is pointed to by aria-owns
.
yes, it would not be included @carmacleod. That particular use case might fall into a warning territory, as an authors could very well use aria-owns
on a form that points to a form control, or its container, but if the control has a form
attribute associating it with the form, then everything should be ok.
if the control has a form attribute associating it with the form, then everything should be ok.
Good point, but then I guess we'd need to look out for aria-owns
conflicting with a form control's form
attribute? Yuk.
Anyhow, you're right that aria-owns
should still be allowed on the form
element.
Where
aria-owns
can have practical use cases for fully custom ARIA implementations of form controls, I question the validity of this attribute on the current set of native HTML form controls.Taking into consideration that
input
elements cannot have descendants in HTML, and for form controls liketextarea
andselect
which do allow for text or options, respectively, usingaria-owns
with these elements either doesn't do anything (select
) or doesn't do anything with a positive benefit (e.g., Firefox will pull in the text from a referenced element, and announce it as if it was part of the entered value of the textarea / input, but this would not actually be part of the actual control's value, and it cannot be "deleted", which would be problematic for users).So, I'm presently of the opinion that this allowance serves no practical purpose, and could even make for broken experiences, in my quick testing. But, interested if maybe I'm missing out on a use case that someone has / is actually relying on? Or, at least relying on outside of Webkit since
aria-owns
isn't even supported there yet.