diff --git a/src/components/App/SideBar/SelectedNodeView/Default/index.tsx b/src/components/App/SideBar/SelectedNodeView/Default/index.tsx index 752547c7d..225d94c66 100644 --- a/src/components/App/SideBar/SelectedNodeView/Default/index.tsx +++ b/src/components/App/SideBar/SelectedNodeView/Default/index.tsx @@ -37,7 +37,11 @@ export const Default = () => { audioElement.removeEventListener('ended', onAudioPlaybackComplete) } } - }, [setCurrentPlayingAudio]) + }, [setCurrentPlayingAudio, isPlaying]) + + useEffect(() => { + setIsPlaying(false) + }, [selectedNode]) const togglePlay = () => { if (currentPlayingAudio?.current && currentPlayingAudio.current !== audioRef.current) {