我在我的应用程序中使用了 ion-slide-box。有时幻灯片内容的高度没有填满整个内容。这意味着我在幻灯片底部有一个空白区域。在这种情况下,用户也应该能够在滑动底部的空白区域时进行滑动。但是,这不起作用,因为 ionic 载玻片的大小不是 100%。 我也无法将大小设置为 100%。我已经尝试过以下方法:
.slider{
height:100%;
}
.slider-slide {
height: 100%;
min-height:100%;
}
使用上面的代码幻灯片内容仍然不是 100%。感谢您的帮助。 这是幻灯片框的 html:
<ion-content>
<ion-slide-box class="slider" on-slide-changed="slideChanged($index, this)" show-pager="false" active-slide="1" ng-init="handleSlideEnabling()" does-continue="true">
<ion-slide class="slider-slides" ng-repeat="question in questions">
<div class="slider-slide">
... some content
</div>
</ion-slide>
</ion-slide-box>
</ion-content>
最佳答案
.slider{
height:100vh;
width:auto;
}
.slider-slide {
height: 100vh;
width: auto;
}
关于css - ionic 滑动盒中的 100% 高度不起作用,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/35266798/