Skip to content

Commit

Permalink
remove add headers
Browse files Browse the repository at this point in the history
  • Loading branch information
vuvnguyen95 committed Apr 23, 2024
1 parent 18d65f5 commit fcb11c3
Show file tree
Hide file tree
Showing 7 changed files with 6 additions and 19 deletions.
1 change: 0 additions & 1 deletion components/AddMeal.js
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,6 @@ const AddMeal = ({ route }) => {
<View style={{ width: 24 }} />
</View>
<ScrollView style={styles.container}>
<MealHeader onClose={() => handleclose()} />
<TextInput
testID="meal-name"
style={styles.input}
Expand Down
1 change: 0 additions & 1 deletion components/AddTask.js
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,6 @@ const CreateTaskScreen = ({ route }) => {
<View style={{ width: 24 }} />
</View>
<ScrollView style={styles.container}>
<Header onClose={() => navigation.goBack()} />
<TextInput
style={styles.input}
value={taskName}
Expand Down
1 change: 0 additions & 1 deletion components/AddWorkout.js
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,6 @@ const AddWorkout = ({ route }) => {
<View style={{ width: 24 }} />
</View>
<ScrollView style={styles.container}>
<WorkoutHeader onClose={() => handleClose()} />
<TextInput
testID="workout-name"
style={styles.input}
Expand Down
2 changes: 1 addition & 1 deletion components/Header.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ const Header = ({ onClose }) => {
const styles = getStyles(theme);
return (
<View style={styles.header}>
<Text style={styles.title}>Name</Text>
<Text style={styles.headerText}> </Text>
<TouchableOpacity onPress={onClose}>
<Text style={styles.closeButton}>×</Text>
</TouchableOpacity>
Expand Down
2 changes: 1 addition & 1 deletion components/MealHeader.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ const MealHeader = ({ onClose }) => {
const styles = getStyles(theme);
return (
<View style={styles.header}>
<Text style={styles.title}>Create Meal</Text>
<Text style={styles.title}> </Text>
<TouchableOpacity onPress={onClose}>
<Text style={styles.closeButton}>×</Text>
</TouchableOpacity>
Expand Down
10 changes: 0 additions & 10 deletions screens/EditTaskScreen.js
Original file line number Diff line number Diff line change
Expand Up @@ -124,16 +124,6 @@ const EditTaskScreen = ({ route, navigation }) => {
<Picker.Item label="High" value="high" />
</Picker>
</View>
<View style={styles.switchContainer}>
<Text style={styles.priorityText}>Task Completed:</Text>
<Switch
value={isCompleted}
onValueChange={(newVal) => {
setIsCompleted(newVal);
if (newVal) handleCompleteAndDeleteTask();
}}
/>
</View>
<CreateButton
onPress={handleUpdateTask}
label="Update Task"
Expand Down
8 changes: 4 additions & 4 deletions styles/DailyViewStyles.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ const getStyles = (theme) =>
fontSize: 16,
maxWidth: '50%', // Set the maxWidth to a value that works with your layout
marginRight: 10, // Add some margin to the right of the text
minWidth: '50%', // Set the minWidth to a value that works with your layout
minWidth: '50%', // Set the minWidth to a value that works with your layout
},
taskActions: {
flexDirection: 'row',
Expand Down Expand Up @@ -77,13 +77,13 @@ const getStyles = (theme) =>
alignItems: 'center',
},
completeButton: {
backgroundColor: '#20B2AA',
backgroundColor: 'green',
},
editButton: {
backgroundColor: '#778899',
backgroundColor: 'blue',
},
deleteButton: {
backgroundColor: '#FFA07A',
backgroundColor: 'red',
},
});

Expand Down

0 comments on commit fcb11c3

Please sign in to comment.