Audit follow-ups: keyboard, wording, performance, transfer, sync, retry and relay fixes #22

Merged
jaap-jan merged 21 commits from claude/audit-followups into main 2026-10-02 12:59:56 +00:00
2 changed files with 44 additions and 1 deletions
Showing only changes of commit 619f49a35a - Show all commits

No files matched your search

@@ -86,7 +86,14 @@
Classes.connecting="{Binding IsConnecting}"
Classes.dropped="{Binding IsDropped}"
VerticalAlignment="Center" />
<TextBlock Text="{Binding Label}" VerticalAlignment="Center" />
<!--
Bounded. A label is whatever the host was called, or the address typed into the palette,
and one long one used to push every tab after it and the "+" past the strip's edge. The
whole of it is on the label's own tooltip; the tab's is the address, as before.
-->
<TextBlock Text="{Binding Label}" VerticalAlignment="Center"
MaxWidth="200" TextTrimming="CharacterEllipsis"
ToolTip.Tip="{Binding Label}" />
<Button Classes="flat close inline" Width="16" Height="16" Padding="0"
VerticalAlignment="Center"
@@ -250,6 +250,42 @@ public sealed class SessionTabRowTests : IAsyncLifetime
Token);
}
/// <remarks>
/// A label is whatever the host was called or the address typed into the palette, and nothing bounded it:
/// one long one pushed the "+" past the edge of the strip, behind a scroll bar nobody looks for.
/// </remarks>
[Fact]
public async Task ALongLabelIsTrimmed_AndLeavesThePlusOnTheStrip()
{
await LayoutHarness.OnTheUiThreadAsync(
() =>
{
var label = string.Concat(Enumerable.Repeat("a-very-long-host-name-", 12));
shell.Tabs.Add(new TerminalTabViewModel(1, label, "deploy@long.internal:22"));
var strip = new SessionTabRow { DataContext = shell, TabCommand = shell.SelectTabCommand };
var window = LayoutHarness.HostAtMinimumSize(
strip, LayoutHarness.MinimumWidth, LayoutHarness.MinimumHeight);
try
{
var text = strip.GetVisualDescendants().OfType<TextBlock>()
.Single(block => string.Equals(block.Text, label, StringComparison.Ordinal));
text.Bounds.Width.ShouldBeLessThanOrEqualTo(200);
ToolTip.GetTip(text).ShouldBe(label, "the whole of it is still one hover away");
LayoutHarness.Unreachable(window).ShouldBeEmpty();
}
finally
{
window.Close();
}
},
Token);
}
/// <remarks>
/// v5b's tab, unlike the pill it replaced, paints no fill at all until it is either active or hovered —
/// so "the plus differs from a tab" can no longer be proven against a resting, inactive one, which reads