I have two divs inside a div
as shown below:
.w-35 {
width: 35%;
}
.d-flex {
display: flex!important;
}
.mr-auto {
margin-right: auto!important;
}
.flex-column {
-webkit-box-orient: vertical!important;
-webkit-box-direction: normal!important;
-ms-flex-direction: column!important;
flex-direction: column!important;
}
<div class="d-flex">
<div class="mr-auto">
<div>Box1</div>
</div>
<div class="w-35">
<div class="flex-column"> Box2 </div>
</div>
</div>
While the second div
has a width of 35%
, is there a way I could correctly deduce the width of the first div
with class mr-auto
to be 65%? I always want the width of the first div
to be 100% - width_of_second_div_in_percent
.
How could I do this?