Data table
Data tables are used to present data sets in a simple and organized way. Unlike standard HTML Table, it is responsive and compatible with all the screen sizes.
Examples
Chi Vue
Props
Property | Description | Interface | Default |
---|---|---|---|
config | To customize Data table behavior and style | { columnResize?: | undefined |
dataTableData | To provide Data Table with Head and Body related data | { head: { [code: string]: { label: | undefined |
Interfaces and types
Name | Interface |
---|---|
DataTableRow | interface DataTableRow { active: |
DataTableStyleConfig | interface DataTableStyleConfig { portal?: |
DataTableSortConfig | interface DataTableSortConfig { direction: |
DataTableEmptyActionableConfig | interface DataTableEmptyActionableConfig { isActionable?: |
DataTableSizes | 'xs' | 'sm' | 'md' | 'lg' | 'xl' |
DataTableColumnDescription | interface DataTableColumnDescription { title?: |
DataTableAction | interface DataTableAction: { label: |
Methods
Method | Description | Returns | Parameters |
---|---|---|---|
toggleRow() => void | To expand / collapse specific rows. | Type: void | row: { rowId: string } action?: 'expand' | 'collapse' |
print() => void | To print the data table | Type: void | title: string |
Events
Event | Description | Type |
---|---|---|
chiDataSorting | The user has sorted the table by a specific column | { column: |
chiPageChange | The user changed active page | { page: |
chiRowExpanded | The user expanded a row | DataTableRow |
chiRowClick | The user clicks in a row | DataTableRow |
chiRowCollapsed | The user collapsed a row | DataTableRow |
chiSelectAll | The user selected all the rows on the page | DataTableRow[] |
chiSelectThisPage | The user selected all the rows on the page | DataTableRow[] |
chiDeselectAll | The user deselected all the rows on the page | DataTableRow[] |
chiDeselectThisPage | The user deselected all the rows on the page | DataTableRow[] |
chiSelectAllPages | The user selected all the rows on the table | DataTableRow[] |
chiDeselectAllPages | The user deselected all the rows on the table | DataTableRow[] |
chiRowSelected | The user selected a row | DataTableRow |
chiRowDeselected | The user deselected a row | DataTableRow |
chiShowSelectedRowsOnly | The user selected show selected only from bulk actions | DataTableRow[] |
chiCancel | The user cancelled bulk actions | undefined |
chiExpandAll | The user expands all the rows on the page | DataTableRow[] |
chiCollapseAll | The user collapses all the rows on the page | DataTableRow[] |
chiEmptyActionableLink | The user clicks the empty actionable link | undefined |
Accessibility
Accessibility guidelines coming soon