Skip to content

Commit

Permalink
Added placeholder in AI Page palette section (#352)
Browse files Browse the repository at this point in the history
  • Loading branch information
lpeyr committed Dec 10, 2023
1 parent bd2404b commit 43e0a09
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 3 deletions.
16 changes: 13 additions & 3 deletions ColorPicker/Pages/AiGenPage.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,6 @@
Grid.Row="2"
HorizontalAlignment="Center"
VerticalAlignment="Center"
d:Visibility="Visible"
Visibility="Collapsed">
<Border
x:Name="ColorBorder"
Expand Down Expand Up @@ -217,11 +216,22 @@
Grid.Row="2"
HorizontalAlignment="Center"
VerticalAlignment="Center"
d:Visibility="Visible"
Visibility="Collapsed">
<StackPanel x:Name="EmptyPalettePlaceholder" Margin="10">
<TextBlock
HorizontalAlignment="Center"
FontFamily="..\Fonts\#FluentSystemIcons-Regular"
FontSize="32"
Text="&#xF2F6;" />
<TextBlock HorizontalAlignment="Center" Text="{x:Static lang:Resources.EmptyAiPlaceholder}" />
</StackPanel>
<StackPanel
x:Name="PaletteBordersPanel"
Margin="10"
HorizontalAlignment="Center"
Orientation="Horizontal">
Orientation="Horizontal"
Visibility="Collapsed">
<Border
x:Name="C1"
Width="50"
Expand Down Expand Up @@ -314,7 +324,7 @@
</Border>

</StackPanel>
<StackPanel Orientation="Horizontal">
<StackPanel HorizontalAlignment="Center" Orientation="Horizontal">
<Border
Width="250"
HorizontalAlignment="Center"
Expand Down
3 changes: 3 additions & 0 deletions ColorPicker/Pages/AiGenPage.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,9 @@ private void LoadBorders(string[] colors)
C3Shadow.Color = Color.FromRgb(convertedColors[2].R, convertedColors[2].G, convertedColors[2].B);
C4Shadow.Color = Color.FromRgb(convertedColors[3].R, convertedColors[3].G, convertedColors[3].B);
C5Shadow.Color = Color.FromRgb(convertedColors[4].R, convertedColors[4].G, convertedColors[4].B);

PaletteBordersPanel.Visibility = Visibility.Visible;
EmptyPalettePlaceholder.Visibility = Visibility.Collapsed;
}
catch (Exception e)
{
Expand Down

0 comments on commit 43e0a09

Please sign in to comment.