Skip to content

Commit

Permalink
Fixed #10491 - StyleClass does not open overlay when source is clicke…
Browse files Browse the repository at this point in the history
…d again
  • Loading branch information
cagataycivici committed Aug 10, 2021
1 parent a1e0e01 commit dbfca6a
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/app/components/styleclass/styleclass.ts
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,10 @@ export class StyleClass implements AfterViewInit, OnDestroy {
DomHandler.addClass(this.target, this.leaveToClass);
}
}

if (this.hideOnOutsideClick) {
this.unbindDocumentListener();
}
}

resolveTarget() {
Expand Down Expand Up @@ -166,7 +170,6 @@ export class StyleClass implements AfterViewInit, OnDestroy {
}
else if (!this.el.nativeElement.isSameNode(event.target) && !this.el.nativeElement.contains(event.target) && !this.target.contains(event.target)) {
this.leave();
this.unbindDocumentListener();
}
});
}
Expand Down

0 comments on commit dbfca6a

Please sign in to comment.