You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
ShopNCook/Views/Components/StoredRecipeView.xaml

68 lines
2.5 KiB

<?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.StoredRecipeView"
xmlns:views="clr-namespace:ShoopNCook.Views">
<Border
Style="{StaticResource SecondaryBorderShadow}"
StrokeShape="RoundRectangle 30">
<Grid
BackgroundColor="{StaticResource BackgroundSecondary}"
Padding="10"
MinimumHeightRequest="250"
MinimumWidthRequest="150"
RowDefinitions="*, Auto">
<Grid.GestureRecognizers>
<TapGestureRecognizer Tapped="OnRecipeTapped"/>
</Grid.GestureRecognizers>
<Border
Grid.Row="0"
Stroke="Transparent"
StrokeShape="RoundRectangle 20"
MaximumHeightRequest="300"
BackgroundColor="{StaticResource ImageBackground}">
<Grid>
<Image Source="{Binding Image}"
Aspect="AspectFill"/>
<HorizontalStackLayout
x:Name="Stars"
VerticalOptions="End"
HorizontalOptions="End"
Margin="0, 0, 15, 2">
<Image
WidthRequest="15"
Source="star_full.svg"/>
<Image
WidthRequest="15"
Source="star_full.svg"/>
<Image
WidthRequest="15"
Source="star_full.svg"/>
<Image
WidthRequest="15"
Source="star_full.svg"/>
<Image
WidthRequest="15"
Source="star_full.svg"/>
</HorizontalStackLayout>
</Grid>
</Border>
<VerticalStackLayout
HorizontalOptions="Start"
Grid.Row="1">
<Label
TextColor="{StaticResource TextColorPrimary}"
Text="{Binding Name}"/>
<views:CounterView
CounterText="pers"
x:Name="Counter"/>
</VerticalStackLayout>
</Grid>
</Border>
</ContentView>