BetinaUKTC

paste

Nov 2nd, 2022
99
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.50 KB | None | 0 0
  1. import { StatusBar } from 'expo-status-bar';
  2. import { TouchableOpacity, Image, StyleSheet, Text, View, ScrollView, Dimensions, Button } from 'react-native';
  3.  
  4. const { width } = Dimensions.get("window");
  5. const height = width;
  6. const images = [
  7. require('./assets/landing/girl1.png'),
  8. require('./assets/landing/girl2.png'),
  9. require('./assets/landing/girl3.png'),
  10. ]
  11.  
  12. export default function App() {
  13. return (
  14. <View style={{ marginTop: 50, width, height }}>
  15. <StatusBar style="auto" />
  16. <ScrollView pageEnabled horizontal style={{ width, height }} showsHorizontalScrollIndicator={false}>
  17. <Image source={images[2]} style={{ resizeMode: 'cover', marginLeft: -200 }} />
  18. {
  19. images.map((item, index) => (
  20. <Image key={index} source={item} style={styles.images} />
  21. ))
  22. }
  23. <Image source={images[0]} style={{ resizeMode: 'cover', marginLeft: 50 }} />
  24. </ScrollView>
  25.  
  26.  
  27. <TouchableOpacity style={styles.button} >
  28. <Text style={{ color: 'white', fontWeight: '500', fontSize: 16 }}> Create an account </Text>
  29. </TouchableOpacity>
  30. </View>
  31. );
  32. }
  33.  
  34. const styles = StyleSheet.create({
  35. images: {
  36. resizeMode: 'cover',
  37. marginLeft: 50
  38. },
  39.  
  40. button: {
  41. width: 295,
  42. height: 55,
  43. backgroundColor: '#E94057',
  44. color: 'white',
  45. borderRadius: 15,
  46. alignSelf: 'center',
  47. alignItems: 'center',
  48. justifyContent: 'center',
  49. position: 'relative',
  50. top: 220,
  51. }
  52. });
  53.  
Advertisement
Add Comment
Please, Sign In to add comment