I am attempting to create the following layout:
https://i.sstatic.net/OzE98.png
Here is what I have been able to achieve:
https://i.sstatic.net/7GxdP.png
In the second picture, the divs are shown separately. My goal is to display the incoming data in a single popup like in the first picture, but I am having trouble accomplishing this.
HTML
<div className="installmentinfo__container">
{
props.installmentList?.map((e, i) => {
return (
<div className="installmentinfo">
<div className="column">
<div className="installmentnumber" >{(i + 1).toString()}</div>
<div className="installmentdate">{e.date}</div>
<div className="installmentamount">{e.amount} {e.currency}</div>
</div>
</div>
);
})
}
</div>
CSS
.installmentinfo__container {
position: absolute;
right: 340px;
.installmentinfo {
background-color: white;
width: 280px;
height: auto;
border: var(--border);
border-radius: 0.5em;
padding: 0.5em 1em;
.column {
display: flex;
margin: 5px;
justify-content: space-between;
font-size: 1.3rem;
border-bottom: 1.5px solid #d1d1d1;
}
.installmentnumber {
float: left;
}
.installmentdate {
width: 50%;
color: black !important;
}
.installmentamount {
width: 50%;
color: black !important;
font-weight: 1000;
}
}
}