<Application xmlns="https://github.com/avaloniaui"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:local="using:VeloeMinecraftLauncher"
             x:Class="VeloeMinecraftLauncher.App"
	         RequestedThemeVariant="Dark">
    <Application.DataTemplates>
        <local:ViewLocator/>
    </Application.DataTemplates>
	<Application.Styles>
		<FluentTheme />
	</Application.Styles>
	<Application.Resources>
		<ControlTheme x:Key="FixDataValidation" TargetType="NumericUpDown">
			<Setter Property="Foreground" Value="{DynamicResource TextControlForeground}" />
			<Setter Property="Background" Value="{DynamicResource TextControlBackground}" />
			<Setter Property="BorderThickness" Value="{DynamicResource TextControlBorderThemeThickness}" />
			<Setter Property="BorderBrush" Value="{DynamicResource TextControlBorderBrush}" />
			<Setter Property="MinHeight" Value="{DynamicResource TextControlThemeMinHeight}" />
			<Setter Property="MinWidth" Value="{DynamicResource TextControlThemeMinWidth}" />
			<Setter Property="Padding" Value="{DynamicResource TextControlThemePadding}" />
			<Setter Property="CornerRadius" Value="{DynamicResource ControlCornerRadius}" />
			<Setter Property="Template">
				<ControlTemplate>
					<DataValidationErrors>
						<ButtonSpinner Name="PART_Spinner"
									   Background="{TemplateBinding Background}"
									   BorderThickness="{TemplateBinding BorderThickness}"
									   BorderBrush="{TemplateBinding BorderBrush}"
									   CornerRadius="{TemplateBinding CornerRadius}"
									   IsTabStop="False"
									   Padding="0"
									   MinWidth="0"
									   HorizontalContentAlignment="Stretch"
									   VerticalContentAlignment="Stretch"
									   AllowSpin="{TemplateBinding AllowSpin}"
									   ShowButtonSpinner="{TemplateBinding ShowButtonSpinner}"
									   ButtonSpinnerLocation="{TemplateBinding ButtonSpinnerLocation}">
							<TextBox Name="PART_TextBox"
									 Background="Transparent"
									 BorderBrush="Transparent"
									 Margin="-1"
									 Padding="{TemplateBinding Padding}"
									 MinWidth="0"
									 Foreground="{TemplateBinding Foreground}"
									 Watermark="{TemplateBinding Watermark}"
									 IsReadOnly="{TemplateBinding IsReadOnly}"
									 VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}"
									 HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}"
									 Text="{TemplateBinding Text}"
									 TextAlignment="{TemplateBinding TextAlignment}"
									 AcceptsReturn="False"
									 TextWrapping="NoWrap"
									 InnerLeftContent="{Binding InnerLeftContent, RelativeSource={RelativeSource TemplatedParent}}"
									 InnerRightContent="{Binding InnerRightContent, RelativeSource={RelativeSource TemplatedParent}}"/>
						</ButtonSpinner>
					</DataValidationErrors>
				</ControlTemplate>
			</Setter>
		</ControlTheme>
	</Application.Resources>
</Application>
