From 3072b462189dd111ec4621cd74797a9c41a265b0 Mon Sep 17 00:00:00 2001 From: Junegunn Choi Date: Sun, 24 Aug 2025 15:34:41 +0900 Subject: [PATCH] Adjust default themes Motivation: `--color 16` can be a better default than `dark` or `light`, since it uses the colors defined by the current theme. This usually blends in more naturally and works well in both light and dark modes. However, some elements were previously hard-coded with white or black foreground colors, which can cause rendering issues in certain terminal themes. * 16 * Avoid using black or white foreground colors, so it works better with both dark and light themes * Display 'info' in italic to better separate it from the other parts * dark / light * Display 'info' in italic for consistency --- src/tui/tui.go | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/tui/tui.go b/src/tui/tui.go index 965be337..46789ec1 100644 --- a/src/tui/tui.go +++ b/src/tui/tui.go @@ -929,13 +929,13 @@ func init() { Current: ColorAttr{colYellow, AttrUndefined}, CurrentMatch: ColorAttr{colGreen, AttrUndefined}, Spinner: ColorAttr{colGreen, AttrUndefined}, - Info: ColorAttr{colWhite, AttrUndefined}, + Info: ColorAttr{colDefault, Italic}, Cursor: ColorAttr{colRed, AttrUndefined}, Marker: ColorAttr{colMagenta, AttrUndefined}, Header: ColorAttr{colCyan, AttrUndefined}, Footer: ColorAttr{colCyan, AttrUndefined}, - Border: ColorAttr{colBlack, AttrUndefined}, - BorderLabel: ColorAttr{colWhite, AttrUndefined}, + Border: ColorAttr{colDefault, Dim}, + BorderLabel: ColorAttr{colDefault, AttrUndefined}, Ghost: ColorAttr{colUndefined, Dim}, Disabled: ColorAttr{colUndefined, AttrUndefined}, PreviewFg: ColorAttr{colUndefined, AttrUndefined}, @@ -977,7 +977,7 @@ func init() { Current: ColorAttr{254, AttrUndefined}, CurrentMatch: ColorAttr{151, AttrUndefined}, Spinner: ColorAttr{148, AttrUndefined}, - Info: ColorAttr{144, AttrUndefined}, + Info: ColorAttr{144, Italic}, Cursor: ColorAttr{161, AttrUndefined}, Marker: ColorAttr{168, AttrUndefined}, Header: ColorAttr{109, AttrUndefined}, @@ -1025,7 +1025,7 @@ func init() { Current: ColorAttr{237, AttrUndefined}, CurrentMatch: ColorAttr{23, AttrUndefined}, Spinner: ColorAttr{65, AttrUndefined}, - Info: ColorAttr{101, AttrUndefined}, + Info: ColorAttr{101, Italic}, Cursor: ColorAttr{161, AttrUndefined}, Marker: ColorAttr{168, AttrUndefined}, Header: ColorAttr{31, AttrUndefined},