ColumnDefinition
A component used to add a column to a DataTable (e.g. QueuesStats․QueuesDataTable)
Component Properties#
| Name | Type | Description | Optional | Default |
|---|---|---|---|---|
| key | React.Key | Identifies the column definition. | No | |
| content | function | React.ReactNode | Renders cell content. If it's a function, it receives DataTable row data as the first argument and DataTable context as the second argument. The render function should return React.ReactNode. | No | |
| header | React.ReactNode | Header content. | No | |
| headerColSpanKey | string | Specify the same key for adjacent columns if you want to merge their headers. | Yes | |
| name | string | Column name is used to add custom classes to cells in the column. | Yes | |
| subHeader | React.ReactNode | Subheader content. | Yes | |
| sortingFn | function | A function that defines sort order. The function should return a negative, zero, or positive value. It receives data for two rows to sort as arguments. | Yes | |
| sortDirection | "asc" | "desc" | sort | Yes | |
| style | React.CSSProperties | style | Yes |
Rate this page