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 have a table where one of the columns should or should not be visible.
I'm aware of toggleHideColumn().
It happens to be a case where I set a width for that column (i.e. instead of letting the browser do its thing).
Which made me think - I can alternatively hide the column (visually) by setting the width to 0.
The upside is that I can also set something like transition: width 0.2s to make the toggling effect more pleasing (toggleHideColumn is certainly not 😕).
Beside extra a11y work (I'll have to hide the column from AT as well), are there other downsides to this approach?
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
Uh oh!
There was an error while loading. Please reload this page.
-
I have a table where one of the columns should or should not be visible.
I'm aware of
toggleHideColumn()
.It happens to be a case where I set a
width
for that column (i.e. instead of letting the browser do its thing).Which made me think - I can alternatively hide the column (visually) by setting the width to 0.
The upside is that I can also set something like
transition: width 0.2s
to make the toggling effect more pleasing (toggleHideColumn
is certainly not 😕).Beside extra a11y work (I'll have to hide the column from AT as well), are there other downsides to this approach?
Beta Was this translation helpful? Give feedback.
All reactions