Ticket #25060: 25060.diff
File 25060.diff, 2.7 KB (added by , 6 years ago) |
---|
-
src/wp-admin/css/list-tables.css
213 213 border-top: 1px solid rgba(0, 0, 0, 0.03); 214 214 } 215 215 216 /* Green used in JS to indicate an event is successfully happening - important to override other specificity */ 217 .in-transition { 218 background-color: #ceb !important; 219 } 220 216 221 /* table vim shortcuts */ 217 222 .vim-current, 218 223 .vim-current th, -
src/wp-admin/js/edit-comments.js
83 83 84 84 a.click(function(){ 85 85 list.wpList.del(this); 86 $('#undo-' + id). css( {backgroundColor:'#ceb'}).fadeOut(350, function(){86 $('#undo-' + id).addClass('in-transition').fadeOut(350, function(){ 87 87 $(this).remove(); 88 $('#comment-' + id). css('backgroundColor', '').fadeIn(300, function(){ $(this).show(); });88 $('#comment-' + id).fadeIn(300, function(){ $(this).show(); }); 89 89 }); 90 90 return false; 91 91 }); … … 338 338 339 339 if ( this.cid && this.act == 'edit-comment' ) { 340 340 c = $('#comment-' + this.cid); 341 c.fadeIn(300, function(){ c.show(); }) .css('backgroundColor', '');341 c.fadeIn(300, function(){ c.show(); }); 342 342 } 343 343 344 344 // reset the Quicktags buttons … … 469 469 }, 470 470 471 471 show : function(xml) { 472 var t = this, r, c, id, bg,pid;472 var t = this, r, c, id, pid; 473 473 474 474 if ( typeof(xml) == 'string' ) { 475 475 t.error({'responseText': xml}); … … 495 495 updatePending( -1 ); 496 496 497 497 if ( this.comments_listing == 'moderated' ) { 498 pid.animate( { 'backgroundColor':'#CCEEBB' }, 400, function(){ 499 pid.fadeOut(); 500 }); 498 pid.addClass('in-transition', 400).fadeOut(); 501 499 return; 502 500 } 503 501 } … … 508 506 509 507 id = $(id); 510 508 t.addEvents(id); 511 bg = id.hasClass('unapproved') ? '#FFFFE0' : id.closest('.widefat, .postbox').css('backgroundColor');512 509 513 id.animate( { 'backgroundColor':'#CCEEBB' }, 300 ) 514 .animate( { 'backgroundColor': bg }, 300, function() { 515 if ( pid && pid.length ) { 516 pid.animate( { 'backgroundColor':'#CCEEBB' }, 300 ) 517 .animate( { 'backgroundColor': bg }, 300 ) 518 .removeClass('unapproved').addClass('approved') 519 .find('div.comment_status').html('1'); 520 } 521 }); 510 id.addClass('in-transition', 300).removeClass('in-transition', 300); 522 511 512 if ( pid && pid.length ) { 513 pid.addClass('in-transition', 300).removeClass('in-transition', 300).removeClass('unapproved').addClass('approved').find('div.comment_status').html('1'); 514 } 523 515 }, 524 516 525 517 error : function(r) {