Files
DE70/UserControl/WelcomeUC.xaml
T
2024-09-21 07:03:45 +07:00

67 lines
4.3 KiB
XML

<UserControl x:Class="SafeBagDE70.WelcomeUC"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:local="clr-namespace:SafeBagDE70"
xmlns:hc="https://handyorg.github.io/handycontrol"
x:Name="ucWelcome"
mc:Ignorable="d">
<Grid>
<Grid x:Name="gridMain" Visibility="Collapsed">
<Grid.RowDefinitions>
<RowDefinition Height="4*"/>
<RowDefinition Height="4*"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<!-- Top Section -->
<StackPanel Grid.Row="0" HorizontalAlignment="Center" VerticalAlignment="Center" Margin="0,0,0,0">
<Image Source="../icon/logo.ico" Width="200" Height="200" Margin="0,10,0,10" Stretch="UniformToFill"/>
<TextBlock Text="Xin chào! Hãy lựa chọn hình thức đăng nhập để tiếp tục" FontSize="24" FontWeight="Bold" TextAlignment="Center"/>
</StackPanel>
<!-- Middle Section -->
<Grid Grid.Row="1" HorizontalAlignment="Center" VerticalAlignment="Center">
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="Auto"/>
<RowDefinition Height="Auto"/>
<RowDefinition Height="Auto"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Button hc:IconElement.Geometry="{StaticResource FullScreenGeometry}" Grid.Column="0" Grid.Row="0" x:Name="btnQRCodeLogin" Content="QR CODE" Width="200" Height="100" Margin="0,0,10,0" FontSize="20" FontWeight="Bold" Click="btnQRCodeLogin_Click"/>
<Button Grid.Column="2" Grid.Row="0" x:Name="btnPinCodeLogin" Content="PIN CODE" Width="200" Height="100" Margin="10,0,0,0" Click="PinCodeButton_Click" FontSize="20" FontWeight="Bold"/>
<StackPanel Grid.ColumnSpan="3" Grid.Row="1" HorizontalAlignment="Center" Visibility="Collapsed" x:Name="PinCodePanel">
<TextBox x:Name="PinCodeBox" Width="300" Height="60" FontSize="20" HorizontalContentAlignment="Center" Margin="0,10,0,0"/>
<!--<TextBlock Text="Quên mã PIN?" Foreground="Blue" TextDecorations="Underline" Cursor="Hand" Margin="0,5,0,0" MouseLeftButtonUp="ForgotPin_Click"/>-->
<Button Content="Đăng nhập" Width="200" Height="40" Margin="0,10,0,0" Click="LoginButton_Click"/>
<Label x:Name="lblPincodeError" Background="Transparent" FontWeight="Bold" HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="Red" />
</StackPanel>
<StackPanel Grid.ColumnSpan="3" Grid.Row="1" HorizontalAlignment="Center" Visibility="Collapsed" x:Name="QrCodePanel">
<TextBlock HorizontalAlignment="Center" VerticalAlignment="Center" Text="Đưa QR Code của bạn vào đầu đọc" FontSize="20"/>
<hc:LoadingCircle Background="Transparent" VerticalAlignment="Bottom" Width="50" Height="50" Margin="10"/>
<Label x:Name="lblQRcodeError" Background="Transparent" FontWeight="Bold" HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="Red" />
</StackPanel>
</Grid>
<!-- Bottom Section -->
<StackPanel Grid.Row="2" HorizontalAlignment="Center" VerticalAlignment="Center">
<TextBlock x:Name="txtVersion" Text="TRỢ GIÚP" Foreground="Blue" TextDecorations="Underline" Cursor="Hand" MouseLeftButtonUp="Help_Click"/>
</StackPanel>
</Grid>
<Grid x:Name="gridInfor">
<StackPanel HorizontalAlignment="Center" VerticalAlignment="Center">
<TextBlock x:Name="txtInfor" Text="ĐANG KHỞI TẠO, VUI LÒNG ĐỢI" Foreground="Blue" FontSize="24" />
</StackPanel>
</Grid>
</Grid>
</UserControl>