summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorLouis Chemineau <louis@chmn.me>2023-04-11 12:39:05 +0200
committerLouis Chemineau <louis@chmn.me>2023-04-11 12:39:05 +0200
commit2e47357d95a30adf491452ad67d40964cf80926a (patch)
treef6a9cacfaa3d8fb1aa379bdd97ae98bb18f631ef /src
parent9d01a2da2d223aa28452ec84b9041d92edd24b0e (diff)
Display post/following/followers count for external accounts
Signed-off-by: Louis Chemineau <louis@chmn.me>
Diffstat (limited to 'src')
-rw-r--r--src/components/ProfileInfo.vue19
1 files changed, 13 insertions, 6 deletions
diff --git a/src/components/ProfileInfo.vue b/src/components/ProfileInfo.vue
index 6ebdbead..ed2e384b 100644
--- a/src/components/ProfileInfo.vue
+++ b/src/components/ProfileInfo.vue
@@ -31,20 +31,19 @@
:disable-tooltip="true"
:size="128" />
<h2>{{ displayName }}</h2>
- <!-- TODO: we have no details, timeline and follower list for non-local accounts for now -->
- <ul v-if="isLocal" class="user-profile__info user-profile__sections">
+ <ul class="user-profile__info user-profile__sections">
<li>
- <router-link :to="{ name: 'profile', params: { account: uid } }" class="icon-category-monitoring">
+ <router-link :class="{ disabled: !isLocal }" :to="{ name: 'profile', params: { account: uid } }" class="icon-category-monitoring">
{{ accountInfo.statuses_count }} {{ t('social', 'posts') }}
</router-link>
</li>
<li>
- <router-link :to="{ name: 'profile.following', params: { account: uid } }" class="icon-category-social">
+ <router-link :class="{ disabled: !isLocal }" :to="{ name: 'profile.following', params: { account: uid } }" class="icon-category-social">
{{ accountInfo.following_count }} {{ t('social', 'following') }}
</router-link>
</li>
<li>
- <router-link :to="{ name: 'profile.followers', params: { account: uid } }" class="icon-category-social">
+ <router-link :class="{ disabled: !isLocal }" :to="{ name: 'profile.followers', params: { account: uid } }" class="icon-category-social">
{{ accountInfo.followers_count }} {{ t('social', 'followers') }}
</router-link>
</li>
@@ -58,7 +57,7 @@
</p>
<!-- Hack to render note safely -->
- <MessageContent v-if="accountInfo.note" class="user-profile__note" :item="{content: accountInfo.note, tag: [], mentions: []}" />
+ <MessageContent v-if="accountInfo.note" class="user-profile__note user-profile__info" :item="{content: accountInfo.note, tag: [], mentions: []}" />
<FollowButton class="user-profile__info" :account="accountInfo.acct" :uid="uid" />
<NcButton v-if="serverData.public"
@@ -184,6 +183,14 @@ export default {
opacity: 1;
border-bottom: 1px solid var(--color-main-text);
}
+
+ &.disabled {
+ opacity: 1;
+ border-bottom: none;
+ text-decoration: none;
+ cursor: auto;
+ pointer-events: none;
+ }
}
}
}