From 2183301e19af35e77bcb4d47385ab9daa772c12b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Manuel=20P=C3=A9rez?= Date: Tue, 26 Sep 2023 12:31:47 +0200 Subject: [PATCH] Fixed tree onKeyDown with contextMenu --- src/app/components/tree/tree.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/app/components/tree/tree.ts b/src/app/components/tree/tree.ts index d16d5fcc3d9..b580b05510c 100755 --- a/src/app/components/tree/tree.ts +++ b/src/app/components/tree/tree.ts @@ -487,7 +487,7 @@ export class UITreeNode implements OnInit { onKeyDown(event: KeyboardEvent) { const nodeElement = (event.target).parentElement?.parentElement; - if (nodeElement?.nodeName !== 'P-TREENODE' || (this.tree.contextMenu && this.tree.contextMenu.containerViewChild.nativeElement.style.display === 'block')) { + if (nodeElement?.nodeName !== 'P-TREENODE' || (this.tree.contextMenu && this.tree.contextMenu.containerViewChild?.nativeElement.style.display === 'block')) { return; }