end MyRecipes page

pull/31/head
maxime.BATISTA@etu.uca.fr 2 years ago
commit f1dcd519e2

1
.gitignore vendored

@ -6,6 +6,7 @@ obj/
#locks and backup
.~*
ShoopNCook - Backup*
.nuspec/
.buildtasks/

@ -4,45 +4,50 @@
xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
xmlns:local="clr-namespace:ShoopNCook"
xmlns:views="clr-namespace:ShoopNCook.Views"
xmlns:pages="clr-namespace:ShoopNCook.Pages"
Shell.FlyoutBehavior="Disabled"
Shell.NavBarIsVisible="False">
<TabBar>
<ShellContent
Title="Login Page"
ContentTemplate="{DataTemplate views:LoginPage}"
ContentTemplate="{DataTemplate pages:LoginPage}"
Route="Login" />
<ShellContent
Title="Profile Page"
ContentTemplate="{DataTemplate views:ProfilePage}"
ContentTemplate="{DataTemplate pages:ProfilePage}"
Route="Profile" />
<ShellContent
Title="Search Page"
ContentTemplate="{DataTemplate views:SearchPage}"
ContentTemplate="{DataTemplate pages:SearchPage}"
Route="Search" />
<ShellContent
Title="More Page"
ContentTemplate="{DataTemplate pages:MorePage}"
Route="More"/>
<ShellContent
Title="Register Page"
ContentTemplate="{DataTemplate views:RegisterPage}"
Route="Register" />
ContentTemplate="{DataTemplate pages:RegisterPage}"
Route="Register"/>
<ShellContent
Title="Recipe Page"
ContentTemplate="{DataTemplate views:RecipePage}"
ContentTemplate="{DataTemplate pages:RecipePage}"
Route="Recipe" />
<ShellContent
Title="Favorites Page"
ContentTemplate="{DataTemplate views:FavoritesPage}"
ContentTemplate="{DataTemplate pages:FavoritesPage}"
Route="Favorites" />
<ShellContent
Title="My Recipes Page"
ContentTemplate="{DataTemplate views:MyRecipesPage}"
ContentTemplate="{DataTemplate pages:MyRecipesPage}"
Route="MyRecipes" />
</TabBar>
</Shell>

@ -15,6 +15,7 @@ public static class MauiProgram
fonts.AddFont("OpenSans-Semibold.ttf", "OpenSansSemibold");
fonts.AddFont("Poppins-Bold.ttf", "PoppinsBold");
fonts.AddFont("Poppins-Medium.ttf", "PoppinsMedium");
fonts.AddFont("Poppins-Regular.ttf", "Poppins");
});
#if DEBUG

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8" ?>
<ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
x:Class="ShoopNCook.Views.FavoritesPage"
x:Class="ShoopNCook.Pages.FavoritesPage"
Title="FavoritesPage"
xmlns:views="clr-namespace:ShoopNCook.Views"
BackgroundColor="{StaticResource BackgroundPrimary}">

@ -0,0 +1,9 @@
namespace ShoopNCook.Pages;
public partial class FavoritesPage : ContentPage
{
public FavoritesPage()
{
InitializeComponent();
}
}

