cover-view的opacity动画兼容
发布于 5 年前 作者 xiulantan 8214 次浏览 来自 问答

iphoneX不支持cover-view的opacity动画,我在其他机型,基本表现良好,测试的有华为荣耀9、苹果8,、苹果7s,,目前就发现iPhone X不兼容该动画。导致我顶部一个空白蓝色条,非常的奇怪

<map class="map">
< cover-view class = "real-explaining-box {{top.realtimeExplainTxt? 'active' : ''}}" >
      {{top.realtimeExplainTxt}}
    </ cover-view >
</map>
.real-explaining-box {
   position : fixed ;
   top : 100 rpx;
   width : 100% ;
   height : 48 rpx;
   line-height : 48 rpx;
   font-size : 24 rpx;
   color : #fff ;
   background : rgba( 0 , 122 , 255 , . 43 );
   text-align : center ;
   -webkit-box-sizing: border-box;
   box-sizing: border-box;
   opacity: 0 ;
   -webkit-transition: all . 8 s ease 0 s;
   transition: all . 8 s ease 0 s;
}
.real-explaining-box.active {
   opacity: 1 ;
   /* background: rgba(0, 122, 255, .43); */
}
回到顶部