I believe this solution can be achieved solely using bootstrap classes. I recommend familiarizing yourself with the bootstrap grid system to understand how it operates: Grid Docs and Column Docs
<link href="https://cdn.jsdelivr.net/npm/<a href="/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="a8cac7c7dcdbdcdac9d8e89d869b8699">[email protected]</a>/dist/css/bootstrap.min.css" rel="stylesheet"/>
<div class="container">
<div class="row">
<div class="col-3">
<div id="letter" class="bg-danger" style="min-height:400px;">A</div>
</div>
<div class="col-12 col-md-9">
<div id="numbers" class="row bg-warning">
<div class="col-12 col-md-6 col-lg-4">
<div class="bg-info" style="min-height:200px;">1</div>
</div>
<div class="col-12 col-md-6 col-lg-4">
<div class="bg-info" style="min-height:180px;">2</div>
</div>
<div class="col-12 col-md-6 col-lg-4">
<div class="bg-info" style="min-height:150px;">3</div>
</div>
</div>
</div>
</div>
</div>
Explanation of Bootstrap Columns
In essence, a row
encompasses the only elements that can directly contain columns, which are assigned col-*
classes. Do not modify the size of a row or column through styling!
Each row consists of 12 available columns. For instance, if two col-6
elements are present, each will utilize 50% of the space.
<div class="row">
<div class="col-6">half</div>
<div class="col-6">half</div>
</div>
You have flexibility in dividing the columns as long as they sum up to 12. This could include 3 col-4
's, a col-6
, 2 col-3
's, or even 12 col-1
's.
If the total exceeds 12, the excess content will wrap to the subsequent line. For example, placing 3 col-6
's would display the first two on one line followed by the third on the next line.
Interrupting Columns
You can designate varying column sizes for distinct screen dimensions! Bootstrap defines these screen sizes and you can explore themhere. It is crucial to generate styles from the smallest to largest screens without deviating from this order.
If a column has col-12 col-sm-6 col-md-4
, it signifies full width at the smallest size, modifying to half width as the screen enlarges, and eventually occupying 4 columns at larger resolutions.
Nested rows within another row's column are feasible. The concept is straightforward—remember that a row
occupies the entire width while columns proportionally dictate their share rather than fixed pixel values.