Skip to content

Commit

Permalink
Fix(#71):typographical errors (#79)
Browse files Browse the repository at this point in the history
  • Loading branch information
Mbabazi12 authored Nov 1, 2024
1 parent 6231c97 commit c017178
Show file tree
Hide file tree
Showing 5 changed files with 23 additions and 20 deletions.
4 changes: 2 additions & 2 deletions app/auth/forgot-password.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ export default function ResetPassword() {
try {
await resetMutation({
variables: { email: values.email },
onCompleted: (data) => {
onCompleted: () => {
toast.show('Check your email to proceed!', {
type: 'success',
placement: 'top',
Expand Down Expand Up @@ -98,7 +98,7 @@ export default function ResetPassword() {
keyboardType="email-address"
/>
</View>
{formik.touched.email && formik.errors.email && <Text className="mb-4 text-error-500">{t('')}</Text>}
{formik.touched.email && formik.errors.email && <Text className="mb-4 text-error-500">{t('forgotPassword.errorEmail')}</Text>}
<TouchableOpacity
testID="submit-button"
onPress={() => formik.handleSubmit()}
Expand Down
30 changes: 15 additions & 15 deletions components/Login/UserLogin.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ export default function UserLogin({ onSubmit }: userLoginProps) {
};

const formik = useFormik({
initialValues: {} as FormValues,
initialValues: {email: '', password: '' } as FormValues,
onSubmit: async (values: FormValues) => {
setLoading(true);
await onSubmit(values);
Expand Down Expand Up @@ -94,25 +94,25 @@ export default function UserLogin({ onSubmit }: userLoginProps) {
)}
</View>
<View>
<Text className={`pl-2 ${textColor}`}>{t('userLogin.password')}</Text>
<View
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'}`}
>
<Ionicons
<Text className={`pl-2 pt-4 ${textColor}`}>{t('userLogin.password')}</Text>
<View
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'}`}
>
<Ionicons
name="lock-closed"
className="py-4"
size={20}
color={colorScheme === 'dark' ? '#e5e7eb' : '#1f2937'}
/>
<TextInput
placeholder={t('userLogin.password')}
secureTextEntry={secureTextEntry}
onChangeText={formik.handleChange('password')}
onBlur={formik.handleBlur('password')}
value={formik.values.password}
placeholderTextColor={colorScheme == 'dark' ? '#e5e7eb' : '#1f2937'}
className={`${colorScheme === 'dark' ? 'text-gray-100' : 'text-gray-800'} py-4 flex-1`}
/>
<TextInput
className={`font-Inter-Regular flex-1 text-start ${colorScheme === 'dark' ? 'text-primary-light' : 'text-secondary-dark-400'}`}
placeholder={t('userLogin.password')}
placeholderTextColor={colorScheme === 'dark' ? '#FFFFFF' : '#9e9e9e'}
secureTextEntry={secureTextEntry}
onChangeText={formik.handleChange('password')}
onBlur={formik.handleBlur('password')}
value={formik.values.password}
/>

<TouchableOpacity
className=""
Expand Down
3 changes: 2 additions & 1 deletion internationalization/locales/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,8 @@
"placeholder": "Enter Email",
"submitButton": "Continue",
"successMessage": "Password reset request successful! Please check your email for a link to reset your password!",
"errorMessage": "An error occurred. Please try again."
"errorMessage": "An error occurred. Please try again.",
"errorEmail" : "Invalid Email"
},
"registerSchema": {
"firstName": {
Expand Down
3 changes: 2 additions & 1 deletion internationalization/locales/fr.json
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,8 @@
"placeholder": "Entrer l'email",
"submitButton": "Continuer",
"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.",
"errorMessage": "Une erreur s'est produite. Veuillez réessayer."
"errorMessage": "Une erreur s'est produite. Veuillez réessayer.",
"errorEmail" : "E-mail invalide"
},
"registerSchema": {
"firstName": {
Expand Down
3 changes: 2 additions & 1 deletion internationalization/locales/kin.json
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,8 @@
"placeholder": "Injiza imeri",
"submitButton": "Komeza",
"successMessage": "Gusaba gusubiramo ijambo ry'ibanga byakozwe neza! Nyamuneka reba imeri yawe kugirango usubiremo ijambo ry'ibanga.",
"errorMessage": "Habaye ikibazo. Ongera ugerageze."
"errorMessage": "Habaye ikibazo. Ongera ugerageze.",
"errorEmail" : "Imeri itemewe"
},
"registerSchema": {
"firstName": {
Expand Down

0 comments on commit c017178

Please sign in to comment.