Do not show neutral label votes in check result rows
Change-Id: I4878a89d68a2fdc93fbb30d105940dd47a6686df
diff --git a/polygerrit-ui/app/elements/checks/gr-checks-results.ts b/polygerrit-ui/app/elements/checks/gr-checks-results.ts
index 9a6a46d..fd8cd80 100644
--- a/polygerrit-ui/app/elements/checks/gr-checks-results.ts
+++ b/polygerrit-ui/app/elements/checks/gr-checks-results.ts
@@ -424,10 +424,14 @@
if (!this.result?.isLatestAttempt) return;
const info = this.labels?.[label];
const status = getLabelStatus(info).toLowerCase();
- const value = valueString(getRepresentativeValue(info));
+ const value = getRepresentativeValue(info);
+ // A neutral vote is not interesting for the user to see and is just
+ // cluttering the UI.
+ if (value === 0) return;
+ const valueStr = valueString(value);
return html`
<div class="label ${status}">
- <span>${label} ${value}</span>
+ <span>${label} ${valueStr}</span>
<paper-tooltip offset="5" fit-to-visible-bounds="true">
The check result has (probably) influenced this label vote.
</paper-tooltip>