Skip to content

Commit

Permalink
Update peek element for canvas mode
Browse files Browse the repository at this point in the history
  • Loading branch information
DustinBrett committed Feb 16, 2025
1 parent f51ea0d commit 4c82b82
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion components/apps/VideoPlayer/useVideoPlayer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -112,8 +112,18 @@ const useVideoPlayer = ({
videoPlayer?.controlBar.pictureInPictureToggle.show();
videoPlayer?.controlBar.fullscreenToggle.show();
}

linkElement(
id,
"peekElement",
enable
? canvasElement
: isYT
? (containerRef.current as HTMLDivElement)
: videoElement
);
},
[containerRef]
[containerRef, id, isYT, linkElement]
);
const loadPlayer = useCallback(() => {
if (playerInitialized.current) return;
Expand Down

0 comments on commit 4c82b82

Please sign in to comment.