From e686bc3f5e1fb6177baa7d0f8d31977a61067225 Mon Sep 17 00:00:00 2001 From: Jason Robbins Date: Sat, 4 Jan 2025 00:10:46 +0000 Subject: [PATCH] Offer a "Re-request Review" button (#4665) --- client-src/elements/chromedash-gate-column.ts | 22 +++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/client-src/elements/chromedash-gate-column.ts b/client-src/elements/chromedash-gate-column.ts index 84e1afab1e99..f56436627355 100644 --- a/client-src/elements/chromedash-gate-column.ts +++ b/client-src/elements/chromedash-gate-column.ts @@ -550,6 +550,26 @@ export class ChromedashGateColumn extends LitElement { `; } + renderReviewStatusNeedsWork() { + const rereviewButton = !this.userCanRequestReview() + ? nothing + : html` +
+ Re-request review +
+ `; + + return html` +
Reviewer has indicated a need for rework.
+ ${rereviewButton} + `; + } + renderReviewRequest() { for (const v of this.votes) { if (v.state === GATE_REVIEW_REQUESTED || v.state === GATE_NA_REQUESTED) { @@ -587,6 +607,8 @@ export class ChromedashGateColumn extends LitElement { renderReviewStatus() { if (this.gate.state == GATE_PREPARING) { return this.renderReviewStatusPreparing(); + } else if (this.gate.state == VOTE_OPTIONS.NEEDS_WORK[0]) { + return this.renderReviewStatusNeedsWork(); } else if (this.gate.state == VOTE_OPTIONS.APPROVED[0]) { return this.renderReviewStatusApproved(); } else if (this.gate.state == VOTE_OPTIONS.DENIED[0]) {