Ticket #32395: 32395.diff
File 32395.diff, 6.5 KB (added by , 8 years ago) |
---|
-
src/wp-admin/css/forms.css
949 949 } 950 950 951 951 .widefat th input[type="checkbox"] { 952 margin-bottom: 2px; 953 } 954 955 .widefat thead input[type="checkbox"] { 952 956 margin-bottom: 8px; 953 957 } 954 958 -
src/wp-admin/css/list-tables.css
423 423 content: '\f140'; 424 424 } 425 425 426 .wp-list-table .toggle-row { 427 position: relative; 428 display: none; 429 margin-left: 8px; /* match the checkbox */ 430 padding: 0; 431 width: 25px; /* match the checkbox */ 432 height: 20px; 433 border: none; 434 background: transparent; 435 } 436 437 .wp-list-table .toggle-row:hover { 438 cursor: pointer; 439 } 440 441 .wp-list-table .toggle-row:focus { 442 color: #124964; 443 -webkit-box-shadow: 444 0 0 0 1px #5b9dd9, 445 0 0 2px 1px rgba(30, 140, 190, .8); 446 box-shadow: 447 0 0 0 1px #5b9dd9, 448 0 0 2px 1px rgba(30, 140, 190, .8); 449 } 450 451 .ie8 .wp-list-table .toggle-row:focus { 452 outline: #5b9dd9 solid 1px; 453 } 454 455 .wp-list-table .toggle-row:before { 456 position: absolute; 457 top: 0; 458 left: -3px; 459 display: block; 460 padding: 0; 461 color: #666; 462 content: '\f140'; 463 font: normal 30px/1 'dashicons'; 464 line-height: 10px; 465 -webkit-font-smoothing: antialiased; 466 -moz-osx-font-smoothing: grayscale; 467 speak: none; 468 } 469 470 .wp-list-table .is-expanded .toggle-row:before { 471 content: '\f142'; 472 } 473 426 474 tr.wp-locked .locked-indicator { 427 475 margin-left: 6px; 428 476 height: 20px; … … 1635 1683 font-size: 14px; 1636 1684 } 1637 1685 1638 /* Columns to hide */ 1639 .fixed .column-date, 1640 .fixed .column-author, 1641 .column-categories, 1642 .column-tags, 1643 .tags .column-description, 1644 .media .column-parent, 1645 .media .column-comments, 1646 .users .column-email, 1647 .users .column-name, 1648 .sites .column-registered, 1649 .sites .column-users { 1686 .wp-list-table th:not(.column-primary), 1687 .wp-list-table th:not(.column-primary), 1688 .wp-list-table td:not(.column-primary) { 1650 1689 display: none; 1651 1690 } 1652 1691 1653 .fixed .column-comment .comment-author { 1692 /* Checkboxes need to show */ 1693 .wp-list-table th.check-column { 1694 display: table-cell; 1695 width: 35px; 1696 } 1697 1698 .wp-list-table .toggle-row { 1654 1699 display: block; 1655 1700 } 1656 1701 1657 /* Posts */ 1658 .column-title { 1659 width: 85%; 1702 .wp-list-table td { 1703 position: relative; 1704 clear: both; 1705 display: block; 1706 width: auto !important; /* needs to override some columns that are more specifically targeted */ 1660 1707 } 1661 1708 1662 . fixed .column-comments, .widefat .check-column{1663 width: 35px1709 .wp-list-table td:not(.column-primary) { 1710 padding: 3px 8px 3px 35% !important; /* space for the label */ 1664 1711 } 1665 1712 1713 .wp-list-table td:not(.column-primary)::before { 1714 position: absolute; 1715 left: 10px; /* match padding of regular table cell */ 1716 display: block; 1717 overflow: hidden; 1718 width: 32%; /* leave a little space for a gutter */ 1719 content: attr(data-colname); 1720 white-space: nowrap; 1721 text-overflow: ellipsis; 1722 } 1723 1724 .wp-list-table .is-expanded td { 1725 display: block; 1726 } 1727 1728 .fixed .column-comment .comment-author { 1729 display: block; 1730 } 1731 1666 1732 .widefat thead .check-column, .widefat tfoot .check-column { 1667 1733 padding: 10px 0 10px; 1668 1734 } … … 1898 1964 } 1899 1965 1900 1966 .widefat tbody th.check-column input[type="checkbox"] { 1901 margin-top: - 3px;1967 margin-top: -4px; 1902 1968 margin-left: 8px; 1903 1969 } 1904 1970 -
src/wp-admin/includes/class-wp-list-table.php
912 912 * @param bool $with_id Whether to set the id attribute or not 913 913 */ 914 914 public function print_column_headers( $with_id = true ) { 915 list( $columns, $hidden, $sortable ) = $this->get_column_info();915 list( $columns, $hidden, $sortable, $primary ) = $this->get_column_info(); 916 916 917 917 $current_url = set_url_scheme( 'http://' . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI'] ); 918 918 $current_url = remove_query_arg( 'paged', $current_url ); … … 948 948 elseif ( in_array( $column_key, array( 'posts', 'comments', 'links' ) ) ) 949 949 $class[] = 'num'; 950 950 951 if ( $column_key === $primary ) { 952 $class[] = 'column-primary'; 953 } 954 951 955 if ( isset( $sortable[$column_key] ) ) { 952 956 list( $orderby, $desc_first ) = $sortable[$column_key]; 953 957 -
src/wp-admin/includes/class-wp-posts-list-table.php
723 723 $style = ' style="display:none;"'; 724 724 } 725 725 726 $attributes = "class='$classes'$style"; 726 // Comments is a special case, as its column display name contains HTML 727 if ( 'comments' === $column_name ) { 728 $data = ' data-colname="' . esc_attr__( 'Comments asadfkj this is a longer string' ) . '"'; 729 } else { 730 $data = ' data-colname="' . esc_attr( $column_display_name ) . '"'; 731 } 727 732 733 $attributes = "class='$classes'$style$data"; 734 728 735 switch ( $column_name ) { 729 736 730 737 case 'cb': … … 737 744 <label class="screen-reader-text" for="cb-select-<?php the_ID(); ?>"><?php printf( __( 'Select %s' ), $title ); ?></label> 738 745 <input id="cb-select-<?php the_ID(); ?>" type="checkbox" name="post[]" value="<?php the_ID(); ?>" /> 739 746 <div class="locked-indicator"></div> 747 <button type="button" class="toggle-row"><span class="screen-reader-text">Show more details</span></button> 740 748 <?php 741 749 } 742 750 ?> … … 746 754 747 755 case 'title': 748 756 $classes .= ' page-title'; // Special addition for title column 749 $attributes = "class='$classes'$style ";757 $attributes = "class='$classes'$style$data"; 750 758 if ( $this->hierarchical_display ) { 751 759 if ( 0 == $level && (int) $post->post_parent > 0 ) { 752 760 // Sent level 0 by accident, by default, or because we don't know the actual level. -
src/wp-admin/js/common.js
480 480 } 481 481 }, 'td.has-row-actions' ); 482 482 483 // Toggle list table rows on small screens 484 $( 'tbody' ).on( 'click', '.toggle-row', function() { 485 $( this ).closest( 'tr' ).toggleClass( 'is-expanded' ); 486 }); 487 483 488 $('#default-password-nag-no').click( function() { 484 489 setUserSetting('default_password_nag', 'hide'); 485 490 $('div.default-password-nag').hide();