fix(messaging): bring cursor pointer back for av.

This commit is contained in:
Paul Makles 2022-01-15 15:59:25 +00:00
parent 271a126a3f
commit 8eb2f4e7e3
3 changed files with 9 additions and 3 deletions

View file

@ -130,7 +130,7 @@ const Message = observer(
} }
onMouseEnter={() => setAnimate(true)} onMouseEnter={() => setAnimate(true)}
onMouseLeave={() => setAnimate(false)}> onMouseLeave={() => setAnimate(false)}>
<MessageInfo> <MessageInfo click={typeof head !== "undefined"}>
{head ? ( {head ? (
<UserIcon <UserIcon
url={message.generateMasqAvatarURL()} url={message.generateMasqAvatarURL()}

View file

@ -134,7 +134,7 @@ export default styled.div<BaseMessageProps>`
} }
`; `;
export const MessageInfo = styled.div` export const MessageInfo = styled.div<{ click: boolean }>`
width: 62px; width: 62px;
display: flex; display: flex;
flex-shrink: 0; flex-shrink: 0;
@ -183,6 +183,12 @@ export const MessageInfo = styled.div`
margin-right: 0.5em; margin-right: 0.5em;
color: var(--tertiary-foreground); color: var(--tertiary-foreground);
} }
${(props) =>
props.click &&
css`
cursor: pointer;
`}
`; `;
export const MessageContent = styled.div` export const MessageContent = styled.div`

View file

@ -147,7 +147,7 @@ export const SystemMessage = observer(
: undefined : undefined
}> }>
{!hideInfo && ( {!hideInfo && (
<MessageInfo> <MessageInfo click={false}>
<MessageDetail message={message} position="left" /> <MessageDetail message={message} position="left" />
<SystemMessageIcon className="systemIcon" /> <SystemMessageIcon className="systemIcon" />
</MessageInfo> </MessageInfo>