Add offline indicator (#66)
This commit is contained in:
parent
f7916f283f
commit
2a38552281
|
@ -105,7 +105,7 @@ export function Member({
|
||||||
style={{
|
style={{
|
||||||
backgroundImage: member.avatar ? `url(${member.avatar})` : "unset",
|
backgroundImage: member.avatar ? `url(${member.avatar})` : "unset",
|
||||||
}}
|
}}
|
||||||
className={isOnline ? "online" : ""}
|
className={isOnline ? "online" : "offline"}
|
||||||
>
|
>
|
||||||
{!member.avatar && <UserIcon memberView={true} />}
|
{!member.avatar && <UserIcon memberView={true} />}
|
||||||
</MemberIcon>
|
</MemberIcon>
|
||||||
|
@ -182,12 +182,26 @@ const MemberIcon = styled(Icon)`
|
||||||
background-position: center;
|
background-position: center;
|
||||||
flex-shrink: 0;
|
flex-shrink: 0;
|
||||||
|
|
||||||
|
&.offline {
|
||||||
|
&::after {
|
||||||
|
content: "";
|
||||||
|
position: absolute;
|
||||||
|
right: -1px;
|
||||||
|
bottom: -2px;
|
||||||
|
width: 7px;
|
||||||
|
height: 7px;
|
||||||
|
border-radius: 50%;
|
||||||
|
background-color: ${({ theme }) => theme.secondary};
|
||||||
|
border: 2px solid ${({ theme }) => theme.bodyBackgroundColor};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
&.online {
|
&.online {
|
||||||
&::after {
|
&::after {
|
||||||
content: "";
|
content: "";
|
||||||
position: absolute;
|
position: absolute;
|
||||||
right: -1px;
|
right: -1px;
|
||||||
bottom: 1px;
|
bottom: -2px;
|
||||||
width: 7px;
|
width: 7px;
|
||||||
height: 7px;
|
height: 7px;
|
||||||
border-radius: 50%;
|
border-radius: 50%;
|
||||||
|
|
Loading…
Reference in New Issue