mirror of
https://github.com/JanDeDobbeleer/oh-my-posh.git
synced 2024-12-26 19:39:39 -08:00
fix: do not print invisible text
This commit is contained in:
parent
f860c8cb55
commit
3d4b3c891c
|
@ -97,7 +97,7 @@ func (a *AnsiColor) getAnsiFromColorString(colorString string, isBackground bool
|
|||
|
||||
func (a *AnsiColor) writeColoredText(background, foreground, text string) {
|
||||
// Avoid emitting empty strings with color codes
|
||||
if text == "" {
|
||||
if text == "" || (foreground == Transparent && background == Transparent) {
|
||||
return
|
||||
}
|
||||
// default to white fg if empty, empty backgrond is supported
|
||||
|
|
Loading…
Reference in a new issue