Above is a picture of my current design. The question is regarding the first container in the dashboard.
The different content inside the container is stuck to each other.
What I am trying to achieve is this:
The HTML code is (using mudblazor):
<MudContainer Class="firstRowContainer" MaxWidth="MaxWidth.Large">
<MudGrid>
<MudPaper Elevation="6" Class="firstRowContent">
<p>Amount bookings today</p>
</MudPaper>
<MudPaper Elevation="3" Class="firstRowContent">
<p>Amount open quotes</p>
</MudPaper>
<MudPaper Elevation="3" Class="firstRowContent">
<p>top 10 customs amount bookings per range</p>
</MudPaper>
<MudPaper Elevation="3" Class="firstRowContent">
<p>Amount new customers today</p>
</MudPaper>
<MudPaper Elevation="3" Class="firstRowContent">
<p>top 10 ports</p>
</MudPaper>
<MudPaper Elevation="3" Class="firstRowContent">
<p>Amount active bookings</p>
</MudPaper>
</MudGrid>
</MudContainer>
CSS is:
<style>
.firstRowContainer {
position: relative;
display: flex;
flex: none;
flex-direction: row;
justify-content: space-between;
top: 10px;
margin-left: 5px;
padding: 11px;
}
.firstRowContent {
border: 0.5px solid aliceblue;
flex: none;
top: 5px;
width: 150px;
max-width: 150px;
height: 80px;
}
</style>
I have read that I should use display: flex
and I've tried different things, but nothing seems to work. I am not sure, but I think the parent/child relation between the container and the content is not set up correctly.
How can I add space between these boxes?