Skip to content

The selected 'options' for the combobox are not announced as 'selected' by NVDA #18224

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

Open
ashankggupta opened this issue Jun 6, 2025 · 0 comments

Comments

@ashankggupta
Copy link

Summary
The selected option of the combobox is not announced as "selected" although aria-selected is set to "TRUE" on the element with role="option".

Actual Result:
The selected option of the combobox is not announced as "selected" while the options with aria-selected="false" are also not announced as 'not selected'.

Expected Result:
Ensure that "selected" and "not selected" states are announced for the selected and not selected option of the combobox.
NOTE: aria-checked attribute is alsi used with the items having aria-selected="true" attribute as a fallback to indicate the selected state.

Additional Information
We have aria-selected and aria-checked attributes to enhance accessibility and provide a consistent user experience across different operating systems.

On Windows, the native select element changes its value as you navigate through options using the arrow keys, without needing to press Enter. However, on Mac, users must press Enter to confirm their selection after navigating with the arrow keys.

Our combobox follows the Mac behavior, requiring users to press Enter to confirm their choice. The aria-selected attribute is used to indicate the currently highlighted option as you navigate through the list. Additionally, a visual check mark is displayed on the selected value, which only moves when Enter is pressed. We use the aria-checked attribute to communicate this visual check mark.

Code Snippet:
<div id="listbox-id-6" class="slds-dropdown slds-dropdown_length-5 slds-dropdown_fluid" role="listbox" aria-label="{{Placeholder for Dropdown Items}}" tabindex="0" aria-busy="false"> <ul class="slds-listbox slds-listbox_vertical" role="presentation"> <li role="presentation" class="slds-listbox__item"> <div **aria-selected="true" aria-checked="true"** id="option208" class="slds-media slds-listbox__option slds-listbox__option_plain slds-media_small slds-is-selected slds-has-focus" role="option"><span class="slds-media__figure slds-listbox__option-icon"><span class="slds-icon_container slds-icon-utility-check slds-current-color"><svg class="slds-icon slds-icon_x-small" aria-hidden="true"><use xlink:href="/assets/icons/utility-sprite/svg/symbols.svg#check"></use></svg></span></span><span class="slds-media__body"><span class="slds-truncate" title="Accounts">Accounts</span></span></div> </li>

....

Operating System and version
Windows 10

Browser and version:
Chrome 136.0.7103.114 (64-bit)

Name and version of other software in use when reproducing the issue: NVDA version 2024.4.1 (2024.4.1.34550)

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. - Yes, the Behavior is same with NVDA 2025

If NVDA add-ons are disabled, is your problem still occurring? - Did not try it

Does the issue still occur after you run the COM Registration Fixing Tool in NVDA's tools menu? - Did not try it

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant