App.xaml

Task 4 of PBKK
mail@pastecode.io avatar
unknown
plain_text
2 years ago
16 kB
1
Indexable
Never
<Application x:Class="Tugas3_PBKK_Dashboard.App"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:local="clr-namespace:Tugas3_PBKK_Dashboard"
             xmlns:fa="http://schemas.fontawesome.io/icons/"
             StartupUri="MainWindow.xaml">
    <Application.Resources>


        <Style x:Key="menuButton" TargetType="Button">
            <Setter Property="Height" Value="47"/>
            <Setter Property="Width" Value="217"/>
            <Setter Property="Background" Value="Transparent"/>
            <Setter Property="Foreground" Value="#f0f0f0"/>
            <Setter Property="Margin" Value="0"/>
            <Setter Property="HorizontalAlignment" Value="Right"/>
            <Setter Property="FocusVisualStyle" Value="{x:Null}"/>
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="Button">
                        <Border Background="{TemplateBinding Background}" CornerRadius="20" Padding="20 0" BorderThickness="3 0 0 0" BorderBrush="Transparent">
                            <ContentPresenter HorizontalAlignment="Stretch" VerticalAlignment="Center"/>
                        </Border>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
            <Style.Triggers>
                <Trigger Property="IsMouseOver" Value="True">
                    <Setter Property="Background" Value="#21203b"/>
                    <Setter Property="Foreground" Value="#e9e9e9"/>
                    <Setter Property="Template">
                        <Setter.Value>
                            <ControlTemplate TargetType="Button">
                                <Border Background="{TemplateBinding Background}" CornerRadius="20" Padding="20 0" BorderThickness="3 0 0 0">
                                    <Border.BorderBrush>
                                        <LinearGradientBrush StartPoint="0.5,0" EndPoint="0.5,1">
                                            <GradientStop Color="#d489ff" Offset="0"/>
                                            <GradientStop Color="#7985ff" Offset="0.5"/>
                                            <GradientStop Color="#6ad8fd" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Border.BorderBrush>
                                    <ContentPresenter HorizontalAlignment="Stretch" VerticalAlignment="Center"/>
                                </Border>
                            </ControlTemplate>
                        </Setter.Value>
                    </Setter>
                </Trigger>
                <Trigger Property="IsMouseCaptured" Value="True">
                    <Setter Property="Background" Value="#1a192e"/>
                    <Setter Property="Foreground" Value="#ffff"/>
                </Trigger>
            </Style.Triggers>
            
        </Style>


        <Style x:Key="buttonIcon" TargetType="fa:ImageAwesome">
            <Setter Property="Foreground" Value="{Binding Path=Foreground, RelativeSource={RelativeSource FindAncestor, AncestorType={x:Type Button}}}"/>
            <Setter Property="Width" Value="18"/>
            <Setter Property="Height" Value="18"/>
        </Style>

        <Style x:Key="buttonIconExpanded" TargetType="fa:ImageAwesome">
            <Setter Property="Foreground" Value="{Binding Path=Foreground, RelativeSource={RelativeSource FindAncestor, AncestorType={x:Type Button}}}"/>
            <Setter Property="Width" Value="6"/>
            <Setter Property="HorizontalAlignment" Value="Right"/>
            <Setter Property="Visibility" Value="Hidden"/>
            <Style.Triggers>
                <DataTrigger Binding="{Binding Path=IsMouseOver, RelativeSource={RelativeSource Mode=FindAncestor, AncestorType=Button}}" Value="True">
                    <Setter Property="Visibility" Value="Visible"/>
                </DataTrigger>
            </Style.Triggers>
        </Style>


        <Style x:Key="buttonText" TargetType="TextBlock">
            <Setter Property="Margin" Value="13 0 0 0"/>
            <Setter Property="FontSize" Value="12"/>
            <Setter Property="VerticalAlignment" Value="Center"/>
        </Style>

        <Style x:Key="activeMenuButton" TargetType="Button" BasedOn="{StaticResource menuButton}">
            <Setter Property="Background" Value="#21203b"/>
            <Setter Property="Foreground" Value="#e9e9e9"/>
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="Button">
                        <Border Background="{TemplateBinding Background}" CornerRadius="20" Padding="20 0" BorderThickness="3 0 0 0">
                            <Border.BorderBrush>
                                <LinearGradientBrush StartPoint="0.5,0" EndPoint="0.5,1">
                                    <GradientStop Color="#d489ff" Offset="0"/>
                                    <GradientStop Color="#7985ff" Offset="0.5"/>
                                    <GradientStop Color="#6ad8fd" Offset="1"/>
                                </LinearGradientBrush>
                            </Border.BorderBrush>
                            <ContentPresenter HorizontalAlignment="Stretch" VerticalAlignment="Center"/>
                        </Border>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>


        <Style x:Key="border" TargetType="Border">
            <Setter Property="Background" Value="#362f54"/>
            <Setter Property="Padding" Value="10"/>
            <Setter Property="CornerRadius" Value="25"/>
            <Setter Property="VerticalAlignment" Value="top"/>
        </Style>

        <Style x:Key="tabButton" TargetType="Button">
            <Setter Property="Height" Value="50"/>
            <Setter Property="Background" Value="Transparent"/>
            <Setter Property="Foreground" Value="#fcfcfc"/>
            <Setter Property="FocusVisualStyle" Value="{x:Null}"/>
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="Button">
                        <Border Background="{TemplateBinding Background}" Padding="20 10" BorderThickness="0 0 0 2" BorderBrush="#3f375f">
                            <ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
                        </Border>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
            <Style.Triggers>
                <Trigger Property="IsMouseOver" Value="True">
                    <Setter Property="Foreground" Value="#e9e9e9"/>
                    <Setter Property="Template">
                        <Setter.Value>
                            <ControlTemplate TargetType="Button">
                                <Border Background="{TemplateBinding Background}" Padding="20 10" BorderThickness="0 0 0 2">
                                    <Border.BorderBrush>
                                        <LinearGradientBrush StartPoint="0,0" EndPoint="1,0">
                                            <GradientStop Color="#d489ff" Offset="0"/>
                                            <GradientStop Color="#7985ff" Offset="0.5"/>
                                            <GradientStop Color="#6ad8fd" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Border.BorderBrush>
                                    <ContentPresenter HorizontalAlignment="Stretch" VerticalAlignment="Center"/>
                                </Border>
                            </ControlTemplate>
                        </Setter.Value>
                    </Setter>
                </Trigger>
                <Trigger Property="IsMouseCaptured" Value="True">
                    <Setter Property="Foreground" Value="#ffff"/>
                </Trigger>
            </Style.Triggers>
        </Style>

        <Style x:Key="activeTabButton" TargetType="Button" BasedOn="{StaticResource tabButton}">
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="Button">
                        <Border Background="{TemplateBinding Background}" Padding="20 10" BorderThickness="0 0 0 2">
                            <Border.BorderBrush>
                                <LinearGradientBrush StartPoint="0,0" EndPoint="1,0">
                                    <GradientStop Color="#d489ff" Offset="0"/>
                                    <GradientStop Color="#7985ff" Offset="0.5"/>
                                    <GradientStop Color="#6ad8fd" Offset="1"/>
                                </LinearGradientBrush>
                            </Border.BorderBrush>
                            <ContentPresenter HorizontalAlignment="Stretch" VerticalAlignment="Center"/>
                        </Border>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>

        <Style x:Key="textLabel" TargetType="TextBlock">
            <Setter Property="Foreground" Value="#fcfcfc"/>
        </Style>

        <Style TargetType="TextBox">
            <Setter Property="Background" Value="#3f375f"/>
            <Setter Property="FocusVisualStyle" Value="{x:Null}"/>
            <Setter Property="Padding" Value="15 12"/>
            <Setter Property="FontSize" Value="12"/>
            <Setter Property="Foreground" Value="#fcfcfc"/>
            <Style.Resources>
                <Style TargetType="Border">
                    <Setter Property="CornerRadius" Value="15"/>
                </Style>
            </Style.Resources>
        </Style>

        <Style x:Key="sendButton" TargetType="Button">
            <Setter Property="Height" Value="50"/>
            <Setter Property="Foreground" Value="#f0f0f0"/>
            <Setter Property="Margin" Value="0 15 0 0"/>
            <Setter Property="FocusVisualStyle" Value="{x:Null}"/>
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="Button">
                        <Border Padding="20 0" CornerRadius="20" BorderThickness="0">
                            <Border.Background>
                                <LinearGradientBrush StartPoint="0,1" EndPoint="1,0">
                                    <GradientStop Color="#7985ff" Offset="0"/>
                                    <GradientStop Color="#6ad8fd" Offset="1"/>
                                </LinearGradientBrush>
                            </Border.Background>
                            <ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
                        </Border>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
            <Style.Triggers>
                <Trigger Property="IsMouseOver" Value="True">
                    <Setter Property="Foreground" Value="White"/>
                    <Setter Property="FontWeight" Value="Bold"/>
                    <Setter Property="Template">
                        <Setter.Value>
                            <ControlTemplate TargetType="Button">
                                <Border  CornerRadius="20" Padding="20 0" BorderThickness="0">
                                    <Border.Background>
                                        <LinearGradientBrush StartPoint="0,1" EndPoint="1,0">
                                            <GradientStop Color="#7985ff" Offset="0.5"/>
                                            <GradientStop Color="#6ad8fd" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Border.Background>
                                    <ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
                                </Border>
                            </ControlTemplate>
                        </Setter.Value>
                    </Setter>
                </Trigger>
            </Style.Triggers>
        </Style>

        <Style x:Key="whiteIcon" TargetType="fa:ImageAwesome">
            <Setter Property="Foreground" Value="#f0f0f0"/>
            <Setter Property="Width" Value="15"/>
            <Setter Property="Height" Value="15"/>
        </Style>

        <Style x:Key="cardBorder" TargetType="Border">
            <Setter Property="Height" Value="150"/>
            <Setter Property="Padding" Value="10"/>
            <Setter Property="CornerRadius" Value="25"/>
            <Setter Property="VerticalAlignment" Value="Top"/>
        </Style>

        <Style x:Key="bankCardNumber" TargetType="TextBlock">
            <Setter Property="Foreground" Value="#fcfcfc"/>
            <Setter Property="FontSize" Value="16"/>
            <Setter Property="Margin" Value="17 10"/>
        </Style>

        <Style x:Key="topMenuIcon" TargetType="fa:ImageAwesome">
            <Setter Property="Foreground" Value="#f0f0f0"/>
            <Setter Property="Width" Value="16"/>
            <Setter Property="Height" Value="14"/>
            <Setter Property="Margin" Value="4"/>
        </Style>

        <Style x:Key="button" TargetType="Button">
            <Setter Property="Foreground" Value="#f0f0f0"/>
            <Setter Property="Background" Value="Transparent"/>
            <Setter Property="FocusVisualStyle" Value="{x:Null}"/>
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="Button">
                        <Border Background="{TemplateBinding Background}" Padding="10 8" CornerRadius="10" BorderThickness="1" BorderBrush="#504373">
                            <ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
                        </Border>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
            <Style.Triggers>
                <Trigger Property="IsMouseOver" Value="True">
                    <Setter Property="Background" Value="#504373"/>
                    <Setter Property="Foreground" Value="#f0f0f0"/>
                </Trigger>
                <Trigger Property="IsMouseCaptured" Value="True">
                    <Setter Property="Background" Value="#2f2745"/>
                    <Setter Property="Foreground" Value="White"/>
                </Trigger>
            </Style.Triggers>
        </Style>

        <Style x:Key="topMenuButton" TargetType="Button" BasedOn="{StaticResource button}">
            <Setter Property="Background" Value="#3c315b"/>
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="Button">
                        <Border Background="{TemplateBinding Background}" Padding="10 8" CornerRadius="10" BorderThickness="1" BorderBrush="#504373">
                            <ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
                        </Border>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>

        <Style x:Key="fillButton" TargetType="Button" BasedOn="{StaticResource button}">
            <Setter Property="Background" Value="#6b5a96"/>
        </Style>

    </Application.Resources>
</Application>