I want to arrange my child card in the parent card in like this picture. I use bootstrap 4 an d card_deck class
But I have a problem to have a correct template. I want also to add a vertical divider html like the picture and when I click the span with the number, I want to display a list group bootstrap with list 8 apples or 3 pear (when I click span 3 pear) etc.
In my code, you can see the based structure : head, body and I also added bootstrap link. My problem is to arrange the elements as shown in the picture.
Does anyone have an idea?
<head>
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.5.2/css/bootstrap.min.css">
</head>
<body>
<div class="container">
<h4 class="card-title">Shopping List</h4>
<div class="card-deck">
<h5 class="card-title">Today</h5>
<div class="card text-center">
<div class="card-block">
<button type="button" class="btn btn-primary">
<span class="badge badge-light">8</span> apples
<span class="sr-only">unread messages</span>
</button>
</div>
</div>
<div class="card text-center">
<div class="card-block">
<button type="button" class="btn btn-primary">
<span class="badge badge-light">3</span> pears
<span class="sr-only">unread messages</span>
</button>
</div>
</div>
</div>
<div class="card-deck mt-20">
<h5 class="card-title">Tomorrow</h5>
<div class="card text-center">
<div class="card-block">
<button type="button" class="btn btn-primary">
<span class="badge badge-light">2</span> cherries
<span class="sr-only">unread messages</span>
</button>
</div>
</div>
<div class="card text-center">
<div class="card-block">
<button type="button" class="btn btn-primary">
<span class="badge badge-light">6</span> mangoes
<span class="sr-only">unread messages</span>
</button>
</div>
</div>
</div>
</div>
</body>
