Skip to content

Commit 082e56c

Browse files
committed
Update src/components/Room.vue
Include avatars with messages
1 parent 296f284 commit 082e56c

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

src/components/Room.vue

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,11 @@
44
<v-list two-line subheader>
55
<v-subheader>Messages</v-subheader>
66
<v-list-tile v-for="(thread, index) in Threads" :key="index">
7+
<v-list-tile-avatar color="grey lighten-4">
8+
<img :src="thread.photoURL" alt="avatar">
9+
</v-list-tile-avatar>
710
<v-list-tile-content>
8-
<v-list-tile-title>{{thread.message}} - <i>{{thread.username}}</i></v-list-tile-title>
11+
<v-list-tile-title>{{thread.message}} </v-list-tile-title>
912
</v-list-tile-content>
1013
<v-list-tile-action>
1114
<v-icon color="black" @click="remove(thread['.key'])">delete</v-icon>
@@ -31,10 +34,6 @@ import Thread from '@/models/Thread'
3134
import General from '@/mixin/room'
3235
3336
export default {
34-
created () {
35-
this.Thread.uid = this.$auth.user().uid
36-
this.Thread.username = this.$auth.user().displayName
37-
},
3837
mixins: [General],
3938
data () {
4039
return {

0 commit comments

Comments
 (0)