diff --git a/assets/js/features/components/control.js b/assets/js/features/components/control.js index 0a05f02526..08fe013f84 100644 --- a/assets/js/features/components/control.js +++ b/assets/js/features/components/control.js @@ -13,7 +13,7 @@ import { } from '@wordpress/components'; import { safeHTML } from '@wordpress/dom'; import { RawHTML, WPElement } from '@wordpress/element'; -import { _n, __, sprintf } from '@wordpress/i18n'; +import { _n, __, _x, sprintf } from '@wordpress/i18n'; /** * Internal dependencies. @@ -162,15 +162,15 @@ const Control = ({ } if (titles.length === 2) { return sprintf( - /* translators: %1$s: first feature name, %2$s: second feature name */ - __('%1$s and %2$s', 'elasticpress'), + /* translators: %1$s: feature name(s), %2$s: last feature name */ + _x('%1$s and %2$s', 'two feature names', 'elasticpress'), titles[0], titles[1], ); } return sprintf( - /* translators: %1$s: comma-separated list of feature names, %2$s: last feature name */ - __('%1$s and %2$s', 'elasticpress'), + /* translators: %1$s: feature name(s), %2$s: last feature name */ + _x('%1$s and %2$s', 'multiple feature names', 'elasticpress'), titles.slice(0, -1).join(__(', ', 'elasticpress')), titles[titles.length - 1], ); diff --git a/assets/js/instant-results/components/results/pagination.js b/assets/js/instant-results/components/results/pagination.js index f2bd155149..4c10acb7d1 100644 --- a/assets/js/instant-results/components/results/pagination.js +++ b/assets/js/instant-results/components/results/pagination.js @@ -173,6 +173,7 @@ const Pagination = ({ offset, onNext, onPage = {}, onPrevious, perPage, total }) } }} aria-current={isCurrent ? 'page' : undefined} + /* translators: %d: Page number. */ aria-label={sprintf(__('Page %d', 'elasticpress'), page.value)} > {page.value} diff --git a/assets/js/synonyms/apps/synonyms-settings.js b/assets/js/synonyms/apps/synonyms-settings.js index d479224cda..16114d8bab 100644 --- a/assets/js/synonyms/apps/synonyms-settings.js +++ b/assets/js/synonyms/apps/synonyms-settings.js @@ -83,7 +83,7 @@ export default () => { title: ( !s.valid)}> { - /* translators: Synonyms count */ + /* translators: %d: Number of synonyms. */ sprintf(__('Synonyms (%d)', 'elasticpress'), synonyms.length) } @@ -94,7 +94,7 @@ export default () => { title: ( !s.valid)}> { - /* translators: Hyponyms count */ + /* translators: %d: Number of hyponyms. */ sprintf(__('Hyponyms (%d)', 'elasticpress'), hyponyms.length) } @@ -105,7 +105,7 @@ export default () => { title: ( !s.valid)}> { - /* translators: Replacements count */ + /* translators: %d: Number of replacements. */ sprintf(__('Replacements (%d)', 'elasticpress'), replacements.length) }