username of repeat chat messages is display:none (#3101)

users who want to show repeat usernames can inject the following CSS:
[class^="ChatUserMessage_repeatUser"]{display:flex !important;}

Co-authored-by: janWilejan <>
This commit is contained in:
janWilejan 2023-06-28 16:58:07 +00:00 committed by GitHub
parent a582ba1eb2
commit ce724fa073
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 11 additions and 8 deletions

View File

@ -26,6 +26,11 @@ $p-v-size: 2px;
font-weight: 600; font-weight: 600;
} }
.repeatUser {
@extend .user;
display: none;
}
.userBadges { .userBadges {
margin-left: 3px; margin-left: 3px;
} }

View File

@ -98,14 +98,12 @@ export const ChatUserMessage: FC<ChatUserMessageProps> = ({
> >
<div className={styles.background} style={{ color }} /> <div className={styles.background} style={{ color }} />
{!sameUserAsLast && (
<UserTooltip user={user}> <UserTooltip user={user}>
<div className={styles.user} style={{ color }}> <div className={sameUserAsLast ? styles.repeatUser : styles.user} style={{ color }}>
<span className={styles.userName}>{displayName}</span> <span className={styles.userName}>{displayName}</span>
<span className={styles.userBadges}>{badgeNodes}</span> <span className={styles.userBadges}>{badgeNodes}</span>
</div> </div>
</UserTooltip> </UserTooltip>
)}
<Tooltip title={formattedTimestamp} mouseEnterDelay={1}> <Tooltip title={formattedTimestamp} mouseEnterDelay={1}>
<Interweave <Interweave
className={styles.message} className={styles.message}