Fix subway graph line gap

In some cases a gap appears in the status page subway graph.
This change corrects that by only leaving a gap when necessary for
an icon or branch line.

Change-Id: I0abb156aa9d9b30fae4ec18ce2da9e4deaf7dbf1
This commit is contained in:
James E. Blair 2024-02-12 10:13:27 -08:00
parent ab71b7a8d4
commit 5467388477
2 changed files with 7 additions and 3 deletions

View File

@ -279,8 +279,14 @@ class Item extends React.Component {
className = ' zuul-change-row-line'
}
}
let lineStyle = {}
if (i === item._tree_index ||
item._tree_branches.indexOf(i) !== -1) {
// Icon or line image: leave a gap
lineStyle = {backgroundPositionY: '15px'}
}
row.push(
<td key={i} className={'zuul-change-row' + className}>
<td key={i} className={'zuul-change-row' + className} style={lineStyle}>
{i === item._tree_index ? this.renderStatusIcon(item) : ''}
{item._tree_branches.indexOf(i) !== -1 ? (
this.renderLineImg(item, i)) : ''}

View File

@ -343,12 +343,10 @@ a.refresh {
.zuul-change-row-line {
background: linear-gradient(#000, #000) no-repeat center/2px 100%;
background-position-y: 15px;
}
.zuul-change-row-line-dark {
background: linear-gradient(#fff, #fff) no-repeat center/2px 100%;
background-position-y: 15px;
}
.progress-bar-animated {