Skip to content

Commit

Permalink
Merge pull request #15821 from primefaces/issue-15714
Browse files Browse the repository at this point in the history
Fixed #15714 - pTree: right click on treenode chevron down
  • Loading branch information
cetincakiroglu authored Jun 13, 2024
2 parents aab60c9 + d762804 commit f155b0c
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/app/components/tree/tree.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1371,8 +1371,9 @@ export class Tree implements OnInit, AfterContentInit, OnChanges, OnDestroy, Blo
onNodeRightClick(event: MouseEvent, node: TreeNode<any>) {
if (this.contextMenu) {
let eventTarget = <Element>event.target;
let className = eventTarget.getAttribute('class');

if (eventTarget.className && eventTarget.className.indexOf('p-tree-toggler') === 0) {
if (className && className.includes('p-tree-toggler')) {
return;
} else {
let index = this.findIndexInSelection(node);
Expand Down

0 comments on commit f155b0c

Please sign in to comment.