loading on login

This commit is contained in:
Guilherme Gazzo 2017-11-19 00:30:09 -02:00
parent fe9a1ebeaa
commit 3dbd70b42b
1 changed files with 2 additions and 1 deletions

View File

@ -1,6 +1,6 @@
import React from 'react';
// import Spinner from 'react-native-loading-spinner-overlay';
import Spinner from 'react-native-loading-spinner-overlay';
import PropTypes from 'prop-types';
import { Keyboard, Text, TextInput, View, TouchableOpacity, SafeAreaView } from 'react-native';
@ -143,6 +143,7 @@ class LoginView extends React.Component {
</TouchableOpacity>
{this.props.login.failure && <Text style={styles.error}>{this.props.login.error.reason}</Text>}
</View>
<Spinner visible={this.props.login.isFetching} textContent='Loading...' textStyle={{ color: '#FFF' }} />
</SafeAreaView>
</View>
</KeyboardView>