v0.1.1
Release Notes — v0.1.1
New Features
Frozen/Pinned Columns
Columns marked with fixed = true and an explicit width are now pinned to the left edge of the table and remain visible during horizontal scrolling.
Multi-Column Sort
Ctrl+click column headers to sort by multiple columns simultaneously. Use the new multiSortBy and onMultiSortChange parameters alongside the existing single-sort API.
Column Resizing
Enable resizableColumns = true to let users drag column edges to resize. Use minColumnWidth to set a lower bound, and DataTableState.resetColumnWidths() to revert to defaults.
Keyboard Navigation
The table is now focusable and supports Arrow Up/Down to move between rows, Enter to trigger onRowClick, Space to toggle selection, and Home/End to jump to the first or last row.
Selection Modes
A new SelectionMode enum (NONE, SINGLE, MULTI) replaces the implicit multi-select behavior previously tied to showSelect. The showSelect parameter remains for backwards compatibility.
Right-Click Context Menu
New onRowContextMenu: (T, Offset) -> Unit callback fired on right-click, providing the item and the pointer position.
DataTableState
New state holder created via rememberDataTableState(). Supports programmatic animateScrollToItem(index) and resetColumnWidths().
Items-Per-Page Selector
The pagination footer now includes a page-size picker. Configure available options with itemsPerPageOptions and respond to changes via onItemsPerPageChange.
Enhancements
- Alternating row colors — set
colors.rowAlternatefor zebra-striped rows. - Row hover highlight — set
colors.hoveredRowfor a mouse-over tint. - Focused row border — set
colors.focusedRowBorderto highlight the keyboard-focused row. - Per-column text overflow —
DataTableHeadernow acceptsmaxLinesandoverflow(TextOverflow) to control cell text truncation. - Custom sort comparator — set
DataTableHeader.comparatorto override the defaultComparable-based sort for a column. - Column visibility toggle — set
DataTableHeader.visible = falseto hide a column without removing it from the header list. - Multi-sort takes precedence over single-sort when both are provided.
Bug Fixes
- Global row index was not tracked correctly across groups, causing mismatched focus and selection highlights in grouped tables.
- Horizontal scrollbar was duplicated (rendered for both header and body) when
showScrollbars = trueand frozen columns were not in use.
Breaking Changes
DataTableRowandDataTableHeaderRownow requireselectionMode,rowIndex,isFocused,state, andonContextMenuparameters. If you are calling these internal composables directly, update your call sites.TableDividerandenableTrackpadHorizontalScrollare nowinternal. They were previouslyprivatebut accessible in the same module — direct external use is no longer supported.
Full Changelog: 0.1.0...0.1.1