From 5b676b4f8e94fc95731bcbd295ca3803ddfa35d9 Mon Sep 17 00:00:00 2001 From: Aaron Jorbin Date: Wed, 1 Apr 2015 21:30:50 +0000 Subject: [PATCH] Fix colors for activated and updated plugins If we don't have the updated class on the TR for he update message, then the message is red and red is scary and they just updated, they should be happy and celebrating, not scared. See #31608 git-svn-id: https://develop.svn.wordpress.org/trunk@31969 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/js/updates.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/wp-admin/js/updates.js b/src/wp-admin/js/updates.js index 08b43c2c3c..1540193967 100644 --- a/src/wp-admin/js/updates.js +++ b/src/wp-admin/js/updates.js @@ -207,6 +207,9 @@ window.wp = window.wp || {}; // Update the version number in the row. var newText = $pluginRow.find('.plugin-version-author-uri').html().replace( response.oldVersion, response.newVersion ); $pluginRow.find('.plugin-version-author-uri').html( newText ); + + // Add updated class to update message parent tr + $pluginRow.next().addClass( 'updated' ); } else if ( 'plugin-install' === pagenow ) { $updateMessage = $( '.plugin-card-' + response.slug ).find( '.update-now' ); $updateMessage.addClass( 'button-disabled' ); @@ -228,6 +231,7 @@ window.wp = window.wp || {}; wp.updates.queueChecker(); }; + /** * On a plugin update error, update the UI appropriately. *