Permalink
Browse files

Step 12.21: Implement location message view

  • Loading branch information...
dotansimha authored and darkbasic committed Jan 24, 2017
1 parent 0172a8a commit 8d3c5e3f776a86f9ab15b4b7ccfcba7fe36da656
Showing with 6 additions and 0 deletions.
  1. +6 −0 src/pages/messages/messages.html
@@ -19,6 +19,12 @@
<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>
<div *ngIf="message.type == 'location'" class="message-content message-content-text">
<agm-map [zoom]="getLocation(message.content).zoom" [latitude]="getLocation(message.content).lat" [longitude]="getLocation(message.content).lng">
<agm-marker [latitude]="getLocation(message.content).lat" [longitude]="getLocation(message.content).lng"></agm-marker>
</agm-map>
</div>
<span class="message-timestamp">{{ message.createdAt | amDateFormat: 'HH:mm' }}</span>
</div>
</div>

0 comments on commit 8d3c5e3

Please sign in to comment.