-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
8 changed files
with
89 additions
and
85 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
interface StateContextType<T> { | ||
auth: T; | ||
setAuth: React.Dispatch<React.SetStateAction<T>>; | ||
} | ||
export interface AuthContextData { | ||
user: Record<string, unknown>; | ||
accessToken: string; | ||
active: boolean; | ||
} | ||
export type AuthContextType = StateContextType<AuthContextData | null>; | ||
|
||
export interface AuthContextProps { | ||
children: React.ReactNode; | ||
} | ||
|
||
export interface TokenResponse { | ||
token: string; | ||
active: boolean; | ||
} | ||
|
||
export interface RegisterData { | ||
email: string; | ||
password: string; | ||
firstName: string; | ||
lastName: string; | ||
gender: string; | ||
age: number; | ||
} | ||
|
||
export interface LoginData { | ||
email: string; | ||
password: string; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
export interface Match { | ||
id: string; | ||
firstUserId: string; | ||
secondUserId: string; | ||
accepted: boolean; | ||
finished: boolean; | ||
} | ||
export interface MatchData { | ||
userId: string; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
export interface User { | ||
id: string; | ||
email: string; | ||
firstName: string; | ||
lastName: string; | ||
hashedPassword: string; | ||
gender: string; | ||
age: number; | ||
active: boolean; | ||
description: string; | ||
profileImageUrl: string; | ||
phoneNumber: string; | ||
location: string; | ||
preferences: UserPreferences; | ||
lastSeen: string; | ||
createdAt: string; | ||
updatedAt: string; | ||
} | ||
|
||
interface UserPreferences { | ||
ageGroupMin: number; | ||
ageGroupMax: number; | ||
partnerGender: string; | ||
} | ||
|
||
export interface PreferencesInitData { | ||
description: string; | ||
profileImageUrl: string; | ||
phoneNumber: string; | ||
location: string; | ||
preferences: UserPreferences; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters