What's new Report an issue
GIG Cymru NHS Wales, Digital Health and Care Wales

Tables

Tabular clinical and administrative data. A tinted header row, a subtle divider between rows, and no rule under the header — the tint is what separates it.

No.PatientNHS numberDoBStatus
1JONES, Alis123 456 789006 Dec 1974Confirmed
2OWEN, Rhys234 567 890114 Mar 1988In review
3PATEL, Nia345 678 901202 Jul 1991Draft
<div class="sr-table-wrap">
  <table class="sr-table">
    <thead class="sr-table__head">…</thead>
    <tbody>
      <tr class="sr-table__row sr-table__row--selected">…</tr>
    </tbody>
  </table>
</div>

Row 2 shows the selected state; hover any row to see the hover surface. Dates use the d Mmm yyyy format, and the header uses the No. abbreviation exception.


Show clinical or administrative data in rows and columns so staff can scan, compare and act on it, patient lists, results, appointments, audit logs.


When to use

When not to use

How it works

Row states

StateTokenLightDark
Defaultsr.color.surface.section-cardswhiteblue.900
Hoversr.color.surface.subtleblue.50navy.700
Selected (--selected)sr.color.surface.accentcyan.100blue.900

Row dividers use sr.color.border.subtle. A selected row must also carry a non-colour signal (e.g. a persistent selection control or a left accent border), colour is never the only indicator (WCAG 1.4.1).

Options

OptionUse when
DefaultA plain data table with column headers only.
Selectable rows (--selected)One row is the active/selected entity, e.g. the current patient.
kebab-leftA row has many actions or space is tight, the menu holds them.
icons-leftOne or two frequent actions worth surfacing directly.
row-headersEach row names an entity the columns describe (observation × time).

Do & don't

DoDon't
Use the row-state tokens aboveHardcode a hover or selected background
Keep cells compact (Body S, 8px padding)Pad clinical tables so loosely they need scrolling
Give every icon-only action an aria-label naming action + subjectRely on colour alone to mark a selected row
Use No. for "Number" in a tight column headingIntroduce other abbreviations with full stops (write ECG, not E.C.G.)
Show dates as d Mmm yyyy (e.g. 10 Mar 2026)Use ambiguous all-numeric formats (06/12/21) in tables

Accessibility

Content

Frameworks

FrameworkStatusWhere
Web (HTML/CSS)Reference baselinepackages/web/src/table/table.css, .sr-table__* classes
ReactCurrentmirrors the sr-table__* markup
Blazor /.NETCurrentmirrors the sr-table__* markup via the RCL
.NET MAUIPlannedNative XAML, not a web view. Tokens available now; native styles in progress
Legacy (.NET 4.8 / Delphi)Tokens only / best-efforttoken CSS custom properties

Sorting, filtering and pagination are planned and not yet part of the reference,

Clinical / DHCW notes

The legacy. These map onto the kebab-left layout and the selectable-row / editable patterns respectively, carried forward, re-expressed against the token system. Chronology defaults to oldest-first with sortable columns.

Related

Accessibility requirements

RequirementWCAG SCHow Single Record meets itTest method
Semantic table structure1.3.1Real table, thead and th elements with a scope; a row-header layout adds a row-scoped header cell.Markup review, screen reader
Icon-only row actions are named4.1.2Each action names the action and its subject, for example "Edit Jones, Alis". Icons are hidden from assistive technology.Screen reader announce
Selected row not colour alone1.4.1Selected rows carry a non-colour signal such as a selection control or a left accent.Greyscale review
Target size for dense actions2.5.832×32px is a documented dense-desktop exception, promoted to full size on touch and mobile.Measure, touch device
Focus visible2.4.7A focus ring sits outside the action buttons so it is never clipped by the row.Keyboard tab