Created
July 17, 2017 20:49
-
-
Save silvawillian/f7f2350299b388dc4e390023b45c5048 to your computer and use it in GitHub Desktop.
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 from 'react'; | |
| import { StyleSheet, Text, View, TouchableOpacity, Image } from 'react-native'; | |
| import { Button, Grid, Row } from 'react-native-elements' | |
| import Swiper from 'react-native-swiper'; | |
| import SwipeableViews from 'react-swipeable-views-native'; | |
| export default class App extends React.Component { | |
| render() { | |
| return ( | |
| <View style={styles.container}> | |
| <Swiper showsButtons loop={false}> | |
| <View style={styles.slide1}> | |
| <Image source={{ uri: 'https://vignette2.wikia.nocookie.net/pokemon/images/b/b5/Rainbow_Badge.png/revision/latest?cb=20141009005938' }} style={{width: 100, height: 100}} /> | |
| <Text style={styles.headerText}>Rainbow Badge</Text> | |
| <Text style={styles.paragraphText}>The Rainbow Badge (レインボーバッジ) allows for the HM Strength to be used outside of battle. Additionally, it will allow for Pokémon up to level 50 to obey their Trainer.</Text> | |
| </View> | |
| <View style={styles.slide1}> | |
| <Image source={{ uri: 'https://vignette2.wikia.nocookie.net/pokemon/images/b/b5/Rainbow_Badge.png/revision/latest?cb=20141009005938' }} style={{width: 100, height: 100}} /> | |
| <Text style={styles.headerText}>Hello Swiper</Text> | |
| <Text style={styles.paragraphText}>Hello Swiper</Text> | |
| </View> | |
| <View style={styles.slide1}> | |
| <Image source={{ uri: 'https://vignette2.wikia.nocookie.net/pokemon/images/b/b5/Rainbow_Badge.png/revision/latest?cb=20141009005938' }} style={{width: 100, height: 100}} /> | |
| <Text style={styles.headerText}>Hello Swiper</Text> | |
| <Text style={styles.paragraphText}>Hello Swiper</Text> | |
| </View> | |
| </Swiper> | |
| <View style={styles.buttonsContainer}> | |
| <TouchableOpacity style={styles.button}> | |
| <Text style={{ fontWeight: 'bold', color: '#FFF' }}>LOG IN</Text> | |
| </TouchableOpacity> | |
| <TouchableOpacity style={styles.button}> | |
| <Text style={{ fontWeight: 'bold', color: '#FFF' }}>SIGN UP</Text> | |
| </TouchableOpacity> | |
| </View> | |
| </View> | |
| ); | |
| } | |
| } | |
| const styles = StyleSheet.create({ | |
| container: { | |
| backgroundColor: 'dodgerblue', | |
| flex: 1, | |
| paddingBottom: 24 | |
| }, | |
| buttonsContainer: { | |
| paddingTop: 16, | |
| bottom: 0, | |
| left: 0, | |
| right: 0, | |
| position: 'absolute', | |
| flexDirection: 'row', | |
| justifyContent: 'space-around', | |
| alignItems: 'center' | |
| }, | |
| button: { | |
| paddingLeft: 4, | |
| paddingRight: 4, | |
| backgroundColor: 'transparent', | |
| height: 48, | |
| width: 100, | |
| flex: 1, | |
| justifyContent: 'center', | |
| alignItems: 'center' | |
| }, | |
| slide1: { | |
| flex: 1, | |
| justifyContent: 'center', | |
| alignItems: 'center' | |
| }, | |
| slide2: { | |
| flex: 1, | |
| justifyContent: 'center', | |
| alignItems: 'center' | |
| }, | |
| slide3: { | |
| flex: 1, | |
| justifyContent: 'center', | |
| alignItems: 'center' | |
| }, | |
| headerText: { | |
| color: '#fff', | |
| fontSize: 30, | |
| fontWeight: 'bold', | |
| fontFamily: 'System' | |
| }, | |
| paragraphText: { | |
| color: '#fff', | |
| fontSize: 16, | |
| paddingLeft: 24, | |
| paddingTop: 8, | |
| paddingRight: 24, | |
| textAlign: 'center', | |
| fontFamily: 'System' | |
| } | |
| }); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment