Space out buttons on top bar, make sure users don't accidentally leave room. Fixes #138
parent
6b469881ef
commit
78262b71e1
|
|
@ -45,6 +45,10 @@ const styles = (theme) =>
|
||||||
display : 'block'
|
display : 'block'
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
divider :
|
||||||
|
{
|
||||||
|
marginLeft : theme.spacing(3),
|
||||||
|
},
|
||||||
show :
|
show :
|
||||||
{
|
{
|
||||||
opacity : 1,
|
opacity : 1,
|
||||||
|
|
@ -200,6 +204,65 @@ const TopBar = (props) =>
|
||||||
</Typography>
|
</Typography>
|
||||||
<div className={classes.grow} />
|
<div className={classes.grow} />
|
||||||
<div className={classes.actionButtons}>
|
<div className={classes.actionButtons}>
|
||||||
|
{ fullscreenEnabled &&
|
||||||
|
<Tooltip title={fullscreenTooltip}>
|
||||||
|
<IconButton
|
||||||
|
aria-label={intl.formatMessage({
|
||||||
|
id : 'tooltip.enterFullscreen',
|
||||||
|
defaultMessage : 'Enter fullscreen'
|
||||||
|
})}
|
||||||
|
className={classes.actionButton}
|
||||||
|
color='inherit'
|
||||||
|
onClick={onFullscreen}
|
||||||
|
>
|
||||||
|
{ fullscreen ?
|
||||||
|
<FullScreenExitIcon />
|
||||||
|
:
|
||||||
|
<FullScreenIcon />
|
||||||
|
}
|
||||||
|
</IconButton>
|
||||||
|
</Tooltip>
|
||||||
|
}
|
||||||
|
<Tooltip
|
||||||
|
title={intl.formatMessage({
|
||||||
|
id : 'tooltip.participants',
|
||||||
|
defaultMessage : 'Show participants'
|
||||||
|
})}
|
||||||
|
>
|
||||||
|
<IconButton
|
||||||
|
aria-label={intl.formatMessage({
|
||||||
|
id : 'tooltip.participants',
|
||||||
|
defaultMessage : 'Show participants'
|
||||||
|
})}
|
||||||
|
color='inherit'
|
||||||
|
onClick={() => openUsersTab()}
|
||||||
|
>
|
||||||
|
<Badge
|
||||||
|
color='primary'
|
||||||
|
badgeContent={peersLength + 1}
|
||||||
|
>
|
||||||
|
<PeopleIcon />
|
||||||
|
</Badge>
|
||||||
|
</IconButton>
|
||||||
|
</Tooltip>
|
||||||
|
<Tooltip
|
||||||
|
title={intl.formatMessage({
|
||||||
|
id : 'tooltip.settings',
|
||||||
|
defaultMessage : 'Show settings'
|
||||||
|
})}
|
||||||
|
>
|
||||||
|
<IconButton
|
||||||
|
aria-label={intl.formatMessage({
|
||||||
|
id : 'tooltip.settings',
|
||||||
|
defaultMessage : 'Show settings'
|
||||||
|
})}
|
||||||
|
className={classes.actionButton}
|
||||||
|
color='inherit'
|
||||||
|
onClick={() => setSettingsOpen(!room.settingsOpen)}
|
||||||
|
>
|
||||||
|
<SettingsIcon />
|
||||||
|
</IconButton>
|
||||||
|
</Tooltip>
|
||||||
<Tooltip title={lockTooltip}>
|
<Tooltip title={lockTooltip}>
|
||||||
<IconButton
|
<IconButton
|
||||||
aria-label={intl.formatMessage({
|
aria-label={intl.formatMessage({
|
||||||
|
|
@ -251,65 +314,6 @@ const TopBar = (props) =>
|
||||||
</IconButton>
|
</IconButton>
|
||||||
</Tooltip>
|
</Tooltip>
|
||||||
}
|
}
|
||||||
<Tooltip
|
|
||||||
title={intl.formatMessage({
|
|
||||||
id : 'tooltip.participants',
|
|
||||||
defaultMessage : 'Show participants'
|
|
||||||
})}
|
|
||||||
>
|
|
||||||
<IconButton
|
|
||||||
aria-label={intl.formatMessage({
|
|
||||||
id : 'tooltip.participants',
|
|
||||||
defaultMessage : 'Show participants'
|
|
||||||
})}
|
|
||||||
color='inherit'
|
|
||||||
onClick={() => openUsersTab()}
|
|
||||||
>
|
|
||||||
<Badge
|
|
||||||
color='primary'
|
|
||||||
badgeContent={peersLength + 1}
|
|
||||||
>
|
|
||||||
<PeopleIcon />
|
|
||||||
</Badge>
|
|
||||||
</IconButton>
|
|
||||||
</Tooltip>
|
|
||||||
{ fullscreenEnabled &&
|
|
||||||
<Tooltip title={fullscreenTooltip}>
|
|
||||||
<IconButton
|
|
||||||
aria-label={intl.formatMessage({
|
|
||||||
id : 'tooltip.enterFullscreen',
|
|
||||||
defaultMessage : 'Enter fullscreen'
|
|
||||||
})}
|
|
||||||
className={classes.actionButton}
|
|
||||||
color='inherit'
|
|
||||||
onClick={onFullscreen}
|
|
||||||
>
|
|
||||||
{ fullscreen ?
|
|
||||||
<FullScreenExitIcon />
|
|
||||||
:
|
|
||||||
<FullScreenIcon />
|
|
||||||
}
|
|
||||||
</IconButton>
|
|
||||||
</Tooltip>
|
|
||||||
}
|
|
||||||
<Tooltip
|
|
||||||
title={intl.formatMessage({
|
|
||||||
id : 'tooltip.settings',
|
|
||||||
defaultMessage : 'Show settings'
|
|
||||||
})}
|
|
||||||
>
|
|
||||||
<IconButton
|
|
||||||
aria-label={intl.formatMessage({
|
|
||||||
id : 'tooltip.settings',
|
|
||||||
defaultMessage : 'Show settings'
|
|
||||||
})}
|
|
||||||
className={classes.actionButton}
|
|
||||||
color='inherit'
|
|
||||||
onClick={() => setSettingsOpen(!room.settingsOpen)}
|
|
||||||
>
|
|
||||||
<SettingsIcon />
|
|
||||||
</IconButton>
|
|
||||||
</Tooltip>
|
|
||||||
{ loginEnabled &&
|
{ loginEnabled &&
|
||||||
<Tooltip title={loginTooltip}>
|
<Tooltip title={loginTooltip}>
|
||||||
<IconButton
|
<IconButton
|
||||||
|
|
@ -332,6 +336,7 @@ const TopBar = (props) =>
|
||||||
</IconButton>
|
</IconButton>
|
||||||
</Tooltip>
|
</Tooltip>
|
||||||
}
|
}
|
||||||
|
<div className={classes.divider} />
|
||||||
<Button
|
<Button
|
||||||
aria-label={intl.formatMessage({
|
aria-label={intl.formatMessage({
|
||||||
id : 'label.leave',
|
id : 'label.leave',
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue