Press n or j to go to the next uncovered block, b, p or k for the previous block.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 | 2x 2x 2x 13x 13x 13x 13x | import { SetMutationError } from "features/connections/friends"; import AddFriendButton from "features/connections/friends/AddFriendButton"; import { User } from "proto/api_pb"; import PendingFriendReqButton from "./PendingFriendReqButton"; interface FriendActionsProps { user: User.AsObject; setMutationError: SetMutationError; } export default function FriendActions({ user, setMutationError, }: FriendActionsProps) { Iif (user.friends === User.FriendshipStatus.NOT_FRIENDS) { return ( <AddFriendButton userId={user.userId} setMutationError={setMutationError} /> ); } else Iif ( user.pendingFriendRequest && user.pendingFriendRequest.sent === false ) { return ( <PendingFriendReqButton friendRequest={user.pendingFriendRequest} setMutationError={setMutationError} /> ); } else { return null; } } |