gregnb / gregnb/mui-datatables
customTableBodyFooterRender should include columnOrder
- Dominant language
- JavaScript
- Stars
- 2.7k
- Forks
- 906
- PR merge metrics
- No merged PRs in 30d
Description
The optional callback `customTableBodyFooterRender` includes `columns`, but not `columnOrder`. This is essential information if column reordering is allowed.
https://github.com/gregnb/mui-datatables/blob/master/src/MUIDataTable.js#L2050
Should be a very easy fix:
```
{this.options.customTableBodyFooterRender
? this.options.customTableBodyFooterRender({
data: displayData,
count: rowCount,
columns,
columnOrder, // <- add this line
selectedRows,
selectableRows: this.options.selectableRows,
})
: null}
```
Contributor guide
No contributing guide indexed for this repository
Research direction
Start in src/MUIDataTable.js around line 2050, where customTableBodyFooterRender is invoked, and inspect the callback payload alongside the existing columns value. Done means the callback receives columnOrder when column reordering is enabled, with the surrounding behavior unchanged.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, react
- Domain
- frontend
- Issue type
- Feature
- Difficulty
- 1/5
- Estimated time
- Under an hour
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 65/100