<UserControl xmlns="https://github.com/avaloniaui"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
             xmlns:ui="clr-namespace:PixiEditor.Extensions.UI;assembly=PixiEditor.Extensions"
             xmlns:converters="clr-namespace:PixiEditor.AvaloniaUI.Helpers.Converters"
             mc:Ignorable="d" d:DesignWidth="800" d:DesignHeight="450"
             x:Class="PixiEditor.AvaloniaUI.Views.Shortcuts.ShortcutHint"
             Name="uc">
    <StackPanel Orientation="Horizontal">
        <ItemsControl
            ItemsSource="{Binding #uc.Shortcut.Modifiers, Converter={converters:ModifierFlagToModifiersConverter}}">
            <ItemsControl.ItemTemplate>
                <DataTemplate DataType="{x:Type KeyModifiers}">
                    <Border Classes="KeyBorder">
                        <TextBlock
                            ui:Translator.LocalizedString="{Binding Converter={converters:KeyToStringConverter}}"
                            Classes="KeyBorderText" TextAlignment="Center" MinWidth="33" />
                    </Border>
                </DataTemplate>
            </ItemsControl.ItemTemplate>
            <ItemsControl.ItemsPanel>
                <ItemsPanelTemplate>
                    <StackPanel Orientation="Horizontal" />
                </ItemsPanelTemplate>
            </ItemsControl.ItemsPanel>
        </ItemsControl>
        <Border Classes="KeyBorder KeyBorderLast">
            <TextBlock
                Text="{Binding #uc.Shortcut.Key, Converter={converters:KeyToStringConverter}}"
                Classes="KeyBorderText" TextAlignment="Center" MinWidth="15" />
        </Border>
    </StackPanel>
</UserControl>