Ticket #23903: 23903.patch
File 23903.patch, 2.6 KB (added by , 12 years ago) |
---|
-
css/wp-admin.css
3621 3621 z-index: 1; 3622 3622 margin-top: 20px; 3623 3623 } 3624 #revisions-diff div label.diff-label { 3625 font-weight: bold; 3626 display: block; 3627 margin-top: 5px; 3628 padding-left: 3px; 3629 font-size: 14px; 3630 } 3624 3631 3625 3632 .diff-header { 3626 3633 height: 35px; -
js/revisions.js
593 593 render: function() { 594 594 var addHtml = ''; 595 595 var thediff; 596 596 597 597 // compare two revisions mode? 598 598 if ( ! Diff.singleRevision ) { 599 599 if ( this.draggingLeft ) { … … 634 634 635 635 // hide the restore button when on the last sport/current post data 636 636 $( '#restore-revision' ).toggle( ! Diff.revisions.at( Diff.rightDiff - 1 ).get( 'is_current_revision' ) ); 637 637 if ( $( '#compare-two-revisions' ).is( ':checked' ) ) { 638 jQuery("#diff-title-to strong:first-child").show() 639 }else{ 640 jQuery("#diff-title-to strong:first-child").html(" ") 641 } 638 642 return this; 639 643 }, 640 644 … … 651 655 if ( $( '#compare-two-revisions' ).is( ':checked' ) ) { // compare 2 mode 652 656 Diff.singleRevision = false ; 653 657 654 658 if ( 1 === Diff.rightDiff ) 655 659 Diff.rightDiff = 2; 656 660 657 661 Diff.revisionView.draggingLeft = false; … … 661 665 Diff.revisionView.model = Diff.rightHandleRevisions; 662 666 663 667 } else { // compare one mode 664 668 Diff.singleRevision = true; 665 669 Diff.revisionView.draggingLeft = false; 666 670 Diff.reloadModelSingle(); 667 671 } -
includes/ajax-actions.php
2152 2152 // compare_to == 0 means first revision, so compare to a blank field to show whats changed 2153 2153 $diff = wp_text_diff_with_count( ( 0 == $compare_to ) ? '' : $left_content, $right_content, $args ); 2154 2154 2155 if ( isset( $diff[ 'html' ] ) ) 2155 if ( isset( $diff[ 'html' ] ) ){ 2156 $content.= "<label class='diff-label'>" . __(ucfirst(str_replace("post_","",$field)) ." : ") ."</label>"; 2156 2157 $content .= $diff[ 'html' ]; 2158 } 2157 2159 2158 2160 if ( isset( $diff[ 'lines_added' ] ) ) 2159 2161 $lines_added = $lines_added + $diff[ 'lines_added' ];