show raised hand state in reactions button

This commit is contained in:
Ramón Souza 2023-09-04 15:28:47 -03:00
parent e25abf7e34
commit ae159e8d1c

View File

@ -123,9 +123,18 @@ const ReactionsButton = (props) => {
customStyles: {...actionCustomStyles, width: 'auto'},
});
const icon = currentUserReaction === 'none' ? 'hand' : null;
const icon = !raiseHand && currentUserReaction === 'none' ? 'hand' : null;
const currentUserReactionEmoji = reactions.find(({ native }) => native === currentUserReaction);
const customIcon = !icon ? <Emoji key={currentUserReactionEmoji?.id} emoji={{ id: currentUserReactionEmoji?.id }} {...emojiProps} /> : null;
let customIcon = null;
if (raiseHand) {
customIcon = <Emoji key="hand" emoji={{ id: 'hand' }} {...emojiProps} />;
} else {
if (!icon) {
customIcon = <Emoji key={currentUserReactionEmoji?.id} emoji={{ id: currentUserReactionEmoji?.id }} {...emojiProps} />;
}
}
return (
<BBBMenu