Ticket #33149: 33149.2.diff
File 33149.2.diff, 4.2 KB (added by , 10 years ago) |
---|
-
src/wp-admin/css/list-tables.css
1 .response-links {2 display: block;3 margin-bottom: 1em;4 }5 6 .response-links a {7 display: block;8 }9 10 .response-links a.comments-edit-item-link {11 font-weight: 600;12 }13 14 .response-links a.comments-view-item-link {15 font-size: 12px;16 }17 18 .column-response .post-com-count .screen-reader-text {19 position: static;20 width: auto;21 height: auto;22 margin: 0;23 }24 25 .column-response .post-com-count [aria-hidden="true"] {26 display: none;27 }28 29 1 .post-com-count-wrapper strong { 30 2 font-weight: 400; 31 3 } 32 4 33 .column-response .post-com-count.post-com-count-pending {34 color: #bb2a2a;35 }36 37 5 .comments-view-item-link { 38 6 display: inline-block; 39 7 clear: both; … … 50 18 vertical-align: top; 51 19 } 52 20 53 .column-response .post-com-count {54 display: block;55 }56 57 21 /* comments bubble approved */ 58 22 .column-comments .post-com-count-no-comments, 59 23 .column-comments .post-com-count-approved { … … 255 219 border-top: 1px solid rgba(0, 0, 0, 0.03); 256 220 } 257 221 222 .wp-list-table.comments .column-response .row-actions a { 223 white-space: nowrap; 224 } 225 258 226 /* table vim shortcuts */ 259 227 .vim-current, 260 228 .vim-current th, … … 313 281 display: none; 314 282 } 315 283 316 .fixed .column-response,317 284 .fixed .column-categories, 318 285 .fixed .column-tags, 319 286 .fixed .column-rel, … … 321 288 width: 15%; 322 289 } 323 290 291 .fixed .column-response, 324 292 .fixed .column-slug { 325 293 width: 25%; 326 294 } … … 1841 1809 box-shadow: none; 1842 1810 } 1843 1811 1844 #the-comment-list .is-expanded td:last-child{1812 #the-comment-list .is-expanded .column-response { 1845 1813 -webkit-box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.1); 1846 1814 box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.1); 1815 padding: 8px 10px; 1816 } 1817 1818 #the-comment-list .is-expanded .column-response::before { 1819 left: auto; 1820 overflow: auto; 1821 position: relative; 1822 width: auto; 1847 1823 } 1848 1824 1849 1825 /* Show comment bubble as text instead */ -
src/wp-admin/includes/class-wp-comments-list-table.php
670 670 * @access public 671 671 */ 672 672 public function column_response() { 673 $post = get_post(); 674 675 if ( isset( $this->pending_count[$post->ID] ) ) { 676 $pending_comments = $this->pending_count[$post->ID]; 677 } else { 678 $_pending_count_temp = get_pending_comments_num( array( $post->ID ) ); 679 $pending_comments = $this->pending_count[$post->ID] = $_pending_count_temp[$post->ID]; 680 } 673 $post = get_post(); 674 $post_link = '<strong>' . esc_html( get_the_title( $post->ID ) ) . '</strong>'; 681 675 682 676 if ( current_user_can( 'edit_post', $post->ID ) ) { 683 $post_link = "<a href='" . get_edit_post_link( $post->ID ) . "' class='comments-edit-item-link'>"; 684 $post_link .= esc_html( get_the_title( $post->ID ) ) . '</a>'; 685 } else { 686 $post_link = esc_html( get_the_title( $post->ID ) ); 677 $post_link = '<a href="' . get_edit_post_link( $post->ID ) . '" class="comments-edit-item-link">' . $post_link . '</a>'; 687 678 } 688 679 689 echo '<div class="response-links">'; 680 $action_links = array( 681 sprintf( '<a href="%1$s">%2$s</a>', esc_url( get_permalink( $post->ID ) ), get_post_type_object( $post->post_type )->labels->view_item ), 682 sprintf( '<a href="%1$s">%2$s</a>', esc_url( add_query_arg( 'p', $post->ID, admin_url( 'edit-comments.php' ) ) ), __( 'Manage Comments' ) ), 683 ); 684 690 685 echo $post_link; 691 $post_type_object = get_post_type_object( $post->post_type ); 692 echo "<a href='" . get_permalink( $post->ID ) . "' class='comments-view-item-link'>" . $post_type_object->labels->view_item . '</a>'; 686 687 echo '<div class="row-actions">'; 688 echo implode( ' | ', $action_links ); 689 echo '</div>'; 690 693 691 if ( 'attachment' == $post->post_type && ( $thumb = wp_get_attachment_image( $post->ID, array( 80, 60 ), true ) ) ) { 694 692 echo $thumb; 695 693 } 696 echo '</div>';697 echo '<span class="post-com-count-wrapper">';698 $this->comments_bubble( $post->ID, $pending_comments );699 echo '</span> ';700 694 } 701 695 702 696 /**