Lint
parent
a691e82f3e
commit
209b545900
|
|
@ -60,7 +60,7 @@ export default class Spotlights extends EventEmitter
|
||||||
const oldIndex = this._unmutablePeerList.indexOf(peerId);
|
const oldIndex = this._unmutablePeerList.indexOf(peerId);
|
||||||
|
|
||||||
let index = oldIndex;
|
let index = oldIndex;
|
||||||
|
|
||||||
index++;
|
index++;
|
||||||
for (let i = 0; i < this._unmutablePeerList.length; i++)
|
for (let i = 0; i < this._unmutablePeerList.length; i++)
|
||||||
{
|
{
|
||||||
|
|
@ -94,7 +94,7 @@ export default class Spotlights extends EventEmitter
|
||||||
const oldIndex = this._unmutablePeerList.indexOf(peerId);
|
const oldIndex = this._unmutablePeerList.indexOf(peerId);
|
||||||
|
|
||||||
let index = oldIndex;
|
let index = oldIndex;
|
||||||
|
|
||||||
index--;
|
index--;
|
||||||
for (let i = 0; i < this._unmutablePeerList.length; i++)
|
for (let i = 0; i < this._unmutablePeerList.length; i++)
|
||||||
{
|
{
|
||||||
|
|
@ -119,7 +119,7 @@ export default class Spotlights extends EventEmitter
|
||||||
logger.debug('setPeerSpotlight() [peerId:"%s"]', peerId);
|
logger.debug('setPeerSpotlight() [peerId:"%s"]', peerId);
|
||||||
|
|
||||||
const index = this._selectedSpotlights.indexOf(peerId);
|
const index = this._selectedSpotlights.indexOf(peerId);
|
||||||
|
|
||||||
if (index !== -1)
|
if (index !== -1)
|
||||||
{
|
{
|
||||||
this._selectedSpotlights = [];
|
this._selectedSpotlights = [];
|
||||||
|
|
@ -177,7 +177,7 @@ export default class Spotlights extends EventEmitter
|
||||||
{
|
{
|
||||||
logger.debug(
|
logger.debug(
|
||||||
'room "newpeer" event [id: "%s"]', id);
|
'room "newpeer" event [id: "%s"]', id);
|
||||||
|
|
||||||
if (this._peerList.indexOf(id) === -1) // We don't have this peer in the list
|
if (this._peerList.indexOf(id) === -1) // We don't have this peer in the list
|
||||||
{
|
{
|
||||||
logger.debug('_handlePeer() | adding peer [peerId: "%s"]', id);
|
logger.debug('_handlePeer() | adding peer [peerId: "%s"]', id);
|
||||||
|
|
|
||||||
|
|
@ -9,7 +9,7 @@ export const addResponseMessage = (message) =>
|
||||||
type : 'ADD_NEW_RESPONSE_MESSAGE',
|
type : 'ADD_NEW_RESPONSE_MESSAGE',
|
||||||
payload : { message }
|
payload : { message }
|
||||||
});
|
});
|
||||||
|
|
||||||
export const addChatHistory = (chatHistory) =>
|
export const addChatHistory = (chatHistory) =>
|
||||||
({
|
({
|
||||||
type : 'ADD_CHAT_HISTORY',
|
type : 'ADD_CHAT_HISTORY',
|
||||||
|
|
|
||||||
|
|
@ -80,13 +80,13 @@ export const setAudioOutputInProgress = (flag) =>
|
||||||
type : 'SET_AUDIO_OUTPUT_IN_PROGRESS',
|
type : 'SET_AUDIO_OUTPUT_IN_PROGRESS',
|
||||||
payload : { flag }
|
payload : { flag }
|
||||||
});
|
});
|
||||||
|
|
||||||
export const setWebcamInProgress = (flag) =>
|
export const setWebcamInProgress = (flag) =>
|
||||||
({
|
({
|
||||||
type : 'SET_WEBCAM_IN_PROGRESS',
|
type : 'SET_WEBCAM_IN_PROGRESS',
|
||||||
payload : { flag }
|
payload : { flag }
|
||||||
});
|
});
|
||||||
|
|
||||||
export const setScreenShareInProgress = (flag) =>
|
export const setScreenShareInProgress = (flag) =>
|
||||||
({
|
({
|
||||||
type : 'SET_SCREEN_SHARE_IN_PROGRESS',
|
type : 'SET_SCREEN_SHARE_IN_PROGRESS',
|
||||||
|
|
|
||||||
|
|
@ -26,13 +26,13 @@ export const setPeerVideoInProgress = (peerId, flag) =>
|
||||||
type : 'SET_PEER_VIDEO_IN_PROGRESS',
|
type : 'SET_PEER_VIDEO_IN_PROGRESS',
|
||||||
payload : { peerId, flag }
|
payload : { peerId, flag }
|
||||||
});
|
});
|
||||||
|
|
||||||
export const setPeerAudioInProgress = (peerId, flag) =>
|
export const setPeerAudioInProgress = (peerId, flag) =>
|
||||||
({
|
({
|
||||||
type : 'SET_PEER_AUDIO_IN_PROGRESS',
|
type : 'SET_PEER_AUDIO_IN_PROGRESS',
|
||||||
payload : { peerId, flag }
|
payload : { peerId, flag }
|
||||||
});
|
});
|
||||||
|
|
||||||
export const setPeerScreenInProgress = (peerId, flag) =>
|
export const setPeerScreenInProgress = (peerId, flag) =>
|
||||||
({
|
({
|
||||||
type : 'SET_PEER_SCREEN_IN_PROGRESS',
|
type : 'SET_PEER_SCREEN_IN_PROGRESS',
|
||||||
|
|
|
||||||
|
|
@ -39,7 +39,7 @@ const ListLobbyPeer = (props) =>
|
||||||
const picture = peer.picture || EmptyAvatar;
|
const picture = peer.picture || EmptyAvatar;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<ListItem
|
<ListItem
|
||||||
className={classnames(classes.root)}
|
className={classnames(classes.root)}
|
||||||
key={peer.peerId}
|
key={peer.peerId}
|
||||||
button
|
button
|
||||||
|
|
|
||||||
|
|
@ -77,7 +77,7 @@ const LockDialog = ({
|
||||||
/>
|
/>
|
||||||
</DialogTitle>
|
</DialogTitle>
|
||||||
{ lobbyPeers.length > 0 ?
|
{ lobbyPeers.length > 0 ?
|
||||||
<List
|
<List
|
||||||
dense
|
dense
|
||||||
subheader={
|
subheader={
|
||||||
<ListSubheader component='div'>
|
<ListSubheader component='div'>
|
||||||
|
|
|
||||||
|
|
@ -286,9 +286,9 @@ const Me = (props) =>
|
||||||
defaultMessage : 'Start screen sharing'
|
defaultMessage : 'Start screen sharing'
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
const [
|
const [
|
||||||
screenShareTooltipOpen,
|
screenShareTooltipOpen,
|
||||||
screenShareTooltipSetOpen
|
screenShareTooltipSetOpen
|
||||||
] = React.useState(false);
|
] = React.useState(false);
|
||||||
|
|
||||||
const screenShareTooltipHandleClose = () =>
|
const screenShareTooltipHandleClose = () =>
|
||||||
|
|
@ -365,7 +365,7 @@ const Me = (props) =>
|
||||||
}}
|
}}
|
||||||
style={spacingStyle}
|
style={spacingStyle}
|
||||||
>
|
>
|
||||||
|
|
||||||
{ me.browser.platform !== 'mobile' && smallContainer &&
|
{ me.browser.platform !== 'mobile' && smallContainer &&
|
||||||
<div className={classnames(
|
<div className={classnames(
|
||||||
classes.ptt,
|
classes.ptt,
|
||||||
|
|
@ -442,8 +442,8 @@ const Me = (props) =>
|
||||||
className={classes.smallContainer}
|
className={classes.smallContainer}
|
||||||
disabled={!me.canSendMic || me.audioInProgress}
|
disabled={!me.canSendMic || me.audioInProgress}
|
||||||
color={
|
color={
|
||||||
micState === 'on' ?
|
micState === 'on' ?
|
||||||
settings.voiceActivatedUnmute && !me.isAutoMuted ?
|
settings.voiceActivatedUnmute && !me.isAutoMuted ?
|
||||||
'primary'
|
'primary'
|
||||||
: 'default'
|
: 'default'
|
||||||
: 'secondary'}
|
: 'secondary'}
|
||||||
|
|
@ -459,7 +459,7 @@ const Me = (props) =>
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{ micState === 'on' ?
|
{ micState === 'on' ?
|
||||||
<MicIcon
|
<MicIcon
|
||||||
color={me.isAutoMuted ? 'secondary' : 'primary'}
|
color={me.isAutoMuted ? 'secondary' : 'primary'}
|
||||||
style={{ opacity: noiseVolume }}
|
style={{ opacity: noiseVolume }}
|
||||||
/>
|
/>
|
||||||
|
|
@ -477,9 +477,9 @@ const Me = (props) =>
|
||||||
})}
|
})}
|
||||||
className={classes.fab}
|
className={classes.fab}
|
||||||
disabled={!me.canSendMic || me.audioInProgress}
|
disabled={!me.canSendMic || me.audioInProgress}
|
||||||
color={micState === 'on' ?
|
color={micState === 'on' ?
|
||||||
settings.voiceActivatedUnmute && !me.isAutoMuted? 'primary'
|
settings.voiceActivatedUnmute && !me.isAutoMuted? 'primary'
|
||||||
: 'default'
|
: 'default'
|
||||||
: 'secondary'}
|
: 'secondary'}
|
||||||
size='large'
|
size='large'
|
||||||
onClick={() =>
|
onClick={() =>
|
||||||
|
|
@ -561,9 +561,9 @@ const Me = (props) =>
|
||||||
}
|
}
|
||||||
</Tooltip>
|
</Tooltip>
|
||||||
{ me.browser.platform !== 'mobile' &&
|
{ me.browser.platform !== 'mobile' &&
|
||||||
<Tooltip open={screenShareTooltipOpen}
|
<Tooltip open={screenShareTooltipOpen}
|
||||||
onClose={screenShareTooltipHandleClose}
|
onClose={screenShareTooltipHandleClose}
|
||||||
onOpen={screenShareTooltipHandleOpen}
|
onOpen={screenShareTooltipHandleOpen}
|
||||||
title={screenTip} placement='left'
|
title={screenTip} placement='left'
|
||||||
>
|
>
|
||||||
{ smallContainer ?
|
{ smallContainer ?
|
||||||
|
|
@ -854,7 +854,7 @@ const Me = (props) =>
|
||||||
defaultMessage='ME'
|
defaultMessage='ME'
|
||||||
/>
|
/>
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<VideoView
|
<VideoView
|
||||||
isMe
|
isMe
|
||||||
isScreen
|
isScreen
|
||||||
|
|
@ -898,15 +898,15 @@ const makeMapStateToProps = () =>
|
||||||
const mapStateToProps = (state) =>
|
const mapStateToProps = (state) =>
|
||||||
{
|
{
|
||||||
let volume;
|
let volume;
|
||||||
|
|
||||||
// noiseVolume under threshold
|
// noiseVolume under threshold
|
||||||
if (state.peerVolumes[state.me.id] < state.settings.noiseThreshold)
|
if (state.peerVolumes[state.me.id] < state.settings.noiseThreshold)
|
||||||
{
|
{
|
||||||
// noiseVolume mapped to range 0.5 ... 1 (threshold switch)
|
// noiseVolume mapped to range 0.5 ... 1 (threshold switch)
|
||||||
volume = 1 + ((Math.abs(state.peerVolumes[state.me.id] -
|
volume = 1 + ((Math.abs(state.peerVolumes[state.me.id] -
|
||||||
state.settings.noiseThreshold) / (-120 -
|
state.settings.noiseThreshold) / (-120 -
|
||||||
state.settings.noiseThreshold)));
|
state.settings.noiseThreshold)));
|
||||||
}
|
}
|
||||||
// noiseVolume over threshold: no noise but voice
|
// noiseVolume over threshold: no noise but voice
|
||||||
else { volume = 0; }
|
else { volume = 0; }
|
||||||
|
|
||||||
|
|
@ -933,7 +933,7 @@ export default withRoomContext(connect(
|
||||||
return (
|
return (
|
||||||
prev.room === next.room &&
|
prev.room === next.room &&
|
||||||
prev.me === next.me &&
|
prev.me === next.me &&
|
||||||
Math.round(prev.peerVolumes[prev.me.id]) ===
|
Math.round(prev.peerVolumes[prev.me.id]) ===
|
||||||
Math.round(next.peerVolumes[next.me.id]) &&
|
Math.round(next.peerVolumes[next.me.id]) &&
|
||||||
prev.peers === next.peers &&
|
prev.peers === next.peers &&
|
||||||
prev.producers === next.producers &&
|
prev.producers === next.producers &&
|
||||||
|
|
|
||||||
|
|
@ -228,14 +228,14 @@ const Peer = (props) =>
|
||||||
{
|
{
|
||||||
if (touchTimeout)
|
if (touchTimeout)
|
||||||
clearTimeout(touchTimeout);
|
clearTimeout(touchTimeout);
|
||||||
|
|
||||||
setHover(true);
|
setHover(true);
|
||||||
}}
|
}}
|
||||||
onTouchEnd={() =>
|
onTouchEnd={() =>
|
||||||
{
|
{
|
||||||
if (touchTimeout)
|
if (touchTimeout)
|
||||||
clearTimeout(touchTimeout);
|
clearTimeout(touchTimeout);
|
||||||
|
|
||||||
touchTimeout = setTimeout(() =>
|
touchTimeout = setTimeout(() =>
|
||||||
{
|
{
|
||||||
setHover(false);
|
setHover(false);
|
||||||
|
|
@ -445,14 +445,14 @@ const Peer = (props) =>
|
||||||
{
|
{
|
||||||
if (touchTimeout)
|
if (touchTimeout)
|
||||||
clearTimeout(touchTimeout);
|
clearTimeout(touchTimeout);
|
||||||
|
|
||||||
setHover(true);
|
setHover(true);
|
||||||
}}
|
}}
|
||||||
onTouchEnd={() =>
|
onTouchEnd={() =>
|
||||||
{
|
{
|
||||||
if (touchTimeout)
|
if (touchTimeout)
|
||||||
clearTimeout(touchTimeout);
|
clearTimeout(touchTimeout);
|
||||||
|
|
||||||
touchTimeout = setTimeout(() =>
|
touchTimeout = setTimeout(() =>
|
||||||
{
|
{
|
||||||
setHover(false);
|
setHover(false);
|
||||||
|
|
@ -471,7 +471,7 @@ const Peer = (props) =>
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
}
|
}
|
||||||
|
|
||||||
<div
|
<div
|
||||||
className={classnames(classes.controls, hover ? 'hover' : null)}
|
className={classnames(classes.controls, hover ? 'hover' : null)}
|
||||||
onMouseOver={() => setHover(true)}
|
onMouseOver={() => setHover(true)}
|
||||||
|
|
@ -480,14 +480,14 @@ const Peer = (props) =>
|
||||||
{
|
{
|
||||||
if (touchTimeout)
|
if (touchTimeout)
|
||||||
clearTimeout(touchTimeout);
|
clearTimeout(touchTimeout);
|
||||||
|
|
||||||
setHover(true);
|
setHover(true);
|
||||||
}}
|
}}
|
||||||
onTouchEnd={() =>
|
onTouchEnd={() =>
|
||||||
{
|
{
|
||||||
if (touchTimeout)
|
if (touchTimeout)
|
||||||
clearTimeout(touchTimeout);
|
clearTimeout(touchTimeout);
|
||||||
|
|
||||||
touchTimeout = setTimeout(() =>
|
touchTimeout = setTimeout(() =>
|
||||||
{
|
{
|
||||||
setHover(false);
|
setHover(false);
|
||||||
|
|
@ -544,7 +544,7 @@ const Peer = (props) =>
|
||||||
}
|
}
|
||||||
</Tooltip>
|
</Tooltip>
|
||||||
}
|
}
|
||||||
|
|
||||||
<Tooltip
|
<Tooltip
|
||||||
title={intl.formatMessage({
|
title={intl.formatMessage({
|
||||||
id : 'label.fullscreen',
|
id : 'label.fullscreen',
|
||||||
|
|
@ -588,7 +588,7 @@ const Peer = (props) =>
|
||||||
}
|
}
|
||||||
</Tooltip>
|
</Tooltip>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<VideoView
|
<VideoView
|
||||||
showQuality
|
showQuality
|
||||||
advancedMode={advancedMode}
|
advancedMode={advancedMode}
|
||||||
|
|
@ -629,14 +629,14 @@ const Peer = (props) =>
|
||||||
{
|
{
|
||||||
if (touchTimeout)
|
if (touchTimeout)
|
||||||
clearTimeout(touchTimeout);
|
clearTimeout(touchTimeout);
|
||||||
|
|
||||||
setHover(true);
|
setHover(true);
|
||||||
}}
|
}}
|
||||||
onTouchEnd={() =>
|
onTouchEnd={() =>
|
||||||
{
|
{
|
||||||
if (touchTimeout)
|
if (touchTimeout)
|
||||||
clearTimeout(touchTimeout);
|
clearTimeout(touchTimeout);
|
||||||
|
|
||||||
touchTimeout = setTimeout(() =>
|
touchTimeout = setTimeout(() =>
|
||||||
{
|
{
|
||||||
setHover(false);
|
setHover(false);
|
||||||
|
|
@ -663,7 +663,7 @@ const Peer = (props) =>
|
||||||
{
|
{
|
||||||
if (touchTimeout)
|
if (touchTimeout)
|
||||||
clearTimeout(touchTimeout);
|
clearTimeout(touchTimeout);
|
||||||
|
|
||||||
setHover(true);
|
setHover(true);
|
||||||
}}
|
}}
|
||||||
onTouchEnd={() =>
|
onTouchEnd={() =>
|
||||||
|
|
@ -671,7 +671,7 @@ const Peer = (props) =>
|
||||||
|
|
||||||
if (touchTimeout)
|
if (touchTimeout)
|
||||||
clearTimeout(touchTimeout);
|
clearTimeout(touchTimeout);
|
||||||
|
|
||||||
touchTimeout = setTimeout(() =>
|
touchTimeout = setTimeout(() =>
|
||||||
{
|
{
|
||||||
setHover(false);
|
setHover(false);
|
||||||
|
|
|
||||||
|
|
@ -69,16 +69,16 @@ const About = ({
|
||||||
/>
|
/>
|
||||||
</DialogTitle>
|
</DialogTitle>
|
||||||
<DialogContent dividers='true'>
|
<DialogContent dividers='true'>
|
||||||
<DialogContentText paragraph>
|
<DialogContentText paragraph>
|
||||||
Contributions to this work were made on behalf of the GÉANT
|
Contributions to this work were made on behalf of the GÉANT
|
||||||
project, a project that has received funding from the
|
project, a project that has received funding from the
|
||||||
European Union’s Horizon 2020 research and innovation
|
European Union’s Horizon 2020 research and innovation
|
||||||
programme under Grant Agreement No. 731122 (GN4-2).
|
programme under Grant Agreement No. 731122 (GN4-2).
|
||||||
On behalf of GÉANT project, GÉANT Association is the sole
|
On behalf of GÉANT project, GÉANT Association is the sole
|
||||||
owner of the copyright in all material which was developed
|
owner of the copyright in all material which was developed
|
||||||
by a member of the GÉANT project.
|
by a member of the GÉANT project.
|
||||||
</DialogContentText>
|
</DialogContentText>
|
||||||
<DialogContentText paragraph>
|
<DialogContentText paragraph>
|
||||||
GÉANT Vereniging (Association) is registered with the
|
GÉANT Vereniging (Association) is registered with the
|
||||||
Chamber of Commerce in Amsterdam with registration number
|
Chamber of Commerce in Amsterdam with registration number
|
||||||
40535155 and operates in the UK as a branch of GÉANT
|
40535155 and operates in the UK as a branch of GÉANT
|
||||||
|
|
@ -106,7 +106,7 @@ const About = ({
|
||||||
/>
|
/>
|
||||||
</Button>
|
</Button>
|
||||||
</DialogActions>
|
</DialogActions>
|
||||||
</Dialog>
|
</Dialog>
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
@ -114,7 +114,7 @@ About.propTypes =
|
||||||
{
|
{
|
||||||
roomClient : PropTypes.object.isRequired,
|
roomClient : PropTypes.object.isRequired,
|
||||||
aboutOpen : PropTypes.bool.isRequired,
|
aboutOpen : PropTypes.bool.isRequired,
|
||||||
handleCloseAbout : PropTypes.func.isRequired,
|
handleCloseAbout : PropTypes.func.isRequired,
|
||||||
classes : PropTypes.object.isRequired
|
classes : PropTypes.object.isRequired
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -107,13 +107,13 @@ const Help = ({
|
||||||
}
|
}
|
||||||
/>
|
/>
|
||||||
</Tabs>
|
</Tabs>
|
||||||
<DialogContent dividers='true'>
|
<DialogContent dividers='true'>
|
||||||
<DialogContentText>
|
<DialogContentText>
|
||||||
{shortcuts.map((value, index) =>
|
{shortcuts.map((value, index) =>
|
||||||
{
|
{
|
||||||
return (
|
return (
|
||||||
<div key={index} className={classes.shortcuts}>
|
<div key={index} className={classes.shortcuts}>
|
||||||
<Paper className={classes.paper}>
|
<Paper className={classes.paper}>
|
||||||
{value.key}
|
{value.key}
|
||||||
</Paper>
|
</Paper>
|
||||||
<FormattedMessage
|
<FormattedMessage
|
||||||
|
|
@ -134,7 +134,7 @@ const Help = ({
|
||||||
/>
|
/>
|
||||||
</Button>
|
</Button>
|
||||||
</DialogActions>
|
</DialogActions>
|
||||||
</Dialog>
|
</Dialog>
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
@ -142,7 +142,7 @@ Help.propTypes =
|
||||||
{
|
{
|
||||||
roomClient : PropTypes.object.isRequired,
|
roomClient : PropTypes.object.isRequired,
|
||||||
helpOpen : PropTypes.bool.isRequired,
|
helpOpen : PropTypes.bool.isRequired,
|
||||||
handleCloseHelp : PropTypes.func.isRequired,
|
handleCloseHelp : PropTypes.func.isRequired,
|
||||||
classes : PropTypes.object.isRequired
|
classes : PropTypes.object.isRequired
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -327,7 +327,7 @@ const JoinDialog = ({
|
||||||
/>
|
/>
|
||||||
</Button>
|
</Button>
|
||||||
</DialogActions>
|
</DialogActions>
|
||||||
:
|
:
|
||||||
<DialogContent>
|
<DialogContent>
|
||||||
<DialogContentText
|
<DialogContentText
|
||||||
className={classes.green}
|
className={classes.green}
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ import React from 'react';
|
||||||
import PropTypes from 'prop-types';
|
import PropTypes from 'prop-types';
|
||||||
import classnames from 'classnames';
|
import classnames from 'classnames';
|
||||||
import { withStyles } from '@material-ui/core/styles';
|
import { withStyles } from '@material-ui/core/styles';
|
||||||
import DOMPurify from 'dompurify';
|
import DOMPurify from 'dompurify';
|
||||||
import marked from 'marked';
|
import marked from 'marked';
|
||||||
import Paper from '@material-ui/core/Paper';
|
import Paper from '@material-ui/core/Paper';
|
||||||
import Typography from '@material-ui/core/Typography';
|
import Typography from '@material-ui/core/Typography';
|
||||||
|
|
@ -14,7 +14,7 @@ linkRenderer.link = (href, title, text) =>
|
||||||
{
|
{
|
||||||
title = title ? title : href;
|
title = title ? title : href;
|
||||||
text = text ? text : href;
|
text = text ? text : href;
|
||||||
|
|
||||||
return `<a target='_blank' href='${ href }' title='${ title }'>${ text }</a>`;
|
return `<a target='_blank' href='${ href }' title='${ title }'>${ text }</a>`;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -60,7 +60,7 @@ class MessageList extends React.Component
|
||||||
myPicture,
|
myPicture,
|
||||||
classes
|
classes
|
||||||
} = this.props;
|
} = this.props;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className={classes.root} ref={(node) => { this.node = node; }}>
|
<div className={classes.root} ref={(node) => { this.node = node; }}>
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -279,7 +279,7 @@ const ListPeer = (props) =>
|
||||||
</IconButton>
|
</IconButton>
|
||||||
</Tooltip>
|
</Tooltip>
|
||||||
}
|
}
|
||||||
{ isModerator && webcamConsumer &&
|
{ isModerator && webcamConsumer &&
|
||||||
<Tooltip
|
<Tooltip
|
||||||
title={intl.formatMessage({
|
title={intl.formatMessage({
|
||||||
id : 'tooltip.muteParticipantVideoModerator',
|
id : 'tooltip.muteParticipantVideoModerator',
|
||||||
|
|
|
||||||
|
|
@ -143,13 +143,13 @@ class Filmstrip extends React.PureComponent
|
||||||
let speakerWidth = (availableWidth - PADDING_H);
|
let speakerWidth = (availableWidth - PADDING_H);
|
||||||
|
|
||||||
let speakerHeight = speakerWidth / RATIO;
|
let speakerHeight = speakerWidth / RATIO;
|
||||||
|
|
||||||
if (this.isSharingCamera(this.getActivePeerId()))
|
if (this.isSharingCamera(this.getActivePeerId()))
|
||||||
{
|
{
|
||||||
speakerWidth /= 2;
|
speakerWidth /= 2;
|
||||||
speakerHeight = speakerWidth / RATIO;
|
speakerHeight = speakerWidth / RATIO;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (speakerHeight > (availableSpeakerHeight - PADDING_V))
|
if (speakerHeight > (availableSpeakerHeight - PADDING_V))
|
||||||
{
|
{
|
||||||
speakerHeight = (availableSpeakerHeight - PADDING_V);
|
speakerHeight = (availableSpeakerHeight - PADDING_V);
|
||||||
|
|
@ -167,7 +167,7 @@ class Filmstrip extends React.PureComponent
|
||||||
let filmStripHeight = availableFilmstripHeight - FILMSTRING_PADDING_V;
|
let filmStripHeight = availableFilmstripHeight - FILMSTRING_PADDING_V;
|
||||||
|
|
||||||
let filmStripWidth = filmStripHeight * RATIO;
|
let filmStripWidth = filmStripHeight * RATIO;
|
||||||
|
|
||||||
if (
|
if (
|
||||||
(filmStripWidth * this.props.boxes) >
|
(filmStripWidth * this.props.boxes) >
|
||||||
(availableWidth - FILMSTRING_PADDING_H)
|
(availableWidth - FILMSTRING_PADDING_H)
|
||||||
|
|
@ -254,7 +254,7 @@ class Filmstrip extends React.PureComponent
|
||||||
};
|
};
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div
|
<div
|
||||||
className={classnames(
|
className={classnames(
|
||||||
classes.root,
|
classes.root,
|
||||||
toolbarsVisible || permanentTopBar ?
|
toolbarsVisible || permanentTopBar ?
|
||||||
|
|
|
||||||
|
|
@ -36,7 +36,7 @@ export default class PeerAudio extends React.PureComponent
|
||||||
if (prevProps !== this.props)
|
if (prevProps !== this.props)
|
||||||
{
|
{
|
||||||
const { audioTrack, audioOutputDevice } = this.props;
|
const { audioTrack, audioOutputDevice } = this.props;
|
||||||
|
|
||||||
this._setTrack(audioTrack);
|
this._setTrack(audioTrack);
|
||||||
this._setOutputDevice(audioOutputDevice);
|
this._setOutputDevice(audioOutputDevice);
|
||||||
}
|
}
|
||||||
|
|
@ -70,7 +70,7 @@ export default class PeerAudio extends React.PureComponent
|
||||||
{
|
{
|
||||||
if (this._audioOutputDevice === audioOutputDevice)
|
if (this._audioOutputDevice === audioOutputDevice)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
this._audioOutputDevice = audioOutputDevice;
|
this._audioOutputDevice = audioOutputDevice;
|
||||||
|
|
||||||
const { audio } = this.refs;
|
const { audio } = this.refs;
|
||||||
|
|
|
||||||
|
|
@ -248,7 +248,7 @@ export const makePermissionSelector = (permission) =>
|
||||||
const permitted = roles.some((role) =>
|
const permitted = roles.some((role) =>
|
||||||
roomPermissions[permission].includes(role)
|
roomPermissions[permission].includes(role)
|
||||||
);
|
);
|
||||||
|
|
||||||
if (permitted)
|
if (permitted)
|
||||||
return true;
|
return true;
|
||||||
|
|
||||||
|
|
@ -265,7 +265,7 @@ export const makePermissionSelector = (permission) =>
|
||||||
).length === 0
|
).length === 0
|
||||||
)
|
)
|
||||||
return true;
|
return true;
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
|
||||||
|
|
@ -18,7 +18,7 @@ import Typography from '@material-ui/core/Typography';
|
||||||
|
|
||||||
const NoiseSlider = withStyles(
|
const NoiseSlider = withStyles(
|
||||||
{
|
{
|
||||||
root :
|
root :
|
||||||
{
|
{
|
||||||
color : '#3880ff',
|
color : '#3880ff',
|
||||||
height : 2,
|
height : 2,
|
||||||
|
|
@ -48,7 +48,7 @@ const styles = (theme) => ({
|
||||||
{
|
{
|
||||||
padding : theme.spacing(2)
|
padding : theme.spacing(2)
|
||||||
},
|
},
|
||||||
margin :
|
margin :
|
||||||
{
|
{
|
||||||
height : theme.spacing(3)
|
height : theme.spacing(3)
|
||||||
},
|
},
|
||||||
|
|
@ -72,7 +72,7 @@ const MediaSettings = ({
|
||||||
}) =>
|
}) =>
|
||||||
{
|
{
|
||||||
const intl = useIntl();
|
const intl = useIntl();
|
||||||
|
|
||||||
const resolutions = [ {
|
const resolutions = [ {
|
||||||
value : 'low',
|
value : 'low',
|
||||||
label : intl.formatMessage({
|
label : intl.formatMessage({
|
||||||
|
|
@ -122,7 +122,7 @@ const MediaSettings = ({
|
||||||
audioDevices = Object.values(me.audioDevices);
|
audioDevices = Object.values(me.audioDevices);
|
||||||
else
|
else
|
||||||
audioDevices = [];
|
audioDevices = [];
|
||||||
|
|
||||||
let audioOutputDevices;
|
let audioOutputDevices;
|
||||||
|
|
||||||
if (me.audioOutputDevices)
|
if (me.audioOutputDevices)
|
||||||
|
|
@ -174,7 +174,7 @@ const MediaSettings = ({
|
||||||
<FormControl className={classes.formControl}>
|
<FormControl className={classes.formControl}>
|
||||||
<Select
|
<Select
|
||||||
value={settings.resolution || ''}
|
value={settings.resolution || ''}
|
||||||
onChange={(event) =>
|
onChange={(event) =>
|
||||||
{
|
{
|
||||||
if (event.target.value)
|
if (event.target.value)
|
||||||
roomClient.changeVideoResolution(event.target.value);
|
roomClient.changeVideoResolution(event.target.value);
|
||||||
|
|
@ -183,7 +183,7 @@ const MediaSettings = ({
|
||||||
autoWidth
|
autoWidth
|
||||||
className={classes.selectEmpty}
|
className={classes.selectEmpty}
|
||||||
>
|
>
|
||||||
{resolutions.map((resolution, index) =>
|
{resolutions.map((resolution, index) =>
|
||||||
{
|
{
|
||||||
return (
|
return (
|
||||||
<MenuItem key={index} value={resolution.value}>
|
<MenuItem key={index} value={resolution.value}>
|
||||||
|
|
@ -293,7 +293,7 @@ const MediaSettings = ({
|
||||||
className={classes.setting}
|
className={classes.setting}
|
||||||
control={
|
control={
|
||||||
<Checkbox checked={settings.showAdvancedAudio} onChange={
|
<Checkbox checked={settings.showAdvancedAudio} onChange={
|
||||||
(event) =>
|
(event) =>
|
||||||
{
|
{
|
||||||
setShowAdvancedAudio(event.target.checked);
|
setShowAdvancedAudio(event.target.checked);
|
||||||
}}
|
}}
|
||||||
|
|
@ -310,7 +310,7 @@ const MediaSettings = ({
|
||||||
className={classes.setting}
|
className={classes.setting}
|
||||||
control={
|
control={
|
||||||
<Checkbox checked={settings.echoCancellation} onChange={
|
<Checkbox checked={settings.echoCancellation} onChange={
|
||||||
(event) =>
|
(event) =>
|
||||||
{
|
{
|
||||||
setEchoCancellation(event.target.checked);
|
setEchoCancellation(event.target.checked);
|
||||||
roomClient.changeAudioDevice(settings.selectedAudioDevice);
|
roomClient.changeAudioDevice(settings.selectedAudioDevice);
|
||||||
|
|
@ -325,7 +325,7 @@ const MediaSettings = ({
|
||||||
className={classes.setting}
|
className={classes.setting}
|
||||||
control={
|
control={
|
||||||
<Checkbox checked={settings.autoGainControl} onChange={
|
<Checkbox checked={settings.autoGainControl} onChange={
|
||||||
(event) =>
|
(event) =>
|
||||||
{
|
{
|
||||||
setAutoGainControl(event.target.checked);
|
setAutoGainControl(event.target.checked);
|
||||||
roomClient.changeAudioDevice(settings.selectedAudioDevice);
|
roomClient.changeAudioDevice(settings.selectedAudioDevice);
|
||||||
|
|
@ -340,7 +340,7 @@ const MediaSettings = ({
|
||||||
className={classes.setting}
|
className={classes.setting}
|
||||||
control={
|
control={
|
||||||
<Checkbox checked={settings.noiseSuppression} onChange={
|
<Checkbox checked={settings.noiseSuppression} onChange={
|
||||||
(event) =>
|
(event) =>
|
||||||
{
|
{
|
||||||
setNoiseSuppression(event.target.checked);
|
setNoiseSuppression(event.target.checked);
|
||||||
roomClient.changeAudioDevice(settings.selectedAudioDevice);
|
roomClient.changeAudioDevice(settings.selectedAudioDevice);
|
||||||
|
|
@ -355,7 +355,7 @@ const MediaSettings = ({
|
||||||
className={classes.setting}
|
className={classes.setting}
|
||||||
control={
|
control={
|
||||||
<Checkbox checked={settings.voiceActivatedUnmute} onChange={
|
<Checkbox checked={settings.voiceActivatedUnmute} onChange={
|
||||||
(event) =>
|
(event) =>
|
||||||
{
|
{
|
||||||
setVoiceActivatedUnmute(event.target.checked);
|
setVoiceActivatedUnmute(event.target.checked);
|
||||||
}}
|
}}
|
||||||
|
|
@ -374,18 +374,18 @@ const MediaSettings = ({
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
</Typography>
|
</Typography>
|
||||||
<NoiseSlider className={classnames(classes.slider, classnames.setting)}
|
<NoiseSlider className={classnames(classes.slider, classnames.setting)}
|
||||||
key={'noise-threshold-slider'}
|
key={'noise-threshold-slider'}
|
||||||
min={-100}
|
min={-100}
|
||||||
value={settings.noiseThreshold}
|
value={settings.noiseThreshold}
|
||||||
max={0}
|
max={0}
|
||||||
valueLabelDisplay={'off'}
|
valueLabelDisplay={'off'}
|
||||||
onChange={
|
onChange={
|
||||||
(event, value) =>
|
(event, value) =>
|
||||||
{
|
{
|
||||||
roomClient._setNoiseThreshold(value);
|
roomClient._setNoiseThreshold(value);
|
||||||
}}
|
}}
|
||||||
marks={[ { value: volume, label: 'level' } ]}
|
marks={[ { value: volume, label: 'level' } ]}
|
||||||
/>
|
/>
|
||||||
<div className={classes.margin} />
|
<div className={classes.margin} />
|
||||||
</form>
|
</form>
|
||||||
|
|
|
||||||
|
|
@ -187,50 +187,50 @@ class VideoView extends React.PureComponent
|
||||||
if (videoScore || audioScore)
|
if (videoScore || audioScore)
|
||||||
{
|
{
|
||||||
const score = videoScore ? videoScore : audioScore;
|
const score = videoScore ? videoScore : audioScore;
|
||||||
|
|
||||||
switch (isMe ? score.score : score.producerScore)
|
switch (isMe ? score.score : score.producerScore)
|
||||||
{
|
{
|
||||||
case 0:
|
case 0:
|
||||||
case 1:
|
case 1:
|
||||||
{
|
{
|
||||||
quality = <SignalCellular0BarIcon style={{ color: red[500] }}/>;
|
quality = <SignalCellular0BarIcon style={{ color: red[500] }}/>;
|
||||||
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
case 2:
|
case 2:
|
||||||
case 3:
|
case 3:
|
||||||
{
|
{
|
||||||
quality = <SignalCellular1BarIcon style={{ color: red[500] }}/>;
|
quality = <SignalCellular1BarIcon style={{ color: red[500] }}/>;
|
||||||
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
case 4:
|
case 4:
|
||||||
case 5:
|
case 5:
|
||||||
case 6:
|
case 6:
|
||||||
{
|
{
|
||||||
quality = <SignalCellular2BarIcon style={{ color: orange[500] }}/>;
|
quality = <SignalCellular2BarIcon style={{ color: orange[500] }}/>;
|
||||||
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
case 7:
|
case 7:
|
||||||
case 8:
|
case 8:
|
||||||
case 9:
|
case 9:
|
||||||
{
|
{
|
||||||
quality = <SignalCellular3BarIcon style={{ color: yellow[500] }}/>;
|
quality = <SignalCellular3BarIcon style={{ color: yellow[500] }}/>;
|
||||||
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
case 10:
|
case 10:
|
||||||
{
|
{
|
||||||
quality = null;
|
quality = null;
|
||||||
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
default:
|
default:
|
||||||
{
|
{
|
||||||
break;
|
break;
|
||||||
|
|
@ -266,7 +266,7 @@ class VideoView extends React.PureComponent
|
||||||
</div>
|
</div>
|
||||||
{ showQuality &&
|
{ showQuality &&
|
||||||
<div className={classnames(classes.box, 'right')}>
|
<div className={classnames(classes.box, 'right')}>
|
||||||
{
|
{
|
||||||
quality
|
quality
|
||||||
}
|
}
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
|
|
@ -135,20 +135,20 @@ function run()
|
||||||
|
|
||||||
if (!basePath)
|
if (!basePath)
|
||||||
basePath = '/';
|
basePath = '/';
|
||||||
|
|
||||||
// Get current device.
|
// Get current device.
|
||||||
const device = deviceInfo();
|
const device = deviceInfo();
|
||||||
|
|
||||||
let unsupportedBrowser=false;
|
let unsupportedBrowser=false;
|
||||||
|
|
||||||
let webrtcUnavailable=false;
|
let webrtcUnavailable=false;
|
||||||
|
|
||||||
if (detectDevice() === undefined)
|
if (detectDevice() === undefined)
|
||||||
{
|
{
|
||||||
logger.error('Unsupported browser detected by mediasoup client detectDevice! deviceInfo: %o', device);
|
logger.error('Unsupported browser detected by mediasoup client detectDevice! deviceInfo: %o', device);
|
||||||
unsupportedBrowser=true;
|
unsupportedBrowser=true;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
if (
|
if (
|
||||||
navigator.mediaDevices === undefined ||
|
navigator.mediaDevices === undefined ||
|
||||||
navigator.mediaDevices.getUserMedia === undefined ||
|
navigator.mediaDevices.getUserMedia === undefined ||
|
||||||
|
|
@ -157,13 +157,13 @@ function run()
|
||||||
{
|
{
|
||||||
logger.error('WebRTC is unavialable in your browser! deviceInfo: %o', device);
|
logger.error('WebRTC is unavialable in your browser! deviceInfo: %o', device);
|
||||||
webrtcUnavailable=true;
|
webrtcUnavailable=true;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
if (device.name === 'safari' && !isNaN(device.version) && parseFloat(device.version) < 12)
|
if (device.name === 'safari' && !isNaN(device.version) && parseFloat(device.version) < 12)
|
||||||
{
|
{
|
||||||
unsupportedBrowser=true;
|
unsupportedBrowser=true;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
logger.debug('Supported Browser! deviceInfo: %o', device);
|
logger.debug('Supported Browser! deviceInfo: %o', device);
|
||||||
}
|
}
|
||||||
|
|
@ -173,15 +173,15 @@ function run()
|
||||||
render(
|
render(
|
||||||
<MuiThemeProvider theme={theme}>
|
<MuiThemeProvider theme={theme}>
|
||||||
<RawIntlProvider value={intl}>
|
<RawIntlProvider value={intl}>
|
||||||
<UnsupportedBrowser
|
<UnsupportedBrowser
|
||||||
webrtcUnavailable={webrtcUnavailable}
|
webrtcUnavailable={webrtcUnavailable}
|
||||||
platform={device.platform}
|
platform={device.platform}
|
||||||
/>
|
/>
|
||||||
</RawIntlProvider>
|
</RawIntlProvider>
|
||||||
</MuiThemeProvider>,
|
</MuiThemeProvider>,
|
||||||
document.getElementById('multiparty-meeting')
|
document.getElementById('multiparty-meeting')
|
||||||
);
|
);
|
||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
const lobbyPeer = (state = {}, action) =>
|
const lobbyPeer = (state = {}, action) =>
|
||||||
{
|
{
|
||||||
switch (action.type)
|
switch (action.type)
|
||||||
{
|
{
|
||||||
case 'ADD_LOBBY_PEER':
|
case 'ADD_LOBBY_PEER':
|
||||||
return { id: action.payload.peerId };
|
return { id: action.payload.peerId };
|
||||||
|
|
@ -42,7 +42,7 @@ const lobbyPeers = (state = {}, action) =>
|
||||||
{
|
{
|
||||||
const oldLobbyPeer = state[action.payload.peerId];
|
const oldLobbyPeer = state[action.payload.peerId];
|
||||||
|
|
||||||
if (!oldLobbyPeer)
|
if (!oldLobbyPeer)
|
||||||
{
|
{
|
||||||
// Tried to update non-existent lobbyPeer. Has probably been promoted, or left.
|
// Tried to update non-existent lobbyPeer. Has probably been promoted, or left.
|
||||||
return state;
|
return state;
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ const initialState = {};
|
||||||
|
|
||||||
const peer = (state = initialState, action) =>
|
const peer = (state = initialState, action) =>
|
||||||
{
|
{
|
||||||
switch (action.type)
|
switch (action.type)
|
||||||
{
|
{
|
||||||
case 'ADD_PEER':
|
case 'ADD_PEER':
|
||||||
return action.payload.peer;
|
return action.payload.peer;
|
||||||
|
|
@ -21,7 +21,7 @@ const peer = (state = initialState, action) =>
|
||||||
|
|
||||||
case 'SET_PEER_KICK_IN_PROGRESS':
|
case 'SET_PEER_KICK_IN_PROGRESS':
|
||||||
return { ...state, peerKickInProgress: action.payload.flag };
|
return { ...state, peerKickInProgress: action.payload.flag };
|
||||||
|
|
||||||
case 'SET_PEER_RAISED_HAND':
|
case 'SET_PEER_RAISED_HAND':
|
||||||
return {
|
return {
|
||||||
...state,
|
...state,
|
||||||
|
|
@ -34,7 +34,7 @@ const peer = (state = initialState, action) =>
|
||||||
...state,
|
...state,
|
||||||
raisedHandInProgress : action.payload.flag
|
raisedHandInProgress : action.payload.flag
|
||||||
};
|
};
|
||||||
|
|
||||||
case 'ADD_CONSUMER':
|
case 'ADD_CONSUMER':
|
||||||
{
|
{
|
||||||
const consumers = [ ...state.consumers, action.payload.consumer.id ];
|
const consumers = [ ...state.consumers, action.payload.consumer.id ];
|
||||||
|
|
@ -127,14 +127,14 @@ const peers = (state = initialState, action) =>
|
||||||
{
|
{
|
||||||
const oldPeer = state[action.payload.peerId];
|
const oldPeer = state[action.payload.peerId];
|
||||||
|
|
||||||
if (!oldPeer)
|
if (!oldPeer)
|
||||||
{
|
{
|
||||||
throw new Error('no Peer found');
|
throw new Error('no Peer found');
|
||||||
}
|
}
|
||||||
|
|
||||||
return { ...state, [oldPeer.id]: peer(oldPeer, action) };
|
return { ...state, [oldPeer.id]: peer(oldPeer, action) };
|
||||||
}
|
}
|
||||||
|
|
||||||
case 'SET_PEER_KICK_IN_PROGRESS':
|
case 'SET_PEER_KICK_IN_PROGRESS':
|
||||||
case 'REMOVE_CONSUMER':
|
case 'REMOVE_CONSUMER':
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -10,7 +10,7 @@ const initialState =
|
||||||
// access code to the room if locked and joinByAccessCode == true
|
// access code to the room if locked and joinByAccessCode == true
|
||||||
accessCode : '',
|
accessCode : '',
|
||||||
// if true: accessCode is a possibility to open the room
|
// if true: accessCode is a possibility to open the room
|
||||||
joinByAccessCode : true,
|
joinByAccessCode : true,
|
||||||
activeSpeakerId : null,
|
activeSpeakerId : null,
|
||||||
torrentSupport : false,
|
torrentSupport : false,
|
||||||
showSettings : false,
|
showSettings : false,
|
||||||
|
|
@ -107,7 +107,7 @@ const room = (state = initialState, action) =>
|
||||||
|
|
||||||
return { ...state, lockDialogOpen };
|
return { ...state, lockDialogOpen };
|
||||||
}
|
}
|
||||||
|
|
||||||
case 'SET_SETTINGS_OPEN':
|
case 'SET_SETTINGS_OPEN':
|
||||||
{
|
{
|
||||||
const { settingsOpen } = action.payload;
|
const { settingsOpen } = action.payload;
|
||||||
|
|
@ -135,7 +135,7 @@ const room = (state = initialState, action) =>
|
||||||
|
|
||||||
return { ...state, aboutOpen };
|
return { ...state, aboutOpen };
|
||||||
}
|
}
|
||||||
|
|
||||||
case 'SET_SETTINGS_TAB':
|
case 'SET_SETTINGS_TAB':
|
||||||
{
|
{
|
||||||
const { tab } = action.payload;
|
const { tab } = action.payload;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue