|
|
|
@ -20,6 +20,7 @@ import riceVegetable from '../assets/images/rice_vegetables.png';
|
|
|
|
|
import riceMeat from '../assets/images/Meat_and_Rice.png';
|
|
|
|
|
import riceFish from '../assets/images/rice_fish.png';
|
|
|
|
|
import riceEgg from '../assets/images/riceEgg.png';
|
|
|
|
|
import pasta from '../assets/images/pasta.png';
|
|
|
|
|
import ColorContext from '../theme/ColorContext';
|
|
|
|
|
import Recipes from '../Models/Recipes';
|
|
|
|
|
|
|
|
|
@ -51,7 +52,25 @@ export default function RecipeElement(props: RecipeElementProps) {
|
|
|
|
|
const eggDictionary: string[] = ["egg", "omelette"];
|
|
|
|
|
const soupDictionary: string[] = ["soup"];
|
|
|
|
|
const pizzaDictionary: string[] = ["pizza"];
|
|
|
|
|
const dessertDictionary: string[] = ['cake', 'cupcake', 'muffin', 'cookie', 'brownie', 'pie', 'tart', 'macaron', 'doughnut', 'eclair', 'pancake', 'waffle', 'crepe', 'pudding', 'gelato', 'sorbet', 'ice cream', 'cheesecake'];
|
|
|
|
|
const dessertDictionary: string[] = ['cake', 'cupcake', 'muffin', 'cookie', 'brownie', 'pie', 'tart', 'macaron', 'doughnut', 'eclair', 'pancake', 'waffle', 'crepe', 'pudding', 'gelato', 'sorbet', 'ice cream', 'cheesecake', 'sugar'];
|
|
|
|
|
const pastaDictionary: string[] = [
|
|
|
|
|
'pasta',
|
|
|
|
|
'spaghetti',
|
|
|
|
|
'penne',
|
|
|
|
|
'fettuccine',
|
|
|
|
|
'macaroni',
|
|
|
|
|
'rigatoni',
|
|
|
|
|
'farfalle',
|
|
|
|
|
'linguine',
|
|
|
|
|
'lasagne',
|
|
|
|
|
'ravioli',
|
|
|
|
|
'tortellini',
|
|
|
|
|
'gnocchi',
|
|
|
|
|
'spaetzle',
|
|
|
|
|
'noodles',
|
|
|
|
|
'spatzle',
|
|
|
|
|
'spatzen',
|
|
|
|
|
];
|
|
|
|
|
|
|
|
|
|
const imagesDictionary = {
|
|
|
|
|
meat: meatDictionary,
|
|
|
|
@ -63,6 +82,7 @@ export default function RecipeElement(props: RecipeElementProps) {
|
|
|
|
|
pizza : pizzaDictionary,
|
|
|
|
|
soup : soupDictionary,
|
|
|
|
|
dessert : dessertDictionary,
|
|
|
|
|
pasta : pastaDictionary,
|
|
|
|
|
unknown: [],
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
@ -126,6 +146,8 @@ export default function RecipeElement(props: RecipeElementProps) {
|
|
|
|
|
return fish;
|
|
|
|
|
case 'vegetables':
|
|
|
|
|
return vegan;
|
|
|
|
|
case 'pasta':
|
|
|
|
|
return pasta;
|
|
|
|
|
case 'MeatAndVegetables':
|
|
|
|
|
return meat_with_vegetable;
|
|
|
|
|
case 'FishAndMeat':
|
|
|
|
@ -222,7 +244,7 @@ export default function RecipeElement(props: RecipeElementProps) {
|
|
|
|
|
<View style={styles.view}>
|
|
|
|
|
<Text style={styles.text}>{props.recipe.id}</Text>
|
|
|
|
|
<Text style={styles.title}>{props.recipe.name}</Text>
|
|
|
|
|
<Image source={getImageForRecipe(props.recipe.name)} style={{width: 100, resizeMode: "contain"}}/>
|
|
|
|
|
<Image source={getImageForRecipe(props.recipe.name)} style={{width: 100, maxHeight: 90,resizeMode: "contain"}}/>
|
|
|
|
|
<View style={styles.horizontalAlignment}>
|
|
|
|
|
<Image source={Union_left} style={{width: "25%", marginRight: "3%", resizeMode: "contain"}} />
|
|
|
|
|
<Text style={styles.text}>Ingredients</Text>
|
|
|
|
|