Table
Render table with theme styles
Import
Source
Docs
Package
Usage
Table data for all examples:
| Element position | Element name | Symbol | Atomic mass |
|---|---|---|---|
| 6 | Carbon | C | 12.011 |
| 7 | Nitrogen | N | 14.007 |
| 39 | Yttrium | Y | 88.906 |
| 56 | Barium | Ba | 137.33 |
| 58 | Cerium | Ce | 140.12 |
Spacing
To control spacing use horizontalSpacing and verticalSpacing props. Both props support spacing from theme.spacing and number values to set cell padding in px:
| Position | Name | Symbol | Mass |
|---|---|---|---|
| 6 | Carbon | C | 12.011 |
| 7 | Nitrogen | N | 14.007 |
| 39 | Yttrium | Y | 88.906 |
| 56 | Barium | Ba | 137.33 |
| 58 | Cerium | Ce | 140.12 |
HorizontalSpacing
xs
sm
md
lg
xl
VerticalSpacing
xs
sm
md
lg
xl
FontSize
xs
sm
md
lg
xl
Caption and tfoot
Table support tfoot and caption elements. Set captionSide prop (top or bottom) to change caption position.
| Element position | Element name | Symbol | Atomic mass |
|---|---|---|---|
| 6 | Carbon | C | 12.011 |
| 7 | Nitrogen | N | 14.007 |
| 39 | Yttrium | Y | 88.906 |
| 56 | Barium | Ba | 137.33 |
| 58 | Cerium | Ce | 140.12 |
| Element position | Element name | Symbol | Atomic mass |
Striped and rows hover
| Element position | Element name | Symbol | Atomic mass |
|---|---|---|---|
| 6 | Carbon | C | 12.011 |
| 7 | Nitrogen | N | 14.007 |
| 39 | Yttrium | Y | 88.906 |
| 56 | Barium | Ba | 137.33 |
| 58 | Cerium | Ce | 140.12 |