diff --git a/cmd/formatter/colors.go b/cmd/formatter/colors.go index cf6a4b56c37..de3be20e567 100644 --- a/cmd/formatter/colors.go +++ b/cmd/formatter/colors.go @@ -37,7 +37,7 @@ var names = []string{ const ( BOLD = "1" - FAINT = "2" + DIM = "2" ITALIC = "3" UNDERLINE = "4" ) diff --git a/cmd/formatter/logs.go b/cmd/formatter/logs.go index 7d2c5451296..5a8b75a53ed 100644 --- a/cmd/formatter/logs.go +++ b/cmd/formatter/logs.go @@ -102,8 +102,6 @@ func (l *logConsumer) Err(container, message string) { l.write(l.stderr, container, message) } -var navColor = makeColorFunc("90") - func (l *logConsumer) write(w io.Writer, container, message string) { if l.ctx.Err() != nil { return diff --git a/cmd/formatter/shortcut.go b/cmd/formatter/shortcut.go index 831a5e4b476..37ee557d5e1 100644 --- a/cmd/formatter/shortcut.go +++ b/cmd/formatter/shortcut.go @@ -187,7 +187,6 @@ func (lk *LogKeyboard) printNavigationMenu() { } func (lk *LogKeyboard) navigationMenu() string { - var options string var openDDInfo string if lk.IsDockerDesktopActive { openDDInfo = shortcutKeyColor("v") + navColor(" View in Docker Desktop") @@ -201,7 +200,7 @@ func (lk *LogKeyboard) navigationMenu() string { isEnabled = " Disable" } watchInfo = watchInfo + shortcutKeyColor("w") + navColor(isEnabled+" Watch") - return options + openDDInfo + watchInfo + return openDDInfo + watchInfo } func (lk *LogKeyboard) clearNavigationMenu() { @@ -325,3 +324,7 @@ func shortcutKeyColor(key string) string { white := "255;255;255" return ansiColor(foreground+";"+black+";"+background+";"+white, key, BOLD) } + +func navColor(key string) string { + return ansiColor(DIM, key) +}