save video dimensions in onLoadedData instead of onLoadedMetadata

This commit is contained in:
Josh Hawkins 2024-05-26 18:36:29 -05:00
parent c2eac10925
commit 9835513cb8

View File

@ -303,8 +303,10 @@ function MSEPlayer({
className={className}
playsInline
preload="auto"
onLoadedData={onPlaying}
onLoadedMetadata={handleLoadedMetadata}
onLoadedData={() => {
handleLoadedMetadata?.();
onPlaying?.();
}}
muted={!audioEnabled}
onError={() => {
if (wsRef.current) {