首页
归档
笔记
树洞
搜索
友言

文章详情

Interesting People Record Interesting.

/ uniapp / 文章详情

[Intervention] Ignored attempt to cancel a touchmove event with cancelable=false, for example because scrolling is in progress and cannot be interrupted.

Sonder
2021-07-21
436字
1分钟
浏览 (3.4k)

使用uView的dropdown组件时发现拖动列表时报以下错误:

image.png

在网上查阅资料都是说给报错的区域加touch-action: none;,结果还是不行。

解决方法:

给元素加上overflow:hidden

复制代码
 <u-dropdown @open="open" @close="close" :style="dropDownShow ? '' :'overflow:hidden'" :close-on-click-mask="true" ref="uDropdown" activeColor="#6277FD" :borderBottom="false">
 ...
 </u-dropdown>
复制代码
    open(){
      this.dropDownShow = true
    },
    close(){
      this.dropDownShow = false
    },
下一篇 / uniapp获取当前页面路径和参数

🎯 相关文章

💡 推荐文章

🕵️‍♂️ 评论 (0)