@@ -66,7 +66,7 @@ export function Login() {
6666 const [ password1 , setPassword1 ] = useState ( '' ) ;
6767 const [ password2 , setPassword2 ] = useState ( '' ) ;
6868 const [ responseMsg , setResponseMsg ] = useState ( '' ) ;
69- const [ activeTab , setActiveTab ] = useState ( 0 ) ;
69+ const [ activeTab , setActiveTab ] = useState ( 0 ) ;
7070
7171 const handleChangeUsername : ChangeEventHandler < HTMLInputElement > = ( event ) => {
7272 setUserName ( event . currentTarget . value as string ) ;
@@ -155,8 +155,8 @@ export function Login() {
155155 return ( < Dialog open = { globalLoginModal } onClose = { handleClose } className = "backDrop" >
156156 < DialogContent >
157157 < Tabs value = { activeTab } onChange = { handleTabChange } aria-label = "basic tabs example" >
158- < Tab label = "Login" { ...a11yProps ( 0 ) } />
159- < Tab label = "Singin" { ...a11yProps ( 1 ) } />
158+ < Tab label = { t ( 'login.login' ) } { ...a11yProps ( 0 ) } />
159+ < Tab label = { t ( 'login.signin' ) } { ...a11yProps ( 1 ) } />
160160 </ Tabs >
161161 < TabPanel value = { activeTab } index = { 0 } >
162162 < Box
@@ -171,7 +171,7 @@ export function Login() {
171171 value = { userName }
172172 onChange = { handleChangeUsername }
173173 id = "userName"
174- label = "user name"
174+ label = { t ( 'login.username' ) }
175175 type = "string"
176176 fullWidth
177177 variant = "standard"
@@ -182,7 +182,7 @@ export function Login() {
182182 value = { password1 }
183183 onChange = { handleChangePassword1 }
184184 id = "password1"
185- label = " password"
185+ label = { t ( 'login. password' ) }
186186 type = "password"
187187 fullWidth
188188 variant = "standard"
@@ -193,7 +193,7 @@ export function Login() {
193193 </ div >
194194 < div className = { styles . responseMsg } >
195195 { [ responseMsg ] . filter ( value => ! ! value ) . map ( ( value , index ) =>
196- < span key = { index } > Message : { value } </ span >
196+ < span key = { index } > { t ( 'common.message' ) } : { value } </ span >
197197 ) }
198198 </ div >
199199 </ Box >
@@ -211,7 +211,7 @@ export function Login() {
211211 value = { userName }
212212 onChange = { handleChangeUsername }
213213 id = "userName"
214- label = "user name"
214+ label = { t ( 'login.username' ) }
215215 type = "string"
216216 fullWidth
217217 variant = "standard"
@@ -222,7 +222,7 @@ export function Login() {
222222 value = { password1 }
223223 onChange = { handleChangePassword1 }
224224 id = "password1"
225- label = " password"
225+ label = { t ( 'login. password' ) }
226226 type = "password"
227227 fullWidth
228228 variant = "standard"
@@ -233,18 +233,18 @@ export function Login() {
233233 value = { password2 }
234234 onChange = { handleChangePassword2 }
235235 id = "password2"
236- label = " password"
236+ label = { t ( 'login. password' ) }
237237 type = "password"
238238 fullWidth
239239 variant = "standard"
240240 />
241241 < div >
242- < Button type = "submit" > Ok </ Button >
243- < Button onClick = { handleCancel } > Cancel </ Button >
242+ < Button type = "submit" > { t ( 'common.ok' ) } </ Button >
243+ < Button onClick = { handleCancel } > { t ( 'common.cancel' ) } </ Button >
244244 </ div >
245245 < div className = { styles . responseMsg } >
246246 { [ responseMsg ] . filter ( value => ! ! value ) . map ( ( value , index ) =>
247- < span key = { index } > Message : { value } </ span >
247+ < span key = { index } > { t ( 'common.message' ) } : { value } </ span >
248248 ) }
249249 </ div >
250250 </ Box >
0 commit comments