Skip to content

Commit 2e70fcf

Browse files
committed
I dont fucking know
1 parent f6a7d0e commit 2e70fcf

File tree

3 files changed

+199
-1
lines changed

3 files changed

+199
-1
lines changed

TAQ/screens/ClassQueue.jsx

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ import { SafeAreaView } from "react-native-safe-area-context";
1515
const ClassQueue = () => {
1616
return (
1717
<SafeAreaView style={styles.safeArea}>
18+
<View style={styles.safeArea}>
1819
<StatusBar
1920
barStyle={"light-content"}
2021
backgroundColor={"transparent"}
@@ -118,6 +119,7 @@ const ClassQueue = () => {
118119
/>
119120
<Text style={styles.addButtonText}>Add in Queue</Text>
120121
</Pressable>
122+
</View>
121123
</SafeAreaView>
122124
);
123125
};
@@ -128,6 +130,7 @@ const styles = StyleSheet.create({
128130
safeArea: {
129131
flex: 1,
130132
backgroundColor: Colors.Background,
133+
paddingTop: 40,
131134
},
132135
container: {
133136
padding: 10,
@@ -145,6 +148,7 @@ const styles = StyleSheet.create({
145148
padding: 10,
146149
gap: 20,
147150
borderColor: Colors.Primary,
151+
marginBottom: 20,
148152
},
149153
addButton: {
150154
flexDirection: "row",
@@ -165,6 +169,6 @@ const styles = StyleSheet.create({
165169
marginLeft: 8,
166170
},
167171
bottomSpacer: {
168-
height: 80, // Adjust height based on the space you want between the last item and the button
172+
height: 100, // Adjust height based on the space you want between the last item and the button
169173
},
170174
});

TAQ/screens/FeedbackForm.jsx

Lines changed: 78 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,78 @@
1+
import { StyleSheet, Text, View, TextInput, TouchableOpacity } from 'react-native'
2+
import React, { useState } from 'react'
3+
import { Colors } from '../config/Colors'
4+
5+
const FeedbackForm = () => {
6+
const [feedback, setFeedback] = useState('')
7+
8+
const handleSubmitFeedback = () => {
9+
// Add submit feedback functionality here
10+
console.log("Feedback:", feedback)
11+
}
12+
13+
return (
14+
<View style={styles.container}>
15+
<Text style={styles.header}>TA Feedback</Text>
16+
17+
<Text style={styles.label}>Your Feedback</Text>
18+
<TextInput
19+
style={[styles.input, styles.textArea]}
20+
placeholder="Optional feedback about TA's help"
21+
value={feedback}
22+
onChangeText={setFeedback}
23+
multiline
24+
/>
25+
26+
<TouchableOpacity style={styles.submitButton} onPress={handleSubmitFeedback}>
27+
<Text style={styles.submitButtonText}>Submit Feedback</Text>
28+
</TouchableOpacity>
29+
</View>
30+
)
31+
}
32+
33+
export default FeedbackForm
34+
35+
const styles = StyleSheet.create({
36+
container: {
37+
flex: 1,
38+
backgroundColor: Colors.Background,
39+
padding: 20,
40+
justifyContent: 'center',
41+
},
42+
header: {
43+
fontSize: 28,
44+
fontWeight: 'bold',
45+
color: Colors.Primary,
46+
marginBottom: 20,
47+
textAlign: 'center',
48+
},
49+
label: {
50+
fontSize: 16,
51+
fontWeight: '600',
52+
color: Colors.Primary,
53+
marginBottom: 8,
54+
},
55+
input: {
56+
borderWidth: 1,
57+
borderColor: Colors.Primary,
58+
padding: 10,
59+
borderRadius: 8,
60+
backgroundColor: '#fff',
61+
marginBottom: 20,
62+
},
63+
textArea: {
64+
height: 100,
65+
textAlignVertical: 'top',
66+
},
67+
submitButton: {
68+
backgroundColor: Colors.Blue,
69+
padding: 15,
70+
borderRadius: 8,
71+
alignItems: 'center',
72+
},
73+
submitButtonText: {
74+
color: '#fff',
75+
fontSize: 16,
76+
fontWeight: '600',
77+
},
78+
})

TAQ/screens/UserForm.jsx

Lines changed: 116 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,116 @@
1+
import { StyleSheet, Text, View, TextInput, TouchableOpacity, Keyboard, TouchableWithoutFeedback } from 'react-native'
2+
import React, { useState } from 'react'
3+
import DropDownPicker from 'react-native-dropdown-picker'
4+
import { Colors } from '../config/Colors'
5+
6+
const UserForm = () => {
7+
const [question, setQuestion] = useState('')
8+
const [open, setOpen] = useState(false)
9+
const [topic, setTopic] = useState("PA1")
10+
const [items, setItems] = useState([
11+
{ label: 'PA1', value: 'PA1' },
12+
{ label: 'PA2', value: 'PA2' },
13+
{ label: 'PA3', value: 'PA3' },
14+
{ label: 'PA4', value: 'PA4' },
15+
{ label: 'PA5', value: 'PA5' }
16+
])
17+
18+
const handleSubmit = () => {
19+
console.log("Topic:", topic, "Question:", question)
20+
}
21+
22+
return (
23+
<TouchableWithoutFeedback onPress={() => Keyboard.dismiss()}>
24+
<View style={styles.container}>
25+
<Text style={styles.header}>Ask a Question</Text>
26+
27+
<Text style={styles.label}>Topic</Text>
28+
<DropDownPicker
29+
open={open}
30+
value={topic}
31+
items={items}
32+
setOpen={setOpen}
33+
setValue={setTopic}
34+
setItems={setItems}
35+
placeholder="Select a topic"
36+
containerStyle={styles.dropdownContainer}
37+
style={styles.dropdown}
38+
dropDownContainerStyle={styles.dropdownContainerStyle}
39+
/>
40+
41+
<Text style={styles.label}>Question</Text>
42+
<TextInput
43+
style={[styles.input, styles.textArea]}
44+
placeholder="Enter your question"
45+
value={question}
46+
onChangeText={setQuestion}
47+
multiline
48+
returnKeyType="done"
49+
onSubmitEditing={() => Keyboard.dismiss()}
50+
/>
51+
52+
<TouchableOpacity style={styles.submitButton} onPress={handleSubmit}>
53+
<Text style={styles.submitButtonText}>Submit</Text>
54+
</TouchableOpacity>
55+
</View>
56+
</TouchableWithoutFeedback>
57+
)
58+
}
59+
60+
export default UserForm
61+
62+
const styles = StyleSheet.create({
63+
container: {
64+
flex: 1,
65+
backgroundColor: Colors.Background,
66+
padding: 20,
67+
justifyContent: 'center',
68+
},
69+
header: {
70+
fontSize: 28,
71+
fontWeight: 'bold',
72+
color: Colors.Primary,
73+
marginBottom: 20,
74+
textAlign: 'center',
75+
},
76+
label: {
77+
fontSize: 16,
78+
fontWeight: '600',
79+
color: Colors.Primary,
80+
marginBottom: 8,
81+
},
82+
dropdownContainer: {
83+
height: 50,
84+
marginBottom: 20,
85+
},
86+
dropdown: {
87+
backgroundColor: '#fff',
88+
borderColor: Colors.Primary,
89+
},
90+
dropdownContainerStyle: {
91+
backgroundColor: '#fafafa',
92+
},
93+
input: {
94+
borderWidth: 1,
95+
borderColor: Colors.Primary,
96+
padding: 10,
97+
borderRadius: 8,
98+
backgroundColor: '#fff',
99+
marginBottom: 20,
100+
},
101+
textArea: {
102+
height: 100,
103+
textAlignVertical: 'top',
104+
},
105+
submitButton: {
106+
backgroundColor: Colors.Blue,
107+
padding: 15,
108+
borderRadius: 8,
109+
alignItems: 'center',
110+
},
111+
submitButtonText: {
112+
color: '#fff',
113+
fontSize: 16,
114+
fontWeight: '600',
115+
},
116+
})

0 commit comments

Comments
 (0)