style<*>: new light theme

This commit is contained in:
leo 2022-10-25 21:50:58 +08:00
parent e1b7c3b7df
commit fc9ede3e09
4 changed files with 49 additions and 44 deletions

View file

@ -5,7 +5,7 @@
<SolidColorBrush x:Key="Brush.Window" Color="#FF252525"/> <SolidColorBrush x:Key="Brush.Window" Color="#FF252525"/>
<SolidColorBrush x:Key="Brush.TitleBar" Color="#FF1F1F1F"/> <SolidColorBrush x:Key="Brush.TitleBar" Color="#FF1F1F1F"/>
<SolidColorBrush x:Key="Brush.NewPageHover" Color="#FF404040"/> <SolidColorBrush x:Key="Brush.TabButtonHover" Color="#FF404040"/>
<SolidColorBrush x:Key="Brush.Popup" Color="#FF2B2B2B"/> <SolidColorBrush x:Key="Brush.Popup" Color="#FF2B2B2B"/>
<SolidColorBrush x:Key="Brush.Contents" Color="#FF1B1B1B"/> <SolidColorBrush x:Key="Brush.Contents" Color="#FF1B1B1B"/>
<SolidColorBrush x:Key="Brush.Badge" Color="#FF8F8F8F"/> <SolidColorBrush x:Key="Brush.Badge" Color="#FF8F8F8F"/>

View file

@ -3,12 +3,12 @@
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"> xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<SolidColorBrush x:Key="Brush.Logo" Color="#FFF05133"/> <SolidColorBrush x:Key="Brush.Logo" Color="#FFF05133"/>
<SolidColorBrush x:Key="Brush.Window" Color="#FFF8F8F8"/> <SolidColorBrush x:Key="Brush.Window" Color="#FFF0F5F9"/>
<SolidColorBrush x:Key="Brush.TitleBar" Color="White"/> <SolidColorBrush x:Key="Brush.TitleBar" Color="#FFCFDEEA"/>
<SolidColorBrush x:Key="Brush.NewPageHover" Color="#1D000000"/> <SolidColorBrush x:Key="Brush.TabButtonHover" Color="#1D000000"/>
<SolidColorBrush x:Key="Brush.Popup" Color="#FFF8F8F8"/> <SolidColorBrush x:Key="Brush.Popup" Color="#FFF8F8F8"/>
<SolidColorBrush x:Key="Brush.Contents" Color="White"/> <SolidColorBrush x:Key="Brush.Contents" Color="#FFFAFAFA"/>
<SolidColorBrush x:Key="Brush.Badge" Color="#FFAFAFAF"/> <SolidColorBrush x:Key="Brush.Badge" Color="#FFB0CEE8"/>
<SolidColorBrush x:Key="Brush.Decorator" Color="#FF6F6F6F"/> <SolidColorBrush x:Key="Brush.Decorator" Color="#FF6F6F6F"/>
<SolidColorBrush x:Key="Brush.DecoratorIcon" Color="#FFF8F8F8"/> <SolidColorBrush x:Key="Brush.DecoratorIcon" Color="#FFF8F8F8"/>
<SolidColorBrush x:Key="Brush.Conflict" Color="#FF836C2E"/> <SolidColorBrush x:Key="Brush.Conflict" Color="#FF836C2E"/>

View file

