fix(context-menus) Don't show volume slider on iOS web
This commit is contained in:
parent
042a2cb447
commit
e278703c58
|
@ -5,6 +5,7 @@ import React, { Component } from 'react';
|
|||
import { Avatar } from '../../../base/avatar';
|
||||
import { isToolbarButtonEnabled } from '../../../base/config/functions.web';
|
||||
import { openDialog } from '../../../base/dialog';
|
||||
import { isIosMobileBrowser } from '../../../base/environment/utils';
|
||||
import { translate } from '../../../base/i18n';
|
||||
import {
|
||||
IconCloseCircle,
|
||||
|
@ -395,6 +396,11 @@ class MeetingParticipantContextMenu extends Component<Props, State> {
|
|||
return null;
|
||||
}
|
||||
|
||||
const showVolumeSlider = !isIosMobileBrowser()
|
||||
&& overflowDrawer
|
||||
&& typeof _volume === 'number'
|
||||
&& !isNaN(_volume);
|
||||
|
||||
const actions
|
||||
= _participant?.isFakeParticipant ? (
|
||||
<>
|
||||
|
@ -463,7 +469,7 @@ class MeetingParticipantContextMenu extends Component<Props, State> {
|
|||
)
|
||||
}
|
||||
</ContextMenuItemGroup>
|
||||
{ overflowDrawer && typeof _volume === 'number' && !isNaN(_volume)
|
||||
{ showVolumeSlider
|
||||
&& <ContextMenuItemGroup>
|
||||
<VolumeSlider
|
||||
initialValue = { _volume }
|
||||
|
|
|
@ -5,7 +5,7 @@ import { batch } from 'react-redux';
|
|||
|
||||
import ConnectionIndicatorContent from
|
||||
'../../../../features/connection-indicator/components/web/ConnectionIndicatorContent';
|
||||
import { isMobileBrowser } from '../../../base/environment/utils';
|
||||
import { isIosMobileBrowser, isMobileBrowser } from '../../../base/environment/utils';
|
||||
import { translate } from '../../../base/i18n';
|
||||
import { Icon, IconMenuThumb } from '../../../base/icons';
|
||||
import { getLocalParticipant, getParticipantById, PARTICIPANT_ROLE } from '../../../base/participants';
|
||||
|
@ -274,6 +274,10 @@ class RemoteVideoMenuTriggerButton extends Component<Props> {
|
|||
} = this.props;
|
||||
|
||||
const buttons = [];
|
||||
const showVolumeSlider = !isIosMobileBrowser()
|
||||
&& onVolumeChange
|
||||
&& typeof initialVolumeValue === 'number'
|
||||
&& !isNaN(initialVolumeValue);
|
||||
|
||||
if (_isModerator) {
|
||||
if (!_disableRemoteMute) {
|
||||
|
@ -348,7 +352,7 @@ class RemoteVideoMenuTriggerButton extends Component<Props> {
|
|||
);
|
||||
}
|
||||
|
||||
if (onVolumeChange && typeof initialVolumeValue === 'number' && !isNaN(initialVolumeValue)) {
|
||||
if (showVolumeSlider) {
|
||||
buttons.push(
|
||||
<VolumeSlider
|
||||
initialValue = { initialVolumeValue }
|
||||
|
|
Loading…
Reference in New Issue