Fix server error in alert.ts where UIkit event handler is defined.

This commit is contained in:
Konstantinos Triantafyllou 2023-03-23 09:18:19 +02:00
parent 2b4835bd0d
commit 4fa36bdd43
1 changed files with 1 additions and 1 deletions

View File

@ -157,7 +157,7 @@ export class AlertModal implements OnInit, AfterViewInit, OnDestroy {
}
ngAfterViewInit() {
if(this.element) {
if(this.element && typeof document !== "undefined") {
this.subscriptions.push(UIkit.util.on(document, 'hide', '#' + this.id, () => {
this.cancelOutput.emit(true);
}));