Skip to content

Commit

Permalink
PR feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
js-jankisalvi committed Aug 23, 2023
1 parent f69b714 commit 878b0f2
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 10 deletions.
14 changes: 7 additions & 7 deletions x-pack/plugins/cases/public/components/all_cases/translations.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,18 +31,18 @@ export const SHOWING_SELECTED_CASES = (totalRules: number) =>
defaultMessage: 'Selected {totalRules} {totalRules, plural, =1 {case} other {cases}}',
});

export const SHOWING_CASES = (totalCases: number, pageSize: number) =>
i18n.translate('xpack.cases.caseTable.showingCasesTitle', {
values: { totalCases, pageSize },
export const SHOWING_CASES = (totalRules: number, pageSize: number) =>
i18n.translate('xpack.cases.caseTable.showingCases', {
values: { totalRules, pageSize },
defaultMessage:
'Showing {pageSize} of {totalCases} {totalCases, plural, =1 {case} other {cases}}',
'Showing {pageSize} of {totalRules} {totalRules, plural, =1 {case} other {cases}}',
});

export const MAX_CASES = (totalCases: number) =>
export const MAX_CASES = (maxCases: number) =>
i18n.translate('xpack.cases.caseTable.maxCases', {
values: { totalCases },
values: { maxCases },
defaultMessage:
'The results were capped at {totalCases} to maintain performance. Try limiting your search to reduce the results.',
'The results were capped at {maxCases} to maintain performance. Try limiting your search to reduce the results.',
});

export const DISMISS = i18n.translate('xpack.cases.caseTable.dismiss', {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ export const CasesTableUtilityBar: FunctionComponent<Props> = React.memo(
margin-top: 4px;
`}
>
{i18n.MAX_CASES(totalCases)}
{i18n.MAX_CASES(MAX_DOCS_PER_PAGE)}
</EuiText>
</EuiFlexItem>
<EuiFlexItem grow={false}>
Expand Down Expand Up @@ -203,7 +203,7 @@ export const CasesTableUtilityBar: FunctionComponent<Props> = React.memo(
</EuiFlexGroup>
{modals}
{flyouts}
{hasReachedMaxCases && !isMessageDismissed && !isDoNotShowAgainSelected ? (
{hasReachedMaxCases && !isMessageDismissed && !isDoNotShowAgainSelected && (
<>
<EuiSpacer size="m" />
<EuiFlexGroup>
Expand All @@ -218,7 +218,7 @@ export const CasesTableUtilityBar: FunctionComponent<Props> = React.memo(
</EuiFlexGroup>
<EuiSpacer size="m" />
</>
) : null}
)}
</>
);
}
Expand Down

0 comments on commit 878b0f2

Please sign in to comment.