|
|
@ -6,13 +6,14 @@ import {SafeAreaProvider} from 'react-native-safe-area-context';
|
|
|
|
import ValidateButton from '../components/ValidateButton';
|
|
|
|
import ValidateButton from '../components/ValidateButton';
|
|
|
|
import ProfileSelection from '../components/ProfileSelection';
|
|
|
|
import ProfileSelection from '../components/ProfileSelection';
|
|
|
|
import FoodElementText from '../components/FoodElementText';
|
|
|
|
import FoodElementText from '../components/FoodElementText';
|
|
|
|
import ThemeContext from '../theme/ThemeContext';
|
|
|
|
import ColorContext from '../theme/ColorContext';
|
|
|
|
|
|
|
|
|
|
|
|
import bracketLeft from '../assets/images/angle_bracket_left.png';
|
|
|
|
import bracketLeft from '../assets/images/angle_bracket_left.png';
|
|
|
|
import bracketRight from '../assets/images/angle_bracket_right.png';
|
|
|
|
import bracketRight from '../assets/images/angle_bracket_right.png';
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
export default function HomePage({ navigation, props }) {
|
|
|
|
export default function HomePage({ navigation, props }) {
|
|
|
|
const {theme, toggleTheme} = useContext(ThemeContext);
|
|
|
|
const {colors, toggleColors} = useContext(ColorContext);
|
|
|
|
|
|
|
|
|
|
|
|
const profiles = [
|
|
|
|
const profiles = [
|
|
|
|
{name: "Johnny Silverhand", avatar: "plus_small.png", isActive: "flex"},
|
|
|
|
{name: "Johnny Silverhand", avatar: "plus_small.png", isActive: "flex"},
|
|
|
@ -69,12 +70,12 @@ export default function HomePage({ navigation, props }) {
|
|
|
|
},
|
|
|
|
},
|
|
|
|
filters: {
|
|
|
|
filters: {
|
|
|
|
fontSize: 20,
|
|
|
|
fontSize: 20,
|
|
|
|
color: '#ACA279',
|
|
|
|
color: colors.cardTitle,
|
|
|
|
flex: 1,
|
|
|
|
flex: 1,
|
|
|
|
},
|
|
|
|
},
|
|
|
|
nbSelected: {
|
|
|
|
nbSelected: {
|
|
|
|
fontSize: 11,
|
|
|
|
fontSize: 11,
|
|
|
|
color: "#3F3C42",
|
|
|
|
color: colors.cardDetail,
|
|
|
|
textAlign: "right",
|
|
|
|
textAlign: "right",
|
|
|
|
},
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
@ -82,7 +83,7 @@ export default function HomePage({ navigation, props }) {
|
|
|
|
alignItems: 'center',
|
|
|
|
alignItems: 'center',
|
|
|
|
justifyContent: 'center',
|
|
|
|
justifyContent: 'center',
|
|
|
|
borderRadius: 20,
|
|
|
|
borderRadius: 20,
|
|
|
|
backgroundColor: '#F2F0E4',
|
|
|
|
backgroundColor: colors.cardBackground,
|
|
|
|
marginHorizontal: "3%",
|
|
|
|
marginHorizontal: "3%",
|
|
|
|
paddingBottom: "3%",
|
|
|
|
paddingBottom: "3%",
|
|
|
|
},
|
|
|
|
},
|
|
|
@ -91,19 +92,19 @@ export default function HomePage({ navigation, props }) {
|
|
|
|
alignItems: 'center',
|
|
|
|
alignItems: 'center',
|
|
|
|
justifyContent: 'center',
|
|
|
|
justifyContent: 'center',
|
|
|
|
borderRadius: 20,
|
|
|
|
borderRadius: 20,
|
|
|
|
backgroundColor: '#F2F0E4',
|
|
|
|
backgroundColor: colors.cardBackground,
|
|
|
|
paddingVertical: "3%",
|
|
|
|
paddingVertical: "3%",
|
|
|
|
paddingHorizontal: "7%",
|
|
|
|
paddingHorizontal: "7%",
|
|
|
|
marginHorizontal: "3%",
|
|
|
|
marginHorizontal: "3%",
|
|
|
|
},
|
|
|
|
},
|
|
|
|
text: {
|
|
|
|
text: {
|
|
|
|
fontSize: 20,
|
|
|
|
fontSize: 20,
|
|
|
|
color: '#ACA279',
|
|
|
|
color: colors.welcomeText,
|
|
|
|
},
|
|
|
|
},
|
|
|
|
name: {
|
|
|
|
name: {
|
|
|
|
fontSize: 20,
|
|
|
|
fontSize: 20,
|
|
|
|
fontWeight: "bold",
|
|
|
|
fontWeight: "bold",
|
|
|
|
color: '#59BDCD',
|
|
|
|
color: colors.welcomeName,
|
|
|
|
},
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
ingredientSelection: {
|
|
|
|
ingredientSelection: {
|
|
|
@ -121,7 +122,7 @@ export default function HomePage({ navigation, props }) {
|
|
|
|
return (
|
|
|
|
return (
|
|
|
|
<SafeAreaProvider style={{flex: 1}}>
|
|
|
|
<SafeAreaProvider style={{flex: 1}}>
|
|
|
|
<ScrollView>
|
|
|
|
<ScrollView>
|
|
|
|
<LinearGradient colors={theme === 'light' ? ['#2680AA', '#59BDCD'] : ['#222222', '#3F3C42']} style={styles.linearGradient}>
|
|
|
|
<LinearGradient colors={[colors.primary, colors.primaryComplement]} style={styles.linearGradient}>
|
|
|
|
<View style={styles.separator}/>
|
|
|
|
<View style={styles.separator}/>
|
|
|
|
<View style={styles.welcome}>
|
|
|
|
<View style={styles.welcome}>
|
|
|
|
<View style={{flexDirection: "column", alignItems: "flex-start", justifyContent: "center", width: "100%"}}>
|
|
|
|
<View style={{flexDirection: "column", alignItems: "flex-start", justifyContent: "center", width: "100%"}}>
|
|
|
|