309 lines
14 KiB
XML
309 lines
14 KiB
XML
<Window x:Class="Server_Dashboard.Views.DashboardPages.ModuleCRUD.CreateModulePopup"
|
|
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:Server_Dashboard.Views.DashboardPages.ModuleCRUD"
|
|
xmlns:root="clr-namespace:Server_Dashboard" xmlns:i="http://schemas.microsoft.com/xaml/behaviors"
|
|
d:DataContext="{d:DesignInstance Type=root:DashboardModuleViewModel}"
|
|
mc:Ignorable="d"
|
|
ResizeMode="NoResize"
|
|
Height="700"
|
|
Width="500"
|
|
d:WindowStyle="None"
|
|
>
|
|
<WindowChrome.WindowChrome>
|
|
<WindowChrome CaptionHeight="0" ResizeBorderThickness="0"/>
|
|
</WindowChrome.WindowChrome>
|
|
<Border
|
|
Width="500"
|
|
Height="700"
|
|
>
|
|
<Border.Background>
|
|
<SolidColorBrush Color="#2D2D2D" Opacity="1"/>
|
|
</Border.Background>
|
|
<Grid>
|
|
<Grid.RowDefinitions>
|
|
<RowDefinition Height="30"/>
|
|
<RowDefinition Height="*"/>
|
|
</Grid.RowDefinitions>
|
|
<Grid
|
|
Background="{StaticResource BackgroundSurface_04dp}"
|
|
Grid.Row="0"
|
|
>
|
|
<i:Interaction.Triggers>
|
|
<i:EventTrigger EventName="MouseDown">
|
|
<i:CallMethodAction MethodName="DragMove" TargetObject="{Binding RelativeSource={RelativeSource Mode=FindAncestor, AncestorType=Window}}"/>
|
|
</i:EventTrigger>
|
|
</i:Interaction.Triggers>
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition/>
|
|
<ColumnDefinition Width="40"/>
|
|
</Grid.ColumnDefinitions>
|
|
<TextBlock
|
|
Grid.Column="0"
|
|
Text="Create a new Server"
|
|
Margin="5 0 0 0"
|
|
Foreground="{StaticResource DeepPurple_A100}"
|
|
VerticalAlignment="Center"
|
|
/>
|
|
<Button
|
|
Style="{StaticResource CloseButton}"
|
|
Grid.Column="2"
|
|
Content="✕"
|
|
Cursor="Hand"
|
|
>
|
|
<i:Interaction.Triggers>
|
|
<i:EventTrigger EventName="Click">
|
|
<i:CallMethodAction MethodName="Close" TargetObject="{Binding RelativeSource={RelativeSource Mode=FindAncestor, AncestorType=Window}}"/>
|
|
</i:EventTrigger>
|
|
</i:Interaction.Triggers>
|
|
</Button>
|
|
</Grid>
|
|
<Grid
|
|
Background="{StaticResource BackgroundSurface_04dp}"
|
|
Grid.Row="1"
|
|
Margin="20"
|
|
>
|
|
<Grid.Effect>
|
|
<DropShadowEffect Direction="0" BlurRadius="5" ShadowDepth="0"/>
|
|
</Grid.Effect>
|
|
<Grid.RowDefinitions>
|
|
<RowDefinition/>
|
|
<RowDefinition/>
|
|
<RowDefinition/>
|
|
<RowDefinition/>
|
|
<RowDefinition/>
|
|
<RowDefinition/>
|
|
</Grid.RowDefinitions>
|
|
<StackPanel VerticalAlignment="Center" Grid.Row="0" Margin="20 0 20 0">
|
|
<StackPanel Orientation="Horizontal">
|
|
<TextBlock
|
|
Text="Server Name"
|
|
FontSize="24"
|
|
Margin="0 0 0 5"
|
|
>
|
|
<TextBlock.Foreground>
|
|
<SolidColorBrush Color="White" Opacity="0.87"/>
|
|
</TextBlock.Foreground>
|
|
</TextBlock>
|
|
<TextBlock
|
|
Text="*"
|
|
Foreground="{StaticResource ErrorRed}"
|
|
FontSize="20"
|
|
/>
|
|
</StackPanel>
|
|
<Grid>
|
|
<Grid.Effect>
|
|
<DropShadowEffect Direction="0" BlurRadius="5" ShadowDepth="0"/>
|
|
</Grid.Effect>
|
|
<TextBox
|
|
Text="{Binding ServerName}"
|
|
Grid.Column="1"
|
|
Height="40"
|
|
FontSize="20"
|
|
x:Name="ServerName"
|
|
/>
|
|
<TextBlock
|
|
VerticalAlignment="Center"
|
|
HorizontalAlignment="Left"
|
|
Text="My Awesome Server"
|
|
FontSize="20"
|
|
Visibility="{Binding ElementName=ServerName, Path=Text.IsEmpty, Converter={StaticResource UserNameVisibillity}}"
|
|
Grid.Column="1"
|
|
IsHitTestVisible="False"
|
|
Margin="5 0 0 0"
|
|
>
|
|
<TextBlock.Foreground>
|
|
<SolidColorBrush Color="White" Opacity="0.12"/>
|
|
</TextBlock.Foreground>
|
|
</TextBlock>
|
|
</Grid>
|
|
</StackPanel>
|
|
<StackPanel VerticalAlignment="Center" Grid.Row="1" Margin="20 0 20 0">
|
|
<StackPanel Orientation="Horizontal">
|
|
<TextBlock
|
|
Text="Password"
|
|
FontSize="24"
|
|
Margin="0 0 0 5"
|
|
>
|
|
<TextBlock.Foreground>
|
|
<SolidColorBrush Color="White" Opacity="0.87"/>
|
|
</TextBlock.Foreground>
|
|
</TextBlock>
|
|
<TextBlock
|
|
Text="*"
|
|
Foreground="{StaticResource ErrorRed}"
|
|
FontSize="20"
|
|
/>
|
|
</StackPanel>
|
|
<Grid>
|
|
<Grid.Effect>
|
|
<DropShadowEffect Direction="0" BlurRadius="5" ShadowDepth="0"/>
|
|
</Grid.Effect>
|
|
<PasswordBox
|
|
Width="420"
|
|
VerticalAlignment="Center"
|
|
HorizontalAlignment="Left"
|
|
root:MonitorPasswordProperty.Value="True"
|
|
Grid.Column="1"
|
|
FontSize="20"
|
|
x:Name="Password"
|
|
Height="40"
|
|
>
|
|
</PasswordBox>
|
|
<TextBlock
|
|
Visibility="{Binding ElementName=Password, Path=(root:HasTextProperty.Value), Converter={StaticResource UserNameVisibillity}}" x:Name="PasswordHint"
|
|
Text="********"
|
|
Grid.Column="1"
|
|
IsHitTestVisible="False"
|
|
VerticalAlignment="Center"
|
|
HorizontalAlignment="Left"
|
|
Margin="5 0 0 0"
|
|
FontSize="20"
|
|
>
|
|
<TextBlock.Foreground>
|
|
<SolidColorBrush Color="White" Opacity="0.12"/>
|
|
</TextBlock.Foreground>
|
|
</TextBlock>
|
|
</Grid>
|
|
</StackPanel>
|
|
<StackPanel VerticalAlignment="Center" Grid.Row="2" Margin="20 0 20 0">
|
|
<StackPanel Orientation="Horizontal">
|
|
<TextBlock
|
|
Text="Username"
|
|
FontSize="24"
|
|
Margin="0 0 0 5"
|
|
>
|
|
<TextBlock.Foreground>
|
|
<SolidColorBrush Color="White" Opacity="0.87"/>
|
|
</TextBlock.Foreground>
|
|
</TextBlock>
|
|
<TextBlock
|
|
Text="*"
|
|
Foreground="{StaticResource ErrorRed}"
|
|
FontSize="16"
|
|
/>
|
|
</StackPanel>
|
|
<Grid>
|
|
<Grid.Effect>
|
|
<DropShadowEffect Direction="0" BlurRadius="5" ShadowDepth="0"/>
|
|
</Grid.Effect>
|
|
<TextBox
|
|
Text="{Binding Username}"
|
|
Grid.Column="1"
|
|
Height="40"
|
|
FontSize="20"
|
|
x:Name="UserName"
|
|
/>
|
|
<TextBlock
|
|
VerticalAlignment="Center"
|
|
HorizontalAlignment="Left"
|
|
Text="Name"
|
|
FontSize="20"
|
|
Visibility="{Binding ElementName=UserName, Path=Text.IsEmpty, Converter={StaticResource UserNameVisibillity}}"
|
|
Grid.Column="1"
|
|
IsHitTestVisible="False"
|
|
Margin="5 0 0 0"
|
|
>
|
|
<TextBlock.Foreground>
|
|
<SolidColorBrush Color="White" Opacity="0.12"/>
|
|
</TextBlock.Foreground>
|
|
</TextBlock>
|
|
</Grid>
|
|
</StackPanel>
|
|
<StackPanel VerticalAlignment="Center" Grid.Row="3" Margin="20 0 20 0">
|
|
<StackPanel Orientation="Horizontal">
|
|
<TextBlock
|
|
Text="IP Adress"
|
|
FontSize="24"
|
|
Margin="0 0 0 5"
|
|
>
|
|
<TextBlock.Foreground>
|
|
<SolidColorBrush Color="White" Opacity="0.87"/>
|
|
</TextBlock.Foreground>
|
|
</TextBlock>
|
|
<TextBlock
|
|
Text="*"
|
|
Foreground="{StaticResource ErrorRed}"
|
|
FontSize="16"
|
|
/>
|
|
</StackPanel>
|
|
<Grid>
|
|
<Grid.Effect>
|
|
<DropShadowEffect Direction="0" BlurRadius="5" ShadowDepth="0"/>
|
|
</Grid.Effect>
|
|
<TextBox
|
|
Text="{Binding IPAdress}"
|
|
Grid.Column="1"
|
|
Height="40"
|
|
FontSize="20"
|
|
x:Name="IPAdress"
|
|
/>
|
|
<TextBlock
|
|
VerticalAlignment="Center"
|
|
HorizontalAlignment="Left"
|
|
Text="sample.ssh.com"
|
|
FontSize="20"
|
|
Visibility="{Binding ElementName=IPAdress, Path=Text.IsEmpty, Converter={StaticResource UserNameVisibillity}}"
|
|
Grid.Column="1"
|
|
IsHitTestVisible="False"
|
|
Margin="5 0 0 0"
|
|
>
|
|
<TextBlock.Foreground>
|
|
<SolidColorBrush Color="White" Opacity="0.12"/>
|
|
</TextBlock.Foreground>
|
|
</TextBlock>
|
|
</Grid>
|
|
</StackPanel>
|
|
<StackPanel VerticalAlignment="Center" Grid.Row="4" Margin="20 0 20 0">
|
|
<TextBlock
|
|
Text="Port"
|
|
FontSize="24"
|
|
Margin="0 0 0 5"
|
|
>
|
|
<TextBlock.Foreground>
|
|
<SolidColorBrush Color="White" Opacity="0.87"/>
|
|
</TextBlock.Foreground>
|
|
</TextBlock>
|
|
<Grid>
|
|
<Grid.Effect>
|
|
<DropShadowEffect Direction="0" BlurRadius="5" ShadowDepth="0"/>
|
|
</Grid.Effect>
|
|
<TextBox
|
|
Text="{Binding Port}"
|
|
Grid.Column="1"
|
|
Height="40"
|
|
FontSize="20"
|
|
x:Name="Port"
|
|
/>
|
|
<TextBlock
|
|
VerticalAlignment="Center"
|
|
HorizontalAlignment="Left"
|
|
Text="22"
|
|
FontSize="20"
|
|
Visibility="{Binding ElementName=Port, Path=Text.IsEmpty, Converter={StaticResource UserNameVisibillity}}"
|
|
Grid.Column="1"
|
|
IsHitTestVisible="False"
|
|
Margin="5 0 0 0"
|
|
>
|
|
<TextBlock.Foreground>
|
|
<SolidColorBrush Color="White" Opacity="0.12"/>
|
|
</TextBlock.Foreground>
|
|
</TextBlock>
|
|
</Grid>
|
|
</StackPanel>
|
|
<Button
|
|
Height="60"
|
|
Width="350"
|
|
Command="{Binding CreateModuleCommand}"
|
|
CommandParameter="{Binding ElementName=CREATE_MODULE}"
|
|
Grid.Row="5"
|
|
Content="CREATE MODULE"
|
|
Grid.ColumnSpan="2"
|
|
/>
|
|
</Grid>
|
|
</Grid>
|
|
</Border>
|
|
</Window>
|