Topic: Dropdown menu always opened

moulot priority asked 1 year ago


Hello, i copied one of the navbar examples on your site with a dropdown menu. the dropdown menu is always opened whatever i do. thank you


Arkadiusz Idzikowski staff commented 1 year ago

Could you please edit your post and provide an example code that you tried to use?

In this case you should copy the code from the Angular documentation: https://mdbootstrap.com/docs/angular/navigation/navbar/


moulot priority commented 1 year ago

Hello, i used the angular version. Just tried this one from your link to no avail :

Dropdown link

  • Action
  • Another action
  • Something else here

  • moulot priority commented 1 year ago

    i don't know how to send you the code : it's from the navbar page with this comment Dropdown You can also use dropdowns in your navbar nav. Dropdown menus require a wrapping element for positioning, so be sure to use separate and nested elements for .nav-item and .nav-link as shown below.


    Arkadiusz Idzikowski staff commented 1 year ago

    You can include the code when you edit your post (there is a 'Code sample' button in our editor that will help you to format the code correctly).

    You need to make sure to use the code from the Angular documentation and not the Standard version (I included the link in my previous comment). To configure the dropdown component correctly you need to use mdbDropdown, mdbDropdownToggle, and mdbDropdownMenu directives like in our documentation. Please also remember to import the MdbDropdownModule in your app.module file.



    Please insert min. 20 characters.

    FREE CONSULTATION

    Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.

    Status

    Opened

    Specification of the issue

    • ForumUser: Priority
    • Premium support: Yes
    • Technology: MDB Angular
    • MDB Version: MDB5 3.0.1
    • Device: macbook pro
    • Browser: Chrome
    • OS: IOS
    • Provided sample code: No
    • Provided link: No