@hendryt wrote:
I have the following code:
HTML:
<ion-row> <ion-col col-12> <div class="form-group"> <ion-label class="content">Category</ion-label> <ion-select interface="popover" class="selector" placeholder="Category" id="category" formControlName="category"> <ion-option *ngFor="let vCategory of categoriesAvail" [value]="vCategory.category" class="option" text-wrap> {{vCategory.category}} </ion-option> </ion-select> </div> </ion-col> </ion-row>
Component:
categoriesAvail: iCategories[] = [];
which I then populate.SCSS:
.selector { font-family: SFNSDisplay; font-size: 12px; line-height: 1.2; letter-spacing: 0.1px; color: #29235e; width: 100% !important; max-width: 100% !important; justify-content: center; border: solid 2px #e8ebf0; background-color: #ffffff; text-align: center; } .option { font-family: SFNSDisplay; font-size: 8px; line-height: 1.2; letter-spacing: 0.1px; color: #29235e; width: 100% !important; max-width: 100% !important; justify-content: center; height: 20px; } ion-option .list{ font-family: SFNSDisplay; font-size: 8px !important; max-width: 100% !important; } .ion-option-items .item{ font-family: SFNSDisplay; font-size: 8px !important; max-width: 100% !important; } .select-popover { font-family: SFNSDisplay !important; font-size: 8px !important; max-width: 100% !important; }
This still keeps the dropdown list narrow as can be seen in the attached image.
How can I make the font on the list smaller and also change the width, nothing I have tried has worked.
Posts: 1
Participants: 1