From fd096c44442da4bb7c1e9286967dfb2ce253805a Mon Sep 17 00:00:00 2001
From: wanglin2 <1013335014@qq.com>
Date: Wed, 21 Sep 2022 09:38:41 +0800
Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E6=A0=B9=E8=8A=82=E7=82=B9?=
=?UTF-8?q?=E6=B7=BB=E5=8A=A0=E5=A4=9A=E4=B8=AA=E8=8A=82=E7=82=B9=E7=88=86?=
=?UTF-8?q?=E6=A0=88=E7=9A=84=E9=97=AE=E9=A2=98?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
index.html | 2 +-
web/src/pages/Edit/components/Toolbar.vue | 10 +++++-----
2 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/index.html b/index.html
index cdc64b40..0eceb4a6 100644
--- a/index.html
+++ b/index.html
@@ -1 +1 @@
-
一个简单的web思维导图实现 We're sorry but thoughts doesn't work properly without JavaScript enabled. Please enable it to continue.
\ No newline at end of file
+一个简单的web思维导图实现 We're sorry but thoughts doesn't work properly without JavaScript enabled. Please enable it to continue.
\ No newline at end of file
diff --git a/web/src/pages/Edit/components/Toolbar.vue b/web/src/pages/Edit/components/Toolbar.vue
index 436c04c9..9e9b749c 100644
--- a/web/src/pages/Edit/components/Toolbar.vue
+++ b/web/src/pages/Edit/components/Toolbar.vue
@@ -106,7 +106,7 @@
@@ -194,14 +194,14 @@ export default {
},
computed: {
hasRoot() {
- return this.activeNodes.find((node) => {
+ return this.activeNodes.findIndex((node) => {
return node.isRoot;
- });
+ }) !== -1;
},
hasGeneralization() {
- return this.activeNodes.find((node) => {
+ return this.activeNodes.findIndex((node) => {
return node.isGeneralization;
- });
+ }) !== -1;;
}
},
created() {