WordPress.org

Make WordPress Core


Ignore:
Timestamp:
09/03/2019 12:39:13 AM (7 weeks ago)
Author:
SergeyBiryukov
Message:

I18N: Capitalize translator comments consistently, add trailing punctuation.

Includes minor code layout fixes.

See #44360.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/includes/update.php

    r45926 r45932  
    133133        trigger_error(
    134134            sprintf(
    135                 /* translators: %s: support forums URL */
     135                /* translators: %s: Support forums URL. */
    136136                __( 'An unexpected error occurred. Something may be wrong with WordPress.org or this server&#8217;s configuration. If you continue to have problems, please try the <a href="%s">support forums</a>.' ),
    137137                __( 'https://wordpress.org/support/forums/' )
     
    210210function core_update_footer( $msg = '' ) {
    211211    if ( ! current_user_can( 'update_core' ) ) {
    212         /* translators: %s: WordPress version */
     212        /* translators: %s: WordPress version. */
    213213        return sprintf( __( 'Version %s' ), get_bloginfo( 'version', 'display' ) );
    214214    }
     
    234234        case 'development':
    235235            return sprintf(
    236                 /* translators: 1: WordPress version number, 2: WordPress updates admin screen URL */
     236                /* translators: 1: WordPress version number, 2: URL to WordPress Updates screen. */
    237237                __( 'You are using a development version (%1$s). Cool! Please <a href="%2$s">stay updated</a>.' ),
    238238                get_bloginfo( 'version', 'display' ),
     
    244244                '<strong><a href="%s">%s</a></strong>',
    245245                network_admin_url( 'update-core.php' ),
    246                 /* translators: %s: WordPress version */
     246                /* translators: %s: WordPress version. */
    247247                sprintf( __( 'Get Version %s' ), $cur->current )
    248248            );
     
    250250        case 'latest':
    251251        default:
    252             /* translators: %s: WordPress version */
     252            /* translators: %s: WordPress version. */
    253253            return sprintf( __( 'Version %s' ), get_bloginfo( 'version', 'display' ) );
    254254    }
     
    277277
    278278    $version_url = sprintf(
    279         /* translators: %s: WordPress version */
     279        /* translators: %s: WordPress version. */
    280280        esc_url( __( 'https://wordpress.org/support/wordpress-version/version-%s/' ) ),
    281281        sanitize_title( $cur->current )
     
    284284    if ( current_user_can( 'update_core' ) ) {
    285285        $msg = sprintf(
    286             /* translators: 1: URL to WordPress release notes, 2: new WordPress version, 3: URL to network admin, 4: accessibility text */
     286            /* translators: 1: URL to WordPress release notes, 2: New WordPress version, 3: URL to network admin, 4: Accessibility text. */
    287287            __( '<a href="%1$s">WordPress %2$s</a> is available! <a href="%3$s" aria-label="%4$s">Please update now</a>.' ),
    288288            $version_url,
     
    293293    } else {
    294294        $msg = sprintf(
    295             /* translators: 1: URL to WordPress release notes, 2: new WordPress version */
     295            /* translators: 1: URL to WordPress release notes, 2: New WordPress version. */
    296296            __( '<a href="%1$s">WordPress %2$s</a> is available! Please notify the site administrator.' ),
    297297            $version_url,
     
    318318                '<a href="%s" class="button" aria-describedby="wp-version">%s</a> ',
    319319                network_admin_url( 'update-core.php' ),
    320                 /* translators: %s: WordPress version number, or 'Latest' string */
     320                /* translators: %s: WordPress version number, or 'Latest' string. */
    321321                sprintf( __( 'Update to %s' ), $cur->current ? $cur->current : __( 'Latest' ) )
    322322            );
     
    324324    }
    325325
    326     /* translators: 1: version number, 2: theme name */
     326    /* translators: 1: Version number, 2: Theme name. */
    327327    $content = __( 'WordPress %1$s running %2$s theme.' );
    328328
     
    437437        if ( ! current_user_can( 'update_plugins' ) ) {
    438438            printf(
    439                 /* translators: 1: plugin name, 2: details URL, 3: additional link attributes, 4: version number */
     439                /* translators: 1: Plugin name, 2: Details URL, 3: Additional link attributes, 4: Version number. */
    440440                __( 'There is a new version of %1$s available. <a href="%2$s" %3$s>View version %4$s details</a>.' ),
    441441                $plugin_name,
     
    443443                sprintf(
    444444                    'class="thickbox open-plugin-details-modal" aria-label="%s"',
    445                     /* translators: 1: plugin name, 2: version number */
     445                    /* translators: 1: Plugin name, 2: Version number. */
    446446                    esc_attr( sprintf( __( 'View %1$s version %2$s details' ), $plugin_name, $response->new_version ) )
    447447                ),
     
    450450        } elseif ( empty( $response->package ) ) {
    451451            printf(
    452                 /* translators: 1: plugin name, 2: details URL, 3: additional link attributes, 4: version number */
     452                /* translators: 1: Plugin name, 2: Details URL, 3: Additional link attributes, 4: Version number. */
    453453                __( 'There is a new version of %1$s available. <a href="%2$s" %3$s>View version %4$s details</a>. <em>Automatic update is unavailable for this plugin.</em>' ),
    454454                $plugin_name,
     
    456456                sprintf(
    457457                    'class="thickbox open-plugin-details-modal" aria-label="%s"',
    458                     /* translators: 1: plugin name, 2: version number */
     458                    /* translators: 1: Plugin name, 2: Version number. */
    459459                    esc_attr( sprintf( __( 'View %1$s version %2$s details' ), $plugin_name, $response->new_version ) )
    460460                ),
     
    464464            if ( $compatible_php ) {
    465465                printf(
    466                     /* translators: 1: plugin name, 2: details URL, 3: additional link attributes, 4: version number, 5: update URL, 6: additional link attributes */
     466                    /* translators: 1: Plugin name, 2: Details URL, 3: Additional link attributes, 4: Version number, 5: Update URL, 6: Additional link attributes. */
    467467                    __( 'There is a new version of %1$s available. <a href="%2$s" %3$s>View version %4$s details</a> or <a href="%5$s" %6$s>update now</a>.' ),
    468468                    $plugin_name,
     
    470470                    sprintf(
    471471                        'class="thickbox open-plugin-details-modal" aria-label="%s"',
    472                         /* translators: 1: plugin name, 2: version number */
     472                        /* translators: 1: Plugin name, 2: Version number. */
    473473                        esc_attr( sprintf( __( 'View %1$s version %2$s details' ), $plugin_name, $response->new_version ) )
    474474                    ),
     
    477477                    sprintf(
    478478                        'class="update-link" aria-label="%s"',
    479                         /* translators: %s: plugin name */
     479                        /* translators: %s: Plugin name. */
    480480                        esc_attr( sprintf( __( 'Update %s now' ), $plugin_name ) )
    481481                    )
     
    483483            } else {
    484484                printf(
    485                     /* translators: 1: plugin name, 2: details URL, 3: additional link attributes, 4: version number 5: Update PHP page URL */
     485                    /* translators: 1: Plugin name, 2: Details URL, 3: Additional link attributes, 4: Version number 5: URL to Update PHP page. */
    486486                    __( 'There is a new version of %1$s available, but it doesn&#8217;t work with your version of PHP. <a href="%2$s" %3$s>View version %4$s details</a> or <a href="%5$s">learn more about updating PHP</a>.' ),
    487487                    $plugin_name,
     
    489489                    sprintf(
    490490                        'class="thickbox open-plugin-details-modal" aria-label="%s"',
    491                         /* translators: 1: plugin name, 2: version number */
     491                        /* translators: 1: Plugin name, 2: Version number. */
    492492                        esc_attr( sprintf( __( 'View %1$s version %2$s details' ), $plugin_name, $response->new_version ) )
    493493                    ),
     
    619619    if ( ! current_user_can( 'update_themes' ) ) {
    620620        printf(
    621             /* translators: 1: theme name, 2: details URL, 3: additional link attributes, 4: version number */
     621            /* translators: 1: Theme name, 2: Details URL, 3: Additional link attributes, 4: Version number. */
    622622            __( 'There is a new version of %1$s available. <a href="%2$s" %3$s>View version %4$s details</a>.' ),
    623623            $theme['Name'],
     
    625625            sprintf(
    626626                'class="thickbox open-plugin-details-modal" aria-label="%s"',
    627                 /* translators: 1: theme name, 2: version number */
     627                /* translators: 1: Theme name, 2: Version number. */
    628628                esc_attr( sprintf( __( 'View %1$s version %2$s details' ), $theme['Name'], $response['new_version'] ) )
    629629            ),
     
    632632    } elseif ( empty( $response['package'] ) ) {
    633633        printf(
    634             /* translators: 1: theme name, 2: details URL, 3: additional link attributes, 4: version number */
     634            /* translators: 1: Theme name, 2: Details URL, 3: Additional link attributes, 4: Version number. */
    635635            __( 'There is a new version of %1$s available. <a href="%2$s" %3$s>View version %4$s details</a>. <em>Automatic update is unavailable for this theme.</em>' ),
    636636            $theme['Name'],
     
    638638            sprintf(
    639639                'class="thickbox open-plugin-details-modal" aria-label="%s"',
    640                 /* translators: 1: theme name, 2: version number */
     640                /* translators: 1: Theme name, 2: Version number. */
    641641                esc_attr( sprintf( __( 'View %1$s version %2$s details' ), $theme['Name'], $response['new_version'] ) )
    642642            ),
     
    645645    } else {
    646646        printf(
    647             /* translators: 1: theme name, 2: details URL, 3: additional link attributes, 4: version number, 5: update URL, 6: additional link attributes */
     647            /* translators: 1: Theme name, 2: Details URL, 3: Additional link attributes, 4: Version number, 5: Update URL, 6: Additional link attributes. */
    648648            __( 'There is a new version of %1$s available. <a href="%2$s" %3$s>View version %4$s details</a> or <a href="%5$s" %6$s>update now</a>.' ),
    649649            $theme['Name'],
     
    651651            sprintf(
    652652                'class="thickbox open-plugin-details-modal" aria-label="%s"',
    653                 /* translators: 1: theme name, 2: version number */
     653                /* translators: 1: Theme name, 2: Version number. */
    654654                esc_attr( sprintf( __( 'View %1$s version %2$s details' ), $theme['Name'], $response['new_version'] ) )
    655655            ),
     
    658658            sprintf(
    659659                'class="update-link" aria-label="%s"',
    660                 /* translators: %s: theme name */
     660                /* translators: %s: Theme name. */
    661661                esc_attr( sprintf( __( 'Update %s now' ), $theme['Name'] ) )
    662662            )
     
    719719    if ( current_user_can( 'update_core' ) ) {
    720720        $msg = sprintf(
    721             /* translators: %s: URL to WordPress Updates screen */
     721            /* translators: %s: URL to WordPress Updates screen. */
    722722            __( 'An automated WordPress update has failed to complete - <a href="%s">please attempt the update again now</a>.' ),
    723723            'update-core.php'
     
    758758                        <# if ( 'plugin' === data.type ) { #>
    759759                            <?php
    760                             /* translators: %s: Number of plugins */
     760                            /* translators: %s: Number of plugins. */
    761761                            printf( __( '%s plugin successfully updated.' ), '{{ data.successes }}' );
    762762                            ?>
    763763                        <# } else { #>
    764764                            <?php
    765                             /* translators: %s: Number of themes */
     765                            /* translators: %s: Number of themes. */
    766766                            printf( __( '%s theme successfully updated.' ), '{{ data.successes }}' );
    767767                            ?>
     
    770770                        <# if ( 'plugin' === data.type ) { #>
    771771                            <?php
    772                             /* translators: %s: Number of plugins */
     772                            /* translators: %s: Number of plugins. */
    773773                            printf( __( '%s plugins successfully updated.' ), '{{ data.successes }}' );
    774774                            ?>
    775775                        <# } else { #>
    776776                            <?php
    777                             /* translators: %s: Number of themes */
     777                            /* translators: %s: Number of themes. */
    778778                            printf( __( '%s themes successfully updated.' ), '{{ data.successes }}' );
    779779                            ?>
     
    785785                        <# if ( 1 === data.errors ) { #>
    786786                            <?php
    787                             /* translators: %s: Number of failed updates */
     787                            /* translators: %s: Number of failed updates. */
    788788                            printf( __( '%s update failed.' ), '{{ data.errors }}' );
    789789                            ?>
    790790                        <# } else { #>
    791791                            <?php
    792                             /* translators: %s: Number of failed updates */
     792                            /* translators: %s: Number of failed updates. */
    793793                            printf( __( '%s updates failed.' ), '{{ data.errors }}' );
    794794                            ?>
     
    853853                    <?php
    854854                    printf(
    855                         /* translators: %s: Plugin name */
     855                        /* translators: %s: Plugin name. */
    856856                        _x( '%s was successfully deleted.', 'plugin' ),
    857857                        '<strong>{{{ data.name }}}</strong>'
     
    861861                    <?php
    862862                    printf(
    863                         /* translators: %s: Theme name */
     863                        /* translators: %s: Theme name. */
    864864                        _x( '%s was successfully deleted.', 'theme' ),
    865865                        '<strong>{{{ data.name }}}</strong>'
     
    892892            <?php
    893893            printf(
    894                 /* translators: %s: Recovery Mode exit link */
     894                /* translators: %s: Recovery Mode exit link. */
    895895                __( 'You are in recovery mode. This means there may be an error with a theme or plugin. To exit recovery mode, log out or use the Exit button. <a href="%s">Exit Recovery Mode</a>' ),
    896896                esc_url( $url )
Note: See TracChangeset for help on using the changeset viewer.