<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:conditionTypes="clr-namespace:Artemis.UI.Screens.ProfileEditor.DisplayCondition.ConditionTypes"
             xmlns:avalonia="clr-namespace:Material.Icons.Avalonia;assembly=Material.Icons.Avalonia"
             mc:Ignorable="d" d:DesignWidth="800" d:DesignHeight="450"
             x:Class="Artemis.UI.Screens.ProfileEditor.DisplayCondition.ConditionTypes.StaticConditionView"
             x:DataType="conditionTypes:StaticConditionViewModel">
    <DockPanel HorizontalAlignment="Stretch">
        <DockPanel.Styles>
            <Style Selector="DockPanel > TextBlock">
                <Setter Property="Margin" Value="0 5" />
            </Style>
        </DockPanel.Styles>
        <TextBlock DockPanel.Dock="Top">While condition is met..</TextBlock>
        <ComboBox DockPanel.Dock="Top" PlaceholderText="Select a play mode" HorizontalAlignment="Stretch" SelectedIndex="{CompiledBinding SelectedPlayMode}">
            <ComboBoxItem>Repeat the main segment</ComboBoxItem>
            <ComboBoxItem>Play the main segment once</ComboBoxItem>
        </ComboBox>

        <TextBlock DockPanel.Dock="Top">And when no longer met..</TextBlock>
        <ComboBox DockPanel.Dock="Top" PlaceholderText="Select a stop mode" HorizontalAlignment="Stretch" SelectedIndex="{CompiledBinding SelectedStopMode}">
            <ComboBoxItem>Finish the main segment</ComboBoxItem>
            <ComboBoxItem>Skip forward to the end segment</ComboBoxItem>
        </ComboBox>

        <DockPanel DockPanel.Dock="Top" Margin="0 5">
            <avalonia:MaterialIcon Kind="InfoCircle" Margin="5 0" />
            <TextBlock Foreground="{DynamicResource TextFillColorSecondaryBrush}"
                       TextWrapping="Wrap">
                The start- and end-segments are played once each time the condition is met.
            </TextBlock>
        </DockPanel>

        <Button DockPanel.Dock="Bottom"
                ToolTip.Tip="Open editor"
                Margin="0 15 0 5"
                Command="{CompiledBinding OpenEditor}"
                HorizontalAlignment="Stretch"
                VerticalAlignment="Bottom">
            Edit condition script
        </Button>
    </DockPanel>
</UserControl>