Skip to content

Commit

Permalink
Save truncation status in public field
Browse files Browse the repository at this point in the history
  • Loading branch information
Adrián David Benjuya committed Mar 8, 2021
1 parent cd4bb5f commit 7e965de
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ export class LineTruncationDirective
windowResize$ = new Subject<Event>();
windowListener: Subscription;
mutationObserver: MutationObserver;
isTruncated: boolean;

@HostListener("window:resize", ["$event"])
handleClick(event: Event) {
Expand Down Expand Up @@ -143,7 +144,8 @@ export class LineTruncationDirective
}

handler(e: boolean) {
this.hasTruncated.emit(e);
this.isTruncated = e;
this.hasTruncated.emit(this.isTruncated);

if (!this.watchChanges) {
this.observerFlag = false;
Expand Down

0 comments on commit 7e965de

Please sign in to comment.