From 8b5279ce15820b48b3557e49904bb736ca53e4d3 Mon Sep 17 00:00:00 2001 From: Samuel Newman Date: Tue, 19 Mar 2024 21:10:31 +0000 Subject: [PATCH] animate login spinner --- package.json | 3 ++- src/screens/Login/LoginForm.tsx | 3 +++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/package.json b/package.json index 97fd91b0..b664dd22 100644 --- a/package.json +++ b/package.json @@ -312,5 +312,6 @@ }, "lint-staged": { "*{.js,.jsx,.ts,.tsx}": "yarn eslint --fix" - } + }, + "packageManager": "yarn@1.22.19+sha1.4ba7fc5c6e704fce2066ecbfb0b0d8976fe62447" } diff --git a/src/screens/Login/LoginForm.tsx b/src/screens/Login/LoginForm.tsx index eddcc967..e9620db5 100644 --- a/src/screens/Login/LoginForm.tsx +++ b/src/screens/Login/LoginForm.tsx @@ -2,6 +2,7 @@ import React, {useState, useRef} from 'react' import { ActivityIndicator, Keyboard, + LayoutAnimation, TextInput, TouchableOpacity, View, @@ -67,6 +68,7 @@ export const LoginForm = ({ const onPressNext = async () => { if (isProcessing) return Keyboard.dismiss() + LayoutAnimation.configureNext(LayoutAnimation.Presets.easeInEaseOut) setError('') setIsProcessing(true) @@ -101,6 +103,7 @@ export const LoginForm = ({ }) } catch (e: any) { const errMsg = e.toString() + LayoutAnimation.configureNext(LayoutAnimation.Presets.easeInEaseOut) setIsProcessing(false) if (errMsg.includes('Authentication Required')) { logger.debug('Failed to login due to invalid credentials', {