| | 6 | 1 | | <UserControl xmlns="https://github.com/avaloniaui" |
| | | 2 | | xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" |
| | | 3 | | xmlns:vm="using:LOCKnet.App.ViewModels" |
| | | 4 | | xmlns:d="http://schemas.microsoft.com/expression/blend/2008" |
| | | 5 | | xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" |
| | | 6 | | mc:Ignorable="d" d:DesignWidth="900" d:DesignHeight="600" |
| | | 7 | | x:Class="LOCKnet.App.Views.LoginView" |
| | | 8 | | x:DataType="vm:LoginViewModel" |
| | 3 | 9 | | Background="{StaticResource BrushBg}"> |
| | | 10 | | |
| | | 11 | | <Design.DataContext> |
| | | 12 | | <vm:LoginViewModel/> |
| | | 13 | | </Design.DataContext> |
| | | 14 | | |
| | 9 | 15 | | <Grid RowDefinitions="*,Auto,*"> |
| | | 16 | | <!-- Footer credit --> |
| | 15 | 17 | | <StackPanel Grid.Row="2" |
| | | 18 | | HorizontalAlignment="Center" |
| | 3 | 19 | | VerticalAlignment="Bottom" |
| | | 20 | | Margin="0,0,0,20" |
| | 3 | 21 | | Spacing="2"> |
| | 12 | 22 | | <TextBlock Text="Alhasan Ramadan" |
| | | 23 | | FontSize="11" |
| | 3 | 24 | | Foreground="{StaticResource BrushTextMuted}" |
| | | 25 | | HorizontalAlignment="Center"/> |
| | 12 | 26 | | <TextBlock Text="https://github.com/alhasan-ramadan/LOCKnet" |
| | | 27 | | FontSize="11" |
| | 3 | 28 | | Foreground="{StaticResource BrushAccent}" |
| | | 29 | | HorizontalAlignment="Center"/> |
| | | 30 | | </StackPanel> |
| | 12 | 31 | | <StackPanel Grid.Row="1" |
| | | 32 | | Width="400" |
| | 3 | 33 | | HorizontalAlignment="Center" |
| | | 34 | | Spacing="0"> |
| | | 35 | | |
| | | 36 | | <!-- Logo / Title --> |
| | 12 | 37 | | <StackPanel Orientation="Horizontal" |
| | | 38 | | HorizontalAlignment="Center" |
| | 3 | 39 | | Spacing="10" |
| | | 40 | | Margin="0,0,0,8"> |
| | 12 | 41 | | <Image Source="/Assets/favicon-32x32.png" |
| | 3 | 42 | | Width="40" Height="40" |
| | | 43 | | VerticalAlignment="Center"/> |
| | 12 | 44 | | <TextBlock Text="LOCKnet" |
| | | 45 | | FontSize="34" |
| | 3 | 46 | | FontWeight="Bold" |
| | 3 | 47 | | Foreground="{StaticResource BrushTextPrimary}" |
| | | 48 | | VerticalAlignment="Center"/> |
| | | 49 | | </StackPanel> |
| | 12 | 50 | | <TextBlock Text="Local Offline Credential Keeper" |
| | | 51 | | FontSize="13" |
| | 3 | 52 | | Foreground="{StaticResource BrushTextSecondary}" |
| | | 53 | | HorizontalAlignment="Center" |
| | 3 | 54 | | Margin="0,0,0,44"/> |
| | | 55 | | |
| | 12 | 56 | | <Separator Background="{StaticResource BrushBorder}" Height="1" Margin="0,0,0,32"/> |
| | | 57 | | |
| | | 58 | | <!-- Card --> |
| | 9 | 59 | | <Border Background="{StaticResource BrushSurface}" |
| | 3 | 60 | | CornerRadius="{StaticResource RadiusLg}" |
| | | 61 | | Padding="40,36"> |
| | 9 | 62 | | <StackPanel Spacing="20"> |
| | | 63 | | |
| | | 64 | | <!-- Mode heading --> |
| | 9 | 65 | | <TextBlock Text="Ersteinrichtung" |
| | | 66 | | FontSize="18" |
| | 3 | 67 | | FontWeight="SemiBold" |
| | 3 | 68 | | Foreground="{StaticResource BrushTextPrimary}" |
| | 3 | 69 | | IsVisible="{Binding IsSetupMode}"/> |
| | 9 | 70 | | <TextBlock Text="Willkommen zurück" |
| | | 71 | | FontSize="18" |
| | 3 | 72 | | FontWeight="SemiBold" |
| | 3 | 73 | | Foreground="{StaticResource BrushTextPrimary}" |
| | 3 | 74 | | IsVisible="{Binding !IsSetupMode}"/> |
| | | 75 | | |
| | | 76 | | <!-- Password --> |
| | 9 | 77 | | <StackPanel Spacing="6"> |
| | 9 | 78 | | <TextBlock Text="Master-Passwort" |
| | | 79 | | FontSize="12" |
| | 3 | 80 | | Foreground="{StaticResource BrushTextSecondary}"/> |
| | 9 | 81 | | <TextBox x:Name="PasswordInput" |
| | | 82 | | PasswordChar="●" |
| | 3 | 83 | | Watermark="Passwort eingeben…"/> |
| | | 84 | | </StackPanel> |
| | | 85 | | |
| | | 86 | | <!-- Confirm Password (only setup mode) --> |
| | 12 | 87 | | <StackPanel Spacing="6" IsVisible="{Binding IsSetupMode}"> |
| | 9 | 88 | | <TextBlock Text="Passwort bestätigen" |
| | | 89 | | FontSize="12" |
| | 3 | 90 | | Foreground="{StaticResource BrushTextSecondary}"/> |
| | 9 | 91 | | <TextBox x:Name="ConfirmPasswordInput" |
| | | 92 | | PasswordChar="●" |
| | 3 | 93 | | Watermark="Passwort wiederholen…"/> |
| | | 94 | | </StackPanel> |
| | | 95 | | |
| | | 96 | | <!-- Error --> |
| | 9 | 97 | | <TextBlock Text="{Binding ErrorMessage}" |
| | 3 | 98 | | Foreground="{StaticResource BrushError}" |
| | | 99 | | FontSize="12" |
| | 3 | 100 | | TextWrapping="Wrap" |
| | 3 | 101 | | IsVisible="{Binding ErrorMessage, Converter={x:Static StringConverters.IsNotNullOrEmpty}} |
| | | 102 | | |
| | | 103 | | <!-- Buttons --> |
| | 12 | 104 | | <Button Content="Entsperren" |
| | | 105 | | Classes="primary" |
| | 3 | 106 | | Click="OnUnlockClick" |
| | 3 | 107 | | IsVisible="{Binding !IsSetupMode}" |
| | | 108 | | HorizontalAlignment="Stretch" |
| | 3 | 109 | | HorizontalContentAlignment="Center"/> |
| | | 110 | | |
| | 12 | 111 | | <Button Content="Einrichten & Entsperren" |
| | | 112 | | Classes="primary" |
| | 3 | 113 | | Click="OnSetupClick" |
| | 3 | 114 | | IsVisible="{Binding IsSetupMode}" |
| | | 115 | | HorizontalAlignment="Stretch" |
| | 3 | 116 | | HorizontalContentAlignment="Center"/> |
| | | 117 | | |
| | | 118 | | </StackPanel> |
| | | 119 | | </Border> |
| | | 120 | | |
| | | 121 | | </StackPanel> |
| | | 122 | | </Grid> |
| | | 123 | | |
| | | 124 | | </UserControl> |