Blog, Website & Page Publishing

ZoeNZ
Participant

Dropdown menu disappears before you can click something

SOLVE

Hello!

 

I've just inherited this site and I've noticed that the dropdown doesn't always stay down when you click on it, if that makes sense. I've made a gif to show you what I mean. I click it, and when I go to click something else it disappears. It does work eventually (usually around my 3rd attempt) but never seems to work for me the first time.

 

slow.gif

 

Any ideas? Thanks guys

0 Upvotes
1 Accepted solution
Kevin-C
Solution
Recognized Expert | Partner
Recognized Expert | Partner

Dropdown menu disappears before you can click something

SOLVE

So there are a number of things going on here, including a few redundencies about 3 of them that can probaly be reduced. Luckely it seems that only one of them is functioning…weird thing to be lucky about lol.

 

Anyway in your "Companymain.js" file on line ~39, find this line of code:

 

child.parent().siblings('.hs-item-has-children').find('.hs-menu-children-wrapper').slideUp(250);

 

Without the ability to modify and test I can't be sure that this will help but its worth a shot.

 

 

PS

Out of pure non-judgemental curiousity, who/where did you get this template and or code?

Kevin Cornett - Sr. Solutions Architect @ BridgeRev

View solution in original post

8 Replies 8
Kevin-C
Recognized Expert | Partner
Recognized Expert | Partner

Dropdown menu disappears before you can click something

SOLVE

Hey @ZoeNZ 

 

Just following up.

Did you get what you needed?

Kevin Cornett - Sr. Solutions Architect @ BridgeRev
ZoeNZ
Participant

Dropdown menu disappears before you can click something

SOLVE

Hi Kevin!

 

Sadly haven't heard back with a solution yet!

 

Cheers,

Zoe

0 Upvotes
Kevin-C
Recognized Expert | Partner
Recognized Expert | Partner

Dropdown menu disappears before you can click something

SOLVE

Hey @ZoeNZ 

 

Sorry for the delay. Ill have a closer look at this today.

 

In the meantime if you inspect at the markup (im using FF) and the associated JS you can see that the LI element has a click listener that adds the "active" class. And inside the A element has a click event listener. I believe that this combo is whats causing the issue. See image below:

eventlistenerissue.png

 

You can investigate by looking at the Companymain.js file line 51 and 33.

Kevin Cornett - Sr. Solutions Architect @ BridgeRev
0 Upvotes
Kevin-C
Solution
Recognized Expert | Partner
Recognized Expert | Partner

Dropdown menu disappears before you can click something

SOLVE

So there are a number of things going on here, including a few redundencies about 3 of them that can probaly be reduced. Luckely it seems that only one of them is functioning…weird thing to be lucky about lol.

 

Anyway in your "Companymain.js" file on line ~39, find this line of code:

 

child.parent().siblings('.hs-item-has-children').find('.hs-menu-children-wrapper').slideUp(250);

 

Without the ability to modify and test I can't be sure that this will help but its worth a shot.

 

 

PS

Out of pure non-judgemental curiousity, who/where did you get this template and or code?

Kevin Cornett - Sr. Solutions Architect @ BridgeRev
ZoeNZ
Participant

Dropdown menu disappears before you can click something

SOLVE

Thanks Kevin!!!

 

Ha I'm not sure, I've only just come on board! But I'm curious too...

 

Cheers,

Zoe

DanielSanchez
Key Advisor | Platinum Partner
Key Advisor | Platinum Partner

Dropdown menu disappears before you can click something

SOLVE

Hi @ZoeNZ ,

 

GIF helps a lot to understand your problem. Thanks!!

 

But, we need link of this page to understand how the menu works in the code.

U can send for us?

 

Thanks! 🙂

Kevin-C
Recognized Expert | Partner
Recognized Expert | Partner

Dropdown menu disappears before you can click something

SOLVE

Hey @DanielSanchez 

 

http://brandmachine.com/ is the website

Kevin Cornett - Sr. Solutions Architect @ BridgeRev
JessicaH
HubSpot Alumni
HubSpot Alumni

Dropdown menu disappears before you can click something

SOLVE

Hi @ZoeNZ,

 

Thanks for reaching out.

I want to tag in some thought leaders to see if they can assist with this.

Hi @ajchapman20 @DanielSanchez @Stephanie-OG , would you be able to share your thoughts with @ZoeNZ?

 

Thanks!

Jess  


Wusstest du, dass es auch eine DACH-Community gibt?
Nimm an regionalen Unterhaltungen teil, in dem du deine Spracheinstellungen änderst !


Did you know that the Community is available in other languages?
Join regional conversations by changing your language settings !