Skip to content

Commit

Permalink
feat: add auth & member type
Browse files Browse the repository at this point in the history
  • Loading branch information
timepresent95 committed Aug 6, 2024
1 parent 80599bd commit 30815b8
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/types/auth.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
export type OAuthAgent = 'apple' | 'google' | 'kakao';

export type SignInLog = {
recentSigninDate: Date; // 최근 접속 시간
recentSigninOAuthAgent: OAuthAgent; // 최근 접속시 사용한 로그인 방법
};
2 changes: 2 additions & 0 deletions src/types/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
export * from './member';
export * from './auth';
16 changes: 16 additions & 0 deletions src/types/member.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
import {roles} from '@/constants';

export type Role = (typeof roles)[number];

export type Birthday = {
isLuna: boolean;
date: Date;
};

export type Member = {
name: string;
role: Role;
birthday: Birthday;
signUpDate: Date;
isHost: boolean; // 그룹장 여부
};

0 comments on commit 30815b8

Please sign in to comment.