As a CSS beginner, I am seeking advice on how to properly position the text in a Gantt chart. Currently, all the text is within the bar and wrapping occurs as the bar narrows. I am looking for a solution to have the text aligned either left or right of the colored gantt bar to maintain a clean display.
https://i.sstatic.net/rZnCK.png
The desired outcome is to have the text for Step 1 on the right side of the bar, while the text for Step 5 on the left. Any additional text should follow suit, adjusting based on space availability to prevent wrapping.
<div style="background-color:green;
padding:10px;
margin-top:-10px;
width:10%;
margin-left:%;
border-radius: 10px;
color:white;
text-align:center;
font-weight:bold
">2months
<div/>