Skip to content

Commit

Permalink
Fixed #14701 - Dropdown | removing a letter from filter that comes af…
Browse files Browse the repository at this point in the history
  • Loading branch information
mehmetcetin01140 committed Feb 7, 2024
1 parent b8cdb86 commit 9747f3c
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/app/components/dropdown/dropdown.ts
Original file line number Diff line number Diff line change
Expand Up @@ -912,11 +912,11 @@ export class Dropdown implements OnInit, AfterViewInit, AfterContentInit, AfterV
!_filterBy && !this.filterFields && !this.optionValue
? this.options.filter((option) => {
if (option.label) {
return option.label.toLowerCase().indexOf(this._filterValue().toLowerCase()) !== -1;
return option.label.toLowerCase().indexOf(this._filterValue().toLowerCase().trim()) !== -1;
}
return option.toLowerCase().indexOf(this._filterValue().toLowerCase()) !== -1;
return option.toLowerCase().indexOf(this._filterValue().toLowerCase().trim()) !== -1;
})
: this.filterService.filter(options, this.searchFields(), this._filterValue(), this.filterMatchMode, this.filterLocale);
: this.filterService.filter(options, this.searchFields(), this._filterValue().trim(), this.filterMatchMode, this.filterLocale);

if (this.group) {
const optionGroups = this.options || [];
Expand Down

0 comments on commit 9747f3c

Please sign in to comment.