Add files via upload

This commit is contained in:
公明
2026-04-30 10:43:23 +08:00
committed by GitHub
parent 6a2a445f32
commit 0de69a6345
2 changed files with 13 additions and 5 deletions
+1 -1
View File
@@ -730,7 +730,7 @@ function renderRecommendedActions(state) {
if (state.openCriticalCount > 0) {
actions.push({
level: 'urgent',
icon: '<svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><path d="M10.29 3.86L1.82 18a2 2 0 0 0 1.71 3h16.94a2 2 0 0 0 1.71-3L13.71 3.86a2 2 0 0 0-3.42 0z"/><line x1="12" y1="9" x2="12" y2="13"/><line x1="12" y1="17" x2="12.01" y2="17"/></svg>',
icon: '<svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M10.29 3.86L1.82 18a2 2 0 0 0 1.71 3h16.94a2 2 0 0 0 1.71-3L13.71 3.86a2 2 0 0 0-3.42 0z"/><line x1="12" y1="9" x2="12" y2="13"/><circle cx="12" cy="17" r="1" fill="currentColor" stroke="none"/></svg>',
title: dt('dashboard.recoFixCritical', { count: state.openCriticalCount },
'修复 ' + state.openCriticalCount + ' 个待处理严重漏洞'),
desc: dt('dashboard.recoFixCriticalDesc', null, '严重等级的漏洞应优先处置'),
+12 -4
View File
@@ -287,10 +287,18 @@
closeDropdown();
return;
}
dropdown.style.display = 'block';
bellBtn.classList.add('active');
state.dropdownOpen = true;
await refreshNotifications();
// 从仪表盘「查看全部」等容器外入口打开时,同一 click 会冒泡到 document
// handleDocumentClick 会误判为「点在外面」并立刻关掉。推迟到宏任务再展开即可。
const runOpen = async function () {
if (dropdown.style.display !== 'none') return;
dropdown.style.display = 'block';
bellBtn.classList.add('active');
state.dropdownOpen = true;
await refreshNotifications();
};
window.setTimeout(function () {
void runOpen();
}, 0);
}
async function markAllSeen() {