diff --git a/src/apps/review/src/lib/components/TableScorecards/TableScorecards.tsx b/src/apps/review/src/lib/components/TableScorecards/TableScorecards.tsx index 7a4f6c748..57c5b24c3 100644 --- a/src/apps/review/src/lib/components/TableScorecards/TableScorecards.tsx +++ b/src/apps/review/src/lib/components/TableScorecards/TableScorecards.tsx @@ -33,6 +33,9 @@ export const TableScorecards: FC = (props: Props) => { const { width: screenWidth }: WindowSize = useWindowSize() const isTablet = useMemo(() => screenWidth <= 1000, [screenWidth]) + const start = (props.page - 1) * (props.perPage ?? 0) + 1 + const end = Math.min(props.page * (props.perPage ?? 0), props.metadata?.total ?? 0) + const columns = useMemo[]>( () => [ { @@ -153,12 +156,15 @@ export const TableScorecards: FC = (props: Props) => { )}
- Showing 1- - {props.perPage} + Showing + {' '} + {start} + - + {end} {' '} of {' '} - {props.metadata.total} + {props.metadata?.total ?? 0} {' '} results
diff --git a/src/apps/review/src/pages/scorecards/ScorecardsListPage/ScorecardsListPage.tsx b/src/apps/review/src/pages/scorecards/ScorecardsListPage/ScorecardsListPage.tsx index e8144d6d0..f9daa156a 100644 --- a/src/apps/review/src/pages/scorecards/ScorecardsListPage/ScorecardsListPage.tsx +++ b/src/apps/review/src/pages/scorecards/ScorecardsListPage/ScorecardsListPage.tsx @@ -94,7 +94,7 @@ export const ScorecardsListPage: FC<{}> = () => { ) : ( <> {scorecards.length === 0 ? ( - + ) : (