How to Use slideDown (or show) function on a table row?

后端 未结 21 2144
清歌不尽
清歌不尽 2020-11-22 09:03

I\'m trying to add a row to a table and have that row slide into view, however the slidedown function seems to be adding a display:block style to the table row which messes

21条回答
  •  遇见更好的自我
    2020-11-22 09:45

    I liked the plugin that Vinny's written and have been using. But in case of tables inside sliding row (tr/td), the rows of nested table are always hidden even after slid up. So I did a quick and simple hack in the plugin not to hide the rows of nested table. Just change the following line

    var $cells = $(this).find('td');
    

    to

    var $cells = $(this).find('> td');
    

    which finds only immediate tds not nested ones. Hope this helps someone using the plugin and have nested tables.

提交回复
热议问题