map组件和cover-view在我控制他们的高时在开发者工具上没问题,但是在手机上没效果
<!–component/phase/index.wxml–>
<map bindtap=‘contentShowTap’ class=‘map {{isShowContent?“show_map”:“hide_map”}}’></map>
<!-- <view bindtap=‘contentShowTap’ bindtouchstart=‘contentShowStart’ bindtouchmove=“contentShowMove” bindtouchend=‘contentShowEnd’ class=‘content {{isShowContent?“show_content”:“hide_content”}}’>
<view style=‘height:100rpx’>1</view>
<view style=‘height:100rpx’>1</view>
<view style=‘height:100rpx’>1</view>
<view style=‘height:100rpx’>1</view>
</view> -->
wxml
<cover-view bindtap=‘contentShowTap’ bindtouchstart=‘contentShowStart’ bindtouchmove=“contentShowMove” bindtouchend=‘contentShowEnd’ class=‘content {{isShowContent?“show_content”:“hide_content”}}’>
<cover-view style=‘height:100rpx’>1</cover-view>
<cover-view style=‘height:100rpx’>1</cover-view>
<cover-view style=‘height:100rpx’>1</cover-view>
<cover-view style=‘height:100rpx’>1</cover-view>
</cover-view>
js
data: {
isShowContent:false,
isMove:false,
},
contentShowTap(){
console.log(1)
this.setData({
isShowContent: !this.data.isShowContent
})
},
contentShowStart(){
console.log(“点击开始”)
},
contentShowMove(){
this.setData({
isMove:true
})
},
contentShowEnd(){
if (this.data.isMove){
this.setData({
isShowContent: !this.data.isShowContent
})
}
}
wxss
.map{
transition: all .7s;
width: 100%;
}
.hide_map{
height: 73.3vh;
}
.show_map{
height: calc(73.3vh - (754rpx - 26.7vh));
}
.content{
position: fixed;
bottom: 0;
left: 0;
width: 100%;
background: white;
transition: all .7s;
overflow: hidden;
}
.hide_content{
height: 26.7vh;
}
.show_content{
height: 754rpx;
}
框架中提到map组件的限制
但是没说过度不可以
cover-view
组件中提到
没说过度不可以
请问我应该怎么去写这个过度