table
table copied to clipboard
when i useing thead Grouping. only set subHeader enableColumnFilter work, parent Column didn't work
TanStack Table version
v8.16.0
Framework/Library version
v18.2.0
Describe the bug and the steps to reproduce it
- go to the grouping example (https://tanstack.com/table/latest/docs/framework/react/examples/grouping)
- set {enableColumnFilter: true} for parentColumn and subParent
- wirte the debug code for or console.log(header.column.getCanFilter())
- that result was false
Your Minimal, Reproducible Example - (Sandbox Highly Recommended)
https://codesandbox.io/p/sandbox/modest-lederberg-lzppdp
Screenshots or Videos (Optional)
Do you intend to try to help solve this bug with your own PR?
None
Terms & Code of Conduct
- [X] I agree to follow this project's Code of Conduct
- [X] I understand that if my bug cannot be reliable reproduced in a debuggable environment, it will probably not be fixed and this issue may even be closed.
how can i resolve this problem. Is it fixed in latest version?
@KevinVandy please have a look, it confused me, help!
You can only filter from a leaf column
You can only filter from a leaf column
Is it a column doesn't have subColumn call Leaf Column.
i didn't define any sub columns, but it not work either
this is Reproducible expample url: https://codesandbox.io/p/sandbox/modest-lederberg-lzppdp @KevinVandy
TanStack Table itself doesn't let you sort, filter, group by, etc. from the header groups (parent group columns) because what values would it be performing those actions on? You can ignore the default logic from TanStack Table and shove in your own UI anyway though.
Your sandbox is not public