In Magento 2 for the main menu, they dropdown with hover. How to change the dropdown on click instead of 'hover'.


Step 1 : You need to remove the hover css for submenu.

Step 2 : After that you can add toggle event in the JS file for sub-menu.

  • It's adding inline css on hover. which js file i should customize to control it
    – Nayem323
    Jan 23 '19 at 4:16
  • @RaselUddin No, create new custom css and custom js file in your theme and implement your code in these file. Jan 23 '19 at 4:59

more details and example can help thanks!


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.