Hide progress bar on embed player until video starts

Restores conditional logic to hide the progress bar for embed players until playback begins, ensuring regular players display the progress bar as expected.
This commit is contained in:
Yiannis Christodoulou 2025-10-11 03:17:29 +03:00
parent 30fdfaf452
commit 62ce066910

View File

@ -2754,13 +2754,13 @@ function VideoJSPlayer({ videoId = 'default-video' }) {
// Initial sync // Initial sync
syncProgressVisibility(); syncProgressVisibility();
// if (isEmbedPlayer) { // For embed players only, hide until video starts
// Initial sync - hide until video starts if (isEmbedPlayer) {
progressEl.style.opacity = '0'; progressEl.style.opacity = '0';
progressEl.style.visibility = 'hidden'; progressEl.style.visibility = 'hidden';
// } }
// Show when video starts // Show when video starts (for embed players) or ensure visibility (for regular players)
const showOnPlay = () => { const showOnPlay = () => {
syncProgressVisibility(); syncProgressVisibility();
playerRef.current.off('play', showOnPlay); playerRef.current.off('play', showOnPlay);