Customize: Fix ability to shift-click on placeholder/pre-saved nav menu items in preview to focus on corresponding control.
Props westonruter. Merges [39562] to the 4.7 branch. Fixes #39102. Built from https://develop.svn.wordpress.org/branches/4.7@39572 git-svn-id: http://core.svn.wordpress.org/branches/4.7@39512 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
5fa8150d16
commit
900cd6c47d
|
@ -419,7 +419,7 @@ wp.customize.navMenusPreview = wp.customize.MenusCustomizerPreview = ( function(
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
navMenuItemParts = $( this ).attr( 'class' ).match( /(?:^|\s)menu-item-(\d+)(?:\s|$)/ );
|
navMenuItemParts = $( this ).attr( 'class' ).match( /(?:^|\s)menu-item-(-?\d+)(?:\s|$)/ );
|
||||||
if ( navMenuItemParts ) {
|
if ( navMenuItemParts ) {
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
e.stopPropagation(); // Make sure a sub-nav menu item will get focused instead of parent items.
|
e.stopPropagation(); // Make sure a sub-nav menu item will get focused instead of parent items.
|
||||||
|
|
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue