WordPress.org

Make WordPress Core

Changeset 19840


Ignore:
Timestamp:
02/06/12 20:54:01 (2 years ago)
Author:
ryan
Message:

Hide theme details by default. Props helenyhou, DH-Shredder. fixes #19853

Location:
trunk/wp-admin
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/includes/class-wp-themes-list-table.php

    r19811 r19840  
    163163    /* translators: 1: theme title, 2: theme version, 3: theme author */ 
    164164    printf( __( '%1$s %2$s by %3$s' ), $title, $version, $author ) ; ?></h3> 
    165 <p class="description"><?php echo $description; ?></p> 
     165 
    166166<span class='action-links'><?php echo $actions ?></span> 
     167<span class="separator hide-if-no-js">| </span><a href="#" class="theme-detail hide-if-no-js" tabindex='4'><?php _e('Details') ?></a> 
     168<div class="themedetaildiv hide-if-js"> 
     169<p><?php echo $description; ?></p> 
    167170    <?php if ( current_user_can( 'edit_themes' ) && $parent_theme ) { 
    168171    /* translators: 1: theme title, 2:  template dir, 3: stylesheet_dir, 4: theme title, 5: parent_theme */ ?> 
     
    174177<p><?php _e( 'Tags:' ); ?> <?php echo join( ', ', $tags ); ?></p> 
    175178<?php endif; ?> 
    176         <?php theme_update_available( $themes[$theme_name] ); ?> 
    177179<?php endif; // end if not empty theme_name ?> 
     180</div> 
     181    <?php theme_update_available( $themes[$theme_name] ); ?> 
    178182    </div> 
    179183<?php } // end foreach $theme_names 
  • trunk/wp-admin/includes/theme-install.php

    r19712 r19840  
    133133 
    134134    $name = wp_kses($theme->name, $themes_allowedtags); 
     135    $author = wp_kses($theme->author, $themes_allowedtags); 
    135136    $desc = wp_kses($theme->description, $themes_allowedtags); 
    136137    //if ( strlen($desc) > 30 ) 
     
    154155<img src='<?php echo esc_url($theme->screenshot_url); ?>' width='150' /> 
    155156</a> 
    156 <h3><?php echo $name ?></h3> 
     157<h3><?php 
     158    /* translators: 1: theme name, 2: author name */ 
     159    printf( __( '%1$s <span>by %2$s</span>' ), $name, $author ); ?></h3> 
    157160<span class='action-links'><?php echo $actions ?></span> 
     161<?php if ( $show_details ) { ?> 
     162<span class="separator hide-if-no-js">| </span><a href="#theme_detail" class="theme-detail hide-if-no-js" tabindex='4'><?php _e('Details') ?></a> 
     163<div class="themedetaildiv hide-if-js"> 
    158164<p><?php echo $desc ?></p> 
    159 <?php if ( $show_details ) { ?> 
    160 <a href="#theme_detail" class="theme-detail hide-if-no-js" tabindex='4'><?php _e('Details') ?></a> 
    161 <div class="themedetaildiv hide-if-js"> 
    162165<p><strong><?php _e('Version:') ?></strong> <?php echo wp_kses($theme->version, $themes_allowedtags) ?></p> 
    163 <p><strong><?php _e('Author:') ?></strong> <?php echo wp_kses($theme->author, $themes_allowedtags) ?></p> 
    164166<?php if ( ! empty($theme->last_updated) ) : ?> 
    165167<p><strong><?php _e('Last Updated:') ?></strong> <span title="<?php echo $theme->last_updated ?>"><?php printf( __('%s ago'), human_time_diff(strtotime($theme->last_updated)) ) ?></span></p> 
  • trunk/wp-admin/js/theme-preview.dev.js

    r19712 r19840  
    5656 
    5757    // Theme details 
    58     $('.theme-detail').click(function () { 
     58    $('#availablethemes').on('click', 'a.theme-detail', function (event) { 
    5959        $(this).siblings('.themedetaildiv').toggle(); 
    6060        return false; 
Note: See TracChangeset for help on using the changeset viewer.