feat(ui): fuse git tab into one approve+merge cockpit
This commit is contained in:
@@ -251,26 +251,18 @@
|
|||||||
|
|
||||||
</DockPanel>
|
</DockPanel>
|
||||||
|
|
||||||
<!-- Git: merge target, approve, diff, worktree -->
|
<!-- Git: one Approve + merge cockpit -->
|
||||||
<ScrollViewer IsVisible="{Binding IsGitTab}" Padding="14,10">
|
<ScrollViewer IsVisible="{Binding IsGitTab}" Padding="14,10">
|
||||||
<StackPanel Spacing="14">
|
<StackPanel Spacing="12" IsVisible="{Binding ShowMergeSection}">
|
||||||
|
<TextBlock Classes="section-label" Text="MERGE" />
|
||||||
|
|
||||||
<!-- Approve (review-gated) -->
|
|
||||||
<StackPanel Spacing="8" IsVisible="{Binding IsWaitingForReview}">
|
|
||||||
<TextBlock Classes="section-label" Text="REVIEW" />
|
|
||||||
<Button Classes="btn accent" Content="Approve"
|
|
||||||
Command="{Binding ApproveReviewCommand}" />
|
|
||||||
</StackPanel>
|
|
||||||
|
|
||||||
<!-- Merge & worktree management (moved from Session tab) -->
|
|
||||||
<StackPanel Spacing="10" IsVisible="{Binding ShowMergeSection}">
|
|
||||||
<TextBlock Classes="section-label" Text="MERGE & WORKTREE" />
|
|
||||||
<StackPanel Spacing="4">
|
<StackPanel Spacing="4">
|
||||||
<TextBlock Classes="field-label" Text="Merge target" />
|
<TextBlock Classes="field-label" Text="Target branch" />
|
||||||
<ComboBox ItemsSource="{Binding MergeTargetBranches}"
|
<ComboBox ItemsSource="{Binding MergeTargetBranches}"
|
||||||
SelectedItem="{Binding SelectedMergeTarget, Mode=TwoWay}"
|
SelectedItem="{Binding SelectedMergeTarget, Mode=TwoWay}"
|
||||||
HorizontalAlignment="Stretch" />
|
HorizontalAlignment="Stretch" />
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
|
|
||||||
<StackPanel Spacing="0">
|
<StackPanel Spacing="0">
|
||||||
<TextBlock Classes="meta" Text="{Binding MergePreviewText}" TextWrapping="Wrap"
|
<TextBlock Classes="meta" Text="{Binding MergePreviewText}" TextWrapping="Wrap"
|
||||||
Foreground="{DynamicResource MossBrush}"
|
Foreground="{DynamicResource MossBrush}"
|
||||||
@@ -282,12 +274,19 @@
|
|||||||
Foreground="{DynamicResource TextMuteBrush}"
|
Foreground="{DynamicResource TextMuteBrush}"
|
||||||
IsVisible="{Binding ShowMergePreviewMuted}" />
|
IsVisible="{Binding ShowMergePreviewMuted}" />
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
|
|
||||||
|
<!-- Primary action: Approve flows straight into the merge.
|
||||||
|
Approve is the review-gated path; the plain Merge button covers
|
||||||
|
already-reviewed / kept worktrees. -->
|
||||||
<WrapPanel Orientation="Horizontal">
|
<WrapPanel Orientation="Horizontal">
|
||||||
<Button Classes="btn" Content="Open Diff" Margin="0,0,8,8"
|
<Button Classes="btn accent" Content="Approve & Merge" Margin="0,0,8,8"
|
||||||
Command="{Binding OpenDiffCommand}" />
|
Command="{Binding ApproveReviewCommand}"
|
||||||
|
IsVisible="{Binding IsWaitingForReview}" />
|
||||||
<Button Classes="btn accent" Content="Merge" Margin="0,0,8,8"
|
<Button Classes="btn accent" Content="Merge" Margin="0,0,8,8"
|
||||||
Command="{Binding MergeCommand}"
|
Command="{Binding MergeCommand}"
|
||||||
IsVisible="{Binding ShowSingleMerge}" />
|
IsVisible="{Binding ShowSingleMerge}" />
|
||||||
|
<Button Classes="btn" Content="Open Diff" Margin="0,0,8,8"
|
||||||
|
Command="{Binding OpenDiffCommand}" />
|
||||||
<Button Classes="btn" Margin="0,0,8,8"
|
<Button Classes="btn" Margin="0,0,8,8"
|
||||||
Command="{Binding OpenWorktreeCommand}">
|
Command="{Binding OpenWorktreeCommand}">
|
||||||
<StackPanel Orientation="Horizontal" Spacing="5">
|
<StackPanel Orientation="Horizontal" Spacing="5">
|
||||||
@@ -302,14 +301,13 @@
|
|||||||
IsEnabled="{Binding CanMergeAll}"
|
IsEnabled="{Binding CanMergeAll}"
|
||||||
ToolTip.Tip="{Binding MergeAllDisabledReason}" />
|
ToolTip.Tip="{Binding MergeAllDisabledReason}" />
|
||||||
</WrapPanel>
|
</WrapPanel>
|
||||||
|
|
||||||
<TextBlock Text="{Binding MergeAllError}"
|
<TextBlock Text="{Binding MergeAllError}"
|
||||||
Foreground="{DynamicResource BloodBrush}"
|
Foreground="{DynamicResource BloodBrush}"
|
||||||
TextWrapping="Wrap"
|
TextWrapping="Wrap"
|
||||||
IsVisible="{Binding MergeAllError,
|
IsVisible="{Binding MergeAllError,
|
||||||
Converter={x:Static ObjectConverters.IsNotNull}}" />
|
Converter={x:Static ObjectConverters.IsNotNull}}" />
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
|
|
||||||
</StackPanel>
|
|
||||||
</ScrollViewer>
|
</ScrollViewer>
|
||||||
|
|
||||||
<!-- Session: subtask outcomes (review lives in Output, merge in Git) -->
|
<!-- Session: subtask outcomes (review lives in Output, merge in Git) -->
|
||||||
|
|||||||
Reference in New Issue
Block a user