react-icons/fi#FiUserMinus TypeScript Examples

The following examples show how to use react-icons/fi#FiUserMinus. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: Member.tsx    From convoychat with GNU General Public License v3.0 6 votes vote down vote up
Member: React.FC<MemberProps> = ({ user, onActionClick }) => {
  const { user: currentUser } = useAuthContext();
  const isCurrentUser = currentUser.id === user.id;

  return (
    <StyledMember>
      <Flex gap="medium" align="center" justify="space-between" nowrap>
        <Flex gap="medium" align="center">
          <Avatar size={35} src={user?.avatarUrl} />
          <Flex direction="column" nowrap>
            <span className="userinfo__displayname">{user?.name}</span>
            <small className="textcolor--gray" title={user?.username}>
              {user?.username?.slice(0, 15)}...
            </small>
          </Flex>
        </Flex>

        {!isCurrentUser && (
          <Tooltip
            placement="top-left"
            message={<span>Remove member from group</span>}
          >
            <IconButton
              icon={<FiUserMinus />}
              onClick={() => onActionClick(user)}
            />
          </Tooltip>
        )}
      </Flex>
    </StyledMember>
  );
}