@@ -39,7 +39,7 @@ struct LoginScreen: View {
3939 Spacer ( )
4040 . frame ( maxHeight: 16 )
4141
42- TextField ( " Username " , text: $loginState. username)
42+ TextField ( String ( localized : " auth.field.username " ) , text: $loginState. username)
4343 . textInputAutocapitalization ( . none)
4444 . padding ( )
4545 . background ( Color . background)
@@ -49,7 +49,7 @@ struct LoginScreen: View {
4949 . stroke ( Color . background. opacity ( 0.5 ) , lineWidth: 1 )
5050 )
5151
52- SecureField ( " Password " , text: $loginState. password)
52+ SecureField ( String ( localized : " auth.field.password " ) , text: $loginState. password)
5353 . padding ( )
5454 . background ( Color . background)
5555 . clipShape ( RoundedRectangle ( cornerRadius: 12 ) )
@@ -59,16 +59,16 @@ struct LoginScreen: View {
5959 )
6060
6161 if loginState. showError {
62- Text ( " Invalid username or password " )
62+ Text ( " auth.error.invalidCredentials " )
6363 . foregroundColor ( . red)
6464 . font ( . ibmPlexMono( . regular, size: 14 ) )
6565 }
6666
6767
6868 HStack ( spacing: 0 ) {
69- Text ( " By signing in, you agree to the " )
69+ Text ( " auth.agreement.prefix " )
7070 . font ( . ibmPlexSans( . regular, size: 12 ) )
71- Text ( " Hacker News Guidelines " )
71+ Text ( " auth.agreement.guidelines " )
7272 . font ( . ibmPlexSans( . regular, size: 12 ) )
7373 . foregroundColor ( . blue)
7474 . underline ( )
@@ -97,7 +97,7 @@ struct LoginScreen: View {
9797 }
9898 } ,
9999 label: {
100- Text ( " Submit " )
100+ Text ( " auth.button.submit " )
101101 . font ( . ibmPlexMono( . bold, size: 16 ) )
102102 . frame ( maxWidth: . infinity)
103103 . frame ( height: 40 )
0 commit comments