Skip to content

Commit

Permalink
feat: 애플 로그인 버튼으로 교체
Browse files Browse the repository at this point in the history
  • Loading branch information
shinwonse committed Aug 5, 2023
1 parent a3567a7 commit e946e2e
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 10 deletions.
4 changes: 2 additions & 2 deletions src/pages/login/index.module.scss
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,8 @@
background-color: #fee500;
}

&--naver {
background-color: #03c75a;
&--apple {
background-color: #000000;
color: themes.$white;
}
}
Expand Down
12 changes: 6 additions & 6 deletions src/pages/login/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ const cx = classNames.bind(styles);
const Login = () => {
const router = useRouter();

const { loginWithKakao, loginWithNaver, verifyLoggedIn } = useAuth();
const { loginWithKakao, loginWithApple, verifyLoggedIn } = useAuth();

useEffect(() => {
verifyLoggedIn().then((isLoggedIn) => {
Expand Down Expand Up @@ -44,12 +44,12 @@ const Login = () => {
</button>
<button
type="button"
aria-label="네이버 로그인"
className={cx('login-button', 'login-button--naver')}
onClick={loginWithNaver}
aria-label="애플 로그인"
className={cx('login-button', 'login-button--apple')}
onClick={loginWithApple}
>
<Icon name="Naver" size={24} />
<span>네이버 로그인</span>
<Icon name="Apple" size={24} />
<span>Apple로 로그인</span>
</button>
<div className={cx('terms-of-service')}>
<span>
Expand Down
4 changes: 2 additions & 2 deletions src/shared/hooks/useAuth.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ const useAuth = () => {
location.href = getKakaoOAuthAuthorizeUrl();
};

const loginWithNaver = () => {
const loginWithApple = () => {
alert('준비중입니다!');
};

Expand All @@ -58,7 +58,7 @@ const useAuth = () => {

return {
loginWithKakao,
loginWithNaver,
loginWithApple,
logout,
verifyLoggedIn,
};
Expand Down

0 comments on commit e946e2e

Please sign in to comment.