Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

styling!! #61

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 8 additions & 3 deletions components/UserIcon.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,15 @@ import {
import { fonts, colors } from '../constants/GlobalStyles';

const UserIcon = (props) => {
const { user, size } = props;
const {
user, size, fontsize, fontcolor,
} = props;
return (
<View style={[styles.container, { backgroundColor: user.iconColor, height: size, width: size }]}>
<Text key={user.firstName}>{`${user.firstName[0]}${user.lastName[0]}`}</Text>
<View style={[styles.container, {
backgroundColor: user.iconColor, height: size, width: size,
}]}
>
<Text key={user.firstName} style={{ fontSize: fontsize, color: fontcolor }}>{`${user.firstName[0]}${user.lastName[0]}` }</Text>
</View>
);
};
Expand Down
3 changes: 3 additions & 0 deletions constants/GlobalStyles.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,17 @@ export const colors = {
mediumSageGreen: '#C6DAC9',
indigo300: '#C7C6E1',
indigo700: '#2E2D4D',
indigo500: '#5D5B9A',
lightGray: '#F4F5F4',
loginGreen: '#57805B',
backgroundGray: '#F2F2F2',
iconYellow: '#FFCD3D',
};

export const fonts = {
largeText: 20,
smallText: 16,
large24: 24,
large22: 22,
iconFont: 37,
};
1 change: 1 addition & 0 deletions screens/CalendarScreen.js
Original file line number Diff line number Diff line change
Expand Up @@ -282,6 +282,7 @@ const styles = StyleSheet.create({
color: colors.darkSageGreen,
marginBottom: 10,
marginTop: 10,
fontWeight: 'bold',
},
empty_title: {
fontSize: fonts.large24,
Expand Down
10 changes: 6 additions & 4 deletions screens/RequestScreen.js
Original file line number Diff line number Diff line change
Expand Up @@ -52,10 +52,11 @@ const RequestScreen = (props) => {
<View style={{ flexDirection: 'row', justifyContent: 'space-between' }}>
<Text style={styles.title}>Requests</Text>
<TouchableOpacity
style={styles.newEvent}
style={styles.empty_addButton}
onPress={() => setShowModal(!showModal)}
>
<Text style={styles.plus}>+</Text>
<Text style={{ color: '#FFFFFF', fontSize: 40 }}>+</Text>

</TouchableOpacity>
</View>

Expand Down Expand Up @@ -108,8 +109,8 @@ const styles = StyleSheet.create({
marginBottom: 3,
},
empty_addButton: {
backgroundColor: colors.darkSageGreen,
borderRadius: 20,
backgroundColor: colors.indigo700,
borderRadius: 25,
width: 50,
height: 50,
alignItems: 'center',
Expand All @@ -131,6 +132,7 @@ const styles = StyleSheet.create({
color: colors.indigo700,
marginLeft: 20,
},

newEvent: {
backgroundColor: colors.indigo700,
borderRadius: 20,
Expand Down
14 changes: 7 additions & 7 deletions screens/SettingsScreen.js
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ const SettingsScreen = (props) => {
return (
<SafeAreaView>
<View style={styles.subContainer}>
<UserIcon key={user.id} user={user} size={90}> </UserIcon>
<UserIcon key={user.id} user={user} size={90} fontsize={fonts.iconFont}> </UserIcon>
</View>
<View style={styles.subContainer}>
<Text style={styles.text}>First Name</Text>
Expand All @@ -88,21 +88,21 @@ const SettingsScreen = (props) => {
<View style={styles.colorPicker}>
{showXDarkPurple
? (
<TouchableOpacity style={styles.buttonDarkPurple} onPress={() => setnewIconColor(colors.indigo700)}>
<TouchableOpacity style={styles.buttonDarkPurple} onPress={() => setnewIconColor(colors.indigo500)}>
<Text style={{ textAlign: 'center', fontSize: 30 }}>X</Text>
</TouchableOpacity>
)
: (
<TouchableOpacity style={styles.buttonDarkPurple} onPress={() => { setnewIconColor(colors.indigo700); setshowXDarkPurple(true); setShowXYellow(false); setshowXLightPurple(false); }} />
<TouchableOpacity style={styles.buttonDarkPurple} onPress={() => { setnewIconColor(colors.indigo500); setshowXDarkPurple(true); setShowXYellow(false); setshowXLightPurple(false); }} />
)}
{showXYellow
? (
<TouchableOpacity style={styles.buttonYellow} onPress={() => setnewIconColor('#FFFF00')}>
<TouchableOpacity style={styles.buttonYellow} onPress={() => setnewIconColor(colors.iconYellow)}>
<Text style={{ textAlign: 'center', fontSize: 30 }}>X</Text>
</TouchableOpacity>
)
: (
<TouchableOpacity style={styles.buttonYellow} onPress={() => { setnewIconColor('#FFFF00'); setshowXDarkPurple(false); setShowXYellow(true); setshowXLightPurple(false); }} />
<TouchableOpacity style={styles.buttonYellow} onPress={() => { setnewIconColor(colors.iconYellow); setshowXDarkPurple(false); setShowXYellow(true); setshowXLightPurple(false); }} />
)}
{showXLightPurple
? (
Expand Down Expand Up @@ -169,7 +169,7 @@ const styles = StyleSheet.create({
height: 30,
width: 30,
marginHorizontal: 10,
backgroundColor: 'purple',
backgroundColor: colors.indigo500,
justifyContent: 'center',
},
buttonLightPurple: {
Expand All @@ -182,7 +182,7 @@ const styles = StyleSheet.create({
height: 30,
width: 30,
marginHorizontal: 10,
backgroundColor: '#FFFF00',
backgroundColor: colors.iconYellow,
justifyContent: 'center',
},
});
Expand Down