I have a table with a thead and tbody sections. I have applied a slideToggle on this successfully, but the animation is broken.
When a user clicks on the thead, I wa
It disappears because This is why the natural-height You can kludge around this with But, notice the effect that has when a table height is set. Probably, the best way is to wrap the whole table in a div and Just be sure and fix the table widths the same. See it in action at jsFiddle. normally will get no shorter than the tallest
td
, no matter what you set its height to with CSS.
tbody
just seems to disappear, while the one with artificial extra-height appears to run until the tr
reached its natural height.tbody {display:block;}
. See the kludge at jsFiddle.slideToggle
that, like so:
TABLE HEADING
Cell Contents
Cell Contents
Cell Contents