Make WordPress Core


Ignore:
Timestamp:
09/29/2017 11:41:06 AM (9 years ago)
Author:
SergeyBiryukov
Message:

I18N: Use a consistent pattern for translator comments for placeholders in Customizer and widget strings.

Props danieltj, Rahmohn.
Fixes #41974.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/script-loader.php

    r41626 r41640  
    474474        $scripts->add( 'wp-theme-plugin-editor', "/wp-admin/js/theme-plugin-editor$suffix.js", array( 'code-editor', 'jquery', 'jquery-ui-core', 'wp-a11y', 'underscore' ) );
    475475        did_action( 'init' ) && $scripts->add_inline_script( 'wp-theme-plugin-editor', sprintf( 'wp.themePluginEditor.l10n = %s;', wp_json_encode( wp_array_slice_assoc(
    476                 /* translators: placeholder is error count */
     476                /* translators: %d: error count */
    477477                _n_noop( 'There is %d error which must be fixed before you can save.', 'There are %d errors which must be fixed before you can save.' ),
    478478                array( 'singular', 'plural' )
    … …  
    572572                'untitledBlogName'   => __( '(Untitled)' ),
    573573                'serverSaveError'    => __( 'Failed connecting to the server. Please try saving again.' ),
    574                 /* translators: placeholder is URL to the Customizer to load the autosaved version */
     574                /* translators: %s: URL to the Customizer to load the autosaved version */
    575575                'autosaveNotice'     => __( 'There is a more recent autosave of your changes than the one you are previewing. <a href="%s">Restore the autosave</a>' ),
    576576                'videoHeaderNotice'  => __( 'This theme doesn\'t support video headers on this page. Navigate to the front page or another page that supports video headers.' ),
    … …  
    578578                'allowedFiles'       => __( 'Allowed Files' ),
    579579                'customCssError'     => wp_array_slice_assoc(
    580                         /* translators: placeholder is error count */
     580                        /* translators: %d: error count */
    581581                        _n_noop( 'There is %d error which must be fixed before you can save.', 'There are %d errors which must be fixed before you can save.' ),
    582582                        array( 'singular', 'plural' )
    … …  
    584584                'pageOnFrontError' => __( 'Homepage and posts page must be different.' ),
    585585                'saveBlockedError' => wp_array_slice_assoc(
    586                         /* translators: placeholder is error count */
     586                        /* translators: %s: error count */
    587587                        _n_noop( 'Unable to save due to %s invalid setting.', 'Unable to save due to %s invalid settings.' ),
    588588                        array( 'singular', 'plural' )
    … …  
    11711171
    11721172                        // This one is only used with wp.a11y.speak(), so it can/should be more brief.
    1173                         /* translators: %s is the name of a city. */
     1173                        /* translators: %s: the name of a city */
    11741174                        'city_updated' => __( 'City updated. Listing events near %s.' ),
    11751175                )
Note: See TracChangeset for help on using the changeset viewer.