Skip to content

Commit c017178

Browse files
authored
Fix(#71):typographical errors (#79)
1 parent 6231c97 commit c017178

File tree

5 files changed

+23
-20
lines changed

5 files changed

+23
-20
lines changed

Diff for: app/auth/forgot-password.tsx

+2-2
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ export default function ResetPassword() {
4141
try {
4242
await resetMutation({
4343
variables: { email: values.email },
44-
onCompleted: (data) => {
44+
onCompleted: () => {
4545
toast.show('Check your email to proceed!', {
4646
type: 'success',
4747
placement: 'top',
@@ -98,7 +98,7 @@ export default function ResetPassword() {
9898
keyboardType="email-address"
9999
/>
100100
</View>
101-
{formik.touched.email && formik.errors.email && <Text className="mb-4 text-error-500">{t('')}</Text>}
101+
{formik.touched.email && formik.errors.email && <Text className="mb-4 text-error-500">{t('forgotPassword.errorEmail')}</Text>}
102102
<TouchableOpacity
103103
testID="submit-button"
104104
onPress={() => formik.handleSubmit()}

Diff for: components/Login/UserLogin.tsx

+15-15
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ export default function UserLogin({ onSubmit }: userLoginProps) {
4242
};
4343

4444
const formik = useFormik({
45-
initialValues: {} as FormValues,
45+
initialValues: {email: '', password: '' } as FormValues,
4646
onSubmit: async (values: FormValues) => {
4747
setLoading(true);
4848
await onSubmit(values);
@@ -94,25 +94,25 @@ export default function UserLogin({ onSubmit }: userLoginProps) {
9494
)}
9595
</View>
9696
<View>
97-
<Text className={`pl-2 ${textColor}`}>{t('userLogin.password')}</Text>
98-
<View
99-
className={`mt-2 relative flex items-center flex-row gap-3 border-2 border-[#D2D2D2] rounded-[10px] px-3 ${colorScheme === 'dark' ? 'bg-primary-dark' : 'bg-secondary-light-50'}`}
100-
>
101-
<Ionicons
97+
<Text className={`pl-2 pt-4 ${textColor}`}>{t('userLogin.password')}</Text>
98+
<View
99+
className={`mt-2 relative flex items-center flex-row gap-3 border-2 border-[#D2D2D2] rounded-[10px] px-3 ${colorScheme === 'dark' ? 'bg-primary-dark' : 'bg-secondary-light-50'}`}
100+
>
101+
<Ionicons
102102
name="lock-closed"
103103
className="py-4"
104104
size={20}
105105
color={colorScheme === 'dark' ? '#e5e7eb' : '#1f2937'}
106106
/>
107-
<TextInput
108-
placeholder={t('userLogin.password')}
109-
secureTextEntry={secureTextEntry}
110-
onChangeText={formik.handleChange('password')}
111-
onBlur={formik.handleBlur('password')}
112-
value={formik.values.password}
113-
placeholderTextColor={colorScheme == 'dark' ? '#e5e7eb' : '#1f2937'}
114-
className={`${colorScheme === 'dark' ? 'text-gray-100' : 'text-gray-800'} py-4 flex-1`}
115-
/>
107+
<TextInput
108+
className={`font-Inter-Regular flex-1 text-start ${colorScheme === 'dark' ? 'text-primary-light' : 'text-secondary-dark-400'}`}
109+
placeholder={t('userLogin.password')}
110+
placeholderTextColor={colorScheme === 'dark' ? '#FFFFFF' : '#9e9e9e'}
111+
secureTextEntry={secureTextEntry}
112+
onChangeText={formik.handleChange('password')}
113+
onBlur={formik.handleBlur('password')}
114+
value={formik.values.password}
115+
/>
116116

117117
<TouchableOpacity
118118
className=""

Diff for: internationalization/locales/en.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,8 @@
5959
"placeholder": "Enter Email",
6060
"submitButton": "Continue",
6161
"successMessage": "Password reset request successful! Please check your email for a link to reset your password!",
62-
"errorMessage": "An error occurred. Please try again."
62+
"errorMessage": "An error occurred. Please try again.",
63+
"errorEmail" : "Invalid Email"
6364
},
6465
"registerSchema": {
6566
"firstName": {

Diff for: internationalization/locales/fr.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,8 @@
5959
"placeholder": "Entrer l'email",
6060
"submitButton": "Continuer",
6161
"successMessage": "Demande de réinitialisation de mot de passe réussie! Veuillez vérifier votre email pour un lien pour réinitialiser votre mot de passe.",
62-
"errorMessage": "Une erreur s'est produite. Veuillez réessayer."
62+
"errorMessage": "Une erreur s'est produite. Veuillez réessayer.",
63+
"errorEmail" : "E-mail invalide"
6364
},
6465
"registerSchema": {
6566
"firstName": {

Diff for: internationalization/locales/kin.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,8 @@
5959
"placeholder": "Injiza imeri",
6060
"submitButton": "Komeza",
6161
"successMessage": "Gusaba gusubiramo ijambo ry'ibanga byakozwe neza! Nyamuneka reba imeri yawe kugirango usubiremo ijambo ry'ibanga.",
62-
"errorMessage": "Habaye ikibazo. Ongera ugerageze."
62+
"errorMessage": "Habaye ikibazo. Ongera ugerageze.",
63+
"errorEmail" : "Imeri itemewe"
6364
},
6465
"registerSchema": {
6566
"firstName": {

0 commit comments

Comments
 (0)