Component libraryData grid
Data grid
ProEdit and select consumer-owned records with contained spreadsheet keyboard movement.
npx shadcn@latest add @tidal-pro/data-gridInstallation
Pro source is gated. Configure the @tidal-pro registry using the agent guide. Create an access key from your account after purchasing.
Terminal
Import components/ui/tidal.css, components/ui/data-grid.css, then add the component inside a tidal-scope wrapper. Its scoped design tokens keep it independent of your existing CSS.
Usage
Complete example source · Dependency and asset manifest
Loading the complete example…
API & behavior
caption, rows, columns, getRowId, getRowLabel, controlled activeCell/onActiveCellChange, controlled editingCell/editValue/onEditingCellChange/onEditValueChange, and onCellCommit are required. Columns require unique nonblank IDs, exact accessible labels and consumer cell rendering; optional getEditValue enables one native text, email, number, URL or telephone editor. The localized editCell label names an editor unless its native props provide aria-label or aria-labelledby. Optional consumer error content is linked to the exact cell editor. Arrow keys move across the roving grid, logical left/right follow direction, Home/End move within a row, Enter/F2 begins editing, and Escape cancels without leaving the grid. Focus reveal is limited to the grid scroller. Optional controlled row selection uses native checkboxes and a consumer callback. Root/table/cell/editor/selection/save/cancel native attributes and refs are supported with owned values, markup, external form reassociation, availability and roving state excluded and runtime-stripped. disabled and readOnly preserve native control semantics. Consumers own validation, record updates, selection, sorting/filtering before rows are passed, persistence and all external effects. Column resizing/reordering, formulas, virtualization, clipboard access, network and storage are not bundled.
Style with the --t-* CSS variables. Set data-theme="dark" on your tidal-scope wrapper for a dark surface. Motion respects the system’s reduced-motion preference.