-
Notifications
You must be signed in to change notification settings - Fork 23
feat(PM-4079): UI updates on Review/Appeals tab #1508
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 7 commits
42bdd33
ff1b989
24c24f3
7a145d3
f577199
838e28d
bb6c314
8badeb9
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -116,8 +116,9 @@ const AiReviewsTable: FC<AiReviewsTableProps> = props => { | |
| <table className={styles.reviewsTable}> | ||
| <thead> | ||
| <tr> | ||
| <th>AI Reviewer</th> | ||
| <th>Reviewer</th> | ||
| <th>Review Date</th> | ||
| <th>Min Score</th> | ||
| <th className={styles.scoreCol}>Score</th> | ||
| <th>Result</th> | ||
| </tr> | ||
|
|
@@ -126,7 +127,7 @@ const AiReviewsTable: FC<AiReviewsTableProps> = props => { | |
| <tbody> | ||
| {!runs.length && isLoading && ( | ||
| <tr> | ||
| <td colSpan={4}>Loading...</td> | ||
| <td colSpan={5}>Loading...</td> | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [ |
||
| </tr> | ||
| )} | ||
|
|
||
|
|
@@ -151,6 +152,9 @@ const AiReviewsTable: FC<AiReviewsTableProps> = props => { | |
| .format(TABLE_DATE_FORMAT) | ||
| )} | ||
| </td> | ||
| <td> | ||
| {run.workflow?.scorecard?.minimumPassingScore ?? '-'} | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [ |
||
| </td> | ||
| <td className={styles.scoreCol}> | ||
| {run.status === 'SUCCESS' ? ( | ||
| run.workflow.id ? ( | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,3 +1,4 @@ | ||
| /* eslint-disable complexity */ | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [ |
||
| /** | ||
| * Content of review tab. | ||
| */ | ||
|
|
@@ -169,6 +170,10 @@ export const TabContentReview: FC<Props> = (props: Props) => { | |
| () => !props.isActiveChallenge && normalizedSelectedTab === 'review', | ||
| [normalizedSelectedTab, props.isActiveChallenge], | ||
| ) | ||
| const isCombinedReviewAppeals = useMemo( | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [💡 |
||
| () => normalizedSelectedTab === 'reviewappeals', | ||
| [normalizedSelectedTab], | ||
| ) | ||
| const { | ||
| challengeInfo, | ||
| challengeSubmissions: backendChallengeSubmissions, | ||
|
|
@@ -685,7 +690,7 @@ export const TabContentReview: FC<Props> = (props: Props) => { | |
| return <TableLoading /> | ||
| } | ||
|
|
||
| if (selectedTab === 'Appeals Response') { | ||
| if (!isCombinedReviewAppeals && selectedTab === 'Appeals Response') { | ||
| return ( | ||
| <TableAppealsResponse | ||
| datas={resolvedReviewsWithSubmitter} | ||
|
|
@@ -703,7 +708,7 @@ export const TabContentReview: FC<Props> = (props: Props) => { | |
| return <TableNoRecord message='No reviews yet' /> | ||
| } | ||
|
|
||
| if (selectedTab === 'Appeals') { | ||
| if (!isCombinedReviewAppeals && selectedTab === 'Appeals') { | ||
| return isSubmitterView ? ( | ||
| <TableAppealsForSubmitter | ||
| datas={filteredSubmitterReviews} | ||
|
|
@@ -741,6 +746,7 @@ export const TabContentReview: FC<Props> = (props: Props) => { | |
| downloadSubmission={props.downloadSubmission} | ||
| mappingReviewAppeal={props.mappingReviewAppeal} | ||
| hideHandleColumn={hideHandleColumn} | ||
| mode={isCombinedReviewAppeals ? 'combined-review-appeals' : 'default'} | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [ |
||
| /> | ||
| ) | ||
| } | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -4,6 +4,15 @@ | |
| display: flex; | ||
| flex-direction: column; | ||
|
|
||
| &:global(.enhanced-table) table tbody tr:global(.row-before-expand) td[data-col-index='0'], | ||
| &:global(.enhanced-table) table tbody tr:global(.row-before-expand) td[data-col-index='1'] { | ||
| border-bottom: none !important; | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [ |
||
| } | ||
|
|
||
| &:global(.enhanced-table) table tbody tr:not(:global(.expand-row)) td { | ||
| border-top: none !important; | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [ |
||
| } | ||
|
|
||
| @include ltemd { | ||
| &:global(.enhanced-table) { | ||
| table { | ||
|
|
@@ -17,6 +26,10 @@ | |
| } | ||
| } | ||
| } | ||
|
|
||
| &:global(.enhanced-table) table tbody tr:global(.expand-row):has(.aiReviews) td { | ||
| border-bottom: var(--TableBorderColor) solid 1px !important; | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [ |
||
| } | ||
| } | ||
|
|
||
| .textBlue { | ||
|
|
@@ -214,13 +227,11 @@ | |
| .aiReviews { | ||
| margin: $sp-2 0; | ||
| :global(.trigger) { | ||
| width: fit-content; | ||
| margin-left: auto; | ||
| margin-left: 16px; | ||
| } | ||
|
|
||
| :global(.reviews-table) { | ||
| margin-left: auto; | ||
| width: 60%; | ||
| margin-bottom: -9px; | ||
|
|
||
| @include ltelg { | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[⚠️
performance]The use of
rowSpanOrFnas a function to determinerowSpanis flexible, but ensure that the function is performant and doesn't introduce unnecessary complexity or performance overhead, especially ifprops.datais large or complex.