Render nicer indent for multi-line messages

This commit is contained in:
Joscha 2022-06-25 17:01:04 +02:00
parent 62033ee5bb
commit 54e5a7c97c

View file

@ -61,12 +61,13 @@ fn render_block<M: Msg>(frame: &mut Frame, pos: Pos, size: Size, block: &Block<M
continue;
}
render_indent(frame, pos.x, y, block.cursor, block.indent);
if i == 0 {
render_indent(frame, pos.x, y, block.cursor, block.indent);
render_time(frame, pos.x, y, block.cursor, block.time);
render_nick(frame, pos.x, y, block.indent, &msg.nick);
} else {
render_indent(frame, pos.x, y, false, block.indent + 1);
render_indent(frame, pos.x, y, block.cursor, block.indent);
render_time(frame, pos.x, y, block.cursor, None);
}