Farbpalette vorladen lassen
Bootstraper läd jetzt die farbeinstellung sofort und nicht nachträglich cleanup and rework PDF switch to HTML export fix Colorsystem Farben für knöpfe hinzugefügt als anpassung button color button color primary and secondary change
This commit is contained in:
+107
-132
@@ -1,142 +1,117 @@
|
||||
<?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">
|
||||
<ContentPage x:Class="cfs_tracker.Views.WeekPage"
|
||||
x:Name="RootPage"
|
||||
xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
|
||||
xmlns:viewModels="clr-namespace:cfs_tracker.ViewModels"
|
||||
x:DataType="viewModels:WeekViewModel"
|
||||
Title="Woche"
|
||||
BackgroundColor="{DynamicResource AppBackground}">
|
||||
|
||||
<Grid RowDefinitions="Auto,*" Padding="16">
|
||||
<ScrollView>
|
||||
<VerticalStackLayout Padding="16" Spacing="16">
|
||||
<Grid ColumnDefinitions="Auto,*,Auto"
|
||||
VerticalOptions="Center">
|
||||
<Button Text="←"
|
||||
Style="{StaticResource PrimaryButtonStyle}"
|
||||
Command="{Binding PreviousWeekCommand}" />
|
||||
<Label Grid.Column="1"
|
||||
Text="{Binding HeaderText}"
|
||||
HorizontalTextAlignment="Center"
|
||||
VerticalTextAlignment="Center"
|
||||
FontSize="20"
|
||||
FontAttributes="Bold"
|
||||
TextColor="{DynamicResource TextPrimary}" />
|
||||
<Button Grid.Column="2"
|
||||
Text="→"
|
||||
Style="{StaticResource PrimaryButtonStyle}"
|
||||
Command="{Binding NextWeekCommand}" />
|
||||
</Grid>
|
||||
|
||||
<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}" />
|
||||
<Grid ColumnDefinitions="*,*"
|
||||
ColumnSpacing="12">
|
||||
<Button Text="Heute"
|
||||
Style="{StaticResource PrimaryButtonStyle}"
|
||||
Command="{Binding TodayCommand}" />
|
||||
<Button Grid.Column="1"
|
||||
Text="Export"
|
||||
Style="{StaticResource PrimaryButtonStyle}"
|
||||
Command="{Binding ExportPdfCommand}" />
|
||||
</Grid>
|
||||
|
||||
<Label
|
||||
Grid.Column="1"
|
||||
Text="{Binding WeekText}"
|
||||
HorizontalTextAlignment="Center"
|
||||
VerticalTextAlignment="Center"
|
||||
FontSize="22"
|
||||
FontAttributes="Bold" />
|
||||
<CollectionView ItemsSource="{Binding Days}"
|
||||
SelectionMode="None">
|
||||
<CollectionView.ItemTemplate>
|
||||
<DataTemplate x:DataType="viewModels:WeekDaySummaryViewModel">
|
||||
<Border Margin="0,0,0,12"
|
||||
Padding="12"
|
||||
Stroke="{DynamicResource Border}"
|
||||
BackgroundColor="{DynamicResource SurfaceBackground}"
|
||||
StrokeShape="RoundRectangle 14">
|
||||
<Border.GestureRecognizers>
|
||||
<TapGestureRecognizer
|
||||
Command="{Binding Source={x:Reference RootPage}, Path=BindingContext.OpenDayCommand}"
|
||||
CommandParameter="{Binding .}" />
|
||||
</Border.GestureRecognizers>
|
||||
|
||||
<Button
|
||||
Grid.Column="2"
|
||||
Text="Heute"
|
||||
Margin="8,0,0,0"
|
||||
Command="{Binding TodayCommand}" />
|
||||
<VerticalStackLayout Spacing="10">
|
||||
<Grid ColumnDefinitions="*"
|
||||
ColumnSpacing="10">
|
||||
<Label Text="{Binding DateText}"
|
||||
FontAttributes="Bold"
|
||||
FontSize="18"
|
||||
TextColor="{DynamicResource TextPrimary}" />
|
||||
</Grid>
|
||||
|
||||
<Button
|
||||
Grid.Column="3"
|
||||
Text="▶"
|
||||
WidthRequest="52"
|
||||
HeightRequest="44"
|
||||
Margin="8,0,0,0"
|
||||
Command="{Binding NextWeekCommand}" />
|
||||
</Grid>
|
||||
<Grid ColumnDefinitions="*,*"
|
||||
ColumnSpacing="12">
|
||||
<Border Padding="10"
|
||||
StrokeThickness="0"
|
||||
StrokeShape="RoundRectangle 10"
|
||||
BackgroundColor="{Binding MorningColor}">
|
||||
<VerticalStackLayout Spacing="4">
|
||||
<Label Text="Vormittag"
|
||||
FontAttributes="Bold"
|
||||
TextColor="White" />
|
||||
<Label Text="{Binding MorningText}"
|
||||
TextColor="White" />
|
||||
</VerticalStackLayout>
|
||||
</Border>
|
||||
|
||||
<CollectionView
|
||||
Grid.Row="1"
|
||||
ItemsSource="{Binding Days}"
|
||||
SelectionMode="None">
|
||||
<Border Grid.Column="1"
|
||||
Padding="10"
|
||||
StrokeThickness="0"
|
||||
StrokeShape="RoundRectangle 10"
|
||||
BackgroundColor="{Binding AfternoonColor}">
|
||||
<VerticalStackLayout Spacing="4">
|
||||
<Label Text="Nachmittag"
|
||||
FontAttributes="Bold"
|
||||
TextColor="White" />
|
||||
<Label Text="{Binding AfternoonText}"
|
||||
TextColor="White" />
|
||||
</VerticalStackLayout>
|
||||
</Border>
|
||||
</Grid>
|
||||
|
||||
<CollectionView.ItemsLayout>
|
||||
<LinearItemsLayout Orientation="Vertical" ItemSpacing="10" />
|
||||
</CollectionView.ItemsLayout>
|
||||
<Button Text="{Binding DetailsButtonText}"
|
||||
IsVisible="{Binding HasDetails}"
|
||||
Style="{StaticResource PrimaryButtonStyle}"
|
||||
Command="{Binding ToggleExpandedCommand}" />
|
||||
|
||||
<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 IsVisible="{Binding IsExpanded}"
|
||||
Spacing="6">
|
||||
<Label Text="{Binding ActivitiesText, StringFormat='Tätigkeiten: {0}'}"
|
||||
IsVisible="{Binding HasActivities}"
|
||||
TextColor="{DynamicResource TextPrimary}" />
|
||||
<Label Text="{Binding SymptomsText, StringFormat='Symptome: {0}'}"
|
||||
IsVisible="{Binding HasSymptoms}"
|
||||
TextColor="{DynamicResource TextPrimary}" />
|
||||
</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>
|
||||
</VerticalStackLayout>
|
||||
</Border>
|
||||
</DataTemplate>
|
||||
</CollectionView.ItemTemplate>
|
||||
</CollectionView>
|
||||
</VerticalStackLayout>
|
||||
</ScrollView>
|
||||
</ContentPage>
|
||||
|
||||
Reference in New Issue
Block a user