@tanstack/table-core 8.5.24 → 8.5.26

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.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@tanstack/table-core",
3
3
  "author": "Tanner Linsley",
4
- "version": "8.5.24",
4
+ "version": "8.5.26",
5
5
  "description": "Headless UI for building powerful tables & datagrids for TS/JS.",
6
6
  "license": "MIT",
7
7
  "homepage": "https://github.com/tanstack/table#readme",
@@ -130,7 +130,7 @@ export const Pagination: TableFeature = {
130
130
  ? Number.MAX_SAFE_INTEGER
131
131
  : table.options.pageCount - 1
132
132
 
133
- pageIndex = Math.min(Math.max(0, pageIndex), maxPageIndex)
133
+ pageIndex = Math.max(0, Math.min(pageIndex, maxPageIndex))
134
134
 
135
135
  return {
136
136
  ...old,
package/src/filterFns.ts CHANGED
@@ -6,7 +6,7 @@ const includesString: FilterFn<any> = (
6
6
  filterValue: string
7
7
  ) => {
8
8
  const search = filterValue.toLowerCase()
9
- return row.getValue<string>(columnId)?.toLowerCase().includes(search)
9
+ return Boolean(row.getValue<string>(columnId)?.toLowerCase().includes(search))
10
10
  }
11
11
 
12
12
  includesString.autoRemove = (val: any) => testFalsey(val)
@@ -16,7 +16,7 @@ const includesStringSensitive: FilterFn<any> = (
16
16
  columnId: string,
17
17
  filterValue: string
18
18
  ) => {
19
- return row.getValue<string>(columnId)?.includes(filterValue)
19
+ return Boolean(row.getValue<string>(columnId)?.includes(filterValue))
20
20
  }
21
21
 
22
22
  includesStringSensitive.autoRemove = (val: any) => testFalsey(val)