登录页UI及长时间未操作锁定逻辑优化

This commit is contained in:
Cheng Zhou
2026-03-10 10:10:58 +08:00
parent 7936c55f3f
commit 4c98147f3e
12 changed files with 2225 additions and 470 deletions
+2
View File
@@ -43,11 +43,13 @@ export const useAuthStore = defineStore("auth", () => {
const logout = () => {
const studyStore = useStudyStore();
const sessionStore = useSessionStore();
const userKey = user.value?.email || localStorage.getItem(LAST_LOGIN_EMAIL_KEY) || "";
studyStore.rememberCurrentStudyForUser(userKey);
token.value = null;
user.value = null;
forceLogin.value = false;
sessionStore.unlock();
clearToken();
studyStore.clearCurrentStudy();
};