Skip to content

Commit 67393eb

Browse files
committed
Scale panel width to terminal size (min 80 chars)
1 parent de1b5cd commit 67393eb

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/Asynkron.TestRunner/LiveDisplay.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@ namespace Asynkron.TestRunner;
99
/// </summary>
1010
public class LiveDisplay
1111
{
12-
private const int PanelWidth = 80;
13-
private const int ContentWidth = PanelWidth - 4; // Account for panel borders
12+
private static int PanelWidth => Math.Max(80, Console.WindowWidth - 2);
13+
private static int ContentWidth => PanelWidth - 4; // Account for panel borders
1414

1515
private readonly Stopwatch _stopwatch = Stopwatch.StartNew();
1616
private readonly object _lock = new();

0 commit comments

Comments
 (0)