I have two columns in a row. The left columns has a fixed height given by the content it holds height:auto. The right column is longer than the left column. How can I overflow the right column once it reaches the height of the left column?
I already tried to give the right column overflow-y: scroll; max-height: 200px;. But I want the right column to automatically adjust to the left column, without specifying a length-based height.
I also created a JSFiddle with my problem here.
I am using Bootstrap 4.6.0 in my Angular project.
My HTML code currently looks like this:
<div class="row justify-content-center">
<div class="col">
<mat-list role="list">
<mat-list-item role="listitem">STATUS: {{statusText}}</mat-list-item>
<mat-list-item role="listitem">UserId: {{character?.userId}}</mat-list-item>
<mat-list-item role="listitem">CharacterId: {{character?._id}}</mat-list-item>
<mat-list-item role="listitem">Gender: {{character?.gender}}</mat-list-item>
<mat-list-item role="listitem">Region Id: {{character?.regionId}} </mat-list-item>
<mat-list-item role="listitem">
Region name: {{region?.name}}
<button mat-raised-button color="primary" [routerLink]="['/regions', character?.regionId]">Overview</button>
<button mat-raised-button color="primary" (click)="goToMap(character?.regionId)">Show on Worldmap</button>
</mat-list-item>
<mat-list-item role="listitem">City Id: {{character?.cityId}} </mat-list-item>
<mat-list-item role="listitem">City name: {{city?.name}}</mat-list-item>
<mat-list-item role="listitem">HP: {{character?.hp}}</mat-list-item>
<mat-list-item role="listitem">Strength: {{character?.strength}}</mat-list-item>
<mat-list-item role="listitem">Agility: {{character?.agility}}</mat-list-item>
<mat-list-item role="listitem">Intelligence: {{character?.intelligence}}</mat-list-item>
</mat-list>
</div>
<div class="col">
<div class="row limit">
<mat-card *ngFor="let log of logs" style="margin-top:10px; width:100%">
<div class="row">
<mat-card-header>
<mat-card-title>{{log.action}}</mat-card-title>
<mat-card-subtitle>{{log.objectId}}</mat-card-subtitle>
</mat-card-header>
</div>
</mat-card>
</div>
<div *ngIf="logsCurrentPage > 1" class="row justify-content-center">
<button class='btn-margin' mat-raised-button color="secondary" (click)='loadNextLogPage()'>Load more</button>
</div>
</div>
</div>