Created
July 4, 2018 11:56
-
-
Save behrends/8f8c2496bc7fc5509bac97d7186ab5ae to your computer and use it in GitHub Desktop.
13:55 - Modal mit TextInputs
This file contains hidden or 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 { Modal, StyleSheet, Text, TextInput, View } from 'react-native'; | |
| export default class NewQuote extends Component { | |
| render() { | |
| return ( | |
| <Modal | |
| visible={this.props.visible} | |
| onRequestClose={this.props.onRequestClose} | |
| > | |
| <View style={styles.container}> | |
| <TextInput | |
| style={[styles.input, { height: '25%' }]} | |
| placeholder="Zitat eingeben" | |
| underlineColorAndroid="transparent" | |
| /> | |
| <TextInput | |
| style={styles.input} | |
| placeholder="Autor" | |
| underlineColorAndroid="transparent" | |
| /> | |
| </View> | |
| </Modal> | |
| ); | |
| } | |
| } | |
| const styles = StyleSheet.create({ | |
| container: { | |
| flex: 1, | |
| justifyContent: 'flex-start', | |
| alignItems: 'center', | |
| paddingTop: 40 | |
| }, | |
| input: { | |
| fontSize: 20, | |
| borderWidth: 1, | |
| borderColor: 'deepskyblue', | |
| borderRadius: 4, | |
| height: 50, | |
| width: '80%', | |
| marginBottom: 20, | |
| padding: 10 | |
| } | |
| }); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment