0

我有一个带有 2 个选项卡窗格的选项卡导航。两个选项卡内容都是动态的,但第一个选项卡内容的行数总是多于第二个选项卡内容。当我单击第二个选项卡窗格时,我不希望第二个选项卡内容折叠。我想让第二个标签的内容高度与第一个相同。我该怎么做?谢谢。

4

2 回答 2

2

You could override the CSS for .tab-pane and set the height attribute if you want all tabs to be the same height:

.tab-pane {
    height: 400px;
}
于 2012-05-04T17:49:06.607 回答
0

按照 Serkan 的建议使用 Jquery 并在一行中做到这一点。唯一的选择器是限制 .tab-pane 选择

$(document).ready(function(){
    // Fix the height of the inner tabs
    $('#unique_selector .tab-pane').css('height', $('#unique_selector .tab-pane').css('height') );
});
于 2013-06-27T10:55:17.180 回答