@tanstack/react-table 8.3.0 → 8.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2156,7 +2156,7 @@ const RowSelection = {
2156
2156
  let isAllRowsSelected = Boolean(preFilteredFlatRows.length && Object.keys(rowSelection).length);
2157
2157
 
2158
2158
  if (isAllRowsSelected) {
2159
- if (preFilteredFlatRows.some(row => !rowSelection[row.id])) {
2159
+ if (preFilteredFlatRows.some(row => row.getCanSelect() && !rowSelection[row.id])) {
2160
2160
  isAllRowsSelected = false;
2161
2161
  }
2162
2162
  }
@@ -2179,7 +2179,8 @@ const RowSelection = {
2179
2179
  getIsSomeRowsSelected: () => {
2180
2180
  var _table$getState$rowSe;
2181
2181
 
2182
- return !table.getIsAllRowsSelected() && !!Object.keys((_table$getState$rowSe = table.getState().rowSelection) != null ? _table$getState$rowSe : {}).length;
2182
+ const totalSelected = Object.keys((_table$getState$rowSe = table.getState().rowSelection) != null ? _table$getState$rowSe : {}).length;
2183
+ return totalSelected < table.getCoreRowModel().flatRows.length;
2183
2184
  },
2184
2185
  getIsSomePageRowsSelected: () => {
2185
2186
  const paginationFlatRows = table.getPaginationRowModel().flatRows;