File tree Expand file tree Collapse file tree 3 files changed +11
-5
lines changed Expand file tree Collapse file tree 3 files changed +11
-5
lines changed Original file line number Diff line number Diff line change @@ -58,6 +58,8 @@ based on whether the list is in "dense" mode.
58
58
flex-direction : column ;
59
59
width : 100% ;
60
60
padding : 0 $md-list-side-padding ;
61
+ box-sizing : border-box ;
62
+ overflow : hidden ;
61
63
62
64
& :first-child {
63
65
padding : 0 ;
@@ -78,6 +80,7 @@ based on whether the list is in "dense" mode.
78
80
[md-list-avatar ] {
79
81
width : $md-list-avatar-size ;
80
82
height : $md-list-avatar-size ;
83
+ border-radius : 50% ;
81
84
}
82
85
}
83
86
Original file line number Diff line number Diff line change @@ -15,7 +15,6 @@ <h2>Normal lists</h2>
15
15
16
16
< md-list >
17
17
< md-list-item *ngFor ="#contact of contacts ">
18
- < img md-list-avatar src ="" alt ="">
19
18
< h3 md-line > {{contact.name}}</ h3 >
20
19
< p md-line *ngIf ="thirdLine "> extra line</ p >
21
20
< p md-line class ="demo-secondary-text "> {{contact.headline}}</ p >
@@ -24,6 +23,7 @@ <h3 md-line>{{contact.name}}</h3>
24
23
25
24
< md-list >
26
25
< md-list-item *ngFor ="#message of messages ">
26
+ < img md-list-avatar [src] ="message.image " alt ="Image of {{message.from}} ">
27
27
< h3 md-line > {{message.from}}</ h3 >
28
28
< p md-line >
29
29
< span > {{message.subject}} -- </ span >
@@ -51,14 +51,14 @@ <h2>Dense lists</h2>
51
51
52
52
< md-list dense >
53
53
< md-list-item *ngFor ="#contact of contacts ">
54
- < img md-list-avatar src ="" alt ="">
55
54
< h3 md-line > {{contact.name}}</ h3 >
56
55
< p md-line class ="demo-secondary-text "> {{contact.headline}}</ p >
57
56
</ md-list-item >
58
57
</ md-list >
59
58
60
59
< md-list dense >
61
60
< md-list-item *ngFor ="#message of messages ">
61
+ < img md-list-avatar [src] ="message.image " alt ="Image of {{message.from}} ">
62
62
< h3 md-line > {{message.from}}</ h3 >
63
63
< p md-line > {{message.subject}} </ p >
64
64
< p md-line class ="demo-secondary-text "> {{message.message}} </ p >
Original file line number Diff line number Diff line change @@ -25,17 +25,20 @@ export class ListDemo {
25
25
{
26
26
from : 'Nancy' ,
27
27
subject : 'Brunch?' ,
28
- message : 'Did you want to go on Sunday? I was thinking that might work.'
28
+ message : 'Did you want to go on Sunday? I was thinking that might work.' ,
29
+ image : 'https://angular.io/resources/images/bios/julie-ralph.jpg'
29
30
} ,
30
31
{
31
32
from : 'Mary' ,
32
33
subject : 'Summer BBQ' ,
33
- message : 'Wish I could come, but I have some prior obligations.'
34
+ message : 'Wish I could come, but I have some prior obligations.' ,
35
+ image : 'https://angular.io/resources/images/bios/juleskremer.jpg'
34
36
} ,
35
37
{
36
38
from : 'Bobby' ,
37
39
subject : 'Oui oui' ,
38
- message : 'Do you have Paris reservations for the 15th? I just booked!'
40
+ message : 'Do you have Paris reservations for the 15th? I just booked!' ,
41
+ image : 'https://angular.io/resources/images/bios/jelbourn.jpg'
39
42
}
40
43
] ;
41
44
You can’t perform that action at this time.
0 commit comments