Skip to content

Commit

Permalink
tooltip autohide false fix
Browse files Browse the repository at this point in the history
  • Loading branch information
maruthumj committed Nov 5, 2023
1 parent 9c487d3 commit 1466502
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/app/components/tooltip/tooltip.ts
Original file line number Diff line number Diff line change
Expand Up @@ -297,7 +297,13 @@ export class Tooltip implements AfterViewInit, OnDestroy {

onMouseLeave(e: MouseEvent) {
if (!this.isAutoHide()) {
const valid = DomHandler.hasClass(e.target, 'p-tooltip') || DomHandler.hasClass(e.target, 'p-tooltip-arrow') || DomHandler.hasClass(e.target, 'p-tooltip-text') || DomHandler.hasClass(e.relatedTarget, 'p-tooltip');
const valid =
DomHandler.hasClass(e.target, 'p-tooltip') ||
DomHandler.hasClass(e.target, 'p-tooltip-arrow') ||
DomHandler.hasClass(e.target, 'p-tooltip-text') ||
DomHandler.hasClass(e.relatedTarget, 'p-tooltip') ||
DomHandler.hasClass(e.relatedTarget, 'p-tooltip-text') ||
DomHandler.hasClass(e.relatedTarget, 'p-tooltip-arrow');
!valid && this.deactivate();
} else {
this.deactivate();
Expand Down

0 comments on commit 1466502

Please sign in to comment.