Files
CustomerPanel-Test/UserControls/Incidents.xaml

167 lines
7.3 KiB
XML

<UserControl x:Class="C4IT_CustomerPanel.UserControls.Incidents"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:local="clr-namespace:C4IT_CustomerPanel.UserControls"
xmlns:resx="clr-namespace:C4IT_CustomerPanel.Properties"
mc:Ignorable="d"
d:DesignHeight="450" d:DesignWidth="800">
<UserControl.Resources>
<Style TargetType="Button"
x:Key="ButtonStyle">
<Setter Property="Foreground"
Value="{DynamicResource buttonTextColor}" />
<Setter Property="Background"
Value="{DynamicResource inactiveButtonColor}" />
<Setter Property="BorderBrush"
Value="{DynamicResource panelBorderColor}" />
<Setter Property="BorderThickness"
Value="1" />
<Setter Property="Padding"
Value="12,6" />
<Setter Property="Cursor"
Value="Hand" />
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type Button}">
<Border Background="{TemplateBinding Background}"
BorderBrush="{TemplateBinding BorderBrush}"
BorderThickness="{TemplateBinding BorderThickness}"
CornerRadius="10">
<ContentPresenter HorizontalAlignment="Center"
VerticalAlignment="Center"
Margin="{TemplateBinding Padding}" />
</Border>
</ControlTemplate>
</Setter.Value>
</Setter>
<Style.Triggers>
<Trigger Property="IsMouseOver"
Value="True">
<Setter Property="Background"
Value="{DynamicResource activeButtonColor}" />
<Setter Property="Foreground"
Value="White" />
</Trigger>
</Style.Triggers>
</Style>
<Style x:Key="ReadAllIconStyle"
TargetType="{x:Type Image}">
<Setter Property="Cursor"
Value="Hand" />
<Setter Property="Width"
Value="24" />
<Setter Property="Height"
Value="24" />
<Setter Property="Opacity"
Value="0.92" />
<Setter Property="RenderTransformOrigin"
Value="0.5,0.5" />
<Setter Property="RenderTransform">
<Setter.Value>
<ScaleTransform ScaleX="1"
ScaleY="1" />
</Setter.Value>
</Setter>
<Style.Triggers>
<Trigger Property="IsMouseOver"
Value="True">
<Setter Property="Opacity"
Value="1" />
<Setter Property="RenderTransform">
<Setter.Value>
<ScaleTransform ScaleX="1.06"
ScaleY="1.06" />
</Setter.Value>
</Setter>
</Trigger>
</Style.Triggers>
</Style>
</UserControl.Resources>
<Grid x:Name="GridEtc"
Width="500"
Canvas.Left="1000"
HorizontalAlignment="Center"
Canvas.Top="10">
<Grid.RowDefinitions>
<RowDefinition Height="*" />
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="100*" />
<ColumnDefinition Width="185*" />
<ColumnDefinition Width="185*" />
<ColumnDefinition Width="30*" />
</Grid.ColumnDefinitions>
<Canvas x:Name="Canvas2"
Grid.Column="1"
Grid.ColumnSpan="2"
Grid.Row="0"
Height="560">
<Image Source="{DynamicResource appbar_clipboard_variant_text}"
Width="36"
Height="36"
Margin="0,6,0,0"
Tag="MAINICO" />
<Label Foreground="{DynamicResource sectionTitleColor}"
Content="{x:Static resx:Resources.incidents}"
FontSize="19"
FontWeight="SemiBold"
Canvas.Top="6"
Height="36"
VerticalContentAlignment="Center"
Padding="0"
Canvas.Left="40" />
<ScrollViewer x:Name="CanvasIncident"
Canvas.Top="56"
Canvas.Left="0"
MaxHeight="448"
MinHeight="60"
HorizontalScrollBarVisibility="Disabled"
VerticalScrollBarVisibility="Auto"
Width="{Binding ActualWidth, ElementName=Canvas2, Mode=OneWay}"
Visibility="Visible" />
<StackPanel x:Name="NoIncident"
Background="Transparent"
Width="{Binding ActualWidth, ElementName=Canvas2, Mode=OneWay}"
Height="58"
Canvas.Top="56"
Canvas.Left="0">
<Border Margin="2,0,2,0"
BorderThickness="1"
CornerRadius="10"
BorderBrush="{DynamicResource cardBorderColor}"
Background="{DynamicResource cardBackgroundColor}">
<TextBlock Text="{x:Static resx:Resources.noincidents}"
Margin="18,12,10,0"
Foreground="{DynamicResource subtleTextColor}" />
</Border>
</StackPanel>
<Button Foreground="{DynamicResource buttonTextColor}"
Style="{DynamicResource PrimaryActionButtonStyle}"
Canvas.Top="510"
Canvas.Left="15"
Width="320"
Height="40"
Content="{x:Static resx:Resources.createNewTicket}"
FontSize="16"
x:Name="BtnCreateNewTicket"
Click="OnCreateNewTicketClicked"
Margin="0" />
<Image Source="{DynamicResource appbar_list_check}"
x:Name="buttonReadAllTickets"
Style="{StaticResource ReadAllIconStyle}"
Tag="readAllTickets"
PreviewMouseDown="ReadAll_PreviewMouseDown"
Canvas.Left="338"
Canvas.Top="14"
ToolTip="{x:Static resx:Resources.removeMarkups}" />
</Canvas>
</Grid>
</UserControl>