refactor(ui/player): fix player toggle method

This commit is contained in:
sylenien 2022-11-23 11:25:00 +01:00
parent b00bc4fe9a
commit a1441c16c6

View file

@ -22,6 +22,7 @@ function Overlay({
}: Props) {
const { player, store } = React.useContext(PlayerContext)
const togglePlay = () => player.togglePlay()
const {
playing,
messagesLoading,
@ -57,7 +58,7 @@ function Overlay({
}
{ loading ? <Loader /> : null }
{ showPlayIconLayer &&
<PlayIconLayer playing={playing} togglePlay={player.togglePlay} />
<PlayIconLayer playing={playing} togglePlay={togglePlay} />
}
{ markedTargets && <ElementsMarker targets={ markedTargets } activeIndex={activeTargetIndex}/>
}