- 描述
苹果手机会出现Bug,安卓手机测试正常
.json配置文件中navigationStyle设置为custom,当页面中视频组件全屏(横屏)时,导航栏不会隐藏,遮挡住视频(如下图)
- 当前 Bug 截图
- 自定义导航代码片段
<div class="comp-navbar">
<!-- 占位栏 -->
<cover-view class="placeholder-bar" :style="{height: navBarHeight + 'px'}"> </cover-view>
<!-- 导航栏主体 -->
<cover-view class="navbar" :style="{height: navBarHeight + 'px',backgroundColor:navBackgroundColor}">
<!-- 状态栏 -->
<cover-view class="nav-statusbar" :style="{height: statusBarHeight + 'px'}"></cover-view>
<!-- 标题栏 -->
<cover-view class="nav-titlebar" :style="{height: titleBarHeight + 'px' }">
<!-- home及后退键 -->
<cover-view class="bar-options">
<cover-view v-if="backVisible" class="opt opt-back" @click="backClick()">
<cover-image class="back-image" src="/static/images/back.png"></cover-image>
</cover-view>
<cover-view class="line" v-if="backVisible"></cover-view>
<cover-view class="opt opt-home" @click="homeClick()">
<cover-image class="home-image" src="/static/images/home.png"></cover-image>
</cover-view>
</cover-view>
<!-- 标题 -->
<cover-view class="bar-title" :style="[{color:titleColor}]">{{title}}</cover-view>
</cover-view>
</cover-view>
</div>
因为层级比video高,监听下手机尺寸变化,然后动态显示/隐藏顶部。
感谢回复的这么及时,请问监听手机尺寸变化要怎么实现?或者说视频横屏(全屏)播放时,哪个尺寸变化了?
楼上正解~