From 068c50382af3d3e6d64b33940400a1491e6a29d6 Mon Sep 17 00:00:00 2001 From: Libin YANG Date: Wed, 15 Jan 2025 16:00:53 +0800 Subject: [PATCH] fix: tab changed (#518) --- src/components/CodemirrorEditor/CssEditor.vue | 1 + src/components/CodemirrorEditor/EditorHeader/PostInfo.vue | 1 - src/stores/index.ts | 3 --- 3 files changed, 1 insertion(+), 4 deletions(-) diff --git a/src/components/CodemirrorEditor/CssEditor.vue b/src/components/CodemirrorEditor/CssEditor.vue index c2725f1..0422bbe 100644 --- a/src/components/CodemirrorEditor/CssEditor.vue +++ b/src/components/CodemirrorEditor/CssEditor.vue @@ -98,6 +98,7 @@ function tabChanged(tabName: string | number) { } tabHistory.value = [tabHistory.value[1], tabName as string] + store.tabChanged(tabName as string) } diff --git a/src/components/CodemirrorEditor/EditorHeader/PostInfo.vue b/src/components/CodemirrorEditor/EditorHeader/PostInfo.vue index 1a12283..14baf52 100644 --- a/src/components/CodemirrorEditor/EditorHeader/PostInfo.vue +++ b/src/components/CodemirrorEditor/EditorHeader/PostInfo.vue @@ -57,7 +57,6 @@ async function prePost() { form.value = { ...auto, } - console.log(form.value, `====`) } } diff --git a/src/stores/index.ts b/src/stores/index.ts index a75e14c..1bc27e4 100644 --- a/src/stores/index.ts +++ b/src/stores/index.ts @@ -189,12 +189,9 @@ export const useStore = defineStore(`store`, () => { renderer.reset({ citeStatus: isCiteStatus.value, legend: legend.value, isUseIndent: isUseIndent.value, countStatus: isCountStatus.value }) const { markdownContent, readingTime: readingTimeResult } = renderer.parseFrontMatterAndContent(editor.value!.getValue()) - console.log(`Reading time result:`, readingTimeResult) readingTime.value = readingTimeResult let outputTemp = marked.parse(markdownContent) as string - console.log(readingTime.value) - // 阅读时间及字数统计 outputTemp = renderer.buildReadingTime(readingTimeResult) + outputTemp