Customizer: Prevent dragging menu items above the main heading.

Improve targeting for the `sortableItems`, resolving an issue where the first `<li>` in the control became a sortable target, allowing the user to drag a single top level menu outside the intended sortable area.

props adamsilverstein.
fixes #32738.
#wceu

git-svn-id: https://develop.svn.wordpress.org/trunk@32955 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Dominik Schilling (ocean90) 2015-06-26 17:10:12 +00:00
parent 4f60683623
commit d6ebee58c2
1 changed files with 1 additions and 1 deletions

View File

@ -7,7 +7,7 @@
*/
wpNavMenu.originalInit = wpNavMenu.init;
wpNavMenu.options.menuItemDepthPerLevel = 20;
wpNavMenu.options.sortableItems = '.customize-control-nav_menu_item';
wpNavMenu.options.sortableItems = '> .customize-control-nav_menu_item';
wpNavMenu.init = function() {
this.jQueryExtensions();
};