ux: command palette layout

Signed-off-by: leo <longshuang@msn.cn>
This commit is contained in:
leo
2026-03-10 11:24:44 +08:00
parent a94975bb02
commit 4ed0800072
10 changed files with 82 additions and 28 deletions

View File

@@ -134,6 +134,10 @@
<x:String x:Key="Text.Clone.RemoteURL" xml:space="preserve">Repository URL:</x:String>
<x:String x:Key="Text.Close" xml:space="preserve">CLOSE</x:String>
<x:String x:Key="Text.CodeEditor" xml:space="preserve">Editor</x:String>
<x:String x:Key="Text.CommandPalette.Branches" xml:space="preserve">Branches</x:String>
<x:String x:Key="Text.CommandPalette.BranchesAndTags" xml:space="preserve">Branches &amp; Tags</x:String>
<x:String x:Key="Text.CommandPalette.RepositoryActions" xml:space="preserve">Repository Custom Actions</x:String>
<x:String x:Key="Text.CommandPalette.RevisionFiles" xml:space="preserve">Revision Files</x:String>
<x:String x:Key="Text.CommitCM.Checkout" xml:space="preserve">Checkout Commit</x:String>
<x:String x:Key="Text.CommitCM.CherryPick" xml:space="preserve">Cherry-Pick Commit</x:String>
<x:String x:Key="Text.CommitCM.CherryPickMultiple" xml:space="preserve">Cherry-Pick ...</x:String>

View File

@@ -138,6 +138,10 @@
<x:String x:Key="Text.Clone.RemoteURL" xml:space="preserve">远程仓库 </x:String>
<x:String x:Key="Text.Close" xml:space="preserve">关闭</x:String>
<x:String x:Key="Text.CodeEditor" xml:space="preserve">提交信息编辑器</x:String>
<x:String x:Key="Text.CommandPalette.Branches" xml:space="preserve">分支列表</x:String>
<x:String x:Key="Text.CommandPalette.BranchesAndTags" xml:space="preserve">分支 &amp; 标签</x:String>
<x:String x:Key="Text.CommandPalette.RepositoryActions" xml:space="preserve">自定义操作列表</x:String>
<x:String x:Key="Text.CommandPalette.RevisionFiles" xml:space="preserve">文件列表</x:String>
<x:String x:Key="Text.CommitCM.Checkout" xml:space="preserve">检出此提交</x:String>
<x:String x:Key="Text.CommitCM.CherryPick" xml:space="preserve">挑选(cherry-pick)此提交</x:String>
<x:String x:Key="Text.CommitCM.CherryPickMultiple" xml:space="preserve">挑选(cherry-pick)...</x:String>

View File

@@ -138,6 +138,10 @@
<x:String x:Key="Text.Clone.RemoteURL" xml:space="preserve">遠端存放庫:</x:String>
<x:String x:Key="Text.Close" xml:space="preserve">關閉</x:String>
<x:String x:Key="Text.CodeEditor" xml:space="preserve">提交訊息編輯器</x:String>
<x:String x:Key="Text.CommandPalette.Branches" xml:space="preserve">分支列表</x:String>
<x:String x:Key="Text.CommandPalette.BranchesAndTags" xml:space="preserve">分支 &amp; 標籤</x:String>
<x:String x:Key="Text.CommandPalette.RepositoryActions" xml:space="preserve">自訂動作</x:String>
<x:String x:Key="Text.CommandPalette.RevisionFiles" xml:space="preserve">檔案列表</x:String>
<x:String x:Key="Text.CommitCM.Checkout" xml:space="preserve">簽出 (checkout) 此提交</x:String>
<x:String x:Key="Text.CommitCM.CherryPick" xml:space="preserve">揀選 (cherry-pick) 此提交</x:String>
<x:String x:Key="Text.CommitCM.CherryPickMultiple" xml:space="preserve">揀選 (cherry-pick)...</x:String>

View File

@@ -8,7 +8,7 @@
mc:Ignorable="d" d:DesignWidth="800" d:DesignHeight="450"
x:Class="SourceGit.Views.BlameCommandPalette"
x:DataType="vm:BlameCommandPalette">
<Grid RowDefinitions="Auto,Auto">
<Grid RowDefinitions="Auto,Auto,Auto">
<v:RepositoryCommandPaletteTextBox Grid.Row="0"
x:Name="FilterTextBox"
Height="24"
@@ -50,11 +50,17 @@
</Button>
</TextBox.InnerRightContent>
</v:RepositoryCommandPaletteTextBox>
<TextBlock Grid.Row="1"
Margin="6,12,0,0"
Text="{DynamicResource Text.CommandPalette.RevisionFiles}"
FontWeight="Bold"
Foreground="{DynamicResource Brush.FG2}"/>
<ListBox Grid.Row="1"
<ListBox Grid.Row="2"
x:Name="FileListBox"
MaxHeight="250"
Margin="4,8,4,0"
MaxHeight="360"
Margin="4,8"
BorderThickness="0"
SelectionMode="Single"
Background="Transparent"

View File

@@ -9,7 +9,7 @@
mc:Ignorable="d" d:DesignWidth="800" d:DesignHeight="450"
x:Class="SourceGit.Views.CheckoutCommandPalette"
x:DataType="vm:CheckoutCommandPalette">
<Grid RowDefinitions="Auto,Auto">
<Grid RowDefinitions="Auto,Auto,Auto">
<v:RepositoryCommandPaletteTextBox Grid.Row="0"
x:Name="FilterTextBox"
Height="24"
@@ -52,10 +52,16 @@
</TextBox.InnerRightContent>
</v:RepositoryCommandPaletteTextBox>
<ListBox Grid.Row="1"
<TextBlock Grid.Row="1"
Margin="6,12,0,0"
Text="{DynamicResource Text.CommandPalette.Branches}"
FontWeight="Bold"
Foreground="{DynamicResource Brush.FG2}"/>
<ListBox Grid.Row="2"
x:Name="BranchListBox"
MaxHeight="250"
Margin="4,8,4,0"
MaxHeight="360"
Margin="4,8"
BorderThickness="0"
SelectionMode="Single"
Background="Transparent"

View File

@@ -9,7 +9,7 @@
mc:Ignorable="d" d:DesignWidth="800" d:DesignHeight="450"
x:Class="SourceGit.Views.CompareCommandPalette"
x:DataType="vm:CompareCommandPalette">
<Grid RowDefinitions="Auto,Auto">
<Grid RowDefinitions="Auto,Auto,Auto">
<v:RepositoryCommandPaletteTextBox Grid.Row="0"
x:Name="FilterTextBox"
Height="24"
@@ -64,10 +64,16 @@
</TextBox.InnerRightContent>
</v:RepositoryCommandPaletteTextBox>
<ListBox Grid.Row="1"
<TextBlock Grid.Row="1"
Margin="6,12,0,0"
Text="{DynamicResource Text.CommandPalette.BranchesAndTags}"
FontWeight="Bold"
Foreground="{DynamicResource Brush.FG2}"/>
<ListBox Grid.Row="2"
x:Name="RefsListBox"
MaxHeight="250"
Margin="4,8,4,0"
MaxHeight="360"
Margin="4,8"
BorderThickness="0"
SelectionMode="Single"
Background="Transparent"

View File

@@ -8,7 +8,7 @@
mc:Ignorable="d" d:DesignWidth="800" d:DesignHeight="450"
x:Class="SourceGit.Views.ExecuteCustomActionCommandPalette"
x:DataType="vm:ExecuteCustomActionCommandPalette">
<Grid RowDefinitions="Auto,Auto">
<Grid RowDefinitions="Auto,Auto,Auto">
<v:RepositoryCommandPaletteTextBox Grid.Row="0"
x:Name="FilterTextBox"
Height="24"
@@ -51,10 +51,16 @@
</TextBox.InnerRightContent>
</v:RepositoryCommandPaletteTextBox>
<ListBox Grid.Row="1"
<TextBlock Grid.Row="1"
Margin="6,12,0,0"
Text="{DynamicResource Text.CommandPalette.RepositoryActions}"
FontWeight="Bold"
Foreground="{DynamicResource Brush.FG2}"/>
<ListBox Grid.Row="2"
x:Name="ActionListBox"
MaxHeight="250"
Margin="4,8,4,0"
MaxHeight="360"
Margin="4,8"
BorderThickness="0"
SelectionMode="Single"
Background="Transparent"

