]> scripts.mit.edu Git - autoinstalls/wordpress.git/blobdiff - wp-includes/js/autosave.js
WordPress 4.1
[autoinstalls/wordpress.git] / wp-includes / js / autosave.js
index b338e949828f1ff2651fd471fcc4425a95e3d2a7..4e6834a15d3e1c0a4157c51e2c408cada6f48051 100644 (file)
@@ -345,7 +345,7 @@ window.autosave = function() {
                                };
 
                                $notice = $( '#local-storage-notice' );
-                               $('.wrap h2').first().after( $notice.addClass( 'updated' ).show() );
+                               $('.wrap h2').first().after( $notice.addClass( 'notice-warning' ).show() );
 
                                $notice.on( 'click.autosave-local', function( event ) {
                                        var $target = $( event.target );
@@ -354,10 +354,12 @@ window.autosave = function() {
                                                restorePost( restorePostData );
                                                $target.parent().hide();
                                                $(this).find( 'p.undo-restore' ).show();
+                                               $notice.removeClass( 'notice-warning' ).addClass( 'notice-success' );
                                        } else if ( $target.hasClass( 'undo-restore-backup' ) ) {
                                                restorePost( undoPostData );
                                                $target.parent().hide();
                                                $(this).find( 'p.local-restore' ).show();
+                                               $notice.removeClass( 'notice-success' ).addClass( 'notice-warning' );
                                        }
 
                                        event.preventDefault();