Tables use a composable architecture with a base class and optional modifiers. The base style is minimalistic — clean borders, no background fills — and modifiers layer on additional behaviour.

Structure

Every table needs two elements:

  1. A scroll wrapper () for horizontal overflow on small screens
  2. The table element with the base class
Name Type Status
Alpha Primary Active
Beta Secondary Pending
Gamma Tertiary Inactive
<div class="table-scroll">
  <table class="table">
    <thead>
      <tr>
        <th>Column</th>
        <th>Column</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td>Data</td>
        <td>Data</td>
      </tr>
    </tbody>
  </table>
</div>

Base Class

The class provides the default minimalistic style:

Property Value
Border collapse collapse
Width fit-content (max 100%)
Font size
Font variant tabular-nums
Header background Transparent
Header border var(--border-s) solid var(--border-secondary)
Body row border var(--border-s) solid var(--border-faded)
Cell padding var(--space-m) var(--space-l)

Modifiers

Modifiers are added alongside on the <table> element. They can be combined freely.

Class Effect
Sets width to 100%
Adds hover highlight on body rows
Adds background colour to header cells

Full Width

NameRole
AliceDesigner
BobDeveloper
<table class="table table-full">

Hoverable Rows

NameRole
AliceDesigner
BobDeveloper
CarolManager
<table class="table table-hover">

Filled Header

NameRole
AliceDesigner
BobDeveloper
<table class="table table-header-filled">

The <tfoot> element is styled automatically when inside a :

  • Top border: var(--border-m) solid var(--border-primary)
  • Header cells: bold weight
  • Data cells: semi-bold weight
ItemPrice
Widget£50
Gadget£75
Total£125
<table class="table table-full">
  <thead>
    <tr><th>Item</th><th>Price</th></tr>
  </thead>
  <tbody>
    <tr><td>Widget</td><td>£50</td></tr>
  </tbody>
  <tfoot>
    <tr><th>Total</th><td>£50</td></tr>
  </tfoot>
</table>

Combining Modifiers

Modifiers compose naturally. A full-featured table with hover, filled header, and footer:

ItemQtyPrice
Widget2£100
Gadget1£75
Doohickey3£60
Total6£235
<div class="table-scroll">
  <table class="table table-full table-hover table-header-filled">
    <thead>...</thead>
    <tbody>...</tbody>
    <tfoot>...</tfoot>
  </table>
</div>

Responsive Behaviour

Tables are mobile-friendly by default:

  • Horizontal scroll allows swiping when the table is wider than the viewport
  • Scroll hint — a subtle fade appears on the right edge when the table overflows, indicating more content. It disappears once the user scrolls to the end
  • Condensed padding — at 768px and below, cell padding and font size reduce automatically to fit more content on screen

No extra classes or markup are needed — this behaviour is built into and .


Markdown Tables

Tables generated from markdown (via the doc generator) automatically receive the class inside a wrapper. No manual class application is needed for documentation pages.


Do Not

  • Do not apply spacing or margins to directly — use the scroll wrapper or parent block for spacing
  • Do not create combined classes like — compose existing modifiers instead
  • Do not hardcode border or colour values — use the design system tokens

Was this page helpful?

We use this feedback to improve our documentation.

Thanks for your feedback