import { useCallStateHooks } from "@stream-io/video-react-sdk";
export const SpeakingWhileMutedNotification = () => {
const { useMicrophoneState } = useCallStateHooks();
const { isSpeakingWhileMuted } = useMicrophoneState();
if (!isSpeakingWhileMuted) return null;
return <div>You are muted</div>;
};
Speaking While Muted
In this cookbook, we will explore the ways to remind users they are speaking while being muted.
The React SDK bundles SpeakingWhileMutedNotification
component, but we will discover how to build our own component.
Speaking-while-muted notification component
Our speaking-while-muted notification component will be based on simple principle of reading the isSpeakingWhileMuted
state of the currently selected mic.
The UI will be rendered only, when isSpeakingWhileMuted
is set to true
.
- I'm working with the Stream Video React SDK and would like to ask questions about this documentation page: https://getstream.io/video/docs/react/ui-cookbook/speaking-while-muted.md
- View as markdown
- Open in ChatGPT
- Open in Claude
On this page: