Skip to content

Commit

Permalink
fix: don't render bold ANSI sequence when colors are disabled (#515)
Browse files Browse the repository at this point in the history
  • Loading branch information
adam12 authored Jul 10, 2023
1 parent 2c267dd commit bb2eaa8
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions internal/log/log.go
Original file line number Diff line number Diff line change
Expand Up @@ -193,6 +193,10 @@ func Gray(s string) string {
}

func Bold(s string) string {
if !std.colors {
return lipgloss.NewStyle().Render(s)
}

return lipgloss.NewStyle().Bold(true).Render(s)
}

Expand Down

0 comments on commit bb2eaa8

Please sign in to comment.