Strange dropdown menu problem

Hi,

I’m having a strange dropdown menu issue with the last item on the top menu. When hovering on the last item on the top menu, the drop-down menu displays quite a bit offset to the left.

Please see zehawk.in or screenshot attached. The problem menu item is “about”. BTW it does not matter which menu item I put here, the problem remains the same. Occurs across browsers.

After doing a code inspection, I see that its applying the following to the sub-menu only for this last item:

<ul class = "sub-menu" style = "left: -250px; display: none; visibility: hidden;">

Why is it applying the left -250px offset?

Thanks for any help or clues.

Hello,

I see the menu alright, have you managed to fix this issue?

Regards

No I haven’t. I just checked right now and I still find the same issue on my side that I reported. Thanks.

Hello,

I’m deeply sorry but I really can’t replicate the behaviour.

I tried Edge browser as well, as it seems that is what you are using.

Try to use this CSS code, it might fix your issue:

#header .top-header .header-navigation ul li.menu-item-has-children .sub-menu{
left: 0 !important;
}

Regards

Test, am I able to post this?

Not able to make this post for some reason for last few days, trying again.

Note that I showed a screenshot in Edge, but the same thing happens across FF and Opera.

Your screen width is higher. Mine is 1366 wide. Perhaps if you resize (reduce) the browser window such that the last menu item is close to the right border, the problem should occur on your side.

The hardcoded width of the submenu is 250px. When a menu element is close to the right border, it makes a decision to offset the submenu dropdown to the left by 250px. I believe this is incorrect logic. Please see attached screenshot. This is in FF and same behavior is in other browsers.

For the moment adding “left: 0 !important;” solves the problem but I would love to know where the offset logic is being applied in the code so that it can be fixed there.

Would you have the time and or interest to debug further?

Thanks very much!

Hello @zehawk,

I will do my best to continue the investigation, thank you for taking the time to explain it in detail.

Also glad that you are back with us and you can post alright :slight_smile:

Regards

> Also glad that you are back with us and you can post alright ?

Thanks for fixing the issue so quickly :slight_smile:

BTW, here’s the screenshot that I referred to in my last post.