I'm using Angular Material and I would like to know if it is possible to automatically increase the size of mat-select when I select several security groups, because today when I select several, it can only visualize the groups that fit in the mat-select space. I wanted to be able to view all security groups.
HTML:
<mat-form-field class="matfield" appearance="outline" required>
<mat-label>Secure Group</mat-label>
<mat-select class="mat-select-securegroup" [formControl]="secureGroups" multiple>
<mat-option *ngFor="let secureGroups of secureGroupsList" [value]="secureGroups"></mat-option>
</mat-select>
</mat-form-field>
COMPONENT.TS:
secureGroups = new FormControl('');
secureGroupsList: string[] = ['Secure Group 1', 'Secure Group 2', 'Secure Group 3', 'Secure Group 4', 'Secure Group 5', 'Secure Group 6'];
Comments
Post a Comment