weex在router里的页面中使用fixed全屏然后嵌套使用用absolute铺满,Android端右边下边出现白条;

weex在router里的页面中使用fixed全屏然后嵌套使用用absolute铺满,Android端右边下边出现白条;
pickerareacut1.png

<template>
    <div class="wrapper">
       <div class="cover"></div>
       <div class="wrapper-cont">
           <text>遮罩层</text>
       </div>
    </div>
</template>
<style scoped>
    .wrapper{
      position: fixed;
      top: 0;
      left: 0;
      bottom: 0;
      right: 0;
      z-index: 3;
    }
    .cover{
        position: absolute;
        top: 0;
        right: 0;
        bottom: 0;
        left: 0;
        background-color: #111;
        opacity: .5;
    }

</style>
# 在这里通过路由进入上面的页面
<template>
    <div>
       <router-view></router-view> 
    </div>
</template>

路由页面中.wrapper使用fixed全屏,然后在.wrapper里面的div.cover用absolute,left:0;right:0;top:0;bottom:0;就会右边下边有白条,不能占满;


在web端iOS端正常,Android出现右边,下边有白条;有点像遮罩层像左上方整体偏移了一段
另外测试,不在router-view下引用.vue页面,.cover的写法就在三端都是全覆盖的,有遇到这个问题的大神没有?

阅读 4.3k
1 个回答

试试换成 top: 0; left: 0; width: 750; height: 1334;

撰写回答
你尚未登录,登录后可以
  • 和开发者交流问题的细节
  • 关注并接收问题和回答的更新提醒
  • 参与内容的编辑和改进,让解决方法与时俱进
推荐问题