2019-02-26 14:51:04 +11:00
|
|
|
<template>
|
|
|
|
<basic-user-card :user="user">
|
2019-02-28 03:58:29 +11:00
|
|
|
<div class="follow-card-content-container">
|
2019-07-05 17:17:44 +10:00
|
|
|
<span
|
|
|
|
v-if="!noFollowsYou && user.follows_you"
|
|
|
|
class="faint"
|
|
|
|
>
|
2019-02-27 03:00:25 +11:00
|
|
|
{{ isMe ? $t('user_card.its_you') : $t('user_card.follows_you') }}
|
|
|
|
</span>
|
2019-04-12 06:34:46 +10:00
|
|
|
<template v-if="!loggedIn">
|
2019-07-05 17:17:44 +10:00
|
|
|
<div
|
|
|
|
v-if="!user.following"
|
|
|
|
class="follow-card-follow-button"
|
|
|
|
>
|
2019-04-12 06:34:46 +10:00
|
|
|
<RemoteFollow :user="user" />
|
|
|
|
</div>
|
|
|
|
</template>
|
|
|
|
<template v-else>
|
2019-10-18 00:19:52 +11:00
|
|
|
<FollowButton
|
|
|
|
:user="user"
|
2019-10-18 04:24:54 +11:00
|
|
|
class="follow-card-follow-button"
|
2019-10-18 00:19:52 +11:00
|
|
|
:label-following="$t('user_card.follow_unfollow')"
|
|
|
|
/>
|
2019-04-12 06:34:46 +10:00
|
|
|
</template>
|
2019-02-28 03:58:29 +11:00
|
|
|
</div>
|
2019-02-26 14:51:04 +11:00
|
|
|
</basic-user-card>
|
|
|
|
</template>
|
|
|
|
|
|
|
|
<script src="./follow_card.js"></script>
|
2019-02-28 03:58:29 +11:00
|
|
|
|
|
|
|
<style lang="scss">
|
2019-03-22 06:03:54 +11:00
|
|
|
.follow-card {
|
|
|
|
&-content-container {
|
|
|
|
flex-shrink: 0;
|
|
|
|
display: flex;
|
|
|
|
flex-direction: row;
|
|
|
|
justify-content: space-between;
|
|
|
|
flex-wrap: wrap;
|
|
|
|
line-height: 1.5em;
|
|
|
|
}
|
2019-02-28 03:58:29 +11:00
|
|
|
|
2019-03-22 06:03:54 +11:00
|
|
|
&-follow-button {
|
2019-02-28 03:58:29 +11:00
|
|
|
margin-top: 0.5em;
|
|
|
|
margin-left: auto;
|
|
|
|
width: 10em;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
</style>
|