1***@qq.com
1***@qq.com
  • 发布:2021-07-19 18:17
  • 更新:2022-07-09 09:22
  • 阅读:502

【报Bug】【报Bug】安卓端nvue页面使用waterfall,两列布局时排列变成从右到左

分类:uni-app

产品分类: uniapp/App

PC开发环境操作系统: Windows

PC开发环境操作系统版本号: win10 64

HBuilderX类型: 正式

HBuilderX版本号: 3.1.22

手机系统: Android

手机系统版本号: Android 10

手机厂商: 小米

手机机型: 小米9

页面类型: vue

打包方式: 云端

项目创建方式: HBuilderX

示例代码:

<template>
<view class="content">
<waterfall class="listview" :column-gap="11" :left-gap="16" :right-gap="16" :show-scrollbar="false" column-count="2" :enableBackToTop="true" :scroll-y="true">
<header>
<view class="n-search" >
<view class="search-wrapper" >
<view class="search-inner">
<text class="n-placeholder" >大家都在搜#啦啦啦啦#</text>
</view>
</view>

            </view>  
        </header>  
        <refresh></refresh>  
        <cell class="cell" v-for="(item, index) in lists" >  
          <text class="cell-text">{{index}}</text>  
        </cell>  
      </waterfall>  
</view>  

</template>

<script>
export default {
data() {
return {
lists: 30
}
},
onLoad() {

    },  
    methods: {  

    }  
}  

</script>

<style>
.content{
flex: 1;
flex-direction: column;
position: absolute;
left: 0;
top: 0;
right: 0;
bottom: 0;
}
.listview {
position: absolute;
left: 0;
top: 0;
right: 0;
bottom: 0;
/ #ifndef APP-NVUE /
display: flex;
flex-direction: column;
/ #endif /
/ #ifndef MP-ALIPAY /
flex-direction: column;
/ #endif /
justify-content: space-between;
}
.cell{
width: 332rpx;
height: 100rpx;
/ #ifndef APP-NVUE /
display: flex;
/ #endif /
align-items: center;
justify-content: center;
border: 1px solid #000;
}
.cell-text{
font-size: 20px;

}  

.n-search{  
    padding: 0 32rpx;  
    background-color: #F8F8F8;  
}  
.mode2{  
    padding: 0;  
}  
.search-inner{  
    /* #ifndef APP-NVUE */  
    display: flex;  
    /* #endif */  
    flex-direction: row;  
    align-items: center;  
    border-radius: 16rpx;  
    height: 72rpx;  
    padding: 0 20rpx;  
    background-color: #fff;  
}  
.n-placeholder{  
    color: #C7C7C7;  
    font-size: 28rpx;  
    line-height: 72rpx;  
    margin-left: 8rpx;  
}  

</style>

操作步骤:

见示例代码

预期结果:

从左到右排列

实际结果:

见示例代码

bug描述:

nvue 使用waterfall 两列布局时如果列表前有 header 和refresh组件,排列就变成从右到左了

2021-07-19 18:17 负责人:无 分享
已邀请:
DCMarvel

DCMarvel

这个 waterfall 布局问题是BUG吗 如何解决 Android 的cell默认 从右开始计算的

要回复问题请先登录注册