mirror of
https://github.com/router-for-me/Cli-Proxy-API-Management-Center.git
synced 2026-02-19 11:10:49 +08:00
feat: initialize new React application structure with TypeScript, ESLint, and Prettier configurations, while removing legacy files and adding new components and pages for enhanced functionality
This commit is contained in:
28
src/types/auth.ts
Normal file
28
src/types/auth.ts
Normal file
@@ -0,0 +1,28 @@
|
||||
/**
|
||||
* 认证相关类型定义
|
||||
* 基于原项目 src/modules/login.js 和 src/core/connection.js
|
||||
*/
|
||||
|
||||
// 登录凭据
|
||||
export interface LoginCredentials {
|
||||
apiBase: string;
|
||||
managementKey: string;
|
||||
}
|
||||
|
||||
// 认证状态
|
||||
export interface AuthState {
|
||||
isAuthenticated: boolean;
|
||||
apiBase: string;
|
||||
managementKey: string;
|
||||
serverVersion: string | null;
|
||||
serverBuildDate: string | null;
|
||||
}
|
||||
|
||||
// 连接状态
|
||||
export type ConnectionStatus = 'connected' | 'disconnected' | 'connecting' | 'error';
|
||||
|
||||
export interface ConnectionInfo {
|
||||
status: ConnectionStatus;
|
||||
lastCheck: Date | null;
|
||||
error: string | null;
|
||||
}
|
||||
Reference in New Issue
Block a user