From e7fee94860d940f44dde87bdca565ec492c89a5c Mon Sep 17 00:00:00 2001 From: lareinayanyu Date: Tue, 17 Dec 2024 11:43:05 +0800 Subject: [PATCH] fix: lint --- .../lib/runtime/components/web/event.js | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/packages/webpack-plugin/lib/runtime/components/web/event.js b/packages/webpack-plugin/lib/runtime/components/web/event.js index 05ad69cb1..61413e7d8 100644 --- a/packages/webpack-plugin/lib/runtime/components/web/event.js +++ b/packages/webpack-plugin/lib/runtime/components/web/event.js @@ -72,14 +72,14 @@ function MpxEvent (layer) { dataset: parseDataset(event.target.dataset) }) extendEvent(touchEvent, { - timeStamp: event.timeStamp, - changedTouches, - touches: changedTouches, - detail: { - // pc端点击事件可能没有changedTouches,所以直接从 event 中取 - x: changedTouches[0]?.pageX || event.pageX || 0, - y: changedTouches[0]?.pageY || event.pageY || 0 - } + timeStamp: event.timeStamp, + changedTouches, + touches: changedTouches, + detail: { + // pc端点击事件可能没有changedTouches,所以直接从 event 中取 + x: changedTouches[0]?.pageX || event.pageX || 0, + y: changedTouches[0]?.pageY || event.pageY || 0 + } }) targetElement && targetElement.dispatchEvent(touchEvent) }