fix: play completion sound in chat (#466)

This commit is contained in:
Zhicheng Han
2026-05-06 08:23:12 +02:00
committed by GitHub
parent 1011c950be
commit f338aeea18
4 changed files with 177 additions and 3 deletions
@@ -4,15 +4,21 @@ import ChatPanel from '@/components/hermes/chat/ChatPanel.vue'
import { useAppStore } from '@/stores/hermes/app'
import { useChatStore } from '@/stores/hermes/chat'
import { useProfilesStore } from '@/stores/hermes/profiles'
import { useSettingsStore } from '@/stores/hermes/settings'
const appStore = useAppStore()
const chatStore = useChatStore()
const profilesStore = useProfilesStore()
const settingsStore = useSettingsStore()
onMounted(async () => {
appStore.loadModels()
// 先加载 profile,确保缓存 key 使用正确的 profile name
await profilesStore.fetchProfiles()
// 先加载 profile,确保缓存 key 使用正确的 profile name;同时预取显示设置,
// 让聊天完成提示音不依赖用户先打开 Settings 页面。
await Promise.all([
profilesStore.fetchProfiles(),
settingsStore.fetchSettings(),
])
chatStore.loadSessions()
})
</script>