You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am using the DataGrid component and when I run Accessibility Insights, I notice that aria-selected is applied to role=gridcell instead of on the input field inside of it.
Expected Behavior
I expect the aria attribute to be applied to the input field instead of the gridcell.
Hi @aubreyquinn this is a known issue, the following is the explanation:
aria-allowed-attribute error on DataGrid for aria-checked on select all gridcell
The aria-allowed-attr error for aria-checked is technically disallowed from role=gridcell, but we choose to include it for a few reasons
The supported selection attribute, aria-selected, does not support a mixed-state value, unlike aria-checked.
In general, we find better user feedback for checked semantics in multiselect scenarios
It does not cause any harm to add it to the gridcell. Even when it is not supported, the checkbox within the cell exposes the state.
These bugs should be marked as false positives if found through vendor testing or use the axe-core config to bypass those tests on those element selectors if using axe-core in a testing suite.
@aubreyquinn as Esteban mentioned, aria-checked is technically disallowed from role=gridcell, as the Accessibility Insights team said. However, there is no other allowed attribute that would support the information and interaction we use in the grid, which is why we've also been discussing adding it in the ARIA working group. Having it there does no harm and provides some practical benefit, which is why we have it (following the principal of prioritizing users over web authors over browser implementors over spec purity).
There's more information documented in our internal known issues wiki
Component
DataGrid
Package version
9.38.0
React version
17.0.2
Environment
Current Behavior
I am using the DataGrid component and when I run Accessibility Insights, I notice that
aria-selected
is applied torole=gridcell
instead of on the input field inside of it.Expected Behavior
I expect the aria attribute to be applied to the input field instead of the gridcell.
Reproduction
https://stackblitz.com/run?file=src%2Fexample.tsx
Steps to reproduce
Are you reporting an Accessibility issue?
yes
Suggested severity
Urgent - No workaround and Products/sites are affected
Products/sites affected
Power Platform Environment Settings
Are you willing to submit a PR to fix?
yes
Validations
The text was updated successfully, but these errors were encountered: