fix(desktop): 扩充应用菜单与元数据快捷键

This commit is contained in:
2026-09-08 00:01:03 +08:00
parent acc0ba167d
commit 2b18b8b2a2
9 changed files with 220 additions and 24 deletions
+8 -2
View File
@@ -91,10 +91,13 @@ export const useWorkspaceStore = defineStore('workspace', () => {
isLoading.value = true
try {
const info = await workspaceService.openVault(path)
const tree = await workspaceService.getFileTree()
vaultPath.value = info.path
vaultId.value = info.vault_id
vaultName.value = info.name
fileTree.value = await workspaceService.getFileTree()
fileTree.value = tree
openFiles.value = []
activeFilePath.value = null
hasVault.value = true
localStorage.setItem('last-vault-path', info.path)
} finally {
@@ -107,10 +110,13 @@ export const useWorkspaceStore = defineStore('workspace', () => {
isLoading.value = true
try {
const info = await workspaceService.createVault(path, name)
const tree = await workspaceService.getFileTree()
vaultPath.value = info.path
vaultId.value = info.vault_id
vaultName.value = info.name
fileTree.value = await workspaceService.getFileTree()
fileTree.value = tree
openFiles.value = []
activeFilePath.value = null
hasVault.value = true
localStorage.setItem('last-vault-path', info.path)
} finally {