Topic: cursor: pointer not added to MDBDropdownItem using "to" property

abnewkirk priority asked 3 years ago

Expected behavior When using the "to" property on a MDBDropdownItem element, I expect that the cursor:pointer css styling to be added, just as if I were using href=""

Actual behavior As showing in this snippet, when I switch from the href property to using to, the the cursor is no longer a pointer, but rather a text-cursor.

Resources (screenshots, code snippets etc.) Please see this snippet. Specifically, I'm using the MDBDropdown in a navbar, but regardless, the behavior is the same.

Mikołaj Smoleński staff commented 3 years ago

It's happening because the router-link is not an anchor element. To fix this issue please add this scss rule:

  .dropdown-item {
    cursor: pointer

I also made this update to the snippet:

Keep coding,  Mikołaj from MDB

abnewkirk priority commented 3 years ago

Perfect, this is exactly how I fixed it as well, I guess I just expected that it would be, but this resolves the issue. Thank you, Mikolaj!

Please insert min. 20 characters.


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



Specification of the issue

  • ForumUser: Priority
  • Premium support: Yes
  • Technology: MDB Vue
  • MDB Version: MDB5 1.0.0-beta3
  • Device: Dell Latitude E5570
  • Browser: Chrome Version 90.0.4430.212
  • OS: Windows 10 Pro 20H2
  • Provided sample code: No
  • Provided link: Yes