Skip to content

Commit

Permalink
fix: kakao, google 소셜로그인
Browse files Browse the repository at this point in the history
  • Loading branch information
jiohjung98 committed Oct 6, 2024
1 parent d680125 commit ae1056e
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
5 changes: 2 additions & 3 deletions src/components/sign/GoogleLogin.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,10 @@ import React from 'react';
import GoogleLoginButton from '../../../public/images/sign/google-login.svg';

const GoogleLogin = ({ setLoginType }: { setLoginType: (type: 'google') => void }) => {

const handleGoogleLogin = () => {
// loginType을 google로 설정
setLoginType('google');
// 구글 로그인 페이지로 리다이렉트
window.location.href = 'https://accounts.google.com/o/oauth2/auth';
window.location.href = 'https://api.moaguide.com/oauth2/authorization/google';
};

return (
Expand Down
5 changes: 2 additions & 3 deletions src/components/sign/KakaoLogin.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,10 @@ import React from 'react';
import KakaoLoginButton from '../../../public/images/sign/kakao-login.svg';

const KakaoLogin = ({ setLoginType }: { setLoginType: (type: 'kakao') => void }) => {

const handleKakaoLogin = () => {
// loginType을 kakao로 설정
setLoginType('kakao');
// 카카오 로그인 페이지로 리다이렉트
window.location.href = 'https://kauth.kakao.com/oauth/authorize';
window.location.href = 'https://api.moaguide.com/oauth2/authorization/kakao';
};

return (
Expand Down

0 comments on commit ae1056e

Please sign in to comment.