I have a mat-list inside a mat-dialog. I'm trying to eliminate the scrollbar generate by the mat list but I couldn't find a solution. selection-list.component.html:
<mat-list role="list">
<mat-list-item role="listitem" *ngFor="let d of data"> {{d}}</mat-list-item>
</mat-list>
main-component.html:
<h1 mat-dialog-title>List</h1>
<div mat-dialog-content fxLayout="column" fxLayoutAlign="flex-start center">
<selection-list></selection-list>
</div>
I tried this:
::ng-deep .mat-list {
overflow-y: hidden !important;
}
You have to override mat-dialog-content overflow:auto to overflow:hidden
:ng-deep .mat-dialog-content{
overflow-y: hidden !important;
}