- .addClass( 'notice-warning' )
- .show();
-
- $notice.on( 'click.autosave-local', function( event ) {
- var $target = $( event.target );
-
- if ( $target.hasClass( 'restore-backup' ) ) {
- 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' );
- }