1.模板代码:
<mt-popup v-model="signReasonVisible" position="bottom" style="width:100%;height:43%;" class="popup">
<mt-picker :slots="slots" @change="setSignReason" style="" :itemHeight="itemHeight" class="picker"></mt-picker>
</mt-popup>
样式代码:
/*--------选择器样式-----------*/
.picker-items{
height:100%;
}
.picker-item{
font-size:1.38rem;
}
.picker-slot-center{
height:100%;
}
.picker-slot-wrapper{
}
.picker-center-highlight{
background-color: #F5F5F9;
z-index:-100;
}
2.样式效果:

本文介绍了一种移动端弹出选择器的实现方式,通过使用模板代码结合特定样式,实现了高度自定义的选择器组件。该选择器支持底部弹出,并且可以调整宽度、高度等属性,同时提供了字体大小和高亮背景色的自定义设置。
2723

被折叠的 条评论
为什么被折叠?



