From f8c46126508ecc0ca12757cbbd84e61ca158f14a Mon Sep 17 00:00:00 2001 From: shuim Date: Sat, 19 Sep 2026 23:58:28 +0900 Subject: [PATCH] =?UTF-8?q?style:=20=EB=A1=9C=EA=B7=B8=EC=9D=B8=20?= =?UTF-8?q?=ED=8E=98=EC=9D=B4=EC=A7=80=20=EC=9E=AC=EC=84=A4=EA=B3=84=20+?= =?UTF-8?q?=20'GEN=203=20ALGO'=20=ED=83=9C=EA=B7=B8=EB=9D=BC=EC=9D=B8=20?= =?UTF-8?q?=EC=A0=9C=EA=B1=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Login: 카드형 레이아웃, 키 아이콘·표시/숨김 토글, 인라인 에러(aria), 로딩 스피너, 입력 시 에러 자동 해제, 그라디언트 텍스트 제거 - Layout 헤더: 태그라인 삭제, 브랜드명 단일 표기 Co-Authored-By: Claude Opus 5 (1M context) --- frontend/src/components/Layout.tsx | 9 +-- frontend/src/pages/Login.tsx | 109 +++++++++++++++++++---------- 2 files changed, 73 insertions(+), 45 deletions(-) diff --git a/frontend/src/components/Layout.tsx b/frontend/src/components/Layout.tsx index 9d8b837..7ad7c47 100644 --- a/frontend/src/components/Layout.tsx +++ b/frontend/src/components/Layout.tsx @@ -8,7 +8,7 @@ * * 구조: * [Header] — sticky 상단 바 (z-50) - * - 브랜드 로고 (AutoStock GEN 3 ALGO) + * - 브랜드 로고 (AutoStock) * - 네비게이션 링크 (대시보드, 성과분석, 전략설정, 백테스트, 매매로그, MCP상태) * - 연결 상태 표시 (Backend LIVE/OFFLINE, MCP connected/unknown) * [Main] — 페이지 컨텐츠 영역 @@ -78,12 +78,7 @@ const Layout = ({ children }: LayoutProps) => {
-
-

- AutoStock -

-

GEN 3 ALGO

-
+

AutoStock

{/* Navigation */} diff --git a/frontend/src/pages/Login.tsx b/frontend/src/pages/Login.tsx index ea1070f..cd01509 100644 --- a/frontend/src/pages/Login.tsx +++ b/frontend/src/pages/Login.tsx @@ -10,7 +10,7 @@ * - onLogin: 인증 성공 시 API 키를 전달받는 콜백 (App에서 localStorage 저장) */ import { useState, FormEvent } from 'react' -import { Activity } from 'lucide-react' +import { Activity, Eye, EyeOff, KeyRound, Loader2 } from 'lucide-react' /** Login 컴포넌트 Props 정의 */ interface LoginProps { @@ -30,6 +30,7 @@ const Login = ({ onLogin }: LoginProps) => { const [apiKey, setApiKey] = useState('') const [error, setError] = useState('') const [loading, setLoading] = useState(false) + const [showKey, setShowKey] = useState(false) /** * 폼 제출 핸들러 — API 키 유효성 검증 @@ -77,48 +78,80 @@ const Login = ({ onLogin }: LoginProps) => { } return ( -
-
-
-
- -
-
-

- AutoStock -

-

GEN 3 ALGO

+
+
+ {/* 브랜드 */} +
+
+
+

AutoStock

+

자동매매 대시보드

-
-
- - setApiKey(e.target.value)} - placeholder="SECRET_KEY 입력" - className="w-full px-4 py-3 bg-gray-800/50 border border-gray-700 rounded-lg text-gray-100 placeholder-gray-600 focus:outline-none focus:border-blue-500 focus:ring-1 focus:ring-blue-500 transition-colors" - autoFocus - /> -
+ {/* 로그인 카드 */} +
+ +
+ +
+ + { + setApiKey(e.target.value) + if (error) setError('') + }} + placeholder="SECRET_KEY" + autoComplete="current-password" + spellCheck={false} + aria-invalid={!!error} + aria-describedby={error ? 'api-key-error' : undefined} + className={`w-full pl-10 pr-11 py-3 bg-[#0f1115] border rounded-xl text-gray-100 placeholder-gray-600 font-mono text-sm transition-colors focus:outline-none focus:ring-2 ${ + error + ? 'border-red-500/60 focus:border-red-500 focus:ring-red-500/30' + : 'border-gray-700 focus:border-blue-500 focus:ring-blue-500/30' + }`} + autoFocus + /> + +
+ {error && ( + + )} +
- {error && ( -

{error}

- )} + + +
- - - -

- .env 파일의 SECRET_KEY 값을 입력하세요 +

+ 백엔드 .env의{' '} + SECRET_KEY 값으로 로그인합니다.