From ff7bf2d174c815422d9ada3fdcac9145a094f6f3 Mon Sep 17 00:00:00 2001 From: "tiago.kayaya" Date: Fri, 3 Sep 2021 17:02:42 +0100 Subject: [PATCH] save --- src/app/pages/chat/chat.page.ts | 5 +++++ src/app/pages/chat/group-messages/group-messages.page.ts | 5 +++++ src/app/pages/chat/messages/messages.page.ts | 6 ++++++ 3 files changed, 16 insertions(+) diff --git a/src/app/pages/chat/chat.page.ts b/src/app/pages/chat/chat.page.ts index a9117c386..2ec8c44fb 100644 --- a/src/app/pages/chat/chat.page.ts +++ b/src/app/pages/chat/chat.page.ts @@ -120,6 +120,11 @@ export class ChatPage implements OnInit { ){ this.loggedUserChat = authService.ValidatedUserChat['data']; this.headers = new HttpHeaders(); + window.onresize = (event) => { + if( window.innerWidth > 701){ + this.modalController.dismiss(); + } + }; } diff --git a/src/app/pages/chat/group-messages/group-messages.page.ts b/src/app/pages/chat/group-messages/group-messages.page.ts index c40abb91c..ab82b2491 100644 --- a/src/app/pages/chat/group-messages/group-messages.page.ts +++ b/src/app/pages/chat/group-messages/group-messages.page.ts @@ -54,6 +54,11 @@ export class GroupMessagesPage implements OnInit, AfterViewInit, OnDestroy { this.loggedUserChat = authService.ValidatedUserChat['data']; this.isGroupCreated = true; this.roomId = this.navParams.get('roomId'); + window.onresize = (event) => { + if( window.innerWidth > 701){ + this.modalController.dismiss(); + } + }; } ngOnInit() { diff --git a/src/app/pages/chat/messages/messages.page.ts b/src/app/pages/chat/messages/messages.page.ts index b0810150b..0408cc09e 100644 --- a/src/app/pages/chat/messages/messages.page.ts +++ b/src/app/pages/chat/messages/messages.page.ts @@ -60,6 +60,12 @@ export class MessagesPage implements OnInit, AfterViewInit, OnDestroy { }); */ this.loggedUser = authService.ValidatedUserChat['data']; this.roomId = this.navParams.get('roomId'); + + window.onresize = (event) => { + if( window.innerWidth > 701){ + this.modalController.dismiss(); + } + }; } ngOnInit() {