From 96340909f14c6c0fdb58b9604a19fc5ff163344c Mon Sep 17 00:00:00 2001 From: Bogdan Date: Sat, 8 Jul 2023 18:16:02 +0300 Subject: [PATCH] Add translations to SearchFooter --- frontend/src/Search/SearchFooter.js | 4 ++-- src/NzbDrone.Core/Localization/Core/en.json | 4 ++++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/frontend/src/Search/SearchFooter.js b/frontend/src/Search/SearchFooter.js index 21d0789a2..404ad7e79 100644 --- a/frontend/src/Search/SearchFooter.js +++ b/frontend/src/Search/SearchFooter.js @@ -191,10 +191,10 @@ class SearchFooter extends Component { icon = icons.SEARCH; } - let footerLabel = `Search ${searchIndexerIds.length === 0 ? 'all' : searchIndexerIds.length} Indexers`; + let footerLabel = searchIndexerIds.length === 0 ? translate('SearchAllIndexers') : translate('SearchCountIndexers', [searchIndexerIds.length]); if (isPopulated) { - footerLabel = selectedCount === 0 ? `Found ${itemCount} releases` : `Selected ${selectedCount} of ${itemCount} releases`; + footerLabel = selectedCount === 0 ? translate('FoundCountReleases', [itemCount]) : translate('SelectedCountOfCountReleases', [selectedCount, itemCount]); } return ( diff --git a/src/NzbDrone.Core/Localization/Core/en.json b/src/NzbDrone.Core/Localization/Core/en.json index b993988ad..2d3e7bdd8 100644 --- a/src/NzbDrone.Core/Localization/Core/en.json +++ b/src/NzbDrone.Core/Localization/Core/en.json @@ -180,6 +180,7 @@ "FocusSearchBox": "Focus Search Box", "Folder": "Folder", "ForMoreInformationOnTheIndividualDownloadClients": "For more information on the individual download clients, click on the info buttons.", + "FoundCountReleases": "Found {0} releases", "FullSync": "Full Sync", "General": "General", "GeneralSettings": "General Settings", @@ -389,7 +390,9 @@ "Scheduled": "Scheduled", "ScriptPath": "Script Path", "Search": "Search", + "SearchAllIndexers": "Search all indexers", "SearchCapabilities": "Search Capabilities", + "SearchCountIndexers": "Search {0} indexers", "SearchIndexers": "Search Indexers", "SearchType": "Search Type", "SearchTypes": "Search Types", @@ -398,6 +401,7 @@ "Seeders": "Seeders", "SelectAll": "Select All", "SelectIndexers": "Select Indexers", + "SelectedCountOfCountReleases": "Selected {0} of {0} releases", "SemiPrivate": "Semi-Private", "SendAnonymousUsageData": "Send Anonymous Usage Data", "SetTags": "Set Tags",