@dolphinweex/weex-vue-render 0.2.43 → 0.2.44
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.common.js +11 -5
- package/package.json +1 -1
package/dist/index.common.js
CHANGED
|
@@ -1547,7 +1547,7 @@ function calc(x1, y1, x2, y2, x3, y3, x4, y4) {
|
|
|
1547
1547
|
* @event
|
|
1548
1548
|
* @param {event} event
|
|
1549
1549
|
*/
|
|
1550
|
-
function touchstartHandler(event) {
|
|
1550
|
+
const touchstartHandler = throttle(function touchstartHandler(event) {
|
|
1551
1551
|
|
|
1552
1552
|
if (Object.keys(gestures).length === 0) {
|
|
1553
1553
|
docEl.addEventListener('touchmove', touchmoveHandler, true);
|
|
@@ -1603,7 +1603,7 @@ function touchstartHandler(event) {
|
|
|
1603
1603
|
touchEvent: event
|
|
1604
1604
|
});
|
|
1605
1605
|
}
|
|
1606
|
-
}
|
|
1606
|
+
},300,true)
|
|
1607
1607
|
|
|
1608
1608
|
/**
|
|
1609
1609
|
* take over touchmove events, and handle pan and dual related gestures.
|
|
@@ -3373,8 +3373,8 @@ function watchAppear (context, fireNow) {
|
|
|
3373
3373
|
* 此处延时执行是临时规避措施,后续需要优化
|
|
3374
3374
|
*/
|
|
3375
3375
|
if (i == 0) {
|
|
3376
|
-
|
|
3377
|
-
|
|
3376
|
+
setTimeout(() => {
|
|
3377
|
+
detectAppear(el, visibleData, dir);
|
|
3378
3378
|
}, 1);
|
|
3379
3379
|
} else {
|
|
3380
3380
|
detectAppear(el, visibleData, dir);
|
|
@@ -7180,6 +7180,9 @@ function getRefresh (weex) {
|
|
|
7180
7180
|
},
|
|
7181
7181
|
methods: {
|
|
7182
7182
|
pulling: function pulling (offsetY) {
|
|
7183
|
+
if(weex.sliderHorizontalScrolling){//轮播图滚动中不允许触发
|
|
7184
|
+
return
|
|
7185
|
+
}
|
|
7183
7186
|
if ( offsetY === void 0 ) offsetY = 0;
|
|
7184
7187
|
|
|
7185
7188
|
this.height = offsetY;
|
|
@@ -8328,6 +8331,7 @@ var slideMixin = {
|
|
|
8328
8331
|
isV = tp.isVertical = Math.abs(offsetX) < Math.abs(offsetY);
|
|
8329
8332
|
if (!isV) {
|
|
8330
8333
|
this._emitScrollEvent('scrollstart');
|
|
8334
|
+
weex.sliderHorizontalScrolling = true;
|
|
8331
8335
|
}
|
|
8332
8336
|
}
|
|
8333
8337
|
// vertical scroll. just ignore it.
|
|
@@ -8410,6 +8414,7 @@ var slideMixin = {
|
|
|
8410
8414
|
},
|
|
8411
8415
|
|
|
8412
8416
|
_handleTouchEnd: function _handleTouchEnd (event) {
|
|
8417
|
+
weex.sliderHorizontalScrolling = false;
|
|
8413
8418
|
var inner = this.$refs.inner;
|
|
8414
8419
|
if (touchSliderInstance == inner) {
|
|
8415
8420
|
touchSliderInstance= null;
|
|
@@ -8433,12 +8438,13 @@ var slideMixin = {
|
|
|
8433
8438
|
var reset = Math.abs(offsetX / this._wrapperWidth) < 0.2;
|
|
8434
8439
|
var direction = offsetX > 0 ? 1 : -1;
|
|
8435
8440
|
var newIndex = reset ? this.currentIndex : (this.currentIndex - direction);
|
|
8436
|
-
this._slideTo(newIndex, true
|
|
8441
|
+
this._slideTo(newIndex, true);
|
|
8437
8442
|
}
|
|
8438
8443
|
delete this._touchParams;
|
|
8439
8444
|
},
|
|
8440
8445
|
|
|
8441
8446
|
_handleTouchCancel: function _handleTouchCancel (event) {
|
|
8447
|
+
weex.sliderHorizontalScrolling = false;
|
|
8442
8448
|
var inner = this.$refs.inner;
|
|
8443
8449
|
if (touchSliderInstance == inner) {
|
|
8444
8450
|
touchSliderInstance= null;
|
package/package.json
CHANGED