Skip to content

Commit 57b9856

Browse files
author
Lukas Ruebbelke
authored
Merge pull request onehungrymind#3 from onehungrymind/feature/price
added price to list items
2 parents a5fc1e0 + 0bf23d2 commit 57b9856

File tree

4 files changed

+16
-2
lines changed

4 files changed

+16
-2
lines changed

apps/dashboard/src/app/items/items-list/items-list.component.css

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,3 +5,7 @@ mat-list-item:not(:first-of-type) {
55
.symbol {
66
color: #777;
77
}
8+
9+
.price {
10+
float: right;
11+
}

apps/dashboard/src/app/items/items-list/items-list.component.html

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,13 @@ <h1>Items</h1>
99
<mat-list-item *ngFor="let item of items" (click)="selected.emit(item)" class="record">
1010
<h3 mat-line>{{item.name}}</h3>
1111
<button *ngIf="!readonly" mat-icon-button (click)="deleted.emit(item);$event.stopImmediatePropagation();">
12-
<mat-icon>close</mat-icon>
12+
<mat-icon>close</mat-icon>
1313
</button>
1414
<p mat-line>
15-
{{item.description}}
15+
{{item.description}}
16+
</p>
17+
<p class="price">
18+
{{item.price | currency}}
1619
</p>
1720
</mat-list-item>
1821
</mat-list>
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
11
mat-list-item:not(:first-of-type) {
22
border-top: 1px solid #efefef;
33
}
4+
5+
.price {
6+
float: right;
7+
}

apps/dashboard/src/app/widgets/widgets-list/widgets-list.component.html

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,9 @@ <h3 mat-line>{{widget.name}}</h3>
1414
<p mat-line>
1515
{{widget.description}}
1616
</p>
17+
<p class="price">
18+
{{widget.price | currency}}
19+
</p>
1720
</mat-list-item>
1821
</mat-list>
1922
</mat-card-content>

0 commit comments

Comments
 (0)