0
我有一个div,其子元素除了第一个孩子以外都是隐藏的。当儿童显示时,jquery滑动容器高度
我想要一个div容器滑下来,当他的孩子从显示器更改为无显示。
<div class="container">
<div class="block">Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen</div>
<div class="block">Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen</div>
<div class="block">Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen</div> <div class="block">Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen</div>
<div class="block">Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen</div>
<div class="block">Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen</div>
</div>
<button id="see_all">see all</button>
只是检查Here
感谢。我忘了用jquery保存;)。事情是,我不希望每个块滑落。只是容器 – user2587454
好吧,我明白了。我已经用2个选项更新了我的答案。我确信他们中的一个将成为你正在寻找的东西:) – vi5ion
选项2不好,因为文本是动态的。但我不知道我没有想到选项1.谢谢! – user2587454