SimpleTableProps<T>
Type parameters
Name |
---|
T |
Hierarchy
-
TsMirrorProps
<T
>↳
SimpleTableProps
Table of contents
Properties
- asChild
- columnWidths
- density
- options
- renderDetail
- rowClick
- setSort
- sort
- sortable
- stickyColumn
- stickyHeader
Properties
asChild
• Optional
asChild: boolean
If true, the Table component will be rendered as a child of the Compose component
Default
false;
Inherited from
Defined in
packages/components/src/table/table.tsx:59 (opens in a new tab)
columnWidths
• Optional
columnWidths: string
[]
Array of column widths
When using the Table component
Default
[]
When using the SimpleTable component
Default
[repeat(${columns.length}, var(--sl-table-default-column-width))]
Inherited from
Defined in
packages/components/src/table/table.tsx:54 (opens in a new tab)
density
• Optional
density: "default"
| "comfortable"
| "compact"
The density of the table
Default
"default";
Inherited from
Defined in
packages/components/src/table/table.tsx:74 (opens in a new tab)
options
• Optional
options: Options
<T
>
Other TanStack/Table options
See
https://tanstack.com/table/v8/docs/api/core/table (opens in a new tab)
Defined in
packages/components/src/simple-table/simple-table.tsx:195 (opens in a new tab)
renderDetail
• Optional
renderDetail: (row
: Row
<T
>) => ReactNode
Type declaration
▸ (row
): ReactNode
Renders function for the detail row
Parameters
Name | Type |
---|---|
row | Row <T > |
Returns
ReactNode
Defined in
packages/components/src/simple-table/simple-table.tsx:199 (opens in a new tab)
rowClick
• Optional
rowClick: { getHref
: (row
: Row
<T
>) => string
; target?
: NavigationTarget
; type
: "link"
} | { onClick
: (row
: Row
<T
>) => void
; type
: "action"
}
Defined in
packages/components/src/simple-table/simple-table.tsx:216 (opens in a new tab)
setSort
• Optional
setSort: OnChangeFn
<SortingState
>
Setter for SortingState for controlled sort usage
Defined in
packages/components/src/simple-table/simple-table.tsx:212 (opens in a new tab)
sort
• Optional
sort: SortingState
SortingState for controlled sort usage
Defined in
packages/components/src/simple-table/simple-table.tsx:208 (opens in a new tab)
sortable
• Optional
sortable: boolean
Defines if columns will be sortable
Default
false;
Defined in
packages/components/src/simple-table/simple-table.tsx:204 (opens in a new tab)
stickyColumn
• Optional
stickyColumn: boolean
If true, the first column will be sticky
Default
false;
Inherited from
Defined in
packages/components/src/table/table.tsx:69 (opens in a new tab)
stickyHeader
• Optional
stickyHeader: boolean
If true, the header will be sticky
Default
false;
Inherited from
Defined in
packages/components/src/table/table.tsx:64 (opens in a new tab)