Skip to content

Commit a95833d

Browse files
committed
Apply "closed" style to bug icon if all bugs associated with entry are closed.
1 parent 81faff1 commit a95833d

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

src/bug-label.ts

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,10 @@ export class BugLabel extends LitElement {
7878
`;
7979
}
8080

81+
private get allBugsClosed() {
82+
return this.bugMeta.every((bug) => !bug.isOpen);
83+
}
84+
8185
private renderMultipleBugsLabel() {
8286
return html`
8387
<a
@@ -87,7 +91,13 @@ export class BugLabel extends LitElement {
8791
rel="noopener noreferrer"
8892
title=${`Bug ${this.bugIds.join(", ")}`}
8993
>
90-
<img class="bug-icon" src=${bugzillaIcon} alt="Bugzilla Icon" width="32" height="32" />
94+
<img
95+
class="bug-icon ${this.allBugsClosed ? "closed" : ""}"
96+
src=${bugzillaIcon}
97+
alt="Bugzilla Icon"
98+
width="32"
99+
height="32"
100+
/>
91101
</a>
92102
`;
93103
}

0 commit comments

Comments
 (0)