Seeking to customize Angular Material Select to resemble a basic dropdown. Even after applying the disableOptionCentering
, the dropdown list options still expand from the left and right sides (refer to Current picture below). The desired look would involve slimming down the left and right sides. How can this be achieved?
https://material.angular.io/components/select/overview
<h4>Basic mat-select</h4>
<mat-form-field appearance="outline">
<mat-label>Favorite food</mat-label>
<mat-select disableOptionCentering>
<mat-option *ngFor="let food of foods" [value]="food.value">
{{food.viewValue}}
</mat-option>
</mat-select>
</mat-form-field>
Current appearance:
Adjustments needed to trim the left and right sides, apply margin/padding accordingly for a vertical alignment
https://i.sstatic.net/VdqbH.png
Desired outcome: