feat(tui): branch names look more like 'pills'
All checks were successful
Rust / build (push) Successful in 10m7s
ci/woodpecker/push/cron-docker-builder Pipeline was successful
ci/woodpecker/push/push-next Pipeline was successful
ci/woodpecker/push/tag-created Pipeline was successful
Release Please / Release-plz (push) Successful in 1m21s

Use round brackets
This commit is contained in:
Paul Campbell 2024-08-31 19:20:50 +01:00
parent d2048d8a34
commit 2b09872131

View file

@ -1,3 +1,4 @@
use color_eyre::owo_colors::OwoColorize;
//
use git_next_core::git::graph::Log;
use lazy_static::lazy_static;
@ -84,12 +85,10 @@ impl From<LogLine> for Line<'_> {
branches.sort();
branches
.into_iter()
.map(|branch| Span::from(branch).style(Style::default().fg(Color::Blue)))
.for_each(|span| {
spans.push("[".into());
spans.push(span);
spans.push("]".into());
});
.map(|branch| format!("({branch})"))
.map(Span::from)
.map(|span| span.style(Style::default().fg(Color::White).bg(Color::Blue)))
.for_each(|span| spans.push(span));
spans.push(" ".into());
spans.push(message.into());
Line::from(spans)