fix(video): prevent preview/presentation playback loop
- Avoid per-render target.set dispatch that reset playback - Stop timer-based and per-frame React ticking while playing - Add regression tests for render-loop sources Made-with: Cursor
This commit is contained in:
@@ -53,7 +53,16 @@ export function PresentationView({
|
||||
} else {
|
||||
el.pause();
|
||||
}
|
||||
}, [scene?.previewAssetId, scene?.previewAssetType, vp]);
|
||||
// eslint-disable-next-line react-hooks/exhaustive-deps -- avoid reruns on 500ms heartbeats (serverNowMs-only updates)
|
||||
}, [
|
||||
scene?.previewAssetId,
|
||||
scene?.previewAssetType,
|
||||
previewUrl,
|
||||
vp?.revision,
|
||||
vp?.targetAssetId,
|
||||
vp?.playing,
|
||||
vp?.playbackRate,
|
||||
]);
|
||||
|
||||
return (
|
||||
<div className={styles.root}>
|
||||
|
||||
Reference in New Issue
Block a user