Components/Lists/Table
Interactive docs page: https://wix-pages.com/design-system-documentation/#/component/tablelistheader
Table list headers are used to provide column titles for custom list layouts.
<Card/> content into sections. Use <Card.Subheader/> instead.Table list headers can have any number of columns. The default column value is text, but it can be replaced with other component.
Set the header's background with the skin prop:
standard is the default and suits a header sitting on a card.neutral adds a tinted background, to separate the header from the rows beneath it.To define the required number of columns in a table, use the options array.
Specify the width of each column in pixels, percentages or frames with the width prop. If not specified, columns will be sized equally.
Control content alignment in a column with the align prop. It supports 3 options:
left (default)centerrightInclude additional info to explain data in a specific column by adding an info icon next to titles. Use infoTooltipProps to show a message that will be displayed in a tooltip on hover.
Add a checkbox that allows users to select all the items below the header with the checkboxState prop. It supports 6 values:
hidden (default)normalcheckedindeterminatehasErrordisabledAllow users to sort data displayed below the header by clicking on column titles with the sortable prop.
sortDescendingfor setting which arrow displays next to a column title.onSortChange is for defining behavior each time a user clicks on a title.Table list headers can be used to build custom table layouts, for example, a table that's divided into sections but still allows sorting and filter data.
| Name | Type | Default | Description |
|---|---|---|---|
checkboxState | "disabled" | "hidden" | "checked" | "normal" | "hasError" | "indeterminate" | — | State of Checkbox rendered at first column. 'hidden' to not render it. |
dataHook | string | — | Applies a data-hook HTML attribute that can be used in the tests. |
onCheckboxChange | () => void | — | Called when checkbox is clicked. |
onSortChange | (colNum: number, nativeEvent: MouseEvent<HTMLDivElement, MouseEvent>) => void | — | A callback function called on each column title click. Signature onSortChange(colNum, nativeEvent) |
options | TableListHeaderColumn[] | — | width supports px/%/fr sortable: Sets whether this field is sortable. If true, clicking the header calls onSortChange sortDescending: Sets what sort icon to display in the column header. true shows an up arrow, false shows a down arrow, undefined' shows no icon infoTooltipProps: Props object for column header's [tooltip](/?path=/story/components-api-components--tooltip). Note: dataHook, moveByandchildren` won't be passed to tooltip. |
ref | null | string | (instance: HTMLDivElement | null) => void | RefObject<HTMLDivElement> | — | Allows getting a ref to the component instance. Once the component unmounts, React will set ref.current to null (or call the ref with null if you passed a callback ref). |
reserveCheckboxSpace | boolean | false | Hides the checkbox without changing the layout when checkboxState is 'hidden'. Used for aligning header columns with TableListItem rows that show a checkbox. |
skin | "standard" | "neutral" | 'standard' | A way to switch between neutral and standard on the TableListHeader instead of Table. |
Import the driver matching your test environment:
| Method | Description |
|---|---|
getColumnTextAt | — |
toggleColumnSortAt | — |
getCheckbox | — |
exists | Checks whether the component found with the given data hook. |
element | Gets the component root element. |
click | Clicks on the component root element. |
base | Returns UniDriver for the base element. |
reserveCheckboxSpace prop that keeps the checkbox space when checkboxState is 'hidden', so header columns align with TableListItem rows that show a checkbox. (#17296) — has visual changesskin prop with standard and neutral values, so the header skin can be set directly instead of through Table. (#16783) — has visual changesLast updated: 22 October 2026