View File

@@ -8,7 +8,7 @@
mc:Ignorable="d" d:DesignWidth="800" d:DesignHeight="450"
x:Class="SourceGit.Views.FileHistoryCommandPalette"
x:DataType="vm:FileHistoryCommandPalette">
<Grid RowDefinitions="Auto,Auto">
<Grid RowDefinitions="Auto,Auto,Auto">
<v:RepositoryCommandPaletteTextBox Grid.Row="0"
x:Name="FilterTextBox"
Height="24"
@@ -51,10 +51,16 @@
</TextBox.InnerRightContent>
</v:RepositoryCommandPaletteTextBox>
<ListBox Grid.Row="1"
<TextBlock Grid.Row="1"
Margin="6,12,0,0"
Text="{DynamicResource Text.CommandPalette.RevisionFiles}"
FontWeight="Bold"
Foreground="{DynamicResource Brush.FG2}"/>
<ListBox Grid.Row="2"
x:Name="FileListBox"
MaxHeight="250"
Margin="4,8,4,0"
MaxHeight="360"
Margin="4,8"
BorderThickness="0"
SelectionMode="Single"
Background="Transparent"

View File

@@ -9,7 +9,7 @@
mc:Ignorable="d" d:DesignWidth="800" d:DesignHeight="450"
x:Class="SourceGit.Views.MergeCommandPalette"
x:DataType="vm:MergeCommandPalette">
<Grid RowDefinitions="Auto,Auto">
<Grid RowDefinitions="Auto,Auto,Auto">
<v:RepositoryCommandPaletteTextBox Grid.Row="0"
x:Name="FilterTextBox"
Height="24"
@@ -52,10 +52,16 @@
</TextBox.InnerRightContent>
</v:RepositoryCommandPaletteTextBox>
<ListBox Grid.Row="1"
<TextBlock Grid.Row="1"
Margin="6,12,0,0"
Text="{DynamicResource Text.CommandPalette.Branches}"
FontWeight="Bold"
Foreground="{DynamicResource Brush.FG2}"/>
<ListBox Grid.Row="2"
x:Name="BranchListBox"
MaxHeight="250"
Margin="4,8,4,0"
MaxHeight="360"
Margin="4,8"
BorderThickness="0"
SelectionMode="Single"
Background="Transparent"

View File

@@ -8,7 +8,7 @@
mc:Ignorable="d" d:DesignWidth="800" d:DesignHeight="450"
x:Class="SourceGit.Views.OpenFileCommandPalette"
x:DataType="vm:OpenFileCommandPalette">
<Grid RowDefinitions="Auto,Auto">
<Grid RowDefinitions="Auto,Auto,Auto">
<v:RepositoryCommandPaletteTextBox Grid.Row="0"
x:Name="FilterTextBox"
Height="24"
@@ -51,10 +51,16 @@
</TextBox.InnerRightContent>
</v:RepositoryCommandPaletteTextBox>
<ListBox Grid.Row="1"
<TextBlock Grid.Row="1"
Margin="6,12,0,0"
Text="{DynamicResource Text.CommandPalette.RevisionFiles}"
FontWeight="Bold"
Foreground="{DynamicResource Brush.FG2}"/>
<ListBox Grid.Row="2"
x:Name="FileListBox"
MaxHeight="250"
Margin="4,8,4,0"
MaxHeight="360"
Margin="4,8"
BorderThickness="0"
SelectionMode="Single"
Background="Transparent"