-
Notifications
You must be signed in to change notification settings - Fork 646
A grid/table fails if a column width autosizes to zero. #361
Copy link
Copy link
Closed
Milestone
Description
Information
- Version: most recent master efa3d3b
Describe the bug
If a grid is created (I guess it's the same for tables, because a grid internally creates a table) and in one of the columns all rows have the content string.Empty the entire grid collapses to a single ellipsis ….
To Reproduce
// Works as expected:
AnsiConsole.Console.Write(
new Grid()
.AddColumns(2)
.AddRow("A", "B")
.AddRow("X", "Y")
);
// Produces:
// A B
// X Y
// This fails:
AnsiConsole.Console.Write(
new Grid()
.AddColumns(2)
.AddRow(string.Empty, "B")
.AddRow(string.Empty, "Y")
);
// Produces:
// …Expected behavior
The expected behaviour would be to measure the column, determine that it's zero width and not render it, but still render the second column like so:
// Result:
// B
// YReactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels