Ticket #32152: 32152.2.diff
| File 32152.2.diff, 4.6 KB (added by , 11 years ago) |
|---|
-
wp-admin/css/list-tables.css
4 4 } 5 5 6 6 .post-com-count { 7 float: left; 7 8 background: none; 8 9 height: 1.3em; 9 10 line-height: 1.1em; 10 display: block;11 11 text-decoration: none; 12 12 padding: 0 0 6px; 13 cursor: pointer;14 background-position: center -80px;15 background-repeat: no-repeat;16 13 color: #fff; 14 text-align: center; 15 position: relative; 16 margin-top: 5px; 17 17 } 18 18 19 .post-com-count:after { /* draw bubble connector using CSS! */19 .post-com-count:after { 20 20 content: ""; 21 21 display: block; 22 22 width: 0; 23 23 height: 0; 24 24 margin-left: 8px; 25 border-top: 5px solid # b4b9be;25 border-top: 5px solid #767676; 26 26 border-right: 5px solid transparent; 27 27 } 28 28 29 .post-com-count span{29 .post-com-count .comment-count { 30 30 font-size: 11px; 31 31 font-weight: 600; 32 height: 1.4em; 33 line-height: 1.4em; 34 min-width: 0.7em; 35 padding: 0 6px; 36 display: inline-block; 32 /* the following are calculated on the font size 33 and need 8 decimals to avoid different roundings in different browsers */ 34 height: 1.95454545em; 35 line-height: 1.96363636; 36 min-width: 0.72727272em; 37 padding: 0 8px; 38 display: block; 37 39 -webkit-border-radius: 5px; 38 40 border-radius: 5px; 39 background-color: # b4b9be;41 background-color: #767676; 40 42 color: #fff; 43 overflow: hidden; 41 44 } 42 45 43 .post-com-count :hover{44 background-position: center -3px;46 .post-com-count .comment-count-pending { 47 display: none; 45 48 } 46 49 47 .post-com-count:hover span { 48 background-color: #00a0d2; 50 .has-pending .post-com-count .comment-count-pending { 51 display: block; 52 background: #d54e21; 53 font-size: 9px; 54 font-weight: 600; 55 /* the following are calculated on the font size 56 and need 8 decimals to avoid different roundings in different browsers */ 57 height: 1.75454545em; 58 line-height: 1.76363636; 59 min-width: 0.2727272em; 60 padding: 0 5px; 61 -webkit-border-radius: 10px; 62 border-radius: 10px; 63 color: #fff; 64 overflow: hidden; 65 position: absolute; 66 top: -4px; 67 left: 85%; 68 border: 2px solid #fff; 49 69 } 50 70 51 .post-com-count:hover:after {52 border-top: 5px solid #00a0d2;53 }54 71 55 strong .post-com-count {56 background-position: center -55px;57 }58 59 strong .post-com-count span {60 background-color: #0073aa;61 }62 63 strong .post-com-count:after {64 border-top: 5px solid #0073aa;65 }66 67 72 .column-response .post-com-count { 68 73 float: left; 69 74 margin-right: 5px; -
wp-admin/includes/class-wp-list-table.php
612 612 * @param int $pending_comments Number of pending comments. 613 613 */ 614 614 protected function comments_bubble( $post_id, $pending_comments ) { 615 $pending_phrase = sprintf( __( '%s pending' ), number_format( $pending_comments ) ); 615 $approved_comments_number = number_format_i18n( get_comments_number() ); 616 $pending_comments_number = number_format( $pending_comments ); 617 $count_phrase = sprintf( __( '%s approved and %s pending comments' ), $approved_comments_number, $pending_comments_number ); 616 618 617 if ( $pending_comments ) 618 echo '<strong>'; 619 if ( $pending_comments ) { 620 echo '<strong class="has-pending">'; 621 } 619 622 620 echo "<a href='" . esc_url( add_query_arg( 'p', $post_id, admin_url( 'edit-comments.php' ) ) ) . "' title='" . esc_attr( $pending_phrase ) . "' class='post-com-count'><span class='comment-count'>" . number_format_i18n( get_comments_number() ) . "</span></a>"; 623 // don't output a link if no comments 624 if ( ! $approved_comments_number && ! $pending_comments_number ) { 625 printf( '<span class="post-com-count"><span class="comment-count comment-count-no-comments" aria-hidden="true">%s</span><span class="screen-reader-text">%s</span></span>', 626 $approved_comments_number, 627 $count_phrase 628 ); 621 629 622 if ( $pending_comments ) 630 } elseif ( $pending_comments ) { 631 printf( '<a href="%s" aria-label="%s" class="post-com-count"><span class="comment-count">%s</span><span class="comment-count-pending">%s</span></a>', 632 esc_url( add_query_arg( 'p', $post_id, admin_url( 'edit-comments.php' ) ) ), 633 esc_attr( $count_phrase ), 634 $approved_comments_number, 635 $pending_comments_number 636 ); 637 } else { 638 printf( '<a href="%s" aria-label="%s" class="post-com-count"><span class="comment-count">%s</span></a>', 639 esc_url( add_query_arg( 'p', $post_id, admin_url( 'edit-comments.php' ) ) ), 640 esc_attr( $count_phrase ), 641 $approved_comments_number, 642 $pending_comments_number 643 ); 644 } 645 646 if ( $pending_comments ) { 623 647 echo '</strong>'; 648 } 624 649 } 625 650 626 651 /**