From dd3e169946f68e6b1cae1c7ed972b308d9a1f1eb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=A1=97=E8=A7=92=E5=B0=8F=E6=9E=97?= <1013335014@qq.com> Date: Mon, 21 Oct 2024 09:37:13 +0800 Subject: [PATCH] =?UTF-8?q?Fix=EF=BC=9A=E4=BF=AE=E5=A4=8D=E5=9C=A8?= =?UTF-8?q?=E8=8A=82=E7=82=B9=E6=96=87=E6=9C=AC=E7=BC=96=E8=BE=91=E4=B8=AD?= =?UTF-8?q?=E8=B0=83=E7=94=A8destroy=E6=96=B9=E6=B3=95=E6=97=B6setBackgrou?= =?UTF-8?q?ndStyle=E6=96=B9=E6=B3=95=E4=BC=9A=E6=8A=A5=E9=94=99=E7=9A=84?= =?UTF-8?q?=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- simple-mind-map/src/core/render/node/Style.js | 1 + 1 file changed, 1 insertion(+) diff --git a/simple-mind-map/src/core/render/node/Style.js b/simple-mind-map/src/core/render/node/Style.js index 164fb948..e038793b 100644 --- a/simple-mind-map/src/core/render/node/Style.js +++ b/simple-mind-map/src/core/render/node/Style.js @@ -12,6 +12,7 @@ const backgroundStyleProps = [ class Style { // 设置背景样式 static setBackgroundStyle(el, themeConfig) { + if (!this.el) return // 缓存容器元素原本的样式 if (!Style.cacheStyle) { Style.cacheStyle = {}