2019-11-15 10:13:18 +09:00
|
|
|
<div class="chat-messages" #scrollMe>
|
2019-10-31 18:12:38 +09:00
|
|
|
<!-- <div class="message-row" *ngIf="eventRemain">
|
|
|
|
<button mat-button (click)="onClickMore($event)">이전 대화 보기</button>
|
|
|
|
</div> -->
|
2019-09-23 14:23:24 +09:00
|
|
|
<!-- MESSAGE -->
|
2019-10-15 15:02:00 +09:00
|
|
|
<div
|
|
|
|
*ngFor="let message of messages; let i = index"
|
|
|
|
class="message-row"
|
|
|
|
[ngClass]="{
|
2019-10-08 13:31:33 +09:00
|
|
|
me: message.senderSeq === loginRes.userSeq,
|
|
|
|
contact: message.senderSeq !== loginRes.userSeq
|
2019-10-15 15:02:00 +09:00
|
|
|
}"
|
|
|
|
>
|
2019-10-24 10:07:30 +09:00
|
|
|
<ucap-chat-message-box-date-splitter
|
|
|
|
*ngIf="getDateSplitter(i)"
|
|
|
|
class="date-splitter"
|
|
|
|
[message]="message"
|
|
|
|
>
|
|
|
|
</ucap-chat-message-box-date-splitter>
|
2019-10-14 17:28:43 +09:00
|
|
|
|
2019-10-24 10:07:30 +09:00
|
|
|
<div class="chat-row">
|
|
|
|
<div
|
|
|
|
*ngIf="getIsInformation(message); then information; else contents"
|
|
|
|
></div>
|
|
|
|
<ng-template #information>
|
|
|
|
<ng-container
|
|
|
|
class="bubble"
|
|
|
|
*ngIf="message.type !== EventType.NotificationForTimerRoom"
|
|
|
|
[ngSwitch]="message.type"
|
|
|
|
>
|
|
|
|
<ucap-chat-message-box-information
|
|
|
|
*ngSwitchCase="EventType.Join"
|
|
|
|
[message]="message"
|
2019-10-29 19:06:25 +09:00
|
|
|
class="information-msg"
|
2019-10-24 10:07:30 +09:00
|
|
|
>
|
|
|
|
</ucap-chat-message-box-information>
|
|
|
|
<ucap-chat-message-box-information
|
|
|
|
*ngSwitchCase="EventType.Exit"
|
|
|
|
[message]="message"
|
2019-11-01 13:03:57 +09:00
|
|
|
class="information-msg"
|
2019-10-24 10:07:30 +09:00
|
|
|
>
|
|
|
|
</ucap-chat-message-box-information>
|
|
|
|
<ucap-chat-message-box-information
|
|
|
|
*ngSwitchCase="EventType.RenameRoom"
|
|
|
|
[message]="message"
|
2019-11-21 18:02:11 +09:00
|
|
|
class="information-msg"
|
2019-10-24 10:07:30 +09:00
|
|
|
>
|
|
|
|
</ucap-chat-message-box-information>
|
|
|
|
<ucap-chat-message-box-information
|
|
|
|
*ngSwitchCase="EventType.GuideForRoomTimerChanged"
|
|
|
|
[message]="message"
|
|
|
|
[senderName]="getUserName(message.senderSeq)"
|
2019-11-21 18:02:11 +09:00
|
|
|
class="information-msg"
|
2019-10-24 10:07:30 +09:00
|
|
|
>
|
|
|
|
</ucap-chat-message-box-information>
|
|
|
|
</ng-container>
|
|
|
|
</ng-template>
|
|
|
|
<ng-template #contents>
|
2019-10-25 13:04:21 +09:00
|
|
|
<div
|
|
|
|
*ngIf="getUserProfile(message.senderSeq) != ''"
|
|
|
|
class="profile-img"
|
|
|
|
>
|
2019-10-24 10:07:30 +09:00
|
|
|
<!-- <img
|
|
|
|
class="avatar"
|
|
|
|
style="width: 50px; height: 50px;"
|
|
|
|
[src]="
|
|
|
|
profileImageRoot
|
|
|
|
| ucapUiImaage
|
|
|
|
: {
|
|
|
|
path: getUserProfile(message.senderSeq),
|
|
|
|
default: 'assets/images/img_nophoto_50.png'
|
|
|
|
}
|
|
|
|
| async
|
|
|
|
"
|
|
|
|
/> -->
|
2019-10-25 13:04:21 +09:00
|
|
|
<img
|
|
|
|
class="avatar"
|
|
|
|
style="width: 50px; height: 50px;"
|
2019-11-05 13:45:30 +09:00
|
|
|
ucapImage
|
2019-10-25 13:04:21 +09:00
|
|
|
[base]="profileImageRoot"
|
|
|
|
[path]="getUserProfile(message.senderSeq)"
|
|
|
|
[default]="'assets/images/img_nophoto_50.png'"
|
2019-11-08 13:35:39 +09:00
|
|
|
(click)="onClickOpenProfile($event, getUerInfo(message.senderSeq))"
|
2019-10-25 13:04:21 +09:00
|
|
|
/>
|
|
|
|
<!-- <ucap-ui-imaage
|
2019-10-24 10:07:30 +09:00
|
|
|
[style]="'width: 50px; height: 50px;'"
|
|
|
|
[imageClass]="'avatar'"
|
|
|
|
[base]="profileImageRoot"
|
|
|
|
[path]="getUserProfile(message.senderSeq)"
|
|
|
|
[default]="'assets/images/img_nophoto_50.png'"
|
2019-10-25 13:04:21 +09:00
|
|
|
></ucap-ui-imaage> -->
|
2019-10-21 13:20:14 +09:00
|
|
|
</div>
|
|
|
|
|
2019-10-24 10:07:30 +09:00
|
|
|
<div class="message-main">
|
|
|
|
<div class="chat-name">
|
|
|
|
{{ getUserName(message.senderSeq) }}
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="bubble">
|
|
|
|
<ng-container
|
|
|
|
class="bubble"
|
|
|
|
*ngIf="message.type !== EventType.NotificationForTimerRoom"
|
|
|
|
[ngSwitch]="message.type"
|
2019-10-21 18:10:39 +09:00
|
|
|
>
|
2019-10-24 10:07:30 +09:00
|
|
|
<ucap-chat-message-box-mass
|
|
|
|
*ngSwitchCase="EventType.MassText"
|
|
|
|
[message]="message"
|
|
|
|
(massDetail)="onMassDetail($event)"
|
2019-10-25 17:51:33 +09:00
|
|
|
(contextmenu)="onContextMenuMessage($event, message)"
|
2019-10-24 10:07:30 +09:00
|
|
|
>
|
|
|
|
</ucap-chat-message-box-mass>
|
|
|
|
<ucap-chat-message-box-file
|
|
|
|
*ngSwitchCase="EventType.File"
|
2019-10-29 18:11:31 +09:00
|
|
|
[eventInfoStatus]="eventInfoStatus"
|
2019-10-24 10:07:30 +09:00
|
|
|
[message]="message"
|
|
|
|
(save)="onSave($event)"
|
2019-11-07 15:46:02 +09:00
|
|
|
(fileViewer)="onFileViewer($event)"
|
2019-10-25 17:51:33 +09:00
|
|
|
(contextmenu)="onContextMenuMessage($event, message)"
|
2019-10-24 10:07:30 +09:00
|
|
|
>
|
|
|
|
</ucap-chat-message-box-file>
|
|
|
|
<ucap-chat-message-box-sticker
|
|
|
|
*ngSwitchCase="EventType.Sticker"
|
|
|
|
[message]="message"
|
2019-10-25 17:51:33 +09:00
|
|
|
(contextmenu)="onContextMenuMessage($event, message)"
|
2019-10-24 10:07:30 +09:00
|
|
|
>
|
|
|
|
</ucap-chat-message-box-sticker>
|
|
|
|
<ucap-chat-message-box-recall
|
|
|
|
*ngSwitchCase="EventType.RecalledMessage"
|
|
|
|
></ucap-chat-message-box-recall>
|
|
|
|
<ucap-chat-message-box-text
|
|
|
|
*ngSwitchCase="EventType.Character"
|
|
|
|
[message]="message"
|
|
|
|
(contextmenu)="onContextMenuMessage($event, message)"
|
|
|
|
>
|
|
|
|
</ucap-chat-message-box-text>
|
|
|
|
<div *ngSwitchDefault>
|
|
|
|
mass-translation
|
|
|
|
<ucap-chat-message-box-mass-translation></ucap-chat-message-box-mass-translation>
|
|
|
|
notice
|
|
|
|
<ucap-chat-message-box-notice></ucap-chat-message-box-notice>
|
|
|
|
<ucap-chat-message-box-schedule></ucap-chat-message-box-schedule>
|
|
|
|
translation
|
|
|
|
<ucap-chat-message-box-translation></ucap-chat-message-box-translation>
|
|
|
|
video-conference
|
|
|
|
<ucap-chat-message-box-video-conference></ucap-chat-message-box-video-conference>
|
2019-10-11 11:40:35 +09:00
|
|
|
|
2019-10-24 10:07:30 +09:00
|
|
|
<div class="message">
|
|
|
|
{{ message.sentMessage }}
|
|
|
|
</div>
|
2019-10-21 18:10:39 +09:00
|
|
|
</div>
|
2019-10-24 10:07:30 +09:00
|
|
|
</ng-container>
|
|
|
|
</div>
|
2019-10-21 18:10:39 +09:00
|
|
|
</div>
|
2019-10-15 11:50:23 +09:00
|
|
|
|
2019-10-24 10:07:30 +09:00
|
|
|
<div class="time secondary-text">
|
2019-10-30 16:22:49 +09:00
|
|
|
<ul>
|
2019-11-22 09:03:32 +09:00
|
|
|
<li *ngIf="isShowUnreadCount">{{ getUnreadCount(message) }}</li>
|
2019-10-30 16:22:49 +09:00
|
|
|
<li>
|
2019-11-13 16:30:15 +09:00
|
|
|
{{ moment(message.sendDate).toDate() | date: 'a hh:mm' }}
|
2019-10-30 16:22:49 +09:00
|
|
|
</li>
|
|
|
|
</ul>
|
2019-10-24 10:07:30 +09:00
|
|
|
</div>
|
|
|
|
</ng-template>
|
|
|
|
</div>
|
2019-09-23 14:23:24 +09:00
|
|
|
</div>
|
2019-10-25 13:04:21 +09:00
|
|
|
</div>
|