Skip to content

Commit

Permalink
Fixed #16191 - Accessibility: Tree not selectable via Keyboard after …
Browse files Browse the repository at this point in the history
…second dialog opening
  • Loading branch information
mehmetcetin01140 committed Aug 8, 2024
1 parent 512f03d commit f54c8f0
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/app/components/tree/tree.ts
Original file line number Diff line number Diff line change
Expand Up @@ -281,7 +281,10 @@ export class UITreeNode implements OnInit {

ngOnInit() {
(<TreeNode>this.node).parent = this.parentNode;
if (this.parentNode) {
const nativeElement = this.tree.el.nativeElement;
const pDialogWrapper = nativeElement.closest('p-dialog');

if (this.parentNode && !pDialogWrapper) {
this.setAllNodesTabIndexes();
this.tree.syncNodeOption(<TreeNode>this.node, <TreeNode<any>[]>this.tree.value, 'parent', this.tree.getNodeWithKey(<string>this.parentNode.key, <TreeNode<any>[]>this.tree.value));
}
Expand Down

0 comments on commit f54c8f0

Please sign in to comment.