diff --git a/projects/ucap-webmessenger-app/src/app/layouts/messenger/components/messages.component.html b/projects/ucap-webmessenger-app/src/app/layouts/messenger/components/messages.component.html index 12664ece..f0bf30c8 100644 --- a/projects/ucap-webmessenger-app/src/app/layouts/messenger/components/messages.component.html +++ b/projects/ucap-webmessenger-app/src/app/layouts/messenger/components/messages.component.html @@ -124,7 +124,7 @@ -
+
user.seq !== this.loginRes.userSeq) + .map(user => user.name); + } + if (!!this.roomInfo.roomName && '' !== this.roomInfo.roomName.trim()) { return this.roomInfo.roomName; - } else if (this.roomInfo.roomType === RoomType.Mytalk) { - return 'MyTalk'; } else { return this.userInfoList .filter(user => { @@ -243,6 +251,22 @@ export class MessagesComponent implements OnInit, OnDestroy, AfterViewInit { } } + getEnableSend() { + if (!this.roomInfo) { + return false; + } + + if ( + this.roomInfo.roomType === RoomType.Bot || + this.roomInfo.roomType === RoomType.Allim || + this.roomInfo.roomType === RoomType.Link + ) { + return false; + } + + return true; + } + getConvertTimer(timerInterval: number, unit: number = 1) { if (timerInterval >= 0 && timerInterval < 60 * unit) { return Math.floor((timerInterval / 1) * unit) + ' 초'; @@ -266,7 +290,9 @@ export class MessagesComponent implements OnInit, OnDestroy, AfterViewInit { focusReplyInput(): void { setTimeout(() => { - this.chatForm.focus(); + if (!!this.chatForm) { + this.chatForm.focus(); + } }); }