Skip to content

armgit / Cap

Public Imported from GitHub
0

Open source Loom alternative. Beautiful, shareable screen recordings.

feat(web): add allowSegmentProbeDuringUpload to HLS player

Richie McIlroyda0bb5a19c7f
diff --git a/apps/web/app/s/[videoId]/_components/HLSVideoPlayer.tsx b/apps/web/app/s/[videoId]/_components/HLSVideoPlayer.tsx
index 9fb8cc9d1..7d0b7260c 100644
--- a/apps/web/app/s/[videoId]/_components/HLSVideoPlayer.tsx
+++ b/apps/web/app/s/[videoId]/_components/HLSVideoPlayer.tsx
@@ -90,6 +90,7 @@ interface Props {
autoplay?: boolean;
hasActiveUpload?: boolean;
isLiveSegments?: boolean;
+ allowSegmentProbeDuringUpload?: boolean;
enhancedAudioUrl?: string | null;
enhancedAudioStatus?: EnhancedAudioStatus | null;
captionLanguage?: string;
@@ -111,6 +112,7 @@ export function HLSVideoPlayer({
autoplay = false,
hasActiveUpload,
isLiveSegments = false,
+ allowSegmentProbeDuringUpload = false,
disableCaptions,
enhancedAudioUrl: _enhancedAudioUrl,
enhancedAudioStatus: _enhancedAudioStatus,
@@ -166,6 +168,7 @@ export function HLSVideoPlayer({
hasActiveUpload || false,
);
const shouldDelayPlaybackSource =
+ !allowSegmentProbeDuringUpload &&
shouldDeferPlaybackSource(uploadProgressRaw);
const liveProbeSrc = isLiveSegments ? getLiveProbeSrc(playbackSrc) : null;