Make WordPress Core


Ignore:
Timestamp:
02/07/2023 05:08:26 PM (2 years ago)
Author:
SergeyBiryukov
Message:

I18N: Mark screen reader strings as such with translator comments.

This aims to provide better context for translators and make it easier to determine that some strings contain hidden accessibility text and are not displayed in the UI.

Props kebbet, mercime, pavelevap, ocean90, swissspidy, Chouby, jipmoors, afercia, desrosj, costdev, audrasjb, SergeyBiryukov.
Fixes #29748.

File:
1 edited

Legend:

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

    r55187 r55276  
    22622262    ?>
    22632263    <p id="async-upload-wrap">
    2264         <label class="screen-reader-text" for="async-upload"><?php _e( 'Upload' ); ?></label>
     2264        <label class="screen-reader-text" for="async-upload">
     2265            <?php
     2266            /* translators: Hidden accessibility text. */
     2267            _e( 'Upload' );
     2268            ?>
     2269        </label>
    22652270        <input type="file" name="async-upload" id="async-upload" />
    22662271        <?php submit_button( __( 'Upload' ), 'primary', 'html-upload', false ); ?>
     
    27302735
    27312736    <p id="media-search" class="search-box">
    2732         <label class="screen-reader-text" for="media-search-input"><?php _e( 'Search Media' ); ?>:</label>
     2737        <label class="screen-reader-text" for="media-search-input">
     2738            <?php
     2739            /* translators: Hidden accessibility text. */
     2740            echo __( 'Search Media' ) . ':';
     2741            ?>
     2742        </label>
    27332743        <input type="search" id="media-search-input" name="s" value="<?php the_search_query(); ?>" />
    27342744        <?php submit_button( __( 'Search Media' ), '', '', false ); ?>
     
    32233233            sprintf(
    32243234                '<span class="screen-reader-text"> %s</span>',
    3225                 /* translators: Accessibility text. */
     3235                /* translators: Hidden accessibility text. */
    32263236                __( '(opens in a new tab)' )
    32273237            )
Note: See TracChangeset for help on using the changeset viewer.