diff --git a/solution/frontend/src/pages/LoginPage.tsx b/solution/frontend/src/pages/LoginPage.tsx index b190e97..13c270a 100644 --- a/solution/frontend/src/pages/LoginPage.tsx +++ b/solution/frontend/src/pages/LoginPage.tsx @@ -3,9 +3,11 @@ import {Link, Navigate, useLocation, useNavigate} from 'react-router'; import {LogIn} from 'lucide-react'; import {googleLogin, login} from '@/api'; import {GoogleSignInButton} from '@/components/auth/GoogleSignInButton'; +import {KakaoSignInButton} from '@/components/auth/KakaoSignInButton'; import {Button} from '@/components/ui/button'; import {Input} from '@/components/ui/input'; import {isGoogleLoginEnabled} from '@/lib/googleIdentity'; +import {isKakaoLoginEnabled} from '@/lib/kakaoIdentity'; import {notifyApiError} from '@/lib/notify'; import {establishSession} from '@/lib/session'; import {useAuthStore} from '@/stores/auth'; @@ -129,14 +131,19 @@ export function LoginPage({ 로그인 - {selfServe && isGoogleLoginEnabled() && ( + {selfServe && (isKakaoLoginEnabled() || isGoogleLoginEnabled()) && ( <>
또는
- + {/* ★ 카카오를 위에 둔다 — 카톡 채널로 홈페이지를 관리하려면 이 수단이어야 + 회원번호가 이어진다(docs/AGENT.md). 구글로 들어오면 6자리 코드를 거쳐야 한다. */} + + {isGoogleLoginEnabled() && ( + + )} )} diff --git a/solution/frontend/src/pages/SignupPage.tsx b/solution/frontend/src/pages/SignupPage.tsx index f1f7d4b..5062e95 100644 --- a/solution/frontend/src/pages/SignupPage.tsx +++ b/solution/frontend/src/pages/SignupPage.tsx @@ -3,9 +3,11 @@ import {Link, Navigate, useNavigate} from 'react-router'; import {UserPlus} from 'lucide-react'; import {googleLogin, signup} from '@/api'; import {GoogleSignInButton} from '@/components/auth/GoogleSignInButton'; +import {KakaoSignInButton} from '@/components/auth/KakaoSignInButton'; import {Button} from '@/components/ui/button'; import {Input} from '@/components/ui/input'; import {isGoogleLoginEnabled} from '@/lib/googleIdentity'; +import {isKakaoLoginEnabled} from '@/lib/kakaoIdentity'; import {notify, notifyApiError} from '@/lib/notify'; import {establishSession} from '@/lib/session'; import {useAuthStore} from '@/stores/auth'; @@ -179,14 +181,19 @@ export function SignupPage() { 가입하기 - {isGoogleLoginEnabled() && ( + {(isKakaoLoginEnabled() || isGoogleLoginEnabled()) && ( <>
또는
- + {/* ★ 카카오는 가입과 로그인이 같은 동작이다 — 처음 온 회원번호면 백엔드가 그 자리에서 + 계정을 만든다. 그래서 두 화면이 같은 버튼을 쓴다. */} + + {isGoogleLoginEnabled() && ( + + )} )}