ui5-select: AXE issue for ui5-select
Describe the bug Required ARIA attribute not present: aria-expanded. Required ARIA child role not present: textbox
To reproduce Steps to reproduce the behavior:
- Go to https://github.wdf.sap.corp/pages/xweb/goalmanagementx/app.html?mock#/goal-list
- click 'Skip Tour' button
- click more actions button on the top right of Goal Card
- click 'Create Activity' button
- Find the last ui5-select on the popup and you will see the issue
Screenshots

Context
- UI5 Web Components version: 0.29.4
- OS/Platform: {...}
- Browser (if relevant): {...}
- Other information: {...}
We are facing the same issue in our unit test case for ui5-select
`expect(received).toHaveNoViolations(expected)
Expected the HTML found at $('#regions-select,div[aria-label="Preferred\ Region"]') to have no violations:
<div class="ui5-select-label-root" role="combobox" aria-haspopup="listbox" tabindex="0" aria-label="Preferred Region" aria-required="false"><!---->Asia Pacific<!----></div>
Received:
"Required ARIA attributes must be provided (aria-required-attr)"
Fix any of the following:
Required ARIA attribute not present: aria-expanded
You can find more information on this issue here:
https://dequeuniversity.com/rules/axe/3.5/aria-required-attr?application=axeAPI
Expected the HTML found at $('#regions-select,div[aria-label="Preferred\ Region"]') to have no violations:
<div class="ui5-select-label-root" role="combobox" aria-haspopup="listbox" tabindex="0" aria-label="Preferred Region" aria-required="false"><!---->Asia Pacific<!----></div>
Received:
"Certain ARIA roles must contain particular children (aria-required-children)"
Fix any of the following:
Required ARIA child role not present: textbox`
Following is the actual markup for the select element
<ui5-select data-testid="regions-select" data-name="regionID" id="regions-select" aria-labelledby="regions-label">
{regions.map((region) => (
<ui5-option value={region.regionID} key={region.regionID}>
{region.description || region.regionID}
</ui5-option>
))}
</ui5-select>
Hello colleagues,
the ui5-select component is missing an aria-expanded attribute https://sap.github.io/ui5-webcomponents/master/playground/components/Select/. I see that the classic ui5 select control has it https://ui5.sap.com/#/entity/sap.m.Select/sample/sap.m.sample.Select but i cannot find it in the acc spec.
My guess is that the presence if this attribute is essential, but could you please check and take action?
Thanks and kind regards, Tereza
FYI @SAP/ui5-webcomponents-topic-p
Hello @GongRichard,
the first issue about aria-expanded is no longer reported.
About the second issue:
ui5-select is implemented according to Select-Only aria 1.2 example and it's complaint with the ARIA specification, which does not require a textbox element to be nested in. (https://w3c.github.io/aria-practices/examples/combobox/combobox-select-only.html)
Kind Regards, Dobrin
We need to extend the aria-roledescription to reflect that this represents and is called a select element
given that, we have 2 options:
- aria-roledescription = "select combobox" with role=combobox
- aria-roledescription = "listbox combobox" with role=combobox
I would opt for 1) since it represents the name of the control/documentation in both frameworks as a convention. Besides, it sounds less confusing.
Hello, as discussed we will add aria-roledescription="select combobox" attribute to the select.
This was discussed again with the accessibility team and the term "Listbox" is the more appropriate one as the term "ComboBox" describes multiple ways of changing the selected value.