Fixed width is not applying for fix width column along with Full width table, Column Resizing and Column visibility.
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 28.4k
- Forks
- 3.6k
- Avg merge
- 1d 14h
- Merged PRs (30d)
- 10
Description
Describe the bug
I have a scenario where I have to toggle the column visibility and according to it the width should be scale for non fixed width columns, But currently the fixed width column are also getting scaled to fill the space for full width table.
I am attaching the sandbox environment where I have repro the issue.
Your minimal, reproducible example
https://codesandbox.io/s/inspiring-resonance-zq6c89?file=/src/App.tsx
Steps to reproduce
- Hide/Toggle as many as columns to check the issue. Check with 2/3 columns to show along with selection column to view.
Expected behavior
The fixed width column like selection and row action column should not be scale when other column visibility are toggled.
How often does this bug happen?
Every time
Screenshots or Videos
https://github.com/TanStack/table/assets/127275956/f0b29606-e625-44bb-a093-96b13aa8a63a
Platform
- OS: MacOs
- Browser: Chrome (Version 117.0.5938.132)
react-table version
8.8.5
TypeScript version
4.4.2
Additional context
Use Tailwind classes also to have full width as per provided example with tailwind version 3.2.7
Terms & Code of Conduct
- I agree to follow this project's Code of Conduct
- 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.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the linked CodeSandbox's src/App.tsx and reproduce the issue by hiding two or three columns while keeping the selection column visible. Trace how full-width sizing, column visibility, resizing, and fixed-width columns interact; done means selection and row-action columns retain their widths while only non-fixed columns scale.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- react, tailwindcss, typescript
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100