@ -30,7 +30,7 @@
x:Name="leftScroller" x:Name="leftScroller"
Click="ScrollLeft" Click="ScrollLeft"
Width="18" Padding="6" Width="18" Padding="6"
HoverBackground="{DynamicResource Brush.NewPageHover}" HoverBackground="{DynamicResource Brush.TabButtonHover}"
BorderThickness="0" BorderThickness="0"
Icon="{StaticResource Icon.ScrollLeft}" Icon="{StaticResource Icon.ScrollLeft}"
WindowChrome.IsHitTestVisibleInChrome="True" WindowChrome.IsHitTestVisibleInChrome="True"
@ -95,7 +95,7 @@
Margin="0,1,8,0" Padding="4" Margin="0,1,8,0" Padding="4"
ToolTip="{DynamicResource Text.Close}" ToolTip="{DynamicResource Text.Close}"
Icon="{StaticResource Icon.Close}" Icon="{StaticResource Icon.Close}"
HoverBackground="{DynamicResource Brush.NewPageHover}" HoverBackground="{DynamicResource Brush.TabButtonHover}"
Visibility="Hidden" Visibility="Hidden"
HorizontalAlignment="Right"/> HorizontalAlignment="Right"/>
@ -152,7 +152,7 @@
x:Name="rightScroller" x:Name="rightScroller"
Click="ScrollRight" Click="ScrollRight"
Width="18" Padding="6" Width="18" Padding="6"
HoverBackground="{DynamicResource Brush.NewPageHover}" HoverBackground="{DynamicResource Brush.TabButtonHover}"
BorderThickness="0" BorderThickness="0"
Icon="{StaticResource Icon.ScrollRight}" Icon="{StaticResource Icon.ScrollRight}"
WindowChrome.IsHitTestVisibleInChrome="True" WindowChrome.IsHitTestVisibleInChrome="True"

View file

