11import React , { useState } from 'react' ;
22
3+ import { faEye , faEyeSlash } from '@fortawesome/free-solid-svg-icons' ;
34import { FontAwesomeIcon } from '@fortawesome/react-fontawesome' ;
45import axios from 'axios' ;
56import cn from 'classnames' ;
@@ -91,7 +92,8 @@ const PasswordInput = ({ id, title, formik }) => {
9192 className = { `position-absolute end-0 top-0 h-100 ${ isInvalid ? 'mr-4' : '' } ` }
9293 onClick = { togglePasswordVisibility }
9394 >
94- < FontAwesomeIcon icon = { showPassword ? 'eye-slash' : 'eye' } />
95+ { /* <FontAwesomeIcon icon={showPassword ? 'eye-slash' : 'eye'} /> */ }
96+ < FontAwesomeIcon icon = { showPassword ? faEyeSlash : faEye } />
9597 </ Button >
9698 </ div >
9799 { isInvalid && < div className = "invalid-feedback" > { formik . errors [ id ] } </ div > }
@@ -122,7 +124,9 @@ const SocialLinks = ({ isSignUp }) => (
122124 href = { getLinkWithNext ( '/auth/github' ) }
123125 className = "btn w-100 px-2 btn-outline-dark rounded-lg"
124126 >
125- { isSignUp ? i18n . t ( 'Sign up with Github' ) : i18n . t ( 'Sign in with Github' ) }
127+ { isSignUp
128+ ? i18n . t ( 'Sign up with Github' )
129+ : i18n . t ( 'Sign in with Github' ) }
126130 </ a >
127131 </ div >
128132 < div className = "mt-1" >
@@ -132,7 +136,9 @@ const SocialLinks = ({ isSignUp }) => (
132136 href = { getLinkWithNext ( '/auth/discord' ) }
133137 className = "btn w-100 px-2 btn-outline-dark rounded-lg"
134138 >
135- { isSignUp ? i18n . t ( 'Sign up with Discord' ) : i18n . t ( 'Sign in with Discord' ) }
139+ { isSignUp
140+ ? i18n . t ( 'Sign up with Discord' )
141+ : i18n . t ( 'Sign in with Discord' ) }
136142 </ a >
137143 </ div >
138144 </ >
@@ -273,7 +279,11 @@ function SignUp() {
273279 < Input id = "name" type = "text" title = "Nickname" formik = { formik } />
274280 < Input id = "email" type = "email" title = "Email" formik = { formik } />
275281 < PasswordInput id = "password" title = "Password" formik = { formik } />
276- < PasswordInput id = "passwordConfirmation" title = "Password Confirmation" formik = { formik } />
282+ < PasswordInput
283+ id = "passwordConfirmation"
284+ title = "Password Confirmation"
285+ formik = { formik }
286+ />
277287 </ Form >
278288 < SocialLinks isSignUp />
279289 </ Body >
0 commit comments