Releases: jbetancur/react-data-table-component
Releases · jbetancur/react-data-table-component
v8.4.0
8.4.0
New features
- Removable sorting — clicking a sorted header now cycles asc → desc → unsorted, so a sort can be cleared without reloading the page. → Sorting docs
- Multi-column sorting — new
sortMultiprop. Ctrl/⌘-click headers to build a sort stack; priority follows click order and a numbered badge marks each sorted column. → Sorting docs (#1325) SortColumn<T>type exported — represents a single entry in the sort stack ({ column, sortDirection }).onSortgains a fourthsortColumns: SortColumn<T>[]argument with the full sort config. Existing three-argument handlers are unaffected.
Behavior changes
- A third click on a sorted header now removes the sort (previously it stayed on descending). Server-side
onSorthandlers should treat an emptysortColumnsarray as "no sort" and drop theirORDER BY. This was always the intent buy 8.0.0 accidentally shipped without it
v8.3.0
New features
- Localization — new
localizationprop onDataTablereplaces the three separate option props (columnFilterOptions,expandableRowsOptions, and pagination aria-label fields onpaginationComponentOptions). Pass a single object to translate every string and aria-label in the table — filter panel, pagination navigation, and expand/collapse buttons. → Localization docs - Built-in locales — import pre-built translations from the
react-data-table-component/localessubpath. Ships with: English (en), French (fr), Spanish (es), German (de), Brazilian Portuguese (ptBR), Arabic — Modern Standard (ar), Egyptian (arEG), Levantine (arLV), Hebrew (he), Chinese Simplified (zhCN), Chinese Traditional (zhTW), Japanese (ja), Korean (ko), Ukrainian (uk). Each locale is individually tree-shakeable. - New utility exports:
emptyFilterState(type)andisFilterActive(filter). → Filtering docs
Deprecations
The following will continue to work in 8.x but will be removed in v9. TypeScript will show a deprecation hint.
columnFilterOptionsprop — uselocalizationwith afilterkey instead.expandableRowsOptionsprop — uselocalizationwith anexpandablekey instead.- Pagination aria-label fields on
paginationComponentOptions(navigationAriaLabel,firstPageAriaLabel,previousPageAriaLabel,nextPageAriaLabel,lastPageAriaLabel) — uselocalizationwith apaginationkey instead. ColumnFilterOptionsandExpandableRowsOptionstypes — useLocalization['filter']andLocalization['expandable']instead.
v8.2.0
What's Changed
- feat: implement clearSort functionality and add SortResetDemo example (#1320)
- feat: add onScroll prop to table API (#1319)
- feat: add pagination position feature with top, bottom, and both options (#1318)
- feat: add footer row support with customizable content (#1317)
- feat: add controlled paginationPage prop and update API documentation (#1316)
- chore: update issue templates and add contributing guidelines (#1315)
Full changelog: v8.1.0...v8.2.0
v8.1.0
Release Notes for v8.1.0
Additive feature release. No breaking changes.
See what's new for narrative coverage.
New features
- Inline editing now supports number, date, checkbox, and custom editor types.
New column-levelvalidatehook gates the edit beforeonCellEditfires.
→ Inline editing - Shift-click range selection on row checkboxes.
Enabled by default — opt out withselectableRowsRange={false}.
NewselectedRowsprop drives controlled selection.
→ Row selection - New headless export hook
useTableExport: build CSV/JSON, trigger a download, or copy to clipboard.
→ Export
Bug fixes & polish
- Expandable row open/close animation now works correctly.
Switched from a max-height tween (which appeared instant at realistic content heights) to the CSS gridgrid-template-rows: 0fr → 1frtrick, giving a true height transition.
Close animation added — the row stays mounted while animating out, then unmounts. Both directions respectanimateRowsandprefers-reduced-motion. - Fixed
useLayoutEffectSSR warning in Next.js App Router and Astro SSR modes.
The effect now falls back touseEffecton the server.
→ SSR - Inline editing: added CSS for checkbox and custom editor types, and validation error tooltip styles (
.rdt_cellEditError,.rdt_editErrorTip).
v8.0.1
v8.0.1
Patch release with internal improvements, dependency updates, and CI automation.
Bug Fixes & Improvements
- Memoization improvements — enhanced
useEffectanduseMemohooks across DataTable components to reduce unnecessary re-renders useIsomorphicLayoutEffect— introduced in column resizing logic for correct SSR behavioruseColorModesimplified — streamlined state management for color mode detection- Removed unused
onSortcallback fromuseTableStateto clean up internal props
Internal / DX
- ESLint upgraded — migrated from
.eslintrc.jsto flat config (eslint.config.js); updated all plugins to latest versions @testing-library/domadded as dev dependency;@testing-library/reactupdated- Test cleanup — removed unnecessary
eslint-disablecomments across test files; refactoredCheckboxto eliminateno-param-reassignsuppression - Linting scripts — simplified to remove file extension filtering from source directory
- Build — migrated from yarn to npm; removed
yarn.lock - CI — added automated release workflow with npm Trusted Publishing (OIDC)
v8.0.0: Refactor/v8 (#1308)
v8.0.0
This is a major release with significant breaking changes. It modernizes the library's internals, drops styled-components, and requires React 18+.
Breaking Changes
- React 18 minimum —
useId()anduseTransition()are now required styled-componentsremoved — replaced with plain CSS (DataTable.css) usingrdt_class namespace- CSS custom properties — theming now uses
--rdt-*CSS variables via thethemeprop;ThemeProvideris replaced byStylesContext clearSelectedRowsprop removed — replaced with an imperative ref API:useRef<DataTableHandle>→ref.current.clearSelectedRows()TablePropssplit — broken intoSelectionProps,PaginationProps,ExpandableProps, andSortPropsfilterValues/onFilterChange— now accept a structuredFilterStateobject instead of a plain stringdeepmergedependency removed — replaced with inlinemergeDeep<T>- Build output changed — rollup replaced with tsup; ships ESM + CJS + DTS; CSS is inlined into JS by default (no separate CSS import needed unless using the
./cssexport)
New Features
- Column visibility —
useColumnVisibilityhook with show/hide support - Column filter redesign —
FilterStatesupports multiple operators, conditions, and AND/OR logic toggles;filterTypeprop specifies input type per column - Column resize — extracted into
useColumnResizehook - Skeleton loading — built-in skeleton load state
- Middle-click row interactions — support for opening rows in a new tab
- Row selection —
keyFieldsupport withselectedIdSetfor improved performance HeadContext/RowContext— eliminates prop drilling inDataTableHeadaria-sort— added to sortable column headers for improved accessibilityTablePaginationFooterandColumnFiltercomponents addedDataTableHandletype exposes imperativeclearSelectedRows()API
Internal / DX
- Jest +
jest-styled-componentsreplaced with Vitest - Storybook replaced with Astro docs site
- Build migrated from rollup + yarn to tsup + npm
src/DataTable/restructured into flatsrc/components/layoutAction<T>discriminated union now includesColumnsAction<T>with exhaustiveness check
v7.7.1
v7.7.0
What's Changed
- Fix Markdown Tables in Storybook (Netlify) by @ADTC in #1204
- Fix width of table columns and fix some mistakes in Storybook (Netlify) by @ADTC in #1206
- Add support for table aria-label (accessibility) by @deiberchacon in #1273
- bump deps by @jbetancur in #1274
New Contributors
- @ADTC made their first contribution in #1204
- @deiberchacon made their first contribution in #1273
Full Changelog: v7.6.2...v7.7.0