From f343bab95f21a85fd6b5fc9bdf15fcf5a2168291 Mon Sep 17 00:00:00 2001 From: zhx Date: Wed, 1 Jul 2026 18:14:19 +0800 Subject: [PATCH] fix withdraw history modal tap --- gonghui/withdraw-exchange/index.html | 2 +- gonghui/withdraw-exchange/script.js | 11 ++++++----- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/gonghui/withdraw-exchange/index.html b/gonghui/withdraw-exchange/index.html index ace9edd..5c01538 100644 --- a/gonghui/withdraw-exchange/index.html +++ b/gonghui/withdraw-exchange/index.html @@ -440,6 +440,6 @@ - + diff --git a/gonghui/withdraw-exchange/script.js b/gonghui/withdraw-exchange/script.js index 7f9181b..d20c4ff 100644 --- a/gonghui/withdraw-exchange/script.js +++ b/gonghui/withdraw-exchange/script.js @@ -881,14 +881,15 @@ var last = 0; function run(event) { var now = Date.now(); - if (now - last < 220) return; - last = now; - if (event && event.type === 'pointerdown') { - event.preventDefault(); + if (now - last < 220) { + if (event) event.preventDefault(); + return; } + last = now; + // 只能在 click 阶段变更弹窗状态:WebView 里 pointerdown 先打开遮罩后,同一次触摸生成的 click 会落到新遮罩上,导致详情弹窗刚打开又被关闭。 + if (event) event.preventDefault(); handler(event); } - node.addEventListener('pointerdown', run); node.addEventListener('click', run); }