File size: 747 Bytes
f5071ca |
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 |
import React from 'react';
import styled from 'styled-components';
import AtIcon from '../icons/At';
import HashtagIcon from '../icons/Hashtag';
const StyledChannelName = styled.div`
display: flex;
align-items: center;
svg {
color: #8a8e94;
margin-right: 3px;
}
span {
margin-top: 3px;
font-weight: ${props => (props.isHeader ? 600 : 500)};
font-size: ${props => (props.isHeader ? '1.1em' : '1em')};
color: ${props => props.textColor || '#72767d'};
}
`;
const ChannelName = ({ name, textColor, isHeader, isUser }) => (
<StyledChannelName isHeader={isHeader} textColor={textColor}>
{isUser ? <AtIcon /> : <HashtagIcon />}
<span>{name}</span>
</StyledChannelName>
);
export default ChannelName;
|