Make WordPress Core

Changeset 26725


Ignore:
Timestamp:
12/06/2013 02:36:07 PM (10 years ago)
Author:
nacin
Message:

Map old -width theme tags to new -layout tags for the purposes of translation in the admin.

see #21442.

Location:
trunk/src
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/css/wp-admin.css

    r26720 r26725  
    70077007    margin: 30px 0 0 0;
    70087008    padding-top: 20px;
    7009     text-transform: capitalize;
    70107009}
    70117010
  • trunk/src/wp-admin/themes.php

    r26708 r26725  
    290290
    291291                <# if ( data.tags ) { #>
    292                     <p class="theme-tags">
    293                         <span><?php _e( 'Tags:' ); ?></span>
    294                         {{{ data.tags.replace( /-/g, ' ' ) }}}
    295                     </p>
     292                    <p class="theme-tags"><span><?php _e( 'Tags:' ); ?></span> {{{ data.tags }}}</p>
    296293                <# } #>
    297294            </div>
  • trunk/src/wp-includes/class-wp-theme.php

    r26024 r26725  
    4545        'twentythirteen' => 'Twenty Thirteen',
    4646        'twentyfourteen' => 'Twenty Fourteen',
     47    );
     48
     49    /**
     50     * Renamed theme tags.
     51     */
     52    private static $tag_map = array(
     53        'fixed-width'    => 'fixed-layout',
     54        'flexible-width' => 'fluid-layout',
    4755    );
    4856
     
    707715
    708716                foreach ( $value as &$tag ) {
    709                     if ( isset( $tags_list[ $tag ] ) )
     717                    if ( isset( $tags_list[ $tag ] ) ) {
    710718                        $tag = $tags_list[ $tag ];
     719                    } elseif ( isset( self::$tag_map[ $tag ] ) ) {
     720                        $tag = $tags_list[ self::$tag_map[ $tag ] ];
     721                    }
    711722                }
    712723
Note: See TracChangeset for help on using the changeset viewer.