ul.horiz {
margin: 0;
padding: 0;
list-style-type: none;
}
ul.horiz > li {
display: inline;
}
<ul class="horiz">
<li>This is the first item text</li>
<li>X</li>
</ul>
I want to have a horizontal list of two items fit in a div 100% of the div (so it adjusts as the browser (and div) changes width. The second list item should have a fixed width and the first item should fill the remaining space.
I'm not sure how this is possible. I don't want to do percentages, if possible.
It doesn't necessarily have to be a list (i.e. ul/li), but that was my initial thought.
The first item would be text content and the second item would be an image.