feat: 消息通知

This commit is contained in:
2026-05-31 09:51:57 +08:00
parent 1cc85f1c46
commit 74b6045220
10 changed files with 637 additions and 243 deletions

View File

@@ -2,13 +2,20 @@ import { defineStore } from 'pinia'
import { ref, computed } from 'vue'
export const useGlobalStore = defineStore('global', () => {
const state = ref({
loading: false
loading: false,
unReadMessageCount: 0
})
const setLoading = (v: boolean) => { state.value.loading = v }
const setLoading = (v: boolean) => {
state.value.loading = v
}
const setUnredCount = (number: number) => {
state.value.unReadMessageCount = number
}
return {
state,
setLoading,
setUnredCount
}
})