142 lines
6.4 KiB
XML
142 lines
6.4 KiB
XML
<?xml version="1.0" encoding="utf-8" ?>
|
|
<ContentPage
|
|
x:Class="cfs_tracker.Views.WeekPage"
|
|
xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
|
|
x:Name="ThisPage"
|
|
Title="Woche">
|
|
|
|
<Grid RowDefinitions="Auto,*" Padding="16">
|
|
|
|
<Grid Grid.Row="0" ColumnDefinitions="Auto,*,Auto,Auto" Margin="0,0,0,12">
|
|
<Button
|
|
Grid.Column="0"
|
|
Text="◀"
|
|
WidthRequest="52"
|
|
HeightRequest="44"
|
|
Command="{Binding PreviousWeekCommand}" />
|
|
|
|
<Label
|
|
Grid.Column="1"
|
|
Text="{Binding WeekText}"
|
|
HorizontalTextAlignment="Center"
|
|
VerticalTextAlignment="Center"
|
|
FontSize="22"
|
|
FontAttributes="Bold" />
|
|
|
|
<Button
|
|
Grid.Column="2"
|
|
Text="Heute"
|
|
Margin="8,0,0,0"
|
|
Command="{Binding TodayCommand}" />
|
|
|
|
<Button
|
|
Grid.Column="3"
|
|
Text="▶"
|
|
WidthRequest="52"
|
|
HeightRequest="44"
|
|
Margin="8,0,0,0"
|
|
Command="{Binding NextWeekCommand}" />
|
|
</Grid>
|
|
|
|
<CollectionView
|
|
Grid.Row="1"
|
|
ItemsSource="{Binding Days}"
|
|
SelectionMode="None">
|
|
|
|
<CollectionView.ItemsLayout>
|
|
<LinearItemsLayout Orientation="Vertical" ItemSpacing="10" />
|
|
</CollectionView.ItemsLayout>
|
|
|
|
<CollectionView.ItemTemplate>
|
|
<DataTemplate>
|
|
<Border
|
|
Padding="12"
|
|
BackgroundColor="{DynamicResource PanelBackground}"
|
|
Stroke="{DynamicResource PanelBorder}"
|
|
StrokeThickness="1"
|
|
StrokeShape="RoundRectangle 12">
|
|
|
|
<VerticalStackLayout Spacing="10">
|
|
|
|
<Grid ColumnDefinitions="*,Auto">
|
|
<VerticalStackLayout>
|
|
<Label
|
|
Text="{Binding DayText}"
|
|
FontAttributes="Bold"
|
|
FontSize="18"
|
|
TextColor="{DynamicResource TextPrimary}" />
|
|
<Label
|
|
Text="{Binding DateText}"
|
|
FontSize="13"
|
|
TextColor="{DynamicResource TextMuted}" />
|
|
</VerticalStackLayout>
|
|
</Grid>
|
|
|
|
<Grid ColumnDefinitions="*,*" ColumnSpacing="10">
|
|
|
|
<Border
|
|
Grid.Column="0"
|
|
BackgroundColor="{Binding MorningBackgroundColor}"
|
|
StrokeThickness="0"
|
|
StrokeShape="RoundRectangle 10"
|
|
Padding="10">
|
|
<Border.GestureRecognizers>
|
|
<TapGestureRecognizer
|
|
Command="{Binding Source={x:Reference ThisPage}, Path=BindingContext.OpenDayCommand}"
|
|
CommandParameter="{Binding .}" />
|
|
</Border.GestureRecognizers>
|
|
|
|
<VerticalStackLayout>
|
|
<Label
|
|
Text="Vormittag"
|
|
FontAttributes="Bold"
|
|
TextColor="{Binding MorningTextColor}" />
|
|
<Label
|
|
Text="{Binding MorningText}"
|
|
FontSize="18"
|
|
TextColor="{Binding MorningTextColor}" />
|
|
<Label
|
|
Text="{Binding MorningCountText}"
|
|
FontSize="12"
|
|
TextColor="{Binding MorningTextColor}" />
|
|
</VerticalStackLayout>
|
|
</Border>
|
|
|
|
<Border
|
|
Grid.Column="1"
|
|
BackgroundColor="{Binding AfternoonBackgroundColor}"
|
|
StrokeThickness="0"
|
|
StrokeShape="RoundRectangle 10"
|
|
Padding="10">
|
|
<Border.GestureRecognizers>
|
|
<TapGestureRecognizer
|
|
Command="{Binding Source={x:Reference ThisPage}, Path=BindingContext.OpenDayCommand}"
|
|
CommandParameter="{Binding .}" />
|
|
</Border.GestureRecognizers>
|
|
|
|
<VerticalStackLayout>
|
|
<Label
|
|
Text="Nachmittag"
|
|
FontAttributes="Bold"
|
|
TextColor="{Binding AfternoonTextColor}" />
|
|
<Label
|
|
Text="{Binding AfternoonText}"
|
|
FontSize="18"
|
|
TextColor="{Binding AfternoonTextColor}" />
|
|
<Label
|
|
Text="{Binding AfternoonCountText}"
|
|
FontSize="12"
|
|
TextColor="{Binding AfternoonTextColor}" />
|
|
</VerticalStackLayout>
|
|
</Border>
|
|
|
|
</Grid>
|
|
</VerticalStackLayout>
|
|
</Border>
|
|
</DataTemplate>
|
|
</CollectionView.ItemTemplate>
|
|
</CollectionView>
|
|
|
|
</Grid>
|
|
</ContentPage> |