login page

This commit is contained in:
naiba
2024-11-02 22:34:43 +08:00
parent d945ca97c1
commit 017e6cfdcf
32 changed files with 2236 additions and 170 deletions

View File

@@ -0,0 +1,7 @@
import { User } from "./user";
export interface AuthContextProps {
profile: User | undefined;
login: (profile: User | undefined) => void;
logout: () => void;
}

3
src/types/index.ts Normal file
View File

@@ -0,0 +1,3 @@
export * from './user';
export * from './mainStore';
export * from './authContext';

6
src/types/mainStore.tsx Normal file
View File

@@ -0,0 +1,6 @@
import { User } from "./user";
export interface MainStore {
profile: User | undefined;
setProfile: (profile: User | undefined) => void;
}

3
src/types/user.ts Normal file
View File

@@ -0,0 +1,3 @@
export interface User {
username: string;
}