Closed Mte90 closed 2 years ago
This pull request removes all the last fixes. Please update to match your intent
I think I fixed that issue.
Using this pull request, on mobile menu , you cannot visit the link of a menu item containing submenu.
The reason is because you are running a prevent default
without checking it the item is opened or not.
Please add this control to your code and the pull request will be accepted.
if (t.hasClass('submenu-opened')) {
return true;
} else {
In what line?
you can replace lines 79. 80, 81 with this:
var t = $(this);
if (t.hasClass('submenu-opened')) {
return true;
} else {
ev.preventDefault();
t.parent().siblings().find('a').removeClass('submenu-opened');
t.addClass('submenu-opened');
}
or, in case you want to avoid a line:
if ($(this).hasClass('submenu-opened')) {
return true;
} else {
ev.preventDefault();
$(this).parent().siblings().find('a').removeClass('submenu-opened');
$(this).addClass('submenu-opened');
}
thanks for your code, merged
As per https://github.com/yithemes/yith-proteo/pull/30/ require some testing