<UserControl
    DockPanel.Dock="Right"
    d:DesignHeight="450"
    d:DesignWidth="800"
    mc:Ignorable="d"
    x:Class="PicView.Avalonia.Views.UC.Buttons.SettingsMenuButton"
    x:DataType="viewModels:MainViewModel"
    xmlns="https://github.com/avaloniaui"
    xmlns:customControls="clr-namespace:PicView.Avalonia.CustomControls"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    xmlns:viewModels="clr-namespace:PicView.Avalonia.ViewModels"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
    <customControls:IconButton
        Background="{DynamicResource WindowSecondaryBackgroundColor}"
        BorderBrush="{DynamicResource MainBorderColor}"
        BorderThickness="1,0,0,0"
        Classes="hover"
        ClickMode="Press"
        Foreground="{DynamicResource MainTextColor}"
        Icon="{StaticResource MenuImage}"
        IconHeight="12"
        IconWidth="12"
        IsRepeatEnabled="False"
        Width="30"
        x:Name="SettingsButton">
        <customControls:IconButton.Flyout>
            <MenuFlyout FlyoutPresenterClasses="noCornerRadius" Placement="Bottom">
                <MenuItem
                    Command="{CompiledBinding Tools.ShowSettingsFileCommand}"
                    Foreground="{DynamicResource MainTextColor}"
                    Header="UserSettings.json"
                    x:Name="UserSettingsItem">
                    <MenuItem.Icon>
                        <Image
                            Height="12"
                            Source="{StaticResource BracesImage}"
                            Width="12" />
                    </MenuItem.Icon>
                </MenuItem>
                <MenuItem
                    Command="{CompiledBinding Tools.ShowKeybindingsFileCommand}"
                    Foreground="{DynamicResource MainTextColor}"
                    Header="keybindings.json"
                    x:Name="KeybindingsItem">
                    <MenuItem.Icon>
                        <Image
                            Height="12"
                            Source="{StaticResource BracesImage}"
                            Width="12" />
                    </MenuItem.Icon>
                </MenuItem>
                <MenuItem
                    Command="{CompiledBinding Tools.ResetSettingsCommand}"
                    Foreground="{DynamicResource MainTextColor}"
                    Header="{CompiledBinding Translation.ResetButtonText.Value,
                                             Mode=OneWay}">
                    <MenuItem.Icon>
                        <Image
                            Height="12"
                            Source="{StaticResource ResetImage}"
                            Width="12" />
                    </MenuItem.Icon>
                </MenuItem>
            </MenuFlyout>
        </customControls:IconButton.Flyout>
    </customControls:IconButton>
</UserControl>