UI Library

DataTable

ID Name Status
p1CatalogActive
p2EditorActive
p3ViewerDraft
p4SyncActive
p5ArchiveActive
p6PortalDraft
p7LedgerActive
p8BillingActive
p9InvoicingDraft
p10PaymentsActive
p11ReceiptsActive
p12RefundsDraft
p13DisputesActive
p14SettlementsActive
p15ClearingDraft
p16TreasuryActive
p17CustodyActive
p18CollateralDraft
p19MarginActive
p20ExposureActive
Prop Type Default Value Notes
allSelectedboolean—
Header checkbox checked state. Interaction override; unset follows the selection.
batchActionsSnippet<[T[], () => void]>?——Batch actions in the toolbar row; receives the selected rows and a clear-selection callback.
bodyScrollboolean?false
Fixed header band with a body-only scrollport (needs fillHeight).
borderedbooleantrue
Card chrome (border, rounding, backdrop) on the viewer container.
chooserColumnsChooserColumn[]?—
Column selector entries; checked writes the hidden-column set.
chooserLabelstring?'Choose columns'
Accessible name for the column selector.
chooserResetLabelstring?'Reset columns'
Accessible name for the reset button.
containerClassNamestring?''
Extra classes for the outer container; built-in scroll/border chrome when unset.
densebooleanfalse
Compact padding for panel tables.
emptyMessagestring?'No rows'
Shown when rows is empty.
fillHeightboolean?false
Fills the parent; table body scrolls.
loadingbooleanfalse
Shows the spinner when there are no rows yet.
modelTableModel<T>?——Managed mode: a createTableModel controller supplies the filter, sort, page slice, selection, and footer; the model-backed props (rows, rowId, searchValue, sortKey, sortDirection, pagination, selectedIds, allSelected, someSelected) are then ignored.
resizablebooleanfalse
Draggable column resize handles.
resetWidthsSignalnumber?0
Rising signal: each new value drops managed and persisted widths.
rowsDemoRow[]—
Demo rows as JSON; the caller filters, sorts, and slices the current page. The eye resets to the default rows.
searchAriaLabelstring?'Search'
Accessible name for the search field.
searchKeysstring[]?—
Bindable searchable column keys; derived from searchable columns when unset. The eye applies the list.
searchPlaceholderstring?'Search...'
Search placeholder.
searchValuestring?''
Bindable search text; filtering stays with the caller. The eye resets it to the default.
selectAllAriaLabelstring?'Select all'
Accessible name for the header checkbox.
selectablebooleanfalse
Renders the checkbox column.
showPaginationbooleanpagination configured
Renders the pagination footer. Unset, the footer renders only when `pagination` supplies its data and onPageChange.
showSearchbooleantrue
Renders the search field.
size'xs' | 'sm' | 'md' | 'lg' | 'xl' | number'md'
Cell text, padding, selection count, and the table’s own column floors scale with the search, chooser, selection, and pagination chrome; numbers are icon-scale pixels.
someSelectedboolean—
Header checkbox indeterminate state. Interaction override; unset follows the selection.
sortDirection'asc' | 'desc''asc'
Bindable sort direction; the eye resets it to the default; clearing restores the default.
sortKeystring?null
Bindable active sort column. The eye resets it to the default.
storageKeystring?—
Persists resized widths under this key.
storagePrefixstring?—
App-owned localStorage prefix for the persisted widths; the package prefix stays the read fallback.
tableClassNamestring?'min-w-0'
Extra classes for the table element; raise the minimum width when columns need a horizontal scroll floor.
toolbarSnippet<[T[], () => void]>?——Leading toolbar content in the batch row (operational buttons); receives the selected rows and a clear-selection callback.
toolbarEndSnippet<[T[], () => void]>?——Trailing toolbar content, after the built-in selection actions (typically Refresh).
variant'data' | 'docs''data'
Presentation: the paged viewer, or the static docs table with a plain wrapper, non-sticky header, and no row hover.
columnsDataTableColumn<T>[]——Column defs with optional cell renderers.
paginationDataTablePagination?——Footer config: total/pageSize/currentPage plus onPageChange gate the footer; onPageSizeChange adds the page-size selector; pageSizeOptions customizes its choices; labels overrides the aria labels; trailing is a snippet pinned to the row’s right edge.
rowId(row: T) => string——Stable key per row.
selectedIdsSet<string>?——Selected row ids; managed by the caller.
selectionActionsfalse | { fileName?, rows? }managed: on—Built-in Export/Clear pair: JSON of the selected rows with an optional export mapper. On by default in managed mode; opt-in in controlled mode, where Clear needs onClearSelection.
selectionCountPosition'start' | 'end''end'
Where the selected-count summary sits in the toolbar row.
onClearSelection() => void——Controlled-mode handler for the built-in Clear action; managed mode clears through the model.
onResetColumns() => void——Reset handler; the caller also bumps resetWidthsSignal to drop resized widths.
onSearchInput(event: Event) => void——Search input handler.
onSearchKeydown(event: KeyboardEvent) => void——Search keydown handler.
onSort(key, direction) => void——Sort handler; or bind sortKey/sortDirection.
onToggleAll() => void——Select-all handler for the header checkbox.
onToggleColumn(key, checked) => void——Column visibility handler.
onToggleSelection(id: string, checked: boolean) => void——Row-selection handler; pair with selectedIds.
resizeAriaLabel(column) => string——Accessible name for the resize handles.
rowSelectAriaLabel(row: T) => string——Accessible name for each selectable row checkbox.
sortAriaLabel(column, direction) => string——Accessible name for the sort buttons.