My webpage, built with Bootstrap 4, features a row with three divs placed horizontally. The divs have different percentage widths and sometimes the center div's width is set to 0%.
However, I need to ensure that the text within the 0% div is always visible above the other divs. I am facing challenges with: a) Making the text appear on top in all scenarios b) Centering the text so that it equally overflows from the center of the 0% div.
I am looking for a solution that does not involve left/right positioning, as the text width varies.
Here is the code snippet:
<div class="row d-flex">
<div class="float-left bg-info" style="width: 80%;"></div>
<div class="text-nowrap text-center" style="width: 1%;">32.34 in.</div>
<div class="float-right bg-warning" style="width: 19%;"></div>
</div>
For reference, here is a BootPly link: https://www.bootply.com/IurHhOsuf5
Does anyone know how to ensure the text stays on top?
Here is an illustration of the current behavior:
And this is how it is meant to appear:
Thank you for any assistance!