AHG 2026: Accessibility Agents

Tables and Data Specialist reference: Visual Data Grids Without Semantic Markup

In the kit: .github/skills/tables-data-specialist/references/visual-data-grids-without-semantic-markup.md.

Copy it into ChatGPT or another assistant

Read the plain text first

Tables and Data Specialist reference: Visual Data Grids Without Semantic Markup

Part of the tables-data-specialist skill. Read this only when the task reaches these sections.

Visual Data Grids Without Semantic Markup

CSS grid and flexbox layouts often display structured data (stats, metrics, KPIs, dashboards, pricing cards) that looks tabular or structured visually but uses only <div>/<span> elements. Screen readers linearize these into undifferentiated text.

The Problem

<!-- PROBLEMATIC: looks structured visually, but screen readers read
     "47 Specialized Agents 3 Platforms 52 Prompts" as one long line -->
<div class="stats-grid">
  <div>
    <span class="stat-number">47</span>
    <span class="stat-label">Specialized Agents</span>
  </div>
  <div>
    <span class="stat-number">3</span>
    <span class="stat-label">Platforms</span>
  </div>
</div>

The Fix: Use <dl> for Key-Value Pairs

When data presents label-value pairs (stat dashboards, profile fields, spec lists, pricing highlights):

<dl class="stats-grid">
  <div class="stat-item">
    <dt class="stat-label">Specialized Agents</dt>
    <dd class="stat-number">47</dd>
  </div>
  <div class="stat-item">
    <dt class="stat-label">Platforms</dt>
    <dd class="stat-number">3</dd>
  </div>
</dl>

Use CSS order: -1 on <dd> if the value should display above the label visually while keeping the label first in DOM order for screen readers.

When to Use <table> Instead

If the data has multiple dimensions (rows AND columns), use a proper <table>. <dl> is for flat key-value lists.

What to Flag

  • Any CSS grid or flexbox container with 3+ child elements where each child has a "label" and "value" pattern using only <div>/<span>
  • Stats bars, KPI dashboards, pricing highlights, feature counts, metric summaries using only generic elements
  • Any visual grid of structured data without <dl>, <table>, or ARIA table/grid roles

Validation Checklist

Structure

  1. Is <table> used for tabular data (not layout)?
  2. Does the table have a <caption> or aria-label?
  3. Are header cells <th> (not styled <td>)?
  4. Do column headers have scope="col" and row headers scope="row"?
  5. Are <thead>, <tbody>, and <tfoot> used correctly?
  6. For complex tables: are headers attributes correct?
  7. For merged cells: do colspan/rowspan have correct header associations?

Sorting

  1. Do sortable columns have aria-sort attributes?
  2. Is aria-sort updated when sort changes?
  3. Are sort buttons inside <th> elements?
  4. Is the sort change announced (live region or aria-sort update)?

Interactive

  1. Do interactive tables use role="grid" appropriately?
  2. Do interactive elements in cells have descriptive aria-label with context?
  3. Does the select-all checkbox handle the indeterminate state?
  4. Are row selections indicated with aria-selected?
  5. Are selection count changes announced?

Responsive

  1. Is the table scrollable on mobile with role="region" and tabindex="0"?
  2. Or does the stacked pattern retain header context per cell?
  3. Are hidden columns properly hidden (not just aria-hidden)?

Pagination

  1. Does pagination have aria-current="page" on the current page?
  2. Are page changes announced via live region?
  3. Is focus managed after page changes?
  4. Is the "showing X of Y" text linked via aria-describedby?

General

  1. Are empty states communicated with descriptive messages?
  2. Are layout tables avoided (or marked with role="presentation")?
  3. Do CSS grid/flexbox layouts displaying structured data use <dl>, <table>, or ARIA roles (not bare <div>/<span>)?

Common Mistakes You Must Catch

  • CSS grid/flexbox layouts displaying key-value data (stats, metrics, KPIs) with only <div>/<span> -- use <dl>/<dt>/<dd> for label-value pairs
  • Using <div> grids styled to look like tables - screen readers cannot navigate them as tables
  • <td> elements styled bold to look like headers - use <th> with scope
  • Missing <caption> - screen readers announce "table" with no description
  • scope attribute on <td> elements (only valid on <th>)
  • aria-sort on all columns simultaneously instead of just the active sort column
  • Sort buttons outside the <th> (breaks header/button association)
  • role="grid" on non-interactive data tables (adds unnecessary complexity for screen readers)
  • Responsive tables that hide columns visually (off-screen or zero size) without display: none, so screen readers still read them, or with aria-hidden alone, so they stay visible
  • Inline edit controls without aria-label context ("Edit" button in 50 rows - edit what?)
  • Pagination without aria-current="page" - screen reader hears identical "1", "2", "3" buttons
  • Empty tables with no message - user doesn't know if data is loading or missing

Structured Output for Sub-Agent Use

When invoked as a sub-agent by the web-accessibility-wizard, consume the ## Web Scan Context block provided at the start of your invocation - it specifies the page URL, framework, audit method, thoroughness level, and disabled rules. Honor every setting in it.

If the audit context indicates no tables are present, return an empty findings array immediately, with a notes entry saying no table audit was needed. Do not spend time searching for tables that don't exist.

Return only JSON matching skills/a11y-core/schemas/findings.schema.json (see examples/findings.json) so the wizard can aggregate, deduplicate, and score results. Each finding carries rule, wcag (for example 1.3.1 A, or n/a), severity, location, summary, fix and, when not high, confidence. Put the offending markup in evidence.

Confidence rules:

  • high - definitively wrong: <table> without <caption> or aria-label, <th> without scope, sortable column without aria-sort
  • medium - likely wrong: table structure appears correct but may have header/data association issues that need browser testing to confirm
  • low - possibly wrong: complex headers/id attribute relationships that need screen reader testing to verify

The wizard counts findings from the JSON for its progress announcements, so do not add a prose summary.