TableHead
The header section of a Table. Renders <thead> and provides TableSectionContext = 'head', which makes descendant TableCells render as <th scope="col">.
The header section of a Table. Renders <thead> and provides TableSectionContext = 'head',
which makes descendant TableCells render as <th scope="col">.
<Table>
<TableHead>
<TableRow>
<TableCell>Name</TableCell>
</TableRow>
</TableHead>
</Table>
Demos
For usage examples, visit the component demo page: Table
Import
import { TableHead } from '@soroush.tech/design-system/Table'Props
| Prop | Type | Default | Description |
|---|---|---|---|
color | keyof Theme['text'] | - | Text color. |
bg | keyof Theme['background'] | - | Background color. |
as | ElementType | 'thead' | Overrides the root element. |
Also supports styled-system space and border props.
Source code
If this page does not answer your question, have a look at the implementation of the component for more detail.