[improvement] Picker: stop propagation when touchmove in vertical direction (#4043)

This commit is contained in:
neverland
2019-08-03 21:28:26 +08:00
committed by GitHub
parent 77ff2bad0e
commit 24b3a05c76
+5 -1
View File
@@ -98,9 +98,13 @@ export default createComponent({
},
onTouchMove(event) {
preventDefault(event);
this.moving = true;
this.touchMove(event);
if (this.direction === 'vertical') {
preventDefault(event, true);
}
this.offset = range(
this.startOffset + this.deltaY,
-(this.count * this.itemHeight),