mirror of
https://github.com/doocs/md.git
synced 2025-01-22 20:04:39 +08:00
fix: tab changed (#518)
This commit is contained in:
parent
6f0ae9dc1d
commit
068c50382a
@ -98,6 +98,7 @@ function tabChanged(tabName: string | number) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
tabHistory.value = [tabHistory.value[1], tabName as string]
|
tabHistory.value = [tabHistory.value[1], tabName as string]
|
||||||
|
store.tabChanged(tabName as string)
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
@ -57,7 +57,6 @@ async function prePost() {
|
|||||||
form.value = {
|
form.value = {
|
||||||
...auto,
|
...auto,
|
||||||
}
|
}
|
||||||
console.log(form.value, `====`)
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -189,12 +189,9 @@ export const useStore = defineStore(`store`, () => {
|
|||||||
renderer.reset({ citeStatus: isCiteStatus.value, legend: legend.value, isUseIndent: isUseIndent.value, countStatus: isCountStatus.value })
|
renderer.reset({ citeStatus: isCiteStatus.value, legend: legend.value, isUseIndent: isUseIndent.value, countStatus: isCountStatus.value })
|
||||||
|
|
||||||
const { markdownContent, readingTime: readingTimeResult } = renderer.parseFrontMatterAndContent(editor.value!.getValue())
|
const { markdownContent, readingTime: readingTimeResult } = renderer.parseFrontMatterAndContent(editor.value!.getValue())
|
||||||
console.log(`Reading time result:`, readingTimeResult)
|
|
||||||
readingTime.value = readingTimeResult
|
readingTime.value = readingTimeResult
|
||||||
let outputTemp = marked.parse(markdownContent) as string
|
let outputTemp = marked.parse(markdownContent) as string
|
||||||
|
|
||||||
console.log(readingTime.value)
|
|
||||||
|
|
||||||
// 阅读时间及字数统计
|
// 阅读时间及字数统计
|
||||||
outputTemp = renderer.buildReadingTime(readingTimeResult) + outputTemp
|
outputTemp = renderer.buildReadingTime(readingTimeResult) + outputTemp
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user