Skip to content

Refactor listItems computed for clarity

Anna Vovchenko requested to merge follow-up-109508 into master

What does this MR do and why?

This MR implements a suggestion from !109508 (comment 1249635857)

Suggestion(not a blocker) For clarity I think the sortedDraft count can be moved at the beginning of the computed prop for better readability

    const sortedDraftCount = this.sortedDrafts.length - 1;
      return this.sortedDrafts.map((item, index) => ({
        text: item.id.toString(),
        action: () => {
          this.onClickDraft(item);
        },
        last: index === sortedDraftCount,
        ...item,
      }));
    },

Screenshots or screen recordings

No visual changes

How to set up and validate locally

  1. Start reviewing an MR with the Start review button
  2. Validate the Pending review comments dropdown

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Merge request reports

Loading