diff --git a/_artifacts/domain_map.yaml b/_artifacts/domain_map.yaml index 4e8ba5973d..d15ad1023f 100644 --- a/_artifacts/domain_map.yaml +++ b/_artifacts/domain_map.yaml @@ -1,6 +1,6 @@ library: name: '@tanstack/table' - version: '9.0.0-beta.42' + version: '9.0.0-beta.43' repository: 'https://github.com/TanStack/table' homepage: 'https://tanstack.com/table' description: 'Headless, framework-agnostic data-grid state and row-processing primitives with tree-shakeable v9 features and framework adapters.' diff --git a/_artifacts/skill_tree.yaml b/_artifacts/skill_tree.yaml index 9917556af0..f22be40a29 100644 --- a/_artifacts/skill_tree.yaml +++ b/_artifacts/skill_tree.yaml @@ -1,6 +1,6 @@ library: name: '@tanstack/table' - version: '9.0.0-beta.42' + version: '9.0.0-beta.43' repository: 'https://github.com/TanStack/table' description: 'Headless data-grid state and row processing with tree-shakeable v9 features and framework adapters.' package_version_overrides: diff --git a/docs/reference/index/interfaces/Row_Core.md b/docs/reference/index/interfaces/Row_Core.md index 872292e610..b4aebd3b84 100644 --- a/docs/reference/index/interfaces/Row_Core.md +++ b/docs/reference/index/interfaces/Row_Core.md @@ -37,13 +37,27 @@ Defined in: [core/rows/coreRowsFeature.types.ts:12](https://github.com/TanStack/ *** +### \_displayIndexCache + +```ts +_displayIndexCache: number; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:16](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L16) + +#### Inherited from + +[`Row_Row`](Row_Row.md).[`_displayIndexCache`](Row_Row.md#_displayindexcache) + +*** + ### \_uniqueValuesCache ```ts _uniqueValuesCache: Record; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:16](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L16) +Defined in: [core/rows/coreRowsFeature.types.ts:17](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L17) #### Inherited from @@ -57,7 +71,7 @@ Defined in: [core/rows/coreRowsFeature.types.ts:16](https://github.com/TanStack/ _valuesCache: Record; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:17](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L17) +Defined in: [core/rows/coreRowsFeature.types.ts:18](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L18) #### Inherited from @@ -71,7 +85,7 @@ Defined in: [core/rows/coreRowsFeature.types.ts:17](https://github.com/TanStack/ depth: number; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:21](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L21) +Defined in: [core/rows/coreRowsFeature.types.ts:22](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L22) The depth of the row (if nested or grouped) relative to the root row array. @@ -87,7 +101,7 @@ The depth of the row (if nested or grouped) relative to the root row array. getAllCells: () => Cell[]; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:63](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L63) +Defined in: [core/rows/coreRowsFeature.types.ts:69](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L69) Builds one cell for each leaf column, including cells for hidden columns. @@ -107,7 +121,7 @@ Builds one cell for each leaf column, including cells for hidden columns. getAllCellsByColumnId: () => Record>; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:59](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L59) +Defined in: [core/rows/coreRowsFeature.types.ts:65](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L65) Builds a lookup of this row's cells keyed by leaf column id. @@ -121,13 +135,34 @@ Builds a lookup of this row's cells keyed by leaf column id. *** +### getDisplayIndex() + +```ts +getDisplayIndex: () => number; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:61](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L61) + +Returns the zero-based index of the row in the current display order +before pagination, or `-1` if the row is not in that model. + +#### Returns + +`number` + +#### Inherited from + +[`Row_Row`](Row_Row.md).[`getDisplayIndex`](Row_Row.md#getdisplayindex) + +*** + ### getLeafRows() ```ts getLeafRows: () => Row[]; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:67](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L67) +Defined in: [core/rows/coreRowsFeature.types.ts:73](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L73) Returns the leaf rows for the row, not including any parent rows. @@ -147,7 +182,7 @@ Returns the leaf rows for the row, not including any parent rows. getParentRow: () => Row | undefined; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:71](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L71) +Defined in: [core/rows/coreRowsFeature.types.ts:77](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L77) Returns the parent row for the row, if it exists. @@ -167,7 +202,7 @@ Returns the parent row for the row, if it exists. getParentRows: () => Row[]; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:75](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L75) +Defined in: [core/rows/coreRowsFeature.types.ts:81](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L81) Returns the parent rows for the row, all the way up to a root row. @@ -187,7 +222,7 @@ Returns the parent rows for the row, all the way up to a root row. getUniqueValues: (columnId) => TValue[]; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:79](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L79) +Defined in: [core/rows/coreRowsFeature.types.ts:85](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L85) Reads the values this row contributes to faceting/grouping for a column. @@ -219,7 +254,7 @@ Reads the values this row contributes to faceting/grouping for a column. getValue: (columnId) => TValue; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:83](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L83) +Defined in: [core/rows/coreRowsFeature.types.ts:89](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L89) Reads this row's accessor value for a column id and caches the result. @@ -251,7 +286,7 @@ Reads this row's accessor value for a column id and caches the result. id: string; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:25](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L25) +Defined in: [core/rows/coreRowsFeature.types.ts:26](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L26) The resolved unique identifier for the row resolved via the `options.getRowId` option. Defaults to the row's index (or relative index if it is a subRow). @@ -267,7 +302,7 @@ The resolved unique identifier for the row resolved via the `options.getRowId` o index: number; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:29](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L29) +Defined in: [core/rows/coreRowsFeature.types.ts:30](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L30) The index of the row within its parent array (or the root data array). @@ -283,7 +318,7 @@ The index of the row within its parent array (or the root data array). original: TData; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:33](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L33) +Defined in: [core/rows/coreRowsFeature.types.ts:34](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L34) The original row object provided to the table. If the row is a grouped row, the original row object will be the first original in the group. @@ -299,7 +334,7 @@ The original row object provided to the table. If the row is a grouped row, the optional originalSubRows: readonly TData[]; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:37](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L37) +Defined in: [core/rows/coreRowsFeature.types.ts:38](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L38) An array of the original subRows as returned by the `options.getSubRows` option. @@ -315,7 +350,7 @@ An array of the original subRows as returned by the `options.getSubRows` option. optional parentId: string; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:41](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L41) +Defined in: [core/rows/coreRowsFeature.types.ts:42](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L42) If nested, this row's parent row id. @@ -331,7 +366,7 @@ If nested, this row's parent row id. renderValue: (columnId) => TValue; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:87](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L87) +Defined in: [core/rows/coreRowsFeature.types.ts:93](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L93) Renders the value for the row in a given columnId the same as `getValue`, but will return the `renderFallbackValue` if no value is found. @@ -363,7 +398,7 @@ Renders the value for the row in a given columnId the same as `getValue`, but wi subRows: Row[]; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:45](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L45) +Defined in: [core/rows/coreRowsFeature.types.ts:46](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L46) An array of subRows for the row as returned and created by the `options.getSubRows` option. @@ -379,7 +414,7 @@ An array of subRows for the row as returned and created by the `options.getSubRo table: Table_Internal; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:49](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L49) +Defined in: [core/rows/coreRowsFeature.types.ts:50](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L50) Reference to the parent table instance. diff --git a/docs/reference/index/interfaces/Row_CoreProperties.md b/docs/reference/index/interfaces/Row_CoreProperties.md index e0f125e07a..615b0172eb 100644 --- a/docs/reference/index/interfaces/Row_CoreProperties.md +++ b/docs/reference/index/interfaces/Row_CoreProperties.md @@ -33,13 +33,23 @@ Defined in: [core/rows/coreRowsFeature.types.ts:12](https://github.com/TanStack/ *** +### \_displayIndexCache + +```ts +_displayIndexCache: number; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:16](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L16) + +*** + ### \_uniqueValuesCache ```ts _uniqueValuesCache: Record; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:16](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L16) +Defined in: [core/rows/coreRowsFeature.types.ts:17](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L17) *** @@ -49,7 +59,7 @@ Defined in: [core/rows/coreRowsFeature.types.ts:16](https://github.com/TanStack/ _valuesCache: Record; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:17](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L17) +Defined in: [core/rows/coreRowsFeature.types.ts:18](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L18) *** @@ -59,7 +69,7 @@ Defined in: [core/rows/coreRowsFeature.types.ts:17](https://github.com/TanStack/ depth: number; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:21](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L21) +Defined in: [core/rows/coreRowsFeature.types.ts:22](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L22) The depth of the row (if nested or grouped) relative to the root row array. @@ -71,7 +81,7 @@ The depth of the row (if nested or grouped) relative to the root row array. id: string; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:25](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L25) +Defined in: [core/rows/coreRowsFeature.types.ts:26](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L26) The resolved unique identifier for the row resolved via the `options.getRowId` option. Defaults to the row's index (or relative index if it is a subRow). @@ -83,7 +93,7 @@ The resolved unique identifier for the row resolved via the `options.getRowId` o index: number; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:29](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L29) +Defined in: [core/rows/coreRowsFeature.types.ts:30](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L30) The index of the row within its parent array (or the root data array). @@ -95,7 +105,7 @@ The index of the row within its parent array (or the root data array). original: TData; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:33](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L33) +Defined in: [core/rows/coreRowsFeature.types.ts:34](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L34) The original row object provided to the table. If the row is a grouped row, the original row object will be the first original in the group. @@ -107,7 +117,7 @@ The original row object provided to the table. If the row is a grouped row, the optional originalSubRows: readonly TData[]; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:37](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L37) +Defined in: [core/rows/coreRowsFeature.types.ts:38](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L38) An array of the original subRows as returned by the `options.getSubRows` option. @@ -119,7 +129,7 @@ An array of the original subRows as returned by the `options.getSubRows` option. optional parentId: string; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:41](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L41) +Defined in: [core/rows/coreRowsFeature.types.ts:42](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L42) If nested, this row's parent row id. @@ -131,7 +141,7 @@ If nested, this row's parent row id. subRows: Row[]; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:45](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L45) +Defined in: [core/rows/coreRowsFeature.types.ts:46](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L46) An array of subRows for the row as returned and created by the `options.getSubRows` option. @@ -143,6 +153,6 @@ An array of subRows for the row as returned and created by the `options.getSubRo table: Table_Internal; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:49](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L49) +Defined in: [core/rows/coreRowsFeature.types.ts:50](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L50) Reference to the parent table instance. diff --git a/docs/reference/index/interfaces/Row_Row.md b/docs/reference/index/interfaces/Row_Row.md index 28045cef24..89b3139b6d 100644 --- a/docs/reference/index/interfaces/Row_Row.md +++ b/docs/reference/index/interfaces/Row_Row.md @@ -5,7 +5,7 @@ title: Row_Row # Interface: Row\_Row\ -Defined in: [core/rows/coreRowsFeature.types.ts:52](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L52) +Defined in: [core/rows/coreRowsFeature.types.ts:53](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L53) ## Extends @@ -41,13 +41,27 @@ Defined in: [core/rows/coreRowsFeature.types.ts:12](https://github.com/TanStack/ *** +### \_displayIndexCache + +```ts +_displayIndexCache: number; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:16](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L16) + +#### Inherited from + +[`Row_CoreProperties`](Row_CoreProperties.md).[`_displayIndexCache`](Row_CoreProperties.md#_displayindexcache) + +*** + ### \_uniqueValuesCache ```ts _uniqueValuesCache: Record; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:16](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L16) +Defined in: [core/rows/coreRowsFeature.types.ts:17](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L17) #### Inherited from @@ -61,7 +75,7 @@ Defined in: [core/rows/coreRowsFeature.types.ts:16](https://github.com/TanStack/ _valuesCache: Record; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:17](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L17) +Defined in: [core/rows/coreRowsFeature.types.ts:18](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L18) #### Inherited from @@ -75,7 +89,7 @@ Defined in: [core/rows/coreRowsFeature.types.ts:17](https://github.com/TanStack/ depth: number; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:21](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L21) +Defined in: [core/rows/coreRowsFeature.types.ts:22](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L22) The depth of the row (if nested or grouped) relative to the root row array. @@ -91,7 +105,7 @@ The depth of the row (if nested or grouped) relative to the root row array. getAllCells: () => Cell[]; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:63](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L63) +Defined in: [core/rows/coreRowsFeature.types.ts:69](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L69) Builds one cell for each leaf column, including cells for hidden columns. @@ -107,7 +121,7 @@ Builds one cell for each leaf column, including cells for hidden columns. getAllCellsByColumnId: () => Record>; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:59](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L59) +Defined in: [core/rows/coreRowsFeature.types.ts:65](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L65) Builds a lookup of this row's cells keyed by leaf column id. @@ -117,13 +131,30 @@ Builds a lookup of this row's cells keyed by leaf column id. *** +### getDisplayIndex() + +```ts +getDisplayIndex: () => number; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:61](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L61) + +Returns the zero-based index of the row in the current display order +before pagination, or `-1` if the row is not in that model. + +#### Returns + +`number` + +*** + ### getLeafRows() ```ts getLeafRows: () => Row[]; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:67](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L67) +Defined in: [core/rows/coreRowsFeature.types.ts:73](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L73) Returns the leaf rows for the row, not including any parent rows. @@ -139,7 +170,7 @@ Returns the leaf rows for the row, not including any parent rows. getParentRow: () => Row | undefined; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:71](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L71) +Defined in: [core/rows/coreRowsFeature.types.ts:77](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L77) Returns the parent row for the row, if it exists. @@ -155,7 +186,7 @@ Returns the parent row for the row, if it exists. getParentRows: () => Row[]; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:75](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L75) +Defined in: [core/rows/coreRowsFeature.types.ts:81](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L81) Returns the parent rows for the row, all the way up to a root row. @@ -171,7 +202,7 @@ Returns the parent rows for the row, all the way up to a root row. getUniqueValues: (columnId) => TValue[]; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:79](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L79) +Defined in: [core/rows/coreRowsFeature.types.ts:85](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L85) Reads the values this row contributes to faceting/grouping for a column. @@ -199,7 +230,7 @@ Reads the values this row contributes to faceting/grouping for a column. getValue: (columnId) => TValue; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:83](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L83) +Defined in: [core/rows/coreRowsFeature.types.ts:89](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L89) Reads this row's accessor value for a column id and caches the result. @@ -227,7 +258,7 @@ Reads this row's accessor value for a column id and caches the result. id: string; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:25](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L25) +Defined in: [core/rows/coreRowsFeature.types.ts:26](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L26) The resolved unique identifier for the row resolved via the `options.getRowId` option. Defaults to the row's index (or relative index if it is a subRow). @@ -243,7 +274,7 @@ The resolved unique identifier for the row resolved via the `options.getRowId` o index: number; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:29](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L29) +Defined in: [core/rows/coreRowsFeature.types.ts:30](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L30) The index of the row within its parent array (or the root data array). @@ -259,7 +290,7 @@ The index of the row within its parent array (or the root data array). original: TData; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:33](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L33) +Defined in: [core/rows/coreRowsFeature.types.ts:34](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L34) The original row object provided to the table. If the row is a grouped row, the original row object will be the first original in the group. @@ -275,7 +306,7 @@ The original row object provided to the table. If the row is a grouped row, the optional originalSubRows: readonly TData[]; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:37](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L37) +Defined in: [core/rows/coreRowsFeature.types.ts:38](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L38) An array of the original subRows as returned by the `options.getSubRows` option. @@ -291,7 +322,7 @@ An array of the original subRows as returned by the `options.getSubRows` option. optional parentId: string; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:41](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L41) +Defined in: [core/rows/coreRowsFeature.types.ts:42](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L42) If nested, this row's parent row id. @@ -307,7 +338,7 @@ If nested, this row's parent row id. renderValue: (columnId) => TValue; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:87](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L87) +Defined in: [core/rows/coreRowsFeature.types.ts:93](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L93) Renders the value for the row in a given columnId the same as `getValue`, but will return the `renderFallbackValue` if no value is found. @@ -335,7 +366,7 @@ Renders the value for the row in a given columnId the same as `getValue`, but wi subRows: Row[]; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:45](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L45) +Defined in: [core/rows/coreRowsFeature.types.ts:46](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L46) An array of subRows for the row as returned and created by the `options.getSubRows` option. @@ -351,7 +382,7 @@ An array of subRows for the row as returned and created by the `options.getSubRo table: Table_Internal; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:49](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L49) +Defined in: [core/rows/coreRowsFeature.types.ts:50](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L50) Reference to the parent table instance. diff --git a/docs/reference/index/interfaces/TableOptions_Core.md b/docs/reference/index/interfaces/TableOptions_Core.md index 2e1fa88908..8852a160d6 100644 --- a/docs/reference/index/interfaces/TableOptions_Core.md +++ b/docs/reference/index/interfaces/TableOptions_Core.md @@ -138,7 +138,7 @@ slots (`tableMeta`, `columnMeta`). optional getRowId: (originalRow, index, parent?) => string; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:98](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L98) +Defined in: [core/rows/coreRowsFeature.types.ts:104](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L104) This optional function is used to derive a unique ID for any given row. If not provided the rows index is used (nested rows join together with `.` using their grandparents' index eg. `index.index.index`). If you need to identify individual rows that are originating from any server-side operations, it's suggested you use this function to return an ID that makes sense regardless of network IO/ambiguity eg. a userId, taskId, database ID field, etc. @@ -178,7 +178,7 @@ getRowId: row => row.userId optional getSubRows: (originalRow, index) => readonly TData[] | undefined; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:107](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L107) +Defined in: [core/rows/coreRowsFeature.types.ts:113](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L113) This optional function is used to access the sub rows for any given row. If you are using nested rows, you will need to use this function to return the sub rows object (or undefined) from the row. diff --git a/docs/reference/index/interfaces/TableOptions_Rows.md b/docs/reference/index/interfaces/TableOptions_Rows.md index b9b6824e69..80701b9d8a 100644 --- a/docs/reference/index/interfaces/TableOptions_Rows.md +++ b/docs/reference/index/interfaces/TableOptions_Rows.md @@ -5,7 +5,7 @@ title: TableOptions_Rows # Interface: TableOptions\_Rows\ -Defined in: [core/rows/coreRowsFeature.types.ts:90](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L90) +Defined in: [core/rows/coreRowsFeature.types.ts:96](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L96) ## Extended by @@ -29,7 +29,7 @@ Defined in: [core/rows/coreRowsFeature.types.ts:90](https://github.com/TanStack/ optional getRowId: (originalRow, index, parent?) => string; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:98](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L98) +Defined in: [core/rows/coreRowsFeature.types.ts:104](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L104) This optional function is used to derive a unique ID for any given row. If not provided the rows index is used (nested rows join together with `.` using their grandparents' index eg. `index.index.index`). If you need to identify individual rows that are originating from any server-side operations, it's suggested you use this function to return an ID that makes sense regardless of network IO/ambiguity eg. a userId, taskId, database ID field, etc. @@ -65,7 +65,7 @@ getRowId: row => row.userId optional getSubRows: (originalRow, index) => readonly TData[] | undefined; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:107](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L107) +Defined in: [core/rows/coreRowsFeature.types.ts:113](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L113) This optional function is used to access the sub rows for any given row. If you are using nested rows, you will need to use this function to return the sub rows object (or undefined) from the row. diff --git a/docs/reference/index/interfaces/Table_Core.md b/docs/reference/index/interfaces/Table_Core.md index 866b70ae47..720d3a6866 100644 --- a/docs/reference/index/interfaces/Table_Core.md +++ b/docs/reference/index/interfaces/Table_Core.md @@ -718,7 +718,7 @@ Table_RowModels.getPreSortedRowModel getRow: (id, searchAll?) => Row; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:121](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L121) +Defined in: [core/rows/coreRowsFeature.types.ts:134](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L134) Returns the row with the given ID. @@ -748,7 +748,7 @@ Returns the row with the given ID. getRowId: (_, index, parent?) => string; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:117](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L117) +Defined in: [core/rows/coreRowsFeature.types.ts:130](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L130) #### Parameters @@ -796,6 +796,29 @@ Table_RowModels.getRowModel *** +### getRowsInDisplayOrder() + +```ts +getRowsInDisplayOrder: () => Row[]; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:129](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L129) + +Returns the rows in the current display order and assigns their display +indexes. When expanded rows bypass pagination, expanded descendants are +included in this order. This is the memoized source for +`row.getDisplayIndex()`. + +#### Returns + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\>[] + +#### Inherited from + +[`Table_Rows`](Table_Rows.md).[`getRowsInDisplayOrder`](Table_Rows.md#getrowsindisplayorder) + +*** + ### getSortedRowModel() ```ts diff --git a/docs/reference/index/interfaces/Table_Internal.md b/docs/reference/index/interfaces/Table_Internal.md index 9406c3c923..8e04ed6e20 100644 --- a/docs/reference/index/interfaces/Table_Internal.md +++ b/docs/reference/index/interfaces/Table_Internal.md @@ -711,7 +711,7 @@ Table_RowModels.getPreSortedRowModel getRow: (id, searchAll?) => Row; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:121](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L121) +Defined in: [core/rows/coreRowsFeature.types.ts:134](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L134) Returns the row with the given ID. @@ -741,7 +741,7 @@ Returns the row with the given ID. getRowId: (_, index, parent?) => string; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:117](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L117) +Defined in: [core/rows/coreRowsFeature.types.ts:130](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L130) #### Parameters @@ -789,6 +789,29 @@ Table_RowModels.getRowModel *** +### getRowsInDisplayOrder() + +```ts +getRowsInDisplayOrder: () => Row[]; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:129](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L129) + +Returns the rows in the current display order and assigns their display +indexes. When expanded rows bypass pagination, expanded descendants are +included in this order. This is the memoized source for +`row.getDisplayIndex()`. + +#### Returns + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\>[] + +#### Inherited from + +[`Table_Rows`](Table_Rows.md).[`getRowsInDisplayOrder`](Table_Rows.md#getrowsindisplayorder) + +*** + ### getSortedRowModel() ```ts diff --git a/docs/reference/index/interfaces/Table_Rows.md b/docs/reference/index/interfaces/Table_Rows.md index e7d7e8f101..f888f514fd 100644 --- a/docs/reference/index/interfaces/Table_Rows.md +++ b/docs/reference/index/interfaces/Table_Rows.md @@ -5,7 +5,7 @@ title: Table_Rows # Interface: Table\_Rows\ -Defined in: [core/rows/coreRowsFeature.types.ts:113](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L113) +Defined in: [core/rows/coreRowsFeature.types.ts:119](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L119) ## Extended by @@ -30,7 +30,7 @@ Defined in: [core/rows/coreRowsFeature.types.ts:113](https://github.com/TanStack getRow: (id, searchAll?) => Row; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:121](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L121) +Defined in: [core/rows/coreRowsFeature.types.ts:134](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L134) Returns the row with the given ID. @@ -56,7 +56,7 @@ Returns the row with the given ID. getRowId: (_, index, parent?) => string; ``` -Defined in: [core/rows/coreRowsFeature.types.ts:117](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L117) +Defined in: [core/rows/coreRowsFeature.types.ts:130](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L130) #### Parameters @@ -75,3 +75,22 @@ Defined in: [core/rows/coreRowsFeature.types.ts:117](https://github.com/TanStack #### Returns `string` + +*** + +### getRowsInDisplayOrder() + +```ts +getRowsInDisplayOrder: () => Row[]; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:129](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L129) + +Returns the rows in the current display order and assigns their display +indexes. When expanded rows bypass pagination, expanded descendants are +included in this order. This is the memoized source for +`row.getDisplayIndex()`. + +#### Returns + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\>[] diff --git a/docs/reference/index/variables/coreRowsFeature.md b/docs/reference/index/variables/coreRowsFeature.md index 938ead6d9f..d582ba459b 100644 --- a/docs/reference/index/variables/coreRowsFeature.md +++ b/docs/reference/index/variables/coreRowsFeature.md @@ -9,6 +9,6 @@ title: coreRowsFeature const coreRowsFeature: TableFeature; ``` -Defined in: [core/rows/coreRowsFeature.ts:19](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.ts#L19) +Defined in: [core/rows/coreRowsFeature.ts:21](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.ts#L21) Core feature that creates row APIs for values, cells, and tree traversal. diff --git a/docs/reference/static-functions/functions/row_getAllCells.md b/docs/reference/static-functions/functions/row_getAllCells.md index 9e670180e5..880be52dcb 100644 --- a/docs/reference/static-functions/functions/row_getAllCells.md +++ b/docs/reference/static-functions/functions/row_getAllCells.md @@ -9,7 +9,7 @@ title: row_getAllCells function row_getAllCells(row): Cell[]; ``` -Defined in: [core/rows/coreRowsFeature.utils.ts:167](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.utils.ts#L167) +Defined in: [core/rows/coreRowsFeature.utils.ts:225](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.utils.ts#L225) Constructs one cell for each leaf column in this row. diff --git a/docs/reference/static-functions/functions/row_getAllCellsByColumnId.md b/docs/reference/static-functions/functions/row_getAllCellsByColumnId.md index a8d55203b0..f9fd6b4237 100644 --- a/docs/reference/static-functions/functions/row_getAllCellsByColumnId.md +++ b/docs/reference/static-functions/functions/row_getAllCellsByColumnId.md @@ -9,7 +9,7 @@ title: row_getAllCellsByColumnId function row_getAllCellsByColumnId(row): Record>; ``` -Defined in: [core/rows/coreRowsFeature.utils.ts:203](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.utils.ts#L203) +Defined in: [core/rows/coreRowsFeature.utils.ts:261](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.utils.ts#L261) Builds a lookup map of this row's cells keyed by column id. diff --git a/docs/reference/static-functions/functions/row_getDisplayIndex.md b/docs/reference/static-functions/functions/row_getDisplayIndex.md new file mode 100644 index 0000000000..45779902cf --- /dev/null +++ b/docs/reference/static-functions/functions/row_getDisplayIndex.md @@ -0,0 +1,35 @@ +--- +id: row_getDisplayIndex +title: row_getDisplayIndex +--- + +# Function: row\_getDisplayIndex() + +```ts +function row_getDisplayIndex(row): number; +``` + +Defined in: [core/rows/coreRowsFeature.utils.ts:14](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.utils.ts#L14) + +Returns this row's zero-based position in the current pre-pagination row +model. Rows outside that model return `-1`. + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../../index/interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../../index/type-aliases/RowData.md) + +## Parameters + +### row + +[`Row`](../../index/type-aliases/Row.md)\<`TFeatures`, `TData`\> + +## Returns + +`number` diff --git a/docs/reference/static-functions/functions/row_getLeafRows.md b/docs/reference/static-functions/functions/row_getLeafRows.md index 4c6a89e1ce..4ebccfdd82 100644 --- a/docs/reference/static-functions/functions/row_getLeafRows.md +++ b/docs/reference/static-functions/functions/row_getLeafRows.md @@ -9,7 +9,7 @@ title: row_getLeafRows function row_getLeafRows(row): Row[]; ``` -Defined in: [core/rows/coreRowsFeature.utils.ts:105](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.utils.ts#L105) +Defined in: [core/rows/coreRowsFeature.utils.ts:163](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.utils.ts#L163) Flattens this row's descendant tree into leaf rows. diff --git a/docs/reference/static-functions/functions/row_getParentRow.md b/docs/reference/static-functions/functions/row_getParentRow.md index d41773982a..b5c9301fd9 100644 --- a/docs/reference/static-functions/functions/row_getParentRow.md +++ b/docs/reference/static-functions/functions/row_getParentRow.md @@ -11,7 +11,7 @@ function row_getParentRow(row): | undefined; ``` -Defined in: [core/rows/coreRowsFeature.utils.ts:123](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.utils.ts#L123) +Defined in: [core/rows/coreRowsFeature.utils.ts:181](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.utils.ts#L181) Looks up this row's direct parent, if it has one. diff --git a/docs/reference/static-functions/functions/row_getParentRows.md b/docs/reference/static-functions/functions/row_getParentRows.md index 8c632cd4da..365e585f53 100644 --- a/docs/reference/static-functions/functions/row_getParentRows.md +++ b/docs/reference/static-functions/functions/row_getParentRows.md @@ -9,7 +9,7 @@ title: row_getParentRows function row_getParentRows(row): Row[]; ``` -Defined in: [core/rows/coreRowsFeature.utils.ts:140](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.utils.ts#L140) +Defined in: [core/rows/coreRowsFeature.utils.ts:198](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.utils.ts#L198) Collects this row's ancestor chain from root to direct parent. diff --git a/docs/reference/static-functions/functions/row_getUniqueValues.md b/docs/reference/static-functions/functions/row_getUniqueValues.md index ea17b86311..f9e7fa9d82 100644 --- a/docs/reference/static-functions/functions/row_getUniqueValues.md +++ b/docs/reference/static-functions/functions/row_getUniqueValues.md @@ -9,7 +9,7 @@ title: row_getUniqueValues function row_getUniqueValues(row, columnId): unknown; ``` -Defined in: [core/rows/coreRowsFeature.utils.ts:50](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.utils.ts#L50) +Defined in: [core/rows/coreRowsFeature.utils.ts:108](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.utils.ts#L108) Reads and caches the values used by faceting/grouping for a column. diff --git a/docs/reference/static-functions/functions/row_getValue.md b/docs/reference/static-functions/functions/row_getValue.md index d46152a12d..e2a167117d 100644 --- a/docs/reference/static-functions/functions/row_getValue.md +++ b/docs/reference/static-functions/functions/row_getValue.md @@ -9,7 +9,7 @@ title: row_getValue function row_getValue(row, columnId): unknown; ``` -Defined in: [core/rows/coreRowsFeature.utils.ts:20](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.utils.ts#L20) +Defined in: [core/rows/coreRowsFeature.utils.ts:78](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.utils.ts#L78) Reads and caches this row's value for a column. diff --git a/docs/reference/static-functions/functions/row_renderValue.md b/docs/reference/static-functions/functions/row_renderValue.md index fb9bca7641..7ff2291498 100644 --- a/docs/reference/static-functions/functions/row_renderValue.md +++ b/docs/reference/static-functions/functions/row_renderValue.md @@ -9,7 +9,7 @@ title: row_renderValue function row_renderValue(row, columnId): any; ``` -Defined in: [core/rows/coreRowsFeature.utils.ts:88](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.utils.ts#L88) +Defined in: [core/rows/coreRowsFeature.utils.ts:146](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.utils.ts#L146) Returns a renderable row value for a column. diff --git a/docs/reference/static-functions/functions/table_getRow.md b/docs/reference/static-functions/functions/table_getRow.md index b9d5b11354..9bc9b608b6 100644 --- a/docs/reference/static-functions/functions/table_getRow.md +++ b/docs/reference/static-functions/functions/table_getRow.md @@ -12,7 +12,7 @@ function table_getRow( searchAll?): Row; ``` -Defined in: [core/rows/coreRowsFeature.utils.ts:253](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.utils.ts#L253) +Defined in: [core/rows/coreRowsFeature.utils.ts:311](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.utils.ts#L311) Looks up a row by id from the current or full row model. diff --git a/docs/reference/static-functions/functions/table_getRowId.md b/docs/reference/static-functions/functions/table_getRowId.md index 490fbc716f..3f67eda1dd 100644 --- a/docs/reference/static-functions/functions/table_getRowId.md +++ b/docs/reference/static-functions/functions/table_getRowId.md @@ -13,7 +13,7 @@ function table_getRowId( parent?): string; ``` -Defined in: [core/rows/coreRowsFeature.utils.ts:227](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.utils.ts#L227) +Defined in: [core/rows/coreRowsFeature.utils.ts:285](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.utils.ts#L285) Resolves the stable id for a row. diff --git a/docs/reference/static-functions/functions/table_getRowsInDisplayOrder.md b/docs/reference/static-functions/functions/table_getRowsInDisplayOrder.md new file mode 100644 index 0000000000..fdc93bbcde --- /dev/null +++ b/docs/reference/static-functions/functions/table_getRowsInDisplayOrder.md @@ -0,0 +1,39 @@ +--- +id: table_getRowsInDisplayOrder +title: table_getRowsInDisplayOrder +--- + +# Function: table\_getRowsInDisplayOrder() + +```ts +function table_getRowsInDisplayOrder(table): Row[]; +``` + +Defined in: [core/rows/coreRowsFeature.utils.ts:32](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.utils.ts#L32) + +Returns the rows in the current display order after assigning their +zero-based display indexes. + +When expanded rows bypass pagination, expanded descendants are inserted into +the returned order even though they are absent from the pre-pagination row +model. + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../../index/interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../../index/type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../../index/interfaces/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`Row`](../../index/type-aliases/Row.md)\<`TFeatures`, `TData`\>[] diff --git a/docs/reference/static-functions/index.md b/docs/reference/static-functions/index.md index 01a322891a..1e14141c26 100644 --- a/docs/reference/static-functions/index.md +++ b/docs/reference/static-functions/index.md @@ -93,6 +93,7 @@ title: static-functions - [row\_getCanSelect](functions/row_getCanSelect.md) - [row\_getCanSelectSubRows](functions/row_getCanSelectSubRows.md) - [row\_getCenterVisibleCells](functions/row_getCenterVisibleCells.md) +- [row\_getDisplayIndex](functions/row_getDisplayIndex.md) - [row\_getEndVisibleCells](functions/row_getEndVisibleCells.md) - [row\_getGroupingValue](functions/row_getGroupingValue.md) - [row\_getIsAllParentsExpanded](functions/row_getIsAllParentsExpanded.md) @@ -192,6 +193,7 @@ title: static-functions - [table\_getRowCount](functions/table_getRowCount.md) - [table\_getRowId](functions/table_getRowId.md) - [table\_getRowModel](functions/table_getRowModel.md) +- [table\_getRowsInDisplayOrder](functions/table_getRowsInDisplayOrder.md) - [table\_getSelectedRowIds](functions/table_getSelectedRowIds.md) - [table\_getSelectedRowModel](functions/table_getSelectedRowModel.md) - [table\_getSortedRowModel](functions/table_getSortedRowModel.md) diff --git a/eslint.config.js b/eslint.config.js index 1de6411738..ec24a7c8f0 100644 --- a/eslint.config.js +++ b/eslint.config.js @@ -8,6 +8,14 @@ const config = [ ...tanstackConfig, { name: 'tanstack/temp', + // Anchor type-aware linting to the repo root so `project: true` does not + // fall back to process.cwd() (e.g. packages/ember-table in the IDE). + languageOptions: { + parserOptions: { + project: true, + tsconfigRootDir: import.meta.dirname, + }, + }, rules: { 'no-case-declarations': 'off', 'no-shadow': 'off', diff --git a/examples/alpine/basic-app-table/package.json b/examples/alpine/basic-app-table/package.json index bb310fd4d9..4d3e5ab223 100644 --- a/examples/alpine/basic-app-table/package.json +++ b/examples/alpine/basic-app-table/package.json @@ -11,7 +11,7 @@ "test:e2e": "PLAYWRIGHT_TEST_DIR=$PWD/tests/e2e playwright test --config ../../../playwright.config.ts" }, "dependencies": { - "@tanstack/alpine-table": "^9.0.0-beta.42", + "@tanstack/alpine-table": "^9.0.0-beta.43", "alpinejs": "^3.15.12" }, "devDependencies": { diff --git a/examples/alpine/basic-create-table/package.json b/examples/alpine/basic-create-table/package.json index 9a62e7c015..ccb3a2ba09 100644 --- a/examples/alpine/basic-create-table/package.json +++ b/examples/alpine/basic-create-table/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/alpine-table": "^9.0.0-beta.42", + "@tanstack/alpine-table": "^9.0.0-beta.43", "alpinejs": "^3.15.12" }, "devDependencies": { diff --git a/examples/alpine/basic-dynamic-columns/package.json b/examples/alpine/basic-dynamic-columns/package.json index c39caa1331..28e193c5b1 100644 --- a/examples/alpine/basic-dynamic-columns/package.json +++ b/examples/alpine/basic-dynamic-columns/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/alpine-table": "^9.0.0-beta.42", + "@tanstack/alpine-table": "^9.0.0-beta.43", "alpinejs": "^3.15.12" }, "devDependencies": { diff --git a/examples/alpine/basic-external-atoms/package.json b/examples/alpine/basic-external-atoms/package.json index f412205872..8557ed419f 100644 --- a/examples/alpine/basic-external-atoms/package.json +++ b/examples/alpine/basic-external-atoms/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/alpine-table": "^9.0.0-beta.42", + "@tanstack/alpine-table": "^9.0.0-beta.43", "@tanstack/store": "^0.11.0", "alpinejs": "^3.15.12" }, diff --git a/examples/alpine/basic-external-state/package.json b/examples/alpine/basic-external-state/package.json index 18deb58db8..8198f2053f 100644 --- a/examples/alpine/basic-external-state/package.json +++ b/examples/alpine/basic-external-state/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/alpine-table": "^9.0.0-beta.42", + "@tanstack/alpine-table": "^9.0.0-beta.43", "alpinejs": "^3.15.12" }, "devDependencies": { diff --git a/examples/alpine/column-groups/package.json b/examples/alpine/column-groups/package.json index 4be673e172..48ef2003bf 100644 --- a/examples/alpine/column-groups/package.json +++ b/examples/alpine/column-groups/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/alpine-table": "^9.0.0-beta.42", + "@tanstack/alpine-table": "^9.0.0-beta.43", "alpinejs": "^3.15.12" }, "devDependencies": { diff --git a/examples/alpine/column-ordering/package.json b/examples/alpine/column-ordering/package.json index 77b29ede47..c2a90cada7 100644 --- a/examples/alpine/column-ordering/package.json +++ b/examples/alpine/column-ordering/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/alpine-table": "^9.0.0-beta.42", + "@tanstack/alpine-table": "^9.0.0-beta.43", "alpinejs": "^3.15.12" }, "devDependencies": { diff --git a/examples/alpine/column-pinning-split/package.json b/examples/alpine/column-pinning-split/package.json index 9f09964269..3641a3faa0 100644 --- a/examples/alpine/column-pinning-split/package.json +++ b/examples/alpine/column-pinning-split/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/alpine-table": "^9.0.0-beta.42", + "@tanstack/alpine-table": "^9.0.0-beta.43", "alpinejs": "^3.15.12" }, "devDependencies": { diff --git a/examples/alpine/column-pinning-sticky/package.json b/examples/alpine/column-pinning-sticky/package.json index 5c59f71570..aaa6d7a65b 100644 --- a/examples/alpine/column-pinning-sticky/package.json +++ b/examples/alpine/column-pinning-sticky/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/alpine-table": "^9.0.0-beta.42", + "@tanstack/alpine-table": "^9.0.0-beta.43", "alpinejs": "^3.15.12" }, "devDependencies": { diff --git a/examples/alpine/column-pinning/package.json b/examples/alpine/column-pinning/package.json index 5fb2c93999..619ce72d1c 100644 --- a/examples/alpine/column-pinning/package.json +++ b/examples/alpine/column-pinning/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/alpine-table": "^9.0.0-beta.42", + "@tanstack/alpine-table": "^9.0.0-beta.43", "alpinejs": "^3.15.12" }, "devDependencies": { diff --git a/examples/alpine/column-resizing-performant/package.json b/examples/alpine/column-resizing-performant/package.json index 3337e503c2..93ca0d5c62 100644 --- a/examples/alpine/column-resizing-performant/package.json +++ b/examples/alpine/column-resizing-performant/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/alpine-table": "^9.0.0-beta.42", + "@tanstack/alpine-table": "^9.0.0-beta.43", "alpinejs": "^3.15.12" }, "devDependencies": { diff --git a/examples/alpine/column-resizing/package.json b/examples/alpine/column-resizing/package.json index d1c36817a7..665dad957c 100644 --- a/examples/alpine/column-resizing/package.json +++ b/examples/alpine/column-resizing/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/alpine-table": "^9.0.0-beta.42", + "@tanstack/alpine-table": "^9.0.0-beta.43", "alpinejs": "^3.15.12" }, "devDependencies": { diff --git a/examples/alpine/column-sizing/package.json b/examples/alpine/column-sizing/package.json index fb0f5b3e50..6d3641f92c 100644 --- a/examples/alpine/column-sizing/package.json +++ b/examples/alpine/column-sizing/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/alpine-table": "^9.0.0-beta.42", + "@tanstack/alpine-table": "^9.0.0-beta.43", "alpinejs": "^3.15.12" }, "devDependencies": { diff --git a/examples/alpine/column-visibility/package.json b/examples/alpine/column-visibility/package.json index 6270603dc1..43b69f9aea 100644 --- a/examples/alpine/column-visibility/package.json +++ b/examples/alpine/column-visibility/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/alpine-table": "^9.0.0-beta.42", + "@tanstack/alpine-table": "^9.0.0-beta.43", "alpinejs": "^3.15.12" }, "devDependencies": { diff --git a/examples/alpine/custom-plugin/package.json b/examples/alpine/custom-plugin/package.json index bea492b40f..82578bf9c0 100644 --- a/examples/alpine/custom-plugin/package.json +++ b/examples/alpine/custom-plugin/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/alpine-table": "^9.0.0-beta.42", + "@tanstack/alpine-table": "^9.0.0-beta.43", "alpinejs": "^3.15.12" }, "devDependencies": { diff --git a/examples/alpine/expanding/package.json b/examples/alpine/expanding/package.json index 464c34d29f..e90614e9d2 100644 --- a/examples/alpine/expanding/package.json +++ b/examples/alpine/expanding/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/alpine-table": "^9.0.0-beta.42", + "@tanstack/alpine-table": "^9.0.0-beta.43", "alpinejs": "^3.15.12" }, "devDependencies": { diff --git a/examples/alpine/expanding/src/main.ts b/examples/alpine/expanding/src/main.ts index f524d2e53c..6232a869fa 100644 --- a/examples/alpine/expanding/src/main.ts +++ b/examples/alpine/expanding/src/main.ts @@ -39,6 +39,11 @@ const features = tableFeatures({ // those controls are rendered directly in `index.html` (special-cased by column // id), so here the column just exposes the plain value. const columns: Array> = [ + { + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }, { accessorKey: 'firstName', header: () => 'First Name', diff --git a/examples/alpine/filters-faceted/package.json b/examples/alpine/filters-faceted/package.json index 9362effdfd..4060dee846 100644 --- a/examples/alpine/filters-faceted/package.json +++ b/examples/alpine/filters-faceted/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/alpine-table": "^9.0.0-beta.42", + "@tanstack/alpine-table": "^9.0.0-beta.43", "alpinejs": "^3.15.12" }, "devDependencies": { diff --git a/examples/alpine/filters/package.json b/examples/alpine/filters/package.json index 3c739a5404..16e1908b08 100644 --- a/examples/alpine/filters/package.json +++ b/examples/alpine/filters/package.json @@ -11,7 +11,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/alpine-table": "^9.0.0-beta.42", + "@tanstack/alpine-table": "^9.0.0-beta.43", "alpinejs": "^3.15.12" }, "devDependencies": { diff --git a/examples/alpine/filters/src/main.ts b/examples/alpine/filters/src/main.ts index d2cd1ca082..79be1d0d7c 100644 --- a/examples/alpine/filters/src/main.ts +++ b/examples/alpine/filters/src/main.ts @@ -30,6 +30,11 @@ const features = tableFeatures({ }) const columns: Array> = [ + { + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }, { accessorKey: 'firstName', cell: (info) => info.getValue(), diff --git a/examples/alpine/grouping/package.json b/examples/alpine/grouping/package.json index ae920b6aeb..5348db6776 100644 --- a/examples/alpine/grouping/package.json +++ b/examples/alpine/grouping/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/alpine-table": "^9.0.0-beta.42", + "@tanstack/alpine-table": "^9.0.0-beta.43", "alpinejs": "^3.15.12" }, "devDependencies": { diff --git a/examples/alpine/pagination/package.json b/examples/alpine/pagination/package.json index 63839c9ea4..b14c3e3f98 100644 --- a/examples/alpine/pagination/package.json +++ b/examples/alpine/pagination/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/alpine-table": "^9.0.0-beta.42", + "@tanstack/alpine-table": "^9.0.0-beta.43", "alpinejs": "^3.15.12" }, "devDependencies": { diff --git a/examples/alpine/pagination/src/main.ts b/examples/alpine/pagination/src/main.ts index 7e3e8f55ce..734acf7c7f 100644 --- a/examples/alpine/pagination/src/main.ts +++ b/examples/alpine/pagination/src/main.ts @@ -19,6 +19,11 @@ const features = tableFeatures({ const columnHelper = createColumnHelper() const columns = columnHelper.columns([ + columnHelper.display({ + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }), columnHelper.accessor('firstName', { cell: (info) => info.getValue(), footer: (props) => props.column.id, diff --git a/examples/alpine/row-pinning/package.json b/examples/alpine/row-pinning/package.json index 37265e1d09..848fce9f8d 100644 --- a/examples/alpine/row-pinning/package.json +++ b/examples/alpine/row-pinning/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/alpine-table": "^9.0.0-beta.42", + "@tanstack/alpine-table": "^9.0.0-beta.43", "alpinejs": "^3.15.12" }, "devDependencies": { diff --git a/examples/alpine/row-selection/package.json b/examples/alpine/row-selection/package.json index 95cd8e7ad0..ea1c891d9f 100644 --- a/examples/alpine/row-selection/package.json +++ b/examples/alpine/row-selection/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/alpine-table": "^9.0.0-beta.42", + "@tanstack/alpine-table": "^9.0.0-beta.43", "alpinejs": "^3.15.12" }, "devDependencies": { diff --git a/examples/alpine/sorting-dynamic-data/package.json b/examples/alpine/sorting-dynamic-data/package.json index 500a24e79d..664d3289ce 100644 --- a/examples/alpine/sorting-dynamic-data/package.json +++ b/examples/alpine/sorting-dynamic-data/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/alpine-table": "^9.0.0-beta.42", + "@tanstack/alpine-table": "^9.0.0-beta.43", "alpinejs": "^3.15.12" }, "devDependencies": { diff --git a/examples/alpine/sorting/package.json b/examples/alpine/sorting/package.json index 8b6c0601bc..a8d3b9657d 100644 --- a/examples/alpine/sorting/package.json +++ b/examples/alpine/sorting/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/alpine-table": "^9.0.0-beta.42", + "@tanstack/alpine-table": "^9.0.0-beta.43", "alpinejs": "^3.15.12" }, "devDependencies": { diff --git a/examples/alpine/sorting/src/main.ts b/examples/alpine/sorting/src/main.ts index d4ebda8c0f..bf102fbde3 100644 --- a/examples/alpine/sorting/src/main.ts +++ b/examples/alpine/sorting/src/main.ts @@ -30,6 +30,11 @@ const sortStatusFn: SortFn = ( } const columns: Array> = [ + { + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }, { accessorKey: 'firstName', cell: (info) => info.getValue(), diff --git a/examples/alpine/sub-components/package.json b/examples/alpine/sub-components/package.json index caa9b5d012..7337499dd0 100644 --- a/examples/alpine/sub-components/package.json +++ b/examples/alpine/sub-components/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/alpine-table": "^9.0.0-beta.42", + "@tanstack/alpine-table": "^9.0.0-beta.43", "alpinejs": "^3.15.12" }, "devDependencies": { diff --git a/examples/angular/basic-app-table/package.json b/examples/angular/basic-app-table/package.json index f66ec632fd..65cb22c4cf 100644 --- a/examples/angular/basic-app-table/package.json +++ b/examples/angular/basic-app-table/package.json @@ -20,8 +20,8 @@ "@angular/platform-browser": "^22.0.2", "@faker-js/faker": "^10.5.0", "@tanstack/angular-devtools": "^0.0.7", - "@tanstack/angular-table": "^9.0.0-beta.42", - "@tanstack/angular-table-devtools": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", + "@tanstack/angular-table-devtools": "^9.0.0-beta.43", "rxjs": "~7.8.2", "tslib": "^2.8.1" }, diff --git a/examples/angular/basic-dynamic-columns/package.json b/examples/angular/basic-dynamic-columns/package.json index 153785e4e1..bb41ba906f 100644 --- a/examples/angular/basic-dynamic-columns/package.json +++ b/examples/angular/basic-dynamic-columns/package.json @@ -21,7 +21,7 @@ "@angular/router": "^22.0.2", "@faker-js/faker": "^10.5.0", "@tanstack/angular-pacer": "^0.23.1", - "@tanstack/angular-table": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", "rxjs": "~7.8.2", "tslib": "^2.8.1" }, diff --git a/examples/angular/basic-external-atoms/package.json b/examples/angular/basic-external-atoms/package.json index 4daa91614a..7bb12936b4 100644 --- a/examples/angular/basic-external-atoms/package.json +++ b/examples/angular/basic-external-atoms/package.json @@ -21,8 +21,8 @@ "@faker-js/faker": "^10.5.0", "@tanstack/angular-devtools": "^0.0.7", "@tanstack/angular-store": "^0.11.0", - "@tanstack/angular-table": "^9.0.0-beta.42", - "@tanstack/angular-table-devtools": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", + "@tanstack/angular-table-devtools": "^9.0.0-beta.43", "rxjs": "~7.8.2", "tslib": "^2.8.1" }, diff --git a/examples/angular/basic-external-state/package.json b/examples/angular/basic-external-state/package.json index 511f6ec430..6c0e7e64bd 100644 --- a/examples/angular/basic-external-state/package.json +++ b/examples/angular/basic-external-state/package.json @@ -21,8 +21,8 @@ "@faker-js/faker": "^10.5.0", "@tanstack/angular-devtools": "^0.0.7", "@tanstack/angular-store": "^0.11.0", - "@tanstack/angular-table": "^9.0.0-beta.42", - "@tanstack/angular-table-devtools": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", + "@tanstack/angular-table-devtools": "^9.0.0-beta.43", "rxjs": "~7.8.2", "tslib": "^2.8.1" }, diff --git a/examples/angular/basic-inject-table/package.json b/examples/angular/basic-inject-table/package.json index f6bae5f5a0..739523e6a6 100644 --- a/examples/angular/basic-inject-table/package.json +++ b/examples/angular/basic-inject-table/package.json @@ -21,8 +21,8 @@ "@angular/router": "^22.0.2", "@faker-js/faker": "^10.5.0", "@tanstack/angular-devtools": "^0.0.7", - "@tanstack/angular-table": "^9.0.0-beta.42", - "@tanstack/angular-table-devtools": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", + "@tanstack/angular-table-devtools": "^9.0.0-beta.43", "rxjs": "~7.8.2", "tslib": "^2.8.1" }, diff --git a/examples/angular/column-groups/package.json b/examples/angular/column-groups/package.json index bf666d30ae..0e24ca713c 100644 --- a/examples/angular/column-groups/package.json +++ b/examples/angular/column-groups/package.json @@ -20,7 +20,7 @@ "@angular/platform-browser": "^22.0.2", "@angular/router": "^22.0.2", "@faker-js/faker": "^10.5.0", - "@tanstack/angular-table": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", "rxjs": "~7.8.2", "tslib": "^2.8.1" }, diff --git a/examples/angular/column-ordering/package.json b/examples/angular/column-ordering/package.json index 0241d7f2e9..274f4b66b7 100644 --- a/examples/angular/column-ordering/package.json +++ b/examples/angular/column-ordering/package.json @@ -20,7 +20,7 @@ "@angular/platform-browser": "^22.0.2", "@angular/router": "^22.0.2", "@faker-js/faker": "^10.5.0", - "@tanstack/angular-table": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", "rxjs": "~7.8.2", "tslib": "^2.8.1" }, diff --git a/examples/angular/column-pinning-split/package.json b/examples/angular/column-pinning-split/package.json index 987a3f6d5d..44b3be9177 100644 --- a/examples/angular/column-pinning-split/package.json +++ b/examples/angular/column-pinning-split/package.json @@ -20,7 +20,7 @@ "@angular/platform-browser": "^22.0.2", "@angular/router": "^22.0.2", "@faker-js/faker": "^10.5.0", - "@tanstack/angular-table": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", "rxjs": "~7.8.2", "tslib": "^2.8.1" }, diff --git a/examples/angular/column-pinning-sticky/package.json b/examples/angular/column-pinning-sticky/package.json index 124a9548a4..c73e440edf 100644 --- a/examples/angular/column-pinning-sticky/package.json +++ b/examples/angular/column-pinning-sticky/package.json @@ -20,7 +20,7 @@ "@angular/platform-browser": "^22.0.2", "@angular/router": "^22.0.2", "@faker-js/faker": "^10.5.0", - "@tanstack/angular-table": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", "rxjs": "~7.8.2", "tslib": "^2.8.1" }, diff --git a/examples/angular/column-pinning/package.json b/examples/angular/column-pinning/package.json index abc7922fce..d6eb85227f 100644 --- a/examples/angular/column-pinning/package.json +++ b/examples/angular/column-pinning/package.json @@ -20,7 +20,7 @@ "@angular/platform-browser": "^22.0.2", "@angular/router": "^22.0.2", "@faker-js/faker": "^10.5.0", - "@tanstack/angular-table": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", "rxjs": "~7.8.2", "tslib": "^2.8.1" }, diff --git a/examples/angular/column-resizing-performant/package.json b/examples/angular/column-resizing-performant/package.json index 03120ed53b..2eb5785d3b 100644 --- a/examples/angular/column-resizing-performant/package.json +++ b/examples/angular/column-resizing-performant/package.json @@ -20,7 +20,7 @@ "@angular/platform-browser": "^22.0.2", "@angular/router": "^22.0.2", "@faker-js/faker": "^10.5.0", - "@tanstack/angular-table": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", "rxjs": "~7.8.2", "tslib": "^2.8.1" }, diff --git a/examples/angular/column-resizing/package.json b/examples/angular/column-resizing/package.json index 59b9c93cec..a4a7a40608 100644 --- a/examples/angular/column-resizing/package.json +++ b/examples/angular/column-resizing/package.json @@ -20,7 +20,7 @@ "@angular/platform-browser": "^22.0.2", "@angular/router": "^22.0.2", "@faker-js/faker": "^10.5.0", - "@tanstack/angular-table": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", "rxjs": "~7.8.2", "tslib": "^2.8.1" }, diff --git a/examples/angular/column-sizing/package.json b/examples/angular/column-sizing/package.json index 1b406f5626..dd4f1f2789 100644 --- a/examples/angular/column-sizing/package.json +++ b/examples/angular/column-sizing/package.json @@ -20,7 +20,7 @@ "@angular/platform-browser": "^22.0.2", "@angular/router": "^22.0.2", "@faker-js/faker": "^10.5.0", - "@tanstack/angular-table": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", "rxjs": "~7.8.2", "tslib": "^2.8.1" }, diff --git a/examples/angular/column-visibility/package.json b/examples/angular/column-visibility/package.json index 6d5dbdd9d7..56ec7f6615 100644 --- a/examples/angular/column-visibility/package.json +++ b/examples/angular/column-visibility/package.json @@ -20,7 +20,7 @@ "@angular/platform-browser": "^22.0.2", "@angular/router": "^22.0.2", "@faker-js/faker": "^10.5.0", - "@tanstack/angular-table": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", "rxjs": "~7.8.2", "tslib": "^2.8.1" }, diff --git a/examples/angular/composable-tables/package.json b/examples/angular/composable-tables/package.json index 51d4019bfe..ada37e7a40 100644 --- a/examples/angular/composable-tables/package.json +++ b/examples/angular/composable-tables/package.json @@ -21,8 +21,8 @@ "@angular/router": "^22.0.2", "@faker-js/faker": "^10.5.0", "@tanstack/angular-devtools": "^0.0.7", - "@tanstack/angular-table": "^9.0.0-beta.42", - "@tanstack/angular-table-devtools": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", + "@tanstack/angular-table-devtools": "^9.0.0-beta.43", "rxjs": "~7.8.2", "tslib": "^2.8.1" }, diff --git a/examples/angular/custom-plugin/package.json b/examples/angular/custom-plugin/package.json index 549ecf16a0..56ffdeaff2 100644 --- a/examples/angular/custom-plugin/package.json +++ b/examples/angular/custom-plugin/package.json @@ -19,7 +19,7 @@ "@angular/forms": "^22.0.2", "@angular/platform-browser": "^22.0.2", "@angular/router": "^22.0.2", - "@tanstack/angular-table": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", "rxjs": "~7.8.2", "tslib": "^2.8.1" }, diff --git a/examples/angular/editable/package.json b/examples/angular/editable/package.json index 739179b463..949d897fd6 100644 --- a/examples/angular/editable/package.json +++ b/examples/angular/editable/package.json @@ -20,7 +20,7 @@ "@angular/platform-browser": "^22.0.2", "@angular/router": "^22.0.2", "@faker-js/faker": "^10.5.0", - "@tanstack/angular-table": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", "rxjs": "~7.8.2", "tslib": "^2.8.1" }, diff --git a/examples/angular/expanding/package.json b/examples/angular/expanding/package.json index 0b7fe106dc..c134f8db84 100644 --- a/examples/angular/expanding/package.json +++ b/examples/angular/expanding/package.json @@ -20,7 +20,7 @@ "@angular/platform-browser": "^22.0.2", "@angular/router": "^22.0.2", "@faker-js/faker": "^10.5.0", - "@tanstack/angular-table": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", "rxjs": "~7.8.2", "tslib": "^2.8.1" }, diff --git a/examples/angular/expanding/src/app/app.ts b/examples/angular/expanding/src/app/app.ts index d14b750783..4463117c7c 100644 --- a/examples/angular/expanding/src/app/app.ts +++ b/examples/angular/expanding/src/app/app.ts @@ -28,6 +28,11 @@ export const features = tableFeatures({ }) const defaultColumns: Array> = [ + { + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }, { accessorKey: 'firstName', header: () => diff --git a/examples/angular/filters-faceted/package.json b/examples/angular/filters-faceted/package.json index e2dde89339..8f18e96223 100644 --- a/examples/angular/filters-faceted/package.json +++ b/examples/angular/filters-faceted/package.json @@ -21,7 +21,7 @@ "@angular/router": "^22.0.2", "@faker-js/faker": "^10.5.0", "@tanstack/angular-pacer": "^0.23.1", - "@tanstack/angular-table": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", "rxjs": "~7.8.2", "tslib": "^2.8.1" }, diff --git a/examples/angular/filters-fuzzy/package.json b/examples/angular/filters-fuzzy/package.json index 4e8646f796..7989e3c1c7 100644 --- a/examples/angular/filters-fuzzy/package.json +++ b/examples/angular/filters-fuzzy/package.json @@ -21,7 +21,7 @@ "@angular/router": "^22.0.2", "@faker-js/faker": "^10.5.0", "@tanstack/angular-pacer": "^0.23.1", - "@tanstack/angular-table": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", "@tanstack/match-sorter-utils": "^9.0.0-beta.41", "rxjs": "~7.8.2", "tslib": "^2.8.1" diff --git a/examples/angular/filters/package.json b/examples/angular/filters/package.json index 6c61cf7a4f..9576fb916b 100644 --- a/examples/angular/filters/package.json +++ b/examples/angular/filters/package.json @@ -21,7 +21,7 @@ "@angular/router": "^22.0.2", "@faker-js/faker": "^10.5.0", "@tanstack/angular-pacer": "^0.23.1", - "@tanstack/angular-table": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", "rxjs": "~7.8.2", "tslib": "^2.8.1" }, diff --git a/examples/angular/filters/src/app/app.ts b/examples/angular/filters/src/app/app.ts index 06fb72376d..085c248372 100644 --- a/examples/angular/filters/src/app/app.ts +++ b/examples/angular/filters/src/app/app.ts @@ -40,6 +40,11 @@ const { injectAppTable, createAppColumnHelper } = createTableHook({ const columnHelper = createAppColumnHelper() const columns = columnHelper.columns([ + columnHelper.display({ + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }), columnHelper.accessor('firstName', { cell: (info) => info.getValue(), }), diff --git a/examples/angular/grouping/package.json b/examples/angular/grouping/package.json index c3fa8e2dce..9c0ea9459a 100644 --- a/examples/angular/grouping/package.json +++ b/examples/angular/grouping/package.json @@ -20,7 +20,7 @@ "@angular/platform-browser": "^22.0.2", "@angular/router": "^22.0.2", "@faker-js/faker": "^10.5.0", - "@tanstack/angular-table": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", "rxjs": "~7.8.2", "tslib": "^2.8.1" }, diff --git a/examples/angular/kitchen-sink/package.json b/examples/angular/kitchen-sink/package.json index 4a2ad18154..38f5e91a02 100644 --- a/examples/angular/kitchen-sink/package.json +++ b/examples/angular/kitchen-sink/package.json @@ -21,8 +21,8 @@ "@angular/router": "^22.0.2", "@faker-js/faker": "^10.5.0", "@tanstack/angular-devtools": "^0.0.7", - "@tanstack/angular-table": "^9.0.0-beta.42", - "@tanstack/angular-table-devtools": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", + "@tanstack/angular-table-devtools": "^9.0.0-beta.43", "@tanstack/match-sorter-utils": "^9.0.0-beta.41", "rxjs": "~7.8.2", "tslib": "^2.8.1" diff --git a/examples/angular/pagination/package.json b/examples/angular/pagination/package.json index a85d1dd961..ea31da622f 100644 --- a/examples/angular/pagination/package.json +++ b/examples/angular/pagination/package.json @@ -20,7 +20,7 @@ "@angular/platform-browser": "^22.0.2", "@angular/router": "^22.0.2", "@faker-js/faker": "^10.5.0", - "@tanstack/angular-table": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", "rxjs": "~7.8.2", "tslib": "^2.8.1" }, diff --git a/examples/angular/pagination/src/app/app.ts b/examples/angular/pagination/src/app/app.ts index 6a1e9152d6..fca50363b6 100644 --- a/examples/angular/pagination/src/app/app.ts +++ b/examples/angular/pagination/src/app/app.ts @@ -16,6 +16,11 @@ const features = tableFeatures({ }) const columns: Array> = [ + { + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }, { header: 'Name', footer: (props) => props.column.id, diff --git a/examples/angular/remote-data/package.json b/examples/angular/remote-data/package.json index 7dffac3022..ab374651f3 100644 --- a/examples/angular/remote-data/package.json +++ b/examples/angular/remote-data/package.json @@ -25,7 +25,7 @@ "@angular/platform-server": "^22.0.2", "@angular/router": "^22.0.2", "@angular/ssr": "^22.0.0", - "@tanstack/angular-table": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", "express": "^5.2.1", "rxjs": "~7.8.2" }, diff --git a/examples/angular/row-dnd/package.json b/examples/angular/row-dnd/package.json index 2b6a69c812..065d4f5145 100644 --- a/examples/angular/row-dnd/package.json +++ b/examples/angular/row-dnd/package.json @@ -21,7 +21,7 @@ "@angular/platform-browser": "^22.0.2", "@angular/router": "^22.0.2", "@faker-js/faker": "^10.5.0", - "@tanstack/angular-table": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", "rxjs": "~7.8.2", "tslib": "^2.8.1" }, diff --git a/examples/angular/row-pinning/package.json b/examples/angular/row-pinning/package.json index 8ee5660430..cbdaacf9bc 100644 --- a/examples/angular/row-pinning/package.json +++ b/examples/angular/row-pinning/package.json @@ -20,7 +20,7 @@ "@angular/platform-browser": "^22.0.2", "@angular/router": "^22.0.2", "@faker-js/faker": "^10.5.0", - "@tanstack/angular-table": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", "rxjs": "~7.8.2", "tslib": "^2.8.1" }, diff --git a/examples/angular/row-selection-signal/package.json b/examples/angular/row-selection-signal/package.json index 1e5a071604..1637dee794 100644 --- a/examples/angular/row-selection-signal/package.json +++ b/examples/angular/row-selection-signal/package.json @@ -23,8 +23,8 @@ "@angular/platform-browser-dynamic": "^22.0.2", "@faker-js/faker": "^10.5.0", "@tanstack/angular-devtools": "^0.0.7", - "@tanstack/angular-table": "^9.0.0-beta.42", - "@tanstack/angular-table-devtools": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", + "@tanstack/angular-table-devtools": "^9.0.0-beta.43", "rxjs": "~7.8.2", "tslib": "^2.8.1" }, diff --git a/examples/angular/row-selection/package.json b/examples/angular/row-selection/package.json index aa26c3f5d3..2162250fe8 100644 --- a/examples/angular/row-selection/package.json +++ b/examples/angular/row-selection/package.json @@ -22,8 +22,8 @@ "@angular/router": "^22.0.2", "@faker-js/faker": "^10.5.0", "@tanstack/angular-devtools": "^0.0.7", - "@tanstack/angular-table": "^9.0.0-beta.42", - "@tanstack/angular-table-devtools": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", + "@tanstack/angular-table-devtools": "^9.0.0-beta.43", "rxjs": "~7.8.2", "tslib": "^2.8.1" }, diff --git a/examples/angular/signal-input/package.json b/examples/angular/signal-input/package.json index 3f8b4a43cf..a497a6db7e 100644 --- a/examples/angular/signal-input/package.json +++ b/examples/angular/signal-input/package.json @@ -21,7 +21,7 @@ "@angular/platform-browser": "^22.0.2", "@angular/router": "^22.0.2", "@faker-js/faker": "^10.5.0", - "@tanstack/angular-table": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", "rxjs": "~7.8.2", "tslib": "^2.8.1" }, diff --git a/examples/angular/sorting/package.json b/examples/angular/sorting/package.json index 4d7ef9745e..3b28bb4619 100644 --- a/examples/angular/sorting/package.json +++ b/examples/angular/sorting/package.json @@ -20,7 +20,7 @@ "@angular/platform-browser": "^22.0.2", "@angular/router": "^22.0.2", "@faker-js/faker": "^10.5.0", - "@tanstack/angular-table": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", "rxjs": "~7.8.2", "tslib": "^2.8.1" }, diff --git a/examples/angular/sorting/src/app/app.ts b/examples/angular/sorting/src/app/app.ts index e519217ef1..4c94d38337 100644 --- a/examples/angular/sorting/src/app/app.ts +++ b/examples/angular/sorting/src/app/app.ts @@ -26,6 +26,11 @@ const sortStatusFn: SortFn = (rowA, rowB) => { } const columns: Array> = [ + { + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }, { accessorKey: 'firstName', cell: (info) => info.getValue() }, { accessorFn: (row) => row.lastName, diff --git a/examples/angular/sub-components/package.json b/examples/angular/sub-components/package.json index 29aae4dcdc..af748a2607 100644 --- a/examples/angular/sub-components/package.json +++ b/examples/angular/sub-components/package.json @@ -20,7 +20,7 @@ "@angular/platform-browser": "^22.0.2", "@angular/router": "^22.0.2", "@faker-js/faker": "^10.5.0", - "@tanstack/angular-table": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", "rxjs": "~7.8.2", "tslib": "^2.8.1" }, diff --git a/examples/angular/virtualized-columns/package.json b/examples/angular/virtualized-columns/package.json index 721820b7fa..fe1d603eea 100644 --- a/examples/angular/virtualized-columns/package.json +++ b/examples/angular/virtualized-columns/package.json @@ -20,7 +20,7 @@ "@angular/platform-browser": "^22.0.2", "@angular/router": "^22.0.2", "@faker-js/faker": "^10.5.0", - "@tanstack/angular-table": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", "@tanstack/angular-virtual": "^5.0.7", "rxjs": "~7.8.2", "tslib": "^2.8.1" diff --git a/examples/angular/virtualized-infinite-scrolling/package.json b/examples/angular/virtualized-infinite-scrolling/package.json index ee0336b342..622200f497 100644 --- a/examples/angular/virtualized-infinite-scrolling/package.json +++ b/examples/angular/virtualized-infinite-scrolling/package.json @@ -20,7 +20,7 @@ "@angular/platform-browser": "^22.0.2", "@angular/router": "^22.0.2", "@faker-js/faker": "^10.5.0", - "@tanstack/angular-table": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", "@tanstack/angular-virtual": "^5.0.7", "rxjs": "~7.8.2", "tslib": "^2.8.1" diff --git a/examples/angular/virtualized-rows/package.json b/examples/angular/virtualized-rows/package.json index e4e7ee1aa0..c64e471066 100644 --- a/examples/angular/virtualized-rows/package.json +++ b/examples/angular/virtualized-rows/package.json @@ -20,7 +20,7 @@ "@angular/platform-browser": "^22.0.2", "@angular/router": "^22.0.2", "@faker-js/faker": "^10.5.0", - "@tanstack/angular-table": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", "@tanstack/angular-virtual": "^5.0.7", "rxjs": "~7.8.2", "tslib": "^2.8.1" diff --git a/examples/angular/with-tanstack-form/package.json b/examples/angular/with-tanstack-form/package.json index 4962dbf316..d795d5d952 100644 --- a/examples/angular/with-tanstack-form/package.json +++ b/examples/angular/with-tanstack-form/package.json @@ -22,8 +22,8 @@ "@faker-js/faker": "^10.5.0", "@tanstack/angular-devtools": "^0.0.7", "@tanstack/angular-form": "^1.33.1", - "@tanstack/angular-table": "^9.0.0-beta.42", - "@tanstack/angular-table-devtools": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", + "@tanstack/angular-table-devtools": "^9.0.0-beta.43", "rxjs": "~7.8.2", "tslib": "^2.8.1", "zod": "^4.4.3" diff --git a/examples/angular/with-tanstack-query/package.json b/examples/angular/with-tanstack-query/package.json index db2250f3e2..db123bd57a 100644 --- a/examples/angular/with-tanstack-query/package.json +++ b/examples/angular/with-tanstack-query/package.json @@ -21,7 +21,7 @@ "@angular/router": "^22.0.2", "@faker-js/faker": "^10.5.0", "@tanstack/angular-query-experimental": "^5.101.2", - "@tanstack/angular-table": "^9.0.0-beta.42", + "@tanstack/angular-table": "^9.0.0-beta.43", "rxjs": "~7.8.2", "tslib": "^2.8.1" }, diff --git a/examples/ember/basic-app-table/package.json b/examples/ember/basic-app-table/package.json index 48e847db34..b0cca14285 100644 --- a/examples/ember/basic-app-table/package.json +++ b/examples/ember/basic-app-table/package.json @@ -43,7 +43,7 @@ "@glint/tsserver-plugin": "2.5.17", "@nullvoxpopuli/ember-vite": "1.0.3", "@rollup/plugin-babel": "7.1.0", - "@tanstack/ember-table": "^9.0.0-beta.42", + "@tanstack/ember-table": "^9.0.0-beta.43", "babel-plugin-ember-template-compilation": "4.0.0", "typescript": "6.0.3", "vite": "^8.1.0" diff --git a/examples/ember/basic-external-atoms/package.json b/examples/ember/basic-external-atoms/package.json index fc9274f64e..690d96fc18 100644 --- a/examples/ember/basic-external-atoms/package.json +++ b/examples/ember/basic-external-atoms/package.json @@ -28,7 +28,7 @@ "@embroider/router": "3.0.6", "@faker-js/faker": "^10.5.0", "@glimmer/component": "2.1.1", - "@tanstack/ember-table": "^9.0.0-beta.42", + "@tanstack/ember-table": "^9.0.0-beta.43", "decorator-transforms": "2.4.0", "ember-source": "7.0.0", "ember-strict-application-resolver": "0.1.1" diff --git a/examples/ember/basic-external-state/package.json b/examples/ember/basic-external-state/package.json index 4d12b5705a..21c1cc2542 100644 --- a/examples/ember/basic-external-state/package.json +++ b/examples/ember/basic-external-state/package.json @@ -28,7 +28,7 @@ "@embroider/router": "3.0.6", "@faker-js/faker": "^10.5.0", "@glimmer/component": "2.1.1", - "@tanstack/ember-table": "^9.0.0-beta.42", + "@tanstack/ember-table": "^9.0.0-beta.43", "decorator-transforms": "2.4.0", "ember-source": "7.0.0", "ember-strict-application-resolver": "0.1.1" diff --git a/examples/ember/basic-table/package.json b/examples/ember/basic-table/package.json index fc7004cb6c..688cc0ab49 100644 --- a/examples/ember/basic-table/package.json +++ b/examples/ember/basic-table/package.json @@ -43,7 +43,7 @@ "@glint/tsserver-plugin": "2.5.17", "@nullvoxpopuli/ember-vite": "1.0.3", "@rollup/plugin-babel": "7.1.0", - "@tanstack/ember-table": "^9.0.0-beta.42", + "@tanstack/ember-table": "^9.0.0-beta.43", "babel-plugin-ember-template-compilation": "4.0.0", "typescript": "6.0.3", "vite": "^8.1.0" diff --git a/examples/ember/column-groups/package.json b/examples/ember/column-groups/package.json index 093ce2b5ab..c7705cf205 100644 --- a/examples/ember/column-groups/package.json +++ b/examples/ember/column-groups/package.json @@ -28,7 +28,7 @@ "@embroider/router": "3.0.6", "@faker-js/faker": "^10.5.0", "@glimmer/component": "2.1.1", - "@tanstack/ember-table": "^9.0.0-beta.42", + "@tanstack/ember-table": "^9.0.0-beta.43", "decorator-transforms": "2.4.0", "ember-source": "7.0.0", "ember-strict-application-resolver": "0.1.1" diff --git a/examples/ember/column-ordering/package.json b/examples/ember/column-ordering/package.json index b7a48578fa..390e8a860f 100644 --- a/examples/ember/column-ordering/package.json +++ b/examples/ember/column-ordering/package.json @@ -28,7 +28,7 @@ "@embroider/router": "3.0.6", "@faker-js/faker": "^10.5.0", "@glimmer/component": "2.1.1", - "@tanstack/ember-table": "^9.0.0-beta.42", + "@tanstack/ember-table": "^9.0.0-beta.43", "decorator-transforms": "2.4.0", "ember-source": "7.0.0", "ember-strict-application-resolver": "0.1.1" diff --git a/examples/ember/column-pinning-split/package.json b/examples/ember/column-pinning-split/package.json index 5cec077921..ba5afafda5 100644 --- a/examples/ember/column-pinning-split/package.json +++ b/examples/ember/column-pinning-split/package.json @@ -28,7 +28,7 @@ "@embroider/router": "3.0.6", "@faker-js/faker": "^10.5.0", "@glimmer/component": "2.1.1", - "@tanstack/ember-table": "^9.0.0-beta.42", + "@tanstack/ember-table": "^9.0.0-beta.43", "decorator-transforms": "2.4.0", "ember-source": "7.0.0", "ember-strict-application-resolver": "0.1.1" diff --git a/examples/ember/column-pinning-sticky/package.json b/examples/ember/column-pinning-sticky/package.json index a3bfe87fde..4b3cbe8c12 100644 --- a/examples/ember/column-pinning-sticky/package.json +++ b/examples/ember/column-pinning-sticky/package.json @@ -28,7 +28,7 @@ "@embroider/router": "3.0.6", "@faker-js/faker": "^10.5.0", "@glimmer/component": "2.1.1", - "@tanstack/ember-table": "^9.0.0-beta.42", + "@tanstack/ember-table": "^9.0.0-beta.43", "decorator-transforms": "2.4.0", "ember-source": "7.0.0", "ember-strict-application-resolver": "0.1.1" diff --git a/examples/ember/column-pinning/package.json b/examples/ember/column-pinning/package.json index 026fb05d14..f18997636e 100644 --- a/examples/ember/column-pinning/package.json +++ b/examples/ember/column-pinning/package.json @@ -28,7 +28,7 @@ "@embroider/router": "3.0.6", "@faker-js/faker": "^10.5.0", "@glimmer/component": "2.1.1", - "@tanstack/ember-table": "^9.0.0-beta.42", + "@tanstack/ember-table": "^9.0.0-beta.43", "decorator-transforms": "2.4.0", "ember-source": "7.0.0", "ember-strict-application-resolver": "0.1.1" diff --git a/examples/ember/column-resizing-performant/package.json b/examples/ember/column-resizing-performant/package.json index 31b0e620a5..c14a69a38f 100644 --- a/examples/ember/column-resizing-performant/package.json +++ b/examples/ember/column-resizing-performant/package.json @@ -28,7 +28,7 @@ "@embroider/router": "3.0.6", "@faker-js/faker": "^10.5.0", "@glimmer/component": "2.1.1", - "@tanstack/ember-table": "^9.0.0-beta.42", + "@tanstack/ember-table": "^9.0.0-beta.43", "decorator-transforms": "2.4.0", "ember-source": "7.0.0", "ember-strict-application-resolver": "0.1.1" diff --git a/examples/ember/column-resizing/package.json b/examples/ember/column-resizing/package.json index 79917fefb6..36d05de430 100644 --- a/examples/ember/column-resizing/package.json +++ b/examples/ember/column-resizing/package.json @@ -28,7 +28,7 @@ "@embroider/router": "3.0.6", "@faker-js/faker": "^10.5.0", "@glimmer/component": "2.1.1", - "@tanstack/ember-table": "^9.0.0-beta.42", + "@tanstack/ember-table": "^9.0.0-beta.43", "decorator-transforms": "2.4.0", "ember-source": "7.0.0", "ember-strict-application-resolver": "0.1.1" diff --git a/examples/ember/column-sizing/package.json b/examples/ember/column-sizing/package.json index ddd56a2fe4..231c63e991 100644 --- a/examples/ember/column-sizing/package.json +++ b/examples/ember/column-sizing/package.json @@ -28,7 +28,7 @@ "@embroider/router": "3.0.6", "@faker-js/faker": "^10.5.0", "@glimmer/component": "2.1.1", - "@tanstack/ember-table": "^9.0.0-beta.42", + "@tanstack/ember-table": "^9.0.0-beta.43", "decorator-transforms": "2.4.0", "ember-source": "7.0.0", "ember-strict-application-resolver": "0.1.1" diff --git a/examples/ember/column-visibility/package.json b/examples/ember/column-visibility/package.json index 5a156646fa..c1a63df0b9 100644 --- a/examples/ember/column-visibility/package.json +++ b/examples/ember/column-visibility/package.json @@ -28,7 +28,7 @@ "@embroider/router": "3.0.6", "@faker-js/faker": "^10.5.0", "@glimmer/component": "2.1.1", - "@tanstack/ember-table": "^9.0.0-beta.42", + "@tanstack/ember-table": "^9.0.0-beta.43", "decorator-transforms": "2.4.0", "ember-source": "7.0.0", "ember-strict-application-resolver": "0.1.1" diff --git a/examples/ember/custom-plugin/package.json b/examples/ember/custom-plugin/package.json index c933764417..a08666ca42 100644 --- a/examples/ember/custom-plugin/package.json +++ b/examples/ember/custom-plugin/package.json @@ -28,8 +28,8 @@ "@embroider/router": "3.0.6", "@faker-js/faker": "^10.5.0", "@glimmer/component": "2.1.1", - "@tanstack/ember-table": "^9.0.0-beta.42", - "@tanstack/table-core": "^9.0.0-beta.42", + "@tanstack/ember-table": "^9.0.0-beta.43", + "@tanstack/table-core": "^9.0.0-beta.43", "decorator-transforms": "2.4.0", "ember-source": "7.0.0", "ember-strict-application-resolver": "0.1.1" diff --git a/examples/ember/editable/package.json b/examples/ember/editable/package.json index f9a29f060f..b8086e1a1a 100644 --- a/examples/ember/editable/package.json +++ b/examples/ember/editable/package.json @@ -28,7 +28,7 @@ "@embroider/router": "3.0.6", "@faker-js/faker": "^10.5.0", "@glimmer/component": "2.1.1", - "@tanstack/ember-table": "^9.0.0-beta.42", + "@tanstack/ember-table": "^9.0.0-beta.43", "decorator-transforms": "2.4.0", "ember-source": "7.0.0", "ember-strict-application-resolver": "0.1.1" diff --git a/examples/ember/expanding/app/templates/application.gts b/examples/ember/expanding/app/templates/application.gts index ac7da982d0..1eec79c852 100644 --- a/examples/ember/expanding/app/templates/application.gts +++ b/examples/ember/expanding/app/templates/application.gts @@ -42,6 +42,11 @@ const features = tableFeatures({ const columnHelper = createColumnHelper() const columns = columnHelper.columns([ + columnHelper.display({ + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }), columnHelper.accessor('firstName', { header: 'First Name', cell: (info) => info.getValue(), @@ -349,9 +354,9 @@ export default class ExpandingTable extends Component { {{#each this.rows as |row|}} - {{#each (getVisibleCells row) as |cell index|}} + {{#each (getVisibleCells row) as |cell|}} - {{#if (eq index 0)}} + {{#if (eq cell.column.id 'firstName')}}
() const columns = columnHelper.columns([ + columnHelper.display({ + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }), columnHelper.accessor('firstName', { header: 'First Name', cell: (info) => info.getValue(), diff --git a/examples/ember/filters/package.json b/examples/ember/filters/package.json index af903da90d..a4d2699ff4 100644 --- a/examples/ember/filters/package.json +++ b/examples/ember/filters/package.json @@ -28,7 +28,7 @@ "@embroider/router": "3.0.6", "@faker-js/faker": "^10.5.0", "@glimmer/component": "2.1.1", - "@tanstack/ember-table": "^9.0.0-beta.42", + "@tanstack/ember-table": "^9.0.0-beta.43", "decorator-transforms": "2.4.0", "ember-source": "7.0.0", "ember-strict-application-resolver": "0.1.1" diff --git a/examples/ember/grouping/package.json b/examples/ember/grouping/package.json index ca396ac545..2a97f212ad 100644 --- a/examples/ember/grouping/package.json +++ b/examples/ember/grouping/package.json @@ -28,7 +28,7 @@ "@embroider/router": "3.0.6", "@faker-js/faker": "^10.5.0", "@glimmer/component": "2.1.1", - "@tanstack/ember-table": "^9.0.0-beta.42", + "@tanstack/ember-table": "^9.0.0-beta.43", "decorator-transforms": "2.4.0", "ember-source": "7.0.0", "ember-strict-application-resolver": "0.1.1" diff --git a/examples/ember/kitchen-sink/package.json b/examples/ember/kitchen-sink/package.json index 1dac938924..6f50d35bc3 100644 --- a/examples/ember/kitchen-sink/package.json +++ b/examples/ember/kitchen-sink/package.json @@ -28,7 +28,7 @@ "@embroider/router": "3.0.6", "@faker-js/faker": "^10.5.0", "@glimmer/component": "2.1.1", - "@tanstack/ember-table": "^9.0.0-beta.42", + "@tanstack/ember-table": "^9.0.0-beta.43", "@tanstack/match-sorter-utils": "^9.0.0-beta.41", "decorator-transforms": "2.4.0", "ember-source": "7.0.0", diff --git a/examples/ember/pagination/app/templates/application.gts b/examples/ember/pagination/app/templates/application.gts index 2cc73980da..3e0f1ca7b5 100644 --- a/examples/ember/pagination/app/templates/application.gts +++ b/examples/ember/pagination/app/templates/application.gts @@ -23,6 +23,11 @@ const features = tableFeatures({ const columnHelper = createColumnHelper() const columns = columnHelper.columns([ + columnHelper.display({ + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }), columnHelper.group({ id: 'name', header: 'Name', diff --git a/examples/ember/pagination/package.json b/examples/ember/pagination/package.json index 94b5f42fa9..0333323c63 100644 --- a/examples/ember/pagination/package.json +++ b/examples/ember/pagination/package.json @@ -28,7 +28,7 @@ "@embroider/router": "3.0.6", "@faker-js/faker": "^10.5.0", "@glimmer/component": "2.1.1", - "@tanstack/ember-table": "^9.0.0-beta.42", + "@tanstack/ember-table": "^9.0.0-beta.43", "decorator-transforms": "2.4.0", "ember-source": "7.0.0", "ember-strict-application-resolver": "0.1.1" diff --git a/examples/ember/remote-data/package.json b/examples/ember/remote-data/package.json index 4aea20cb15..a0f361ed5c 100644 --- a/examples/ember/remote-data/package.json +++ b/examples/ember/remote-data/package.json @@ -28,7 +28,7 @@ "@embroider/router": "3.0.6", "@faker-js/faker": "^10.5.0", "@glimmer/component": "2.1.1", - "@tanstack/ember-table": "^9.0.0-beta.42", + "@tanstack/ember-table": "^9.0.0-beta.43", "decorator-transforms": "2.4.0", "ember-source": "7.0.0", "ember-strict-application-resolver": "0.1.1" diff --git a/examples/ember/row-dnd/package.json b/examples/ember/row-dnd/package.json index ce9dc94cd9..77e00f0995 100644 --- a/examples/ember/row-dnd/package.json +++ b/examples/ember/row-dnd/package.json @@ -28,7 +28,7 @@ "@embroider/router": "3.0.6", "@faker-js/faker": "^10.5.0", "@glimmer/component": "2.1.1", - "@tanstack/ember-table": "^9.0.0-beta.42", + "@tanstack/ember-table": "^9.0.0-beta.43", "decorator-transforms": "2.4.0", "ember-source": "7.0.0", "ember-strict-application-resolver": "0.1.1" diff --git a/examples/ember/row-pinning/package.json b/examples/ember/row-pinning/package.json index 959b44d05f..e2d571b61c 100644 --- a/examples/ember/row-pinning/package.json +++ b/examples/ember/row-pinning/package.json @@ -28,7 +28,7 @@ "@embroider/router": "3.0.6", "@faker-js/faker": "^10.5.0", "@glimmer/component": "2.1.1", - "@tanstack/ember-table": "^9.0.0-beta.42", + "@tanstack/ember-table": "^9.0.0-beta.43", "decorator-transforms": "2.4.0", "ember-source": "7.0.0", "ember-strict-application-resolver": "0.1.1" diff --git a/examples/ember/row-selection/package.json b/examples/ember/row-selection/package.json index 591a84c628..0b8ddd39f6 100644 --- a/examples/ember/row-selection/package.json +++ b/examples/ember/row-selection/package.json @@ -28,7 +28,7 @@ "@embroider/router": "3.0.6", "@faker-js/faker": "^10.5.0", "@glimmer/component": "2.1.1", - "@tanstack/ember-table": "^9.0.0-beta.42", + "@tanstack/ember-table": "^9.0.0-beta.43", "decorator-transforms": "2.4.0", "ember-source": "7.0.0", "ember-strict-application-resolver": "0.1.1" diff --git a/examples/ember/sorting/app/templates/application.gts b/examples/ember/sorting/app/templates/application.gts index 1836ff5d57..187ff17c86 100644 --- a/examples/ember/sorting/app/templates/application.gts +++ b/examples/ember/sorting/app/templates/application.gts @@ -39,6 +39,11 @@ const sortStatusFn: SortFn = (rowA, rowB) => { const columnHelper = createColumnHelper() const columns = columnHelper.columns([ + columnHelper.display({ + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }), columnHelper.accessor('firstName', { cell: (info) => info.getValue(), footer: (info) => info.column.id, diff --git a/examples/ember/sorting/package.json b/examples/ember/sorting/package.json index bba2f6bae9..0f8d16eb5a 100644 --- a/examples/ember/sorting/package.json +++ b/examples/ember/sorting/package.json @@ -28,7 +28,7 @@ "@embroider/router": "3.0.6", "@faker-js/faker": "^10.5.0", "@glimmer/component": "2.1.1", - "@tanstack/ember-table": "^9.0.0-beta.42", + "@tanstack/ember-table": "^9.0.0-beta.43", "decorator-transforms": "2.4.0", "ember-source": "7.0.0", "ember-strict-application-resolver": "0.1.1" diff --git a/examples/ember/sub-components/package.json b/examples/ember/sub-components/package.json index edf5b5154d..169d2c55f7 100644 --- a/examples/ember/sub-components/package.json +++ b/examples/ember/sub-components/package.json @@ -28,7 +28,7 @@ "@embroider/router": "3.0.6", "@faker-js/faker": "^10.5.0", "@glimmer/component": "2.1.1", - "@tanstack/ember-table": "^9.0.0-beta.42", + "@tanstack/ember-table": "^9.0.0-beta.43", "decorator-transforms": "2.4.0", "ember-source": "7.0.0", "ember-strict-application-resolver": "0.1.1" diff --git a/examples/lit/basic-app-table/package.json b/examples/lit/basic-app-table/package.json index 3c1941ed2b..73b33cad09 100644 --- a/examples/lit/basic-app-table/package.json +++ b/examples/lit/basic-app-table/package.json @@ -13,7 +13,7 @@ "dependencies": { "@faker-js/faker": "^10.5.0", "@lit/context": "^1.1.6", - "@tanstack/lit-table": "^9.0.0-beta.42", + "@tanstack/lit-table": "^9.0.0-beta.43", "lit": "^3.3.3" }, "devDependencies": { diff --git a/examples/lit/basic-dynamic-columns/package.json b/examples/lit/basic-dynamic-columns/package.json index 525fac4834..4dbf1826a0 100644 --- a/examples/lit/basic-dynamic-columns/package.json +++ b/examples/lit/basic-dynamic-columns/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/lit-table": "^9.0.0-beta.42", + "@tanstack/lit-table": "^9.0.0-beta.43", "lit": "^3.3.3" }, "devDependencies": { diff --git a/examples/lit/basic-external-atoms/package.json b/examples/lit/basic-external-atoms/package.json index 36e04f8d1b..036f795ddd 100644 --- a/examples/lit/basic-external-atoms/package.json +++ b/examples/lit/basic-external-atoms/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/lit-table": "^9.0.0-beta.42", + "@tanstack/lit-table": "^9.0.0-beta.43", "@tanstack/store": "^0.11.0", "lit": "^3.3.3" }, diff --git a/examples/lit/basic-external-state/package.json b/examples/lit/basic-external-state/package.json index 9dfbff682e..08511d1a50 100644 --- a/examples/lit/basic-external-state/package.json +++ b/examples/lit/basic-external-state/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/lit-table": "^9.0.0-beta.42", + "@tanstack/lit-table": "^9.0.0-beta.43", "lit": "^3.3.3" }, "devDependencies": { diff --git a/examples/lit/basic-subscribe/package.json b/examples/lit/basic-subscribe/package.json index 4388385cfa..3d1cfa8b8e 100644 --- a/examples/lit/basic-subscribe/package.json +++ b/examples/lit/basic-subscribe/package.json @@ -13,7 +13,7 @@ "dependencies": { "@faker-js/faker": "^10.5.0", "@tanstack/lit-store": "^0.14.0", - "@tanstack/lit-table": "^9.0.0-beta.42", + "@tanstack/lit-table": "^9.0.0-beta.43", "lit": "^3.3.3" }, "devDependencies": { diff --git a/examples/lit/basic-table-controller/package.json b/examples/lit/basic-table-controller/package.json index 997450ac92..acc3607189 100644 --- a/examples/lit/basic-table-controller/package.json +++ b/examples/lit/basic-table-controller/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/lit-table": "^9.0.0-beta.42", + "@tanstack/lit-table": "^9.0.0-beta.43", "lit": "^3.3.3" }, "devDependencies": { diff --git a/examples/lit/column-groups/package.json b/examples/lit/column-groups/package.json index 87706c022f..b6f3c0a533 100644 --- a/examples/lit/column-groups/package.json +++ b/examples/lit/column-groups/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/lit-table": "^9.0.0-beta.42", + "@tanstack/lit-table": "^9.0.0-beta.43", "lit": "^3.3.3" }, "devDependencies": { diff --git a/examples/lit/column-ordering/package.json b/examples/lit/column-ordering/package.json index 3d59534ce7..42f9a17cfd 100644 --- a/examples/lit/column-ordering/package.json +++ b/examples/lit/column-ordering/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/lit-table": "^9.0.0-beta.42", + "@tanstack/lit-table": "^9.0.0-beta.43", "lit": "^3.3.3" }, "devDependencies": { diff --git a/examples/lit/column-pinning-split/package.json b/examples/lit/column-pinning-split/package.json index 0fbb419dce..4cf6c3eb8a 100644 --- a/examples/lit/column-pinning-split/package.json +++ b/examples/lit/column-pinning-split/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/lit-table": "^9.0.0-beta.42", + "@tanstack/lit-table": "^9.0.0-beta.43", "lit": "^3.3.3" }, "devDependencies": { diff --git a/examples/lit/column-pinning-sticky/package.json b/examples/lit/column-pinning-sticky/package.json index fe7bb5342f..fe11b82442 100644 --- a/examples/lit/column-pinning-sticky/package.json +++ b/examples/lit/column-pinning-sticky/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/lit-table": "^9.0.0-beta.42", + "@tanstack/lit-table": "^9.0.0-beta.43", "lit": "^3.3.3" }, "devDependencies": { diff --git a/examples/lit/column-pinning/package.json b/examples/lit/column-pinning/package.json index 641df2da0e..f268d3bd30 100644 --- a/examples/lit/column-pinning/package.json +++ b/examples/lit/column-pinning/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/lit-table": "^9.0.0-beta.42", + "@tanstack/lit-table": "^9.0.0-beta.43", "lit": "^3.3.3" }, "devDependencies": { diff --git a/examples/lit/column-resizing-performant/package.json b/examples/lit/column-resizing-performant/package.json index 77ccca1b58..9ae6e177d0 100644 --- a/examples/lit/column-resizing-performant/package.json +++ b/examples/lit/column-resizing-performant/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/lit-table": "^9.0.0-beta.42", + "@tanstack/lit-table": "^9.0.0-beta.43", "lit": "^3.3.3" }, "devDependencies": { diff --git a/examples/lit/column-resizing/package.json b/examples/lit/column-resizing/package.json index fbceec5f96..63342744db 100644 --- a/examples/lit/column-resizing/package.json +++ b/examples/lit/column-resizing/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/lit-table": "^9.0.0-beta.42", + "@tanstack/lit-table": "^9.0.0-beta.43", "lit": "^3.3.3" }, "devDependencies": { diff --git a/examples/lit/column-sizing/package.json b/examples/lit/column-sizing/package.json index 1e4f01ebe1..e04f8f8443 100644 --- a/examples/lit/column-sizing/package.json +++ b/examples/lit/column-sizing/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/lit-table": "^9.0.0-beta.42", + "@tanstack/lit-table": "^9.0.0-beta.43", "lit": "^3.3.3" }, "devDependencies": { diff --git a/examples/lit/column-visibility/package.json b/examples/lit/column-visibility/package.json index c8803b87d6..111cf61f93 100644 --- a/examples/lit/column-visibility/package.json +++ b/examples/lit/column-visibility/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/lit-table": "^9.0.0-beta.42", + "@tanstack/lit-table": "^9.0.0-beta.43", "lit": "^3.3.3" }, "devDependencies": { diff --git a/examples/lit/composable-tables/package.json b/examples/lit/composable-tables/package.json index bbaede6ec9..46c6773aa7 100644 --- a/examples/lit/composable-tables/package.json +++ b/examples/lit/composable-tables/package.json @@ -13,7 +13,7 @@ "dependencies": { "@faker-js/faker": "^10.5.0", "@lit/context": "^1.1.6", - "@tanstack/lit-table": "^9.0.0-beta.42", + "@tanstack/lit-table": "^9.0.0-beta.43", "lit": "^3.3.3" }, "devDependencies": { diff --git a/examples/lit/expanding/package.json b/examples/lit/expanding/package.json index a2a8d60dd0..294d675569 100644 --- a/examples/lit/expanding/package.json +++ b/examples/lit/expanding/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/lit-table": "^9.0.0-beta.42", + "@tanstack/lit-table": "^9.0.0-beta.43", "lit": "^3.3.3" }, "devDependencies": { diff --git a/examples/lit/expanding/src/main.ts b/examples/lit/expanding/src/main.ts index 9bc373bdb7..892c4f3314 100644 --- a/examples/lit/expanding/src/main.ts +++ b/examples/lit/expanding/src/main.ts @@ -107,6 +107,11 @@ function renderFilter( } const columns: Array> = [ + { + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }, { accessorKey: 'firstName', header: ({ table }) => html` diff --git a/examples/lit/filters-faceted/package.json b/examples/lit/filters-faceted/package.json index ffd7c834b7..430fe10b79 100644 --- a/examples/lit/filters-faceted/package.json +++ b/examples/lit/filters-faceted/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/lit-table": "^9.0.0-beta.42", + "@tanstack/lit-table": "^9.0.0-beta.43", "lit": "^3.3.3" }, "devDependencies": { diff --git a/examples/lit/filters-fuzzy/package.json b/examples/lit/filters-fuzzy/package.json index e97ebf90c2..69addbbea9 100644 --- a/examples/lit/filters-fuzzy/package.json +++ b/examples/lit/filters-fuzzy/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/lit-table": "^9.0.0-beta.42", + "@tanstack/lit-table": "^9.0.0-beta.43", "@tanstack/match-sorter-utils": "^9.0.0-beta.41", "lit": "^3.3.3" }, diff --git a/examples/lit/filters/package.json b/examples/lit/filters/package.json index 356d075bf6..f3f2b88183 100644 --- a/examples/lit/filters/package.json +++ b/examples/lit/filters/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/lit-table": "^9.0.0-beta.42", + "@tanstack/lit-table": "^9.0.0-beta.43", "lit": "^3.3.3" }, "devDependencies": { diff --git a/examples/lit/filters/src/main.ts b/examples/lit/filters/src/main.ts index 8b03f9889f..8fdf80c426 100644 --- a/examples/lit/filters/src/main.ts +++ b/examples/lit/filters/src/main.ts @@ -31,6 +31,11 @@ const features = tableFeatures({ }) const columns: Array> = [ + { + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }, { accessorKey: 'firstName', cell: (info) => info.getValue(), diff --git a/examples/lit/grouping/package.json b/examples/lit/grouping/package.json index 8389faa8a6..77d1c2583a 100644 --- a/examples/lit/grouping/package.json +++ b/examples/lit/grouping/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/lit-table": "^9.0.0-beta.42", + "@tanstack/lit-table": "^9.0.0-beta.43", "lit": "^3.3.3" }, "devDependencies": { diff --git a/examples/lit/kitchen-sink/package.json b/examples/lit/kitchen-sink/package.json index 4a785f2cb2..1a33377002 100644 --- a/examples/lit/kitchen-sink/package.json +++ b/examples/lit/kitchen-sink/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/lit-table": "^9.0.0-beta.42", + "@tanstack/lit-table": "^9.0.0-beta.43", "@tanstack/match-sorter-utils": "^9.0.0-beta.41", "lit": "^3.3.3" }, diff --git a/examples/lit/pagination/package.json b/examples/lit/pagination/package.json index 17473566dc..3e61500a50 100644 --- a/examples/lit/pagination/package.json +++ b/examples/lit/pagination/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/lit-table": "^9.0.0-beta.42", + "@tanstack/lit-table": "^9.0.0-beta.43", "lit": "^3.3.3" }, "devDependencies": { diff --git a/examples/lit/pagination/src/main.ts b/examples/lit/pagination/src/main.ts index ee6b6d4ef3..5abd7be16e 100644 --- a/examples/lit/pagination/src/main.ts +++ b/examples/lit/pagination/src/main.ts @@ -20,6 +20,11 @@ const features = tableFeatures({ const columnHelper = createColumnHelper() const columns = columnHelper.columns([ + columnHelper.display({ + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }), columnHelper.accessor('firstName', { cell: (info) => info.getValue(), footer: (props) => props.column.id, diff --git a/examples/lit/row-pinning/package.json b/examples/lit/row-pinning/package.json index 3ddb534b75..e2d5ded25c 100644 --- a/examples/lit/row-pinning/package.json +++ b/examples/lit/row-pinning/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/lit-table": "^9.0.0-beta.42", + "@tanstack/lit-table": "^9.0.0-beta.43", "lit": "^3.3.3" }, "devDependencies": { diff --git a/examples/lit/row-selection/package.json b/examples/lit/row-selection/package.json index 66aa039ada..b421e2dde4 100644 --- a/examples/lit/row-selection/package.json +++ b/examples/lit/row-selection/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/lit-table": "^9.0.0-beta.42", + "@tanstack/lit-table": "^9.0.0-beta.43", "lit": "^3.3.3" }, "devDependencies": { diff --git a/examples/lit/sorting-dynamic-data/package.json b/examples/lit/sorting-dynamic-data/package.json index 8aea6ab40b..bab771a8a6 100644 --- a/examples/lit/sorting-dynamic-data/package.json +++ b/examples/lit/sorting-dynamic-data/package.json @@ -11,7 +11,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/lit-table": "^9.0.0-beta.42", + "@tanstack/lit-table": "^9.0.0-beta.43", "lit": "^3.3.3" }, "devDependencies": { diff --git a/examples/lit/sorting/package.json b/examples/lit/sorting/package.json index 18551187a7..0e9fc5e6ca 100644 --- a/examples/lit/sorting/package.json +++ b/examples/lit/sorting/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/lit-table": "^9.0.0-beta.42", + "@tanstack/lit-table": "^9.0.0-beta.43", "lit": "^3.3.3" }, "devDependencies": { diff --git a/examples/lit/sorting/src/main.ts b/examples/lit/sorting/src/main.ts index d66c39eeaf..c321b61523 100644 --- a/examples/lit/sorting/src/main.ts +++ b/examples/lit/sorting/src/main.ts @@ -30,6 +30,11 @@ const sortStatusFn: SortFn = ( } const columns: Array> = [ + { + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }, { accessorKey: 'firstName', cell: (info) => info.getValue(), diff --git a/examples/lit/sub-components/package.json b/examples/lit/sub-components/package.json index 84956f5028..63a4595f34 100644 --- a/examples/lit/sub-components/package.json +++ b/examples/lit/sub-components/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/lit-table": "^9.0.0-beta.42", + "@tanstack/lit-table": "^9.0.0-beta.43", "lit": "^3.3.3" }, "devDependencies": { diff --git a/examples/lit/virtualized-columns/package.json b/examples/lit/virtualized-columns/package.json index 07fc456961..177a967639 100644 --- a/examples/lit/virtualized-columns/package.json +++ b/examples/lit/virtualized-columns/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/lit-table": "^9.0.0-beta.42", + "@tanstack/lit-table": "^9.0.0-beta.43", "@tanstack/lit-virtual": "^3.13.32", "lit": "^3.3.3" }, diff --git a/examples/lit/virtualized-infinite-scrolling/package.json b/examples/lit/virtualized-infinite-scrolling/package.json index 902477b141..b1161e427a 100644 --- a/examples/lit/virtualized-infinite-scrolling/package.json +++ b/examples/lit/virtualized-infinite-scrolling/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/lit-table": "^9.0.0-beta.42", + "@tanstack/lit-table": "^9.0.0-beta.43", "@tanstack/lit-virtual": "^3.13.32", "lit": "^3.3.3" }, diff --git a/examples/lit/virtualized-rows/package.json b/examples/lit/virtualized-rows/package.json index f6e98e02dd..98825af084 100644 --- a/examples/lit/virtualized-rows/package.json +++ b/examples/lit/virtualized-rows/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/lit-table": "^9.0.0-beta.42", + "@tanstack/lit-table": "^9.0.0-beta.43", "@tanstack/lit-virtual": "^3.13.32", "lit": "^3.3.3" }, diff --git a/examples/preact/basic-dynamic-columns/package.json b/examples/preact/basic-dynamic-columns/package.json index 351abdd168..515d05ae34 100644 --- a/examples/preact/basic-dynamic-columns/package.json +++ b/examples/preact/basic-dynamic-columns/package.json @@ -15,8 +15,8 @@ "@faker-js/faker": "^10.5.0", "@tanstack/preact-devtools": "^0.10.8", "@tanstack/preact-pacer": "^0.22.1", - "@tanstack/preact-table": "^9.0.0-beta.42", - "@tanstack/preact-table-devtools": "^9.0.0-beta.42", + "@tanstack/preact-table": "^9.0.0-beta.43", + "@tanstack/preact-table-devtools": "^9.0.0-beta.43", "preact": "^10.29.2" }, "devDependencies": { diff --git a/examples/preact/basic-external-atoms/package.json b/examples/preact/basic-external-atoms/package.json index 76be1cc03e..b4057c5ec1 100644 --- a/examples/preact/basic-external-atoms/package.json +++ b/examples/preact/basic-external-atoms/package.json @@ -15,8 +15,8 @@ "@faker-js/faker": "^10.5.0", "@tanstack/preact-devtools": "^0.10.8", "@tanstack/preact-store": "^0.13.1", - "@tanstack/preact-table": "^9.0.0-beta.42", - "@tanstack/preact-table-devtools": "^9.0.0-beta.42", + "@tanstack/preact-table": "^9.0.0-beta.43", + "@tanstack/preact-table-devtools": "^9.0.0-beta.43", "preact": "^10.29.2" }, "devDependencies": { diff --git a/examples/preact/basic-external-state/package.json b/examples/preact/basic-external-state/package.json index d91160ca13..0e5db1bdf1 100644 --- a/examples/preact/basic-external-state/package.json +++ b/examples/preact/basic-external-state/package.json @@ -15,8 +15,8 @@ "@faker-js/faker": "^10.5.0", "@tanstack/preact-devtools": "^0.10.8", "@tanstack/preact-store": "^0.13.1", - "@tanstack/preact-table": "^9.0.0-beta.42", - "@tanstack/preact-table-devtools": "^9.0.0-beta.42", + "@tanstack/preact-table": "^9.0.0-beta.43", + "@tanstack/preact-table-devtools": "^9.0.0-beta.43", "preact": "^10.29.2" }, "devDependencies": { diff --git a/examples/preact/basic-subscribe/package.json b/examples/preact/basic-subscribe/package.json index 0047970399..fc65b7ffd8 100644 --- a/examples/preact/basic-subscribe/package.json +++ b/examples/preact/basic-subscribe/package.json @@ -15,8 +15,8 @@ "@faker-js/faker": "^10.5.0", "@tanstack/preact-devtools": "^0.10.8", "@tanstack/preact-store": "^0.13.1", - "@tanstack/preact-table": "^9.0.0-beta.42", - "@tanstack/preact-table-devtools": "^9.0.0-beta.42", + "@tanstack/preact-table": "^9.0.0-beta.43", + "@tanstack/preact-table-devtools": "^9.0.0-beta.43", "preact": "^10.29.2" }, "devDependencies": { diff --git a/examples/preact/basic-use-app-table/package.json b/examples/preact/basic-use-app-table/package.json index 6b5cef4ab1..ca6288543c 100644 --- a/examples/preact/basic-use-app-table/package.json +++ b/examples/preact/basic-use-app-table/package.json @@ -13,8 +13,8 @@ }, "dependencies": { "@tanstack/preact-devtools": "^0.10.8", - "@tanstack/preact-table": "^9.0.0-beta.42", - "@tanstack/preact-table-devtools": "^9.0.0-beta.42", + "@tanstack/preact-table": "^9.0.0-beta.43", + "@tanstack/preact-table-devtools": "^9.0.0-beta.43", "preact": "^10.29.2" }, "devDependencies": { diff --git a/examples/preact/basic-use-table/package.json b/examples/preact/basic-use-table/package.json index 6a98c18060..a51c08ad4d 100644 --- a/examples/preact/basic-use-table/package.json +++ b/examples/preact/basic-use-table/package.json @@ -13,8 +13,8 @@ }, "dependencies": { "@tanstack/preact-devtools": "^0.10.8", - "@tanstack/preact-table": "^9.0.0-beta.42", - "@tanstack/preact-table-devtools": "^9.0.0-beta.42", + "@tanstack/preact-table": "^9.0.0-beta.43", + "@tanstack/preact-table-devtools": "^9.0.0-beta.43", "preact": "^10.29.2" }, "devDependencies": { diff --git a/examples/preact/column-groups/package.json b/examples/preact/column-groups/package.json index 616f27a602..1288434ba2 100644 --- a/examples/preact/column-groups/package.json +++ b/examples/preact/column-groups/package.json @@ -13,7 +13,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/preact-table": "^9.0.0-beta.42", + "@tanstack/preact-table": "^9.0.0-beta.43", "preact": "^10.29.2" }, "devDependencies": { diff --git a/examples/preact/column-ordering/package.json b/examples/preact/column-ordering/package.json index 1623662b0d..ac00890270 100644 --- a/examples/preact/column-ordering/package.json +++ b/examples/preact/column-ordering/package.json @@ -13,7 +13,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/preact-table": "^9.0.0-beta.42", + "@tanstack/preact-table": "^9.0.0-beta.43", "preact": "^10.29.2" }, "devDependencies": { diff --git a/examples/preact/column-pinning-split/package.json b/examples/preact/column-pinning-split/package.json index b675a1286a..55121e5dbf 100644 --- a/examples/preact/column-pinning-split/package.json +++ b/examples/preact/column-pinning-split/package.json @@ -13,7 +13,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/preact-table": "^9.0.0-beta.42", + "@tanstack/preact-table": "^9.0.0-beta.43", "preact": "^10.29.2" }, "devDependencies": { diff --git a/examples/preact/column-pinning-sticky/package.json b/examples/preact/column-pinning-sticky/package.json index 65da11d1ee..7f55cabb4e 100644 --- a/examples/preact/column-pinning-sticky/package.json +++ b/examples/preact/column-pinning-sticky/package.json @@ -13,7 +13,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/preact-table": "^9.0.0-beta.42", + "@tanstack/preact-table": "^9.0.0-beta.43", "preact": "^10.29.2" }, "devDependencies": { diff --git a/examples/preact/column-pinning/package.json b/examples/preact/column-pinning/package.json index cd082e1a8e..beb2fd535d 100644 --- a/examples/preact/column-pinning/package.json +++ b/examples/preact/column-pinning/package.json @@ -13,7 +13,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/preact-table": "^9.0.0-beta.42", + "@tanstack/preact-table": "^9.0.0-beta.43", "preact": "^10.29.2" }, "devDependencies": { diff --git a/examples/preact/column-resizing-performant/package.json b/examples/preact/column-resizing-performant/package.json index 94978e03fd..02e0920837 100644 --- a/examples/preact/column-resizing-performant/package.json +++ b/examples/preact/column-resizing-performant/package.json @@ -13,7 +13,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/preact-table": "^9.0.0-beta.42", + "@tanstack/preact-table": "^9.0.0-beta.43", "preact": "^10.29.2" }, "devDependencies": { diff --git a/examples/preact/column-resizing/package.json b/examples/preact/column-resizing/package.json index 9d3d81cb60..82b4e93beb 100644 --- a/examples/preact/column-resizing/package.json +++ b/examples/preact/column-resizing/package.json @@ -13,7 +13,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/preact-table": "^9.0.0-beta.42", + "@tanstack/preact-table": "^9.0.0-beta.43", "preact": "^10.29.2" }, "devDependencies": { diff --git a/examples/preact/column-sizing/package.json b/examples/preact/column-sizing/package.json index fec9e9308d..58c0318835 100644 --- a/examples/preact/column-sizing/package.json +++ b/examples/preact/column-sizing/package.json @@ -13,7 +13,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/preact-table": "^9.0.0-beta.42", + "@tanstack/preact-table": "^9.0.0-beta.43", "preact": "^10.29.2" }, "devDependencies": { diff --git a/examples/preact/column-visibility/package.json b/examples/preact/column-visibility/package.json index f81d8b416e..9f7cc52336 100644 --- a/examples/preact/column-visibility/package.json +++ b/examples/preact/column-visibility/package.json @@ -13,7 +13,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/preact-table": "^9.0.0-beta.42", + "@tanstack/preact-table": "^9.0.0-beta.43", "preact": "^10.29.2" }, "devDependencies": { diff --git a/examples/preact/composable-tables/package.json b/examples/preact/composable-tables/package.json index b736704cfc..f5d2678ab0 100644 --- a/examples/preact/composable-tables/package.json +++ b/examples/preact/composable-tables/package.json @@ -15,8 +15,8 @@ "@faker-js/faker": "^10.5.0", "@tanstack/preact-devtools": "^0.10.8", "@tanstack/preact-store": "^0.13.1", - "@tanstack/preact-table": "^9.0.0-beta.42", - "@tanstack/preact-table-devtools": "^9.0.0-beta.42", + "@tanstack/preact-table": "^9.0.0-beta.43", + "@tanstack/preact-table-devtools": "^9.0.0-beta.43", "preact": "^10.29.2" }, "devDependencies": { diff --git a/examples/preact/custom-plugin/package.json b/examples/preact/custom-plugin/package.json index 37ccf4efbb..b026f0b4e6 100644 --- a/examples/preact/custom-plugin/package.json +++ b/examples/preact/custom-plugin/package.json @@ -13,7 +13,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/preact-table": "^9.0.0-beta.42", + "@tanstack/preact-table": "^9.0.0-beta.43", "preact": "^10.29.2" }, "devDependencies": { diff --git a/examples/preact/expanding/package.json b/examples/preact/expanding/package.json index 9d7f5fa94d..1a3255c4fc 100644 --- a/examples/preact/expanding/package.json +++ b/examples/preact/expanding/package.json @@ -13,7 +13,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/preact-table": "^9.0.0-beta.42", + "@tanstack/preact-table": "^9.0.0-beta.43", "preact": "^10.29.2" }, "devDependencies": { diff --git a/examples/preact/expanding/src/main.tsx b/examples/preact/expanding/src/main.tsx index 36d3c4f36a..3662b122cf 100644 --- a/examples/preact/expanding/src/main.tsx +++ b/examples/preact/expanding/src/main.tsx @@ -42,6 +42,11 @@ function App() { const columns = useMemo( () => columnHelper.columns([ + columnHelper.display({ + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }), columnHelper.accessor('firstName', { header: ({ table }) => ( <> diff --git a/examples/preact/filters-faceted/package.json b/examples/preact/filters-faceted/package.json index b62c691d6d..91ff8f9824 100644 --- a/examples/preact/filters-faceted/package.json +++ b/examples/preact/filters-faceted/package.json @@ -15,7 +15,7 @@ "@faker-js/faker": "^10.5.0", "@tanstack/match-sorter-utils": "^9.0.0-beta.41", "@tanstack/preact-pacer": "^0.22.1", - "@tanstack/preact-table": "^9.0.0-beta.42", + "@tanstack/preact-table": "^9.0.0-beta.43", "preact": "^10.29.2" }, "devDependencies": { diff --git a/examples/preact/filters-fuzzy/package.json b/examples/preact/filters-fuzzy/package.json index 983117abcc..e45ddb5cec 100644 --- a/examples/preact/filters-fuzzy/package.json +++ b/examples/preact/filters-fuzzy/package.json @@ -15,7 +15,7 @@ "@faker-js/faker": "^10.5.0", "@tanstack/match-sorter-utils": "^9.0.0-beta.41", "@tanstack/preact-pacer": "^0.22.1", - "@tanstack/preact-table": "^9.0.0-beta.42", + "@tanstack/preact-table": "^9.0.0-beta.43", "preact": "^10.29.2" }, "devDependencies": { diff --git a/examples/preact/filters/package.json b/examples/preact/filters/package.json index 63cc80b57d..3334d19c68 100644 --- a/examples/preact/filters/package.json +++ b/examples/preact/filters/package.json @@ -15,7 +15,7 @@ "@faker-js/faker": "^10.5.0", "@tanstack/match-sorter-utils": "^9.0.0-beta.41", "@tanstack/preact-pacer": "^0.22.1", - "@tanstack/preact-table": "^9.0.0-beta.42", + "@tanstack/preact-table": "^9.0.0-beta.43", "preact": "^10.29.2" }, "devDependencies": { diff --git a/examples/preact/filters/src/main.tsx b/examples/preact/filters/src/main.tsx index f1980678e2..1714c2f689 100644 --- a/examples/preact/filters/src/main.tsx +++ b/examples/preact/filters/src/main.tsx @@ -38,6 +38,11 @@ function App() { const columns = useMemo( () => columnHelper.columns([ + columnHelper.display({ + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }), columnHelper.accessor('firstName', { cell: (info) => info.getValue(), }), diff --git a/examples/preact/grouping/package.json b/examples/preact/grouping/package.json index 3215d20502..7d50253d9c 100644 --- a/examples/preact/grouping/package.json +++ b/examples/preact/grouping/package.json @@ -13,7 +13,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/preact-table": "^9.0.0-beta.42", + "@tanstack/preact-table": "^9.0.0-beta.43", "preact": "^10.29.2" }, "devDependencies": { diff --git a/examples/preact/kitchen-sink/package.json b/examples/preact/kitchen-sink/package.json index a938832f98..f9bf11634a 100644 --- a/examples/preact/kitchen-sink/package.json +++ b/examples/preact/kitchen-sink/package.json @@ -15,8 +15,8 @@ "@faker-js/faker": "^10.5.0", "@tanstack/match-sorter-utils": "^9.0.0-beta.41", "@tanstack/preact-devtools": "^0.10.8", - "@tanstack/preact-table": "^9.0.0-beta.42", - "@tanstack/preact-table-devtools": "^9.0.0-beta.42", + "@tanstack/preact-table": "^9.0.0-beta.43", + "@tanstack/preact-table-devtools": "^9.0.0-beta.43", "preact": "^10.29.2" }, "devDependencies": { diff --git a/examples/preact/pagination/package.json b/examples/preact/pagination/package.json index ab58df99aa..319389380a 100644 --- a/examples/preact/pagination/package.json +++ b/examples/preact/pagination/package.json @@ -14,7 +14,7 @@ "dependencies": { "@faker-js/faker": "^10.5.0", "@tanstack/preact-store": "^0.13.1", - "@tanstack/preact-table": "^9.0.0-beta.42", + "@tanstack/preact-table": "^9.0.0-beta.43", "preact": "^10.29.2" }, "devDependencies": { diff --git a/examples/preact/pagination/src/main.tsx b/examples/preact/pagination/src/main.tsx index b42a590032..a44f787f54 100644 --- a/examples/preact/pagination/src/main.tsx +++ b/examples/preact/pagination/src/main.tsx @@ -22,6 +22,11 @@ function App() { const columns = useMemo( () => columnHelper.columns([ + columnHelper.display({ + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }), columnHelper.accessor('firstName', { cell: (info) => info.getValue(), footer: (props) => props.column.id, diff --git a/examples/preact/row-pinning/package.json b/examples/preact/row-pinning/package.json index 041cce0703..769c26c205 100644 --- a/examples/preact/row-pinning/package.json +++ b/examples/preact/row-pinning/package.json @@ -13,7 +13,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/preact-table": "^9.0.0-beta.42", + "@tanstack/preact-table": "^9.0.0-beta.43", "preact": "^10.29.2" }, "devDependencies": { diff --git a/examples/preact/row-selection/package.json b/examples/preact/row-selection/package.json index a435a776ab..5f88526a0e 100644 --- a/examples/preact/row-selection/package.json +++ b/examples/preact/row-selection/package.json @@ -15,8 +15,8 @@ "@faker-js/faker": "^10.5.0", "@tanstack/preact-devtools": "^0.10.8", "@tanstack/preact-store": "^0.13.1", - "@tanstack/preact-table": "^9.0.0-beta.42", - "@tanstack/preact-table-devtools": "^9.0.0-beta.42", + "@tanstack/preact-table": "^9.0.0-beta.43", + "@tanstack/preact-table-devtools": "^9.0.0-beta.43", "preact": "^10.29.2" }, "devDependencies": { diff --git a/examples/preact/sorting/package.json b/examples/preact/sorting/package.json index f48890f4d4..d4cff30642 100644 --- a/examples/preact/sorting/package.json +++ b/examples/preact/sorting/package.json @@ -13,7 +13,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/preact-table": "^9.0.0-beta.42", + "@tanstack/preact-table": "^9.0.0-beta.43", "preact": "^10.29.2" }, "devDependencies": { diff --git a/examples/preact/sorting/src/main.tsx b/examples/preact/sorting/src/main.tsx index 71843561fe..8b11f903e9 100644 --- a/examples/preact/sorting/src/main.tsx +++ b/examples/preact/sorting/src/main.tsx @@ -35,6 +35,11 @@ function App() { const columns = useMemo( () => columnHelper.columns([ + columnHelper.display({ + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }), columnHelper.accessor('firstName', { cell: (info) => info.getValue(), }), diff --git a/examples/preact/sub-components/package.json b/examples/preact/sub-components/package.json index 74e8ce7027..161a9053d7 100644 --- a/examples/preact/sub-components/package.json +++ b/examples/preact/sub-components/package.json @@ -13,7 +13,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/preact-table": "^9.0.0-beta.42", + "@tanstack/preact-table": "^9.0.0-beta.43", "preact": "^10.29.2" }, "devDependencies": { diff --git a/examples/preact/with-tanstack-form/package.json b/examples/preact/with-tanstack-form/package.json index cb66f26146..fa6ed9d806 100644 --- a/examples/preact/with-tanstack-form/package.json +++ b/examples/preact/with-tanstack-form/package.json @@ -16,8 +16,8 @@ "@tanstack/preact-devtools": "^0.10.8", "@tanstack/preact-form": "^1.30.1", "@tanstack/preact-pacer": "^0.22.1", - "@tanstack/preact-table": "^9.0.0-beta.42", - "@tanstack/preact-table-devtools": "^9.0.0-beta.42", + "@tanstack/preact-table": "^9.0.0-beta.43", + "@tanstack/preact-table-devtools": "^9.0.0-beta.43", "@tanstack/react-form-devtools": "^0.2.30", "preact": "^10.29.2", "zod": "^4.4.3" diff --git a/examples/preact/with-tanstack-query/package.json b/examples/preact/with-tanstack-query/package.json index 8e165e54f4..d16736ef79 100644 --- a/examples/preact/with-tanstack-query/package.json +++ b/examples/preact/with-tanstack-query/package.json @@ -15,7 +15,7 @@ "@faker-js/faker": "^10.5.0", "@tanstack/preact-query": "^5.101.2", "@tanstack/preact-store": "^0.13.1", - "@tanstack/preact-table": "^9.0.0-beta.42", + "@tanstack/preact-table": "^9.0.0-beta.43", "preact": "^10.29.2" }, "devDependencies": { diff --git a/examples/react/basic-dynamic-columns/package.json b/examples/react/basic-dynamic-columns/package.json index 6f4632de5e..5787051b8d 100644 --- a/examples/react/basic-dynamic-columns/package.json +++ b/examples/react/basic-dynamic-columns/package.json @@ -14,8 +14,8 @@ "@faker-js/faker": "^10.5.0", "@tanstack/react-devtools": "^0.10.8", "@tanstack/react-pacer": "^0.22.1", - "@tanstack/react-table": "^9.0.0-beta.42", - "@tanstack/react-table-devtools": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", + "@tanstack/react-table-devtools": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/basic-external-atoms/package.json b/examples/react/basic-external-atoms/package.json index 9c52529544..b4f8b8e23f 100644 --- a/examples/react/basic-external-atoms/package.json +++ b/examples/react/basic-external-atoms/package.json @@ -14,8 +14,8 @@ "@faker-js/faker": "^10.5.0", "@tanstack/react-devtools": "^0.10.8", "@tanstack/react-store": "^0.11.0", - "@tanstack/react-table": "^9.0.0-beta.42", - "@tanstack/react-table-devtools": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", + "@tanstack/react-table-devtools": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/basic-external-state/package.json b/examples/react/basic-external-state/package.json index 145b8c5924..8c7bc48a73 100644 --- a/examples/react/basic-external-state/package.json +++ b/examples/react/basic-external-state/package.json @@ -14,8 +14,8 @@ "@faker-js/faker": "^10.5.0", "@tanstack/react-devtools": "^0.10.8", "@tanstack/react-store": "^0.11.0", - "@tanstack/react-table": "^9.0.0-beta.42", - "@tanstack/react-table-devtools": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", + "@tanstack/react-table-devtools": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/basic-subscribe/package.json b/examples/react/basic-subscribe/package.json index afd86809c5..c863455f7e 100644 --- a/examples/react/basic-subscribe/package.json +++ b/examples/react/basic-subscribe/package.json @@ -15,8 +15,8 @@ "@tanstack/react-devtools": "^0.10.8", "@tanstack/react-pacer": "^0.22.1", "@tanstack/react-store": "^0.11.0", - "@tanstack/react-table": "^9.0.0-beta.42", - "@tanstack/react-table-devtools": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", + "@tanstack/react-table-devtools": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/basic-use-app-table/package.json b/examples/react/basic-use-app-table/package.json index fa7e351b7b..fbd4da5c0f 100644 --- a/examples/react/basic-use-app-table/package.json +++ b/examples/react/basic-use-app-table/package.json @@ -12,8 +12,8 @@ }, "dependencies": { "@tanstack/react-devtools": "^0.10.8", - "@tanstack/react-table": "^9.0.0-beta.42", - "@tanstack/react-table-devtools": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", + "@tanstack/react-table-devtools": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/basic-use-legacy-table/package.json b/examples/react/basic-use-legacy-table/package.json index dcd06d7c6b..1b91461e6e 100644 --- a/examples/react/basic-use-legacy-table/package.json +++ b/examples/react/basic-use-legacy-table/package.json @@ -14,8 +14,8 @@ "@faker-js/faker": "^10.5.0", "@tanstack/react-devtools": "^0.10.8", "@tanstack/react-pacer": "^0.22.1", - "@tanstack/react-table": "^9.0.0-beta.42", - "@tanstack/react-table-devtools": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", + "@tanstack/react-table-devtools": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/basic-use-table/package.json b/examples/react/basic-use-table/package.json index 686859e40b..ee2bb92b7d 100644 --- a/examples/react/basic-use-table/package.json +++ b/examples/react/basic-use-table/package.json @@ -12,8 +12,8 @@ }, "dependencies": { "@tanstack/react-devtools": "^0.10.8", - "@tanstack/react-table": "^9.0.0-beta.42", - "@tanstack/react-table-devtools": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", + "@tanstack/react-table-devtools": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/column-dnd/package.json b/examples/react/column-dnd/package.json index 87bdcc376a..2f428e86b7 100644 --- a/examples/react/column-dnd/package.json +++ b/examples/react/column-dnd/package.json @@ -16,7 +16,7 @@ "@dnd-kit/sortable": "^10.0.0", "@dnd-kit/utilities": "^3.2.2", "@faker-js/faker": "^10.5.0", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/column-groups/package.json b/examples/react/column-groups/package.json index 056023a02b..4d7c887552 100644 --- a/examples/react/column-groups/package.json +++ b/examples/react/column-groups/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/column-ordering/package.json b/examples/react/column-ordering/package.json index 4a6782c441..4fd47301d6 100644 --- a/examples/react/column-ordering/package.json +++ b/examples/react/column-ordering/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/column-pinning-split/package.json b/examples/react/column-pinning-split/package.json index c93bbff649..783049039c 100644 --- a/examples/react/column-pinning-split/package.json +++ b/examples/react/column-pinning-split/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/column-pinning-sticky/package.json b/examples/react/column-pinning-sticky/package.json index faeaffc935..038dbc4fee 100644 --- a/examples/react/column-pinning-sticky/package.json +++ b/examples/react/column-pinning-sticky/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/column-pinning/package.json b/examples/react/column-pinning/package.json index 89b00f5c7c..cb0f177ac2 100644 --- a/examples/react/column-pinning/package.json +++ b/examples/react/column-pinning/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/column-resizing-performant/package.json b/examples/react/column-resizing-performant/package.json index bacfae33c2..0cbd8e49ec 100644 --- a/examples/react/column-resizing-performant/package.json +++ b/examples/react/column-resizing-performant/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/column-resizing/package.json b/examples/react/column-resizing/package.json index 363ec4abd3..cd0eb81cae 100644 --- a/examples/react/column-resizing/package.json +++ b/examples/react/column-resizing/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/column-sizing/package.json b/examples/react/column-sizing/package.json index 1663c954f0..869d2567fe 100644 --- a/examples/react/column-sizing/package.json +++ b/examples/react/column-sizing/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/column-visibility/package.json b/examples/react/column-visibility/package.json index e3a1b602ec..5b015e1fa9 100644 --- a/examples/react/column-visibility/package.json +++ b/examples/react/column-visibility/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/composable-tables/package.json b/examples/react/composable-tables/package.json index 93e93db84b..70b5d3a0f2 100644 --- a/examples/react/composable-tables/package.json +++ b/examples/react/composable-tables/package.json @@ -14,8 +14,8 @@ "@faker-js/faker": "^10.5.0", "@tanstack/react-devtools": "^0.10.8", "@tanstack/react-store": "^0.11.0", - "@tanstack/react-table": "^9.0.0-beta.42", - "@tanstack/react-table-devtools": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", + "@tanstack/react-table-devtools": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/custom-plugin/package.json b/examples/react/custom-plugin/package.json index 1f8fa1cb0a..8a7f9d27a1 100644 --- a/examples/react/custom-plugin/package.json +++ b/examples/react/custom-plugin/package.json @@ -13,7 +13,7 @@ "dependencies": { "@faker-js/faker": "^10.5.0", "@tanstack/react-pacer": "^0.22.1", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/expanding/package.json b/examples/react/expanding/package.json index 66889b955e..d6e996a6de 100644 --- a/examples/react/expanding/package.json +++ b/examples/react/expanding/package.json @@ -13,7 +13,7 @@ "dependencies": { "@faker-js/faker": "^10.5.0", "@tanstack/react-pacer": "^0.22.1", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/expanding/src/main.tsx b/examples/react/expanding/src/main.tsx index 67a60bbe01..9e88ab3f7f 100644 --- a/examples/react/expanding/src/main.tsx +++ b/examples/react/expanding/src/main.tsx @@ -43,6 +43,11 @@ function App() { const columns = React.useMemo( () => columnHelper.columns([ + columnHelper.display({ + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }), columnHelper.accessor('firstName', { header: ({ table }) => ( <> @@ -129,6 +134,7 @@ function App() { columns, data, getSubRows: (row) => row.subRows, + // paginateExpandedRows: false, // filterFromLeafRows: true, // maxLeafRowFilterDepth: 0, debugTable: true, diff --git a/examples/react/filters-faceted/package.json b/examples/react/filters-faceted/package.json index 968582c300..0151ec1bb5 100644 --- a/examples/react/filters-faceted/package.json +++ b/examples/react/filters-faceted/package.json @@ -14,7 +14,7 @@ "@faker-js/faker": "^10.5.0", "@tanstack/match-sorter-utils": "^9.0.0-beta.41", "@tanstack/react-pacer": "^0.22.1", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/filters-fuzzy/package.json b/examples/react/filters-fuzzy/package.json index 046d6ea703..7be4f5613e 100644 --- a/examples/react/filters-fuzzy/package.json +++ b/examples/react/filters-fuzzy/package.json @@ -14,7 +14,7 @@ "@faker-js/faker": "^10.5.0", "@tanstack/match-sorter-utils": "^9.0.0-beta.41", "@tanstack/react-pacer": "^0.22.1", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/filters/package.json b/examples/react/filters/package.json index e4c9217301..45b463b4bf 100644 --- a/examples/react/filters/package.json +++ b/examples/react/filters/package.json @@ -14,7 +14,7 @@ "@faker-js/faker": "^10.5.0", "@tanstack/match-sorter-utils": "^9.0.0-beta.41", "@tanstack/react-pacer": "^0.22.1", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/filters/src/main.tsx b/examples/react/filters/src/main.tsx index 14c0f82ddd..b530f38ddb 100644 --- a/examples/react/filters/src/main.tsx +++ b/examples/react/filters/src/main.tsx @@ -37,6 +37,11 @@ function App() { const columns = React.useMemo( () => columnHelper.columns([ + columnHelper.display({ + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }), columnHelper.accessor('firstName', { cell: (info) => info.getValue(), }), diff --git a/examples/react/grouping/package.json b/examples/react/grouping/package.json index 3b53fad197..636ce87b9a 100644 --- a/examples/react/grouping/package.json +++ b/examples/react/grouping/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/kitchen-sink-chakra-ui/package.json b/examples/react/kitchen-sink-chakra-ui/package.json index de338d7109..96273946c2 100644 --- a/examples/react/kitchen-sink-chakra-ui/package.json +++ b/examples/react/kitchen-sink-chakra-ui/package.json @@ -22,8 +22,8 @@ "@tanstack/match-sorter-utils": "^9.0.0-beta.41", "@tanstack/react-devtools": "^0.10.8", "@tanstack/react-pacer": "^0.22.1", - "@tanstack/react-table": "^9.0.0-beta.42", - "@tanstack/react-table-devtools": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", + "@tanstack/react-table-devtools": "^9.0.0-beta.43", "date-fns": "^4.4.0", "next-themes": "^0.4.6", "react": "^19.2.7", diff --git a/examples/react/kitchen-sink-hero-ui/package.json b/examples/react/kitchen-sink-hero-ui/package.json index bd4a660baf..68b16d5e4c 100644 --- a/examples/react/kitchen-sink-hero-ui/package.json +++ b/examples/react/kitchen-sink-hero-ui/package.json @@ -23,8 +23,8 @@ "@tanstack/match-sorter-utils": "^9.0.0-beta.41", "@tanstack/react-devtools": "^0.10.8", "@tanstack/react-pacer": "^0.22.1", - "@tanstack/react-table": "^9.0.0-beta.42", - "@tanstack/react-table-devtools": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", + "@tanstack/react-table-devtools": "^9.0.0-beta.43", "date-fns": "^4.4.0", "react": "^19.2.7", "react-dom": "^19.2.7", diff --git a/examples/react/kitchen-sink-mantine/package.json b/examples/react/kitchen-sink-mantine/package.json index a7f6d6cc0d..c7b010286d 100644 --- a/examples/react/kitchen-sink-mantine/package.json +++ b/examples/react/kitchen-sink-mantine/package.json @@ -22,8 +22,8 @@ "@tanstack/match-sorter-utils": "^9.0.0-beta.41", "@tanstack/react-devtools": "^0.10.8", "@tanstack/react-pacer": "^0.22.1", - "@tanstack/react-table": "^9.0.0-beta.42", - "@tanstack/react-table-devtools": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", + "@tanstack/react-table-devtools": "^9.0.0-beta.43", "date-fns": "^4.4.0", "react": "^19.2.7", "react-dom": "^19.2.7" diff --git a/examples/react/kitchen-sink-material-ui/package.json b/examples/react/kitchen-sink-material-ui/package.json index f3a8dc1793..fadaba2f95 100644 --- a/examples/react/kitchen-sink-material-ui/package.json +++ b/examples/react/kitchen-sink-material-ui/package.json @@ -23,8 +23,8 @@ "@tanstack/match-sorter-utils": "^9.0.0-beta.41", "@tanstack/react-devtools": "^0.10.8", "@tanstack/react-pacer": "^0.22.1", - "@tanstack/react-table": "^9.0.0-beta.42", - "@tanstack/react-table-devtools": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", + "@tanstack/react-table-devtools": "^9.0.0-beta.43", "date-fns": "^4.4.0", "react": "^19.2.7", "react-dom": "^19.2.7" diff --git a/examples/react/kitchen-sink-react-aria/package.json b/examples/react/kitchen-sink-react-aria/package.json index 6b13e6baa1..856b82fb67 100644 --- a/examples/react/kitchen-sink-react-aria/package.json +++ b/examples/react/kitchen-sink-react-aria/package.json @@ -21,8 +21,8 @@ "@tanstack/match-sorter-utils": "^9.0.0-beta.41", "@tanstack/react-devtools": "^0.10.8", "@tanstack/react-pacer": "^0.22.1", - "@tanstack/react-table": "^9.0.0-beta.42", - "@tanstack/react-table-devtools": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", + "@tanstack/react-table-devtools": "^9.0.0-beta.43", "date-fns": "^4.4.0", "react": "^19.2.7", "react-aria-components": "^1.19.0", diff --git a/examples/react/kitchen-sink-shadcn-base/package.json b/examples/react/kitchen-sink-shadcn-base/package.json index b3e7dc6f79..f77d68245c 100644 --- a/examples/react/kitchen-sink-shadcn-base/package.json +++ b/examples/react/kitchen-sink-shadcn-base/package.json @@ -23,8 +23,8 @@ "@tanstack/match-sorter-utils": "^9.0.0-beta.41", "@tanstack/react-devtools": "^0.10.8", "@tanstack/react-pacer": "^0.22.1", - "@tanstack/react-table": "^9.0.0-beta.42", - "@tanstack/react-table-devtools": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", + "@tanstack/react-table-devtools": "^9.0.0-beta.43", "class-variance-authority": "^0.7.1", "clsx": "^2.1.1", "cmdk": "1.1.1", diff --git a/examples/react/kitchen-sink-shadcn-radix/package.json b/examples/react/kitchen-sink-shadcn-radix/package.json index 6dbc3b23c4..cf2d9fad25 100644 --- a/examples/react/kitchen-sink-shadcn-radix/package.json +++ b/examples/react/kitchen-sink-shadcn-radix/package.json @@ -22,8 +22,8 @@ "@tanstack/match-sorter-utils": "^9.0.0-beta.41", "@tanstack/react-devtools": "^0.10.8", "@tanstack/react-pacer": "^0.22.1", - "@tanstack/react-table": "^9.0.0-beta.42", - "@tanstack/react-table-devtools": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", + "@tanstack/react-table-devtools": "^9.0.0-beta.43", "class-variance-authority": "^0.7.1", "clsx": "^2.1.1", "cmdk": "1.1.1", diff --git a/examples/react/kitchen-sink/package.json b/examples/react/kitchen-sink/package.json index 4d5ab24d71..5a889f3548 100644 --- a/examples/react/kitchen-sink/package.json +++ b/examples/react/kitchen-sink/package.json @@ -23,8 +23,8 @@ "@tanstack/react-router": "^1.170.17", "@tanstack/react-start": "^1.168.27", "@tanstack/react-store": "^0.11.0", - "@tanstack/react-table": "^9.0.0-beta.42", - "@tanstack/react-table-devtools": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", + "@tanstack/react-table-devtools": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/lib-chakra-ui/package.json b/examples/react/lib-chakra-ui/package.json index baf9261dee..cd378e034d 100644 --- a/examples/react/lib-chakra-ui/package.json +++ b/examples/react/lib-chakra-ui/package.json @@ -16,7 +16,7 @@ "@emotion/react": "^11.14.0", "@faker-js/faker": "^10.5.0", "@tabler/icons-react": "^3.44.0", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/lib-hero-ui/package.json b/examples/react/lib-hero-ui/package.json index b4a6d5c31f..a2daf5f8f5 100644 --- a/examples/react/lib-hero-ui/package.json +++ b/examples/react/lib-hero-ui/package.json @@ -16,7 +16,7 @@ "@heroui/react": "^3.2.1", "@heroui/styles": "^3.2.1", "@tailwindcss/vite": "^4.3.1", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7", "tailwindcss": "^4.3.1" diff --git a/examples/react/lib-mantine/package.json b/examples/react/lib-mantine/package.json index 60c2089303..27546f00cf 100644 --- a/examples/react/lib-mantine/package.json +++ b/examples/react/lib-mantine/package.json @@ -16,7 +16,7 @@ "@mantine/core": "^9.4.0", "@mantine/hooks": "^9.4.0", "@tabler/icons-react": "^3.44.0", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/lib-material-ui/package.json b/examples/react/lib-material-ui/package.json index ed96926e60..cfcdf5b6f9 100644 --- a/examples/react/lib-material-ui/package.json +++ b/examples/react/lib-material-ui/package.json @@ -17,7 +17,7 @@ "@faker-js/faker": "^10.5.0", "@mui/icons-material": "^9.1.1", "@mui/material": "^9.1.2", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/lib-react-aria/package.json b/examples/react/lib-react-aria/package.json index 5e10215c3e..616310b35c 100644 --- a/examples/react/lib-react-aria/package.json +++ b/examples/react/lib-react-aria/package.json @@ -14,7 +14,7 @@ "dependencies": { "@faker-js/faker": "^10.5.0", "@tailwindcss/vite": "^4.3.1", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "react": "^19.2.7", "react-aria-components": "^1.19.0", "react-dom": "^19.2.7", diff --git a/examples/react/lib-shadcn-base/package.json b/examples/react/lib-shadcn-base/package.json index b24c635dec..5975e594cb 100644 --- a/examples/react/lib-shadcn-base/package.json +++ b/examples/react/lib-shadcn-base/package.json @@ -16,7 +16,7 @@ "@faker-js/faker": "^10.5.0", "@tailwindcss/vite": "^4.3.1", "@tanstack/react-pacer": "^0.22.1", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "class-variance-authority": "^0.7.1", "clsx": "^2.1.1", "lucide-react": "^1.21.0", diff --git a/examples/react/lib-shadcn-radix/package.json b/examples/react/lib-shadcn-radix/package.json index 90edd8fc0e..1f9843fa08 100644 --- a/examples/react/lib-shadcn-radix/package.json +++ b/examples/react/lib-shadcn-radix/package.json @@ -15,7 +15,7 @@ "@faker-js/faker": "^10.5.0", "@tailwindcss/vite": "^4.3.1", "@tanstack/react-pacer": "^0.22.1", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "class-variance-authority": "^0.7.1", "clsx": "^2.1.1", "lucide-react": "^1.21.0", diff --git a/examples/react/mantine-react-table/package.json b/examples/react/mantine-react-table/package.json index ad62f67efa..9ea4393527 100644 --- a/examples/react/mantine-react-table/package.json +++ b/examples/react/mantine-react-table/package.json @@ -18,7 +18,7 @@ "@tabler/icons-react": "^3.44.0", "@tanstack/match-sorter-utils": "^9.0.0-beta.41", "@tanstack/react-store": "^0.11.0", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "@tanstack/react-virtual": "^3.14.5", "clsx": "^2.1.1", "dayjs": "^1.11.21", diff --git a/examples/react/material-react-table/package.json b/examples/react/material-react-table/package.json index 0e81942c5a..a0f6c902fe 100644 --- a/examples/react/material-react-table/package.json +++ b/examples/react/material-react-table/package.json @@ -21,7 +21,7 @@ "@tanstack/match-sorter-utils": "^9.0.0-beta.41", "@tanstack/react-pacer": "^0.22.1", "@tanstack/react-store": "^0.11.0", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "@tanstack/react-virtual": "^3.14.5", "highlight-words": "^2.0.0", "react": "^19.2.7", diff --git a/examples/react/pagination/package.json b/examples/react/pagination/package.json index 93dc7e7000..fc9c75e0a8 100644 --- a/examples/react/pagination/package.json +++ b/examples/react/pagination/package.json @@ -13,7 +13,7 @@ "dependencies": { "@faker-js/faker": "^10.5.0", "@tanstack/react-store": "^0.11.0", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/pagination/src/main.tsx b/examples/react/pagination/src/main.tsx index 63ca961618..0c0d126dde 100644 --- a/examples/react/pagination/src/main.tsx +++ b/examples/react/pagination/src/main.tsx @@ -22,6 +22,11 @@ function App() { const columns = React.useMemo( () => columnHelper.columns([ + columnHelper.display({ + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }), columnHelper.accessor('firstName', { cell: (info) => info.getValue(), footer: (props) => props.column.id, diff --git a/examples/react/row-dnd/package.json b/examples/react/row-dnd/package.json index 8a24f3685c..cc94aae02f 100644 --- a/examples/react/row-dnd/package.json +++ b/examples/react/row-dnd/package.json @@ -16,7 +16,7 @@ "@dnd-kit/sortable": "^10.0.0", "@dnd-kit/utilities": "^3.2.2", "@faker-js/faker": "^10.5.0", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/row-pinning/package.json b/examples/react/row-pinning/package.json index 448c89d5c5..4afbcf6c4c 100644 --- a/examples/react/row-pinning/package.json +++ b/examples/react/row-pinning/package.json @@ -13,7 +13,7 @@ "dependencies": { "@faker-js/faker": "^10.5.0", "@tanstack/react-pacer": "^0.22.1", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/row-selection/package.json b/examples/react/row-selection/package.json index f13e707c1e..eae76bc379 100644 --- a/examples/react/row-selection/package.json +++ b/examples/react/row-selection/package.json @@ -15,8 +15,8 @@ "@tanstack/react-devtools": "^0.10.8", "@tanstack/react-pacer": "^0.22.1", "@tanstack/react-store": "^0.11.0", - "@tanstack/react-table": "^9.0.0-beta.42", - "@tanstack/react-table-devtools": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", + "@tanstack/react-table-devtools": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/sorting/package.json b/examples/react/sorting/package.json index ba71f97d34..0a51e13830 100644 --- a/examples/react/sorting/package.json +++ b/examples/react/sorting/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/sorting/src/main.tsx b/examples/react/sorting/src/main.tsx index 540b161661..106809e5b5 100644 --- a/examples/react/sorting/src/main.tsx +++ b/examples/react/sorting/src/main.tsx @@ -37,6 +37,11 @@ function App() { const columns = React.useMemo( () => columnHelper.columns([ + columnHelper.display({ + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }), columnHelper.accessor('firstName', { cell: (info) => info.getValue(), // this column will sort in ascending order by default since it is a string column diff --git a/examples/react/sub-components/package.json b/examples/react/sub-components/package.json index a8117ac569..2a4602af52 100644 --- a/examples/react/sub-components/package.json +++ b/examples/react/sub-components/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/virtualized-columns-experimental/package.json b/examples/react/virtualized-columns-experimental/package.json index d096ebd9f0..ff13f6525e 100644 --- a/examples/react/virtualized-columns-experimental/package.json +++ b/examples/react/virtualized-columns-experimental/package.json @@ -11,7 +11,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "@tanstack/react-virtual": "^3.14.5", "react": "^19.2.7", "react-dom": "^19.2.7" diff --git a/examples/react/virtualized-columns/package.json b/examples/react/virtualized-columns/package.json index 8d41d810de..26f9124ec8 100644 --- a/examples/react/virtualized-columns/package.json +++ b/examples/react/virtualized-columns/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "@tanstack/react-virtual": "^3.14.5", "react": "^19.2.7", "react-dom": "^19.2.7" diff --git a/examples/react/virtualized-infinite-scrolling/package.json b/examples/react/virtualized-infinite-scrolling/package.json index b52f39b656..79c22cb5cd 100644 --- a/examples/react/virtualized-infinite-scrolling/package.json +++ b/examples/react/virtualized-infinite-scrolling/package.json @@ -13,7 +13,7 @@ "dependencies": { "@faker-js/faker": "^10.5.0", "@tanstack/react-query": "^5.101.2", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "@tanstack/react-virtual": "^3.14.5", "react": "^19.2.7", "react-dom": "^19.2.7" diff --git a/examples/react/virtualized-rows-experimental/package.json b/examples/react/virtualized-rows-experimental/package.json index 9c508e88df..6cd845f39a 100644 --- a/examples/react/virtualized-rows-experimental/package.json +++ b/examples/react/virtualized-rows-experimental/package.json @@ -11,7 +11,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "@tanstack/react-virtual": "^3.14.5", "react": "^19.2.7", "react-dom": "^19.2.7" diff --git a/examples/react/virtualized-rows/package.json b/examples/react/virtualized-rows/package.json index 737b6939c3..27ab795df8 100644 --- a/examples/react/virtualized-rows/package.json +++ b/examples/react/virtualized-rows/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "@tanstack/react-virtual": "^3.14.5", "react": "^19.2.7", "react-dom": "^19.2.7" diff --git a/examples/react/web-worker-row-models/package.json b/examples/react/web-worker-row-models/package.json index 707a199bd8..6fbeca35b3 100644 --- a/examples/react/web-worker-row-models/package.json +++ b/examples/react/web-worker-row-models/package.json @@ -17,8 +17,8 @@ "@tanstack/react-router": "^1.170.17", "@tanstack/react-start": "^1.168.27", "@tanstack/react-store": "^0.11.0", - "@tanstack/react-table": "^9.0.0-beta.42", - "@tanstack/react-table-devtools": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", + "@tanstack/react-table-devtools": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/with-tanstack-form/package.json b/examples/react/with-tanstack-form/package.json index f5b5c2ebc9..4c91b52f0f 100644 --- a/examples/react/with-tanstack-form/package.json +++ b/examples/react/with-tanstack-form/package.json @@ -16,8 +16,8 @@ "@tanstack/react-form": "^1.33.1", "@tanstack/react-form-devtools": "^0.2.30", "@tanstack/react-pacer": "^0.22.1", - "@tanstack/react-table": "^9.0.0-beta.42", - "@tanstack/react-table-devtools": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", + "@tanstack/react-table-devtools": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7", "zod": "^4.4.3" diff --git a/examples/react/with-tanstack-query/package.json b/examples/react/with-tanstack-query/package.json index 47bfe8d50a..8ff74222cf 100644 --- a/examples/react/with-tanstack-query/package.json +++ b/examples/react/with-tanstack-query/package.json @@ -14,7 +14,7 @@ "@faker-js/faker": "^10.5.0", "@tanstack/react-query": "^5.101.2", "@tanstack/react-store": "^0.11.0", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/react/with-tanstack-router/package.json b/examples/react/with-tanstack-router/package.json index 24b2dc8a02..0f31822e43 100644 --- a/examples/react/with-tanstack-router/package.json +++ b/examples/react/with-tanstack-router/package.json @@ -14,7 +14,7 @@ "@tanstack/react-pacer": "^0.22.1", "@tanstack/react-query": "^5.101.2", "@tanstack/react-router": "^1.170.17", - "@tanstack/react-table": "^9.0.0-beta.42", + "@tanstack/react-table": "^9.0.0-beta.43", "react": "^19.2.7", "react-dom": "^19.2.7" }, diff --git a/examples/solid/basic-app-table/package.json b/examples/solid/basic-app-table/package.json index 90b2cad375..f81e5bea1b 100644 --- a/examples/solid/basic-app-table/package.json +++ b/examples/solid/basic-app-table/package.json @@ -19,8 +19,8 @@ "dependencies": { "@faker-js/faker": "^10.5.0", "@tanstack/solid-devtools": "^0.8.8", - "@tanstack/solid-table": "^9.0.0-beta.42", - "@tanstack/solid-table-devtools": "^9.0.0-beta.42", + "@tanstack/solid-table": "^9.0.0-beta.43", + "@tanstack/solid-table-devtools": "^9.0.0-beta.43", "solid-js": "^1.9.13" } } diff --git a/examples/solid/basic-dynamic-columns/package.json b/examples/solid/basic-dynamic-columns/package.json index 96d467f7ab..730c4a4ad0 100644 --- a/examples/solid/basic-dynamic-columns/package.json +++ b/examples/solid/basic-dynamic-columns/package.json @@ -19,7 +19,7 @@ }, "dependencies": { "@tanstack/solid-pacer": "^0.21.1", - "@tanstack/solid-table": "^9.0.0-beta.42", + "@tanstack/solid-table": "^9.0.0-beta.43", "solid-js": "^1.9.13" } } diff --git a/examples/solid/basic-external-atoms/package.json b/examples/solid/basic-external-atoms/package.json index 4339279146..3b9759c431 100644 --- a/examples/solid/basic-external-atoms/package.json +++ b/examples/solid/basic-external-atoms/package.json @@ -20,8 +20,8 @@ "dependencies": { "@tanstack/solid-devtools": "^0.8.8", "@tanstack/solid-store": "^0.11.0", - "@tanstack/solid-table": "^9.0.0-beta.42", - "@tanstack/solid-table-devtools": "^9.0.0-beta.42", + "@tanstack/solid-table": "^9.0.0-beta.43", + "@tanstack/solid-table-devtools": "^9.0.0-beta.43", "solid-js": "^1.9.13" } } diff --git a/examples/solid/basic-external-state/package.json b/examples/solid/basic-external-state/package.json index b7e58f7218..ffe8bf11bf 100644 --- a/examples/solid/basic-external-state/package.json +++ b/examples/solid/basic-external-state/package.json @@ -19,8 +19,8 @@ }, "dependencies": { "@tanstack/solid-devtools": "^0.8.8", - "@tanstack/solid-table": "^9.0.0-beta.42", - "@tanstack/solid-table-devtools": "^9.0.0-beta.42", + "@tanstack/solid-table": "^9.0.0-beta.43", + "@tanstack/solid-table-devtools": "^9.0.0-beta.43", "solid-js": "^1.9.13" } } diff --git a/examples/solid/basic-use-table/package.json b/examples/solid/basic-use-table/package.json index 989df1eaea..c93d4e64d6 100644 --- a/examples/solid/basic-use-table/package.json +++ b/examples/solid/basic-use-table/package.json @@ -18,8 +18,8 @@ }, "dependencies": { "@tanstack/solid-devtools": "^0.8.8", - "@tanstack/solid-table": "^9.0.0-beta.42", - "@tanstack/solid-table-devtools": "^9.0.0-beta.42", + "@tanstack/solid-table": "^9.0.0-beta.43", + "@tanstack/solid-table-devtools": "^9.0.0-beta.43", "solid-js": "^1.9.13" } } diff --git a/examples/solid/column-groups/package.json b/examples/solid/column-groups/package.json index 8b8c7cb3a9..c99bd6d868 100644 --- a/examples/solid/column-groups/package.json +++ b/examples/solid/column-groups/package.json @@ -18,7 +18,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/solid-table": "^9.0.0-beta.42", + "@tanstack/solid-table": "^9.0.0-beta.43", "solid-js": "^1.9.13" } } diff --git a/examples/solid/column-ordering/package.json b/examples/solid/column-ordering/package.json index 26f0f98aa6..3b28be8091 100644 --- a/examples/solid/column-ordering/package.json +++ b/examples/solid/column-ordering/package.json @@ -18,7 +18,7 @@ "vite-plugin-solid": "^2.11.12" }, "dependencies": { - "@tanstack/solid-table": "^9.0.0-beta.42", + "@tanstack/solid-table": "^9.0.0-beta.43", "solid-js": "^1.9.13" } } diff --git a/examples/solid/column-pinning-split/package.json b/examples/solid/column-pinning-split/package.json index 9942442a60..92f895a203 100644 --- a/examples/solid/column-pinning-split/package.json +++ b/examples/solid/column-pinning-split/package.json @@ -18,7 +18,7 @@ "vite-plugin-solid": "^2.11.12" }, "dependencies": { - "@tanstack/solid-table": "^9.0.0-beta.42", + "@tanstack/solid-table": "^9.0.0-beta.43", "solid-js": "^1.9.13" } } diff --git a/examples/solid/column-pinning-sticky/package.json b/examples/solid/column-pinning-sticky/package.json index 484fae9f18..65248cfd8b 100644 --- a/examples/solid/column-pinning-sticky/package.json +++ b/examples/solid/column-pinning-sticky/package.json @@ -18,7 +18,7 @@ "vite-plugin-solid": "^2.11.12" }, "dependencies": { - "@tanstack/solid-table": "^9.0.0-beta.42", + "@tanstack/solid-table": "^9.0.0-beta.43", "solid-js": "^1.9.13" } } diff --git a/examples/solid/column-pinning/package.json b/examples/solid/column-pinning/package.json index 4c2f94b5ee..b145a0abe3 100644 --- a/examples/solid/column-pinning/package.json +++ b/examples/solid/column-pinning/package.json @@ -18,7 +18,7 @@ "vite-plugin-solid": "^2.11.12" }, "dependencies": { - "@tanstack/solid-table": "^9.0.0-beta.42", + "@tanstack/solid-table": "^9.0.0-beta.43", "solid-js": "^1.9.13" } } diff --git a/examples/solid/column-resizing-performant/package.json b/examples/solid/column-resizing-performant/package.json index c47bf42b23..d13a8071cd 100644 --- a/examples/solid/column-resizing-performant/package.json +++ b/examples/solid/column-resizing-performant/package.json @@ -18,7 +18,7 @@ "vite-plugin-solid": "^2.11.12" }, "dependencies": { - "@tanstack/solid-table": "^9.0.0-beta.42", + "@tanstack/solid-table": "^9.0.0-beta.43", "solid-js": "^1.9.13" } } diff --git a/examples/solid/column-resizing/package.json b/examples/solid/column-resizing/package.json index 1c79eaa23e..3cc65c9817 100644 --- a/examples/solid/column-resizing/package.json +++ b/examples/solid/column-resizing/package.json @@ -18,7 +18,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/solid-table": "^9.0.0-beta.42", + "@tanstack/solid-table": "^9.0.0-beta.43", "solid-js": "^1.9.13" } } diff --git a/examples/solid/column-sizing/package.json b/examples/solid/column-sizing/package.json index af36e37c88..f7c073bac9 100644 --- a/examples/solid/column-sizing/package.json +++ b/examples/solid/column-sizing/package.json @@ -18,7 +18,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/solid-table": "^9.0.0-beta.42", + "@tanstack/solid-table": "^9.0.0-beta.43", "solid-js": "^1.9.13" } } diff --git a/examples/solid/column-visibility/package.json b/examples/solid/column-visibility/package.json index 1d697daac5..e36572a59b 100644 --- a/examples/solid/column-visibility/package.json +++ b/examples/solid/column-visibility/package.json @@ -18,7 +18,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/solid-table": "^9.0.0-beta.42", + "@tanstack/solid-table": "^9.0.0-beta.43", "solid-js": "^1.9.13" } } diff --git a/examples/solid/composable-tables/package.json b/examples/solid/composable-tables/package.json index 68f8cc27f2..a0876b1c59 100644 --- a/examples/solid/composable-tables/package.json +++ b/examples/solid/composable-tables/package.json @@ -18,8 +18,8 @@ }, "dependencies": { "@tanstack/solid-devtools": "^0.8.8", - "@tanstack/solid-table": "^9.0.0-beta.42", - "@tanstack/solid-table-devtools": "^9.0.0-beta.42", + "@tanstack/solid-table": "^9.0.0-beta.43", + "@tanstack/solid-table-devtools": "^9.0.0-beta.43", "solid-js": "^1.9.13" } } diff --git a/examples/solid/expanding/package.json b/examples/solid/expanding/package.json index 4921037323..2049121d7e 100644 --- a/examples/solid/expanding/package.json +++ b/examples/solid/expanding/package.json @@ -18,7 +18,7 @@ "vite-plugin-solid": "^2.11.12" }, "dependencies": { - "@tanstack/solid-table": "^9.0.0-beta.42", + "@tanstack/solid-table": "^9.0.0-beta.43", "solid-js": "^1.9.13" } } diff --git a/examples/solid/expanding/src/App.tsx b/examples/solid/expanding/src/App.tsx index 948c05ad61..d6f7797353 100644 --- a/examples/solid/expanding/src/App.tsx +++ b/examples/solid/expanding/src/App.tsx @@ -41,6 +41,11 @@ function App() { const stressTest = () => setData(makeData(10_000, 5, 3)) const columns = columnHelper.columns([ + columnHelper.display({ + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }), columnHelper.accessor('firstName', { header: ({ table }) => ( <> diff --git a/examples/solid/filters-faceted/package.json b/examples/solid/filters-faceted/package.json index 991e6b0cce..92d93a4c23 100644 --- a/examples/solid/filters-faceted/package.json +++ b/examples/solid/filters-faceted/package.json @@ -19,7 +19,7 @@ }, "dependencies": { "@tanstack/solid-pacer": "^0.21.1", - "@tanstack/solid-table": "^9.0.0-beta.42", + "@tanstack/solid-table": "^9.0.0-beta.43", "solid-js": "^1.9.13" } } diff --git a/examples/solid/filters-fuzzy/package.json b/examples/solid/filters-fuzzy/package.json index 909d2e6bac..52165a09c4 100644 --- a/examples/solid/filters-fuzzy/package.json +++ b/examples/solid/filters-fuzzy/package.json @@ -20,7 +20,7 @@ "dependencies": { "@tanstack/match-sorter-utils": "^9.0.0-beta.41", "@tanstack/solid-pacer": "^0.21.1", - "@tanstack/solid-table": "^9.0.0-beta.42", + "@tanstack/solid-table": "^9.0.0-beta.43", "solid-js": "^1.9.13" } } diff --git a/examples/solid/filters/package.json b/examples/solid/filters/package.json index 590b22369a..1544cafe06 100644 --- a/examples/solid/filters/package.json +++ b/examples/solid/filters/package.json @@ -19,7 +19,7 @@ }, "dependencies": { "@tanstack/solid-pacer": "^0.21.1", - "@tanstack/solid-table": "^9.0.0-beta.42", + "@tanstack/solid-table": "^9.0.0-beta.43", "solid-js": "^1.9.13" } } diff --git a/examples/solid/filters/src/App.tsx b/examples/solid/filters/src/App.tsx index 7006ef20d3..ba8882a28e 100644 --- a/examples/solid/filters/src/App.tsx +++ b/examples/solid/filters/src/App.tsx @@ -34,6 +34,11 @@ export const features = tableFeatures({ }) const columns: Array> = [ + { + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }, { header: 'Name', footer: (props) => props.column.id, diff --git a/examples/solid/grouping/package.json b/examples/solid/grouping/package.json index e6350001c5..be06e45ad9 100644 --- a/examples/solid/grouping/package.json +++ b/examples/solid/grouping/package.json @@ -18,7 +18,7 @@ "vite-plugin-solid": "^2.11.12" }, "dependencies": { - "@tanstack/solid-table": "^9.0.0-beta.42", + "@tanstack/solid-table": "^9.0.0-beta.43", "solid-js": "^1.9.13" } } diff --git a/examples/solid/kitchen-sink/package.json b/examples/solid/kitchen-sink/package.json index 83c90c58f4..69c07a49c1 100644 --- a/examples/solid/kitchen-sink/package.json +++ b/examples/solid/kitchen-sink/package.json @@ -20,8 +20,8 @@ "dependencies": { "@tanstack/match-sorter-utils": "^9.0.0-beta.41", "@tanstack/solid-devtools": "^0.8.8", - "@tanstack/solid-table": "^9.0.0-beta.42", - "@tanstack/solid-table-devtools": "^9.0.0-beta.42", + "@tanstack/solid-table": "^9.0.0-beta.43", + "@tanstack/solid-table-devtools": "^9.0.0-beta.43", "solid-js": "^1.9.13" } } diff --git a/examples/solid/pagination/package.json b/examples/solid/pagination/package.json index d4be458331..681cb6ed4e 100644 --- a/examples/solid/pagination/package.json +++ b/examples/solid/pagination/package.json @@ -18,7 +18,7 @@ "vite-plugin-solid": "^2.11.12" }, "dependencies": { - "@tanstack/solid-table": "^9.0.0-beta.42", + "@tanstack/solid-table": "^9.0.0-beta.43", "solid-js": "^1.9.13" } } diff --git a/examples/solid/pagination/src/App.tsx b/examples/solid/pagination/src/App.tsx index a1dfd3c19d..769c8212e0 100644 --- a/examples/solid/pagination/src/App.tsx +++ b/examples/solid/pagination/src/App.tsx @@ -17,6 +17,11 @@ const features = tableFeatures({ const columnHelper = createColumnHelper() const columns = columnHelper.columns([ + columnHelper.display({ + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }), columnHelper.accessor('firstName', { cell: (info) => info.getValue(), footer: (props) => props.column.id, diff --git a/examples/solid/row-pinning/package.json b/examples/solid/row-pinning/package.json index b9453ae8ac..dd268d2d95 100644 --- a/examples/solid/row-pinning/package.json +++ b/examples/solid/row-pinning/package.json @@ -18,7 +18,7 @@ "vite-plugin-solid": "^2.11.12" }, "dependencies": { - "@tanstack/solid-table": "^9.0.0-beta.42", + "@tanstack/solid-table": "^9.0.0-beta.43", "solid-js": "^1.9.13" } } diff --git a/examples/solid/row-selection/package.json b/examples/solid/row-selection/package.json index f250b22c87..10d37b3cf7 100644 --- a/examples/solid/row-selection/package.json +++ b/examples/solid/row-selection/package.json @@ -19,8 +19,8 @@ }, "dependencies": { "@tanstack/solid-devtools": "^0.8.8", - "@tanstack/solid-table": "^9.0.0-beta.42", - "@tanstack/solid-table-devtools": "^9.0.0-beta.42", + "@tanstack/solid-table": "^9.0.0-beta.43", + "@tanstack/solid-table-devtools": "^9.0.0-beta.43", "solid-js": "^1.9.13" } } diff --git a/examples/solid/sorting/package.json b/examples/solid/sorting/package.json index 30ba59d7d6..5db88eb43b 100644 --- a/examples/solid/sorting/package.json +++ b/examples/solid/sorting/package.json @@ -18,7 +18,7 @@ "vite-plugin-solid": "^2.11.12" }, "dependencies": { - "@tanstack/solid-table": "^9.0.0-beta.42", + "@tanstack/solid-table": "^9.0.0-beta.43", "solid-js": "^1.9.13" } } diff --git a/examples/solid/sorting/src/App.tsx b/examples/solid/sorting/src/App.tsx index 78999641bb..113da85f78 100644 --- a/examples/solid/sorting/src/App.tsx +++ b/examples/solid/sorting/src/App.tsx @@ -23,6 +23,11 @@ function App() { const stressTest = () => setData(makeData(1_000_000)) const columns: Array> = [ + { + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }, { header: 'Name', footer: (props) => props.column.id, diff --git a/examples/solid/sub-components/package.json b/examples/solid/sub-components/package.json index a19f010df6..c87cdf9986 100644 --- a/examples/solid/sub-components/package.json +++ b/examples/solid/sub-components/package.json @@ -18,7 +18,7 @@ "vite-plugin-solid": "^2.11.12" }, "dependencies": { - "@tanstack/solid-table": "^9.0.0-beta.42", + "@tanstack/solid-table": "^9.0.0-beta.43", "solid-js": "^1.9.13" } } diff --git a/examples/solid/virtualized-columns/package.json b/examples/solid/virtualized-columns/package.json index eb1f63c08b..b116be912f 100644 --- a/examples/solid/virtualized-columns/package.json +++ b/examples/solid/virtualized-columns/package.json @@ -18,7 +18,7 @@ "vite-plugin-solid": "^2.11.12" }, "dependencies": { - "@tanstack/solid-table": "^9.0.0-beta.42", + "@tanstack/solid-table": "^9.0.0-beta.43", "@tanstack/solid-virtual": "^3.13.32", "solid-js": "^1.9.13" } diff --git a/examples/solid/virtualized-infinite-scrolling/package.json b/examples/solid/virtualized-infinite-scrolling/package.json index 71754d35fc..7d37990db2 100644 --- a/examples/solid/virtualized-infinite-scrolling/package.json +++ b/examples/solid/virtualized-infinite-scrolling/package.json @@ -20,7 +20,7 @@ "dependencies": { "@tanstack/solid-query": "^5.101.2", "@tanstack/solid-store": "^0.11.0", - "@tanstack/solid-table": "^9.0.0-beta.42", + "@tanstack/solid-table": "^9.0.0-beta.43", "@tanstack/solid-virtual": "^3.13.32", "solid-js": "^1.9.13" } diff --git a/examples/solid/virtualized-rows/package.json b/examples/solid/virtualized-rows/package.json index 439eb940e4..04aa86080b 100644 --- a/examples/solid/virtualized-rows/package.json +++ b/examples/solid/virtualized-rows/package.json @@ -18,7 +18,7 @@ "vite-plugin-solid": "^2.11.12" }, "dependencies": { - "@tanstack/solid-table": "^9.0.0-beta.42", + "@tanstack/solid-table": "^9.0.0-beta.43", "@tanstack/solid-virtual": "^3.13.32", "solid-js": "^1.9.13" } diff --git a/examples/solid/with-tanstack-form/package.json b/examples/solid/with-tanstack-form/package.json index fd90cdabe9..a623de0baa 100644 --- a/examples/solid/with-tanstack-form/package.json +++ b/examples/solid/with-tanstack-form/package.json @@ -21,8 +21,8 @@ "@tanstack/solid-devtools": "^0.8.8", "@tanstack/solid-form": "^1.33.1", "@tanstack/solid-form-devtools": "^0.2.30", - "@tanstack/solid-table": "^9.0.0-beta.42", - "@tanstack/solid-table-devtools": "^9.0.0-beta.42", + "@tanstack/solid-table": "^9.0.0-beta.43", + "@tanstack/solid-table-devtools": "^9.0.0-beta.43", "solid-js": "^1.9.13", "zod": "^4.4.3" } diff --git a/examples/solid/with-tanstack-query/package.json b/examples/solid/with-tanstack-query/package.json index c8933c5aa3..73fe1441a5 100644 --- a/examples/solid/with-tanstack-query/package.json +++ b/examples/solid/with-tanstack-query/package.json @@ -20,7 +20,7 @@ "dependencies": { "@tanstack/solid-query": "^5.101.2", "@tanstack/solid-store": "^0.11.0", - "@tanstack/solid-table": "^9.0.0-beta.42", + "@tanstack/solid-table": "^9.0.0-beta.43", "solid-js": "^1.9.13" } } diff --git a/examples/solid/with-tanstack-router/package.json b/examples/solid/with-tanstack-router/package.json index c71565315f..69c201a884 100644 --- a/examples/solid/with-tanstack-router/package.json +++ b/examples/solid/with-tanstack-router/package.json @@ -22,7 +22,7 @@ "@tanstack/solid-pacer": "^0.21.1", "@tanstack/solid-query": "^5.101.2", "@tanstack/solid-router": "^1.170.17", - "@tanstack/solid-table": "^9.0.0-beta.42", + "@tanstack/solid-table": "^9.0.0-beta.43", "solid-js": "^1.9.13" } } diff --git a/examples/svelte/basic-app-table/package.json b/examples/svelte/basic-app-table/package.json index 6d62f54682..717e6a8685 100644 --- a/examples/svelte/basic-app-table/package.json +++ b/examples/svelte/basic-app-table/package.json @@ -14,7 +14,7 @@ "@faker-js/faker": "^10.5.0", "@rollup/plugin-replace": "^6.0.3", "@sveltejs/vite-plugin-svelte": "^7.1.2", - "@tanstack/svelte-table": "^9.0.0-beta.42", + "@tanstack/svelte-table": "^9.0.0-beta.43", "@tsconfig/svelte": "^5.0.8", "svelte": "^5.56.2", "svelte-check": "^4.6.0", diff --git a/examples/svelte/basic-create-table/package.json b/examples/svelte/basic-create-table/package.json index e0b33584f7..389881b3e8 100644 --- a/examples/svelte/basic-create-table/package.json +++ b/examples/svelte/basic-create-table/package.json @@ -14,7 +14,7 @@ "@faker-js/faker": "^10.5.0", "@rollup/plugin-replace": "^6.0.3", "@sveltejs/vite-plugin-svelte": "^7.1.2", - "@tanstack/svelte-table": "^9.0.0-beta.42", + "@tanstack/svelte-table": "^9.0.0-beta.43", "@tsconfig/svelte": "^5.0.8", "svelte": "^5.56.2", "svelte-check": "^4.6.0", diff --git a/examples/svelte/basic-dynamic-columns/package.json b/examples/svelte/basic-dynamic-columns/package.json index 3c3047ee6e..1c5bd33f60 100644 --- a/examples/svelte/basic-dynamic-columns/package.json +++ b/examples/svelte/basic-dynamic-columns/package.json @@ -14,7 +14,7 @@ "@faker-js/faker": "^10.5.0", "@rollup/plugin-replace": "^6.0.3", "@sveltejs/vite-plugin-svelte": "^7.1.2", - "@tanstack/svelte-table": "^9.0.0-beta.42", + "@tanstack/svelte-table": "^9.0.0-beta.43", "@tsconfig/svelte": "^5.0.8", "svelte": "^5.56.2", "svelte-check": "^4.6.0", diff --git a/examples/svelte/basic-external-atoms/package.json b/examples/svelte/basic-external-atoms/package.json index 14968df77a..e3da74e6b0 100644 --- a/examples/svelte/basic-external-atoms/package.json +++ b/examples/svelte/basic-external-atoms/package.json @@ -17,7 +17,7 @@ "@faker-js/faker": "^10.5.0", "@rollup/plugin-replace": "^6.0.3", "@sveltejs/vite-plugin-svelte": "^7.1.2", - "@tanstack/svelte-table": "^9.0.0-beta.42", + "@tanstack/svelte-table": "^9.0.0-beta.43", "@tsconfig/svelte": "^5.0.8", "svelte": "^5.56.2", "svelte-check": "^4.6.0", diff --git a/examples/svelte/basic-external-state/package.json b/examples/svelte/basic-external-state/package.json index e4d93d71fb..49c5ed2712 100644 --- a/examples/svelte/basic-external-state/package.json +++ b/examples/svelte/basic-external-state/package.json @@ -14,7 +14,7 @@ "@faker-js/faker": "^10.5.0", "@rollup/plugin-replace": "^6.0.3", "@sveltejs/vite-plugin-svelte": "^7.1.2", - "@tanstack/svelte-table": "^9.0.0-beta.42", + "@tanstack/svelte-table": "^9.0.0-beta.43", "@tsconfig/svelte": "^5.0.8", "svelte": "^5.56.2", "svelte-check": "^4.6.0", diff --git a/examples/svelte/basic-snippets/package.json b/examples/svelte/basic-snippets/package.json index 09fb6cc28d..885c726de6 100644 --- a/examples/svelte/basic-snippets/package.json +++ b/examples/svelte/basic-snippets/package.json @@ -14,7 +14,7 @@ "@faker-js/faker": "^10.5.0", "@rollup/plugin-replace": "^6.0.3", "@sveltejs/vite-plugin-svelte": "^7.1.2", - "@tanstack/svelte-table": "^9.0.0-beta.42", + "@tanstack/svelte-table": "^9.0.0-beta.43", "@tsconfig/svelte": "^5.0.8", "svelte": "^5.56.2", "svelte-check": "^4.6.0", diff --git a/examples/svelte/column-groups/package.json b/examples/svelte/column-groups/package.json index 6ef09d1cb2..fbc8be544f 100644 --- a/examples/svelte/column-groups/package.json +++ b/examples/svelte/column-groups/package.json @@ -14,7 +14,7 @@ "@faker-js/faker": "^10.5.0", "@rollup/plugin-replace": "^6.0.3", "@sveltejs/vite-plugin-svelte": "^7.1.2", - "@tanstack/svelte-table": "^9.0.0-beta.42", + "@tanstack/svelte-table": "^9.0.0-beta.43", "@tsconfig/svelte": "^5.0.8", "svelte": "^5.56.2", "svelte-check": "^4.6.0", diff --git a/examples/svelte/column-ordering/package.json b/examples/svelte/column-ordering/package.json index be4c8daed6..013564abaa 100644 --- a/examples/svelte/column-ordering/package.json +++ b/examples/svelte/column-ordering/package.json @@ -14,7 +14,7 @@ "@faker-js/faker": "^10.5.0", "@rollup/plugin-replace": "^6.0.3", "@sveltejs/vite-plugin-svelte": "^7.1.2", - "@tanstack/svelte-table": "^9.0.0-beta.42", + "@tanstack/svelte-table": "^9.0.0-beta.43", "@tsconfig/svelte": "^5.0.8", "svelte": "^5.56.2", "svelte-check": "^4.6.0", diff --git a/examples/svelte/column-pinning-split/package.json b/examples/svelte/column-pinning-split/package.json index b641dd3b51..62011134e4 100644 --- a/examples/svelte/column-pinning-split/package.json +++ b/examples/svelte/column-pinning-split/package.json @@ -14,7 +14,7 @@ "@faker-js/faker": "^10.5.0", "@rollup/plugin-replace": "^6.0.3", "@sveltejs/vite-plugin-svelte": "^7.1.2", - "@tanstack/svelte-table": "^9.0.0-beta.42", + "@tanstack/svelte-table": "^9.0.0-beta.43", "@tsconfig/svelte": "^5.0.8", "svelte": "^5.56.2", "svelte-check": "^4.6.0", diff --git a/examples/svelte/column-pinning-sticky/package.json b/examples/svelte/column-pinning-sticky/package.json index a8854d5c82..426e230780 100644 --- a/examples/svelte/column-pinning-sticky/package.json +++ b/examples/svelte/column-pinning-sticky/package.json @@ -14,7 +14,7 @@ "@faker-js/faker": "^10.5.0", "@rollup/plugin-replace": "^6.0.3", "@sveltejs/vite-plugin-svelte": "^7.1.2", - "@tanstack/svelte-table": "^9.0.0-beta.42", + "@tanstack/svelte-table": "^9.0.0-beta.43", "@tsconfig/svelte": "^5.0.8", "svelte": "^5.56.2", "svelte-check": "^4.6.0", diff --git a/examples/svelte/column-pinning/package.json b/examples/svelte/column-pinning/package.json index 32811ee170..7b14dcc89c 100644 --- a/examples/svelte/column-pinning/package.json +++ b/examples/svelte/column-pinning/package.json @@ -14,7 +14,7 @@ "@faker-js/faker": "^10.5.0", "@rollup/plugin-replace": "^6.0.3", "@sveltejs/vite-plugin-svelte": "^7.1.2", - "@tanstack/svelte-table": "^9.0.0-beta.42", + "@tanstack/svelte-table": "^9.0.0-beta.43", "@tsconfig/svelte": "^5.0.8", "svelte": "^5.56.2", "svelte-check": "^4.6.0", diff --git a/examples/svelte/column-resizing-performant/package.json b/examples/svelte/column-resizing-performant/package.json index cb8f569c0e..4e4362135e 100644 --- a/examples/svelte/column-resizing-performant/package.json +++ b/examples/svelte/column-resizing-performant/package.json @@ -14,7 +14,7 @@ "@faker-js/faker": "^10.5.0", "@rollup/plugin-replace": "^6.0.3", "@sveltejs/vite-plugin-svelte": "^7.1.2", - "@tanstack/svelte-table": "^9.0.0-beta.42", + "@tanstack/svelte-table": "^9.0.0-beta.43", "@tsconfig/svelte": "^5.0.8", "svelte": "^5.56.2", "svelte-check": "^4.6.0", diff --git a/examples/svelte/column-resizing/package.json b/examples/svelte/column-resizing/package.json index b11004a24f..888f386f69 100644 --- a/examples/svelte/column-resizing/package.json +++ b/examples/svelte/column-resizing/package.json @@ -14,7 +14,7 @@ "@faker-js/faker": "^10.5.0", "@rollup/plugin-replace": "^6.0.3", "@sveltejs/vite-plugin-svelte": "^7.1.2", - "@tanstack/svelte-table": "^9.0.0-beta.42", + "@tanstack/svelte-table": "^9.0.0-beta.43", "@tsconfig/svelte": "^5.0.8", "svelte": "^5.56.2", "svelte-check": "^4.6.0", diff --git a/examples/svelte/column-sizing/package.json b/examples/svelte/column-sizing/package.json index 87d058a9b4..e6c2d265b9 100644 --- a/examples/svelte/column-sizing/package.json +++ b/examples/svelte/column-sizing/package.json @@ -14,7 +14,7 @@ "@faker-js/faker": "^10.5.0", "@rollup/plugin-replace": "^6.0.3", "@sveltejs/vite-plugin-svelte": "^7.1.2", - "@tanstack/svelte-table": "^9.0.0-beta.42", + "@tanstack/svelte-table": "^9.0.0-beta.43", "@tsconfig/svelte": "^5.0.8", "svelte": "^5.56.2", "svelte-check": "^4.6.0", diff --git a/examples/svelte/column-visibility/package.json b/examples/svelte/column-visibility/package.json index 1efe767e6a..a0832b9ac5 100644 --- a/examples/svelte/column-visibility/package.json +++ b/examples/svelte/column-visibility/package.json @@ -14,7 +14,7 @@ "@faker-js/faker": "^10.5.0", "@rollup/plugin-replace": "^6.0.3", "@sveltejs/vite-plugin-svelte": "^7.1.2", - "@tanstack/svelte-table": "^9.0.0-beta.42", + "@tanstack/svelte-table": "^9.0.0-beta.43", "@tsconfig/svelte": "^5.0.8", "svelte": "^5.56.2", "svelte-check": "^4.6.0", diff --git a/examples/svelte/composable-tables/package.json b/examples/svelte/composable-tables/package.json index 258e499f3f..a34b1fceaa 100644 --- a/examples/svelte/composable-tables/package.json +++ b/examples/svelte/composable-tables/package.json @@ -14,7 +14,7 @@ "@faker-js/faker": "^10.5.0", "@rollup/plugin-replace": "^6.0.3", "@sveltejs/vite-plugin-svelte": "^7.1.2", - "@tanstack/svelte-table": "^9.0.0-beta.42", + "@tanstack/svelte-table": "^9.0.0-beta.43", "@tsconfig/svelte": "^5.0.8", "svelte": "^5.56.2", "svelte-check": "^4.6.0", diff --git a/examples/svelte/expanding/package.json b/examples/svelte/expanding/package.json index 10178f2b5f..c6fde3a756 100644 --- a/examples/svelte/expanding/package.json +++ b/examples/svelte/expanding/package.json @@ -14,7 +14,7 @@ "@faker-js/faker": "^10.5.0", "@rollup/plugin-replace": "^6.0.3", "@sveltejs/vite-plugin-svelte": "^7.1.2", - "@tanstack/svelte-table": "^9.0.0-beta.42", + "@tanstack/svelte-table": "^9.0.0-beta.43", "@tsconfig/svelte": "^5.0.8", "svelte": "^5.56.2", "svelte-check": "^4.6.0", diff --git a/examples/svelte/expanding/src/App.svelte b/examples/svelte/expanding/src/App.svelte index a9c81c7da6..c0b42f792f 100644 --- a/examples/svelte/expanding/src/App.svelte +++ b/examples/svelte/expanding/src/App.svelte @@ -52,6 +52,11 @@ const stressTest = () => { data = makeData(10_000, 5, 3) } const columns = columnHelper.columns([ + columnHelper.display({ + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }), columnHelper.accessor('firstName', { header: () => 'firstName', cell: ({ row, getValue }) => getValue(), diff --git a/examples/svelte/filtering/package.json b/examples/svelte/filtering/package.json index 621e18c26d..47b77bae21 100644 --- a/examples/svelte/filtering/package.json +++ b/examples/svelte/filtering/package.json @@ -14,7 +14,7 @@ "@faker-js/faker": "^10.5.0", "@rollup/plugin-replace": "^6.0.3", "@sveltejs/vite-plugin-svelte": "^7.1.2", - "@tanstack/svelte-table": "^9.0.0-beta.42", + "@tanstack/svelte-table": "^9.0.0-beta.43", "@tsconfig/svelte": "^5.0.8", "svelte": "^5.56.2", "svelte-check": "^4.6.0", diff --git a/examples/svelte/filters-faceted/package.json b/examples/svelte/filters-faceted/package.json index a8a77099f8..d039ea5482 100644 --- a/examples/svelte/filters-faceted/package.json +++ b/examples/svelte/filters-faceted/package.json @@ -14,7 +14,7 @@ "@faker-js/faker": "^10.5.0", "@rollup/plugin-replace": "^6.0.3", "@sveltejs/vite-plugin-svelte": "^7.1.2", - "@tanstack/svelte-table": "^9.0.0-beta.42", + "@tanstack/svelte-table": "^9.0.0-beta.43", "@tsconfig/svelte": "^5.0.8", "svelte": "^5.56.2", "svelte-check": "^4.6.0", diff --git a/examples/svelte/filters-fuzzy/package.json b/examples/svelte/filters-fuzzy/package.json index e26792d8aa..6215fccbe4 100644 --- a/examples/svelte/filters-fuzzy/package.json +++ b/examples/svelte/filters-fuzzy/package.json @@ -15,7 +15,7 @@ "@rollup/plugin-replace": "^6.0.3", "@sveltejs/vite-plugin-svelte": "^7.1.2", "@tanstack/match-sorter-utils": "^9.0.0-beta.41", - "@tanstack/svelte-table": "^9.0.0-beta.42", + "@tanstack/svelte-table": "^9.0.0-beta.43", "@tsconfig/svelte": "^5.0.8", "svelte": "^5.56.2", "svelte-check": "^4.6.0", diff --git a/examples/svelte/grouping/package.json b/examples/svelte/grouping/package.json index 6719d5b295..e59ca4d94a 100644 --- a/examples/svelte/grouping/package.json +++ b/examples/svelte/grouping/package.json @@ -14,7 +14,7 @@ "@faker-js/faker": "^10.5.0", "@rollup/plugin-replace": "^6.0.3", "@sveltejs/vite-plugin-svelte": "^7.1.2", - "@tanstack/svelte-table": "^9.0.0-beta.42", + "@tanstack/svelte-table": "^9.0.0-beta.43", "@tsconfig/svelte": "^5.0.8", "svelte": "^5.56.2", "svelte-check": "^4.6.0", diff --git a/examples/svelte/kitchen-sink/package.json b/examples/svelte/kitchen-sink/package.json index 5f44d76293..65e30954c5 100644 --- a/examples/svelte/kitchen-sink/package.json +++ b/examples/svelte/kitchen-sink/package.json @@ -15,7 +15,7 @@ "@rollup/plugin-replace": "^6.0.3", "@sveltejs/vite-plugin-svelte": "^7.1.2", "@tanstack/match-sorter-utils": "^9.0.0-beta.41", - "@tanstack/svelte-table": "^9.0.0-beta.42", + "@tanstack/svelte-table": "^9.0.0-beta.43", "@tsconfig/svelte": "^5.0.8", "svelte": "^5.56.2", "svelte-check": "^4.6.0", diff --git a/examples/svelte/pagination/package.json b/examples/svelte/pagination/package.json index 68c1285e68..977ce81414 100644 --- a/examples/svelte/pagination/package.json +++ b/examples/svelte/pagination/package.json @@ -14,7 +14,7 @@ "@faker-js/faker": "^10.5.0", "@rollup/plugin-replace": "^6.0.3", "@sveltejs/vite-plugin-svelte": "^7.1.2", - "@tanstack/svelte-table": "^9.0.0-beta.42", + "@tanstack/svelte-table": "^9.0.0-beta.43", "@tsconfig/svelte": "^5.0.8", "svelte": "^5.56.2", "svelte-check": "^4.6.0", diff --git a/examples/svelte/pagination/src/App.svelte b/examples/svelte/pagination/src/App.svelte index 25211d3c38..7b15097e6d 100644 --- a/examples/svelte/pagination/src/App.svelte +++ b/examples/svelte/pagination/src/App.svelte @@ -19,6 +19,11 @@ const columnHelper = createColumnHelper() const columns = columnHelper.columns([ + columnHelper.display({ + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }), columnHelper.accessor('firstName', { cell: (info) => info.getValue(), footer: (props) => props.column.id, diff --git a/examples/svelte/row-pinning/package.json b/examples/svelte/row-pinning/package.json index aa137d3b30..85b95a6062 100644 --- a/examples/svelte/row-pinning/package.json +++ b/examples/svelte/row-pinning/package.json @@ -14,7 +14,7 @@ "@faker-js/faker": "^10.5.0", "@rollup/plugin-replace": "^6.0.3", "@sveltejs/vite-plugin-svelte": "^7.1.2", - "@tanstack/svelte-table": "^9.0.0-beta.42", + "@tanstack/svelte-table": "^9.0.0-beta.43", "@tsconfig/svelte": "^5.0.8", "svelte": "^5.56.2", "svelte-check": "^4.6.0", diff --git a/examples/svelte/row-selection/package.json b/examples/svelte/row-selection/package.json index 6a88595555..8cef986d90 100644 --- a/examples/svelte/row-selection/package.json +++ b/examples/svelte/row-selection/package.json @@ -14,7 +14,7 @@ "@faker-js/faker": "^10.5.0", "@rollup/plugin-replace": "^6.0.3", "@sveltejs/vite-plugin-svelte": "^7.1.2", - "@tanstack/svelte-table": "^9.0.0-beta.42", + "@tanstack/svelte-table": "^9.0.0-beta.43", "@tsconfig/svelte": "^5.0.8", "svelte": "^5.56.2", "svelte-check": "^4.6.0", diff --git a/examples/svelte/sorting/package.json b/examples/svelte/sorting/package.json index 15b96e4fbd..e28f8d76c6 100644 --- a/examples/svelte/sorting/package.json +++ b/examples/svelte/sorting/package.json @@ -14,7 +14,7 @@ "@faker-js/faker": "^10.5.0", "@rollup/plugin-replace": "^6.0.3", "@sveltejs/vite-plugin-svelte": "^7.1.2", - "@tanstack/svelte-table": "^9.0.0-beta.42", + "@tanstack/svelte-table": "^9.0.0-beta.43", "@tsconfig/svelte": "^5.0.8", "svelte": "^5.56.2", "svelte-check": "^4.6.0", diff --git a/examples/svelte/sorting/src/App.svelte b/examples/svelte/sorting/src/App.svelte index 1b6f8a8a25..75eed9e610 100644 --- a/examples/svelte/sorting/src/App.svelte +++ b/examples/svelte/sorting/src/App.svelte @@ -11,6 +11,11 @@ import { features } from './tableHelper.svelte' const columns: ColumnDef[] = [ + { + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }, { header: 'Name', footer: (props) => props.column.id, diff --git a/examples/svelte/sub-components/package.json b/examples/svelte/sub-components/package.json index 60aaf51042..9d578553c9 100644 --- a/examples/svelte/sub-components/package.json +++ b/examples/svelte/sub-components/package.json @@ -14,7 +14,7 @@ "@faker-js/faker": "^10.5.0", "@rollup/plugin-replace": "^6.0.3", "@sveltejs/vite-plugin-svelte": "^7.1.2", - "@tanstack/svelte-table": "^9.0.0-beta.42", + "@tanstack/svelte-table": "^9.0.0-beta.43", "@tsconfig/svelte": "^5.0.8", "svelte": "^5.56.2", "svelte-check": "^4.6.0", diff --git a/examples/svelte/virtualized-columns/package.json b/examples/svelte/virtualized-columns/package.json index 53934bf742..a31cf47a38 100644 --- a/examples/svelte/virtualized-columns/package.json +++ b/examples/svelte/virtualized-columns/package.json @@ -14,7 +14,7 @@ "@faker-js/faker": "^10.5.0", "@rollup/plugin-replace": "^6.0.3", "@sveltejs/vite-plugin-svelte": "^7.1.2", - "@tanstack/svelte-table": "^9.0.0-beta.42", + "@tanstack/svelte-table": "^9.0.0-beta.43", "@tanstack/svelte-virtual": "^3.13.31", "@tsconfig/svelte": "^5.0.8", "svelte": "^5.56.2", diff --git a/examples/svelte/virtualized-infinite-scrolling/package.json b/examples/svelte/virtualized-infinite-scrolling/package.json index d7a06fffd7..14b5e6e8a5 100644 --- a/examples/svelte/virtualized-infinite-scrolling/package.json +++ b/examples/svelte/virtualized-infinite-scrolling/package.json @@ -15,7 +15,7 @@ "@rollup/plugin-replace": "^6.0.3", "@sveltejs/vite-plugin-svelte": "^7.1.2", "@tanstack/svelte-query": "^6.1.36", - "@tanstack/svelte-table": "^9.0.0-beta.42", + "@tanstack/svelte-table": "^9.0.0-beta.43", "@tanstack/svelte-virtual": "^3.13.31", "@tsconfig/svelte": "^5.0.8", "svelte": "^5.56.2", diff --git a/examples/svelte/virtualized-rows/package.json b/examples/svelte/virtualized-rows/package.json index 4db1e579d5..cab3fe243c 100644 --- a/examples/svelte/virtualized-rows/package.json +++ b/examples/svelte/virtualized-rows/package.json @@ -14,7 +14,7 @@ "@faker-js/faker": "^10.5.0", "@rollup/plugin-replace": "^6.0.3", "@sveltejs/vite-plugin-svelte": "^7.1.2", - "@tanstack/svelte-table": "^9.0.0-beta.42", + "@tanstack/svelte-table": "^9.0.0-beta.43", "@tanstack/svelte-virtual": "^3.13.31", "@tsconfig/svelte": "^5.0.8", "svelte": "^5.56.2", diff --git a/examples/svelte/with-tanstack-form/package.json b/examples/svelte/with-tanstack-form/package.json index b5a91333e2..2c96a2fef7 100644 --- a/examples/svelte/with-tanstack-form/package.json +++ b/examples/svelte/with-tanstack-form/package.json @@ -23,7 +23,7 @@ "dependencies": { "@tanstack/form-core": "^1.33.1", "@tanstack/svelte-form": "^1.33.1", - "@tanstack/svelte-table": "^9.0.0-beta.42", + "@tanstack/svelte-table": "^9.0.0-beta.43", "zod": "^4.4.3" } } diff --git a/examples/svelte/with-tanstack-query/package.json b/examples/svelte/with-tanstack-query/package.json index d1a9725157..d325b1231a 100644 --- a/examples/svelte/with-tanstack-query/package.json +++ b/examples/svelte/with-tanstack-query/package.json @@ -22,6 +22,6 @@ }, "dependencies": { "@tanstack/svelte-query": "^6.1.36", - "@tanstack/svelte-table": "^9.0.0-beta.42" + "@tanstack/svelte-table": "^9.0.0-beta.43" } } diff --git a/examples/vanilla/basic/package.json b/examples/vanilla/basic/package.json index aeaa3de29c..fc5564ec94 100644 --- a/examples/vanilla/basic/package.json +++ b/examples/vanilla/basic/package.json @@ -17,6 +17,6 @@ "vite": "^8.1.0" }, "dependencies": { - "@tanstack/table-core": "^9.0.0-beta.42" + "@tanstack/table-core": "^9.0.0-beta.43" } } diff --git a/examples/vanilla/pagination/package.json b/examples/vanilla/pagination/package.json index 948ec1d832..5b757e0560 100644 --- a/examples/vanilla/pagination/package.json +++ b/examples/vanilla/pagination/package.json @@ -17,6 +17,6 @@ "vite": "^8.1.0" }, "dependencies": { - "@tanstack/table-core": "^9.0.0-beta.42" + "@tanstack/table-core": "^9.0.0-beta.43" } } diff --git a/examples/vanilla/pagination/src/main.ts b/examples/vanilla/pagination/src/main.ts index fcb63c43c4..0514d15f3a 100644 --- a/examples/vanilla/pagination/src/main.ts +++ b/examples/vanilla/pagination/src/main.ts @@ -24,6 +24,11 @@ const features = tableFeatures({ const columnHelper = createColumnHelper() const columns = columnHelper.columns([ + columnHelper.display({ + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }), columnHelper.accessor('firstName', { cell: (info) => info.getValue(), footer: (info) => info.column.id, diff --git a/examples/vanilla/sorting/package.json b/examples/vanilla/sorting/package.json index 1ecd70835e..81ba907374 100644 --- a/examples/vanilla/sorting/package.json +++ b/examples/vanilla/sorting/package.json @@ -17,6 +17,6 @@ "vite": "^8.1.0" }, "dependencies": { - "@tanstack/table-core": "^9.0.0-beta.42" + "@tanstack/table-core": "^9.0.0-beta.43" } } diff --git a/examples/vanilla/sorting/src/main.ts b/examples/vanilla/sorting/src/main.ts index 580099fd65..abacd18640 100644 --- a/examples/vanilla/sorting/src/main.ts +++ b/examples/vanilla/sorting/src/main.ts @@ -37,6 +37,11 @@ const sortStatusFn: SortFn = ( const columnHelper = createColumnHelper() const columns = columnHelper.columns([ + columnHelper.display({ + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }), columnHelper.accessor('firstName', { cell: (info) => info.getValue(), // This column will sort in ascending order by default since it is a string column diff --git a/examples/vue/basic-dynamic-columns/package.json b/examples/vue/basic-dynamic-columns/package.json index 5c583442f7..7ef9f2843f 100644 --- a/examples/vue/basic-dynamic-columns/package.json +++ b/examples/vue/basic-dynamic-columns/package.json @@ -12,8 +12,8 @@ "dependencies": { "@faker-js/faker": "^10.5.0", "@tanstack/vue-devtools": "^0.2.22", - "@tanstack/vue-table": "^9.0.0-beta.42", - "@tanstack/vue-table-devtools": "^9.0.0-beta.42", + "@tanstack/vue-table": "^9.0.0-beta.43", + "@tanstack/vue-table-devtools": "^9.0.0-beta.43", "vue": "^3.5.38" }, "devDependencies": { diff --git a/examples/vue/basic-external-atoms/package.json b/examples/vue/basic-external-atoms/package.json index 243f60282a..64f95d4621 100644 --- a/examples/vue/basic-external-atoms/package.json +++ b/examples/vue/basic-external-atoms/package.json @@ -13,8 +13,8 @@ "@faker-js/faker": "^10.5.0", "@tanstack/vue-devtools": "^0.2.22", "@tanstack/vue-store": "^0.11.0", - "@tanstack/vue-table": "^9.0.0-beta.42", - "@tanstack/vue-table-devtools": "^9.0.0-beta.42", + "@tanstack/vue-table": "^9.0.0-beta.43", + "@tanstack/vue-table-devtools": "^9.0.0-beta.43", "vue": "^3.5.38" }, "devDependencies": { diff --git a/examples/vue/basic-external-state/package.json b/examples/vue/basic-external-state/package.json index eae0ba7c19..3a647d3e37 100644 --- a/examples/vue/basic-external-state/package.json +++ b/examples/vue/basic-external-state/package.json @@ -12,8 +12,8 @@ "dependencies": { "@faker-js/faker": "^10.5.0", "@tanstack/vue-devtools": "^0.2.22", - "@tanstack/vue-table": "^9.0.0-beta.42", - "@tanstack/vue-table-devtools": "^9.0.0-beta.42", + "@tanstack/vue-table": "^9.0.0-beta.43", + "@tanstack/vue-table-devtools": "^9.0.0-beta.43", "vue": "^3.5.38" }, "devDependencies": { diff --git a/examples/vue/basic-use-app-table/package.json b/examples/vue/basic-use-app-table/package.json index 6cdac23c1b..8029a9bc17 100644 --- a/examples/vue/basic-use-app-table/package.json +++ b/examples/vue/basic-use-app-table/package.json @@ -11,8 +11,8 @@ }, "dependencies": { "@tanstack/vue-devtools": "^0.2.22", - "@tanstack/vue-table": "^9.0.0-beta.42", - "@tanstack/vue-table-devtools": "^9.0.0-beta.42", + "@tanstack/vue-table": "^9.0.0-beta.43", + "@tanstack/vue-table-devtools": "^9.0.0-beta.43", "vue": "^3.5.38" }, "devDependencies": { diff --git a/examples/vue/basic-use-table/package.json b/examples/vue/basic-use-table/package.json index ade8a85159..8e3bad7542 100644 --- a/examples/vue/basic-use-table/package.json +++ b/examples/vue/basic-use-table/package.json @@ -11,8 +11,8 @@ }, "dependencies": { "@tanstack/vue-devtools": "^0.2.22", - "@tanstack/vue-table": "^9.0.0-beta.42", - "@tanstack/vue-table-devtools": "^9.0.0-beta.42", + "@tanstack/vue-table": "^9.0.0-beta.43", + "@tanstack/vue-table-devtools": "^9.0.0-beta.43", "vue": "^3.5.38" }, "devDependencies": { diff --git a/examples/vue/column-groups/package.json b/examples/vue/column-groups/package.json index aa92a5a4a1..f5eb76b75f 100644 --- a/examples/vue/column-groups/package.json +++ b/examples/vue/column-groups/package.json @@ -11,7 +11,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/vue-table": "^9.0.0-beta.42", + "@tanstack/vue-table": "^9.0.0-beta.43", "vue": "^3.5.38" }, "devDependencies": { diff --git a/examples/vue/column-ordering/package.json b/examples/vue/column-ordering/package.json index 6a9f91833f..2b44fb453f 100644 --- a/examples/vue/column-ordering/package.json +++ b/examples/vue/column-ordering/package.json @@ -11,7 +11,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/vue-table": "^9.0.0-beta.42", + "@tanstack/vue-table": "^9.0.0-beta.43", "vue": "^3.5.38" }, "devDependencies": { diff --git a/examples/vue/column-pinning-split/package.json b/examples/vue/column-pinning-split/package.json index 3dda4a03f0..40d1875c51 100644 --- a/examples/vue/column-pinning-split/package.json +++ b/examples/vue/column-pinning-split/package.json @@ -11,7 +11,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/vue-table": "^9.0.0-beta.42", + "@tanstack/vue-table": "^9.0.0-beta.43", "vue": "^3.5.38" }, "devDependencies": { diff --git a/examples/vue/column-pinning-sticky/package.json b/examples/vue/column-pinning-sticky/package.json index 9ccf6c3364..c4a700b926 100644 --- a/examples/vue/column-pinning-sticky/package.json +++ b/examples/vue/column-pinning-sticky/package.json @@ -11,7 +11,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/vue-table": "^9.0.0-beta.42", + "@tanstack/vue-table": "^9.0.0-beta.43", "vue": "^3.5.38" }, "devDependencies": { diff --git a/examples/vue/column-pinning/package.json b/examples/vue/column-pinning/package.json index 400dcd2b16..eff66714d5 100644 --- a/examples/vue/column-pinning/package.json +++ b/examples/vue/column-pinning/package.json @@ -11,7 +11,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/vue-table": "^9.0.0-beta.42", + "@tanstack/vue-table": "^9.0.0-beta.43", "vue": "^3.5.38" }, "devDependencies": { diff --git a/examples/vue/column-resizing-performant/package.json b/examples/vue/column-resizing-performant/package.json index dad03de9d6..52fbb8d501 100644 --- a/examples/vue/column-resizing-performant/package.json +++ b/examples/vue/column-resizing-performant/package.json @@ -11,7 +11,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/vue-table": "^9.0.0-beta.42", + "@tanstack/vue-table": "^9.0.0-beta.43", "vue": "^3.5.38" }, "devDependencies": { diff --git a/examples/vue/column-resizing/package.json b/examples/vue/column-resizing/package.json index bcbb17cff3..7ab8fc83bf 100644 --- a/examples/vue/column-resizing/package.json +++ b/examples/vue/column-resizing/package.json @@ -11,7 +11,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/vue-table": "^9.0.0-beta.42", + "@tanstack/vue-table": "^9.0.0-beta.43", "vue": "^3.5.38" }, "devDependencies": { diff --git a/examples/vue/column-sizing/package.json b/examples/vue/column-sizing/package.json index 82f14f5784..2190669aa0 100644 --- a/examples/vue/column-sizing/package.json +++ b/examples/vue/column-sizing/package.json @@ -11,7 +11,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/vue-table": "^9.0.0-beta.42", + "@tanstack/vue-table": "^9.0.0-beta.43", "vue": "^3.5.38" }, "devDependencies": { diff --git a/examples/vue/column-visibility/package.json b/examples/vue/column-visibility/package.json index 6e64b0d9b7..a2320a2b6e 100644 --- a/examples/vue/column-visibility/package.json +++ b/examples/vue/column-visibility/package.json @@ -11,7 +11,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/vue-table": "^9.0.0-beta.42", + "@tanstack/vue-table": "^9.0.0-beta.43", "vue": "^3.5.38" }, "devDependencies": { diff --git a/examples/vue/composable-tables/package.json b/examples/vue/composable-tables/package.json index 25ce4d48e2..c3605d865c 100644 --- a/examples/vue/composable-tables/package.json +++ b/examples/vue/composable-tables/package.json @@ -12,8 +12,8 @@ "dependencies": { "@tanstack/vue-devtools": "^0.2.22", "@tanstack/vue-store": "^0.11.0", - "@tanstack/vue-table": "^9.0.0-beta.42", - "@tanstack/vue-table-devtools": "^9.0.0-beta.42", + "@tanstack/vue-table": "^9.0.0-beta.43", + "@tanstack/vue-table-devtools": "^9.0.0-beta.43", "vue": "^3.5.38" }, "devDependencies": { diff --git a/examples/vue/expanding/package.json b/examples/vue/expanding/package.json index de75e1f790..648f44b0bb 100644 --- a/examples/vue/expanding/package.json +++ b/examples/vue/expanding/package.json @@ -11,7 +11,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/vue-table": "^9.0.0-beta.42", + "@tanstack/vue-table": "^9.0.0-beta.43", "vue": "^3.5.38" }, "devDependencies": { diff --git a/examples/vue/expanding/src/App.tsx b/examples/vue/expanding/src/App.tsx index 57b6e49ee7..a962eec680 100644 --- a/examples/vue/expanding/src/App.tsx +++ b/examples/vue/expanding/src/App.tsx @@ -138,6 +138,11 @@ export default defineComponent({ } const columns = columnHelper.columns([ + columnHelper.display({ + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }), columnHelper.accessor('firstName', { header: ({ table }) => ( <> diff --git a/examples/vue/filters-faceted/package.json b/examples/vue/filters-faceted/package.json index 02678ab27c..d8b85965d0 100644 --- a/examples/vue/filters-faceted/package.json +++ b/examples/vue/filters-faceted/package.json @@ -11,7 +11,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/vue-table": "^9.0.0-beta.42", + "@tanstack/vue-table": "^9.0.0-beta.43", "vue": "^3.5.38" }, "devDependencies": { diff --git a/examples/vue/filters-fuzzy/package.json b/examples/vue/filters-fuzzy/package.json index 728a8328b3..2260f964b2 100644 --- a/examples/vue/filters-fuzzy/package.json +++ b/examples/vue/filters-fuzzy/package.json @@ -12,7 +12,7 @@ "dependencies": { "@faker-js/faker": "^10.5.0", "@tanstack/match-sorter-utils": "^9.0.0-beta.41", - "@tanstack/vue-table": "^9.0.0-beta.42", + "@tanstack/vue-table": "^9.0.0-beta.43", "vue": "^3.5.38" }, "devDependencies": { diff --git a/examples/vue/filters/package.json b/examples/vue/filters/package.json index 353f048483..e09901ddf0 100644 --- a/examples/vue/filters/package.json +++ b/examples/vue/filters/package.json @@ -11,7 +11,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/vue-table": "^9.0.0-beta.42", + "@tanstack/vue-table": "^9.0.0-beta.43", "vue": "^3.5.38" }, "devDependencies": { diff --git a/examples/vue/filters/src/App.vue b/examples/vue/filters/src/App.vue index 0c10a57446..8c4a86fdaa 100644 --- a/examples/vue/filters/src/App.vue +++ b/examples/vue/filters/src/App.vue @@ -10,6 +10,11 @@ const columnHelper = createAppColumnHelper() const columns = ref( columnHelper.columns([ + columnHelper.display({ + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }), columnHelper.group({ header: 'Name', footer: (props) => props.column.id, diff --git a/examples/vue/grouping/package.json b/examples/vue/grouping/package.json index 863e834b73..c61a8a503a 100644 --- a/examples/vue/grouping/package.json +++ b/examples/vue/grouping/package.json @@ -11,7 +11,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/vue-table": "^9.0.0-beta.42", + "@tanstack/vue-table": "^9.0.0-beta.43", "vue": "^3.5.38" }, "devDependencies": { diff --git a/examples/vue/kitchen-sink/package.json b/examples/vue/kitchen-sink/package.json index 13bbc662db..62fa323178 100644 --- a/examples/vue/kitchen-sink/package.json +++ b/examples/vue/kitchen-sink/package.json @@ -13,8 +13,8 @@ "@faker-js/faker": "^10.5.0", "@tanstack/match-sorter-utils": "^9.0.0-beta.41", "@tanstack/vue-devtools": "^0.2.22", - "@tanstack/vue-table": "^9.0.0-beta.42", - "@tanstack/vue-table-devtools": "^9.0.0-beta.42", + "@tanstack/vue-table": "^9.0.0-beta.43", + "@tanstack/vue-table-devtools": "^9.0.0-beta.43", "vue": "^3.5.38" }, "devDependencies": { diff --git a/examples/vue/pagination/package.json b/examples/vue/pagination/package.json index 9061bd9d76..2400da32cd 100644 --- a/examples/vue/pagination/package.json +++ b/examples/vue/pagination/package.json @@ -11,7 +11,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/vue-table": "^9.0.0-beta.42", + "@tanstack/vue-table": "^9.0.0-beta.43", "vue": "^3.5.38" }, "devDependencies": { diff --git a/examples/vue/pagination/src/App.vue b/examples/vue/pagination/src/App.vue index 33bda60504..7f9c9eef30 100644 --- a/examples/vue/pagination/src/App.vue +++ b/examples/vue/pagination/src/App.vue @@ -26,6 +26,11 @@ const data = ref(makeData(1_000)) const columns = ref( columnHelper.columns([ + columnHelper.display({ + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }), columnHelper.group({ header: 'Name', footer: (props) => props.column.id, diff --git a/examples/vue/row-pinning/package.json b/examples/vue/row-pinning/package.json index 5418ef48da..01e618e8b1 100644 --- a/examples/vue/row-pinning/package.json +++ b/examples/vue/row-pinning/package.json @@ -11,7 +11,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/vue-table": "^9.0.0-beta.42", + "@tanstack/vue-table": "^9.0.0-beta.43", "vue": "^3.5.38" }, "devDependencies": { diff --git a/examples/vue/row-selection/package.json b/examples/vue/row-selection/package.json index 86aa52eb05..b5c0c56294 100644 --- a/examples/vue/row-selection/package.json +++ b/examples/vue/row-selection/package.json @@ -12,8 +12,8 @@ "dependencies": { "@faker-js/faker": "^10.5.0", "@tanstack/vue-devtools": "^0.2.22", - "@tanstack/vue-table": "^9.0.0-beta.42", - "@tanstack/vue-table-devtools": "^9.0.0-beta.42", + "@tanstack/vue-table": "^9.0.0-beta.43", + "@tanstack/vue-table-devtools": "^9.0.0-beta.43", "vue": "^3.5.38" }, "devDependencies": { diff --git a/examples/vue/sorting/package.json b/examples/vue/sorting/package.json index 4f695dabf4..3a515c8485 100644 --- a/examples/vue/sorting/package.json +++ b/examples/vue/sorting/package.json @@ -11,7 +11,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/vue-table": "^9.0.0-beta.42", + "@tanstack/vue-table": "^9.0.0-beta.43", "vue": "^3.5.38" }, "devDependencies": { diff --git a/examples/vue/sorting/src/App.vue b/examples/vue/sorting/src/App.vue index 8fb1e40a77..ebf64c15ef 100644 --- a/examples/vue/sorting/src/App.vue +++ b/examples/vue/sorting/src/App.vue @@ -21,6 +21,11 @@ const features = tableFeatures({ const columnHelper = createColumnHelper() const columns = columnHelper.columns([ + columnHelper.display({ + id: 'rowNumber', + header: '#', + cell: ({ row }) => row.getDisplayIndex() + 1, + }), columnHelper.accessor('firstName', { cell: (info) => info.getValue(), footer: (props) => props.column.id, diff --git a/examples/vue/sub-components/package.json b/examples/vue/sub-components/package.json index f6664e284e..b858cdc485 100644 --- a/examples/vue/sub-components/package.json +++ b/examples/vue/sub-components/package.json @@ -11,7 +11,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/vue-table": "^9.0.0-beta.42", + "@tanstack/vue-table": "^9.0.0-beta.43", "vue": "^3.5.38" }, "devDependencies": { diff --git a/examples/vue/virtualized-columns/package.json b/examples/vue/virtualized-columns/package.json index 42376d5a73..cd056b5af5 100644 --- a/examples/vue/virtualized-columns/package.json +++ b/examples/vue/virtualized-columns/package.json @@ -11,7 +11,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/vue-table": "^9.0.0-beta.42", + "@tanstack/vue-table": "^9.0.0-beta.43", "@tanstack/vue-virtual": "^3.13.31", "vue": "^3.5.38" }, diff --git a/examples/vue/virtualized-infinite-scrolling/package.json b/examples/vue/virtualized-infinite-scrolling/package.json index e770ff6f2d..80a9ff47a1 100644 --- a/examples/vue/virtualized-infinite-scrolling/package.json +++ b/examples/vue/virtualized-infinite-scrolling/package.json @@ -14,7 +14,7 @@ "@tanstack/match-sorter-utils": "^9.0.0-beta.41", "@tanstack/vue-query": "^5.101.2", "@tanstack/vue-store": "^0.11.0", - "@tanstack/vue-table": "^9.0.0-beta.42", + "@tanstack/vue-table": "^9.0.0-beta.43", "@tanstack/vue-virtual": "^3.13.31", "vue": "^3.5.38" }, diff --git a/examples/vue/virtualized-rows/package.json b/examples/vue/virtualized-rows/package.json index 5edd11d3aa..ebd1665727 100644 --- a/examples/vue/virtualized-rows/package.json +++ b/examples/vue/virtualized-rows/package.json @@ -11,7 +11,7 @@ }, "dependencies": { "@faker-js/faker": "^10.5.0", - "@tanstack/vue-table": "^9.0.0-beta.42", + "@tanstack/vue-table": "^9.0.0-beta.43", "@tanstack/vue-virtual": "^3.13.31", "vue": "^3.5.38" }, diff --git a/examples/vue/with-tanstack-form/package.json b/examples/vue/with-tanstack-form/package.json index 7d824c8ed2..57ef288913 100644 --- a/examples/vue/with-tanstack-form/package.json +++ b/examples/vue/with-tanstack-form/package.json @@ -13,8 +13,8 @@ "@faker-js/faker": "^10.5.0", "@tanstack/vue-devtools": "^0.2.22", "@tanstack/vue-form": "^1.33.1", - "@tanstack/vue-table": "^9.0.0-beta.42", - "@tanstack/vue-table-devtools": "^9.0.0-beta.42", + "@tanstack/vue-table": "^9.0.0-beta.43", + "@tanstack/vue-table-devtools": "^9.0.0-beta.43", "vue": "^3.5.38", "zod": "^4.4.3" }, diff --git a/examples/vue/with-tanstack-query/package.json b/examples/vue/with-tanstack-query/package.json index c353d6696d..11965dc74c 100644 --- a/examples/vue/with-tanstack-query/package.json +++ b/examples/vue/with-tanstack-query/package.json @@ -14,7 +14,7 @@ "@tanstack/match-sorter-utils": "^9.0.0-beta.41", "@tanstack/vue-query": "^5.101.2", "@tanstack/vue-store": "^0.11.0", - "@tanstack/vue-table": "^9.0.0-beta.42", + "@tanstack/vue-table": "^9.0.0-beta.43", "vue": "^3.5.38" }, "devDependencies": { diff --git a/packages/alpine-table/package.json b/packages/alpine-table/package.json index caff1c7d77..471477e4d6 100644 --- a/packages/alpine-table/package.json +++ b/packages/alpine-table/package.json @@ -1,6 +1,6 @@ { "name": "@tanstack/alpine-table", - "version": "9.0.0-beta.42", + "version": "9.0.0-beta.43", "description": "Headless UI for building powerful tables & datagrids for Alpine.", "author": "Tanner Linsley", "license": "MIT", diff --git a/packages/alpine-table/skills/create-table-hook/SKILL.md b/packages/alpine-table/skills/create-table-hook/SKILL.md index b2760f0336..6da39e0386 100644 --- a/packages/alpine-table/skills/create-table-hook/SKILL.md +++ b/packages/alpine-table/skills/create-table-hook/SKILL.md @@ -6,7 +6,7 @@ metadata: type: framework library: '@tanstack/alpine-table' framework: alpine - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#core' - getting-started diff --git a/packages/alpine-table/skills/getting-started/SKILL.md b/packages/alpine-table/skills/getting-started/SKILL.md index 16329fb3f9..d4bf2d3a42 100644 --- a/packages/alpine-table/skills/getting-started/SKILL.md +++ b/packages/alpine-table/skills/getting-started/SKILL.md @@ -6,7 +6,7 @@ metadata: type: framework library: '@tanstack/alpine-table' framework: alpine - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#core' - '@tanstack/table-core#table-features' diff --git a/packages/alpine-table/skills/table-state/SKILL.md b/packages/alpine-table/skills/table-state/SKILL.md index f9ad9f16a7..1525c2b66f 100644 --- a/packages/alpine-table/skills/table-state/SKILL.md +++ b/packages/alpine-table/skills/table-state/SKILL.md @@ -6,7 +6,7 @@ metadata: type: framework library: '@tanstack/alpine-table' framework: alpine - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#core' - getting-started diff --git a/packages/angular-table-devtools/package.json b/packages/angular-table-devtools/package.json index 45ed437057..f83b8ede34 100644 --- a/packages/angular-table-devtools/package.json +++ b/packages/angular-table-devtools/package.json @@ -1,6 +1,6 @@ { "name": "@tanstack/angular-table-devtools", - "version": "9.0.0-beta.42", + "version": "9.0.0-beta.43", "description": "Angular devtools for TanStack Table.", "license": "MIT", "repository": { diff --git a/packages/angular-table-devtools/skills/devtools/SKILL.md b/packages/angular-table-devtools/skills/devtools/SKILL.md index 4a93752d1e..dfb7393422 100644 --- a/packages/angular-table-devtools/skills/devtools/SKILL.md +++ b/packages/angular-table-devtools/skills/devtools/SKILL.md @@ -6,7 +6,7 @@ metadata: type: framework library: '@tanstack/angular-table-devtools' framework: angular - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#core' - '@tanstack/table-devtools#devtools' diff --git a/packages/angular-table/package.json b/packages/angular-table/package.json index 8974597251..8c083c5c9e 100644 --- a/packages/angular-table/package.json +++ b/packages/angular-table/package.json @@ -1,6 +1,6 @@ { "name": "@tanstack/angular-table", - "version": "9.0.0-beta.42", + "version": "9.0.0-beta.43", "description": "Headless UI for building powerful tables & datagrids for Angular.", "author": "Tanner Linsley", "license": "MIT", diff --git a/packages/angular-table/skills/create-table-hook/SKILL.md b/packages/angular-table/skills/create-table-hook/SKILL.md index ea6462f3be..35a1c4475d 100644 --- a/packages/angular-table/skills/create-table-hook/SKILL.md +++ b/packages/angular-table/skills/create-table-hook/SKILL.md @@ -6,7 +6,7 @@ metadata: type: framework library: '@tanstack/angular-table' framework: angular - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#core' - getting-started diff --git a/packages/angular-table/skills/getting-started/SKILL.md b/packages/angular-table/skills/getting-started/SKILL.md index 7eb85a9e29..24a50fdde7 100644 --- a/packages/angular-table/skills/getting-started/SKILL.md +++ b/packages/angular-table/skills/getting-started/SKILL.md @@ -6,7 +6,7 @@ metadata: type: framework library: '@tanstack/angular-table' framework: angular - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#core' - '@tanstack/table-core#table-features' diff --git a/packages/angular-table/skills/migrate-v8-to-v9/SKILL.md b/packages/angular-table/skills/migrate-v8-to-v9/SKILL.md index 9b6a15390e..5a20fb4650 100644 --- a/packages/angular-table/skills/migrate-v8-to-v9/SKILL.md +++ b/packages/angular-table/skills/migrate-v8-to-v9/SKILL.md @@ -6,7 +6,7 @@ metadata: type: lifecycle library: '@tanstack/angular-table' framework: angular - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#migrate-v8-to-v9' - getting-started diff --git a/packages/angular-table/skills/table-state/SKILL.md b/packages/angular-table/skills/table-state/SKILL.md index 75bc939e02..12076649ed 100644 --- a/packages/angular-table/skills/table-state/SKILL.md +++ b/packages/angular-table/skills/table-state/SKILL.md @@ -6,7 +6,7 @@ metadata: type: framework library: '@tanstack/angular-table' framework: angular - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#core' - getting-started diff --git a/packages/angular-table/skills/with-tanstack-query/SKILL.md b/packages/angular-table/skills/with-tanstack-query/SKILL.md index 4b8ec9c835..a559e0aafa 100644 --- a/packages/angular-table/skills/with-tanstack-query/SKILL.md +++ b/packages/angular-table/skills/with-tanstack-query/SKILL.md @@ -6,7 +6,7 @@ metadata: type: composition library: '@tanstack/angular-table' framework: angular - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#client-vs-server' - getting-started diff --git a/packages/angular-table/skills/with-tanstack-virtual/SKILL.md b/packages/angular-table/skills/with-tanstack-virtual/SKILL.md index 3172525c9c..93cbaddfd7 100644 --- a/packages/angular-table/skills/with-tanstack-virtual/SKILL.md +++ b/packages/angular-table/skills/with-tanstack-virtual/SKILL.md @@ -6,7 +6,7 @@ metadata: type: composition library: '@tanstack/angular-table' framework: angular - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#core' - getting-started diff --git a/packages/ember-table/package.json b/packages/ember-table/package.json index bdd68f2fd1..8eaea2f02a 100644 --- a/packages/ember-table/package.json +++ b/packages/ember-table/package.json @@ -1,6 +1,6 @@ { "name": "@tanstack/ember-table", - "version": "9.0.0-beta.42", + "version": "9.0.0-beta.43", "description": "Headless UI for building powerful tables & datagrids for Ember.", "author": "Tanner Linsley", "license": "MIT", diff --git a/packages/ember-table/skills/create-table-hook/SKILL.md b/packages/ember-table/skills/create-table-hook/SKILL.md index ab6b5ba3c7..51a4378ef2 100644 --- a/packages/ember-table/skills/create-table-hook/SKILL.md +++ b/packages/ember-table/skills/create-table-hook/SKILL.md @@ -6,7 +6,7 @@ metadata: type: framework library: '@tanstack/ember-table' framework: ember - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#core' - getting-started diff --git a/packages/ember-table/skills/getting-started/SKILL.md b/packages/ember-table/skills/getting-started/SKILL.md index 8353d19b87..eb2f7cfb00 100644 --- a/packages/ember-table/skills/getting-started/SKILL.md +++ b/packages/ember-table/skills/getting-started/SKILL.md @@ -6,7 +6,7 @@ metadata: type: framework library: '@tanstack/ember-table' framework: ember - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#core' - '@tanstack/table-core#table-features' diff --git a/packages/ember-table/skills/table-state/SKILL.md b/packages/ember-table/skills/table-state/SKILL.md index 1329bf5479..4cdecc8f58 100644 --- a/packages/ember-table/skills/table-state/SKILL.md +++ b/packages/ember-table/skills/table-state/SKILL.md @@ -6,7 +6,7 @@ metadata: type: framework library: '@tanstack/ember-table' framework: ember - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#core' - getting-started diff --git a/packages/lit-table/package.json b/packages/lit-table/package.json index 1af3fdb0e8..2c211ec8da 100644 --- a/packages/lit-table/package.json +++ b/packages/lit-table/package.json @@ -1,6 +1,6 @@ { "name": "@tanstack/lit-table", - "version": "9.0.0-beta.42", + "version": "9.0.0-beta.43", "description": "Headless UI for building powerful tables & datagrids for Lit.", "author": "Tanner Linsley", "license": "MIT", diff --git a/packages/lit-table/skills/create-table-hook/SKILL.md b/packages/lit-table/skills/create-table-hook/SKILL.md index 0e5898b028..0bcc758523 100644 --- a/packages/lit-table/skills/create-table-hook/SKILL.md +++ b/packages/lit-table/skills/create-table-hook/SKILL.md @@ -6,7 +6,7 @@ metadata: type: framework library: '@tanstack/lit-table' framework: lit - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#core' - getting-started diff --git a/packages/lit-table/skills/getting-started/SKILL.md b/packages/lit-table/skills/getting-started/SKILL.md index 8df9971cb3..a652312916 100644 --- a/packages/lit-table/skills/getting-started/SKILL.md +++ b/packages/lit-table/skills/getting-started/SKILL.md @@ -6,7 +6,7 @@ metadata: type: framework library: '@tanstack/lit-table' framework: lit - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#core' - '@tanstack/table-core#table-features' diff --git a/packages/lit-table/skills/migrate-v8-to-v9/SKILL.md b/packages/lit-table/skills/migrate-v8-to-v9/SKILL.md index d015d4c686..a1728bddbc 100644 --- a/packages/lit-table/skills/migrate-v8-to-v9/SKILL.md +++ b/packages/lit-table/skills/migrate-v8-to-v9/SKILL.md @@ -6,7 +6,7 @@ metadata: type: lifecycle library: '@tanstack/lit-table' framework: lit - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#migrate-v8-to-v9' - getting-started diff --git a/packages/lit-table/skills/table-state/SKILL.md b/packages/lit-table/skills/table-state/SKILL.md index 374fc788db..52c20451b8 100644 --- a/packages/lit-table/skills/table-state/SKILL.md +++ b/packages/lit-table/skills/table-state/SKILL.md @@ -6,7 +6,7 @@ metadata: type: framework library: '@tanstack/lit-table' framework: lit - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#core' - getting-started diff --git a/packages/lit-table/skills/with-tanstack-virtual/SKILL.md b/packages/lit-table/skills/with-tanstack-virtual/SKILL.md index 9bda935d61..cee45aceb6 100644 --- a/packages/lit-table/skills/with-tanstack-virtual/SKILL.md +++ b/packages/lit-table/skills/with-tanstack-virtual/SKILL.md @@ -6,7 +6,7 @@ metadata: type: composition library: '@tanstack/lit-table' framework: lit - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#core' - getting-started diff --git a/packages/preact-table-devtools/package.json b/packages/preact-table-devtools/package.json index e33797c622..0493451b9f 100644 --- a/packages/preact-table-devtools/package.json +++ b/packages/preact-table-devtools/package.json @@ -1,6 +1,6 @@ { "name": "@tanstack/preact-table-devtools", - "version": "9.0.0-beta.42", + "version": "9.0.0-beta.43", "description": "Preact devtools for TanStack Table.", "author": "Tanner Linsley", "license": "MIT", diff --git a/packages/preact-table-devtools/skills/devtools/SKILL.md b/packages/preact-table-devtools/skills/devtools/SKILL.md index dcbd6650be..a18e21a19e 100644 --- a/packages/preact-table-devtools/skills/devtools/SKILL.md +++ b/packages/preact-table-devtools/skills/devtools/SKILL.md @@ -6,7 +6,7 @@ metadata: type: framework library: '@tanstack/preact-table-devtools' framework: preact - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#core' - '@tanstack/table-devtools#devtools' diff --git a/packages/preact-table/package.json b/packages/preact-table/package.json index 1eb0d472bc..5ec2c79f41 100644 --- a/packages/preact-table/package.json +++ b/packages/preact-table/package.json @@ -1,6 +1,6 @@ { "name": "@tanstack/preact-table", - "version": "9.0.0-beta.42", + "version": "9.0.0-beta.43", "description": "Headless UI for building powerful tables & datagrids for Preact.", "author": "Tanner Linsley", "license": "MIT", diff --git a/packages/preact-table/skills/create-table-hook/SKILL.md b/packages/preact-table/skills/create-table-hook/SKILL.md index a4b1cda0f7..ba7ace11ac 100644 --- a/packages/preact-table/skills/create-table-hook/SKILL.md +++ b/packages/preact-table/skills/create-table-hook/SKILL.md @@ -6,7 +6,7 @@ metadata: { type: framework, library: '@tanstack/preact-table', - library_version: '9.0.0-beta.42', + library_version: '9.0.0-beta.43', framework: preact, } requires: ['@tanstack/table-core#core', getting-started, table-state] diff --git a/packages/preact-table/skills/getting-started/SKILL.md b/packages/preact-table/skills/getting-started/SKILL.md index 3b705658f9..cf72f2be18 100644 --- a/packages/preact-table/skills/getting-started/SKILL.md +++ b/packages/preact-table/skills/getting-started/SKILL.md @@ -6,7 +6,7 @@ metadata: { type: framework, library: '@tanstack/preact-table', - library_version: '9.0.0-beta.42', + library_version: '9.0.0-beta.43', framework: preact, } requires: ['@tanstack/table-core#core', '@tanstack/table-core#table-features'] diff --git a/packages/preact-table/skills/migrate-v8-to-v9/SKILL.md b/packages/preact-table/skills/migrate-v8-to-v9/SKILL.md index 928f330a8d..1ecc6f1839 100644 --- a/packages/preact-table/skills/migrate-v8-to-v9/SKILL.md +++ b/packages/preact-table/skills/migrate-v8-to-v9/SKILL.md @@ -5,7 +5,7 @@ description: > metadata: type: lifecycle library: '@tanstack/preact-table' - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' framework: preact requires: - '@tanstack/table-core#migrate-v8-to-v9' diff --git a/packages/preact-table/skills/table-state/SKILL.md b/packages/preact-table/skills/table-state/SKILL.md index ddbd2725bf..6fcf47ec47 100644 --- a/packages/preact-table/skills/table-state/SKILL.md +++ b/packages/preact-table/skills/table-state/SKILL.md @@ -6,7 +6,7 @@ metadata: { type: framework, library: '@tanstack/preact-table', - library_version: '9.0.0-beta.42', + library_version: '9.0.0-beta.43', framework: preact, } requires: ['@tanstack/table-core#core', getting-started] diff --git a/packages/preact-table/skills/with-tanstack-query/SKILL.md b/packages/preact-table/skills/with-tanstack-query/SKILL.md index ac446cdf8d..83f1f35e8f 100644 --- a/packages/preact-table/skills/with-tanstack-query/SKILL.md +++ b/packages/preact-table/skills/with-tanstack-query/SKILL.md @@ -6,7 +6,7 @@ metadata: { type: composition, library: '@tanstack/preact-table', - library_version: '9.0.0-beta.42', + library_version: '9.0.0-beta.43', framework: preact, } requires: diff --git a/packages/preact-table/skills/with-tanstack-virtual/SKILL.md b/packages/preact-table/skills/with-tanstack-virtual/SKILL.md index 5508edea7b..b0fc2bfab4 100644 --- a/packages/preact-table/skills/with-tanstack-virtual/SKILL.md +++ b/packages/preact-table/skills/with-tanstack-virtual/SKILL.md @@ -6,7 +6,7 @@ metadata: { type: composition, library: '@tanstack/preact-table', - library_version: '9.0.0-beta.42', + library_version: '9.0.0-beta.43', framework: preact, } requires: ['@tanstack/table-core#core', getting-started, table-state] diff --git a/packages/react-table-devtools/package.json b/packages/react-table-devtools/package.json index 6cb513e12f..63e2493074 100644 --- a/packages/react-table-devtools/package.json +++ b/packages/react-table-devtools/package.json @@ -1,6 +1,6 @@ { "name": "@tanstack/react-table-devtools", - "version": "9.0.0-beta.42", + "version": "9.0.0-beta.43", "description": "React devtools for TanStack Table.", "author": "Tanner Linsley", "license": "MIT", diff --git a/packages/react-table-devtools/skills/devtools/SKILL.md b/packages/react-table-devtools/skills/devtools/SKILL.md index 5412cbc466..fd08519de5 100644 --- a/packages/react-table-devtools/skills/devtools/SKILL.md +++ b/packages/react-table-devtools/skills/devtools/SKILL.md @@ -6,7 +6,7 @@ metadata: type: framework library: '@tanstack/react-table-devtools' framework: react - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#core' - '@tanstack/table-devtools#devtools' diff --git a/packages/react-table/package.json b/packages/react-table/package.json index 2567fc14a7..c462f6d1a2 100644 --- a/packages/react-table/package.json +++ b/packages/react-table/package.json @@ -1,6 +1,6 @@ { "name": "@tanstack/react-table", - "version": "9.0.0-beta.42", + "version": "9.0.0-beta.43", "description": "Headless UI for building powerful tables & datagrids for React.", "author": "Tanner Linsley", "license": "MIT", diff --git a/packages/react-table/skills/create-table-hook/SKILL.md b/packages/react-table/skills/create-table-hook/SKILL.md index 55a11cdedc..a0256dd5f8 100644 --- a/packages/react-table/skills/create-table-hook/SKILL.md +++ b/packages/react-table/skills/create-table-hook/SKILL.md @@ -5,7 +5,7 @@ description: > metadata: type: framework library: '@tanstack/react-table' - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' framework: react requires: - '@tanstack/table-core#core' diff --git a/packages/react-table/skills/getting-started/SKILL.md b/packages/react-table/skills/getting-started/SKILL.md index cdfde40e17..0dd35b08a0 100644 --- a/packages/react-table/skills/getting-started/SKILL.md +++ b/packages/react-table/skills/getting-started/SKILL.md @@ -5,7 +5,7 @@ description: > metadata: type: framework library: '@tanstack/react-table' - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' framework: react requires: - '@tanstack/table-core#core' diff --git a/packages/react-table/skills/migrate-v8-to-v9/SKILL.md b/packages/react-table/skills/migrate-v8-to-v9/SKILL.md index e7e0471359..e0cba9224c 100644 --- a/packages/react-table/skills/migrate-v8-to-v9/SKILL.md +++ b/packages/react-table/skills/migrate-v8-to-v9/SKILL.md @@ -5,7 +5,7 @@ description: > metadata: type: lifecycle library: '@tanstack/react-table' - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' framework: react requires: - '@tanstack/table-core#migrate-v8-to-v9' diff --git a/packages/react-table/skills/table-state/SKILL.md b/packages/react-table/skills/table-state/SKILL.md index 557664bfea..966d5f78df 100644 --- a/packages/react-table/skills/table-state/SKILL.md +++ b/packages/react-table/skills/table-state/SKILL.md @@ -5,7 +5,7 @@ description: > metadata: type: framework library: '@tanstack/react-table' - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' framework: react requires: - '@tanstack/table-core#core' diff --git a/packages/react-table/skills/with-tanstack-query/SKILL.md b/packages/react-table/skills/with-tanstack-query/SKILL.md index 3f5297d5e8..332a0cc713 100644 --- a/packages/react-table/skills/with-tanstack-query/SKILL.md +++ b/packages/react-table/skills/with-tanstack-query/SKILL.md @@ -5,7 +5,7 @@ description: > metadata: type: composition library: '@tanstack/react-table' - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' framework: react requires: - '@tanstack/table-core#client-vs-server' diff --git a/packages/react-table/skills/with-tanstack-virtual/SKILL.md b/packages/react-table/skills/with-tanstack-virtual/SKILL.md index 680bbef5d3..f45806ada7 100644 --- a/packages/react-table/skills/with-tanstack-virtual/SKILL.md +++ b/packages/react-table/skills/with-tanstack-virtual/SKILL.md @@ -5,7 +5,7 @@ description: > metadata: type: composition library: '@tanstack/react-table' - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' framework: react requires: - '@tanstack/table-core#core' diff --git a/packages/solid-table-devtools/package.json b/packages/solid-table-devtools/package.json index 1ce67d8c4c..d0e5115d33 100644 --- a/packages/solid-table-devtools/package.json +++ b/packages/solid-table-devtools/package.json @@ -1,6 +1,6 @@ { "name": "@tanstack/solid-table-devtools", - "version": "9.0.0-beta.42", + "version": "9.0.0-beta.43", "description": "Solid devtools for TanStack Table.", "author": "Tanner Linsley", "license": "MIT", diff --git a/packages/solid-table-devtools/skills/devtools/SKILL.md b/packages/solid-table-devtools/skills/devtools/SKILL.md index d239aefaad..19858b60d3 100644 --- a/packages/solid-table-devtools/skills/devtools/SKILL.md +++ b/packages/solid-table-devtools/skills/devtools/SKILL.md @@ -6,7 +6,7 @@ metadata: type: framework library: '@tanstack/solid-table-devtools' framework: solid - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#core' - '@tanstack/table-devtools#devtools' diff --git a/packages/solid-table/package.json b/packages/solid-table/package.json index 4dbc0637ec..5847f2c5b2 100644 --- a/packages/solid-table/package.json +++ b/packages/solid-table/package.json @@ -1,6 +1,6 @@ { "name": "@tanstack/solid-table", - "version": "9.0.0-beta.42", + "version": "9.0.0-beta.43", "description": "Headless UI for building powerful tables & datagrids for Solid.", "author": "Tanner Linsley", "license": "MIT", diff --git a/packages/solid-table/skills/create-table-hook/SKILL.md b/packages/solid-table/skills/create-table-hook/SKILL.md index 02995f915e..9d99d19957 100644 --- a/packages/solid-table/skills/create-table-hook/SKILL.md +++ b/packages/solid-table/skills/create-table-hook/SKILL.md @@ -6,7 +6,7 @@ metadata: { type: framework, library: '@tanstack/solid-table', - library_version: '9.0.0-beta.42', + library_version: '9.0.0-beta.43', framework: solid, } requires: ['@tanstack/table-core#core', getting-started, table-state] diff --git a/packages/solid-table/skills/getting-started/SKILL.md b/packages/solid-table/skills/getting-started/SKILL.md index f97f534d02..2190c4cee5 100644 --- a/packages/solid-table/skills/getting-started/SKILL.md +++ b/packages/solid-table/skills/getting-started/SKILL.md @@ -6,7 +6,7 @@ metadata: { type: framework, library: '@tanstack/solid-table', - library_version: '9.0.0-beta.42', + library_version: '9.0.0-beta.43', framework: solid, } requires: ['@tanstack/table-core#core', '@tanstack/table-core#table-features'] diff --git a/packages/solid-table/skills/migrate-v8-to-v9/SKILL.md b/packages/solid-table/skills/migrate-v8-to-v9/SKILL.md index 19268c95b5..18c1e2a487 100644 --- a/packages/solid-table/skills/migrate-v8-to-v9/SKILL.md +++ b/packages/solid-table/skills/migrate-v8-to-v9/SKILL.md @@ -5,7 +5,7 @@ description: > metadata: type: lifecycle library: '@tanstack/solid-table' - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' framework: solid requires: - '@tanstack/table-core#migrate-v8-to-v9' diff --git a/packages/solid-table/skills/table-state/SKILL.md b/packages/solid-table/skills/table-state/SKILL.md index 89bd543391..1c1c401f7a 100644 --- a/packages/solid-table/skills/table-state/SKILL.md +++ b/packages/solid-table/skills/table-state/SKILL.md @@ -6,7 +6,7 @@ metadata: { type: framework, library: '@tanstack/solid-table', - library_version: '9.0.0-beta.42', + library_version: '9.0.0-beta.43', framework: solid, } requires: ['@tanstack/table-core#core', getting-started] diff --git a/packages/solid-table/skills/with-tanstack-query/SKILL.md b/packages/solid-table/skills/with-tanstack-query/SKILL.md index 4de65be051..f1a1e15e1d 100644 --- a/packages/solid-table/skills/with-tanstack-query/SKILL.md +++ b/packages/solid-table/skills/with-tanstack-query/SKILL.md @@ -6,7 +6,7 @@ metadata: { type: composition, library: '@tanstack/solid-table', - library_version: '9.0.0-beta.42', + library_version: '9.0.0-beta.43', framework: solid, } requires: diff --git a/packages/solid-table/skills/with-tanstack-virtual/SKILL.md b/packages/solid-table/skills/with-tanstack-virtual/SKILL.md index a6978cf9b0..573fbf225f 100644 --- a/packages/solid-table/skills/with-tanstack-virtual/SKILL.md +++ b/packages/solid-table/skills/with-tanstack-virtual/SKILL.md @@ -6,7 +6,7 @@ metadata: { type: composition, library: '@tanstack/solid-table', - library_version: '9.0.0-beta.42', + library_version: '9.0.0-beta.43', framework: solid, } requires: ['@tanstack/table-core#core', getting-started, table-state] diff --git a/packages/svelte-table/eslint.config.js b/packages/svelte-table/eslint.config.js index 3e317481c5..b39a1b670c 100644 --- a/packages/svelte-table/eslint.config.js +++ b/packages/svelte-table/eslint.config.js @@ -23,7 +23,19 @@ export default [ languageOptions: { parserOptions: { parser: tsParser, + project: false, + projectService: true, + extraFileExtensions: ['.svelte'], + tsconfigRootDir: import.meta.dirname, }, }, }, + { + files: ['**/FlexRender.svelte'], + rules: { + // The rule does not detect property reads through this component's + // generic union-based Props type. + 'svelte/no-unused-props': 'off', + }, + }, ] diff --git a/packages/svelte-table/package.json b/packages/svelte-table/package.json index d8492c7691..cccae864fc 100644 --- a/packages/svelte-table/package.json +++ b/packages/svelte-table/package.json @@ -1,6 +1,6 @@ { "name": "@tanstack/svelte-table", - "version": "9.0.0-beta.42", + "version": "9.0.0-beta.43", "description": "Headless UI for building powerful tables & datagrids for Svelte.", "author": "Tanner Linsley", "license": "MIT", diff --git a/packages/svelte-table/skills/create-table-hook/SKILL.md b/packages/svelte-table/skills/create-table-hook/SKILL.md index 441ac25f36..9d34aa99a1 100644 --- a/packages/svelte-table/skills/create-table-hook/SKILL.md +++ b/packages/svelte-table/skills/create-table-hook/SKILL.md @@ -6,7 +6,7 @@ metadata: type: framework library: '@tanstack/svelte-table' framework: svelte - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#core' - getting-started diff --git a/packages/svelte-table/skills/getting-started/SKILL.md b/packages/svelte-table/skills/getting-started/SKILL.md index c4476696d8..d82f32a331 100644 --- a/packages/svelte-table/skills/getting-started/SKILL.md +++ b/packages/svelte-table/skills/getting-started/SKILL.md @@ -6,7 +6,7 @@ metadata: type: framework library: '@tanstack/svelte-table' framework: svelte - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#core' - '@tanstack/table-core#table-features' diff --git a/packages/svelte-table/skills/migrate-v8-to-v9/SKILL.md b/packages/svelte-table/skills/migrate-v8-to-v9/SKILL.md index 62d55f3655..00e98ba978 100644 --- a/packages/svelte-table/skills/migrate-v8-to-v9/SKILL.md +++ b/packages/svelte-table/skills/migrate-v8-to-v9/SKILL.md @@ -6,7 +6,7 @@ metadata: type: lifecycle library: '@tanstack/svelte-table' framework: svelte - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#migrate-v8-to-v9' - getting-started diff --git a/packages/svelte-table/skills/table-state/SKILL.md b/packages/svelte-table/skills/table-state/SKILL.md index a0ed6c4e34..5054c9153a 100644 --- a/packages/svelte-table/skills/table-state/SKILL.md +++ b/packages/svelte-table/skills/table-state/SKILL.md @@ -6,7 +6,7 @@ metadata: type: framework library: '@tanstack/svelte-table' framework: svelte - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#core' - getting-started diff --git a/packages/svelte-table/skills/with-tanstack-query/SKILL.md b/packages/svelte-table/skills/with-tanstack-query/SKILL.md index a6b707eda6..2efd18d114 100644 --- a/packages/svelte-table/skills/with-tanstack-query/SKILL.md +++ b/packages/svelte-table/skills/with-tanstack-query/SKILL.md @@ -6,7 +6,7 @@ metadata: type: composition library: '@tanstack/svelte-table' framework: svelte - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#client-vs-server' - getting-started diff --git a/packages/svelte-table/skills/with-tanstack-virtual/SKILL.md b/packages/svelte-table/skills/with-tanstack-virtual/SKILL.md index 21e3fba32e..e9ff5f53e8 100644 --- a/packages/svelte-table/skills/with-tanstack-virtual/SKILL.md +++ b/packages/svelte-table/skills/with-tanstack-virtual/SKILL.md @@ -6,7 +6,7 @@ metadata: type: composition library: '@tanstack/svelte-table' framework: svelte - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#core' - getting-started diff --git a/packages/table-core/eslint.config.js b/packages/table-core/eslint.config.js index 5880eb7bfa..8765d15329 100644 --- a/packages/table-core/eslint.config.js +++ b/packages/table-core/eslint.config.js @@ -6,6 +6,12 @@ import rootConfig from '../../eslint.config.js' const config = [ ...rootConfig, { + languageOptions: { + parserOptions: { + project: true, + tsconfigRootDir: import.meta.dirname, + }, + }, rules: {}, }, ] diff --git a/packages/table-core/package.json b/packages/table-core/package.json index b8487b830f..9e75a607f4 100644 --- a/packages/table-core/package.json +++ b/packages/table-core/package.json @@ -1,6 +1,6 @@ { "name": "@tanstack/table-core", - "version": "9.0.0-beta.42", + "version": "9.0.0-beta.43", "description": "Headless UI for building powerful tables & datagrids for TS/JS.", "author": "Tanner Linsley", "license": "MIT", diff --git a/packages/table-core/skills/api-not-found/SKILL.md b/packages/table-core/skills/api-not-found/SKILL.md index c4b3b655a5..18e9c5b582 100644 --- a/packages/table-core/skills/api-not-found/SKILL.md +++ b/packages/table-core/skills/api-not-found/SKILL.md @@ -5,7 +5,7 @@ description: > metadata: type: sub-skill library: '@tanstack/table-core' - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: ['core', 'table-features'] sources: - 'TanStack/table:packages/table-core/src/index.ts' diff --git a/packages/table-core/skills/client-vs-server/SKILL.md b/packages/table-core/skills/client-vs-server/SKILL.md index 545fcf4bc5..f1f20a36c4 100644 --- a/packages/table-core/skills/client-vs-server/SKILL.md +++ b/packages/table-core/skills/client-vs-server/SKILL.md @@ -5,7 +5,7 @@ description: > metadata: type: sub-skill library: '@tanstack/table-core' - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: ['core', 'table-features'] sources: - 'TanStack/table:docs/guide/row-models.md' diff --git a/packages/table-core/skills/column-faceting/SKILL.md b/packages/table-core/skills/column-faceting/SKILL.md index efc4f40966..225790aad5 100644 --- a/packages/table-core/skills/column-faceting/SKILL.md +++ b/packages/table-core/skills/column-faceting/SKILL.md @@ -6,7 +6,7 @@ metadata: { type: sub-skill, library: '@tanstack/table-core', - library_version: '9.0.0-beta.42', + library_version: '9.0.0-beta.43', } requires: ['core', 'table-features', 'column-filtering'] sources: diff --git a/packages/table-core/skills/column-filtering/SKILL.md b/packages/table-core/skills/column-filtering/SKILL.md index 95c7530e6c..b7b95f2289 100644 --- a/packages/table-core/skills/column-filtering/SKILL.md +++ b/packages/table-core/skills/column-filtering/SKILL.md @@ -6,7 +6,7 @@ metadata: { type: sub-skill, library: '@tanstack/table-core', - library_version: '9.0.0-beta.42', + library_version: '9.0.0-beta.43', } requires: ['core', 'table-features', 'client-vs-server'] sources: diff --git a/packages/table-core/skills/column-ordering/SKILL.md b/packages/table-core/skills/column-ordering/SKILL.md index 62ebed5d25..6f6d264fee 100644 --- a/packages/table-core/skills/column-ordering/SKILL.md +++ b/packages/table-core/skills/column-ordering/SKILL.md @@ -6,7 +6,7 @@ metadata: { type: sub-skill, library: '@tanstack/table-core', - library_version: '9.0.0-beta.42', + library_version: '9.0.0-beta.43', } requires: ['core', 'table-features'] sources: diff --git a/packages/table-core/skills/column-pinning/SKILL.md b/packages/table-core/skills/column-pinning/SKILL.md index ddb920d6ce..b653e6f1c7 100644 --- a/packages/table-core/skills/column-pinning/SKILL.md +++ b/packages/table-core/skills/column-pinning/SKILL.md @@ -6,7 +6,7 @@ metadata: { type: sub-skill, library: '@tanstack/table-core', - library_version: '9.0.0-beta.42', + library_version: '9.0.0-beta.43', } requires: ['core', 'table-features', 'column-sizing'] sources: diff --git a/packages/table-core/skills/column-resizing/SKILL.md b/packages/table-core/skills/column-resizing/SKILL.md index 669332dadc..432430baf9 100644 --- a/packages/table-core/skills/column-resizing/SKILL.md +++ b/packages/table-core/skills/column-resizing/SKILL.md @@ -6,7 +6,7 @@ metadata: { type: sub-skill, library: '@tanstack/table-core', - library_version: '9.0.0-beta.42', + library_version: '9.0.0-beta.43', } requires: ['core', 'table-features', 'column-sizing'] sources: diff --git a/packages/table-core/skills/column-sizing/SKILL.md b/packages/table-core/skills/column-sizing/SKILL.md index 6c1d60a778..24579f0475 100644 --- a/packages/table-core/skills/column-sizing/SKILL.md +++ b/packages/table-core/skills/column-sizing/SKILL.md @@ -6,7 +6,7 @@ metadata: { type: sub-skill, library: '@tanstack/table-core', - library_version: '9.0.0-beta.42', + library_version: '9.0.0-beta.43', } requires: ['core', 'table-features'] sources: diff --git a/packages/table-core/skills/column-visibility/SKILL.md b/packages/table-core/skills/column-visibility/SKILL.md index 2cec5f7b92..f1615946c8 100644 --- a/packages/table-core/skills/column-visibility/SKILL.md +++ b/packages/table-core/skills/column-visibility/SKILL.md @@ -6,7 +6,7 @@ metadata: { type: sub-skill, library: '@tanstack/table-core', - library_version: '9.0.0-beta.42', + library_version: '9.0.0-beta.43', } requires: ['core', 'table-features'] sources: diff --git a/packages/table-core/skills/core/SKILL.md b/packages/table-core/skills/core/SKILL.md index 0a607389f8..637d7d2ab1 100644 --- a/packages/table-core/skills/core/SKILL.md +++ b/packages/table-core/skills/core/SKILL.md @@ -5,7 +5,7 @@ description: > metadata: type: core library: '@tanstack/table-core' - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' sources: - 'TanStack/table:docs/overview.md' - 'TanStack/table:docs/guide/tables.md' diff --git a/packages/table-core/skills/custom-features/SKILL.md b/packages/table-core/skills/custom-features/SKILL.md index a7ea239972..5aeb0a3f14 100644 --- a/packages/table-core/skills/custom-features/SKILL.md +++ b/packages/table-core/skills/custom-features/SKILL.md @@ -5,7 +5,7 @@ description: > metadata: type: sub-skill library: '@tanstack/table-core' - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: ['core', 'table-features', 'typescript'] sources: - 'TanStack/table:docs/framework/react/guide/custom-features.md' diff --git a/packages/table-core/skills/expanding/SKILL.md b/packages/table-core/skills/expanding/SKILL.md index 19ed718e71..2c794de4b6 100644 --- a/packages/table-core/skills/expanding/SKILL.md +++ b/packages/table-core/skills/expanding/SKILL.md @@ -6,7 +6,7 @@ metadata: { type: sub-skill, library: '@tanstack/table-core', - library_version: '9.0.0-beta.42', + library_version: '9.0.0-beta.43', } requires: ['core', 'table-features', 'client-vs-server'] sources: diff --git a/packages/table-core/skills/global-filtering/SKILL.md b/packages/table-core/skills/global-filtering/SKILL.md index cf52ce16f4..aef1a5ebfb 100644 --- a/packages/table-core/skills/global-filtering/SKILL.md +++ b/packages/table-core/skills/global-filtering/SKILL.md @@ -6,7 +6,7 @@ metadata: { type: sub-skill, library: '@tanstack/table-core', - library_version: '9.0.0-beta.42', + library_version: '9.0.0-beta.43', } requires: ['core', 'table-features', 'client-vs-server', 'column-filtering'] sources: diff --git a/packages/table-core/skills/grouping/SKILL.md b/packages/table-core/skills/grouping/SKILL.md index fefda25407..cda2fcd100 100644 --- a/packages/table-core/skills/grouping/SKILL.md +++ b/packages/table-core/skills/grouping/SKILL.md @@ -6,7 +6,7 @@ metadata: { type: sub-skill, library: '@tanstack/table-core', - library_version: '9.0.0-beta.42', + library_version: '9.0.0-beta.43', } requires: ['core', 'table-features', 'client-vs-server'] sources: diff --git a/packages/table-core/skills/migrate-v8-to-v9/SKILL.md b/packages/table-core/skills/migrate-v8-to-v9/SKILL.md index 67d2262067..872a601afa 100644 --- a/packages/table-core/skills/migrate-v8-to-v9/SKILL.md +++ b/packages/table-core/skills/migrate-v8-to-v9/SKILL.md @@ -5,7 +5,7 @@ description: > metadata: type: lifecycle library: '@tanstack/table-core' - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: ['core', 'table-features', 'typescript'] sources: - 'TanStack/table:docs/framework/react/guide/migrating.md' diff --git a/packages/table-core/skills/pagination/SKILL.md b/packages/table-core/skills/pagination/SKILL.md index a59acd1c43..b9563521d0 100644 --- a/packages/table-core/skills/pagination/SKILL.md +++ b/packages/table-core/skills/pagination/SKILL.md @@ -6,7 +6,7 @@ metadata: { type: sub-skill, library: '@tanstack/table-core', - library_version: '9.0.0-beta.42', + library_version: '9.0.0-beta.43', } requires: ['core', 'table-features', 'client-vs-server'] sources: diff --git a/packages/table-core/skills/row-pinning/SKILL.md b/packages/table-core/skills/row-pinning/SKILL.md index e0a2476666..016d670477 100644 --- a/packages/table-core/skills/row-pinning/SKILL.md +++ b/packages/table-core/skills/row-pinning/SKILL.md @@ -6,7 +6,7 @@ metadata: { type: sub-skill, library: '@tanstack/table-core', - library_version: '9.0.0-beta.42', + library_version: '9.0.0-beta.43', } requires: ['core', 'table-features'] sources: diff --git a/packages/table-core/skills/row-selection/SKILL.md b/packages/table-core/skills/row-selection/SKILL.md index 9ed674bc65..ec6cc0ee9c 100644 --- a/packages/table-core/skills/row-selection/SKILL.md +++ b/packages/table-core/skills/row-selection/SKILL.md @@ -6,7 +6,7 @@ metadata: { type: sub-skill, library: '@tanstack/table-core', - library_version: '9.0.0-beta.42', + library_version: '9.0.0-beta.43', } requires: ['core', 'table-features'] sources: diff --git a/packages/table-core/skills/sorting/SKILL.md b/packages/table-core/skills/sorting/SKILL.md index 2c0f5415ee..1fd93ae576 100644 --- a/packages/table-core/skills/sorting/SKILL.md +++ b/packages/table-core/skills/sorting/SKILL.md @@ -6,7 +6,7 @@ metadata: { type: sub-skill, library: '@tanstack/table-core', - library_version: '9.0.0-beta.42', + library_version: '9.0.0-beta.43', } requires: ['core', 'table-features', 'client-vs-server'] sources: diff --git a/packages/table-core/skills/table-features/SKILL.md b/packages/table-core/skills/table-features/SKILL.md index b08efb40ea..d78afee666 100644 --- a/packages/table-core/skills/table-features/SKILL.md +++ b/packages/table-core/skills/table-features/SKILL.md @@ -5,7 +5,7 @@ description: > metadata: type: sub-skill library: '@tanstack/table-core' - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: ['core'] sources: - 'TanStack/table:docs/guide/row-models.md' diff --git a/packages/table-core/skills/typescript/SKILL.md b/packages/table-core/skills/typescript/SKILL.md index d33a4969ba..12d6c9c327 100644 --- a/packages/table-core/skills/typescript/SKILL.md +++ b/packages/table-core/skills/typescript/SKILL.md @@ -5,7 +5,7 @@ description: > metadata: type: sub-skill library: '@tanstack/table-core' - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: ['core', 'table-features'] sources: - 'TanStack/table:docs/guide/helpers.md' diff --git a/packages/table-core/src/core/rows/constructRow.ts b/packages/table-core/src/core/rows/constructRow.ts index 4a1a56ae3d..663f346962 100644 --- a/packages/table-core/src/core/rows/constructRow.ts +++ b/packages/table-core/src/core/rows/constructRow.ts @@ -48,6 +48,7 @@ export const constructRow = < > // Only assign instance-specific properties + row._displayIndexCache = -1 row._uniqueValuesCache = makeObjectMap() row._valuesCache = makeObjectMap() row.depth = depth diff --git a/packages/table-core/src/core/rows/coreRowsFeature.ts b/packages/table-core/src/core/rows/coreRowsFeature.ts index d3f801c03b..01701f876a 100644 --- a/packages/table-core/src/core/rows/coreRowsFeature.ts +++ b/packages/table-core/src/core/rows/coreRowsFeature.ts @@ -2,6 +2,7 @@ import { assignPrototypeAPIs, assignTableAPIs } from '../../utils' import { row_getAllCells, row_getAllCellsByColumnId, + row_getDisplayIndex, row_getLeafRows, row_getParentRow, row_getParentRows, @@ -10,6 +11,7 @@ import { row_renderValue, table_getRow, table_getRowId, + table_getRowsInDisplayOrder, } from './coreRowsFeature.utils' import type { TableFeature } from '../../types/TableFeatures' @@ -19,6 +21,9 @@ import type { TableFeature } from '../../types/TableFeatures' export const coreRowsFeature: TableFeature = { assignRowPrototype: (prototype, table) => { assignPrototypeAPIs('coreRowsFeature', prototype, table, { + row_getDisplayIndex: { + fn: (row) => row_getDisplayIndex(row), + }, row_getAllCellsByColumnId: { fn: (row) => row_getAllCellsByColumnId(row), memoDeps: (row) => [row.getAllCells()], @@ -50,6 +55,16 @@ export const coreRowsFeature: TableFeature = { }, constructTableAPIs: (table) => { assignTableAPIs('coreRowsFeature', table, { + table_getRowsInDisplayOrder: { + fn: () => table_getRowsInDisplayOrder(table), + memoDeps: () => [ + table.getPrePaginatedRowModel().rows, + table.options.paginateExpandedRows, + table.options.paginateExpandedRows === false + ? table.atoms.expanded?.get() + : undefined, + ], + }, table_getRowId: { fn: (originalRow, index, parent) => table_getRowId(originalRow, table, index, parent), diff --git a/packages/table-core/src/core/rows/coreRowsFeature.types.ts b/packages/table-core/src/core/rows/coreRowsFeature.types.ts index 993775a9fb..42ce63eb46 100644 --- a/packages/table-core/src/core/rows/coreRowsFeature.types.ts +++ b/packages/table-core/src/core/rows/coreRowsFeature.types.ts @@ -13,6 +13,7 @@ export interface Row_CoreProperties< Column, Cell > + _displayIndexCache: number _uniqueValuesCache: Record _valuesCache: Record /** @@ -53,6 +54,11 @@ export interface Row_Row< in out TFeatures extends TableFeatures, in out TData extends RowData, > extends Row_CoreProperties { + /** + * Returns the zero-based index of the row in the current display order + * before pagination, or `-1` if the row is not in that model. + */ + getDisplayIndex: () => number /** * Builds a lookup of this row's cells keyed by leaf column id. */ @@ -114,6 +120,13 @@ export interface Table_Rows< in out TFeatures extends TableFeatures, in out TData extends RowData, > { + /** + * Returns the rows in the current display order and assigns their display + * indexes. When expanded rows bypass pagination, expanded descendants are + * included in this order. This is the memoized source for + * `row.getDisplayIndex()`. + */ + getRowsInDisplayOrder: () => Array> getRowId: (_: TData, index: number, parent?: Row) => string /** * Returns the row with the given ID. diff --git a/packages/table-core/src/core/rows/coreRowsFeature.utils.ts b/packages/table-core/src/core/rows/coreRowsFeature.utils.ts index 2e8b74927c..06b8f0ad6c 100644 --- a/packages/table-core/src/core/rows/coreRowsFeature.utils.ts +++ b/packages/table-core/src/core/rows/coreRowsFeature.utils.ts @@ -5,6 +5,64 @@ import type { RowData } from '../../types/type-utils' import type { TableFeatures } from '../../types/TableFeatures' import type { Row } from '../../types/Row' import type { Cell } from '../../types/Cell' +import type { Row_RowExpanding } from '../../features/row-expanding/rowExpandingFeature.types' + +/** + * Returns this row's zero-based position in the current pre-pagination row + * model. Rows outside that model return `-1`. + */ +export function row_getDisplayIndex< + TFeatures extends TableFeatures, + TData extends RowData, +>(row: Row) { + const rows = row.table.getRowsInDisplayOrder() + const displayIndex = row._displayIndexCache + + return rows[displayIndex] === row ? displayIndex : -1 +} + +/** + * Returns the rows in the current display order after assigning their + * zero-based display indexes. + * + * When expanded rows bypass pagination, expanded descendants are inserted into + * the returned order even though they are absent from the pre-pagination row + * model. + */ +export function table_getRowsInDisplayOrder< + TFeatures extends TableFeatures, + TData extends RowData, +>(table: Table_Internal) { + const rows = table.getPrePaginatedRowModel().rows + + if (table.options.paginateExpandedRows === false) { + const displayRows: Array> = [] + + const handleRow = (row: Row) => { + row._displayIndexCache = displayRows.length + displayRows.push(row) + + if ( + row.subRows.length && + ( + row as Row & Partial + ).getIsExpanded?.() + ) { + row.subRows.forEach(handleRow) + } + } + + rows.forEach(handleRow) + + return displayRows + } + + for (let i = 0; i < rows.length; i++) { + rows[i]!._displayIndexCache = i + } + + return rows +} /** * Reads and caches this row's value for a column. diff --git a/packages/table-core/tests/implementation/features/column-filtering/createFilteredRowModel.test.ts b/packages/table-core/tests/implementation/features/column-filtering/createFilteredRowModel.test.ts new file mode 100644 index 0000000000..b7150ea3a4 --- /dev/null +++ b/packages/table-core/tests/implementation/features/column-filtering/createFilteredRowModel.test.ts @@ -0,0 +1,50 @@ +import { describe, expect, it } from 'vitest' +import { + columnFilteringFeature, + constructTable, + createFilteredRowModel, + filterFns, +} from '../../../../src' +import { testFeatures } from '../../../fixtures/features' +import type { ColumnDef } from '../../../../src' + +interface TestRow { + name: string +} + +const features = testFeatures({ + columnFilteringFeature, + filteredRowModel: createFilteredRowModel(), + filterFns, +}) + +const columns: Array> = [ + { accessorKey: 'name', id: 'name' }, +] + +describe('createFilteredRowModel', () => { + it('assigns display indexes in filtered row order', () => { + const table = constructTable({ + features, + columns, + data: [{ name: 'keep' }, { name: 'drop' }, { name: 'keep' }], + initialState: { + columnFilters: [{ id: 'name', value: 'keep' }], + }, + }) + + const rows = table.getRowModel().rows + const filteredOutRow = table.getCoreRowModel().rows[1]! + + expect(rows.map((row) => row.index)).toEqual([0, 2]) + expect(rows.map((row) => row.getDisplayIndex())).toEqual([0, 1]) + expect(filteredOutRow.getDisplayIndex()).toBe(-1) + + table.setColumnFilters([]) + + expect( + table.getRowModel().rows.map((row) => row.getDisplayIndex()), + ).toEqual([0, 1, 2]) + expect(filteredOutRow.getDisplayIndex()).toBe(1) + }) +}) diff --git a/packages/table-core/tests/implementation/features/column-grouping/createGroupedRowModel.test.ts b/packages/table-core/tests/implementation/features/column-grouping/createGroupedRowModel.test.ts index 7db86ad9c4..33305118e7 100644 --- a/packages/table-core/tests/implementation/features/column-grouping/createGroupedRowModel.test.ts +++ b/packages/table-core/tests/implementation/features/column-grouping/createGroupedRowModel.test.ts @@ -51,9 +51,16 @@ describe('createGroupedRowModel flatRows contain every row exactly once', () => { status: 'b', firstName: 'five' }, ] const table = makeTable(data, ['status']) - const rowModel = table.getGroupedRowModel() + const rowModel = table.getRowModel() expect(rowModel.rows.length).toBe(2) + expect(rowModel.rows.map((row) => row.getDisplayIndex())).toEqual([0, 1]) + + table.setGrouping([]) + + expect( + table.getRowModel().rows.map((row) => row.getDisplayIndex()), + ).toEqual([0, 1, 2, 3, 4]) // 2 group rows + 5 leaf rows, each exactly once expect(rowModel.flatRows.length).toBe(7) expectUniqueFlatRowIds(rowModel) diff --git a/packages/table-core/tests/implementation/features/row-expanding/rowExpandingFeature.test.ts b/packages/table-core/tests/implementation/features/row-expanding/rowExpandingFeature.test.ts index aef9b7a5a7..d07217d1fe 100644 --- a/packages/table-core/tests/implementation/features/row-expanding/rowExpandingFeature.test.ts +++ b/packages/table-core/tests/implementation/features/row-expanding/rowExpandingFeature.test.ts @@ -54,14 +54,55 @@ function createTable(options?: { paginateExpandedRows?: boolean }) { } describe('row expanding feature', () => { + it('assigns display indexes in expanded row order before pagination', () => { + const table = createTable({ paginateExpandedRows: true }) + + table.getRow('0').toggleExpanded() + + const rows = table.getPrePaginatedRowModel().rows + expect(rows.map((row) => row.id)).toEqual(['0', '0.0', '1']) + expect(rows.map((row) => row.getDisplayIndex())).toEqual([0, 1, 2]) + + table.getRow('0').toggleExpanded() + + const collapsedRows = table.getPrePaginatedRowModel().rows + expect(collapsedRows.map((row) => row.id)).toEqual(['0', '1']) + expect(collapsedRows.map((row) => row.getDisplayIndex())).toEqual([0, 1]) + }) + it('updates the paginated row model when expanded state changes and expanded rows are not paginated', () => { const table = createTable({ paginateExpandedRows: false }) expect(table.getRowModel().rows.map((row) => row.id)).toEqual(['0']) + expect(table.getRowsInDisplayOrder().map((row) => row.id)).toEqual([ + '0', + '1', + ]) table.getRow('0').toggleExpanded() expect(table.atoms.expanded.get()).toEqual({ 0: true }) expect(table.getRowModel().rows.map((row) => row.id)).toEqual(['0', '0.0']) + expect(table.getRowsInDisplayOrder().map((row) => row.id)).toEqual([ + '0', + '0.0', + '1', + ]) + expect( + table.getRowModel().rows.map((row) => row.getDisplayIndex()), + ).toEqual([0, 1]) + + table.setPageIndex(1) + + expect(table.getRowModel().rows.map((row) => row.id)).toEqual(['1']) + expect(table.getRowModel().rows[0]!.getDisplayIndex()).toBe(2) + + table.getRow('0').toggleExpanded() + + expect(table.getRowsInDisplayOrder().map((row) => row.id)).toEqual([ + '0', + '1', + ]) + expect(table.getRow('0.0').getDisplayIndex()).toBe(-1) }) }) diff --git a/packages/table-core/tests/unit/core/row-models/coreRowModelsFeature.utils.test.ts b/packages/table-core/tests/unit/core/row-models/coreRowModelsFeature.utils.test.ts index d7397ca9b0..d0fb0334bc 100644 --- a/packages/table-core/tests/unit/core/row-models/coreRowModelsFeature.utils.test.ts +++ b/packages/table-core/tests/unit/core/row-models/coreRowModelsFeature.utils.test.ts @@ -37,6 +37,14 @@ describe('row model fallback chains', () => { const table = makeCoreOnlyTable() const coreRowModel = table.getCoreRowModel() + expect(coreRowModel.rows.map((row) => row._displayIndexCache)).toEqual([ + -1, -1, -1, + ]) + expect(table.getRowsInDisplayOrder()).toBe(coreRowModel.rows) + expect(coreRowModel.rows.map((row) => row.getDisplayIndex())).toEqual([ + 0, 1, 2, + ]) + expect(table.getPreFilteredRowModel()).toBe(coreRowModel) expect(table.getFilteredRowModel()).toBe(coreRowModel) expect(table.getPreGroupedRowModel()).toBe(coreRowModel) diff --git a/packages/table-core/tests/unit/core/rows/constructRow.test.ts b/packages/table-core/tests/unit/core/rows/constructRow.test.ts index c102a7c2f4..69bef711aa 100644 --- a/packages/table-core/tests/unit/core/rows/constructRow.test.ts +++ b/packages/table-core/tests/unit/core/rows/constructRow.test.ts @@ -38,6 +38,7 @@ describe('constructRow', () => { expect(row).toHaveProperty('_uniqueValuesCache') expect(row).toHaveProperty('_valuesCache') expect(row).toHaveProperty('depth') + expect(row).toHaveProperty('getDisplayIndex') expect(row).toHaveProperty('id') expect(row).toHaveProperty('index') expect(row).toHaveProperty('original') @@ -55,6 +56,7 @@ describe('constructRow', () => { expect(row.id).toBe(id) expect(row.original).toBe(original) expect(row.index).toBe(rowIndex) + expect(row.getDisplayIndex()).toBe(-1) expect(row.depth).toBe(depth) expect(row.subRows).toBe(subRows) expect(row.parentId).toBe(parentId) diff --git a/packages/table-core/tests/unit/features/row-pagination/rowPaginationFeature.utils.test.ts b/packages/table-core/tests/unit/features/row-pagination/rowPaginationFeature.utils.test.ts index ce84952787..0ac6ceaedf 100644 --- a/packages/table-core/tests/unit/features/row-pagination/rowPaginationFeature.utils.test.ts +++ b/packages/table-core/tests/unit/features/row-pagination/rowPaginationFeature.utils.test.ts @@ -172,6 +172,16 @@ describe('table_setPageIndex', () => { getUpdaterResult(onPaginationChange, getDefaultPaginationState()), ).toEqual({ pageIndex: 99, pageSize: 10 }) }) + + it('keeps pre-pagination display indexes on the current page', () => { + const table = makeTable(DEFAULT_ROW_COUNT, { + initialState: { pagination: { pageIndex: 2, pageSize: 10 } }, + }) + + expect( + table.getRowModel().rows.map((row) => row.getDisplayIndex()), + ).toEqual([20, 21, 22, 23, 24]) + }) }) describe('table_resetPageIndex', () => { diff --git a/packages/table-core/tests/unit/features/row-sorting/createSortedRowModel.test.ts b/packages/table-core/tests/unit/features/row-sorting/createSortedRowModel.test.ts index 8a90d357de..13f01c736a 100644 --- a/packages/table-core/tests/unit/features/row-sorting/createSortedRowModel.test.ts +++ b/packages/table-core/tests/unit/features/row-sorting/createSortedRowModel.test.ts @@ -74,6 +74,39 @@ describe('createSortedRowModel', () => { ).toEqual(['amy', 'alice', 'bob']) }) + it('assigns display indexes in the final sorted order', () => { + const table = makeTable([{ id: 'age', desc: false }]) + + let rows = table.getRowModel().rows + + expect(rows.map((row) => row.original.firstName)).toEqual([ + 'amy', + 'alice', + 'bob', + ]) + expect(rows.map((row) => row.getDisplayIndex())).toEqual([0, 1, 2]) + + table.setSorting([{ id: 'age', desc: true }]) + rows = table.getRowModel().rows + + expect(rows.map((row) => row.original.firstName)).toEqual([ + 'bob', + 'alice', + 'amy', + ]) + expect(rows.map((row) => row.getDisplayIndex())).toEqual([0, 1, 2]) + + table.setSorting([]) + rows = table.getRowModel().rows + + expect(rows.map((row) => row.original.firstName)).toEqual([ + 'amy', + 'bob', + 'alice', + ]) + expect(rows.map((row) => row.getDisplayIndex())).toEqual([0, 1, 2]) + }) + it('keeps branch row identity when sorted subRows are unchanged', () => { const table = makeTable( [{ id: 'age', desc: false }], diff --git a/packages/table-devtools/package.json b/packages/table-devtools/package.json index e4067a131f..42612bd5ab 100644 --- a/packages/table-devtools/package.json +++ b/packages/table-devtools/package.json @@ -1,6 +1,6 @@ { "name": "@tanstack/table-devtools", - "version": "9.0.0-beta.42", + "version": "9.0.0-beta.43", "description": "Devtools for TanStack Table.", "author": "Tanner Linsley", "license": "MIT", diff --git a/packages/table-devtools/skills/devtools/SKILL.md b/packages/table-devtools/skills/devtools/SKILL.md index 79973b4c17..212ee3d81c 100644 --- a/packages/table-devtools/skills/devtools/SKILL.md +++ b/packages/table-devtools/skills/devtools/SKILL.md @@ -5,7 +5,7 @@ description: > metadata: type: core library: '@tanstack/table-devtools' - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#core' sources: diff --git a/packages/vue-table-devtools/package.json b/packages/vue-table-devtools/package.json index 1ee33a8b58..6ff758b8da 100644 --- a/packages/vue-table-devtools/package.json +++ b/packages/vue-table-devtools/package.json @@ -1,6 +1,6 @@ { "name": "@tanstack/vue-table-devtools", - "version": "9.0.0-beta.42", + "version": "9.0.0-beta.43", "description": "Vue devtools for TanStack Table.", "author": "Tanner Linsley", "license": "MIT", diff --git a/packages/vue-table-devtools/skills/devtools/SKILL.md b/packages/vue-table-devtools/skills/devtools/SKILL.md index 5d10a91642..26bb8f5b1b 100644 --- a/packages/vue-table-devtools/skills/devtools/SKILL.md +++ b/packages/vue-table-devtools/skills/devtools/SKILL.md @@ -6,7 +6,7 @@ metadata: type: framework library: '@tanstack/vue-table-devtools' framework: vue - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#core' - '@tanstack/table-devtools#devtools' diff --git a/packages/vue-table/package.json b/packages/vue-table/package.json index e8da2bfffa..123b5d95da 100644 --- a/packages/vue-table/package.json +++ b/packages/vue-table/package.json @@ -1,6 +1,6 @@ { "name": "@tanstack/vue-table", - "version": "9.0.0-beta.42", + "version": "9.0.0-beta.43", "description": "Headless UI for building powerful tables & datagrids for Vue.", "author": "Tanner Linsley", "license": "MIT", diff --git a/packages/vue-table/skills/create-table-hook/SKILL.md b/packages/vue-table/skills/create-table-hook/SKILL.md index 2efdcfe3c8..f899e1fb50 100644 --- a/packages/vue-table/skills/create-table-hook/SKILL.md +++ b/packages/vue-table/skills/create-table-hook/SKILL.md @@ -6,7 +6,7 @@ metadata: type: framework library: '@tanstack/vue-table' framework: vue - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#core' - getting-started diff --git a/packages/vue-table/skills/getting-started/SKILL.md b/packages/vue-table/skills/getting-started/SKILL.md index c8b7b9c890..19c2302aea 100644 --- a/packages/vue-table/skills/getting-started/SKILL.md +++ b/packages/vue-table/skills/getting-started/SKILL.md @@ -6,7 +6,7 @@ metadata: type: framework library: '@tanstack/vue-table' framework: vue - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#core' - '@tanstack/table-core#table-features' diff --git a/packages/vue-table/skills/migrate-v8-to-v9/SKILL.md b/packages/vue-table/skills/migrate-v8-to-v9/SKILL.md index 603db50bc7..80929fab54 100644 --- a/packages/vue-table/skills/migrate-v8-to-v9/SKILL.md +++ b/packages/vue-table/skills/migrate-v8-to-v9/SKILL.md @@ -6,7 +6,7 @@ metadata: type: lifecycle library: '@tanstack/vue-table' framework: vue - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#migrate-v8-to-v9' - getting-started diff --git a/packages/vue-table/skills/table-state/SKILL.md b/packages/vue-table/skills/table-state/SKILL.md index aca966e0a1..b6a105415d 100644 --- a/packages/vue-table/skills/table-state/SKILL.md +++ b/packages/vue-table/skills/table-state/SKILL.md @@ -6,7 +6,7 @@ metadata: type: framework library: '@tanstack/vue-table' framework: vue - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#core' - getting-started diff --git a/packages/vue-table/skills/with-tanstack-query/SKILL.md b/packages/vue-table/skills/with-tanstack-query/SKILL.md index 6ded99269e..831a68c06c 100644 --- a/packages/vue-table/skills/with-tanstack-query/SKILL.md +++ b/packages/vue-table/skills/with-tanstack-query/SKILL.md @@ -6,7 +6,7 @@ metadata: type: composition library: '@tanstack/vue-table' framework: vue - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#client-vs-server' - getting-started diff --git a/packages/vue-table/skills/with-tanstack-virtual/SKILL.md b/packages/vue-table/skills/with-tanstack-virtual/SKILL.md index 735d7721e4..9858513c7e 100644 --- a/packages/vue-table/skills/with-tanstack-virtual/SKILL.md +++ b/packages/vue-table/skills/with-tanstack-virtual/SKILL.md @@ -6,7 +6,7 @@ metadata: type: composition library: '@tanstack/vue-table' framework: vue - library_version: '9.0.0-beta.42' + library_version: '9.0.0-beta.43' requires: - '@tanstack/table-core#core' - getting-started