fix: 移除所有弹框遮罩层点击关闭 — 防止输入时误触关闭

涉及文件 (12处):
- InstancePage.tsx: 添加数据源弹框
- UsersPage.tsx: 新建/编辑/重置密码/详情弹框 (4处)
- RolesPage.tsx: 克隆角色弹框
- InstanceGroupPage.tsx: 新建/编辑/关联实例/关联用户弹框 (4处)
- SlowQueryPage.tsx: 查询对比弹框
- RedisDetailPage.tsx: 键详情/新增键弹框 (2处)

改动: 遮罩层div移除onClick,只能通过X按钮或取消按钮关闭
This commit is contained in:
logan committed 2026-05-23 23:38:58 +08:00
1 parent 47f077c97f
commit 9f56e866f2
6 files changed
+13 -13

No files matched your search

+1 -1
View File
@@ -553,7 +553,7 @@ function CloneRoleModal({ sourceRole, onClose }: { sourceRole: Role; onClose: ()
};
return (
<div className="fixed inset-0 z-50 flex items-center justify-center bg-black/50" onClick={onClose}>
<div className="fixed inset-0 z-50 flex items-center justify-center bg-black/50">
<div className="w-full max-w-md bg-[var(--dg-bg-secondary)] border border-[var(--dg-border)] rounded-xl p-6 shadow-xl" onClick={e => e.stopPropagation()}>
<div className="flex items-center justify-between mb-5">
<h2 className="text-lg font-semibold flex items-center gap-2"><Copy className="w-5 h-5 text-blue-400" /> 克隆角色</h2>