Follow-up from #1251738: Allow ability to set table caption.

Problem/Motivation

Allow for users to better describe table details for better usability and accessibility.

Proposed resolution

Either a nested summary and details tag in the caption element:

Summary and details

<table>
<caption>
  Population of Cities in California in 2010
  <details>
   <summary>Largest cities in California</summary>
   Populations of the largest cities in California listed from largest to smallest, with recorded population in the right column.
  </details>
</caption>
...
</table>

Making Tables More Accessible With HTML5

or

aria-decribedby

<p id="summary">In the following table, characteristics are 
given in the second column, with the negative side in the left column and the positive
side in the right column.</p>
<table aria-describedby="summary">
 <caption>Characteristics with positive and negative sides</caption>
 <thead>
  <tr>
   <th id="n"> Negative
   <th> Characteristic
   <th> Positive
 <tbody>
  <tr>
   <td headers="n r1"> Sad
   <th id="r1"> Mood
   <td> Happy
  <tr>
   <td headers="n r2"> Failing
   <th id="r2"> Grade
   <td> Passing
</table>

4.9.1.1 Techniques for describing tables

Comments

sjbassett’s picture

Title: Create » Allow for better description of tables
mgifford’s picture

Issue tags: -a11y +Accessibility

Just changing the tags to be consistent.

lolandese’s picture

Status: Active » Closed (duplicate)
Related issues: +#2301003: tfoot & caption tag support