@tanstack/table-core 8.13.0 → 8.13.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/lib/features/Visibility.js +3 -2
- package/build/lib/features/Visibility.js.map +1 -1
- package/build/lib/index.esm.js +3 -2
- package/build/lib/index.esm.js.map +1 -1
- package/build/lib/index.mjs +3 -2
- package/build/lib/index.mjs.map +1 -1
- package/build/lib/utils.d.ts +1 -1
- package/build/lib/utils.js.map +1 -1
- package/build/umd/index.development.js +3 -2
- package/build/umd/index.development.js.map +1 -1
- package/build/umd/index.production.js +1 -1
- package/build/umd/index.production.js.map +1 -1
- package/package.json +1 -1
- package/src/features/Visibility.ts +6 -1
- package/src/utils.ts +9 -11
package/package.json
CHANGED
|
@@ -178,7 +178,12 @@ export const Visibility: TableFeature = {
|
|
|
178
178
|
}
|
|
179
179
|
}
|
|
180
180
|
column.getIsVisible = () => {
|
|
181
|
-
|
|
181
|
+
const childColumns = column.columns
|
|
182
|
+
return (
|
|
183
|
+
(childColumns.length
|
|
184
|
+
? childColumns.some(c => c.getIsVisible())
|
|
185
|
+
: table.getState().columnVisibility?.[column.id]) ?? true
|
|
186
|
+
)
|
|
182
187
|
}
|
|
183
188
|
|
|
184
189
|
column.getCanHide = () => {
|
package/src/utils.ts
CHANGED
|
@@ -47,17 +47,15 @@ export type DeepKeys<T, TDepth extends any[] = []> = TDepth['length'] extends 5
|
|
|
47
47
|
? never
|
|
48
48
|
: unknown extends T
|
|
49
49
|
? string
|
|
50
|
-
:
|
|
51
|
-
?
|
|
52
|
-
: T extends
|
|
53
|
-
?
|
|
54
|
-
: T extends
|
|
55
|
-
?
|
|
56
|
-
: T extends
|
|
57
|
-
?
|
|
58
|
-
:
|
|
59
|
-
? (keyof T & string) | DeepKeysPrefix<T, keyof T, TDepth>
|
|
60
|
-
: never
|
|
50
|
+
: T extends readonly any[] & IsTuple<T>
|
|
51
|
+
? AllowedIndexes<T> | DeepKeysPrefix<T, AllowedIndexes<T>, TDepth>
|
|
52
|
+
: T extends any[]
|
|
53
|
+
? DeepKeys<T[number], [...TDepth, any]>
|
|
54
|
+
: T extends Date
|
|
55
|
+
? never
|
|
56
|
+
: T extends object
|
|
57
|
+
? (keyof T & string) | DeepKeysPrefix<T, keyof T, TDepth>
|
|
58
|
+
: never
|
|
61
59
|
|
|
62
60
|
type DeepKeysPrefix<
|
|
63
61
|
T,
|