feat: following badge
This commit is contained in:
parent
f7051ed46b
commit
f23493742b
10 changed files with 67 additions and 23 deletions
|
|
@ -9,7 +9,7 @@ import { useTranslation } from 'react-i18next'
|
|||
export default function Followings({ pubkey }: { pubkey: string }) {
|
||||
const { t } = useTranslation()
|
||||
const { pubkey: accountPubkey } = useNostr()
|
||||
const { followings: selfFollowings } = useFollowList()
|
||||
const { followingSet: selfFollowingSet } = useFollowList()
|
||||
const { followings, isFetching } = useFetchFollowings(pubkey)
|
||||
|
||||
return (
|
||||
|
|
@ -18,7 +18,7 @@ export default function Followings({ pubkey }: { pubkey: string }) {
|
|||
className="flex gap-1 hover:underline w-fit items-center"
|
||||
>
|
||||
{accountPubkey === pubkey ? (
|
||||
selfFollowings.length
|
||||
selfFollowingSet.size
|
||||
) : isFetching ? (
|
||||
<Loader className="animate-spin size-4" />
|
||||
) : (
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue