feat: Adds visitors count in participants pane.
This commit is contained in:
parent
f83840a3bc
commit
50c4748d40
|
@ -759,6 +759,7 @@
|
||||||
"headings": {
|
"headings": {
|
||||||
"lobby": "Lobby ({{count}})",
|
"lobby": "Lobby ({{count}})",
|
||||||
"participantsList": "Meeting participants ({{count}})",
|
"participantsList": "Meeting participants ({{count}})",
|
||||||
|
"visitors": "Visitors ({{count}})",
|
||||||
"waitingLobby": "Waiting in lobby ({{count}})"
|
"waitingLobby": "Waiting in lobby ({{count}})"
|
||||||
},
|
},
|
||||||
"search": "Search participants",
|
"search": "Search participants",
|
||||||
|
|
|
@ -30,6 +30,9 @@ import MeetingParticipantItems from './MeetingParticipantItems';
|
||||||
|
|
||||||
const useStyles = makeStyles()(theme => {
|
const useStyles = makeStyles()(theme => {
|
||||||
return {
|
return {
|
||||||
|
headingW: {
|
||||||
|
color: theme.palette.warning02
|
||||||
|
},
|
||||||
heading: {
|
heading: {
|
||||||
color: theme.palette.text02,
|
color: theme.palette.text02,
|
||||||
|
|
||||||
|
@ -103,11 +106,16 @@ function MeetingParticipants({
|
||||||
const askUnmuteText = t('participantsPane.actions.askUnmute');
|
const askUnmuteText = t('participantsPane.actions.askUnmute');
|
||||||
const muteParticipantButtonText = t('dialog.muteParticipantButton');
|
const muteParticipantButtonText = t('dialog.muteParticipantButton');
|
||||||
const isBreakoutRoom = useSelector(isInBreakoutRoom);
|
const isBreakoutRoom = useSelector(isInBreakoutRoom);
|
||||||
|
const visitorsCount = useSelector((state: IReduxState) => state['features/visitors'].count);
|
||||||
|
|
||||||
const { classes: styles } = useStyles();
|
const { classes: styles, cx } = useStyles();
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
|
<div className = { cx(styles.heading, styles.headingW) }>
|
||||||
|
{visitorsCount && visitorsCount > 0
|
||||||
|
&& t('participantsPane.headings.visitors', { count: visitorsCount })}
|
||||||
|
</div>
|
||||||
<div className = { styles.heading }>
|
<div className = { styles.heading }>
|
||||||
{currentRoom?.name
|
{currentRoom?.name
|
||||||
? `${currentRoom.name} (${participantsCount})`
|
? `${currentRoom.name} (${participantsCount})`
|
||||||
|
|
Loading…
Reference in New Issue