feat: Limit list mode cells to a maximum height of 3

Co-authored-by: aider (openai/andrew/openrouter/deepseek/deepseek-chat-v3.1) <aider@aider.chat>
This commit is contained in:
Andrew Phillips
2025-09-08 18:40:35 -03:00
parent 33a9049a1f
commit ef43c8a8f8

View File

@@ -136,11 +136,13 @@ pub fn mode_list(
}, },
}; };
// Apply alignment in one place // Apply alignment and max height
cell = match column.align { cell = match column.align {
crate::config::ColumnAlignment::Right => cell.set_alignment(CellAlignment::Right), crate::config::ColumnAlignment::Right => cell.set_alignment(CellAlignment::Right),
crate::config::ColumnAlignment::Left => cell.set_alignment(CellAlignment::Left), crate::config::ColumnAlignment::Left => cell.set_alignment(CellAlignment::Left),
}; };
// Set max height of 3 for the cell
let cell = cell.max_height(3);
table_row.add_cell(cell); table_row.add_cell(cell);
} }
table.add_row(table_row); table.add_row(table_row);