next-ucap-messenger/projects/ucap-webmessenger-app/src/app/layouts/messenger/components/left-sidenav/chat.component.html
leejh 72c704e9af 기능 추가 :: 대화 > 대화목록 :: context menu 기능 추가 및 기능 구현.
1. 대화방 열기,
2. 대화방 알림 토들
3. 대화방 나가기.
2019-10-23 17:03:34 +09:00

56 lines
1.5 KiB
HTML

<div>
<mat-form-field>
<input
matInput
#inputSearch
type="text"
maxlength="20"
placeholder="대화방 이름 검색"
value=""
(keydown.enter)="onKeyDownEnter(inputSearch.value)"
/>
<button
mat-button
matSuffix
mat-icon-button
aria-label="Clear"
(click)="inputSearch.value = ''; searchWord = ''; isSearch = false"
>
<mat-icon>close</mat-icon>
</button>
</mat-form-field>
</div>
<div>
<ucap-room-list-item
*ngFor="let room of getRoomList()"
[loginRes]="loginRes"
[roomInfo]="room"
[roomUserInfo]="getRoomUserList(room)"
[sessionVerinfo]="sessionVerinfo"
(click)="onSelectedRoom(room)"
(contextmenu)="onContextMenuChat($event, room)"
>
</ucap-room-list-item>
</div>
<div
style="visibility: hidden; position: fixed"
[style.left]="chatContextMenuPosition.x"
[style.top]="chatContextMenuPosition.y"
#chatContextMenuTrigger="matMenuTrigger"
[matMenuTriggerFor]="chatContextMenu"
></div>
<mat-menu #chatContextMenu="matMenu" [overlapTrigger]="false">
<ng-template matMenuContent let-roomInfo="roomInfo">
<button mat-menu-item (click)="onSelectedRoom(roomInfo)">
대화방 열기
</button>
<button mat-menu-item (click)="onClickToggleAlarm(roomInfo)">
대화방 알람 {{ roomInfo.receiveAlarm ? '끄기' : '켜기' }}
</button>
<button mat-menu-item (click)="onClickExit(roomInfo)">
대화방 나가기
</button>
</ng-template>
</mat-menu>