0

I have created a simple dropdown menu using bootstrap Basic bootstrap dropdown

<li class="nav-item dropdown">
    <a href="" id="dropdownMenu2" data-bs-toggle="dropdown" aria-expanded="false" class="nav-link">
        <i class="fa-solid fa-user" style="font-size: 24px"></i>
    </a>
    <ul class="dropdown-menu w-500 align-items-stretch" aria-labelledby="dropdownMenu2">
        <li><a class="dropdown-item" href="#">Another action</a></li>
        <li><a class="dropdown-item" href="#">Something else here</a></li>
        <li><a class="dropdown-item" href="#">Nothing else</a></li>
    </ul>
</li>

I've searched a lot on how to extend the UX for the user in a more complex window shown when the user clicks on the button but like this one.

Enhanced menu

Any hint on what bootstrap options do I have?

Thank you

2 Answers2

0

You could always put a grid within the <li></li>. Of course you're going to have to use the docs (Grid system) to see what options you have in styling it, but basically:

<li>
  <div class='row'>
    <div class='col'>
      <a class="dropdown-item" href="#">Another action</a>
      <a class="dropdown-item" href="#">Something else here</a>
      <a class="dropdown-item" href="#">Nothing else</a>
    </div>
    <div class='col'>
      <a class="dropdown-item" href="#">Another action</a>
      <a class="dropdown-item" href="#">Something else here</a>
      <a class="dropdown-item" href="#">Nothing else</a>
    </div>
    <div class='col'>
      <a class="dropdown-item" href="#">Another action</a>
      <a class="dropdown-item" href="#">Something else here</a>
      <a class="dropdown-item" href="#">Nothing else</a>
    </div>
  </div>
</li>
  • Thank you for your answer János but this didn't work as expected. I pasted the snippet code into the dropdown
  • list and I have the same behavior that is a list within a small window, like a normal menu behavior of a windows menu.
  • – Ernesto Pareja Oct 23 '22 at 13:59