I am currently designing a form with a side navigation bar that will display around 15-20 elements. Each element is represented by an <li>
containing a link to open a modal when clicked.
This is the current structure of my code:
<div id="sidebar-wrapper">
<ul class="sidebar-nav">
<h4 class="sidebar-brand">Select Field Type</h4>
<li><a href="#" data-toggle="modal" data-target="#SingleLine_Modal">Single Line</a></li>
<li><a href="#" data-toggle="modal" data-target="#PickList_Modal">Pick List</a></li>
<li><a href="#" data-toggle="modal" data-target="#MultiSelect_Modal">Multi Select</a></li>
<li><a href="#" data-toggle="modal" data-target="#MultiLine_Modal">Multi Line</a></li>
<li><a href="#" data-toggle="modal" data-target="#Email_Modal">Email</a></li>
<li><a href="#" data-toggle="modal" data-target="#Phone_Modal">Phone Number</a></li>
<li><a href="#" data-toggle="modal" data-target="#Mobile_Modal">Mobile Number</a></li>
<li><a href="#" data-toggle="modal" data-target="#Date_Modal">Date</a></li>
<li><a href="#" data-toggle="modal" data-target="#Time_Modal">Time</a></li>
<li><a href="#" data-toggle="modal" data-target="#DateTime_Modal">Date-Time</a></li>
<li><a href="#" data-toggle="modal" data-target="#CheckBox_Modal">Checkbox</a></li>
<li><a href="#" data-toggle="modal" data-target="#Radio_Modal">Radio</a></li>
<li><a href="#" data-toggle="modal" data-target="#Decimal_Modal">Decimal</a></li>
<li><a href="#" data-toggle="modal" data-target="#Number_Modal">Number</a></li>
<li><a href="#" data-toggle="modal" data-target="#AutoNumber_Modal">Auto Number</a></li>
</div>
And this is the current layout:
Single Line
Pick List
Multi Select
Multi Line
Email
Phone Number
Mobile Number
Date
Time
Date-Time
Checkbox
Radio
Decimal
Number
Auto Number
However, I would like the layout to appear as follows:
| Single Line | Pick List |
| Multiple Select | Email |
| Phone Number | Mobile Number |
| Date | Time |
| Checkbox | Radio |
| Decimal | Number |
| Auto Number | (additional li)|
To achieve this, how can I adjust my CSS or make changes to the HTML code?
The reason for this desired layout change is that as more <li>
items are added, they quickly overflow and become hidden. What steps should I take to ensure all elements are visible in the format I want?