diff --git a/ts/components/GroupCallRemoteParticipant.stories.tsx b/ts/components/GroupCallRemoteParticipant.stories.tsx index 639ebfa479fb..f02846ea68be 100644 --- a/ts/components/GroupCallRemoteParticipant.stories.tsx +++ b/ts/components/GroupCallRemoteParticipant.stories.tsx @@ -192,3 +192,43 @@ export function NoMediaKeys(): JSX.Element { /> ); } + +export function NoMediaKeysBlockedIntermittent(): JSX.Element { + const [isBlocked, setIsBlocked] = React.useState(false); + React.useEffect(() => { + const interval = setInterval(() => { + setIsBlocked(value => !value); + }, 6000); + + return () => clearInterval(interval); + }, [isBlocked]); + + const [mediaKeysReceived, setMediaKeysReceived] = React.useState(false); + React.useEffect(() => { + const interval = setInterval(() => { + setMediaKeysReceived(value => !value); + }, 3000); + + return () => clearInterval(interval); + }, [mediaKeysReceived]); + + return ( + + ); +} diff --git a/ts/components/GroupCallRemoteParticipant.tsx b/ts/components/GroupCallRemoteParticipant.tsx index 42c26cbe8d6b..cf4b1d32f9c2 100644 --- a/ts/components/GroupCallRemoteParticipant.tsx +++ b/ts/components/GroupCallRemoteParticipant.tsx @@ -304,8 +304,6 @@ export const GroupCallRemoteParticipant: React.FC = React.memo( } let noVideoNode: ReactNode; - let errorDialogTitle: ReactNode; - let errorDialogBody = ''; if (!hasVideoToShow) { const showDialogButton = (