Skip to content

Commit

Permalink
Fixed #14595 - Autocomplete | maxlength doesn't work anymore
Browse files Browse the repository at this point in the history
  • Loading branch information
mehmetcetin01140 committed Jan 30, 2024
1 parent 239b86c commit 379a207
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/app/components/autocomplete/autocomplete.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1061,7 +1061,7 @@ export class AutoComplete implements AfterViewChecked, AfterContentInit, OnDestr
clearTimeout(this.searchTimeout);
}

let query = event.target.value;
let query = event.target.value.split('').slice(0, this.maxlength).join('');

if (!this.multiple && !this.forceSelection) {
this.updateModel(query);
Expand Down Expand Up @@ -1622,3 +1622,4 @@ export class AutoComplete implements AfterViewChecked, AfterContentInit, OnDestr
declarations: [AutoComplete]
})
export class AutoCompleteModule {}

0 comments on commit 379a207

Please sign in to comment.