akkoma-fe/src/components/follow_card/follow_card.js

31 lines
748 B
JavaScript
Raw Normal View History

2019-02-26 03:51:04 +00:00
import BasicUserCard from '../basic_user_card/basic_user_card.vue'
import RemoteFollow from '../remote_follow/remote_follow.vue'
2019-10-17 13:19:52 +00:00
import FollowButton from '../follow_button/follow_button.vue'
import RemoveFollowerButton from '../remove_follower_button/remove_follower_button.vue'
2019-02-26 03:51:04 +00:00
const FollowCard = {
props: [
'user',
'noFollowsYou'
],
components: {
BasicUserCard,
2019-10-17 13:19:52 +00:00
RemoteFollow,
FollowButton,
RemoveFollowerButton
2019-02-26 03:51:04 +00:00
},
computed: {
isMe () {
return this.$store.state.users.currentUser.id === this.user.id
},
loggedIn () {
return this.$store.state.users.currentUser
2020-04-21 20:27:51 +00:00
},
relationship () {
return this.$store.getters.relationship(this.user.id)
2019-02-26 03:51:04 +00:00
}
}
}
export default FollowCard