I just ran http://fae.cita.illinois.edu/ on /filter/tips and got the following errors:
The summary attribute value for each data table on a page should be unique. Warn: 2 data tables (out of 2 total) do not meet the criteria. Each th element in a complex data table must have an id attribute whose value is unique relative to all ids on the page. Fail: 3 th elements (out of 3 total in 1 complex data table) do not meet the criteria. Each td element in a complex data table must have a headers attribute that references the id attributes of associated th elements. Fail: 30 td elements (out of 30 total in 1 complex data table) do not meet the criteria.
Best practice is defined here - http://html.cita.illinois.edu/nav/dtable/
http://html.cita.illinois.edu/nav/dtable/
Comments
Comment #1
Jeff Burnz commentedSubscribe
Comment #2
mgiffordA bit more on this from FAE:
http://html.cita.illinois.edu/nav/dtable/
And then updated for HTML5:
http://www.w3.org/TR/html5/attributes-common-to-td-and-th-elements.html#...
It's ultimately just about adding more semantics to tables by default. Filter tips are presently pretty public if you allow comments - http://openconcept.ca/filter/tips
It's ultimately a matter of setting an ID in the TH element and then pointing to it in the TD element as an attribute like headers="header1".
Fixing this in core will again propagate a best practice in D8.
Comment #3
mgiffordPostponing this because ultimately the theme table needs to be able to support the scope and headers attributes.
http://tink.co.uk/2010/08/screen-reader-support-for-html-tables/
http://webaim.org/techniques/tables/data
Comment #4
mgiffordJust opened a new issue based on this tread - #1645308: Improve table semantics by adding scope or headers/id attributes to theme_table()
Comment #5
wim leersComment #6
mgiffordI don't think this would need to be postponed any more, but will probably need to get nudged back to 8.1.
Comment #7
mgiffordComment #23
mgiffordTagging for https://www.w3.org/WAI/WCAG21/Understanding/name-role-value
Comment #25
mgiffordI believe with https://www.drupal.org/project/drupal/issues/3505370 we can close this.