Input: Change options breakpoint to 6

This commit is contained in:
Konstantinos Triantafyllou 2022-06-20 13:11:21 +03:00
parent 8a64b576d0
commit 2ba6777d97
1 changed files with 2 additions and 1 deletions

View File

@ -235,6 +235,7 @@ export class InputComponent implements OnInit, OnDestroy, AfterViewInit, OnChang
public properties: EnvProperties = properties;
private initValue: any;
private optionsArray: Option[] = [];
private optionsBreakpoint: number = 6;
private subscriptions: any[] = [];
@ViewChild('inputBox') inputBox: ElementRef;
@ViewChild('optionBox') optionBox: ElementRef;
@ -269,7 +270,7 @@ export class InputComponent implements OnInit, OnDestroy, AfterViewInit, OnChang
this.tooltip = this.optionsArray.length > 0;
}
if(this.type === "select") {
if (this.optionsArray.length > 7) {
if (this.optionsArray.length > this.optionsBreakpoint) {
this.type = 'autocomplete';
this.showOptionsOnEmpty = true;
this.icon = this.selectArrow;