From d9840b98c34b11cb25515c644190378aa8ec2ff6 Mon Sep 17 00:00:00 2001 From: Maxime Robert Date: Mon, 10 Aug 2020 17:42:30 +0200 Subject: [PATCH] FIX #887 (#909) Co-authored-by: Giancarlo Buomprisco --- modules/components/dropdown/tag-input-dropdown.component.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/modules/components/dropdown/tag-input-dropdown.component.ts b/modules/components/dropdown/tag-input-dropdown.component.ts index 6f4fc51f..c267b30e 100644 --- a/modules/components/dropdown/tag-input-dropdown.component.ts +++ b/modules/components/dropdown/tag-input-dropdown.component.ts @@ -13,7 +13,7 @@ import { // rx import { Observable } from 'rxjs'; -import { filter, first, debounceTime } from 'rxjs/operators'; +import { filter, first, debounceTime, distinctUntilChanged } from 'rxjs/operators'; import { Ng2Dropdown, Ng2MenuItem } from 'ng2-material-dropdown'; import { defaults } from '../../defaults'; @@ -172,6 +172,7 @@ export class TagInputDropdown implements AfterViewInit { this.tagInput.onTextChange .asObservable() .pipe( + distinctUntilChanged(), debounceTime(DEBOUNCE_TIME), filter((value: string) => { if (KEEP_OPEN === false) {