File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -42,8 +42,6 @@ const Auth = () => {
4242
4343 const TYPE = new URL ( window . location . href ) . searchParams . get ( 'type' ) ;
4444
45- let tokenUrl = '' ;
46-
4745 if ( ! AUTHORIZATION_CODE || ! TYPE ) {
4846 console . error ( 'Authorization Code or Type is missing' ) ;
4947 return ;
Original file line number Diff line number Diff line change @@ -14,6 +14,32 @@ const notReady = () => {
1414 alert ( '준비 중입니다.' ) ;
1515} ;
1616
17+ const oauthButtons = [
18+ {
19+ key : 'naver' ,
20+ bgColor : '#03CF5D' ,
21+ component : (
22+ < Image
23+ src = "/assets/icons/ic_naver.svg"
24+ alt = "Naver"
25+ width = { 26 }
26+ height = { 26 }
27+ onClick = { ( ) => alert ( '준비 중입니다.' ) }
28+ />
29+ )
30+ } ,
31+ {
32+ key : 'google' ,
33+ bgColor : '#FFFFFF' ,
34+ component : < SocialGoogle />
35+ } ,
36+ {
37+ key : 'kakao' ,
38+ bgColor : '#FEE500' ,
39+ component : < SocialKakao />
40+ }
41+ ] ;
42+
1743export default function Login ( ) {
1844 return (
1945 < Container >
@@ -22,21 +48,11 @@ export default function Login() {
2248 < LogoText > 편지로 수놓는 나의 스페이스</ LogoText >
2349 < LogoImage src = "/assets/login/login_logo.png" />
2450 < OauthWrapper >
25- < OauthButton bgColor = "#03CF5D" >
26- < Image
27- src = "/assets/icons/ic_naver.svg"
28- alt = "Naver"
29- width = { 26 }
30- height = { 26 }
31- onClick = { notReady }
32- />
33- </ OauthButton >
34- < OauthButton bgColor = "#FFFFFF" >
35- < SocialGoogle />
36- </ OauthButton >
37- < OauthButton bgColor = "#FEE500" >
38- < SocialKakao />
39- </ OauthButton >
51+ { oauthButtons . map ( ( { key, bgColor, component } ) => (
52+ < OauthButton key = { key } bgColor = { bgColor } >
53+ { component }
54+ </ OauthButton >
55+ ) ) }
4056 </ OauthWrapper >
4157 < LetterBtnText onClick = { notReady } >
4258 로그인 없이 편지 작성해보기
You can’t perform that action at this time.
0 commit comments