feat(admin-web/auth): support phone-or-email login and dim shell on expiry

Login form takes a phone-or-email identifier; user info now exposes phone
so the shell can fall back through name → phone → email. When membership
expires, the app stays on the current route but renders a minimal blocked
state in the shell instead of redirecting to a dedicated page; an Axios
interceptor flips the local session into the blocked state when the API
returns trial/subscription errors.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-04-29 00:01:47 +08:00
parent ee21f512a9
commit 62b824520c
10 changed files with 170 additions and 33 deletions
+5 -3
View File
@@ -21,14 +21,16 @@ export interface AuthTokens {
}
export interface LoginRequest {
email: string;
identifier: string;
password: string;
email?: string;
}
export interface UserInfo {
id: number;
email: string;
name: string;
email: string | null;
phone: string;
name: string | null;
avatar_url: string | null;
tenant_id: number;
primary_workspace_id: number;