From 255d1f112b543f4b21272bb201d332d237157494 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=87etin?= <69278826+cetincakiroglu@users.noreply.github.com> Date: Fri, 3 May 2024 12:40:02 +0300 Subject: [PATCH] Fixed #14953 - Add missing stopPropagation --- src/app/components/dropdown/dropdown.ts | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/app/components/dropdown/dropdown.ts b/src/app/components/dropdown/dropdown.ts index 942391459d5..d879f37ea4e 100755 --- a/src/app/components/dropdown/dropdown.ts +++ b/src/app/components/dropdown/dropdown.ts @@ -1581,6 +1581,7 @@ export class Dropdown implements OnInit, AfterViewInit, AfterContentInit, AfterV // !this.overlayVisible && this.show(); event.preventDefault(); + event.stopPropagation(); } changeFocusedOptionIndex(event, index) { @@ -1681,15 +1682,15 @@ export class Dropdown implements OnInit, AfterViewInit, AfterContentInit, AfterV } this.overlayVisible && this.hide(); - event.preventDefault(); } else { const optionIndex = this.focusedOptionIndex() !== -1 ? this.findPrevOptionIndex(this.focusedOptionIndex()) : this.clicked() ? this.findLastOptionIndex() : this.findLastFocusedOptionIndex(); this.changeFocusedOptionIndex(event, optionIndex); !this.overlayVisible && this.show(); - event.preventDefault(); } + event.preventDefault(); + event.stopPropagation(); } onArrowLeftKey(event: KeyboardEvent, pressedInInputText: boolean = false) { @@ -1790,6 +1791,7 @@ export class Dropdown implements OnInit, AfterViewInit, AfterContentInit, AfterV this.overlayVisible && this.hide(this.filter); } } + event.stopPropagation(); } onFirstHiddenFocus(event) {