refactor(auth): remove unused machine state
This commit is contained in:
@@ -1,17 +1,11 @@
|
||||
/**
|
||||
* Auth 状态机:State 形状 + 初始值
|
||||
*/
|
||||
import type { AuthMode, AuthPanelMode, LoginStatus } from "@/data/dto/auth";
|
||||
import type { AuthPanelMode, LoginStatus } from "@/data/dto/auth";
|
||||
|
||||
export interface AuthState {
|
||||
/** 当前面板模式(Facebook / Email) */
|
||||
authPanelMode: AuthPanelMode;
|
||||
/** 内部登录模式(login / register) */
|
||||
authMode: AuthMode;
|
||||
email: string;
|
||||
password: string;
|
||||
username: string;
|
||||
confirmPassword: string;
|
||||
errorMessage: string | null;
|
||||
/** 当前登录状态(未登录 / 游客 / OAuth / 邮箱)—— 下游同步器监听此字段的双向变化 */
|
||||
loginStatus: LoginStatus;
|
||||
@@ -21,11 +15,6 @@ export interface AuthState {
|
||||
|
||||
export const initialState: AuthState = {
|
||||
authPanelMode: "facebook",
|
||||
authMode: "login",
|
||||
email: "",
|
||||
password: "",
|
||||
username: "",
|
||||
confirmPassword: "",
|
||||
errorMessage: null,
|
||||
loginStatus: "notLoggedIn",
|
||||
hasInitialized: false,
|
||||
|
||||
Reference in New Issue
Block a user