Merge pull request #18855 from ramonlsouza/add-reactions-userlist
fix: user reactions do not appear in userlist
This commit is contained in:
commit
5b196afb3b
@ -42,6 +42,10 @@ export interface Voice {
|
||||
startTime: number;
|
||||
}
|
||||
|
||||
export interface Reaction {
|
||||
reactionEmoji: string;
|
||||
}
|
||||
|
||||
export interface User {
|
||||
userId: string;
|
||||
extId: string;
|
||||
@ -66,4 +70,5 @@ export interface User {
|
||||
size: number;
|
||||
away: boolean;
|
||||
raiseHand: boolean;
|
||||
reaction: Reaction;
|
||||
}
|
||||
|
@ -108,6 +108,8 @@ const UserListItem: React.FC<UserListItemProps> = ({ user, lockSettings }) => {
|
||||
: <Icon iconName={normalizeEmojiName('away')} />;
|
||||
} if (user.emoji !== 'none' && user.emoji !== 'notAway') {
|
||||
return <Icon iconName={normalizeEmojiName(user.emoji)} />;
|
||||
} if (user.reaction && user.reaction.reactionEmoji !== 'none') {
|
||||
return user.reaction.reactionEmoji;
|
||||
} if (user.name && userAvatarFiltered.length === 0) {
|
||||
return user.name.toLowerCase().slice(0, 2);
|
||||
} return '';
|
||||
|
@ -53,6 +53,9 @@ export const USER_LIST_SUBSCRIPTION = gql`subscription Users($offset: Int!, $lim
|
||||
shortName
|
||||
currentlyInRoom
|
||||
}
|
||||
reaction {
|
||||
reactionEmoji
|
||||
}
|
||||
}
|
||||
}`;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user