Skip to content

Editorial · @csdr/editorial

Table

Numbered, captioned table wrapper. Markdown tables inside reports are auto-wrapped in a scroll container with sticky first column.

Import
import { Table } from '@csdr/editorial'
Use on
reports · docs

When to use

Small reference tables in reports (≤ ~15 rows). Larger data belongs in a bundle with a chart and a download. In MDX, wrap a Markdown table in <Table id caption units>; the table itself is auto-wrapped in a horizontal scroll container with a sticky first column and tabular numerals.

Numbered table

Table 1.Ecosystem extent by class.(thousand ha)
Class20152020Change
Mangroves35.136.0+0.9
Seagrass21.420.2−1.2

Source: Illustrative.

Code
<Table id="tab-summary" caption="Ecosystem extent by class." units="thousand ha" source="Illustrative.">

| Class | 2015 | 2020 | Change |
| --- | ---: | ---: | ---: |
| Mangroves | 35.1 | 36.0 | +0.9 |
| Seagrass | 21.4 | 20.2 | −1.2 |

</Table>