Commit 1c1faa3453

1c1faa3453d2deac92955b4b2cc7f331894c1927

parent: b891f3ae5e

Unregistered key

Matthew Kabat <45803702+Nightchicken@users.noreply.github.com> · 2026-10-21 05:19 UTC
committer: <noreply@github.com>

Avoid setting background colors in `default` ANSI theme (#807)

Co-authored-by: Ulyssa <git@ulyssa.dev>

Layout: unified · split

src/config/theme.rs +2 −10
@@ -17,9 +17,9 @@ pub fn default_theme() -> Theme {
1717 messages: ThemeMessages {
1818 blockquote: LineStylable {
1919 line: Some(LineName::Thick),
20 stylable: Stylable::fg(Color::Indexed(236)),
20 stylable: Stylable::fg(Color::Cyan),
2121 },
22 code: Stylable::bg(Color::Indexed(236)),
22 code: Stylable::fg(Color::Cyan),
2323 code_block: LineStylable {
2424 line: Some(LineName::Plain),
2525 stylable: Stylable::default(),
@@ -302,14 +302,6 @@ struct Stylable {
302302}
303303
304304impl Stylable {
305 fn bg(c: Color) -> Self {
306 Self {
307 background: Some(c),
308 color: None,
309 modifiers: vec![],
310 }
311 }
312
313305 fn fg(c: Color) -> Self {
314306 Self {
315307 background: None,
src/message/html.rs +1 −1
@@ -1178,7 +1178,7 @@ pub mod tests {
11781178 let s = "<blockquote>Hello world!</blockquote>";
11791179 let tree = parse_matrix_html(s);
11801180 let text = tree.to_text(10, Style::default(), &settings, &info);
1181 let style = Style::new().fg(Color::Indexed(236));
1181 let style = Style::new().fg(Color::Cyan);
11821182 assert_eq!(text.lines.len(), 2);
11831183 assert_eq!(
11841184 text.lines[0],