diff --git a/cmd/cover/html.go b/cmd/cover/html.go index 864359afd7..5680a702c4 100644 --- a/cmd/cover/html.go +++ b/cmd/cover/html.go @@ -288,11 +288,11 @@ func rgb(n int) string { if n == 0 { return "rgb(255, 0, 0)" // Red } - // Gradient from pale green (low count) - // to bright green (high count) - r := 240 - 22*(n-1) - b := 170 + r/3 - return fmt.Sprintf("rgb(%v, 255, %v)", r, b) + // Gradient from pale blue (low count) to yellow (high count) + r := 185 + 7*(n-1) + g := 185 + 7*(n-1) + b := 5 + 25*(11-n) + return fmt.Sprintf("rgb(%v, %v, %v)", r, g, b) } // colors generates the CSS rules for coverage colors. @@ -322,7 +322,21 @@ const tmplHTML = `
@@ -334,6 +348,23 @@ const tmplHTML = ` {{end}} +{{$f.Body}}{{end}}