diff --git a/ts/components/CallScreen.stories.tsx b/ts/components/CallScreen.stories.tsx index a3f32532c8..247c85fb55 100644 --- a/ts/components/CallScreen.stories.tsx +++ b/ts/components/CallScreen.stories.tsx @@ -105,7 +105,17 @@ const createActiveGroupCallProp = (overrideProps: GroupCallOverrideProps) => ({ peekedParticipants: overrideProps.peekedParticipants || overrideProps.remoteParticipants || [], remoteParticipants: overrideProps.remoteParticipants || [], - remoteAudioLevels: new Map(), + remoteAudioLevels: new Map( + overrideProps.remoteParticipants?.map((_participant, index) => [ + index, + number('remoteAudioLevel', 0, { + range: true, + min: 0, + max: 1, + step: 0.01, + }), + ]) + ), }); const createActiveCallProp = ( diff --git a/ts/components/CallingPipRemoteVideo.tsx b/ts/components/CallingPipRemoteVideo.tsx index 72e05add31..8487be9f41 100644 --- a/ts/components/CallingPipRemoteVideo.tsx +++ b/ts/components/CallingPipRemoteVideo.tsx @@ -172,6 +172,7 @@ export function CallingPipRemoteVideo({ isInPip remoteParticipant={activeGroupCallSpeaker} remoteParticipantsCount={activeCall.remoteParticipants.length} + isActiveSpeakerInSpeakerView={false} /> ); diff --git a/ts/components/GroupCallOverflowArea.tsx b/ts/components/GroupCallOverflowArea.tsx index df352baa18..4605057926 100644 --- a/ts/components/GroupCallOverflowArea.tsx +++ b/ts/components/GroupCallOverflowArea.tsx @@ -126,6 +126,7 @@ export function GroupCallOverflowArea({ )} remoteParticipant={remoteParticipant} remoteParticipantsCount={remoteParticipantsCount} + isActiveSpeakerInSpeakerView={false} /> ))} diff --git a/ts/components/GroupCallRemoteParticipant.stories.tsx b/ts/components/GroupCallRemoteParticipant.stories.tsx index aa0f9b8e87..92bcf3735c 100644 --- a/ts/components/GroupCallRemoteParticipant.stories.tsx +++ b/ts/components/GroupCallRemoteParticipant.stories.tsx @@ -64,6 +64,7 @@ const createProps = ( }), }, remoteParticipantsCount: 1, + isActiveSpeakerInSpeakerView: false, ...overrideProps, }); diff --git a/ts/components/GroupCallRemoteParticipant.tsx b/ts/components/GroupCallRemoteParticipant.tsx index cd9622c7e9..86c68ebf1d 100644 --- a/ts/components/GroupCallRemoteParticipant.tsx +++ b/ts/components/GroupCallRemoteParticipant.tsx @@ -35,6 +35,7 @@ type BasePropsType = { getFrameBuffer: () => Buffer; getGroupCallVideoFrameSource: (demuxId: number) => VideoFrameSource; i18n: LocalizerType; + isActiveSpeakerInSpeakerView: boolean; onVisibilityChanged?: (demuxId: number, isVisible: boolean) => unknown; remoteParticipant: GroupCallRemoteParticipantType; remoteParticipantsCount: number; @@ -67,6 +68,7 @@ export const GroupCallRemoteParticipant: React.FC = React.memo( i18n, onVisibilityChanged, remoteParticipantsCount, + isActiveSpeakerInSpeakerView, } = props; const { @@ -83,7 +85,6 @@ export const GroupCallRemoteParticipant: React.FC = React.memo( sharingScreen, title, videoAspectRatio, - presenting, } = props.remoteParticipant; const isSpeaking = useValueAtFixedRate( @@ -281,7 +282,7 @@ export const GroupCallRemoteParticipant: React.FC = React.memo( className={classNames( 'module-ongoing-call__group-call-remote-participant', isSpeaking && - !presenting && + !isActiveSpeakerInSpeakerView && remoteParticipantsCount > 1 && 'module-ongoing-call__group-call-remote-participant--speaking' )} diff --git a/ts/components/GroupCallRemoteParticipants.tsx b/ts/components/GroupCallRemoteParticipants.tsx index 54e7c11aea..477a79a593 100644 --- a/ts/components/GroupCallRemoteParticipants.tsx +++ b/ts/components/GroupCallRemoteParticipants.tsx @@ -296,6 +296,7 @@ export function GroupCallRemoteParticipants({ top={top} width={renderedWidth} remoteParticipantsCount={remoteParticipants.length} + isActiveSpeakerInSpeakerView={isInSpeakerView} /> ); });