2026-06-04 21:56:25 +03:00
|
|
|
import BasicUserCard from 'src/components/basic_user_card/basic_user_card.vue'
|
|
|
|
|
import FollowButton from 'src/components/follow_button/follow_button.vue'
|
|
|
|
|
import RemoteFollow from 'src/components/remote_follow/remote_follow.vue'
|
|
|
|
|
import RemoveFollowerButton from 'src/components/remove_follower_button/remove_follower_button.vue'
|
2019-02-25 22:51:04 -05:00
|
|
|
|
2026-08-10 15:00:59 +03:00
|
|
|
import { useUsersStore } from 'src/stores/users.js'
|
|
|
|
|
|
2019-02-25 22:51:04 -05:00
|
|
|
const FollowCard = {
|
2026-01-06 16:22:52 +02:00
|
|
|
props: ['user', 'noFollowsYou'],
|
2019-02-25 22:51:04 -05:00
|
|
|
components: {
|
2019-03-19 14:36:27 -04:00
|
|
|
BasicUserCard,
|
2019-10-17 16:19:52 +03:00
|
|
|
RemoteFollow,
|
2022-09-17 11:36:34 -06:00
|
|
|
FollowButton,
|
2026-01-06 16:22:52 +02:00
|
|
|
RemoveFollowerButton,
|
2019-02-25 22:51:04 -05:00
|
|
|
},
|
|
|
|
|
computed: {
|
2026-01-06 16:22:52 +02:00
|
|
|
isMe() {
|
2026-09-01 13:50:21 +03:00
|
|
|
return useUsersStore().currentUser?.id === this.user.id
|
2019-03-19 14:36:27 -04:00
|
|
|
},
|
2026-01-06 16:22:52 +02:00
|
|
|
loggedIn() {
|
2026-08-10 15:00:59 +03:00
|
|
|
return useUsersStore().currentUser
|
2020-04-21 23:27:51 +03:00
|
|
|
},
|
2026-01-06 16:22:52 +02:00
|
|
|
relationship() {
|
2026-08-12 15:56:31 +03:00
|
|
|
return useUsersStore().relationships.get(this.user.id)
|
2026-01-06 16:22:52 +02:00
|
|
|
},
|
|
|
|
|
},
|
2019-02-25 22:51:04 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export default FollowCard
|