Skip to content

Commit

Permalink
Refactor #11313
Browse files Browse the repository at this point in the history
  • Loading branch information
yigitfindikli committed Mar 30, 2022
1 parent 232b402 commit 828f63a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/app/components/toast/toast.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import {Message, PrimeNGConfig} from 'primeng/api';
import {DomHandler} from 'primeng/dom';
import {PrimeTemplate,SharedModule} from 'primeng/api';
import {MessageService} from 'primeng/api';
import {UniqueComponentId} from 'primeng/utils';
import {ObjectUtils, UniqueComponentId} from 'primeng/utils';
import {RippleModule} from 'primeng/ripple';
import {Subscription} from 'rxjs';
import {trigger,state,style,transition,animate,query,animateChild,AnimationEvent} from '@angular/animations';
Expand Down Expand Up @@ -305,7 +305,7 @@ export class Toast implements OnInit,AfterContentInit,OnDestroy {

onAnimationEnd(event: AnimationEvent) {
if (event.toState === 'void') {
if (this.autoZIndex && !this.messages.length ) {
if (this.autoZIndex && ObjectUtils.isEmpty(this.messages)) {
ZIndexUtils.clear(this.containerViewChild.nativeElement);
}
}
Expand Down

0 comments on commit 828f63a

Please sign in to comment.