TableView.columns
property · packages/mixins-ui/src/table.ts:123
readonly columns: ReadonlyArray<TableColumn<Row>>Mixins / foldkit-mixins-ui
interface · packages/mixins-ui/src/table.ts:122
interface TableView<Row, Message = never> {
readonly columns: ReadonlyArray<TableColumn<Row>>
readonly rows: ReadonlyArray<Row>
readonly caption?: string | undefined
readonly rowKey?: ((row: Row) => string) | undefined
readonly sort?:
| {
readonly by: Option.Option<TableSort>
readonly onSort: (column: string) => Message
}
| undefined
readonly selection?: TableSelection<Row, Message> | undefined
readonly expansion?: TableExpansion<Row, Message> | undefined
readonly empty?: Html | undefined
readonly style?: NamedStyle<typeof TableSlots> | undefined
readonly mixins?: MixinList<Message> | undefined
readonly fluid?: boolean | undefined
}A plain table in one call: columns with per-row values, the rows, an
optional caption, a style for its slots, and mixins beside the style. No
upstream component stands behind it, except the checkboxes, which are
@foldkit/ui's.
TableView.columnsproperty · packages/mixins-ui/src/table.ts:123
readonly columns: ReadonlyArray<TableColumn<Row>>TableView.rowsproperty · packages/mixins-ui/src/table.ts:124
readonly rows: ReadonlyArray<Row>TableView.captionproperty · packages/mixins-ui/src/table.ts:125
readonly caption?: string | undefinedTableView.rowKeyproperty · packages/mixins-ui/src/table.ts:127
readonly rowKey?: ((row: Row) => string) | undefinedEach row's key, so a sorted row keeps its element; by default its place.
TableView.sortproperty · packages/mixins-ui/src/table.ts:129
readonly sort?:
| {
readonly by: Option.Option<TableSort>
readonly onSort: (column: string) => Message
}
| undefinedThe sort the rows are drawn in, and the Message a press on a sortable heading sends.
TableView.selectionproperty · packages/mixins-ui/src/table.ts:136
readonly selection?: TableSelection<Row, Message> | undefinedA checkbox on every row, and one in the heading for all of them.
TableView.expansionproperty · packages/mixins-ui/src/table.ts:137
readonly expansion?: TableExpansion<Row, Message> | undefinedTableView.emptyproperty · packages/mixins-ui/src/table.ts:139
readonly empty?: Html | undefinedDrawn across the table while there are no rows: an Empty.view, say.
TableView.styleproperty · packages/mixins-ui/src/table.ts:141
readonly style?: NamedStyle<typeof TableSlots> | undefinedA style of TableSlots, for the table's look.
TableView.mixinsproperty · packages/mixins-ui/src/table.ts:143
readonly mixins?: MixinList<Message> | undefinedMixins beside the style.
TableView.fluidproperty · packages/mixins-ui/src/table.ts:149
readonly fluid?: boolean | undefinedOne highlight behind the body rows, following the pointer, and the lit
row marked data-fluid-lit. Off by default: its Mount sends no
Message, which a Scene test would have to resolve.