-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathchatroom.page.html
39 lines (31 loc) · 1.1 KB
/
chatroom.page.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
<ion-header>
<ion-toolbar>
<ion-buttons slot="start">
<ion-button color="light" (click)="goBack()">
<ion-icon name="arrow-back"></ion-icon>
</ion-button>
</ion-buttons>
<ion-title>Discussion avec {{ hisName}}</ion-title>
</ion-toolbar>
</ion-header>
<ion-content>
<ion-card *ngFor="let message of messagesArray; let i = index"
[ngClass]="{'blue': message.mode === 'sent',
'orange': message.mode === 'received',
'meAgain': message.mode === 'meAgain',
'hisAgain': message.mode === 'hisAgain'}">
{{message.msg}}
<p id='time'>{{message.time}}</p>
</ion-card>
<form (ngSubmit)='sendMessage()'>
<ion-item>
<ion-input name='input' [(ngModel)]='Input'>
</ion-input>
</ion-item>
<ion-fab horizontal='end'>
<ion-fab-button (click)='sendMessage()'>
<ion-icon name='send'></ion-icon>
</ion-fab-button>
</ion-fab>
</form>
</ion-content>