@ -23,7 +23,7 @@
</Grid.ColumnDefinitions> </Grid.ColumnDefinitions>
<!-- Repositories Tool Bar --> <!-- Repositories Tool Bar -->
<Grid Grid.Row="0" Grid.Column="1" Margin="0,100,0,0"> <Grid Grid.Row="0" Grid.Column="1" Margin="2,100,2,0">
<Grid.ColumnDefinitions> <Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/> <ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="*"/> <ColumnDefinition Width="*"/>
@ -74,7 +74,7 @@
</Grid> </Grid>
<!-- Search Bar --> <!-- Search Bar -->
<Grid Grid.Row="1" Grid.Column="1" Margin="0,8" Height="28" VerticalAlignment="Top"> <Grid Grid.Row="1" Grid.Column="1" Margin="2,8" Height="28" VerticalAlignment="Top">
<Grid.ColumnDefinitions> <Grid.ColumnDefinitions>
<ColumnDefinition Width="24"/> <ColumnDefinition Width="24"/>
<ColumnDefinition Width="*"/> <ColumnDefinition Width="*"/>
@ -120,42 +120,47 @@
<Control MouseDoubleClick="OnDoubleClickRepository"> <Control MouseDoubleClick="OnDoubleClickRepository">
<Control.Template> <Control.Template>
<ControlTemplate> <ControlTemplate>
<Border <Grid Height="38" Margin="2">
Height="36" Margin="0,2" <Grid.ColumnDefinitions>
BorderThickness="1" BorderBrush="{DynamicResource Brush.Border2}" <ColumnDefinition Width="8"/>
Background="{DynamicResource Brush.Contents}"> <ColumnDefinition Width="*"/>
<Grid> <ColumnDefinition Width="32"/>
<Grid.ColumnDefinitions> <ColumnDefinition Width="32"/>
<ColumnDefinition Width="8"/> <ColumnDefinition Width="32"/>
<ColumnDefinition Width="*"/> <ColumnDefinition Width="32"/>
<ColumnDefinition Width="32"/> <ColumnDefinition Width="8"/>
<ColumnDefinition Width="32"/> </Grid.ColumnDefinitions>
<ColumnDefinition Width="32"/>
<ColumnDefinition Width="32"/>
<ColumnDefinition Width="8"/>
</Grid.ColumnDefinitions>
<Border Grid.Column="0" Width="4" HorizontalAlignment="Left" Background="{Binding Bookmark, Converter={StaticResource IntToBookmarkBrush}}"/> <Border
Grid.Column="0" Grid.ColumnSpan="7"
BorderThickness="1" BorderBrush="{DynamicResource Brush.Border2}"
Background="{DynamicResource Brush.Contents}">
<Border.Effect>
<DropShadowEffect Color="Black" ShadowDepth="2" BlurRadius="0" Opacity=".1"/>
</Border.Effect>
</Border>
<StackPanel Grid.Column="1" Margin="4,0" Orientation="Horizontal"> <Border Grid.Column="0" Width="4" HorizontalAlignment="Left" Background="{Binding Bookmark, Converter={StaticResource IntToBookmarkBrush}}"/>
<TextBlock Text="{Binding Name}" FontSize="12pt" FontFamily="{Binding Source={x:Static models:Preference.Instance}, Path=General.FontFamilyContent, Mode=OneWay}"/>
<TextBlock Text="{Binding Path}" FontSize="10pt" FontFamily="{Binding Source={x:Static models:Preference.Instance}, Path=General.FontFamilyContent, Mode=OneWay}" Margin="8,0" Foreground="{DynamicResource Brush.FG2}"/> <StackPanel Grid.Column="1" Margin="4,0" Orientation="Horizontal">
</StackPanel> <TextBlock Text="{Binding Name}" FontSize="12pt" FontFamily="{Binding Source={x:Static models:Preference.Instance}, Path=General.FontFamilyContent, Mode=OneWay}"/>
<TextBlock Text="{Binding Path}" FontSize="10pt" FontFamily="{Binding Source={x:Static models:Preference.Instance}, Path=General.FontFamilyContent, Mode=OneWay}" Margin="8,0" Foreground="{DynamicResource Brush.FG2}"/>
</StackPanel>
<Button Grid.Column="2" BorderThickness="0" Background="Transparent" ToolTip="{DynamicResource Text.RepoCM.Open}" Click="OnOpenRepository">
<Path Width="15" Data="{StaticResource Icon.Folder.Open}"/>
</Button>
<Button Grid.Column="3" Margin="8,0,0,0" BorderThickness="0" Background="Transparent" ToolTip="{DynamicResource Text.RepoCM.Explore}" Click="OnExploreRepository">
<Path Width="14" Data="{StaticResource Icon.DiffWith}"/>
</Button>
<Button Grid.Column="4" Margin="8,0,0,0" BorderThickness="0" Background="Transparent" ToolTip="{DynamicResource Text.Welcome.OpenTerminal}" Click="OnOpenRepositoryTerminal">
<Path Width="14" Data="{StaticResource Icon.Terminal}"/>
</Button>
<Button Grid.Column="5" Margin="8,0,0,0" BorderThickness="0" Background="Transparent" ToolTip="{DynamicResource Text.Welcome.Delete}" Click="OnRemoveRepository">
<Path Width="10" Data="{StaticResource Icon.Close}"/>
</Button>
</Grid>
<Button Grid.Column="2" BorderThickness="0" Background="Transparent" ToolTip="{DynamicResource Text.RepoCM.Open}" Click="OnOpenRepository">
<Path Width="15" Data="{StaticResource Icon.Folder.Open}"/>
</Button>
<Button Grid.Column="3" Margin="8,0,0,0" BorderThickness="0" Background="Transparent" ToolTip="{DynamicResource Text.RepoCM.Explore}" Click="OnExploreRepository">
<Path Width="14" Data="{StaticResource Icon.DiffWith}"/>
</Button>
<Button Grid.Column="4" Margin="8,0,0,0" BorderThickness="0" Background="Transparent" ToolTip="{DynamicResource Text.Welcome.OpenTerminal}" Click="OnOpenRepositoryTerminal">
<Path Width="14" Data="{StaticResource Icon.Terminal}"/>
</Button>
<Button Grid.Column="5" Margin="8,0,0,0" BorderThickness="0" Background="Transparent" ToolTip="{DynamicResource Text.Welcome.Delete}" Click="OnRemoveRepository">
<Path Width="10" Data="{StaticResource Icon.Close}"/>
</Button>
</Grid>
</Border>
</ControlTemplate> </ControlTemplate>
</Control.Template> </Control.Template>
</Control> </Control>