From ce2385d0d36d485f4aa108cccac99af2ad568dd8 Mon Sep 17 00:00:00 2001 From: Chris Aprea Date: Mon, 9 May 2022 15:58:35 +1000 Subject: [PATCH] Change the badge wording to "new". --- .../src/Internal/Admin/WcPaySubscriptionsPage.php | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/plugins/woocommerce/src/Internal/Admin/WcPaySubscriptionsPage.php b/plugins/woocommerce/src/Internal/Admin/WcPaySubscriptionsPage.php index 8d3c6b66759..c3ce8dd0582 100644 --- a/plugins/woocommerce/src/Internal/Admin/WcPaySubscriptionsPage.php +++ b/plugins/woocommerce/src/Internal/Admin/WcPaySubscriptionsPage.php @@ -76,10 +76,13 @@ class WcPaySubscriptionsPage { return; } - // Add the "1" badge. + // translators: Admin menu item badge. It is used alongside the "Subscriptions" menu item to grab attention and let merchants know that this is a new offering. + $new_badge_text = __( 'new', 'woocommerce' ); + + // Add the "new" badge. foreach ( $submenu['woocommerce'] as $key => $menu_item ) { if ( 'wc-admin&path=/subscriptions' === $menu_item[2] ) { - $submenu['woocommerce'][ $key ][0] .= ' 1'; // phpcs:ignore WordPress.WP.GlobalVariablesOverride.Prohibited + $submenu['woocommerce'][ $key ][0] .= sprintf( ' %s', esc_html( $new_badge_text ) ); // phpcs:ignore WordPress.WP.GlobalVariablesOverride.Prohibited break; } }