fluentui icon indicating copy to clipboard operation
fluentui copied to clipboard

[DetailsList] Announcing wrong number of rows for the DetailsList grid

Open harshil93 opened this issue 9 years ago • 4 comments

Are you willing to submit a PR to fix? Yes

Requested priority: High

Products/sites affected: VSTS

Describe the issue:

Wrong number of rows are announced for details list because aria-rowcount is set to number of rows + 1 ( probably it is including header also)

Actual behavior:

Announcing 501 rows

Expected behavior:

Should announce 500 rows

If applicable, please provide a codepen repro:

Can be repored on official fabric react website

image

harshil93 avatar Oct 09 '17 06:10 harshil93

aria-rowcount={ (isHeaderVisible ? 1 : 0) + (items ? items.length : 0) } The header is being counted only when it's visible. Should the header never be counted? Seems intentional in the code, but not sure what the standard is

erichdev avatar Oct 13 '17 18:10 erichdev

We ran into this as well. The keyboard behavior does not allow you to navigate to the header, so this seems wrong to us.

taylorcyoung avatar Feb 02 '18 00:02 taylorcyoung

I don't think this is a bug. Although the Fabric doesn't make the header keyboard navigable, screenreader users can use the screenreader to navigate to the header and read its contents. Check the examples from ARIA here, where Windows Narrator reads each grid as having n+1 rows, and example 3 explicitly sets aria-rowindex on the header to 1 and to 2 on the first data row. Thus aria-rowcount should be n+1 whenever a header is displayed.

dwilsonactual avatar Mar 20 '18 17:03 dwilsonactual

This issue sounds like it is resolved. Closing.

michaelangotti avatar Apr 09 '18 18:04 michaelangotti