Move userProfile link to methods

This commit is contained in:
Maxim Filippov 2018-12-17 02:52:27 +03:00
parent 5f10c5e786
commit ea6977cd4d
4 changed files with 10 additions and 10 deletions

View File

@ -11,9 +11,6 @@ const chatPanel = {
computed: {
messages () {
return this.$store.state.chat.messages
},
userProfileLink (user) {
return generateProfileLink(user.id, user.screen_name)
}
},
methods: {
@ -23,6 +20,9 @@ const chatPanel = {
},
togglePanel () {
this.collapsed = !this.collapsed
},
userProfileLink (user) {
return generateProfileLink(user.id, user.screen_name)
}
}
}

View File

@ -21,6 +21,9 @@ const Notification = {
methods: {
toggleUserExpanded () {
this.userExpanded = !this.userExpanded
},
userProfileLink (user) {
return generateProfileLink(user.id, user.screen_name)
}
},
computed: {
@ -31,9 +34,6 @@ const Notification = {
const highlight = this.$store.state.config.highlight
const user = this.notification.action.user
return highlightStyle(highlight[user.screen_name])
},
userProfileLink (user) {
return generateProfileLink(user.id, user.screen_name)
}
}
}

View File

@ -29,9 +29,7 @@ const UserCard = {
denyUser () {
this.$store.state.api.backendInteractor.denyUser(this.user.id)
this.$store.dispatch('removeFollowRequest', this.user)
}
},
computed: {
},
userProfileLink (user) {
return generateProfileLink(user.id, user.screen_name)
}

View File

@ -92,7 +92,9 @@ const WhoToFollowPanel = {
},
suggestionsEnabled () {
return this.$store.state.instance.suggestionsEnabled
},
}
},
methods: {
userProfileLink (id, name) {
return generateProfileLink(id, name)
}