fix(ui): surface precondition hints for silently-disabled review buttons (UX-Audit #2)
Cancel now shows an amber hint + tooltip while a merge drain is in progress (ShowMergeDrainHint mirrors IsMergeDraining). Continue, Reset & Retry, Open Diff, Worktree, and Review Combined Diff gain ToolTip.Tip + ToolTip.ShowOnDisabled explaining why they're locked. No CanExecute or behavior changed, only added communication.
This commit is contained in:
@@ -174,10 +174,14 @@
|
||||
<StackPanel Orientation="Horizontal" Spacing="8">
|
||||
<Button Classes="btn accent" Content="Continue"
|
||||
Command="{Binding ContinueCommand}"
|
||||
IsVisible="{Binding ShowContinue}" />
|
||||
IsVisible="{Binding ShowContinue}"
|
||||
ToolTip.Tip="{loc:Tr session.continueNoSessionTip}"
|
||||
ToolTip.ShowOnDisabled="True" />
|
||||
<Button Classes="btn" Content="Reset & Retry"
|
||||
Command="{Binding ResetAndRetryCommand}"
|
||||
IsVisible="{Binding ShowResetAndRetry}" />
|
||||
IsVisible="{Binding ShowResetAndRetry}"
|
||||
ToolTip.Tip="{loc:Tr session.resetAndRetryInteractiveTip}"
|
||||
ToolTip.ShowOnDisabled="True" />
|
||||
</StackPanel>
|
||||
</StackPanel>
|
||||
</Border>
|
||||
@@ -341,9 +345,12 @@
|
||||
<!-- Inspect: diff / worktree / combined diff -->
|
||||
<WrapPanel Orientation="Horizontal">
|
||||
<Button Classes="btn" Content="Open Diff" Margin="0,0,8,8"
|
||||
ToolTip.Tip="{loc:Tr agent.openDiffTip}"
|
||||
ToolTip.ShowOnDisabled="True"
|
||||
Command="{Binding Merge.OpenDiffCommand}" />
|
||||
<Button Classes="btn" Margin="0,0,8,8"
|
||||
ToolTip.Tip="{loc:Tr agent.openWorktreeTip}"
|
||||
ToolTip.ShowOnDisabled="True"
|
||||
Command="{Binding Merge.OpenWorktreeCommand}">
|
||||
<StackPanel Orientation="Horizontal" Spacing="5">
|
||||
<TextBlock Text="Worktree" />
|
||||
@@ -351,6 +358,8 @@
|
||||
</StackPanel>
|
||||
</Button>
|
||||
<Button Classes="btn" Content="Review Combined Diff" Margin="0,0,8,8"
|
||||
ToolTip.Tip="{loc:Tr agent.reviewCombinedDiffTip}"
|
||||
ToolTip.ShowOnDisabled="True"
|
||||
Command="{Binding Merge.ReviewCombinedDiffCommand}" />
|
||||
</WrapPanel>
|
||||
</StackPanel>
|
||||
@@ -371,6 +380,17 @@
|
||||
Text="Open the diff to enable merge" />
|
||||
</StackPanel>
|
||||
|
||||
<!-- Gate: a unit merge is draining this task's subtasks, so Cancel is locked
|
||||
until it finishes (mirrors the worker-side guard). -->
|
||||
<StackPanel Orientation="Horizontal" Spacing="6"
|
||||
IsVisible="{Binding ShowMergeDrainHint}">
|
||||
<PathIcon Data="{StaticResource Icon.Warning}" Width="11" Height="11"
|
||||
Foreground="{DynamicResource AmberBrush}" VerticalAlignment="Center" />
|
||||
<TextBlock Classes="meta" VerticalAlignment="Center"
|
||||
Foreground="{DynamicResource AmberBrush}"
|
||||
Text="{loc:Tr session.mergeDrainHint}" />
|
||||
</StackPanel>
|
||||
|
||||
<WrapPanel Orientation="Horizontal">
|
||||
<StackPanel Orientation="Horizontal" Spacing="{StaticResource SpaceSm}" Margin="0,0,8,8">
|
||||
<Button Classes="btn accent" Content="Approve & Merge"
|
||||
@@ -384,6 +404,8 @@
|
||||
<controls:OperationIndicator Status="{Binding ParkOp}" />
|
||||
</StackPanel>
|
||||
<Button Classes="btn" Content="Cancel" Margin="0,0,8,8"
|
||||
ToolTip.Tip="{loc:Tr session.mergeDrainHint}"
|
||||
ToolTip.ShowOnDisabled="True"
|
||||
Command="{Binding CancelReviewCommand}" />
|
||||
</WrapPanel>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user