diff --git a/frontend/public/loginBtns/google_login.svg b/frontend/public/loginBtns/google_login.svg new file mode 100644 index 000000000..21ec49090 --- /dev/null +++ b/frontend/public/loginBtns/google_login.svg @@ -0,0 +1,7 @@ + diff --git a/frontend/src/app/_components/ui/button/GoogleLoginButton.tsx b/frontend/src/app/_components/ui/button/GoogleLoginButton.tsx new file mode 100644 index 000000000..63d335326 --- /dev/null +++ b/frontend/src/app/_components/ui/button/GoogleLoginButton.tsx @@ -0,0 +1,18 @@ +'use client'; + +import Image from 'next/image'; +import { signIn } from 'next-auth/react'; + +import googleLogo from '@/../public/loginBtns/google_login.svg'; + +export default function GoogleLoginButton() { + return ( + + ); +} diff --git a/frontend/src/app/_components/ui/button/Kakao.tsx b/frontend/src/app/_components/ui/button/Kakao.tsx index 0dfa48604..65e45e225 100644 --- a/frontend/src/app/_components/ui/button/Kakao.tsx +++ b/frontend/src/app/_components/ui/button/Kakao.tsx @@ -1,7 +1,9 @@ -import { signIn } from 'next-auth/react' -import Image from 'next/image' -import React from 'react' -import kakaoLogo from '../../../../../public/loginBtns/kakao_logo.png' +'use client'; + +import { signIn } from 'next-auth/react'; +import Image from 'next/image'; +import React from 'react'; +import kakaoLogo from '../../../../../public/loginBtns/kakao_logo.png'; export default function KakaoBtn() { return ( @@ -9,7 +11,7 @@ export default function KakaoBtn() { className="bg-[#fee500] w-[300px] h-[45px] flex justify-start text-center items-center rounded-md p-[15px] cursor-pointer border-none" onClick={() => signIn('kakao', { - callbackUrl: '/home', + callbackUrl: '/', }) } > @@ -18,5 +20,5 @@ export default function KakaoBtn() { Kakao 로그인하기 - ) + ); } diff --git a/frontend/src/app/login/page.tsx b/frontend/src/app/login/page.tsx index 7cd093204..41da4ca4b 100644 --- a/frontend/src/app/login/page.tsx +++ b/frontend/src/app/login/page.tsx @@ -1,5 +1,8 @@ import React from 'react'; + import KakaoBtn from '@/app/_components/ui/button/Kakao'; +import GoogleLoginButton from '@/app/_components/ui/button/GoogleLoginButton'; + import LoginLogo from './_components/ui/LoginLogo'; export default function LoginPage() { @@ -11,6 +14,7 @@ export default function LoginPage() {