From 4d0fcc557324c5d7be71cf7deafa158a4e81ab1c Mon Sep 17 00:00:00 2001 From: Taras Madan Date: Thu, 22 Aug 2024 17:48:57 +0200 Subject: pkg/cover: fix layout Html li item is not a block element by default. It allows sub-elements to overflow next line. This change still allow element to go next line, but the overall file tree layout will not be affected. --- pkg/cover/templates/cover.html | 43 +++++++++++++++++++++++------------------- 1 file changed, 24 insertions(+), 19 deletions(-) (limited to 'pkg/cover') diff --git a/pkg/cover/templates/cover.html b/pkg/cover/templates/cover.html index 0c7f46419..d45a0f74b 100644 --- a/pkg/cover/templates/cover.html +++ b/pkg/cover/templates/cover.html @@ -46,7 +46,7 @@ } .cover { float: right; - width: 250px; + width: 150px; padding-right: 4px; } .cover-right { @@ -105,7 +105,10 @@ .total-right { float: right; } - + .flex-column { + display: flex; + flex-direction: column; + } @@ -205,7 +208,7 @@ {{define "dir"}} {{range $dir := .Dirs}} -
  • +
  • {{$dir.Name}} @@ -219,25 +222,27 @@
  • {{end}} {{range $file := .Files}} -
  • - {{if $file.Covered}} - - {{$file.Name}} - - - - {{$file.Percent}}% +
  • + + {{if $file.Covered}} + + {{$file.Name}} - of {{$file.Total}} - - {{else}} - {{$file.Name}} - --- + + {{$file.Percent}}% + of {{$file.Total}} - {{end}} -
  • + {{else}} + {{$file.Name}} + + --- + of {{$file.Total}} + + {{end}} + + {{end}} {{end}} -- cgit mrf-deployment