Skip to content

Commit 4e7fa08

Browse files
Fix whitespace issue in HTML report for files with long lines
The Bootstrap col-1/col-11 flex columns caused the line number column to take 8.33% of the table width, which became excessive when a long line made the table very wide, pushing the start of source code far to the right. Override the flex properties so the line number column only takes the space it needs.
1 parent 7c82e09 commit 4e7fa08

1 file changed

Lines changed: 11 additions & 0 deletions

File tree

  • src/Report/Html/Renderer/Template/css

src/Report/Html/Renderer/Template/css/style.css

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -224,11 +224,22 @@ table + .structure-heading {
224224
padding-top: 0.5em;
225225
}
226226

227+
table#code tr {
228+
flex-wrap: nowrap;
229+
}
230+
227231
table#code td:first-of-type {
232+
flex: 0 0 auto;
233+
width: auto;
228234
padding-left: .75em;
229235
padding-right: .75em;
230236
}
231237

238+
table#code td.codeLine {
239+
flex: 1 1 auto;
240+
width: auto;
241+
}
242+
232243
table#code td:first-of-type a {
233244
text-decoration: none;
234245
}

0 commit comments

Comments
 (0)