From 37aaec1e42b8638f7d5c2994fc88834b50b3c61b Mon Sep 17 00:00:00 2001 From: Zhukj <3262118957> Date: Sat, 25 Apr 2026 15:43:02 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E9=98=BB=E6=AD=A2=E8=BE=93=E5=85=A5?= =?UTF-8?q?=E6=A1=86=E7=BC=96=E8=BE=91=E6=97=B6=E7=9A=84=E4=BA=8B=E4=BB=B6?= =?UTF-8?q?=E5=86=92=E6=B3=A1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 避免在编辑输入框时触发容器的点击事件 --- js/script.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/js/script.js b/js/script.js index f2fd6ae..bca179c 100644 --- a/js/script.js +++ b/js/script.js @@ -1669,8 +1669,10 @@ // 如果已经在编辑中,不重复进入 if (editingInput === element) return; - // 选中并立即进入编辑模式 - selectInput(element); + // 阻止事件冒泡,避免触发容器点击 + e.stopPropagation(); + + // 进入编辑模式(selectInput 已在 mousedown 中调用) startEdit(element); }); }