Skip to content

Commit

Permalink
Fix delay initialization options for customized JQuery UI menu widget
Browse files Browse the repository at this point in the history
  • Loading branch information
scazz010 authored and stemcellscarr committed Nov 14, 2017
1 parent 5de0f07 commit 6330103
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion lib/web/mage/menu.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ define([
expanded: false,
showDelay: 42,
hideDelay: 300,
delay: 300,
mediaBreakpoint: '(max-width: 768px)'
},

Expand All @@ -30,6 +31,8 @@ define([
_create: function () {
var self = this;

this.delay = this.options.delay;

this._super();
$(window).on('resize', function () {
self.element.find('.submenu-reverse').removeClass('submenu-reverse');
Expand Down Expand Up @@ -583,7 +586,7 @@ define([
html.removeClass('nav-open');
setTimeout(function () {
html.removeClass('nav-before-open');
}, 300);
}, this.options.hideDelay);
}
},

Expand Down

0 comments on commit 6330103

Please sign in to comment.