forked from tjhickey724/cs153aFall21
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathQuiz1a.js
63 lines (49 loc) · 1.81 KB
/
Quiz1a.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
import React from 'react';
import { StyleSheet, Text, View, Image, TextInput, Button } from 'react-native';
// const App = () => {...}
export default function App() {
return (
<View style={styles.container}>
<View style={{flex:1,backgroundColor:'yellow',}}>
<Text style={{fontSize:64}}>
Quiz 1a
</Text>
<Text>CS153a Fall21 </Text>
<Text>Write the code for this App, including the Quiz1a title and this text! The layout is five units high and 3 units wide</Text>
</View>
<View style={{flex:1,flexDirection:'row',
alignItems:'center',
justifyContent:'space-around'}}>
<Text> Choose your gift by pressing the button </Text>
<Button title="This is a big green button!" color="green"/>
</View>
<View style={{flex:3, flexDirection:'row',
backgroundColor:'lightgreen',
alignItems:'stretch',
justifyContent:'stretch'}}>
<Text style={{flex:1}}>lightgreen</Text>
<View style={{flex:1,flexDirection:'column'}}>
<View style={{flex:1, backgroundColor:'red'}}>
<Text>red</Text>
</View>
<View style={{flex:1, backgroundColor:'white'}}>
<Text>white</Text>
</View>
<View style={{flex:1, backgroundColor:'blue'}}>
<Text>blue</Text>
</View>
</View>
<Text style={{flex:1}}>lightgreen</Text>
</View>
</View>
);
}
const styles = StyleSheet.create({
container: {
flex: 1,
backgroundColor: '#fff',
alignItems: 'stretch',
justifyContent: 'stretch',
flexDirection:'column',
},
});