I'm currently using the latest version of Bootstrap 4 and facing a challenge with making my 'list-group' responsive. Despite searching for solutions, I have yet to find one that fits my specific needs.
The 'list-group' is intended to be a tab, displaying content on the left side. While it functions correctly on desktop screens, the design falls short on mobile devices. After some exploration, I noticed that implementing a dropdown menu above the content could be a viable solution. However, I am unsure how to convert my list into a dropdown without causing any issues.
Here is what it looks like currently, with a red background indicating the selected tab and a different shade of red when hovered over: list-group. Ideally, I would like to position it at the top of its content on mobile view so that clicking on the category title expands the submenu.
Below is the code snippet:
<div class="col-xl-3 ">
<div class="list-group list-group-flush" id="list-tab" role="tablist">
<h4> Lorem Ipsum </h4>
</br>
<a class="list-group-item list-group-item-action active" id="list-who-list" data-toggle="list" href="#list-who" role="tab" aria-controls="who">dolor sit amet quo te</a>
<a class="list-group-item list-group-item-action" id="list-info-list" data-toggle="list" href="#list-info" role="tab" aria-controls="info">lorem prompta deseruisse</a>
</br>
<h4> Mei ipsum neglegentur ex</h4>
</br>
<a class="list-group-item list-group-item-action" id="list-contact-list" data-toggle="list" href="#list-contact" role="tab" aria-controls="contact">est probo</a>
<a class="list-group-item list-group-item-action" id="list-where-list" data-toggle="list" href="#list-where" role="tab" aria-controls="where">nusquam eu</a>
</br>
<h4> Quo solum soleat</h4>
</br>
<a class="list-group-item list-group-item-action" id="list-get-list" data-toggle="list" href="#list-get" role="tab" aria-controls="get">adversarium id</a>
<a class="list-group-item list-group-item-action" id="list-send-list" data-toggle="list" href="#list-send" role="tab" aria-controls="send">qui ex minim discere</a>
</div>
</div>
Essentially, I aim to reposition the entire list at the top of the tab on smaller screens such as mobile/tablet devices, converting the 'h4' elements into a dropdown menu where clicking on the title reveals the corresponding item.
Consideration has been given to creating a dropdown menu solely for small screens, though uncertainties remain regarding whether this approach constitutes a genuine solution or merely a temporary fix.