-
-
Notifications
You must be signed in to change notification settings - Fork 655
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
Selected state isn't reported on treeitems #14352
Comments
Confirmed. NVDA is not communicating state of treeitem role using aria-selected. reference: treeitem role. NVDA does appropriately communicate state if using aria-checked but aria-selected is used for single selects in a tree role |
More information on an older duplicate: #8587 |
@prabhudevu - this screenshot seems unrelated to the issue. can you please explain more? |
We are following with product team and will response ASAP. |
Hi @seanbudd Sorry, Actually this bug is an external bug to https://dynamicscrm.visualstudio.com/OneCRM/_workitems/edit/3159230/ Issue is fixed in primary Bug and Environment. |
Are you sure we should close this? Our understanding was this was a legitimate bug, as per the duplicate #8587 |
Please don't close the bug if it is not fixed in the Environment which you used while logging the bug |
This issue also exists for role="treegrid". Repro here: |
hi @seanbudd sorry for the confusion this bug is external to a primary bug that still repro on azure devops |
Hi I'm still confused here @fsteffi Do you believe this is an issue with NVDA? As mentioned earlier, this appears to be related/duplicate of another valid issue with NVDA |
Related or might be duplicate of #11986. It seems NVDA does not honor aria_selected. cc: @michaelDCurran |
This is because of bugs in Firefox and Chromium: Firefox and Chromium are assuming the focus is also the selection, even though the spec says "If any DOM element in the widget is explicitly marked as selected, the user agent MUST NOT convey implicit selection for the widget." |
Maybe @jcsteh and @aleventhal can give some more insights on how this is handled in Firefox and Chromium. |
In theory, we could walk the accessibility tree, querying the aria attributes to find if aria-multipleselect is true, and if not, only honour the current focus as selected if no treeitem has aria-selected=true. But this will likely be slow and error-prone, and it's not supposed to be our responsibility anyway. |
@SaschaCowley Can you summarize what you think Chrome is doing wrong and how you would like things to work? We can look into making change but I want to make sure I understand how you want single selects to work vs multi selects. |
After reading this completely, I try to clarify where the problem exactly is:
Currently, when using object navigation NVDA reports "not selected" on the tree item "activities". But in browse mode, NVDA does not distinguish between selected and not selected attributes when having tree views. @SaschaCowley why does this work properly for tabs but not for trees? |
@aleventhal, my expectation would be:
From memory, both Firefox and Chrome were always communicating that focused descendents of selection containers were selected, unless |
Thanks Sascha, that's very helpful. I created a Google Doc where we can make sure we get all the details right before we implement. I added some Q's for you in the comments. For anyone else interested, here's the link: https://docs.google.com/document/d/1qDQfjDiqCgPiCJccIbOufncYhhBDiNW6XBLSc19jNMo/edit?tab=t.0 |
😩 This is one of those cases where I think the spec was written without considering implementation feasibility. Even on the browser side, this is going to have a significant performance cost in a sufficiently large container, regardless of whether aria-selected is specified on any item or not. Sure, we can try to cache container selection, but then we have to keep that cache up to date whenever items get added or removed or whenever the selection of any item changes, keeping in mind that a tree can have nested treeitems. Even so, that's what the spec has required for years and we've just never implemented it, so i guess it is what it is.
This is actually what both Firefox and Chrome already do:
If you focus the tree item, observe that it does not get the selected state. Interestingly, I don't see any support for this in the spec. Do either of you?
I agree this is what the spec says: undefined (default): The element is not selectable. I'd argue this contradicts the rule for single selection containers though. As above, if aria-selected isn't specified in a single selection container, we're supposed to just assume that means it isn't selected, not that it isn't selectable. aria-selected undefined says nothing about being relevant to multiple selection containers only. I think we'll need to get that fixed in the spec.
You're correct. |
Roles is the spec that are marked as having "aria-selected (required)" in their supported attribute table automatically get a default value of false for aria-selected if the attribute isn't present. I agree this is unclear. And it should only happen when the container is multiselectable. |
Implicit selection is where currently focused descendant or active descendant is treated as selected, in terms of the state and selection events. It is supported only in single selection containers. Changes to the ARIA spec have affected when it is supported: * tree/listbox: only support if none of the treeitems/options have an explicit aria-selected/aria-checked * tabpanel: only support if none of the tabs have an explicit aria-selected/aria-expanded * grid/treegrid: not supported (same as before) Tree updates: If aria-multiselectable changes on the container, or aria-selected/aria-checked changes on an option/treeitem, or aria-expanded/aria-selected changes on a tab, then mark their container as not supporting implicit selection, and mark everything dirty where the implicit selected state may have changed. Note: this is tricky in the tab case because when focus is inside a tabpanel controlled by a tab, implicit selection is on the tab, which has a somewhat indirect relation with the focus in the tree. Fixed: 1143451 Bug: nvaccess/nvda#14352 Change-Id: I117cb6210b1c35e976f3962cf17ea39ace7901e7 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6021043 Commit-Queue: Aaron Leventhal <aleventhal@chromium.org> Reviewed-by: Jocelyn Tran <jocelyntran@google.com> Cr-Commit-Position: refs/heads/main@{#1383813}
Ok, the single selection fixes should be in the next build of Chrome Canary. |
Oh, looks like i filed this bug against Firefox 7 months ago and forgot about it: |
Steps to reproduce:
code pen
TestSitemap.zip
Actual behavior:
NVDA is not announcing the state for tabs present under left side navigation panel.
Expected behavior:
NVDA should announcing the state for tabs present under left side navigation panel.
NVDA logs, crash dumps and other attachments:
System configuration
NVDA installed/portable/running from source:
installed
NVDA version:
2022.3
Windows version:
Version 21H2(OS Build 22000.1098)
Name and version of other software in use when reproducing the issue:
Microsoft Edge, Version 107.0.1418.35 (Official build) (64-bit)
Other information about your system:
Other questions
Does the issue still occur after restarting your computer?
yes
Have you tried any other versions of NVDA? If so, please report their behaviors.
no
If NVDA add-ons are disabled, is your problem still occurring?
Does the issue still occur after you run the COM Registration Fixing Tool in NVDA's tools menu?
The text was updated successfully, but these errors were encountered: