Ticket #31006: 31006.diff
File 31006.diff, 5.1 KB (added by , 10 years ago) |
---|
-
src/wp-admin/css/common.css
637 637 border-right-color: #99d; 638 638 } 639 639 640 /* Action colors for wp-lists */ 641 .wp-core-ui #wpwrap .is-working { 642 background-color: #ceb; 643 } 644 645 .wp-core-ui #wpwrap .is-deleted, 646 .wp-core-ui #wpwrap .is-unsuccessful { 647 background-color: #faa; 648 } 649 640 650 .media-upload-form label.form-help, 641 651 td.help { 642 652 color: #9a9a9a; -
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('is-working').fadeOut(350, function(){ 87 87 $(this).remove(); 88 $('#comment-' + id). css('backgroundColor', '').fadeIn(300, function(){ $(this).show(); });88 $('#comment-' + id).removeClass('is-deleted').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('is-working').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');509 t.addEvents(id); 512 510 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 }); 511 id.addClass('is-working', 300).removeClass('is-working', 300); 522 512 513 if ( pid && pid.length ) { 514 pid.addClass('is-working').switchClass('unapproved', 'approved').removeClass('is-working', 400).find('div.comment_status').html('1'); 515 } 523 516 }, 524 517 525 518 error : function(r) { -
src/wp-includes/js/wp-lists.js
9 9 10 10 what: '', 11 11 alt: 'alternate', altOffset: 0, 12 addColor: null, delColor: null, dimAddColor: null, dimDelColor: null, 12 addColor: null, delColor: null, dimAddColor: null, dimDelColor: null, // Deprecated in favor of classes 13 13 14 14 confirm: null, 15 15 addBefore: null, addAfter: null, … … 154 154 155 155 s.element = data[2] || s.element || null; 156 156 157 if ( data[3] )158 s.delColor = '#' + data[3];159 else160 s.delColor = s.delColor || '#faa';161 162 157 if ( !s || !s.element ) 163 158 return false; 164 159 … … 182 177 183 178 element = $('#' + s.element); 184 179 185 if ( 'none' != s.delColor ) { 186 element.css( 'backgroundColor', s.delColor ).fadeOut( 350, function(){ 187 list.wpList.recolor(); 188 $(list).trigger( 'wpListDelEnd', [ s, list.wpList ] ); 189 }); 190 } else { 180 element.addClass('is-deleted').fadeOut( 350, function(){ 191 181 list.wpList.recolor(); 192 182 $(list).trigger( 'wpListDelEnd', [ s, list.wpList ] ); 193 } 183 }); 194 184 195 185 s.success = function(r) { 196 186 res = wpAjax.parseAjaxResponse(r, s.response, s.element); 197 187 rres = r; 198 188 199 189 if ( !res || res.errors ) { 200 element.stop().stop(). css( 'backgroundColor', '#faa').show().queue( function() { list.wpList.recolor(); $(this).dequeue(); } );190 element.stop().stop().addClass('is-unsuccessful').show().queue( function() { list.wpList.recolor(); $(this).dequeue(); } ); 201 191 return false; 202 192 } 203 193 }; -
src/wp-includes/script-loader.php
144 144 'interval' => apply_filters( 'wp_auth_check_interval', 3 * MINUTE_IN_SECONDS ), 145 145 ) ); 146 146 147 $scripts->add( 'wp-lists', "/wp-includes/js/wp-lists$suffix.js", array( 'wp-ajax-response', 'jquery- color' ), false, 1 );147 $scripts->add( 'wp-lists', "/wp-includes/js/wp-lists$suffix.js", array( 'wp-ajax-response', 'jquery-ui-core', 'jquery-effects-core' ), false, 1 ); 148 148 149 149 // WordPress no longer uses or bundles Prototype or script.aculo.us. These are now pulled from an external source. 150 150 $scripts->add( 'prototype', '//ajax.googleapis.com/ajax/libs/prototype/1.7.1.0/prototype.js', array(), '1.7.1');