@tanstack/table-core 8.8.2 → 8.8.5
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/build/lib/columnHelper.js +0 -1
- package/build/lib/columnHelper.js.map +1 -1
- package/build/lib/features/ColumnSizing.js +2 -0
- package/build/lib/features/ColumnSizing.js.map +1 -1
- package/build/lib/features/Expanding.js +1 -1
- package/build/lib/features/Expanding.js.map +1 -1
- package/build/lib/features/RowSelection.js.map +1 -1
- package/build/lib/filterFns.js +6 -6
- package/build/lib/filterFns.js.map +1 -1
- package/build/lib/index.esm.js +9 -8
- package/build/lib/index.esm.js.map +1 -1
- package/build/lib/index.mjs +9 -8
- package/build/lib/index.mjs.map +1 -1
- package/build/lib/utils/getFacetedMinMaxValues.js.map +1 -1
- package/build/lib/utils/getSortedRowModel.js.map +1 -1
- package/build/umd/index.development.js +9 -8
- package/build/umd/index.development.js.map +1 -1
- package/build/umd/index.production.js +1 -1
- package/build/umd/index.production.js.map +1 -1
- package/package.json +1 -1
- package/src/features/Expanding.ts +3 -1
- package/src/features/RowSelection.ts +7 -7
- package/src/filterFns.ts +12 -3
- package/src/utils/getFacetedMinMaxValues.ts +1 -1
- package/src/utils/getSortedRowModel.ts +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getFacetedMinMaxValues.js","sources":["../../../src/utils/getFacetedMinMaxValues.ts"],"sourcesContent":["import { Table, RowData } from '../types'\nimport { memo } from '../utils'\n\nexport function getFacetedMinMaxValues<TData extends RowData>(): (\n table: Table<TData>,\n columnId: string\n) => () => undefined | [number, number] {\n return (table, columnId) =>\n memo(\n () => [table.getColumn(columnId)?.getFacetedRowModel()],\n facetedRowModel => {\n if (!facetedRowModel) return undefined\n
|
|
1
|
+
{"version":3,"file":"getFacetedMinMaxValues.js","sources":["../../../src/utils/getFacetedMinMaxValues.ts"],"sourcesContent":["import { Table, RowData } from '../types'\nimport { memo } from '../utils'\n\nexport function getFacetedMinMaxValues<TData extends RowData>(): (\n table: Table<TData>,\n columnId: string\n) => () => undefined | [number, number] {\n return (table, columnId) =>\n memo(\n () => [table.getColumn(columnId)?.getFacetedRowModel()],\n facetedRowModel => {\n if (!facetedRowModel) return undefined\n\n const firstValue =\n facetedRowModel.flatRows[0]?.getUniqueValues(columnId)\n\n if (typeof firstValue === 'undefined') {\n return undefined\n }\n\n let facetedMinMaxValues: [any, any] = [firstValue, firstValue]\n\n for (let i = 0; i < facetedRowModel.flatRows.length; i++) {\n const values =\n facetedRowModel.flatRows[i]!.getUniqueValues<number>(columnId)\n\n for (let j = 0; j < values.length; j++) {\n const value = values[j]!\n\n if (value < facetedMinMaxValues[0]) {\n facetedMinMaxValues[0] = value\n } else if (value > facetedMinMaxValues[1]) {\n facetedMinMaxValues[1] = value\n }\n }\n }\n\n return facetedMinMaxValues\n },\n {\n key:\n process.env.NODE_ENV === 'development' &&\n 'getFacetedMinMaxValues_' + columnId,\n debug: () => table.options.debugAll ?? table.options.debugTable,\n onChange: () => {},\n }\n )\n}\n"],"names":["getFacetedMinMaxValues","table","columnId","memo","_table$getColumn","getColumn","getFacetedRowModel","facetedRowModel","_facetedRowModel$flat","undefined","firstValue","flatRows","getUniqueValues","facetedMinMaxValues","i","length","values","j","value","key","process","env","NODE_ENV","debug","_table$options$debugA","options","debugAll","debugTable","onChange"],"mappings":";;;;;;;;;;;;;;;;AAGO,SAASA,sBAAsBA,GAGE;AACtC,EAAA,OAAO,CAACC,KAAK,EAAEC,QAAQ,KACrBC,UAAI,CACF,MAAA;AAAA,IAAA,IAAAC,gBAAA,CAAA;AAAA,IAAA,OAAM,CAAAA,CAAAA,gBAAA,GAACH,KAAK,CAACI,SAAS,CAACH,QAAQ,CAAC,KAAzBE,IAAAA,GAAAA,KAAAA,CAAAA,GAAAA,gBAAA,CAA2BE,kBAAkB,EAAE,CAAC,CAAA;AAAA,GAAA,EACvDC,eAAe,IAAI;AAAA,IAAA,IAAAC,qBAAA,CAAA;AACjB,I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AAAC,qBAAA,CAAA;AAAA,MAAA,OAAA,CAAAA,qBAAA,GAAMvB,KAAK,CAACwB,OAAO,CAACC,QAAQ,KAAAF,IAAAA,GAAAA,qBAAA,GAAIvB,KAAK,CAACwB,OAAO,CAACE,UAAU,CAAA;AAAA,KAAA;IAC/DC,QAAQ,EAAEA,MAAM,EAAC;AACnB,GAAC,CACF,CAAA;AACL;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getSortedRowModel.js","sources":["../../../src/utils/getSortedRowModel.ts"],"sourcesContent":["import { Table, Row, RowModel, RowData } from '../types'\nimport { SortingFn } from '../features/Sorting'\nimport { memo } from '../utils'\n\nexport function getSortedRowModel<TData extends RowData>(): (\n table: Table<TData>\n) => () => RowModel<TData> {\n return table =>\n memo(\n () => [table.getState().sorting, table.getPreSortedRowModel()],\n (sorting, rowModel) => {\n if (!rowModel.rows.length || !sorting?.length) {\n return rowModel\n }\n\n const sortingState = table.getState().sorting\n\n const sortedFlatRows: Row<TData>[] = []\n\n // Filter out sortings that correspond to non existing columns\n const availableSorting = sortingState.filter(sort =>\n table.getColumn(sort.id)?.getCanSort()\n )\n\n const columnInfoById: Record<\n string,\n {\n sortUndefined?: false | -1 | 1\n invertSorting?: boolean\n sortingFn: SortingFn<TData>\n }\n > = {}\n\n availableSorting.forEach(sortEntry => {\n const column = table.getColumn(sortEntry.id)\n if(!column) return\n\n columnInfoById[sortEntry.id] = {\n sortUndefined: column.columnDef.sortUndefined,\n invertSorting: column.columnDef.invertSorting,\n sortingFn: column.getSortingFn(),\n }\n })\n\n const sortData = (rows: Row<TData>[]) => {\n // This will also perform a stable sorting using the row index\n // if needed.\n const sortedData = [...rows]\n\n sortedData.sort((rowA, rowB) => {\n for (let i = 0; i < availableSorting.length; i += 1) {\n const sortEntry = availableSorting[i]!\n const columnInfo = columnInfoById[sortEntry.id]!\n const isDesc = sortEntry?.desc ?? false\n\n if (columnInfo.sortUndefined) {\n const aValue = rowA.getValue(sortEntry.id)\n const bValue = rowB.getValue(sortEntry.id)\n\n const aUndefined = typeof aValue === 'undefined'\n const bUndefined = typeof bValue === 'undefined'\n\n if (aUndefined || bUndefined) {\n return aUndefined && bUndefined\n ? 0\n : aUndefined\n ? columnInfo.sortUndefined\n : -columnInfo.sortUndefined\n }\n }\n\n // This function should always return in ascending order\n let sortInt = columnInfo.sortingFn(rowA, rowB, sortEntry.id)\n\n if (sortInt !== 0) {\n if (isDesc) {\n sortInt *= -1\n }\n\n if (columnInfo.invertSorting) {\n sortInt *= -1\n }\n\n return sortInt\n }\n }\n\n return rowA.index - rowB.index\n })\n\n // If there are sub-rows, sort them\n sortedData.forEach(row => {\n sortedFlatRows.push(row)\n if (row.subRows?.length) {\n row.subRows = sortData(row.subRows)\n }\n })\n\n return sortedData\n }\n\n return {\n rows: sortData(rowModel.rows),\n flatRows: sortedFlatRows,\n rowsById: rowModel.rowsById,\n }\n },\n {\n key: process.env.NODE_ENV === 'development' && 'getSortedRowModel',\n debug: () => table.options.debugAll ?? table.options.debugTable,\n onChange: () => {\n table._autoResetPageIndex()\n },\n }\n )\n}\n"],"names":["getSortedRowModel","table","memo","getState","sorting","getPreSortedRowModel","rowModel","rows","length","sortingState","sortedFlatRows","availableSorting","filter","sort","_table$getColumn","getColumn","id","getCanSort","columnInfoById","forEach","sortEntry","column","sortUndefined","columnDef","invertSorting","sortingFn","getSortingFn","sortData","sortedData","rowA","rowB","i","_sortEntry$desc","columnInfo","isDesc","desc","aValue","getValue","bValue","aUndefined","bUndefined","sortInt","index","row","_row$subRows","push","subRows","flatRows","rowsById","key","process","env","NODE_ENV","debug","_table$options$debugA","options","debugAll","debugTable","onChange","_autoResetPageIndex"],"mappings":";;;;;;;;;;;;;;;;AAIO,SAASA,iBAAiBA,GAEN;EACzB,OAAOC,KAAK,IACVC,UAAI,CACF,MAAM,CAACD,KAAK,CAACE,QAAQ,EAAE,CAACC,OAAO,EAAEH,KAAK,CAACI,oBAAoB,EAAE,CAAC,EAC9D,CAACD,OAAO,EAAEE,QAAQ,KAAK;AACrB,IAAA,IAAI,CAACA,QAAQ,CAACC,IAAI,CAACC,MAAM,IAAI,EAACJ,OAAO,IAAA,IAAA,IAAPA,OAAO,CAAEI,MAAM,CAAE,EAAA;AAC7C,MAAA,OAAOF,QAAQ,CAAA;AACjB,KAAA;AAEA,IAAA,MAAMG,YAAY,GAAGR,KAAK,CAACE,QAAQ,EAAE,CAACC,OAAO,CAAA;IAE7C,MAAMM,cAA4B,GAAG,EAAE,CAAA;;AAEvC;AACA,IAAA,MAAMC,gBAAgB,GAAGF,YAAY,CAACG,MAAM,CAACC,IAAI,IAAA;AAAA,MAAA,IAAAC,gBAAA,CAAA;AAAA,MAAA,OAAA,CAAAA,gBAAA,GAC/Cb,KAAK,CAACc,SAAS,CAACF,IAAI,CAACG,EAAE,CAAC,KAAA,IAAA,GAAA,KAAA,CAAA,GAAxBF,gBAAA,CAA0BG,UAAU,EAAE,CAAA;KACvC,CAAA,CAAA;IAED,MAAMC,cAOL,GAAG,EAAE,CAAA;AAENP,IAAAA,gBAAgB,CAACQ,OAAO,CAACC,SAAS,IAAI;MACpC,MAAMC,MAAM,GAAGpB,KAAK,CAACc,SAAS,CAACK,SAAS,CAACJ,EAAE,CAAC,CAAA;MAC5C,
|
|
1
|
+
{"version":3,"file":"getSortedRowModel.js","sources":["../../../src/utils/getSortedRowModel.ts"],"sourcesContent":["import { Table, Row, RowModel, RowData } from '../types'\nimport { SortingFn } from '../features/Sorting'\nimport { memo } from '../utils'\n\nexport function getSortedRowModel<TData extends RowData>(): (\n table: Table<TData>\n) => () => RowModel<TData> {\n return table =>\n memo(\n () => [table.getState().sorting, table.getPreSortedRowModel()],\n (sorting, rowModel) => {\n if (!rowModel.rows.length || !sorting?.length) {\n return rowModel\n }\n\n const sortingState = table.getState().sorting\n\n const sortedFlatRows: Row<TData>[] = []\n\n // Filter out sortings that correspond to non existing columns\n const availableSorting = sortingState.filter(sort =>\n table.getColumn(sort.id)?.getCanSort()\n )\n\n const columnInfoById: Record<\n string,\n {\n sortUndefined?: false | -1 | 1\n invertSorting?: boolean\n sortingFn: SortingFn<TData>\n }\n > = {}\n\n availableSorting.forEach(sortEntry => {\n const column = table.getColumn(sortEntry.id)\n if (!column) return\n\n columnInfoById[sortEntry.id] = {\n sortUndefined: column.columnDef.sortUndefined,\n invertSorting: column.columnDef.invertSorting,\n sortingFn: column.getSortingFn(),\n }\n })\n\n const sortData = (rows: Row<TData>[]) => {\n // This will also perform a stable sorting using the row index\n // if needed.\n const sortedData = [...rows]\n\n sortedData.sort((rowA, rowB) => {\n for (let i = 0; i < availableSorting.length; i += 1) {\n const sortEntry = availableSorting[i]!\n const columnInfo = columnInfoById[sortEntry.id]!\n const isDesc = sortEntry?.desc ?? false\n\n if (columnInfo.sortUndefined) {\n const aValue = rowA.getValue(sortEntry.id)\n const bValue = rowB.getValue(sortEntry.id)\n\n const aUndefined = typeof aValue === 'undefined'\n const bUndefined = typeof bValue === 'undefined'\n\n if (aUndefined || bUndefined) {\n return aUndefined && bUndefined\n ? 0\n : aUndefined\n ? columnInfo.sortUndefined\n : -columnInfo.sortUndefined\n }\n }\n\n // This function should always return in ascending order\n let sortInt = columnInfo.sortingFn(rowA, rowB, sortEntry.id)\n\n if (sortInt !== 0) {\n if (isDesc) {\n sortInt *= -1\n }\n\n if (columnInfo.invertSorting) {\n sortInt *= -1\n }\n\n return sortInt\n }\n }\n\n return rowA.index - rowB.index\n })\n\n // If there are sub-rows, sort them\n sortedData.forEach(row => {\n sortedFlatRows.push(row)\n if (row.subRows?.length) {\n row.subRows = sortData(row.subRows)\n }\n })\n\n return sortedData\n }\n\n return {\n rows: sortData(rowModel.rows),\n flatRows: sortedFlatRows,\n rowsById: rowModel.rowsById,\n }\n },\n {\n key: process.env.NODE_ENV === 'development' && 'getSortedRowModel',\n debug: () => table.options.debugAll ?? table.options.debugTable,\n onChange: () => {\n table._autoResetPageIndex()\n },\n }\n )\n}\n"],"names":["getSortedRowModel","table","memo","getState","sorting","getPreSortedRowModel","rowModel","rows","length","sortingState","sortedFlatRows","availableSorting","filter","sort","_table$getColumn","getColumn","id","getCanSort","columnInfoById","forEach","sortEntry","column","sortUndefined","columnDef","invertSorting","sortingFn","getSortingFn","sortData","sortedData","rowA","rowB","i","_sortEntry$desc","columnInfo","isDesc","desc","aValue","getValue","bValue","aUndefined","bUndefined","sortInt","index","row","_row$subRows","push","subRows","flatRows","rowsById","key","process","env","NODE_ENV","debug","_table$options$debugA","options","debugAll","debugTable","onChange","_autoResetPageIndex"],"mappings":";;;;;;;;;;;;;;;;AAIO,SAASA,iBAAiBA,GAEN;EACzB,OAAOC,KAAK,IACVC,UAAI,CACF,MAAM,CAACD,KAAK,CAACE,QAAQ,EAAE,CAACC,OAAO,EAAEH,KAAK,CAACI,oBAAoB,EAAE,CAAC,EAC9D,CAACD,OAAO,EAAEE,QAAQ,KAAK;AACrB,IAAA,IAAI,CAACA,QAAQ,CAACC,IAAI,CAACC,MAAM,IAAI,EAACJ,OAAO,IAAA,IAAA,IAAPA,OAAO,CAAEI,MAAM,CAAE,EAAA;AAC7C,MAAA,OAAOF,QAAQ,CAAA;AACjB,KAAA;AAEA,IAAA,MAAMG,YAAY,GAAGR,KAAK,CAACE,QAAQ,EAAE,CAACC,OAAO,CAAA;IAE7C,MAAMM,cAA4B,GAAG,EAAE,CAAA;;AAEvC;AACA,IAAA,MAAMC,gBAAgB,GAAGF,YAAY,CAACG,MAAM,CAACC,IAAI,IAAA;AAAA,MAAA,IAAAC,gBAAA,CAAA;AAAA,MAAA,OAAA,CAAAA,gBAAA,GAC/Cb,KAAK,CAACc,SAAS,CAACF,IAAI,CAACG,EAAE,CAAC,KAAA,IAAA,GAAA,KAAA,CAAA,GAAxBF,gBAAA,CAA0BG,UAAU,EAAE,CAAA;KACvC,CAAA,CAAA;IAED,MAAMC,cAOL,GAAG,EAAE,CAAA;AAENP,IAAAA,gBAAgB,CAACQ,OAAO,CAACC,SAAS,IAAI;MACpC,MAAMC,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rB,QAAQ,CAACC,IAAI,CAAC;AAC7BwC,MAAAA,QAAQ,EAAErC,cAAc;MACxBsC,QAAQ,EAAE1C,QAAQ,CAAC0C,QAAAA;KACpB,CAAA;AACH,GAAC,EACD;IACEC,GAAG,EAAEC,OAAO,CAACC,GAAG,CAACC,QAAQ,KAAK,aAAa,IAAI,mBAAmB;AAClEC,IAAAA,KAAK,EAAEA,MAAA;AAAA,MAAA,IAAAC,qBAAA,CAAA;AAAA,MAAA,OAAA,CAAAA,qBAAA,GAAMrD,KAAK,CAACsD,OAAO,CAACC,QAAQ,KAAAF,IAAAA,GAAAA,qBAAA,GAAIrD,KAAK,CAACsD,OAAO,CAACE,UAAU,CAAA;AAAA,KAAA;IAC/DC,QAAQ,EAAEA,MAAM;MACdzD,KAAK,CAAC0D,mBAAmB,EAAE,CAAA;AAC7B,KAAA;AACF,GAAC,CACF,CAAA;AACL;;;;"}
|
|
@@ -515,6 +515,8 @@
|
|
|
515
515
|
|
|
516
516
|
//
|
|
517
517
|
|
|
518
|
+
//
|
|
519
|
+
|
|
518
520
|
const defaultColumnSizing = {
|
|
519
521
|
size: 150,
|
|
520
522
|
minSize: 20,
|
|
@@ -821,7 +823,7 @@
|
|
|
821
823
|
table.setExpanded(defaultState ? {} : (_table$initialState$e = (_table$initialState = table.initialState) == null ? void 0 : _table$initialState.expanded) != null ? _table$initialState$e : {});
|
|
822
824
|
},
|
|
823
825
|
getCanSomeRowsExpand: () => {
|
|
824
|
-
return table.
|
|
826
|
+
return table.getPrePaginationRowModel().flatRows.some(row => row.getCanExpand());
|
|
825
827
|
},
|
|
826
828
|
getToggleAllRowsExpandedHandler: () => {
|
|
827
829
|
return e => {
|
|
@@ -925,19 +927,19 @@
|
|
|
925
927
|
};
|
|
926
928
|
|
|
927
929
|
const includesString = (row, columnId, filterValue) => {
|
|
928
|
-
var _row$getValue;
|
|
930
|
+
var _row$getValue, _row$getValue$toStrin, _row$getValue$toStrin2;
|
|
929
931
|
const search = filterValue.toLowerCase();
|
|
930
|
-
return Boolean((_row$getValue = row.getValue(columnId)) == null ? void 0 : _row$getValue.toLowerCase().includes(search));
|
|
932
|
+
return Boolean((_row$getValue = row.getValue(columnId)) == null ? void 0 : (_row$getValue$toStrin = _row$getValue.toString()) == null ? void 0 : (_row$getValue$toStrin2 = _row$getValue$toStrin.toLowerCase()) == null ? void 0 : _row$getValue$toStrin2.includes(search));
|
|
931
933
|
};
|
|
932
934
|
includesString.autoRemove = val => testFalsey(val);
|
|
933
935
|
const includesStringSensitive = (row, columnId, filterValue) => {
|
|
934
|
-
var _row$getValue2;
|
|
935
|
-
return Boolean((_row$getValue2 = row.getValue(columnId)) == null ? void 0 : _row$getValue2.includes(filterValue));
|
|
936
|
+
var _row$getValue2, _row$getValue2$toStri;
|
|
937
|
+
return Boolean((_row$getValue2 = row.getValue(columnId)) == null ? void 0 : (_row$getValue2$toStri = _row$getValue2.toString()) == null ? void 0 : _row$getValue2$toStri.includes(filterValue));
|
|
936
938
|
};
|
|
937
939
|
includesStringSensitive.autoRemove = val => testFalsey(val);
|
|
938
940
|
const equalsString = (row, columnId, filterValue) => {
|
|
939
|
-
var _row$getValue3;
|
|
940
|
-
return ((_row$getValue3 = row.getValue(columnId)) == null ? void 0 : _row$getValue3.toLowerCase()) === filterValue.toLowerCase();
|
|
941
|
+
var _row$getValue3, _row$getValue3$toStri;
|
|
942
|
+
return ((_row$getValue3 = row.getValue(columnId)) == null ? void 0 : (_row$getValue3$toStri = _row$getValue3.toString()) == null ? void 0 : _row$getValue3$toStri.toLowerCase()) === (filterValue == null ? void 0 : filterValue.toLowerCase());
|
|
941
943
|
};
|
|
942
944
|
equalsString.autoRemove = val => testFalsey(val);
|
|
943
945
|
const arrIncludes = (row, columnId, filterValue) => {
|
|
@@ -2947,7 +2949,6 @@
|
|
|
2947
2949
|
// helper.accessor('nested.bar', {
|
|
2948
2950
|
// cell: info => info.getValue(),
|
|
2949
2951
|
// })
|
|
2950
|
-
|
|
2951
2952
|
function createColumnHelper() {
|
|
2952
2953
|
return {
|
|
2953
2954
|
accessor: (accessor, column) => {
|