Skip to content

Commit

Permalink
feat(reactions): Added heart reaction
Browse files Browse the repository at this point in the history
* Added heart reaction feature

* Edits to preserve alphabetical sorting

* Changed the position of hide self view checkbox

* undid irrelevant changes made

* Fixed CSS issue + tooltip text
  • Loading branch information
KingRain authored Nov 13, 2024
1 parent 49cf632 commit 71de1d1
Show file tree
Hide file tree
Showing 6 changed files with 28 additions and 2 deletions.
4 changes: 2 additions & 2 deletions css/_reactions-menu.scss
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
@use 'sass:math';

.reactions-menu {
width: 280px;
width: 330px;
background: #242528;
box-shadow: 0px 3px 16px rgba(0, 0, 0, 0.6), 0px 0px 4px 1px rgba(0, 0, 0, 0.25);
border-radius: 6px;
padding: 16px;

&.with-gif {
width: 328px;
width: 380px;

.reactions-row .toolbox-button:last-of-type {
top: 3px;
Expand Down
3 changes: 3 additions & 0 deletions lang/main.json
Original file line number Diff line number Diff line change
Expand Up @@ -1246,6 +1246,7 @@
"lobbyButton": "Enable/disable lobby mode",
"localRecording": "Toggle local recording controls",
"lockRoom": "Toggle meeting password",
"love": "Heart",
"lowerHand": "Lower your hand",
"moreActions": "More actions",
"moreActionsMenu": "More actions menu",
Expand Down Expand Up @@ -1335,6 +1336,7 @@
"lobbyButtonEnable": "Enable lobby mode",
"login": "Log-in",
"logout": "Log-out",
"love": "Heart",
"lowerYourHand": "Lower your hand",
"moreActions": "More actions",
"moreOptions": "More options",
Expand All @@ -1360,6 +1362,7 @@
"raiseYourHand": "Raise your hand",
"reactionBoo": "Send boo reaction",
"reactionClap": "Send clap reaction",
"reactionHeart": "Send heart reaction",
"reactionLaugh": "Send laugh reaction",
"reactionLike": "Send thumbs up reaction",
"reactionSilence": "Send silence reaction",
Expand Down
16 changes: 16 additions & 0 deletions react/features/reactions/constants.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import {
BOO_SOUND_FILES,
CLAP_SOUND_FILES,
HEART_SOUND_FILES,
LAUGH_SOUND_FILES,
LIKE_SOUND_FILES,
SILENCE_SOUND_FILES,
Expand Down Expand Up @@ -92,6 +93,14 @@ export const SURPRISE_SOUND_ID = `${REACTION_SOUND}_SURPRISE_`;
*/
export const SILENCE_SOUND_ID = `${REACTION_SOUND}_SILENCE_`;

/**
* The audio ID of the audio element for which the {@link playAudio} action is
* triggered when a new raise hand event is received.
*
* @type {string}
*/
export const HEART_SOUND_ID = `${REACTION_SOUND}_HEART_`;

/**
* The audio ID of the audio element for which the {@link playAudio} action is
* triggered when a new raise hand event is received.
Expand Down Expand Up @@ -167,6 +176,13 @@ export const REACTIONS: IReactions = {
shortcutChar: 'S',
soundId: SILENCE_SOUND_ID,
soundFiles: SILENCE_SOUND_FILES
},
love: {
message: ':heart:',
emoji: '💖',
shortcutChar: 'H',
soundId: HEART_SOUND_ID,
soundFiles: HEART_SOUND_FILES
}
};

Expand Down
7 changes: 7 additions & 0 deletions react/features/reactions/sounds.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,13 @@ export const SURPRISE_SOUND_FILES = new Array(3).fill('reactions-surprise.mp3');
*/
export const SILENCE_SOUND_FILES = new Array(3).fill('reactions-crickets.mp3');

/**
* The name of the bundled audio file which will be played for the heart reaction sound.
*
* @type {Array<string>}
*/
export const HEART_SOUND_FILES = new Array(3).fill('reactions-love.mp3');

/**
* The name of the bundled audio file which will be played for the raise hand sound.
*
Expand Down
Binary file added sounds/reactions-love.mp3
Binary file not shown.
Binary file added sounds/reactions-love.opus
Binary file not shown.

0 comments on commit 71de1d1

Please sign in to comment.