<ResourceDictionary
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:controls="using:Wino.Controls">

    <Style TargetType="controls:ImagePreviewControl">
        <Style.Setters>
            <Setter Property="Width" Value="34" />
            <Setter Property="Height" Value="34" />
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="controls:ImagePreviewControl">
                        <Grid>
                            <!--  Ellipse Initials  -->
                            <Grid x:Name="EllipseInitialsGrid">
                                <Ellipse
                                    x:Name="Ellipse"
                                    Grid.RowSpan="2"
                                    Width="{TemplateBinding Width}"
                                    Height="{TemplateBinding Height}"
                                    HorizontalAlignment="Center"
                                    VerticalAlignment="Center" />
                                <TextBlock
                                    x:Name="InitialsTextBlock"
                                    HorizontalAlignment="Center"
                                    VerticalAlignment="Center"
                                    FontWeight="SemiBold"
                                    Foreground="White" />
                            </Grid>

                            <!--  Squircle for favicon  -->
                            <Border
                                x:Name="FaviconSquircle"
                                Width="{TemplateBinding Width}"
                                Height="{TemplateBinding Height}"
                                HorizontalAlignment="Center"
                                VerticalAlignment="Center"
                                Background="Transparent"
                                CornerRadius="6"
                                Visibility="Collapsed">
                                <Image x:Name="FaviconImage" Stretch="Fill" />
                            </Border>

                            <Image
                                x:Name="KnownHostImage"
                                Width="{TemplateBinding Width}"
                                Height="{TemplateBinding Height}"
                                HorizontalAlignment="Center"
                                VerticalAlignment="Center"
                                Stretch="UniformToFill"
                                Visibility="Collapsed" />
                        </Grid>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style.Setters>
    </Style>
</ResourceDictionary>
