From 5c41bf7a590e9c58be698f56a60b4dd7a0e3a464 Mon Sep 17 00:00:00 2001 From: qinglong Date: Sun, 14 Jun 2026 15:01:22 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20row=E6=A8=A1=E5=BC=8F=E6=AF=8F=E6=AC=A1?= =?UTF-8?q?=E9=87=8D=E5=BB=BAHiChart?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- plugins/sentinel/dashboard.html | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/plugins/sentinel/dashboard.html b/plugins/sentinel/dashboard.html index 29e4fd5..7ec3d10 100644 --- a/plugins/sentinel/dashboard.html +++ b/plugins/sentinel/dashboard.html @@ -322,15 +322,7 @@ grid.appendChild(card); _cardCache[id] = card; if (isRow) { - // 销毁旧图表实例 - if (_chartInstances[id]) { - ['cpu','mem','net'].forEach(function(k){ - if (_chartInstances[id][k] && _chartInstances[id][k].canvas) { - var c = _chartInstances[id][k].canvas; - c.getContext('2d').clearRect(0,0,c.width,c.height); - } - }); - } + if (_chartInstances[id]) { _chartInstances[id] = null; } try { _chartInstances[id] = { cpu: null, mem: null, net: null }; if (typeof MiniChart !== 'undefined') {