Skip to content

Table

<ts-table> vv0.6.3

A styled wrapper for native HTML tables. Consumers place standard <table>, <thead>, <tbody>, <tr>, <th>, <td> elements inside.

Uses light DOM (no Shadow DOM) so nested table elements can be styled directly via the component’s CSS.

Open in Storybook for interactive demos.

<ts-table selectedRows="[]" sort-direction="none">Content</ts-table>
PropertyAttributeTypeDefaultDescription
borderedborderedbooleanfalseAdds borders to all cells.
compactcompactbooleanfalseReduces cell padding for denser display.
hoverablehoverablebooleanfalseHighlights rows on hover.
selectableselectablebooleanfalseEnables row selection with checkboxes.
selectedRowsstring[][]Array of selected row values (matches data-value on <tr>).
sortColumnsort-columnstring | undefinedThe column identifier currently sorted by (matches data-column on <th>).
sortDirectionsort-direction"asc" | "desc" | "none"'none'The current sort direction.
sortablesortablebooleanfalseEnables column sorting on header click.
stickyHeadersticky-headerbooleanfalseMakes the table header stick to the top on scroll.
stripedstripedbooleanfalseApplies alternating row background colors.
EventDetailBubblesComposedDescription
tsSelectionChange\{ selectedRows: string[]; \}YesYesEmitted when row selection changes.
tsSort`{ column: string; direction: “desc""asc”; }`YesYes
NameDescription
*(default)*Default slot for the native <table> element.
<ts-table selectedRows="[]" sort-direction="none">Content</ts-table>
import { TsTable } from '@tessera-ui/react';
<TsTable selectedRows="[]" sortDirection="none">Content</TsTable>