2023-04-16 08:00:42 +03:00
|
|
|
import { Avatar, Col, Row } from 'antd';
|
2022-09-07 10:00:28 +03:00
|
|
|
import React, { FC } from 'react';
|
2022-12-13 09:54:29 +03:00
|
|
|
import cn from 'classnames';
|
2022-09-03 21:38:52 +03:00
|
|
|
import { Follower } from '../../../../interfaces/follower';
|
2022-09-07 10:00:28 +03:00
|
|
|
import styles from './SingleFollower.module.scss';
|
2022-07-12 04:29:58 +03:00
|
|
|
|
2022-09-07 10:00:28 +03:00
|
|
|
export type SingleFollowerProps = {
|
2022-07-12 04:29:58 +03:00
|
|
|
follower: Follower;
|
2022-09-07 10:00:28 +03:00
|
|
|
};
|
2022-07-12 04:29:58 +03:00
|
|
|
|
2022-09-07 10:00:28 +03:00
|
|
|
export const SingleFollower: FC<SingleFollowerProps> = ({ follower }) => (
|
2023-04-16 08:32:57 +03:00
|
|
|
<div>
|
2022-09-07 10:00:28 +03:00
|
|
|
<a href={follower.link} target="_blank" rel="noreferrer">
|
2023-04-16 08:32:57 +03:00
|
|
|
<Row wrap={false} className={cn([styles.follower, 'followers-follower'])}>
|
2023-04-16 08:00:42 +03:00
|
|
|
<Col span={6} className={styles.avatarColumn}>
|
|
|
|
<Avatar
|
|
|
|
src={follower.image}
|
|
|
|
alt={(follower.name || follower.username).charAt(0).toUpperCase()}
|
|
|
|
className={styles.avatar}
|
|
|
|
size="large"
|
|
|
|
>
|
|
|
|
{(follower.name || follower.username).charAt(0).toUpperCase()}
|
2023-03-24 05:11:08 +03:00
|
|
|
</Avatar>
|
2022-09-07 10:00:28 +03:00
|
|
|
</Col>
|
2023-04-16 08:00:42 +03:00
|
|
|
<Col>
|
|
|
|
<Row className={styles.username}>
|
|
|
|
{follower.name || follower.username.split('@', 2)[0]}
|
2023-02-05 07:45:31 +03:00
|
|
|
</Row>
|
2023-04-16 08:00:42 +03:00
|
|
|
<Row className={styles.account}>{follower.username}</Row>
|
2022-09-07 10:00:28 +03:00
|
|
|
</Col>
|
|
|
|
</Row>
|
|
|
|
</a>
|
|
|
|
</div>
|
|
|
|
);
|