Skip to content

Commit

Permalink
Merge pull request #2208 from saithsab877/Listen-Button-Does-Not-Change
Browse files Browse the repository at this point in the history
[AI Search]: `Listen` Button Does Not Change State After `TLDR` Content Is Read Aloud from AI Search Sources
  • Loading branch information
Rassl authored Sep 25, 2024
2 parents cca8ef7 + 0dac386 commit d3f0d4e
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -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) {
Expand Down

0 comments on commit d3f0d4e

Please sign in to comment.