fix: hide follow button when not loginned
This commit is contained in:
parent
d2c4d62cf5
commit
2004445e81
|
@ -22,7 +22,7 @@ async function toggleFollow() {
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<button
|
<button
|
||||||
v-if="!isSelf"
|
v-if="!isSelf && currentUser"
|
||||||
flex gap-1 items-center h-fit rounded hover="op100 text-white b-orange" group
|
flex gap-1 items-center h-fit rounded hover="op100 text-white b-orange" group
|
||||||
@click="toggleFollow"
|
@click="toggleFollow"
|
||||||
>
|
>
|
||||||
|
|
|
@ -49,66 +49,68 @@ const toggleBlockDomain = async () => {
|
||||||
</CommonDropdownItem>
|
</CommonDropdownItem>
|
||||||
</NuxtLink>
|
</NuxtLink>
|
||||||
|
|
||||||
<template v-if="!isSelf">
|
<template v-if="currentUser">
|
||||||
<CommonDropdownItem icon="i-ri:at-line" @click="mentionUser(account)">
|
<template v-if="!isSelf">
|
||||||
Mention @{{ account.acct }}
|
<CommonDropdownItem icon="i-ri:at-line" @click="mentionUser(account)">
|
||||||
</CommonDropdownItem>
|
Mention @{{ account.acct }}
|
||||||
<CommonDropdownItem icon="i-ri:message-3-line" @click="directMessageUser(account)">
|
</CommonDropdownItem>
|
||||||
Direct message @{{ account.acct }}
|
<CommonDropdownItem icon="i-ri:message-3-line" @click="directMessageUser(account)">
|
||||||
</CommonDropdownItem>
|
Direct message @{{ account.acct }}
|
||||||
|
</CommonDropdownItem>
|
||||||
|
|
||||||
<CommonDropdownItem v-if="!relationship?.muting" icon="i-ri:volume-up-fill" @click="toggleMute">
|
<CommonDropdownItem v-if="!relationship?.muting" icon="i-ri:volume-up-fill" @click="toggleMute">
|
||||||
Mute @{{ account.acct }}
|
Mute @{{ account.acct }}
|
||||||
</CommonDropdownItem>
|
</CommonDropdownItem>
|
||||||
<CommonDropdownItem v-else icon="i-ri:volume-mute-line" @click="toggleMute">
|
<CommonDropdownItem v-else icon="i-ri:volume-mute-line" @click="toggleMute">
|
||||||
Unmute @{{ account.acct }}
|
Unmute @{{ account.acct }}
|
||||||
</CommonDropdownItem>
|
</CommonDropdownItem>
|
||||||
|
|
||||||
<CommonDropdownItem v-if="!relationship?.blocking" icon="i-ri:forbid-2-line" @click="toggleBlockUser">
|
<CommonDropdownItem v-if="!relationship?.blocking" icon="i-ri:forbid-2-line" @click="toggleBlockUser">
|
||||||
Block @{{ account.acct }}
|
Block @{{ account.acct }}
|
||||||
</CommonDropdownItem>
|
</CommonDropdownItem>
|
||||||
<CommonDropdownItem v-else icon="i-ri:checkbox-circle-line" @click="toggleBlockUser">
|
<CommonDropdownItem v-else icon="i-ri:checkbox-circle-line" @click="toggleBlockUser">
|
||||||
Unblock @{{ account.acct }}
|
Unblock @{{ account.acct }}
|
||||||
</CommonDropdownItem>
|
</CommonDropdownItem>
|
||||||
|
|
||||||
<CommonDropdownItem
|
<CommonDropdownItem
|
||||||
v-if="!relationship?.domainBlocking"
|
v-if="!relationship?.domainBlocking"
|
||||||
icon="i-ri:shut-down-line"
|
icon="i-ri:shut-down-line"
|
||||||
@click="toggleBlockDomain"
|
@click="toggleBlockDomain"
|
||||||
>
|
>
|
||||||
Block domain {{ getServerName(account) }}
|
Block domain {{ getServerName(account) }}
|
||||||
</CommonDropdownItem>
|
</CommonDropdownItem>
|
||||||
<CommonDropdownItem v-else icon="i-ri:restart-line" @click="toggleBlockDomain">
|
<CommonDropdownItem v-else icon="i-ri:restart-line" @click="toggleBlockDomain">
|
||||||
Unblock domain {{ getServerName(account) }}
|
Unblock domain {{ getServerName(account) }}
|
||||||
</CommonDropdownItem>
|
</CommonDropdownItem>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<template v-else>
|
<template v-else>
|
||||||
<NuxtLink to="/pinned">
|
<NuxtLink to="/pinned">
|
||||||
<CommonDropdownItem icon="i-ri:pushpin-line">
|
<CommonDropdownItem icon="i-ri:pushpin-line">
|
||||||
Pinned
|
Pinned
|
||||||
</CommonDropdownItem>
|
</CommonDropdownItem>
|
||||||
</NuxtLink>
|
</NuxtLink>
|
||||||
<NuxtLink to="/favourites">
|
<NuxtLink to="/favourites">
|
||||||
<CommonDropdownItem icon="i-ri:heart-3-line">
|
<CommonDropdownItem icon="i-ri:heart-3-line">
|
||||||
Favourites
|
Favourites
|
||||||
</CommonDropdownItem>
|
</CommonDropdownItem>
|
||||||
</NuxtLink>
|
</NuxtLink>
|
||||||
<NuxtLink to="/mutes">
|
<NuxtLink to="/mutes">
|
||||||
<CommonDropdownItem icon="i-ri:volume-mute-line">
|
<CommonDropdownItem icon="i-ri:volume-mute-line">
|
||||||
Muted users
|
Muted users
|
||||||
</CommonDropdownItem>
|
</CommonDropdownItem>
|
||||||
</NuxtLink>
|
</NuxtLink>
|
||||||
<NuxtLink to="/blocks">
|
<NuxtLink to="/blocks">
|
||||||
<CommonDropdownItem icon="i-ri:forbid-2-line">
|
<CommonDropdownItem icon="i-ri:forbid-2-line">
|
||||||
Blocked users
|
Blocked users
|
||||||
</CommonDropdownItem>
|
</CommonDropdownItem>
|
||||||
</NuxtLink>
|
</NuxtLink>
|
||||||
<NuxtLink to="/domain_blocks">
|
<NuxtLink to="/domain_blocks">
|
||||||
<CommonDropdownItem icon="i-ri:shut-down-line">
|
<CommonDropdownItem icon="i-ri:shut-down-line">
|
||||||
Blocked domains
|
Blocked domains
|
||||||
</CommonDropdownItem>
|
</CommonDropdownItem>
|
||||||
</NuxtLink>
|
</NuxtLink>
|
||||||
|
</template>
|
||||||
</template>
|
</template>
|
||||||
</template>
|
</template>
|
||||||
</CommonDropdown>
|
</CommonDropdown>
|
||||||
|
|
Loading…
Reference in a new issue