1.给父元素限制宽高
2.给Scroll限制高度,并overflow:hidden;
<div class="rank">
<scroll class="top-list">
.top-list{
height: 100%;
width: 100%;
overflow:hidden;
}
.rank{
position: fixed;
width: 100%;
top: 88px;
bottom: 0;
}
1.给父元素限制宽高
2.给Scroll限制高度,并overflow:hidden;
<div class="rank">
<scroll class="top-list">
.top-list{
height: 100%;
width: 100%;
overflow:hidden;
}
.rank{
position: fixed;
width: 100%;
top: 88px;
bottom: 0;
}