mirror of
https://github.com/PrimalHQ/primal-web-app.git
synced 2024-10-01 17:31:13 +00:00
Allow following yourself in you are not already
This commit is contained in:
parent
18f95a5e83
commit
5d08eeb097
@ -47,7 +47,7 @@ const PeopleList: Component<{ people: PrimalUser[], label: string, id?: string }
|
||||
{truncateNpub(person?.npub)}
|
||||
</div>
|
||||
</div>
|
||||
<Show when={account?.publicKey !== person.pubkey}>
|
||||
<Show when={account?.publicKey !== person.pubkey || !account?.following.includes(person.pubkey)}>
|
||||
<FollowButton person={person} />
|
||||
</Show>
|
||||
</A>
|
||||
|
@ -75,3 +75,7 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.placeholderDiv {
|
||||
width: 72px;
|
||||
}
|
||||
|
@ -59,7 +59,10 @@ const ProfileContact: Component<{
|
||||
</div>
|
||||
</div>
|
||||
</Show>
|
||||
<Show when={account?.publicKey !== props.profile?.pubkey}>
|
||||
<Show
|
||||
when={account?.publicKey !== props.profile?.pubkey || !account?.following.includes(props.profile?.pubkey || '')}
|
||||
fallback={<div class={styles.placeholderDiv}></div>}
|
||||
>
|
||||
<FollowButton person={props.profile} postAction={props.postAction} />
|
||||
</Show>
|
||||
</div>
|
||||
|
@ -603,7 +603,7 @@ const Profile: Component = () => {
|
||||
</ButtonSecondary>
|
||||
</Show>
|
||||
|
||||
<Show when={account?.publicKey !== profile?.profileKey}>
|
||||
<Show when={!isCurrentUser() || !account?.following.includes(profile?.profileKey || '')}>
|
||||
<FollowButton person={profile?.userProfile} large={true} />
|
||||
</Show>
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user