I’m trying to make an IonSelect call open on itself. My use cases are:
- I want to force a user to select a value in that popup
- I want to force a user to select a sequence of values from the same popup, one after the other (yes, this could be a checklist, but checklists lack the ability to say "I only want to select X values, disable the rest easily)
Since there doesn’t appear to be a way to disable backdrop close or cancel, this was my solution. My code:
<ion-item class="hidden">
<ion-label>
Select Skill
</ion-label>
<ion-select #skillSelect placeholder="Select Skill" (ionChange)="addSkillFromMove($event, skillSelect, move)">
<ion-select-option *ngFor="let skill of getAddSkills(move.name)"
[value]="skill">
{{ skill }}
</ion-select-option>
</ion-select>
</ion-item>
addSkillFromMove(event, control: IonSelect, skill: string): void {
console.log(event, control, skill);
control.open();
}
(I think the rest that I haven’t included isn’t relevant)
Is there an easy way to forcibly re-open the select in its cancel or change events?
1 post - 1 participant