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/CounterView.xaml

53 lines
1.7 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.CounterView"
x:Name="Counter">
<Grid
ColumnDefinitions="*, Auto, *">
<Border
Grid.Column="0"
Stroke="Transparent"
StrokeShape="RoundRectangle 100"
BackgroundColor="{StaticResource Selected}">
<ImageButton
Source="minus.svg"
WidthRequest="40"
HeightRequest="40"
Clicked="OnMinus"/>
</Border>
<HorizontalStackLayout
Grid.Column="1"
Spacing="3"
Margin="10, 0, 10, 0">
<Label
x:Name="CountLabel"
Text="{Binding Count, Source={x:Reference Counter}}"
TextColor="{StaticResource TextColorPrimary}"
VerticalTextAlignment="Center"
FontFamily="PoppinsMedium"/>
<Label
x:Name="CounterLabel"
Text="{Binding CounterText, Source={x:Reference Counter}}"
TextColor="{StaticResource TextColorPrimary}"
VerticalTextAlignment="Center"
FontFamily="PoppinsMedium"/>
</HorizontalStackLayout>
<Border
Grid.Column="2"
Stroke="Transparent"
StrokeShape="RoundRectangle 100"
BackgroundColor="{StaticResource Selected}">
<ImageButton
Source="plus.svg"
WidthRequest="40"
HeightRequest="40"
Clicked="OnPlus"/>
</Border>
</Grid>
</ContentView>