Skip to content

Commit

Permalink
Step 6.20: Update the template to use grouped messages
Browse files Browse the repository at this point in the history
  • Loading branch information
DAB0mB committed Feb 13, 2017
1 parent 58e8de4 commit 8b1c333
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion client/imports/pages/messages/messages.html
Expand Up @@ -15,11 +15,15 @@

<ion-content padding class="messages-page-content">
<ion-scroll scrollY="true" class="messages">
<div *ngFor="let message of messages | async" class="message-wrapper">
<div *ngFor="let day of messagesDayGroups | async" class="day-wrapper">
<div *ngFor="let message of day.messages" class="message-wrapper">
<div [class]="'message message-' + message.ownership">
<div *ngIf="message.type == 'text'" class="message-content message-content-text">{{message.content}}</div>
<span class="message-timestamp">{{ message.createdAt | amDateFormat: 'HH:mm' }}</span>
</div>
</div>

<div *ngIf="!day.today" class="day-timestamp">{{day.timestamp}}</div>
</div>
</ion-scroll>
</ion-content>
Expand Down

0 comments on commit 8b1c333

Please sign in to comment.