-
Notifications
You must be signed in to change notification settings - Fork 3.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
new synonym role tests #38941
new synonym role tests #38941
Conversation
Discussion in w3c/core-aam#166 is settling that the assertions in this PR are good, but I'll modify the file to use |
180432e
to
e364f98
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
From everything i saw you haven't been including html implicit role tests, I feel like you shouldn't introduce an implicit html role test in here.
Asserts computedrole for ARIA Core-AAM role synonyms - image/img - none/presentation - list/directory Related Issues: - web-platform-tests/interop-accessibility#10 - w3c/core-aam#166 Supporting Spec Change: - w3c/core-aam#167 Implementation Changes: - WebKit: https://webkit.org/b/224617 - Chromium: https://bugs.chromium.org/p/chromium/issues/detail?id=1428763 Reviewed By: - spectranaut: Valerie Young (Igalia)
<!-- spec resolution https://github.com/w3c/core-aam/issues/166 --> | ||
|
||
<div role="none" id="none" data-expectedrole="none" data-testname="none role == computedrole none" class="ex">x</div><!-- preferred --> | ||
<div role="presentation" id="presentation" data-expectedrole="none" data-testname="synonym presentation role == computedrole none" class="ex">x</div><!-- synonym --> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This requires browsers to return a computed role for this element even though it's not in the a11y tree because role="presentation"/"none" excludes it from the tree. We can fudge this with the DOM, but this seems wrong given that we're trying to test the browser's a11y implementation. In general, what are the expectations for computedRole for nodes which aren't in the a11y tree?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think "none" is the expected return value for these, whether they are not in the tree or whether they are ignored for some other reason. In either case, they have no role, right? But to be clear, I'm definitely open to rehashing that assumption if that doesn't work for Gecko.
Here are some related issues where I suspect you'll have an opinion.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Gecko currently returns null, but I can change that to anything: "", "none", whatever. However, it seems to me that there is a subtle difference between role="none" (one very specific way of removing an element from the a11y tree) vs the non-existence of an element in the a11y tree for one of several reasons (role="none", hidden, aria-hidden, ...). Could "none" lead people to think that this is specifically about role="none", when in reality, aria-hidden will return "none" as well?
That said, I don't want to bikeshed too much here. If WebKit and Chromium are happy with "none" for all cases of a11y non-existence, I can just change Gecko's WebDriver implementation to return "none" and move on.
resolves web-platform-tests/interop-accessibility#10