Customize: Restrict click target of menu deletion, moving to button from its container.

Merges [41020] onto 4.8 branch.
Props westonruter, afercia.
Fixes #40981 for 4.8.1.

Built from https://develop.svn.wordpress.org/branches/4.8@41057


git-svn-id: http://core.svn.wordpress.org/branches/4.8@40907 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Weston Ruter 2017-07-14 17:44:33 +00:00
parent d32185545b
commit 3f4babe28b
2 changed files with 2 additions and 3 deletions

View File

@ -2229,8 +2229,7 @@
} }
} ); } );
control.container.find( '.menu-delete-item' ).on( 'click', function( event ) { control.container.find( '.menu-delete-item .button-link-delete' ).on( 'click', function( event ) {
event.stopPropagation();
event.preventDefault(); event.preventDefault();
control.setting.set( false ); control.setting.set( false );
}); });

File diff suppressed because one or more lines are too long