<ResourceDictionary
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:noesis="clr-namespace:NoesisGUIExtensions;assembly=Noesis.GUI.Extensions"
    xmlns:system="clr-namespace:System;assembly=mscorlib"
    xmlns:i="http://schemas.microsoft.com/expression/2010/interactivity"
    xmlns:ei="http://schemas.microsoft.com/expression/2010/interactions"
    xmlns:b="http://schemas.microsoft.com/xaml/behaviors">

    <!-- DRAGGED ITEM TEMPLATE -->
    <!--////////////////////////////////////////////////////////////////////-->
    <ControlTemplate x:Key="DraggedItemTemplate" TargetType="{x:Type ContentControl}">
        <Grid>
            <Viewbox>
                <Viewbox.RenderTransform>
                    <TranslateTransform X="-30" Y="-30" />
                </Viewbox.RenderTransform>

                <Image Source="{Binding Content.Icon, RelativeSource={RelativeSource TemplatedParent}}" />
            </Viewbox>

            <TextBlock
                x:Name="ItemAmount"
                Style="{DynamicResource SlotItemAmountStyle}"
                Text="{Binding Content.DisplayAmount, RelativeSource={RelativeSource TemplatedParent}}">

                <TextBlock.RenderTransform>
                    <TranslateTransform X="-30" Y="-30" />
                </TextBlock.RenderTransform>
            </TextBlock>
        </Grid>

        <ControlTemplate.Triggers>
            <Trigger Property="Content" Value="{x:Null}">
                <Setter Property="Visibility" Value="Collapsed" />
            </Trigger>
        </ControlTemplate.Triggers>
    </ControlTemplate>

    <!-- DRAGGED ITEM STYLE -->
    <!--////////////////////////////////////////////////////////////////////-->
    <Style x:Key="DraggedItemStyle" TargetType="{x:Type ContentControl}">
        <Setter Property="IsHitTestVisible" Value="False" />
        <Setter Property="Template" Value="{StaticResource DraggedItemTemplate}" />
    </Style>
</ResourceDictionary>
