Skip to content

Commit

Permalink
feat: lighten colors in UI (#5689)
Browse files Browse the repository at this point in the history
  • Loading branch information
exu authored Jul 26, 2024
1 parent e545ebb commit c2e262c
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions pkg/ui/printers.go
Original file line number Diff line number Diff line change
Expand Up @@ -71,11 +71,11 @@ func (ui *UI) Alert(message string, subMessages ...string) {
}

func (ui *UI) LogLine(message string) {
fmt.Fprintf(ui.Writer, "%s\n", DarkGray(message))
fmt.Fprintf(ui.Writer, "%s\n", LightGray(message))
}

func (ui *UI) LogMultiLine(message string) {
fmt.Fprintf(ui.Writer, "%s\n\n", DarkGray(message))
fmt.Fprintf(ui.Writer, "%s\n\n", LightGray(message))
}

func (ui *UI) Debug(message string, subMessages ...string) {
Expand Down Expand Up @@ -127,7 +127,7 @@ func (ui *UI) PrintDisabled(message string, subMessages ...string) {
}

func (ui *UI) Info(message string, subMessages ...string) {
fmt.Fprintf(ui.Writer, "%s", DarkGray(message))
fmt.Fprintf(ui.Writer, "%s", White(message))
for _, sub := range subMessages {
fmt.Fprintf(ui.Writer, " %s", LightGray(sub))
}
Expand Down Expand Up @@ -157,8 +157,8 @@ func (ui *UI) Failf(err string, params ...interface{}) {
}

func (ui *UI) CommandOutput(output []byte, command string, params ...string) {
fullCommand := fmt.Sprintf("%s %s", LightCyan(command), DarkGray(strings.Join(params, " ")))
fmt.Fprintf(ui.Writer, "command: %s\noutput:\n%s\n", LightGray(fullCommand), DarkGray(string(output)))
fullCommand := fmt.Sprintf("%s %s", White(command), LightGray(strings.Join(params, " ")))
fmt.Fprintf(ui.Writer, "command: %s\noutput:\n%s\n", White(fullCommand), LightGray(string(output)))
}

func (ui *UI) Medal() {
Expand Down Expand Up @@ -187,7 +187,7 @@ func (ui *UI) GroupCompleted(main string, sub ...string) {

func (ui *UI) InfoGrid(table map[string]string) {
for k, v := range table {
fmt.Fprintf(ui.Writer, " %s: %s\n", DarkGray(k), LightBlue(v))
fmt.Fprintf(ui.Writer, " %s: %s\n", LightGray(k), LightBlue(v))
}
fmt.Fprintln(ui.Writer)
}
Expand All @@ -213,15 +213,15 @@ func (ui *UI) Properties(table [][]string) {

func (ui *UI) Vector(table []string) {
for _, v := range table {
fmt.Fprintf(ui.Writer, " %s\n", DarkGray(v))
fmt.Fprintf(ui.Writer, " %s\n", LightGray(v))
}
}

// Warn shows warning in terminal
func (ui *UI) ShellCommand(title string, commands ...string) {
fmt.Fprintf(ui.Writer, "$ %s", LightGray(title))
for _, sub := range commands {
fmt.Fprintf(ui.Writer, DarkGray(" \\\n")+LightGray("\t%s"), sub)
fmt.Fprintf(ui.Writer, LightGray(" \\\n\t%s"), sub)
}
fmt.Fprintln(ui.Writer)
}
Expand Down

0 comments on commit c2e262c

Please sign in to comment.