Fixed collaborator avatars

This commit is contained in:
Jori Lallo
2017-09-10 23:14:32 -07:00
parent 9aa49deeeb
commit d73f2e856e

View File

@ -25,15 +25,20 @@ const Collaborators = function({ document }: { document: Document }) {
return (
<Avatars>
<Tooltip tooltip={tooltip} placement="bottom">
<StyledTooltip tooltip={tooltip} placement="bottom">
{collaborators.map(user => (
<Avatar key={user.id} src={user.avatarUrl} />
))}
</Tooltip>
</StyledTooltip>
</Avatars>
);
};
const StyledTooltip = styled(Tooltip)`
display: flex;
flex-direction: row-reverse;
`;
const Avatars = styled(Flex)`
flex-direction: row-reverse;
height: 26px;
@ -45,7 +50,7 @@ const Avatar = styled.img`
flex-shrink: 0;
border-radius: 50%;
border: 2px solid ${color.white};
margin-right: -13px;
margin-right: -10px;
&:first-child {
margin-right: 0;