使用jqTransform插件的Bug

Bug using jqTransform plugin

本文关键字:Bug 插件 jqTransform 使用      更新时间:2023-09-26

我使用jqTransform插件在我的页面的表单项中添加一些样式。选项卡中有三个表单,第二个和第三个选项卡中的选择框不能正常工作。

似乎由于某种原因,脚本对这些选择框列表应用了"height:0"。下面是处理这个动作的代码:

// Calculate the height if necessary, less elements that the default height
//show the ul to calculate the block, if ul is not displayed li height value is 0
$ul.css({display:'block',visibility:'hidden'});
var iSelectHeight = ($('li',$ul).length)*($('li:first',$ul).height());//+1 else bug ff
(iSelectHeight < $ul.height()) && $ul.css({height:iSelectHeight,'overflow':'hidden'});//hidden else bug with ff
$ul.css({display:'none',visibility:'visible'});
我真的不明白为什么会发生这种事。

注释掉这一行

(iSelectHeight < $ul.height()) && $ul.css({height:iSelectHeight,'overflow':'hidden'})