Created
May 16, 2018 15:44
-
-
Save hinata4zzahra/eaa2b0b601c4e165ecd691b2eddbecb5 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React, {Component} from 'react' | |
import { | |
Form, Item, Button, | |
Text, Label, Input, Icon | |
} from 'native-base' | |
import {StyleSheet} from 'react-native' | |
import {Field, reduxForm} from 'redux-form' | |
import {LkTextInput, LkPicker} from 'lazy-kitten-redux-form' | |
class LoginForm extends Component{ | |
render(){ | |
const {handleSubmit} = this.props | |
return( | |
<Form> | |
<Field component={LkTextInput} name="username" label="Username" style={{backgroundColor:'white',opacity:0.5, paddingLeft:10}} /> | |
<Field component={LkTextInput} name="password" label="Password" style={{backgroundColor:'white',opacity:0.5,paddingLeft:10}} /> | |
<Button style={styles.button}> | |
<Text>LOGIN</Text> | |
</Button> | |
</Form> | |
) | |
} | |
} | |
export default reduxForm({ | |
form:'login', | |
}) (LoginForm) | |
const styles= StyleSheet.create({ | |
button: { | |
height: 40, | |
width: 300, | |
marginTop:10, | |
borderColor: '#f9fafc', | |
borderRadius: 100, | |
alignSelf: 'center', | |
zIndex: 99, | |
justifyContent:'center', | |
alignItems:'center', | |
backgroundColor:"#29bc8b" | |
}, | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment