visibleInShowHideMenu: false has no effect on "Show all columns"
mantine-react-table version
2.0.0-beta.6
react & react-dom versions
18.2.0
Describe the bug and the steps to reproduce it
- Disable a column from the show/hide menu via
visibleInShowHideMenu: false. - Set the column to default hidden with
columnVisibilityininitialState. (not necessar but easier to reproduce with this step) - Click "Show all columns"
All columns appear, including the one that is not visible in the show/hide menu.
I would expect the disabled column (in the stackblitz example below, I chose name.firstName) to remain hidden, as the user cannot turn it back off, except by clicking "hide all".
As a background to why I am using this option, I want to sort the table by creation date but not show creation date to the user. If I disable sorting for creation date, the table can't be sorted by that column, so I have the column always hidden in the background, with no ability to show it. This works perfectly, until you click "show all".
Minimal, Reproducible Example - (Optional, but Recommended)
https://stackblitz.com/edit/github-rat1cb?file=src%2FTS.tsx
Screenshots or Videos (Optional)
Do you intend to try to help solve this bug with your own PR?
No, because I do not have time to dig into it
Terms
- [X] I understand that if my bug cannot be reliably reproduced in a debuggable environment, it will probably not be fixed and this issue may even be closed.