Force-wrap comments in Recent Comments on the dashboard, expand width when no avatar, fixes #9283

git-svn-id: http://svn.automattic.com/wordpress/trunk@10729 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
azaozz 2009-03-06 03:20:38 +00:00
parent 5ebd95e257
commit 6405b50953
3 changed files with 13 additions and 4 deletions

View File

@ -210,7 +210,7 @@ div.postbox div.inside {
} }
#the-comment-list .comment-item { #the-comment-list .comment-item {
padding: 1em 10px 1em 70px; padding: 1em 10px;
border-top: 1px solid; border-top: 1px solid;
} }
@ -229,7 +229,7 @@ div.postbox div.inside {
#the-comment-list .comment-item .avatar { #the-comment-list .comment-item .avatar {
float: left; float: left;
margin-left: -60px; margin: 0 10px 5px 0;
} }
#the-comment-list .comment-item h4 { #the-comment-list .comment-item h4 {
@ -394,3 +394,9 @@ a.rsswidget {
margin: 0 0 1.4em; margin: 0 0 1.4em;
line-height: 1.4em; line-height: 1.4em;
} }
.dashboard-comment-wrap {
overflow: hidden;
word-wrap: break-word;
}

View File

@ -550,6 +550,8 @@ function _wp_dashboard_recent_comments_row( &$comment, $show_date = true ) {
<?php if ( !$comment->comment_type || 'comment' == $comment->comment_type ) : ?> <?php if ( !$comment->comment_type || 'comment' == $comment->comment_type ) : ?>
<?php echo get_avatar( $comment, 50 ); ?> <?php echo get_avatar( $comment, 50 ); ?>
<div class="dashboard-comment-wrap">
<h4 class="comment-meta"><?php printf( __( 'From %1$s on %2$s%3$s' ), '<cite class="comment-author">' . get_comment_author_link() . '</cite>', $comment_post_link." ".$comment_link, ' <span class="approve">' . __( '[Pending]' ) . '</span>' ); ?></h4> <h4 class="comment-meta"><?php printf( __( 'From %1$s on %2$s%3$s' ), '<cite class="comment-author">' . get_comment_author_link() . '</cite>', $comment_post_link." ".$comment_link, ' <span class="approve">' . __( '[Pending]' ) . '</span>' ); ?></h4>
<?php <?php
@ -566,6 +568,7 @@ function _wp_dashboard_recent_comments_row( &$comment, $show_date = true ) {
endswitch; endswitch;
$type = wp_specialchars( $type ); $type = wp_specialchars( $type );
?> ?>
<div class="dashboard-comment-wrap">
<?php /* translators: %1$s is type of comment, %2$s is link to the post */ ?> <?php /* translators: %1$s is type of comment, %2$s is link to the post */ ?>
<h4 class="comment-meta"><?php printf( _x( '%1$s on %2$s', 'dashboard' ), "<strong>$type</strong>", $comment_post_link ); ?></h4> <h4 class="comment-meta"><?php printf( _x( '%1$s on %2$s', 'dashboard' ), "<strong>$type</strong>", $comment_post_link ); ?></h4>
<p class="comment-author"><?php comment_author_link(); ?></p> <p class="comment-author"><?php comment_author_link(); ?></p>
@ -581,7 +584,7 @@ function _wp_dashboard_recent_comments_row( &$comment, $show_date = true ) {
<div class="author-url"><?php echo attribute_escape( $comment->comment_author_url ); ?></div> <div class="author-url"><?php echo attribute_escape( $comment->comment_author_url ); ?></div>
<div class="comment_status"><?php echo $comment->comment_approved; ?></div> <div class="comment_status"><?php echo $comment->comment_approved; ?></div>
</div> </div>
</div>
</div> </div>
<?php <?php
} }

View File

@ -438,7 +438,7 @@ function wp_default_styles( &$styles ) {
$styles->add( 'global', '/wp-admin/css/global.css', array(), '20081226' ); $styles->add( 'global', '/wp-admin/css/global.css', array(), '20081226' );
$styles->add( 'media', '/wp-admin/css/media.css', array(), '20081210' ); $styles->add( 'media', '/wp-admin/css/media.css', array(), '20081210' );
$styles->add( 'widgets', '/wp-admin/css/widgets.css', array(), '20081210' ); $styles->add( 'widgets', '/wp-admin/css/widgets.css', array(), '20081210' );
$styles->add( 'dashboard', '/wp-admin/css/dashboard.css', array(), '20081210' ); $styles->add( 'dashboard', '/wp-admin/css/dashboard.css', array(), '20090305' );
$styles->add( 'install', '/wp-admin/css/install.css', array(), '20081210' ); $styles->add( 'install', '/wp-admin/css/install.css', array(), '20081210' );
$styles->add( 'theme-editor', '/wp-admin/css/theme-editor.css', array(), '20081210' ); $styles->add( 'theme-editor', '/wp-admin/css/theme-editor.css', array(), '20081210' );
$styles->add( 'press-this', '/wp-admin/css/press-this.css', array(), '20081210' ); $styles->add( 'press-this', '/wp-admin/css/press-this.css', array(), '20081210' );