You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am currently working on building a Table component on top of react-table and have been running into an issue with the column sizing.
The column sizing documentation mentions at one point:
So I was assuming that there shouldn't be a problem to base everything in the table off rem values. This has been working pretty well with some adjustments, until working with column resizing. I can't get column resizing to work with rem units, no matter what I try.
I have checked out the column sizing state documentation and have been playing around with the onColumnSizingChange and onColumnSizingInfoChange handlers.
It seems like you can properly adjust the stored column sizes. However, the resizing handler internally uses pixel values which then result in an offset / initial jumping when dragging the resize handle. related table-core code
Is it an unintended missing feature, since using different units is mentioned in the docs?
Should this be possible? / Will this ever be possible?
If this is not possible and will never be, I think it would be nice to have a comment on that in the documentation as well, something like However, using different css units is not supported by the built-in resizing feature.
PS: I love this library and am having a blast using it, keep up that great work! 🔥
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hi! :)
I am currently working on building a Table component on top of react-table and have been running into an issue with the column sizing.
The column sizing documentation mentions at one point:
So I was assuming that there shouldn't be a problem to base everything in the table off
rem
values. This has been working pretty well with some adjustments, until working with column resizing. I can't get column resizing to work withrem
units, no matter what I try.I have checked out the column sizing state documentation and have been playing around with the
onColumnSizingChange
andonColumnSizingInfoChange
handlers.It seems like you can properly adjust the stored column sizes. However, the resizing handler internally uses pixel values which then result in an offset / initial jumping when dragging the resize handle. related table-core code
See this reproduction for what I am trying to achieve.
Now my questions are:
If this is not possible and will never be, I think it would be nice to have a comment on that in the documentation as well, something like
However, using different css units is not supported by the built-in resizing feature
.PS: I love this library and am having a blast using it, keep up that great work! 🔥
Beta Was this translation helpful? Give feedback.
All reactions