import React, {useContext} from 'react'; import {View} from 'react-native'; import PropsContext, {UidInterface} from '../Contexts/PropsContext'; import styles from '../Style'; import RemoteAudioMute from './Remote/RemoteAudioMute'; import RemoteSwap from './Remote/RemoteSwap'; import RemoteVideoMute from './Remote/RemoteVideoMute'; interface RemoteControlsInterface { showMuteRemoteVideo?: boolean; showMuteRemoteAudio?: boolean; showRemoteSwap?: boolean; user: UidInterface; } const RemoteControls: React.FC = (props) => { const {styleProps, rtcProps} = useContext(PropsContext); const {remoteBtnContainer} = styleProps || {}; return ( {rtcProps.disableRtm ? ( <> ) : ( <> {props.showMuteRemoteAudio !== false ? ( ) : ( <> )} {props.showMuteRemoteVideo !== false ? ( ) : ( <> )} )} {props.showRemoteSwap !== false ? ( ) : ( <> )} ); }; export default RemoteControls;