Fix: FAB white background with dark icon in dark mode

Add FabBackgroundColor / FabTextColor theme keys so the FAB is always
visible: dark background + white icon in light mode, white background +
dark icon in dark mode.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Gerwin Kuijntjes
2026-04-02 12:31:05 +02:00
parent af37fb7095
commit eadc2d6606
3 changed files with 6 additions and 2 deletions

View File

@@ -142,8 +142,8 @@
FontSize="20"
WidthRequest="56" HeightRequest="56"
CornerRadius="28"
BackgroundColor="{DynamicResource NavigationBarColor}"
TextColor="White"
BackgroundColor="{DynamicResource FabBackgroundColor}"
TextColor="{DynamicResource FabTextColor}"
VerticalOptions="End" HorizontalOptions="End"
Margin="0,0,16,16"
Command="{Binding Commands[AddConnection]}" />

View File

@@ -18,6 +18,8 @@
<Color x:Key="QueryActionBar">#141414</Color>
<Color x:Key="Extreme">#141414</Color>
<Color x:Key="NavigationBarColor">#141414</Color>
<Color x:Key="FabBackgroundColor">#ffffff</Color>
<Color x:Key="FabTextColor">#0c0c0c</Color>
<Style TargetType="ContentPage" ApplyToDerivedTypes="True">
<Setter Property="BackgroundColor" Value="{StaticResource PageBackground}" />

View File

@@ -18,6 +18,8 @@
<Color x:Key="QueryActionBar">#f5f5f5</Color>
<Color x:Key="Extreme">#ffffff</Color>
<Color x:Key="NavigationBarColor">#0c0c0c</Color>
<Color x:Key="FabBackgroundColor">#0c0c0c</Color>
<Color x:Key="FabTextColor">#ffffff</Color>
<Style TargetType="ContentPage" ApplyToDerivedTypes="True">
<Setter Property="BackgroundColor" Value="{StaticResource PageBackground}" />