I need to implement something like a table (no columns, only rows). I drew a layout of how it should look. As I understand it, you need 3 divs – a common one, then for the top table (which needs to be divided in half – each with its own set of rows), and for the bottom. Rows can dynamically increase in height if there is not enough space for them. How can I do that?
layout.
<div class="dx-scroll-view.css-accident-info">
<div class="div">
<div class="wrapper">
<div class="row" style="border-right: 5px solid black">
<div class="css-field">
<span class="css-label">Initicator:</span>
<span class="css-value">{{accident.initiator}}</span>
</div>
</div>
<div class="row" style="border-right: 5px solid black">
<div class="css-field">
<span class="css-label">Initicator:</span>
<span class="css-value">{{accident.initiator}}</span>
</div>
</div>
</div>
</div>
</div>
style
.wrapper {
display: flex;
flex-direction: column;
}
.row {
width: 50%;
height: 40px;
border: 1px solid #000;
}
I tried to implement it like this, but it didn’t work
2
Answers
I’m not sure I understand where you ran into an issue but the following basic HTML creates the structure you posted in your image link. I left off the styling because it’s unclear to me what is not working in your implementation.
Hi have a look at using CSS GRID although it can just be done with traditional styling:
https://gridbyexample.com/examples/
https://css-tricks.com/snippets/css/complete-guide-grid/
Just tweak the below to your liking