2024-12-21 13:11:30 +03:00
|
|
|
<UserControl
|
|
|
|
|
d:DesignHeight="450"
|
|
|
|
|
d:DesignWidth="800"
|
|
|
|
|
mc:Ignorable="d"
|
2024-12-21 15:15:04 +03:00
|
|
|
x:Class="Nebula.Launcher.Views.Pages.AccountInfoView"
|
2025-01-14 22:10:16 +03:00
|
|
|
x:DataType="pages:AccountInfoViewModel"
|
2024-12-21 13:11:30 +03:00
|
|
|
xmlns="https://github.com/avaloniaui"
|
|
|
|
|
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
|
|
|
|
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
2025-01-23 20:43:52 +03:00
|
|
|
xmlns:pages="clr-namespace:Nebula.Launcher.ViewModels.Pages"
|
|
|
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
|
2024-12-22 21:38:19 +03:00
|
|
|
<Design.DataContext>
|
2025-01-14 22:10:16 +03:00
|
|
|
<pages:AccountInfoViewModel />
|
2024-12-22 21:38:19 +03:00
|
|
|
</Design.DataContext>
|
2024-12-27 19:15:33 +03:00
|
|
|
<Grid
|
2025-03-12 14:51:47 +03:00
|
|
|
ColumnDefinitions="3*,2*"
|
2024-12-27 19:15:33 +03:00
|
|
|
Margin="15"
|
|
|
|
|
RowDefinitions="*">
|
2024-12-21 13:11:30 +03:00
|
|
|
<StackPanel Grid.Column="1" Grid.Row="0">
|
|
|
|
|
<Border
|
2025-01-28 19:59:35 +03:00
|
|
|
BoxShadow="0 -1 15 -2 #121212"
|
2024-12-21 13:11:30 +03:00
|
|
|
CornerRadius="10,10,0,0"
|
|
|
|
|
Margin="5,5,5,0"
|
|
|
|
|
Padding="5">
|
2025-02-02 10:57:29 +03:00
|
|
|
<Border.Background>
|
|
|
|
|
<LinearGradientBrush EndPoint="50%,100%" StartPoint="50%,0%">
|
|
|
|
|
<GradientStop Color="#222222" Offset="0.0" />
|
|
|
|
|
<GradientStop Color="#292222" Offset="1.0" />
|
|
|
|
|
</LinearGradientBrush>
|
|
|
|
|
</Border.Background>
|
2024-12-21 13:11:30 +03:00
|
|
|
<Label HorizontalAlignment="Center">Profiles:</Label>
|
|
|
|
|
</Border>
|
|
|
|
|
<ScrollViewer HorizontalScrollBarVisibility="Disabled" VerticalScrollBarVisibility="Auto">
|
2025-01-07 19:14:42 +03:00
|
|
|
<ItemsControl
|
2024-12-22 21:38:19 +03:00
|
|
|
Background="#00000000"
|
|
|
|
|
ItemsSource="{Binding Accounts}"
|
2024-12-27 19:15:33 +03:00
|
|
|
Padding="0">
|
2025-01-07 19:14:42 +03:00
|
|
|
<ItemsControl.ItemTemplate>
|
2025-02-01 18:19:18 +03:00
|
|
|
<DataTemplate DataType="{x:Type pages:ProfileAuthCredentials}">
|
2024-12-27 19:15:33 +03:00
|
|
|
<Border
|
2025-01-28 19:59:35 +03:00
|
|
|
BoxShadow="0 1 15 -2 #121212"
|
2024-12-22 21:38:19 +03:00
|
|
|
CornerRadius="0,10,0,10"
|
2025-03-12 14:51:47 +03:00
|
|
|
Margin="5,5,5,0"
|
2024-12-22 21:38:19 +03:00
|
|
|
VerticalAlignment="Center">
|
2025-02-02 10:57:29 +03:00
|
|
|
<Border.Background>
|
|
|
|
|
<LinearGradientBrush EndPoint="50%,100%" StartPoint="50%,0%">
|
|
|
|
|
<GradientStop Color="#292222" Offset="0.0" />
|
|
|
|
|
<GradientStop Color="#222222" Offset="1.0" />
|
|
|
|
|
</LinearGradientBrush>
|
|
|
|
|
</Border.Background>
|
2024-12-22 21:38:19 +03:00
|
|
|
<Panel>
|
|
|
|
|
<StackPanel Margin="10,5,5,5" Orientation="Horizontal">
|
2024-12-27 19:15:33 +03:00
|
|
|
<Label>
|
|
|
|
|
<TextBlock Text="{Binding Login}" />
|
|
|
|
|
</Label>
|
2024-12-22 21:38:19 +03:00
|
|
|
</StackPanel>
|
|
|
|
|
<StackPanel HorizontalAlignment="Right" Orientation="Horizontal">
|
2024-12-27 19:15:33 +03:00
|
|
|
<Button
|
|
|
|
|
Command="{Binding OnSelect}"
|
|
|
|
|
CornerRadius="0,0,0,10"
|
|
|
|
|
Padding="5">
|
2024-12-22 21:38:19 +03:00
|
|
|
<Label>
|
|
|
|
|
Select
|
|
|
|
|
</Label>
|
|
|
|
|
</Button>
|
|
|
|
|
<Button
|
2024-12-27 19:15:33 +03:00
|
|
|
Command="{Binding OnDelete}"
|
2024-12-22 21:38:19 +03:00
|
|
|
CornerRadius="0,10,0,0"
|
2024-12-27 19:15:33 +03:00
|
|
|
Padding="5">
|
2024-12-22 21:38:19 +03:00
|
|
|
<Label>
|
|
|
|
|
Delete
|
|
|
|
|
</Label>
|
|
|
|
|
</Button>
|
|
|
|
|
</StackPanel>
|
|
|
|
|
</Panel>
|
|
|
|
|
</Border>
|
|
|
|
|
</DataTemplate>
|
2025-01-07 19:14:42 +03:00
|
|
|
</ItemsControl.ItemTemplate>
|
|
|
|
|
</ItemsControl>
|
2024-12-21 13:11:30 +03:00
|
|
|
</ScrollViewer>
|
|
|
|
|
</StackPanel>
|
2024-12-27 19:15:33 +03:00
|
|
|
|
|
|
|
|
<StackPanel
|
|
|
|
|
Grid.Column="0"
|
|
|
|
|
Grid.ColumnSpan="{Binding AuthViewSpan}"
|
|
|
|
|
Grid.Row="0">
|
|
|
|
|
<Border
|
2025-01-28 19:59:35 +03:00
|
|
|
BoxShadow="{StaticResource DefaultShadow}"
|
2024-12-27 19:15:33 +03:00
|
|
|
CornerRadius="10"
|
|
|
|
|
Margin="5"
|
|
|
|
|
Padding="15">
|
2025-02-02 10:57:29 +03:00
|
|
|
<Border.Background>
|
|
|
|
|
<LinearGradientBrush EndPoint="50%,100%" StartPoint="50%,0%">
|
|
|
|
|
<GradientStop Color="#292222" Offset="0.0" />
|
|
|
|
|
<GradientStop Color="#222222" Offset="1.0" />
|
|
|
|
|
</LinearGradientBrush>
|
|
|
|
|
</Border.Background>
|
2024-12-27 19:15:33 +03:00
|
|
|
<Panel>
|
|
|
|
|
<StackPanel IsVisible="{Binding !IsLogged}" Spacing="15">
|
2025-01-18 18:20:11 +03:00
|
|
|
<Svg
|
2024-12-27 19:15:33 +03:00
|
|
|
Height="100"
|
|
|
|
|
Margin="0,0,0,20"
|
2025-01-23 20:43:52 +03:00
|
|
|
Path="/Assets/svg/user.svg" />
|
2024-12-27 19:15:33 +03:00
|
|
|
<StackPanel HorizontalAlignment="Center">
|
|
|
|
|
<StackPanel Orientation="Horizontal">
|
|
|
|
|
<Label VerticalAlignment="Center">
|
|
|
|
|
Login:
|
|
|
|
|
</Label>
|
2025-03-12 14:51:47 +03:00
|
|
|
<TextBox Text="{Binding CurrentLogin}" MinWidth="200" />
|
2024-12-27 19:15:33 +03:00
|
|
|
</StackPanel>
|
|
|
|
|
<StackPanel Orientation="Horizontal">
|
|
|
|
|
<Label HorizontalAlignment="Left" VerticalAlignment="Center">
|
|
|
|
|
Password:
|
|
|
|
|
</Label>
|
2025-03-12 14:51:47 +03:00
|
|
|
<TextBox PasswordChar="#" MinWidth="200" Text="{Binding CurrentPassword}" />
|
2024-12-27 19:15:33 +03:00
|
|
|
</StackPanel>
|
|
|
|
|
<StackPanel Orientation="Horizontal">
|
|
|
|
|
<Label VerticalAlignment="Center">
|
|
|
|
|
Auth server:
|
|
|
|
|
</Label>
|
|
|
|
|
<Button Command="{Binding ExpandAuthUrlCommand}" VerticalAlignment="Stretch">
|
|
|
|
|
<Label>+</Label>
|
|
|
|
|
</Button>
|
|
|
|
|
</StackPanel>
|
|
|
|
|
</StackPanel>
|
|
|
|
|
|
|
|
|
|
<Border
|
2025-01-28 19:59:35 +03:00
|
|
|
BoxShadow="{StaticResource DefaultShadow}"
|
2024-12-27 19:15:33 +03:00
|
|
|
CornerRadius="10"
|
|
|
|
|
IsVisible="{Binding AuthUrlConfigExpand}">
|
|
|
|
|
<ScrollViewer Height="80">
|
|
|
|
|
<ListBox
|
|
|
|
|
Background="#00000000"
|
|
|
|
|
ItemsSource="{Binding AuthUrls}"
|
|
|
|
|
Margin="5"
|
2024-12-30 22:23:55 +03:00
|
|
|
SelectedItem="{Binding AuthItemSelect}"
|
2025-03-12 14:51:47 +03:00
|
|
|
SelectionMode="Single">
|
2024-12-27 19:15:33 +03:00
|
|
|
<ListBox.ItemTemplate>
|
|
|
|
|
<DataTemplate>
|
|
|
|
|
<Label>
|
2025-05-03 18:20:24 +03:00
|
|
|
<TextBlock Text="{Binding Name}" />
|
2024-12-27 19:15:33 +03:00
|
|
|
</Label>
|
|
|
|
|
</DataTemplate>
|
|
|
|
|
</ListBox.ItemTemplate>
|
|
|
|
|
</ListBox>
|
|
|
|
|
</ScrollViewer>
|
|
|
|
|
</Border>
|
2025-01-28 19:59:35 +03:00
|
|
|
<Border Background="{StaticResource DefaultSelected}" BoxShadow="{StaticResource DefaultShadow}">
|
2025-01-23 20:43:52 +03:00
|
|
|
<Button
|
|
|
|
|
Command="{Binding DoAuth}"
|
|
|
|
|
HorizontalAlignment="Stretch"
|
|
|
|
|
HorizontalContentAlignment="Center">
|
|
|
|
|
<Label>Auth</Label>
|
|
|
|
|
</Button>
|
|
|
|
|
</Border>
|
2025-03-12 14:51:47 +03:00
|
|
|
<Border BoxShadow="{StaticResource DefaultShadow}">
|
|
|
|
|
<Button
|
|
|
|
|
Command="{Binding SaveProfileCommand}"
|
|
|
|
|
HorizontalAlignment="Stretch"
|
|
|
|
|
HorizontalContentAlignment="Center">
|
|
|
|
|
<Label>Save profile</Label>
|
|
|
|
|
</Button>
|
|
|
|
|
</Border>
|
2024-12-27 19:15:33 +03:00
|
|
|
<Button Command="{Binding ExpandAuthViewCommand}" HorizontalAlignment="Right">
|
|
|
|
|
<Label>
|
|
|
|
|
>
|
|
|
|
|
</Label>
|
|
|
|
|
</Button>
|
|
|
|
|
</StackPanel>
|
|
|
|
|
|
|
|
|
|
<StackPanel IsVisible="{Binding IsLogged}">
|
2025-01-18 18:20:11 +03:00
|
|
|
<Svg
|
2024-12-27 19:15:33 +03:00
|
|
|
Height="100"
|
|
|
|
|
Margin="0,0,0,20"
|
2025-01-23 20:43:52 +03:00
|
|
|
Path="/Assets/svg/user.svg" />
|
2024-12-27 19:15:33 +03:00
|
|
|
<Label>
|
|
|
|
|
<StackPanel HorizontalAlignment="Center" Orientation="Horizontal">
|
2025-01-18 18:20:11 +03:00
|
|
|
<TextBlock>Hello,</TextBlock>
|
2024-12-27 19:15:33 +03:00
|
|
|
<TextBlock Text="{Binding CurrentLogin}" />
|
|
|
|
|
</StackPanel>
|
|
|
|
|
</Label>
|
|
|
|
|
<StackPanel
|
|
|
|
|
HorizontalAlignment="Center"
|
2025-01-18 18:20:11 +03:00
|
|
|
Margin="5,20,5,5"
|
2024-12-27 19:15:33 +03:00
|
|
|
Orientation="Horizontal"
|
|
|
|
|
Spacing="5">
|
2025-01-28 19:59:35 +03:00
|
|
|
<Border BoxShadow="{StaticResource DefaultShadow}">
|
2025-01-23 20:43:52 +03:00
|
|
|
<Button Command="{Binding Logout}">
|
|
|
|
|
<Label>Logout</Label>
|
|
|
|
|
</Button>
|
|
|
|
|
</Border>
|
2025-01-28 19:59:35 +03:00
|
|
|
<Border BoxShadow="{StaticResource DefaultShadow}">
|
2025-01-23 20:43:52 +03:00
|
|
|
<Button Command="{Binding SaveProfileCommand}">
|
|
|
|
|
<Label>Save profile</Label>
|
|
|
|
|
</Button>
|
|
|
|
|
</Border>
|
2024-12-27 19:15:33 +03:00
|
|
|
</StackPanel>
|
|
|
|
|
</StackPanel>
|
|
|
|
|
</Panel>
|
|
|
|
|
</Border>
|
|
|
|
|
</StackPanel>
|
2024-12-21 13:11:30 +03:00
|
|
|
</Grid>
|
2025-01-14 22:10:16 +03:00
|
|
|
</UserControl>
|