泰到位
泰到位
  • 发布:2024-02-20 14:58
  • 更新:2024-02-20 15:25
  • 阅读:216

【报Bug】filter: grayscale(1)页面置灰时uni-popup的定位bug

分类:uni-app

产品分类: uniapp/App

PC开发环境操作系统: Windows

PC开发环境操作系统版本号: 22H2

HBuilderX类型: 正式

HBuilderX版本号: 3.99

手机系统: Android

手机系统版本号: Android 12

手机厂商: 华为

手机机型: nova 10z

页面类型: vue

vue版本: vue2

打包方式: 云端

项目创建方式: HBuilderX

操作步骤:

使用filter: grayscale(1);置灰页面,并且页面列表长度超过页面时,使用uni-popup

预期结果:

使用filter: grayscale(1);置灰页面,并且页面列表长度超过页面时,uni-popup会定位到页面最低端

实际结果:

使用filter: grayscale(1);置灰页面,并且页面列表长度超过页面时,uni-popup会定位到列表最低端

bug描述:

使用filter: grayscale(1);置灰页面,并且页面列表长度超过页面时,uni-popup的定位出现问题,uni-popup会定位到列表最低端,而不是页面最低端

2024-02-20 14:58 负责人:无 分享
已邀请:
s***@qq.com

s***@qq.com

css filter 与 fixed 有冲突,自己想办法解决吧。

喜欢技术的前端

喜欢技术的前端 - QQ---445849201

层级分开就行

<template>  
    <view class="">  
        <view class="body">  
            <image src="/static/logo.png" mode=""></image>  
            <button @click="showPop">show</button>  
            <view class="view" v-for="(item,index) in 20" :key="index">  
                vview{{item}}  
            </view>  
        </view>  
        <uni-popup ref="popup">  
            <view class="popup-content">  
                <image src="/static/logo.png" mode=""></image>  
                <view class="text">popup 内容</view>  
            </view>  
        </uni-popup>  
    </view>  
</template>  

<script>  
    export default {  
        data() {  
            return {}  
        },  

        methods: {  
            showPop() {  
                this.$refs.popup.open()  
            }  
        }  
    }  
</script>  

<style>  
    .view {  
        text-align: center;  
        padding: 20rpx;  
    }  

    .body {  
        filter: grayscale(1);  
    }  

    .popup-content {  
        background-color: #fff;  
        filter: grayscale(1);  
    }  
</style>

要回复问题请先登录注册