mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-05-22 06:31:45 +08:00
fix(SwipeCell): avoid Vue 2.6 event bubble issues (#5348)
This commit is contained in:
parent
6a20400699
commit
e037082feb
@ -48,6 +48,10 @@ export default createComponent({
|
||||
}
|
||||
},
|
||||
|
||||
mounted() {
|
||||
this.bindTouchEvent(this.$el);
|
||||
},
|
||||
|
||||
methods: {
|
||||
getWidthByRef(ref) {
|
||||
if (this.$refs[ref]) {
|
||||
@ -227,14 +231,7 @@ export default createComponent({
|
||||
};
|
||||
|
||||
return (
|
||||
<div
|
||||
class={bem()}
|
||||
onClick={this.getClickHandler('cell')}
|
||||
onTouchstart={this.onTouchStart}
|
||||
onTouchmove={this.onTouchMove}
|
||||
onTouchend={this.onTouchEnd}
|
||||
onTouchcancel={this.onTouchEnd}
|
||||
>
|
||||
<div class={bem()} onClick={this.getClickHandler('cell')}>
|
||||
<div class={bem('wrapper')} style={wrapperStyle}>
|
||||
{this.genLeftPart()}
|
||||
{this.slots()}
|
||||
|
Loading…
x
Reference in New Issue
Block a user