我有一个外部div和三个内部div,每个div都是单独查看的,当查看每个div时,我希望外部div的高度相应地增大或缩小。
我希望每个div中都有表格会动态扩展,这意味着它们不会都是相同的大小,我希望外部div与内部div的大小相匹配,提前感谢
HTML
<div id="scroll-view">
<div id="scroll-items">
<div class="view"></div>
<div class="view"></div>
<div class="view"></div>
</div>
</div>
<button id="previous">Previous</button>
<button id="next">Next</button>
CSS
.view { width: 300px; height: 300px; float:left; }
#scroll-view {
width: 300px;
height: 50px;
overflow:hidden;
position:relative;
}
#scroll-items { width: 10000px; max-height: auto; overflow:auto; position: absolute ; }