<UserControl
    x:Class="Sonex.Client.Controls.BoolProperty"
    x:Name="Root"
    Width="400"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">

    <Grid ColumnSpacing="10" MinHeight="30">
        <Grid.ColumnDefinitions>
            <ColumnDefinition Width="{Binding HeaderWidth, ElementName=Root}" />
            <ColumnDefinition Width="*" />
        </Grid.ColumnDefinitions>

        <TextBlock
            Text="{Binding Header, ElementName=Root}"
            VerticalAlignment="Center"
            FontSize="12"
            Foreground="{ThemeResource TextFillColorSecondaryBrush}" />

        <CheckBox
            x:Name="ValueCheckBox"
            Grid.Column="1"
            IsChecked="{Binding Value, ElementName=Root, Mode=TwoWay}"
            Content="{Binding Text, ElementName=Root}"
            HorizontalAlignment="Left"
            VerticalAlignment="Center"
            MinHeight="28"
            Height="28"
            Padding="0"
            FontSize="12" />
    </Grid>
</UserControl>
