From 88ed58f0fd8c4503a52f76166875e39245b8b9f5 Mon Sep 17 00:00:00 2001 From: fofolee Date: Sun, 1 May 2022 16:26:06 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E6=90=9C=E7=B4=A2=E7=BB=93?= =?UTF-8?q?=E6=9E=9C=E6=98=BE=E7=A4=BA=20bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pages/ConfigurationPage.vue | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/pages/ConfigurationPage.vue b/src/pages/ConfigurationPage.vue index a2b4972..dd79328 100644 --- a/src/pages/ConfigurationPage.vue +++ b/src/pages/ConfigurationPage.vue @@ -29,7 +29,6 @@ ? 'text-blue-7 text-weight-bolder' : '' " - v-show="!(tag === '搜索结果' && commandSearchKeyword?.length < 2)" > {{ tag }} @@ -299,7 +298,7 @@ export default { Object.values(this.allQuickCommands).map((x) => x.tags) ) ).concat(["未分类", "来自分享"]); - allTags.push("搜索结果"); + if (this.commandSearchKeyword?.length > 1) allTags.push("搜索结果"); return allTags; }, // 标签栏宽度 @@ -551,9 +550,9 @@ export default { if (this.currentTag !== "搜索结果") this.lastTag = this.currentTag; if (this.commandSearchKeyword?.length > 1) { // 搜索时跳转到搜索结果标签 - this.$nextTick(() => { + setTimeout(() => { this.currentTag = "搜索结果"; - }); + }, 100); } else { // 清空搜索回跳到之前标签 if (this.currentTag !== this.lastTag) this.currentTag = this.lastTag;