1 import PropTypes from 'prop-types';
2 import React from 'react';
3 import { Button, Col, Container, Row } from 'react-bootstrap';
4 import { withTranslation } from 'react-i18next';
6 import Box from './Box';
7 import EditStreamLinkButton from './EditStreamLinkButton';
8 import Participation from './Participation';
9 import Icon from '../common/Icon';
10 import i18n from '../../i18n';
12 const Profile = ({ user }) => <Container>
13 <h1>{user.username}</h1>
16 <h2>{i18n.t('users.discordTag')}</h2>
17 <Box discriminator user={user} />
20 <h2>{i18n.t('users.streamLink')}</h2>
24 href={user.stream_link}
26 variant="outline-twitch"
33 i18n.t('users.noStream')
36 <EditStreamLinkButton user={user} />
40 <h2>{i18n.t('users.tournaments')}</h2>
41 <Participation user={user} />
47 user: PropTypes.shape({
48 participation: PropTypes.arrayOf(PropTypes.shape({
50 stream_link: PropTypes.string,
51 username: PropTypes.string,
55 export default withTranslation()(Profile);