Ticket #32152: 32152.diff
| File 32152.diff, 4.3 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;45 }46 46 47 .post-com-count:hover span { 48 background-color: #00a0d2; 47 .has-pending .post-com-count .comment-count-pending { 48 display: block; 49 background: #d54e21; 50 font-size: 9px; 51 font-weight: 600; 52 /* the following are calculated on the font size 53 and need 8 decimals to avoid different roundings in different browsers */ 54 height: 1.75454545em; 55 line-height: 1.76363636; 56 min-width: 0.2727272em; 57 padding: 0 5px; 58 -webkit-border-radius: 10px; 59 border-radius: 10px; 60 color: #fff; 61 overflow: hidden; 62 position: absolute; 63 top: -4px; 64 left: 85%; 65 border: 2px solid #fff; 49 66 } 50 67 51 .post-com-count:hover:after {52 border-top: 5px solid #00a0d2;53 }54 68 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 69 .column-response .post-com-count { 68 70 float: left; 69 71 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 ); 629 } else { 630 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>', 631 esc_url( add_query_arg( 'p', $post_id, admin_url( 'edit-comments.php' ) ) ), 632 esc_attr( $count_phrase ), 633 $approved_comments_number, 634 $pending_comments_number 635 ); 636 } 621 637 622 if ( $pending_comments ) 638 if ( $pending_comments ) { 623 639 echo '</strong>'; 640 } 624 641 } 625 642 626 643 /**