@ -1,144 +1,144 @@
<?xml version="1.0" encoding="utf-8" ?>
<ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
x:Class="ShoopNCook.Views.LoginPage"
Title="Login"
BackgroundColor="{StaticResource BackgroundPrimary}">
<VerticalStackLayout
Margin="20, 75, 20, 20">
<Label
FontFamily="PoppinsBold"
Text="Welcome Back!"
FontSize="32"
TextColor="{StaticResource TextColorPrimary}"
FontAttributes="Bold"
VerticalOptions="Start"
HorizontalOptions="Start" />
<Label
Text="Fill in your credentials or continue with social media"
FontFamily="PoppinsBold"
FontSize="20"
TextColor="{StaticResource TextColorSecondary}"
VerticalOptions="Start"
HorizontalOptions="Start" />
<Border
Style="{StaticResource SecondaryBorderShadow}"
Margin="0,30,0,20">
<Grid
Padding="5"
BackgroundColor="{StaticResource BackgroundSecondary}"
ColumnDefinitions="Auto,Auto,*">
<Image
Grid.Column="1"
Source="email_icon.svg">
</Image>
<Entry
Style="{StaticResource UserInput}"
Grid.Column="2"
Placeholder="Mail address"/>
</Grid>
</Border>
<Border
Style="{StaticResource SecondaryBorderShadow}"
>
<Grid
Padding="5"
BackgroundColor="{StaticResource BackgroundSecondary}"
ColumnDefinitions="Auto,Auto,*,Auto">
<Image
Grid.Column="1"
Source="password_icon.svg">
</Image>
<Entry
Style="{StaticResource UserInput}"
Grid.Column="2"
Placeholder="Password"/>
<ImageButton
Grid.Column="3"
Source="visibility_off.svg"
HeightRequest="30">
</ImageButton>
</Grid>
</Border>
<Label
TextColor="{StaticResource TextColorSecondary}"
HorizontalOptions="End"
Text="Forgot Password ?"
BackgroundColor="Transparent"/>
<Border
Margin="0, 30, 0, 0"
Stroke="{StaticResource BackgroundPrimary}"
StrokeShape="RoundRectangle 12">
<Button
BackgroundColor="{StaticResource Selected}"
FontFamily="PoppinsMedium"
TextColor="{StaticResource ButtonText}"
Text="LOG IN"/>
</Border>
<HorizontalStackLayout
HorizontalOptions="Center"
Margin="0, 20, 0, 0"
Spacing="6">
<Rectangle
BackgroundColor="Gray"
WidthRequest="15"
HeightRequest="3"/>
<Label
TextColor="{StaticResource TextColorSecondary}">
Or continue with</Label>
<Rectangle
BackgroundColor="Gray"
WidthRequest="15"
HeightRequest="3"/>
</HorizontalStackLayout>
<HorizontalStackLayout
Margin="0, 20, 0, 0"
Spacing="15"
HorizontalOptions="Center">
<Border
HeightRequest="75"
WidthRequest="75"
BackgroundColor="#e9f4ff"
StrokeShape="RoundRectangle 25 25 25 25"
Stroke="{StaticResource BackgroundPrimary}">
<Image
HeightRequest="50"
Source="google_logo.svg"/>
</Border>
<Border
HeightRequest="75"
WidthRequest="75"
BackgroundColor="#4460a0"
StrokeShape="RoundRectangle 25 25 25 25"
Stroke="{StaticResource BackgroundPrimary}">
<Image
WidthRequest="40"
Source="facebook_logo.svg"/>
</Border>
</HorizontalStackLayout>
<HorizontalStackLayout
Spacing="4"
HorizontalOptions="Center"
Margin="0, 20, 0, 0">
<Label
TextColor="{StaticResource TextColorPrimary}">
New User?</Label>
<Label
FontAttributes="Bold"
TextColor="{StaticResource TextColorPrimary}">
Create Account</Label>
</HorizontalStackLayout>
</VerticalStackLayout>
<?xml version="1.0" encoding="utf-8" ?>
<ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
x:Class="ShoopNCook.Pages.LoginPage"
Title="Login"
BackgroundColor="{StaticResource BackgroundPrimary}">
<VerticalStackLayout
Margin="20, 75, 20, 20">
<Label
FontFamily="PoppinsBold"
Text="Welcome Back!"
FontSize="32"
TextColor="{StaticResource TextColorPrimary}"
FontAttributes="Bold"
VerticalOptions="Start"
HorizontalOptions="Start" />
<Label
Text="Fill in your credentials or continue with social media"
FontFamily="PoppinsBold"
FontSize="20"
TextColor="{StaticResource TextColorSecondary}"
VerticalOptions="Start"
HorizontalOptions="Start" />
<Border
Style="{StaticResource SecondaryBorderShadow}"
Margin="0,30,0,20">
<Grid
Padding="5"
BackgroundColor="{StaticResource BackgroundSecondary}"
ColumnDefinitions="Auto,Auto,*">
<Image
Grid.Column="1"
Source="email_icon.svg">
</Image>
<Entry
Style="{StaticResource UserInput}"
Grid.Column="2"
Placeholder="Mail address"/>
</Grid>
</Border>
<Border
Style="{StaticResource SecondaryBorderShadow}"
>
<Grid
Padding="5"
BackgroundColor="{StaticResource BackgroundSecondary}"
ColumnDefinitions="Auto,Auto,*,Auto">
<Image
Grid.Column="1"
Source="password_icon.svg">
</Image>
<Entry
Style="{StaticResource UserInput}"
Grid.Column="2"
Placeholder="Password"/>
<ImageButton
Grid.Column="3"
Source="visibility_off.svg"
HeightRequest="30">
</ImageButton>
</Grid>
</Border>
<Label
TextColor="{StaticResource TextColorSecondary}"
HorizontalOptions="End"
Text="Forgot Password ?"
BackgroundColor="Transparent"/>
<Border
Margin="0, 30, 0, 0"
Stroke="{StaticResource BackgroundPrimary}"
StrokeShape="RoundRectangle 12">
<Button
BackgroundColor="{StaticResource Selected}"
FontFamily="PoppinsMedium"
TextColor="{StaticResource ButtonText}"
Text="LOG IN"/>
</Border>
<HorizontalStackLayout
HorizontalOptions="Center"
Margin="0, 20, 0, 0"
Spacing="6">
<Rectangle
BackgroundColor="Gray"
WidthRequest="15"
HeightRequest="3"/>
<Label
TextColor="{StaticResource TextColorSecondary}">
Or continue with</Label>
<Rectangle
BackgroundColor="Gray"
WidthRequest="15"
HeightRequest="3"/>
</HorizontalStackLayout>
<HorizontalStackLayout
Margin="0, 20, 0, 0"
Spacing="15"
HorizontalOptions="Center">
<Border
HeightRequest="75"
WidthRequest="75"
BackgroundColor="#e9f4ff"
StrokeShape="RoundRectangle 25 25 25 25"
Stroke="{StaticResource BackgroundPrimary}">
<Image
HeightRequest="50"
Source="google_logo.svg"/>
</Border>
<Border
HeightRequest="75"
WidthRequest="75"
BackgroundColor="#4460a0"
StrokeShape="RoundRectangle 25 25 25 25"
Stroke="{StaticResource BackgroundPrimary}">
<Image
WidthRequest="40"
Source="facebook_logo.svg"/>
</Border>
</HorizontalStackLayout>
<HorizontalStackLayout
Spacing="4"
HorizontalOptions="Center"
Margin="0, 20, 0, 0">
<Label
TextColor="{StaticResource TextColorPrimary}">
New User?</Label>
<Label
FontAttributes="Bold"
TextColor="{StaticResource TextColorPrimary}">
Create Account</Label>
</HorizontalStackLayout>
</VerticalStackLayout>
</ContentPage>

