From 3710c3b3ace21912de4b31ed0d1e0404ac2733b3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?H=C3=A5var=20Aamb=C3=B8=20Fosstveit?= Date: Tue, 5 May 2020 20:08:11 +0200 Subject: [PATCH] Add tooltips to participant list, fixes #299 --- .../MeetingDrawer/ParticipantList/ListMe.js | 35 ++-- .../MeetingDrawer/ParticipantList/ListPeer.js | 163 +++++++++++------- app/src/translations/cn.json | 1 + app/src/translations/cs.json | 1 + app/src/translations/de.json | 1 + app/src/translations/dk.json | 1 + app/src/translations/el.json | 1 + app/src/translations/en.json | 1 + app/src/translations/es.json | 1 + app/src/translations/fr.json | 1 + app/src/translations/hr.json | 1 + app/src/translations/hu.json | 1 + app/src/translations/it.json | 1 + app/src/translations/lv.json | 1 + app/src/translations/nb.json | 1 + app/src/translations/pl.json | 1 + app/src/translations/pt.json | 1 + app/src/translations/ro.json | 1 + app/src/translations/tr.json | 1 + app/src/translations/uk.json | 1 + 20 files changed, 138 insertions(+), 78 deletions(-) diff --git a/app/src/components/MeetingDrawer/ParticipantList/ListMe.js b/app/src/components/MeetingDrawer/ParticipantList/ListMe.js index a32412f..d230db2 100644 --- a/app/src/components/MeetingDrawer/ParticipantList/ListMe.js +++ b/app/src/components/MeetingDrawer/ParticipantList/ListMe.js @@ -6,6 +6,7 @@ import PropTypes from 'prop-types'; import * as appPropTypes from '../../appPropTypes'; import { useIntl } from 'react-intl'; import IconButton from '@material-ui/core/IconButton'; +import Tooltip from '@material-ui/core/Tooltip'; import PanIcon from '@material-ui/icons/PanTool'; import EmptyAvatar from '../../../images/avatar-empty.jpeg'; @@ -58,23 +59,31 @@ const ListMe = (props) =>
{settings.displayName}
- - { - e.stopPropagation(); - - roomClient.setRaisedHand(!me.raisedHand); - }} + placement='bottom' > - - + + { + e.stopPropagation(); + + roomClient.setRaisedHand(!me.raisedHand); + }} + > + + + ); }; diff --git a/app/src/components/MeetingDrawer/ParticipantList/ListPeer.js b/app/src/components/MeetingDrawer/ParticipantList/ListPeer.js index 914ae04..1aa70a1 100644 --- a/app/src/components/MeetingDrawer/ParticipantList/ListPeer.js +++ b/app/src/components/MeetingDrawer/ParticipantList/ListPeer.js @@ -7,6 +7,7 @@ import * as appPropTypes from '../../appPropTypes'; import { withRoomContext } from '../../../RoomContext'; import { useIntl } from 'react-intl'; import IconButton from '@material-ui/core/IconButton'; +import Tooltip from '@material-ui/core/Tooltip'; import VideocamIcon from '@material-ui/icons/Videocam'; import VideocamOffIcon from '@material-ui/icons/VideocamOff'; import VolumeUpIcon from '@material-ui/icons/VolumeUp'; @@ -99,90 +100,122 @@ const ListPeer = (props) => } { screenConsumer && - - { - e.stopPropagation(); - - screenVisible ? - roomClient.modifyPeerConsumer(peer.id, 'screen', true) : - roomClient.modifyPeerConsumer(peer.id, 'screen', false); - }} + placement='bottom' > - { screenVisible ? - - : - - } - + + { + e.stopPropagation(); + + screenVisible ? + roomClient.modifyPeerConsumer(peer.id, 'screen', true) : + roomClient.modifyPeerConsumer(peer.id, 'screen', false); + }} + > + { screenVisible ? + + : + + } + + } - - { - e.stopPropagation(); - - webcamEnabled ? - roomClient.modifyPeerConsumer(peer.id, 'webcam', true) : - roomClient.modifyPeerConsumer(peer.id, 'webcam', false); - }} + placement='bottom' > - { webcamEnabled ? - - : - - } - - - { - e.stopPropagation(); - - micEnabled ? - roomClient.modifyPeerConsumer(peer.id, 'mic', true) : - roomClient.modifyPeerConsumer(peer.id, 'mic', false); - }} - > - { micEnabled ? - - : - - } - - { isModerator && { e.stopPropagation(); - roomClient.kickPeer(peer.id); + webcamEnabled ? + roomClient.modifyPeerConsumer(peer.id, 'webcam', true) : + roomClient.modifyPeerConsumer(peer.id, 'webcam', false); }} > - + { webcamEnabled ? + + : + + } + + + + { + e.stopPropagation(); + + micEnabled ? + roomClient.modifyPeerConsumer(peer.id, 'mic', true) : + roomClient.modifyPeerConsumer(peer.id, 'mic', false); + }} + > + { micEnabled ? + + : + + } + + + { isModerator && + + + { + e.stopPropagation(); + + roomClient.kickPeer(peer.id); + }} + > + + + } {children} diff --git a/app/src/translations/cn.json b/app/src/translations/cn.json index e3b5597..3ead544 100644 --- a/app/src/translations/cn.json +++ b/app/src/translations/cn.json @@ -80,6 +80,7 @@ "tooltip.muteParticipant": null, "tooltip.muteParticipantVideo": null, "tooltip.raisedHand": null, + "tooltip.muteScreenSharing": null, "label.roomName": "房间名称", "label.chooseRoomButton": "继续", diff --git a/app/src/translations/cs.json b/app/src/translations/cs.json index fd3cc3c..cd16197 100644 --- a/app/src/translations/cs.json +++ b/app/src/translations/cs.json @@ -79,6 +79,7 @@ "tooltip.muteParticipant": null, "tooltip.muteParticipantVideo": null, "tooltip.raisedHand": null, + "tooltip.muteScreenSharing": null, "label.roomName": "Jméno místnosti", "label.chooseRoomButton": "Pokračovat", diff --git a/app/src/translations/de.json b/app/src/translations/de.json index 8a119ad..b5015d7 100644 --- a/app/src/translations/de.json +++ b/app/src/translations/de.json @@ -80,6 +80,7 @@ "tooltip.muteParticipant": null, "tooltip.muteParticipantVideo": null, "tooltip.raisedHand": null, + "tooltip.muteScreenSharing": null, "label.roomName": "Name des Raums", "label.chooseRoomButton": "Weiter", diff --git a/app/src/translations/dk.json b/app/src/translations/dk.json index 40e2698..9f99a55 100644 --- a/app/src/translations/dk.json +++ b/app/src/translations/dk.json @@ -80,6 +80,7 @@ "tooltip.muteParticipant": null, "tooltip.muteParticipantVideo": null, "tooltip.raisedHand": null, + "tooltip.muteScreenSharing": null, "label.roomName": "Værelsesnavn", "label.chooseRoomButton": "Fortsæt", diff --git a/app/src/translations/el.json b/app/src/translations/el.json index 2600ab2..47d5fe0 100644 --- a/app/src/translations/el.json +++ b/app/src/translations/el.json @@ -80,6 +80,7 @@ "tooltip.muteParticipant": null, "tooltip.muteParticipantVideo": null, "tooltip.raisedHand": null, + "tooltip.muteScreenSharing": null, "label.roomName": "Όνομα δωματίου", "label.chooseRoomButton": "Συνέχεια", diff --git a/app/src/translations/en.json b/app/src/translations/en.json index 19c46b4..c7447fe 100644 --- a/app/src/translations/en.json +++ b/app/src/translations/en.json @@ -80,6 +80,7 @@ "tooltip.muteParticipant": "Mute participant", "tooltip.muteParticipantVideo": "Mute participant video", "tooltip.raisedHand": "Raise hand", + "tooltip.muteScreenSharing": "Mute participant share", "label.roomName": "Room name", "label.chooseRoomButton": "Continue", diff --git a/app/src/translations/es.json b/app/src/translations/es.json index 4c8abea..a630e15 100644 --- a/app/src/translations/es.json +++ b/app/src/translations/es.json @@ -80,6 +80,7 @@ "tooltip.muteParticipant": null, "tooltip.muteParticipantVideo": null, "tooltip.raisedHand": null, + "tooltip.muteScreenSharing": null, "label.roomName": "Nombre de la sala", "label.chooseRoomButton": "Continuar", diff --git a/app/src/translations/fr.json b/app/src/translations/fr.json index 9148655..d36e238 100644 --- a/app/src/translations/fr.json +++ b/app/src/translations/fr.json @@ -80,6 +80,7 @@ "tooltip.muteParticipant": null, "tooltip.muteParticipantVideo": null, "tooltip.raisedHand": null, + "tooltip.muteScreenSharing": null, "label.roomName": "Nom de la salle", "label.chooseRoomButton": "Continuer", diff --git a/app/src/translations/hr.json b/app/src/translations/hr.json index 1f5ce55..68f8418 100644 --- a/app/src/translations/hr.json +++ b/app/src/translations/hr.json @@ -80,6 +80,7 @@ "tooltip.muteParticipant": "Utišaj sudionika", "tooltip.muteParticipantVideo": "Ne primaj video sudionika", "tooltip.raisedHand": "Podigni ruku", + "tooltip.muteScreenSharing": null, "label.roomName": "Naziv sobe", "label.chooseRoomButton": "Nastavi", diff --git a/app/src/translations/hu.json b/app/src/translations/hu.json index e185cfb..7c2ce89 100644 --- a/app/src/translations/hu.json +++ b/app/src/translations/hu.json @@ -80,6 +80,7 @@ "tooltip.muteParticipant": "Résztvevő némítása", "tooltip.muteParticipantVideo": "Résztvevő video némítása", "tooltip.raisedHand": "Jelentkezés", + "tooltip.muteScreenSharing": null, "label.roomName": "Konferencia", "label.chooseRoomButton": "Tovább", diff --git a/app/src/translations/it.json b/app/src/translations/it.json index 284c40e..b088fa9 100644 --- a/app/src/translations/it.json +++ b/app/src/translations/it.json @@ -79,6 +79,7 @@ "tooltip.muteParticipant": "Muta partecipante", "tooltip.muteParticipantVideo": "Ferma video partecipante", "tooltip.raisedHand": "Mano alzata", + "tooltip.muteScreenSharing": null, "label.roomName": "Nome della stanza", "label.chooseRoomButton": "Continua", diff --git a/app/src/translations/lv.json b/app/src/translations/lv.json index dce2204..e981b35 100644 --- a/app/src/translations/lv.json +++ b/app/src/translations/lv.json @@ -79,6 +79,7 @@ "tooltip.muteParticipant": "Noklusināt dalībnieku", "tooltip.muteParticipantVideo": "Atslēgt dalībnieka video", "tooltip.raisedHand": "Pacelt roku", + "tooltip.muteScreenSharing": null, "label.roomName": "Sapulces telpas nosaukums (ID)", "label.chooseRoomButton": "Turpināt", diff --git a/app/src/translations/nb.json b/app/src/translations/nb.json index 2965f59..77c4ef5 100644 --- a/app/src/translations/nb.json +++ b/app/src/translations/nb.json @@ -80,6 +80,7 @@ "tooltip.muteParticipant": "Demp deltaker", "tooltip.muteParticipantVideo": "Demp deltakervideo", "tooltip.raisedHand": "Rekk opp hånden", + "tooltip.muteScreenSharing": "Demp deltaker skjermdeling", "label.roomName": "Møtenavn", "label.chooseRoomButton": "Fortsett", diff --git a/app/src/translations/pl.json b/app/src/translations/pl.json index 14f5146..ffb41ec 100644 --- a/app/src/translations/pl.json +++ b/app/src/translations/pl.json @@ -80,6 +80,7 @@ "tooltip.muteParticipant": null, "tooltip.muteParticipantVideo": null, "tooltip.raisedHand": null, + "tooltip.muteScreenSharing": null, "label.roomName": "Nazwa konferencji", "label.chooseRoomButton": "Kontynuuj", diff --git a/app/src/translations/pt.json b/app/src/translations/pt.json index 89a8da1..3861c01 100644 --- a/app/src/translations/pt.json +++ b/app/src/translations/pt.json @@ -80,6 +80,7 @@ "tooltip.muteParticipant": null, "tooltip.muteParticipantVideo": null, "tooltip.raisedHand": null, + "tooltip.muteScreenSharing": null, "label.roomName": "Nome da sala", "label.chooseRoomButton": "Continuar", diff --git a/app/src/translations/ro.json b/app/src/translations/ro.json index 49936b0..ca906de 100644 --- a/app/src/translations/ro.json +++ b/app/src/translations/ro.json @@ -80,6 +80,7 @@ "tooltip.muteParticipant": null, "tooltip.muteParticipantVideo": null, "tooltip.raisedHand": null, + "tooltip.muteScreenSharing": null, "label.roomName": "Numele camerei", "label.chooseRoomButton": "Continuare", diff --git a/app/src/translations/tr.json b/app/src/translations/tr.json index 3fb115f..b53d1ea 100644 --- a/app/src/translations/tr.json +++ b/app/src/translations/tr.json @@ -80,6 +80,7 @@ "tooltip.muteParticipant": null, "tooltip.muteParticipantVideo": null, "tooltip.raisedHand": null, + "tooltip.muteScreenSharing": null, "label.roomName": "Oda adı", "label.chooseRoomButton": "Devam", diff --git a/app/src/translations/uk.json b/app/src/translations/uk.json index 6c15f7a..d9ceaa8 100644 --- a/app/src/translations/uk.json +++ b/app/src/translations/uk.json @@ -80,6 +80,7 @@ "tooltip.muteParticipant": null, "tooltip.muteParticipantVideo": null, "tooltip.raisedHand": null, + "tooltip.muteScreenSharing": null, "label.roomName": "Назва кімнати", "label.chooseRoomButton": "Продовжити",