From c34fad6c8bea71b37aab86d8c8dd1e771f8835cf Mon Sep 17 00:00:00 2001 From: audrasjb Date: Tue, 18 Apr 2023 08:24:25 +0000 Subject: [PATCH] Twenty Nineteen: Fix a translation issue in Comments navigation text. This changeset combines text strings for "Previous Comments" and "Next Comments" links to ensure translators can control word order in each string. The `span` tags are included in the translation to give more control over what is hidden on small screens. Props sabernhardt. Fixes #58149. Built from https://develop.svn.wordpress.org/trunk@55655 git-svn-id: http://core.svn.wordpress.org/trunk@55167 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-content/themes/twentynineteen/comments.php | 19 ++++++++++++++----- wp-includes/version.php | 2 +- 2 files changed, 15 insertions(+), 6 deletions(-) diff --git a/wp-content/themes/twentynineteen/comments.php b/wp-content/themes/twentynineteen/comments.php index 5e734d417e..3cd1768824 100644 --- a/wp-content/themes/twentynineteen/comments.php +++ b/wp-content/themes/twentynineteen/comments.php @@ -87,13 +87,22 @@ $discussion = twentynineteen_get_discussion_data(); // Show comment navigation. if ( have_comments() ) : - $prev_icon = twentynineteen_get_icon_svg( 'chevron_left', 22 ); - $next_icon = twentynineteen_get_icon_svg( 'chevron_right', 22 ); - $comments_text = __( 'Comments', 'twentynineteen' ); + $prev_icon = twentynineteen_get_icon_svg( 'chevron_left', 22 ); + $next_icon = twentynineteen_get_icon_svg( 'chevron_right', 22 ); the_comments_navigation( array( - 'prev_text' => sprintf( '%s %s %s', $prev_icon, __( 'Previous', 'twentynineteen' ), __( 'Comments', 'twentynineteen' ) ), - 'next_text' => sprintf( '%s %s %s', __( 'Next', 'twentynineteen' ), __( 'Comments', 'twentynineteen' ), $next_icon ), + 'prev_text' => sprintf( + '%1$s %2$s', + $prev_icon, + /* translators: Comments navigation link text. The secondary-text element is hidden on small screens. */ + __( 'Previous Comments', 'twentynineteen' ) + ), + 'next_text' => sprintf( + '%1$s %2$s', + /* translators: Comments navigation link text. The secondary-text element is hidden on small screens. */ + __( 'Next Comments', 'twentynineteen' ), + $next_icon + ), ) ); endif; diff --git a/wp-includes/version.php b/wp-includes/version.php index c8c2ee3349..1cbc2169f7 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -16,7 +16,7 @@ * * @global string $wp_version */ -$wp_version = '6.3-alpha-55654'; +$wp_version = '6.3-alpha-55655'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.