@ -1,9 +1,9 @@
namespace ShoopNCook.Views;
public partial class LoginPage : ContentPage
{
public LoginPage()
{
InitializeComponent();
}
namespace ShoopNCook.Pages;
public partial class LoginPage : ContentPage
{
public LoginPage()
{
InitializeComponent();
}
}

@ -0,0 +1,40 @@
<?xml version="1.0" encoding="utf-8" ?>
<ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
x:Class="ShoopNCook.Pages.MorePage"
BackgroundColor="{StaticResource BackgroundPrimary}"
xmlns:views="clr-namespace:ShoopNCook.Views"
Title="MorePage">
<Grid
RowDefinitions="Auto, *"
Padding="20, 50, 20, 20">
<!-- Profile picture and name -->
<Grid
Grid.Row="0"
ColumnDefinitions="*, 2*"
ColumnSpacing="30">
<Image
x:Name="ProfileImage"/>
<Label
x:Name="ProfileName"
Grid.Column="1"
FontSize="24"
VerticalTextAlignment="Center"
TextColor="{StaticResource TextColorPrimary}"
FontFamily="Poppins"/>
</Grid>
<VerticalStackLayout
Grid.Row="1"
VerticalOptions="Center"
Margin="40, 0, 0, 0">
<views:HeadedButton Text="My Recipes" HeadSource="cookie.svg" HeadColor="#FF5441"/>
<views:HeadedButton Text="Edit Profile" HeadSource="user_fill.svg" HeadColor="#FF5441"/>
<views:HeadedButton Text="Dark Mode" HeadSource="moon_white.svg" HeadColor="#FF5441"/>
<views:HeadedButton Text="Share App" HeadSource="share.svg" HeadColor="#FF5441"/>
<views:HeadedButton Text="Logout" HeadSource="logout_arrow.svg" HeadColor="#FF5441"/>
</VerticalStackLayout>
</Grid>
</ContentPage>

@ -0,0 +1,15 @@
namespace ShoopNCook.Pages;
public partial class MorePage : ContentPage
{
public MorePage(): this("Adom Shafi", ImageSource.FromFile("default_profile_picture.png"))
{
}
public MorePage(string userName, ImageSource userImage)
{
InitializeComponent();
ProfileImage.Source = userImage;
ProfileName.Text = userName;
}
}

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8" ?>
<ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
x:Class="ShoopNCook.Views.MyRecipesPage"
x:Class="ShoopNCook.Pages.MyRecipesPage"
Title="MyRecipesPage"
xmlns:views="clr-namespace:ShoopNCook.Views"
BackgroundColor="{StaticResource BackgroundPrimary}">
@ -40,16 +40,16 @@
Direction="Row"
Wrap="Wrap">
<views:RecipeView Margin="5" Note="4.5" Title="Spaghetti Bolognese" Subtitle="30 min"/>
<views:RecipeView Margin="5" Note="3" Title="Chickend Curry" Subtitle="45 min"/>
<views:RecipeView Margin="5" Note="0.2" Title="Beef Stroganoff" Subtitle="10 min"/>
<views:RecipeView Margin="5" Note="1.6" Title="Fish And Ships" Subtitle="15 min"/>
<views:RecipeView Margin="5" Note="5" Title="Caesar Salad" Subtitle="20 min"/>
<views:RecipeView Margin="5" Note="3.5" Title="Vegetables" Subtitle="60 min"/>
<views:RecipeView Margin="5" Note="4.6" Title="Guacamole" Subtitle="90 min"/>
<views:RecipeView Margin="5" Note="4" Title="Pad Thai" Subtitle="10 min"/>
<views:RecipeView Margin="5" Note="3" Title="French Toast" Subtitle="5 min"/>
<views:RecipeView Margin="5" Note="2" Title="Margherita Pizza" Subtitle="2 min"/>
<views:OwnedRecipeView Margin="5" Note="4.5" Title="Spaghetti Bolognese"/>
<views:OwnedRecipeView Margin="5" Note="3" Title="Chickend Curry"/>
<views:OwnedRecipeView Margin="5" Note="0.2" Title="Beef Stroganoff"/>
<views:OwnedRecipeView Margin="5" Note="1.6" Title="Fish And Ships"/>
<views:OwnedRecipeView Margin="5" Note="5" Title="Caesar Salad"/>
<views:OwnedRecipeView Margin="5" Note="3.5" Title="Vegetables"/>
<views:OwnedRecipeView Margin="5" Note="4.6" Title="Guacamole"/>
<views:OwnedRecipeView Margin="5" Note="4" Title="Pad Thai"/>
<views:OwnedRecipeView Margin="5" Note="3" Title="French Toast"/>
<views:OwnedRecipeView Margin="5" Note="2" Title="Margherita Pizza"/>
</FlexLayout>
</ScrollView>
</Grid>

@ -1,4 +1,4 @@
namespace ShoopNCook.Views;
namespace ShoopNCook.Pages;
public partial class MyRecipesPage : ContentPage
{

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8" ?>
<ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
x:Class="ShoopNCook.Views.ProfilePage"
x:Class="ShoopNCook.Pages.ProfilePage"
Title="Profile"
BackgroundColor="{StaticResource BackgroundPrimary}">

@ -1,4 +1,4 @@
namespace ShoopNCook.Views;
namespace ShoopNCook.Pages;
public partial class ProfilePage : ContentPage
{

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8" ?>
<ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
x:Class="ShoopNCook.Views.RecipePage"
x:Class="ShoopNCook.Pages.RecipePage"
Title="RecipePage"
x:Name="RecipeViewPage"
BackgroundColor="{StaticResource BackgroundPrimary}">

@ -1,7 +1,7 @@
using Microsoft.Maui.Controls;
using ShoopNCook.Views;
using System.Windows.Input;
namespace ShoopNCook.Views;
namespace ShoopNCook.Pages;
public partial class RecipePage : ContentPage
{

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8" ?>
<ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
x:Class="ShoopNCook.Views.RegisterPage"
x:Class="ShoopNCook.Pages.RegisterPage"
Title="Register"
BackgroundColor="{StaticResource BackgroundPrimary}">
<ScrollView>

@ -1,4 +1,4 @@
namespace ShoopNCook.Views;
namespace ShoopNCook.Pages;
public partial class RegisterPage : ContentPage
{

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8" ?>
<ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
x:Class="ShoopNCook.Views.SearchPage"
x:Class="ShoopNCook.Pages.SearchPage"
xmlns:views="clr-namespace:ShoopNCook.Views"
Title="SearchPage"
BackgroundColor="{StaticResource BackgroundPrimary}">

@ -1,4 +1,4 @@
namespace ShoopNCook.Views;
namespace ShoopNCook.Pages;
public partial class SearchPage : ContentPage
{

@ -0,0 +1,3 @@
<svg width="66" height="77" viewBox="0 0 66 77" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M10.4156 77C8.76563 77 7.32188 76.3583 6.08438 75.075C4.84688 73.7917 4.22813 72.2944 4.22813 70.5833V9.625H3.09375C2.21719 9.625 1.48242 9.31575 0.889453 8.69726C0.296484 8.07869 0 7.31226 0 6.39795C0 5.48358 0.296484 4.72338 0.889453 4.11736C1.48242 3.51134 2.21719 3.20833 3.09375 3.20833H19.3875C19.3875 2.28148 19.684 1.51505 20.277 0.909028C20.8699 0.303009 21.6047 0 22.4813 0H43.5188C44.3953 0 45.1301 0.307465 45.7231 0.922396C46.316 1.53733 46.6125 2.29931 46.6125 3.20833H62.9062C63.7828 3.20833 64.5176 3.51758 65.1105 4.13608C65.7035 4.75464 66 5.52108 66 6.43538C66 7.34976 65.7035 8.10995 65.1105 8.71597C64.5176 9.32199 63.7828 9.625 62.9062 9.625H61.7719V70.5833C61.7719 72.2944 61.1531 73.7917 59.9156 75.075C58.6781 76.3583 57.2344 77 55.5844 77H10.4156ZM21.3469 58.1778C21.3469 59.0868 21.6451 59.8488 22.2415 60.4637C22.838 61.0786 23.577 61.3861 24.4587 61.3861C25.3404 61.3861 26.0734 61.0786 26.6578 60.4637C27.2422 59.8488 27.5344 59.0868 27.5344 58.1778V21.9236C27.5344 21.0146 27.2362 20.2526 26.6398 19.6377C26.0433 19.0227 25.3042 18.7153 24.4226 18.7153C23.5409 18.7153 22.8078 19.0227 22.2234 19.6377C21.6391 20.2526 21.3469 21.0146 21.3469 21.9236V58.1778ZM38.4656 58.1778C38.4656 59.0868 38.7638 59.8488 39.3602 60.4637C39.9567 61.0786 40.6958 61.3861 41.5774 61.3861C42.4591 61.3861 43.1922 61.0786 43.7766 60.4637C44.3609 59.8488 44.6531 59.0868 44.6531 58.1778V21.9236C44.6531 21.0146 44.3549 20.2526 43.7585 19.6377C43.162 19.0227 42.423 18.7153 41.5413 18.7153C40.6596 18.7153 39.9266 19.0227 39.3422 19.6377C38.7578 20.2526 38.4656 21.0146 38.4656 21.9236V58.1778Z" fill="white"/>
</svg>

After

Width:  |  Height:  |  Size: 1.7 KiB

@ -0,0 +1,3 @@
<svg width="21" height="21" viewBox="0 0 21 21" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M9.06258 8.63127C9.47786 8.63127 9.82925 8.48752 10.1167 8.20002C10.4042 7.91252 10.548 7.56114 10.548 7.14586C10.548 6.73058 10.4042 6.37919 10.1167 6.09169C9.82925 5.80419 9.47786 5.66044 9.06258 5.66044C8.6473 5.66044 8.29592 5.80419 8.00842 6.09169C7.72092 6.37919 7.57717 6.73058 7.57717 7.14586C7.57717 7.56114 7.72092 7.91252 8.00842 8.20002C8.29592 8.48752 8.6473 8.63127 9.06258 8.63127ZM7.14592 13.4229C7.56119 13.4229 7.91258 13.2792 8.20008 12.9917C8.48758 12.7042 8.63133 12.3528 8.63133 11.9375C8.63133 11.5222 8.48758 11.1709 8.20008 10.8834C7.91258 10.5959 7.56119 10.4521 7.14592 10.4521C6.73064 10.4521 6.37925 10.5959 6.09175 10.8834C5.80425 11.1709 5.6605 11.5222 5.6605 11.9375C5.6605 12.3528 5.80425 12.7042 6.09175 12.9917C6.37925 13.2792 6.73064 13.4229 7.14592 13.4229ZM13.3751 14.3334C13.6466 14.3334 13.8742 14.2415 14.0579 14.0578C14.2416 13.8742 14.3334 13.6466 14.3334 13.375C14.3334 13.1035 14.2416 12.8759 14.0579 12.6922C13.8742 12.5085 13.6466 12.4167 13.3751 12.4167C13.1036 12.4167 12.8759 12.5085 12.6923 12.6922C12.5086 12.8759 12.4167 13.1035 12.4167 13.375C12.4167 13.6466 12.5086 13.8742 12.6923 14.0578C12.8759 14.2415 13.1036 14.3334 13.3751 14.3334ZM10.5001 20.0834C9.19036 20.0834 7.95251 19.8318 6.78654 19.3287C5.62057 18.8255 4.60234 18.1387 3.73185 17.2683C2.86137 16.3978 2.17456 15.3795 1.67144 14.2136C1.16831 13.0476 0.916748 11.8097 0.916748 10.5C0.916748 9.1903 1.16831 7.95246 1.67144 6.78648C2.17456 5.62051 2.85737 4.59829 3.71987 3.71982C4.58237 2.84134 5.58862 2.14655 6.73862 1.63544C7.88862 1.12433 9.1105 0.868774 10.4042 0.868774C10.9154 0.868774 11.3266 0.988566 11.6381 1.22815C11.9496 1.46773 12.1452 1.84308 12.2251 2.35419C12.3529 3.28058 12.7522 4.06721 13.423 4.71409C14.0938 5.36096 14.8845 5.74829 15.7949 5.87607C16.1303 5.92398 16.3938 6.05176 16.5855 6.2594C16.7772 6.46704 16.9129 6.76252 16.9928 7.14586C17.0727 7.641 17.2803 8.08423 17.6157 8.47555C17.9511 8.86687 18.3504 9.17433 18.8136 9.39794C19.3088 9.63752 19.6522 9.92502 19.8438 10.2604C20.0355 10.5959 20.0994 11.0191 20.0355 11.5302C19.9237 12.7122 19.5963 13.8222 19.0532 14.8604C18.5102 15.8986 17.8114 16.8051 16.9569 17.5797C16.1023 18.3544 15.124 18.9653 14.022 19.4125C12.9199 19.8597 11.7459 20.0834 10.5001 20.0834Z" fill="white"/>
</svg>

After

Width:  |  Height:  |  Size: 2.3 KiB

@ -0,0 +1,3 @@
<svg width="17" height="14" viewBox="0 0 17 14" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M6.6111 3.72736V0L0 6.52288L6.6111 13.0458V9.22524C11.3333 9.22524 14.6389 10.7162 17 13.9776C16.0556 9.31841 13.2222 4.65923 6.6111 3.72736Z" fill="white"/>
</svg>

After

Width:  |  Height:  |  Size: 270 B

@ -0,0 +1,3 @@
<svg width="21" height="21" viewBox="0 0 21 21" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M10.5 20.625C7.6875 20.625 5.29688 19.6406 3.32812 17.6719C1.35938 15.7031 0.375 13.3125 0.375 10.5C0.375 7.6875 1.35938 5.29688 3.32812 3.32812C5.29688 1.35938 7.6875 0.375 10.5 0.375C10.65 0.375 10.8094 0.379687 10.9781 0.389062C11.1469 0.398438 11.3625 0.4125 11.625 0.43125C10.95 1.03125 10.425 1.77187 10.05 2.65313C9.675 3.53437 9.4875 4.4625 9.4875 5.4375C9.4875 7.125 10.0781 8.55937 11.2594 9.74062C12.4406 10.9219 13.875 11.5125 15.5625 11.5125C16.5375 11.5125 17.4656 11.3391 18.3469 10.9922C19.2281 10.6453 19.9688 10.1625 20.5688 9.54375C20.5875 9.76875 20.6016 9.95156 20.6109 10.0922C20.6203 10.2328 20.625 10.3687 20.625 10.5C20.625 13.3125 19.6406 15.7031 17.6719 17.6719C15.7031 19.6406 13.3125 20.625 10.5 20.625ZM10.5 18.9375C12.5437 18.9375 14.325 18.3047 15.8438 17.0391C17.3625 15.7734 18.3094 14.2875 18.6844 12.5812C18.2156 12.7875 17.7125 12.9422 17.175 13.0453C16.6375 13.1484 16.1 13.2 15.5625 13.2C13.4121 13.2 11.5807 12.4439 10.0684 10.9316C8.55614 9.41928 7.8 7.58792 7.8 5.4375C7.8 4.9875 7.84687 4.50469 7.94062 3.98906C8.03437 3.47344 8.20312 2.8875 8.44687 2.23125C6.60938 2.7375 5.08594 3.76406 3.87656 5.31094C2.66719 6.85781 2.0625 8.5875 2.0625 10.5C2.0625 12.8438 2.88281 14.8359 4.52344 16.4766C6.16406 18.1172 8.15625 18.9375 10.5 18.9375Z" fill="#B6AAB2"/>
</svg>

After

Width:  |  Height:  |  Size: 1.4 KiB

@ -0,0 +1,3 @@
<svg width="16" height="15" viewBox="0 0 16 15" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M15.7821 3.04977C15.2529 1.22653 13.7808 0.000759829 12.1198 0.000759829C11.0616 0.000759829 9.99429 0.446733 9.1908 1.22509C8.48601 1.90729 8.04507 3.05364 8.02077 3.11724C8.01383 3.13844 8.00688 3.15813 7.99994 3.17479C7.99161 3.15434 7.98258 3.13011 7.97355 3.1021C7.9548 3.05364 7.51388 1.90729 6.80906 1.22433C6.00567 0.445973 4.93847 0 3.88007 0C2.2184 0 0.74772 1.22509 0.218521 3.04901C-0.717506 6.27537 1.38925 10.2443 5.8527 13.6659C6.45681 14.1292 7.51437 14.8417 7.55951 14.8728C7.68102 14.9546 7.83726 15 7.99975 15C8.16224 15 8.31848 14.9546 8.44069 14.8728C8.48583 14.8425 9.54268 14.1293 10.1468 13.6659C14.611 10.2451 16.7171 6.27595 15.7817 3.04959L15.7821 3.04977Z" fill="white"/>
</svg>

After

Width:  |  Height:  |  Size: 812 B

@ -0,0 +1,4 @@
<svg width="14" height="15" viewBox="0 0 14 15" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M7.15916 6.8975C9.09848 6.8975 10.6706 5.35344 10.6706 3.44875C10.6706 1.54406 9.09848 0 7.15916 0C5.21984 0 3.64771 1.54406 3.64771 3.44875C3.64771 5.35344 5.21984 6.8975 7.15916 6.8975Z" fill="white"/>
<path d="M7.15905 8.62128C3.64451 8.62128 0.79541 11.4195 0.79541 14.8713H13.5227C13.5227 11.4195 10.6736 8.62128 7.15905 8.62128Z" fill="white"/>
</svg>

After

Width:  |  Height:  |  Size: 463 B

@ -1,87 +0,0 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFrameworks>net7.0-android;net7.0-ios;net7.0-maccatalyst</TargetFrameworks>
<TargetFrameworks Condition="$([MSBuild]::IsOSPlatform('windows'))">$(TargetFrameworks);net7.0-windows10.0.19041.0</TargetFrameworks>
<!-- Uncomment to also build the tizen app. You will need to install tizen by following this: https://github.com/Samsung/Tizen.NET -->
<!-- <TargetFrameworks>$(TargetFrameworks);net7.0-tizen</TargetFrameworks> -->
<OutputType>Exe</OutputType>
<RootNamespace>ShoopNCook</RootNamespace>
<UseMaui>true</UseMaui>
<SingleProject>true</SingleProject>
<ImplicitUsings>enable</ImplicitUsings>
<!-- Display name -->
<ApplicationTitle>ShoopNCook</ApplicationTitle>
<!-- App Identifier -->
<ApplicationId>com.companyname.shoopncook</ApplicationId>
<ApplicationIdGuid>bf17e1fe-a722-42f6-a24d-3327d351c924</ApplicationIdGuid>
<!-- Versions -->
<ApplicationDisplayVersion>1.0</ApplicationDisplayVersion>
<ApplicationVersion>1</ApplicationVersion>
<SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'ios'">11.0</SupportedOSPlatformVersion>
<SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'maccatalyst'">13.1</SupportedOSPlatformVersion>
<SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'android'">21.0</SupportedOSPlatformVersion>
<SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'windows'">10.0.17763.0</SupportedOSPlatformVersion>
<TargetPlatformMinVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'windows'">10.0.17763.0</TargetPlatformMinVersion>
<SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'tizen'">6.5</SupportedOSPlatformVersion>
</PropertyGroup>
<ItemGroup>
<!-- App Icon -->
<MauiIcon Include="Resources\AppIcon\appicon.svg" ForegroundFile="Resources\AppIcon\appiconfg.svg" Color="#512BD4" />
<!-- Splash Screen -->
<MauiSplashScreen Include="Resources\Splash\splash.svg" Color="#512BD4" BaseSize="128,128" />
<!-- Images -->
<MauiImage Include="Resources\Images\*" />
<!-- Custom Fonts -->
<MauiFont Include="Resources\Fonts\*" />
<!-- Raw Assets (also remove the "Resources\Raw" prefix) -->
<MauiAsset Include="Resources\Raw\**" LogicalName="%(RecursiveDir)%(Filename)%(Extension)" />
</ItemGroup>
<ItemGroup>
<None Remove="Resources\Fonts\Poppins-Bold.ttf" />
<None Remove="Resources\Images\email_icon.svg" />
<None Remove="Resources\Images\facebook_logo.svg" />
<None Remove="Resources\Images\password_icon.svg" />
<None Remove="Resources\Images\search_options.svg" />
<None Remove="Resources\Images\visibility_off.svg" />
<None Remove="Resources\Images\visibility_on.svg" />
</ItemGroup>
<ItemGroup>
<None Remove="Resources\Fonts\arrow_back_ios_FILL0_wght400_GRAD200_opsz48.svg" />
<None Remove="Resources\Images\default_profile_picture.png" />
</ItemGroup>
<ItemGroup>
<MauiFont Include="Resources\Images\arrow_back.svg" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="Microsoft.Extensions.Logging.Debug" Version="7.0.0" />
</ItemGroup>
<ItemGroup>
<MauiXaml Update="Views\ProfilePage.xaml">
<Generator>MSBuild:Compile</Generator>
</MauiXaml>
<MauiXaml Update="Views\RecipeView.xaml">
<Generator>MSBuild:Compile</Generator>
</MauiXaml>
<MauiXaml Update="Views\SearchPage.xaml">
<Generator>MSBuild:Compile</Generator>
</MauiXaml>
</ItemGroup>
<ProjectExtensions><VisualStudio><UserProperties XamarinHotReloadDebuggerTimeoutExceptionShoopNCookHideInfoBar="True" XamarinHotReloadUnhandledDeviceExceptionShoopNCookHideInfoBar="True" /></VisualStudio></ProjectExtensions>
</Project>

@ -1,104 +0,0 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFrameworks>net7.0-android;net7.0-ios;net7.0-maccatalyst</TargetFrameworks>
<TargetFrameworks Condition="$([MSBuild]::IsOSPlatform('windows'))">$(TargetFrameworks);net7.0-windows10.0.19041.0</TargetFrameworks>
<!-- Uncomment to also build the tizen app. You will need to install tizen by following this: https://github.com/Samsung/Tizen.NET -->
<!-- <TargetFrameworks>$(TargetFrameworks);net7.0-tizen</TargetFrameworks> -->
<OutputType>Exe</OutputType>
<RootNamespace>ShoopNCook</RootNamespace>
<UseMaui>true</UseMaui>
<SingleProject>true</SingleProject>
<ImplicitUsings>enable</ImplicitUsings>
<!-- Display name -->
<ApplicationTitle>ShoopNCook</ApplicationTitle>
<!-- App Identifier -->
<ApplicationId>com.companyname.shoopncook</ApplicationId>
<ApplicationIdGuid>bf17e1fe-a722-42f6-a24d-3327d351c924</ApplicationIdGuid>
<!-- Versions -->
<ApplicationDisplayVersion>1.0</ApplicationDisplayVersion>
<ApplicationVersion>1</ApplicationVersion>
<SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'ios'">11.0</SupportedOSPlatformVersion>
<SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'maccatalyst'">13.1</SupportedOSPlatformVersion>
<SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'android'">21.0</SupportedOSPlatformVersion>
<SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'windows'">10.0.17763.0</SupportedOSPlatformVersion>
<TargetPlatformMinVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'windows'">10.0.17763.0</TargetPlatformMinVersion>
<SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'tizen'">6.5</SupportedOSPlatformVersion>
</PropertyGroup>
<ItemGroup>
<!-- App Icon -->
<MauiIcon Include="Resources\AppIcon\appicon.svg" ForegroundFile="Resources\AppIcon\appiconfg.svg" Color="#512BD4" />
<!-- Splash Screen -->
<MauiSplashScreen Include="Resources\Splash\splash.svg" Color="#512BD4" BaseSize="128,128" />
<!-- Images -->
<MauiImage Include="Resources\Images\*" />
<!-- Custom Fonts -->
<MauiFont Include="Resources\Fonts\*" />
<!-- Raw Assets (also remove the "Resources\Raw" prefix) -->
<MauiAsset Include="Resources\Raw\**" LogicalName="%(RecursiveDir)%(Filename)%(Extension)" />
</ItemGroup>
<ItemGroup>
<None Remove="Resources\Fonts\Poppins-Bold.ttf" />
<None Remove="Resources\Fonts\Poppins-Medium.ttf" />
<None Remove="Resources\Images\email_icon.svg" />
<None Remove="Resources\Images\facebook_logo.svg" />
<None Remove="Resources\Images\hearth_off.svg" />
<None Remove="Resources\Images\hearth_on.svg" />
<None Remove="Resources\Images\minus.svg" />
<None Remove="Resources\Images\password_icon.svg" />
<None Remove="Resources\Images\plus.svg" />
<None Remove="Resources\Images\search_options.svg" />
<None Remove="Resources\Images\star_empty.svg" />
<None Remove="Resources\Images\star_full.svg" />
<None Remove="Resources\Images\user.svg" />
<None Remove="Resources\Images\visibility_off.svg" />
<None Remove="Resources\Images\visibility_on.svg" />
</ItemGroup>
<ItemGroup>
<None Remove="Resources\Fonts\arrow_back_ios_FILL0_wght400_GRAD200_opsz48.svg" />
<None Remove="Resources\Images\default_profile_picture.png" />
</ItemGroup>
<ItemGroup>
<MauiFont Include="Resources\Images\arrow_back.svg" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="Microsoft.Extensions.Logging.Debug" Version="7.0.0" />
</ItemGroup>
<ItemGroup>
<MauiXaml Update="Views\IngredientView.xaml">
<Generator>MSBuild:Compile</Generator>
</MauiXaml>
<MauiXaml Update="Views\ProfilePage.xaml">
<Generator>MSBuild:Compile</Generator>
</MauiXaml>
<MauiXaml Update="Views\RecipePage.xaml">
<Generator>MSBuild:Compile</Generator>
</MauiXaml>
<MauiXaml Update="Views\RecipeView.xaml">
<Generator>MSBuild:Compile</Generator>
</MauiXaml>
<MauiXaml Update="Views\RegisterPage.xaml">
<Generator>MSBuild:Compile</Generator>
</MauiXaml>
<MauiXaml Update="Views\SearchPage.xaml">
<Generator>MSBuild:Compile</Generator>
</MauiXaml>
</ItemGroup>
<ProjectExtensions><VisualStudio><UserProperties XamarinHotReloadDebuggerTimeoutExceptionShoopNCookHideInfoBar="True" XamarinHotReloadUnhandledDeviceExceptionShoopNCookHideInfoBar="True" /></VisualStudio></ProjectExtensions>
</Project>

@ -1,87 +0,0 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFrameworks>net7.0-android;net7.0-ios;net7.0-maccatalyst</TargetFrameworks>
<TargetFrameworks Condition="$([MSBuild]::IsOSPlatform('windows'))">$(TargetFrameworks);net7.0-windows10.0.19041.0</TargetFrameworks>
<!-- Uncomment to also build the tizen app. You will need to install tizen by following this: https://github.com/Samsung/Tizen.NET -->
<!-- <TargetFrameworks>$(TargetFrameworks);net7.0-tizen</TargetFrameworks> -->
<OutputType>Exe</OutputType>
<RootNamespace>ShoopNCook</RootNamespace>
<UseMaui>true</UseMaui>
<SingleProject>true</SingleProject>
<ImplicitUsings>enable</ImplicitUsings>
<!-- Display name -->
<ApplicationTitle>ShoopNCook</ApplicationTitle>
<!-- App Identifier -->
<ApplicationId>com.companyname.shoopncook</ApplicationId>
<ApplicationIdGuid>bf17e1fe-a722-42f6-a24d-3327d351c924</ApplicationIdGuid>
<!-- Versions -->
<ApplicationDisplayVersion>1.0</ApplicationDisplayVersion>
<ApplicationVersion>1</ApplicationVersion>
<SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'ios'">11.0</SupportedOSPlatformVersion>
<SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'maccatalyst'">13.1</SupportedOSPlatformVersion>
<SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'android'">21.0</SupportedOSPlatformVersion>
<SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'windows'">10.0.17763.0</SupportedOSPlatformVersion>
<TargetPlatformMinVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'windows'">10.0.17763.0</TargetPlatformMinVersion>
<SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'tizen'">6.5</SupportedOSPlatformVersion>
</PropertyGroup>
<ItemGroup>
<!-- App Icon -->
<MauiIcon Include="Resources\AppIcon\appicon.svg" ForegroundFile="Resources\AppIcon\appiconfg.svg" Color="#512BD4" />
<!-- Splash Screen -->
<MauiSplashScreen Include="Resources\Splash\splash.svg" Color="#512BD4" BaseSize="128,128" />
<!-- Images -->
<MauiImage Include="Resources\Images\*" />
<!-- Custom Fonts -->
<MauiFont Include="Resources\Fonts\*" />
<!-- Raw Assets (also remove the "Resources\Raw" prefix) -->
<MauiAsset Include="Resources\Raw\**" LogicalName="%(RecursiveDir)%(Filename)%(Extension)" />
</ItemGroup>
<ItemGroup>
<None Remove="Resources\Fonts\Poppins-Bold.ttf" />
<None Remove="Resources\Images\email_icon.svg" />
<None Remove="Resources\Images\facebook_logo.svg" />
<None Remove="Resources\Images\password_icon.svg" />
<None Remove="Resources\Images\search_options.svg" />
<None Remove="Resources\Images\visibility_off.svg" />
<None Remove="Resources\Images\visibility_on.svg" />
</ItemGroup>
<ItemGroup>
<None Remove="Resources\Fonts\arrow_back_ios_FILL0_wght400_GRAD200_opsz48.svg" />
<None Remove="Resources\Images\default_profile_picture.png" />
</ItemGroup>
<ItemGroup>
<MauiFont Include="Resources\Images\arrow_back.svg" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="Microsoft.Extensions.Logging.Debug" Version="7.0.0" />
</ItemGroup>
<ItemGroup>
<MauiXaml Update="Views\ProfilePage.xaml">
<Generator>MSBuild:Compile</Generator>
</MauiXaml>
<MauiXaml Update="Views\RecipeView.xaml">
<Generator>MSBuild:Compile</Generator>
</MauiXaml>
<MauiXaml Update="Views\SearchPage.xaml">
<Generator>MSBuild:Compile</Generator>
</MauiXaml>
</ItemGroup>
<ProjectExtensions><VisualStudio><UserProperties XamarinHotReloadDebuggerTimeoutExceptionShoopNCookHideInfoBar="True" XamarinHotReloadUnhandledDeviceExceptionShoopNCookHideInfoBar="True" /></VisualStudio></ProjectExtensions>
</Project>

@ -49,6 +49,7 @@
<ItemGroup>
<None Remove="Resources\Fonts\Poppins-Bold.ttf" />
<None Remove="Resources\Images\bin.svg" />
<None Remove="Resources\Images\email_icon.svg" />
<None Remove="Resources\Images\facebook_logo.svg" />
<None Remove="Resources\Images\password_icon.svg" />

@ -1,9 +0,0 @@
namespace ShoopNCook.Views;
public partial class FavoritesPage : ContentPage
{
public FavoritesPage()
{
InitializeComponent();
}
}

@ -0,0 +1,28 @@
<?xml version="1.0" encoding="utf-8" ?>
<ContentView xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
x:Class="ShoopNCook.Views.HeadedButton"
x:Name="HeadedBtn">
<HorizontalStackLayout>
<Border
x:Name="PrefixBorder"
BackgroundColor="{Binding HeadColor, Source={x:Reference HeadedBtn}}"
Stroke="Transparent"
StrokeShape="RoundRectangle 250"
Padding="10">
<ImageButton
x:Name="PrefixImage"
WidthRequest="25"
HeightRequest="25"
Source="{Binding HeadSource, Source={x:Reference HeadedBtn}}"/>
</Border>
<Label
x:Name="BtnLabel"
Margin="20, 0, 0, 0"
Text="{Binding Text, Source={x:Reference HeadedBtn}}"
VerticalTextAlignment="Center"
FontFamily="Poppins"
FontSize="16"
TextColor="{StaticResource TextColorPrimary}"/>
</HorizontalStackLayout>
</ContentView>

@ -0,0 +1,37 @@
namespace ShoopNCook.Views;
public partial class HeadedButton : ContentView
{
private readonly BindableProperty TextProperty =
BindableProperty.Create("Text", typeof(string), typeof(HeadedButton), "No Text Defined.");
private readonly BindableProperty HeadColorProperty =
BindableProperty.Create("HeadColor", typeof(string), typeof(HeadedButton), "#FFFFFF");
private readonly BindableProperty HeadSourceProperty =
BindableProperty.Create("HeadSource", typeof(string), typeof(HeadedButton), default(string));
public string Text
{
get => (string)GetValue(TextProperty);
set => SetValue(TextProperty, value);
}
public string HeadColor
{
get => (string)GetValue(HeadColorProperty);
set => SetValue(HeadColorProperty, value);
}
public string HeadSource
{
get => (string)GetValue(HeadSourceProperty);
set => SetValue(HeadSourceProperty, value);
}
public HeadedButton()
{
InitializeComponent();
}
}

@ -2,5 +2,78 @@
<ContentView xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
x:Class="ShoopNCook.Views.OwnedRecipeView">
<Border
Style="{StaticResource SecondaryBorderShadow}"
StrokeShape="RoundRectangle 30">
<Grid
BackgroundColor="{StaticResource BackgroundSecondary}"
Padding="10"
MinimumHeightRequest="175"
MinimumWidthRequest="150"
RowDefinitions="*, Auto">
<Border
Grid.Row="0"
Stroke="Transparent"
StrokeShape="RoundRectangle 20"
BackgroundColor="AliceBlue">
<Grid>
<Image />
<HorizontalStackLayout
x:Name="Stars"
VerticalOptions="End"
HorizontalOptions="End"
Margin="0, 0, 15, 2">
<Image
WidthRequest="10"
Source="star_full.svg"/>
<Image
WidthRequest="10"
Source="star_full.svg"/>
<Image
WidthRequest="10"
Source="star_full.svg"/>
<Image
WidthRequest="10"
Source="star_full.svg"/>
<Image
WidthRequest="10"
Source="star_full.svg"/>
</HorizontalStackLayout>
</Grid>
</Border>
<VerticalStackLayout Grid.Row="1">
<Label
TextColor="{StaticResource TextColorPrimary}"
x:Name="TitleLabel"/>
<Border
BackgroundColor="{StaticResource Selected}"
Stroke="Transparent"
StrokeShape="RoundRectangle 250"
Margin="15, 0, 15, 0">
<Grid
ColumnDefinitions="Auto, *"
Padding="15, 3, 15, 3"
ColumnSpacing="4">
<Grid.GestureRecognizers>
<TapGestureRecognizer
Tapped="TapGestureRecognizer_Tapped"
NumberOfTapsRequired="1"/>
</Grid.GestureRecognizers>
<Image
Grid.Column="0"
Source="bin.svg"
MaximumHeightRequest="15"/>
<Label
Grid.Column="1"
Text="Delete"
/>
</Grid>
</Border>
</VerticalStackLayout>
</Grid>
</Border>
</ContentView>

@ -3,12 +3,42 @@ namespace ShoopNCook.Views;
public partial class OwnedRecipeView : ContentView
{
private readonly RecipeView recipeView;
public OwnedRecipeView() : this(5, "Title")
{ }
public OwnedRecipeView(float note, string title, string subtitle)
{
recipeView = new RecipeView(note, title, subtitle);
public OwnedRecipeView(float note, string title)
{
InitializeComponent();
Note = note;
Title = title;
}
public float Note
{
set => SetNote(value);
}
public string Title
{
set => TitleLabel.Text = value;
}
private void SetNote(float note)
{
int i = 1;
foreach (Image img in Stars.Children)
{
if (i <= note)
{
img.Opacity = 0;
i++;
}
else img.Opacity = 1;
}
}
private void TapGestureRecognizer_Tapped(object sender, TappedEventArgs e)
{
Console.WriteLine("This is a test");
}
}

@ -42,5 +42,5 @@ public partial class RecipeView : ContentView
}
else img.Opacity = 1;
}
}
}
}
Loading…
Cancel
Save