Added CMS_ALIAS and redesign
Some checks failed
Build and Publish Docker Image / build-and-push (push) Has been cancelled
Some checks failed
Build and Publish Docker Image / build-and-push (push) Has been cancelled
This commit is contained in:
@@ -5,29 +5,37 @@
|
||||
x:DataType="vm:HostsViewModel">
|
||||
|
||||
<DockPanel>
|
||||
<!-- Toolbar -->
|
||||
<StackPanel DockPanel.Dock="Top" Orientation="Horizontal" Spacing="8" Margin="0,0,0,12">
|
||||
<Button Content="Add Host" Command="{Binding NewHostCommand}" />
|
||||
<Button Content="Edit" Command="{Binding EditSelectedHostCommand}" />
|
||||
<Button Content="Test Connection" Command="{Binding TestConnectionCommand}" />
|
||||
<Button Content="Delete" Command="{Binding DeleteHostCommand}" />
|
||||
<Button Content="Refresh" Command="{Binding LoadHostsCommand}" />
|
||||
<!-- Page header -->
|
||||
<StackPanel DockPanel.Dock="Top" Margin="0,0,0,4">
|
||||
<TextBlock Text="SSH Hosts" Classes="pageTitle" />
|
||||
<TextBlock Text="Manage remote Docker Swarm manager connections" Classes="pageSubtitle" />
|
||||
</StackPanel>
|
||||
|
||||
<!-- Toolbar -->
|
||||
<Border DockPanel.Dock="Top" Classes="toolbar" Margin="0,0,0,16">
|
||||
<StackPanel Orientation="Horizontal" Spacing="8">
|
||||
<Button Content="Add Host" Classes="accent" Command="{Binding NewHostCommand}" />
|
||||
<Button Content="Edit" Command="{Binding EditSelectedHostCommand}" />
|
||||
<Button Content="Test Connection" Command="{Binding TestConnectionCommand}" />
|
||||
<Button Content="Delete" Classes="danger" Command="{Binding DeleteHostCommand}" />
|
||||
<Border Width="1" Background="{StaticResource BorderSubtleBrush}" Margin="4,2" />
|
||||
<Button Content="Refresh" Command="{Binding LoadHostsCommand}" />
|
||||
</StackPanel>
|
||||
</Border>
|
||||
|
||||
<!-- Status -->
|
||||
<TextBlock DockPanel.Dock="Bottom" Text="{Binding StatusMessage}" Margin="0,8,0,0"
|
||||
FontSize="12" Foreground="#a6adc8" />
|
||||
<TextBlock DockPanel.Dock="Bottom" Text="{Binding StatusMessage}" Classes="status"
|
||||
Margin="0,10,0,0" />
|
||||
|
||||
<!-- Remote Nodes panel -->
|
||||
<Border DockPanel.Dock="Bottom" Margin="0,12,0,0" Padding="8"
|
||||
Background="#1e1e2e" CornerRadius="8"
|
||||
<Border DockPanel.Dock="Bottom" Classes="card" Margin="0,16,0,0"
|
||||
MinHeight="120" MaxHeight="300">
|
||||
<DockPanel>
|
||||
<StackPanel DockPanel.Dock="Top" Orientation="Horizontal" Spacing="8" Margin="0,0,0,8">
|
||||
<TextBlock Text="Cluster Nodes" FontSize="14" FontWeight="SemiBold" VerticalAlignment="Center" />
|
||||
<StackPanel DockPanel.Dock="Top" Orientation="Horizontal" Spacing="10" Margin="0,0,0,10">
|
||||
<TextBlock Text="Cluster Nodes" Classes="sectionTitle" VerticalAlignment="Center" />
|
||||
<Button Content="List Nodes" Command="{Binding ListNodesCommand}" />
|
||||
<TextBlock Text="{Binding NodesStatusMessage}" FontSize="12"
|
||||
Foreground="#a6adc8" VerticalAlignment="Center" Margin="8,0,0,0" />
|
||||
<TextBlock Text="{Binding NodesStatusMessage}" Classes="status"
|
||||
VerticalAlignment="Center" Margin="4,0,0,0" />
|
||||
</StackPanel>
|
||||
|
||||
<DataGrid ItemsSource="{Binding RemoteNodes}"
|
||||
@@ -50,43 +58,48 @@
|
||||
</Border>
|
||||
|
||||
<!-- Edit panel (shown when editing) -->
|
||||
<Border DockPanel.Dock="Right" Width="350" IsVisible="{Binding IsEditing}"
|
||||
Background="#1e1e2e" CornerRadius="8" Padding="16" Margin="12,0,0,0">
|
||||
<Border DockPanel.Dock="Right" Width="360" IsVisible="{Binding IsEditing}"
|
||||
Classes="card" Margin="16,0,0,0">
|
||||
<ScrollViewer>
|
||||
<StackPanel Spacing="8">
|
||||
<TextBlock Text="SSH Host" FontSize="16" FontWeight="SemiBold" Margin="0,0,0,8" />
|
||||
<StackPanel Spacing="10">
|
||||
<TextBlock Text="SSH Host" FontSize="17" FontWeight="SemiBold"
|
||||
Foreground="{StaticResource AccentBrush}" Margin="0,0,0,6" />
|
||||
|
||||
<TextBlock Text="Label" FontSize="12" />
|
||||
<TextBlock Text="Label" FontSize="12" Foreground="{StaticResource TextSecondaryBrush}" />
|
||||
<TextBox Text="{Binding EditLabel}" Watermark="e.g. Production Swarm" />
|
||||
|
||||
<TextBlock Text="Host" FontSize="12" />
|
||||
<TextBlock Text="Host" FontSize="12" Foreground="{StaticResource TextSecondaryBrush}" />
|
||||
<TextBox Text="{Binding EditHost}" Watermark="hostname or IP" />
|
||||
|
||||
<TextBlock Text="Port" FontSize="12" />
|
||||
<NumericUpDown Value="{Binding EditPort}" Minimum="1" Maximum="65535" />
|
||||
<TextBlock Text="Port" FontSize="12" Foreground="{StaticResource TextSecondaryBrush}" />
|
||||
<NumericUpDown Value="{Binding EditPort}" Minimum="1" Maximum="65535" CornerRadius="6" />
|
||||
|
||||
<TextBlock Text="Username" FontSize="12" />
|
||||
<TextBlock Text="Username" FontSize="12" Foreground="{StaticResource TextSecondaryBrush}" />
|
||||
<TextBox Text="{Binding EditUsername}" Watermark="ssh username" />
|
||||
|
||||
<CheckBox Content="Use Key Authentication" IsChecked="{Binding EditUseKeyAuth}" />
|
||||
<CheckBox Content="Use Key Authentication" IsChecked="{Binding EditUseKeyAuth}"
|
||||
Margin="0,4,0,0" />
|
||||
|
||||
<TextBlock Text="Private Key Path" FontSize="12"
|
||||
Foreground="{StaticResource TextSecondaryBrush}"
|
||||
IsVisible="{Binding EditUseKeyAuth}" />
|
||||
<TextBox Text="{Binding EditPrivateKeyPath}" Watermark="~/.ssh/id_rsa"
|
||||
IsVisible="{Binding EditUseKeyAuth}" />
|
||||
|
||||
<TextBlock Text="Key Passphrase (optional)" FontSize="12"
|
||||
Foreground="{StaticResource TextSecondaryBrush}"
|
||||
IsVisible="{Binding EditUseKeyAuth}" />
|
||||
<TextBox Text="{Binding EditKeyPassphrase}" PasswordChar="●"
|
||||
IsVisible="{Binding EditUseKeyAuth}" />
|
||||
|
||||
<TextBlock Text="Password (if not using key)" FontSize="12"
|
||||
Foreground="{StaticResource TextSecondaryBrush}"
|
||||
IsVisible="{Binding !EditUseKeyAuth}" />
|
||||
<TextBox Text="{Binding EditPassword}" PasswordChar="●"
|
||||
IsVisible="{Binding !EditUseKeyAuth}" />
|
||||
|
||||
<StackPanel Orientation="Horizontal" Spacing="8" Margin="0,12,0,0">
|
||||
<Button Content="Save" Command="{Binding SaveHostCommand}" />
|
||||
<StackPanel Orientation="Horizontal" Spacing="8" Margin="0,14,0,0">
|
||||
<Button Content="Save" Classes="accent" Command="{Binding SaveHostCommand}" />
|
||||
<Button Content="Cancel" Command="{Binding CancelEditCommand}" />
|
||||
</StackPanel>
|
||||
</StackPanel>
|
||||
|
||||
Reference in New Issue
Block a user