WordPress.org

Make WordPress Core

Ticket #17958: add thumbnail to admin posts - spacing fix.diff

File add thumbnail to admin posts - spacing fix.diff, 2.6 KB (added by christopherross, 4 years ago)

minor spacing fix around the sizing array

  • css/widgets.dev.css

     
    380380        cursor: default; 
    381381} 
    382382 
     383.column-title-thumb {  
     384        float:left; 
     385        margin-right: 5px;  
     386} 
     387 No newline at end of file 
  • includes/class-wp-posts-list-table.php

     
    524524 
    525525                                        $pad = str_repeat( '— ', $level ); 
    526526?> 
    527                         <td <?php echo $attributes ?>><strong><?php if ( $can_edit_post && $post->post_status != 'trash' ) { ?><a class="row-title" href="<?php echo $edit_link; ?>" title="<?php echo esc_attr( sprintf( __( 'Edit &#8220;%s&#8221;' ), $title ) ); ?>"><?php echo $pad; echo $title ?></a><?php } else { echo $pad; echo $title; }; _post_states( $post ); echo isset( $parent_name ) ? ' | ' . $post_type_object->labels->parent_item_colon . ' ' . esc_html( $parent_name ) : ''; ?></strong> 
     527                        <td <?php echo $attributes ?>><?php if ( has_post_thumbnail() ) { echo "<div class='column-title-thumb'>"; the_post_thumbnail( array( 32,32 ) ); echo "</div>"; } ?><strong><?php if ( $can_edit_post && $post->post_status != 'trash' ) { ?><a class="row-title" href="<?php echo $edit_link; ?>" title="<?php echo esc_attr( sprintf( __( 'Edit &#8220;%s&#8221;' ), $title ) ); ?>"><?php echo $pad; echo $title ?></a><?php } else { echo $pad; echo $title; }; _post_states( $post ); echo isset( $parent_name ) ? ' | ' . $post_type_object->labels->parent_item_colon . ' ' . esc_html( $parent_name ) : ''; ?></strong> 
    528528<?php 
    529529                                } 
    530530                                else { 
    531531                                        $attributes = 'class="post-title page-title column-title"' . $style; 
    532532?> 
    533                         <td <?php echo $attributes ?>><strong><?php if ( $can_edit_post && $post->post_status != 'trash' ) { ?><a class="row-title" href="<?php echo $edit_link; ?>" title="<?php echo esc_attr( sprintf( __( 'Edit &#8220;%s&#8221;' ), $title ) ); ?>"><?php echo $title ?></a><?php } else { echo $title; }; _post_states( $post ); ?></strong> 
     533                        <td <?php echo $attributes ?>><?php if ( has_post_thumbnail() ) { echo "<div class='column-title-thumb'>"; the_post_thumbnail( array( 32,32 ) ); echo "</div>"; } ?><strong><?php if ( $can_edit_post && $post->post_status != 'trash' ) { ?><a class="row-title" href="<?php echo $edit_link; ?>" title="<?php echo esc_attr( sprintf( __( 'Edit &#8220;%s&#8221;' ), $title ) ); ?>"><?php echo $title ?></a><?php } else { echo $title; }; _post_states( $post ); ?></strong> 
    534534<?php 
    535535                                        if ( 'excerpt' == $mode ) { 
    536536                                                the_excerpt();