Skip to content

🎥 Make videos programmatically with React

Adapt Activity discovery to committed loading handles

JonnyBurger782a36a7fced
diff --git a/packages/core/src/animated-image/AnimatedImage.tsx b/packages/core/src/animated-image/AnimatedImage.tsx
index e2e916d807..87172bde4e 100644
--- a/packages/core/src/animated-image/AnimatedImage.tsx
+++ b/packages/core/src/animated-image/AnimatedImage.tsx
@@ -402,6 +402,8 @@ const AnimatedImageInner = ({
_remotionInternalIsPostmounting={postmountingActive}
{...sequenceProps}
>
+ {/* Hidden Activity cleans up effects but retains state. Unmount the
+ decoder so reactivation cannot reuse one that cleanup has closed. */}
<SequenceContent>
<AnimatedImageContent
{...animatedImageProps}
@@ -507,12 +509,10 @@ const AnimatedImageComponent = (
const resolvedSrc = resolveAnimatedImageSource(props.src);
const requestInitKey = serializeRequestInit(props.requestInit);
return (
- <SequenceContent>
- <AnimatedImageWithIntrinsicDuration
- key={`${resolvedSrc}-${requestInitKey}-${props.trimBefore ?? 0}`}
- {...props}
- />
- </SequenceContent>
+ <AnimatedImageWithIntrinsicDuration
+ {...props}
+ key={`${resolvedSrc}-${requestInitKey}-${props.trimBefore ?? 0}`}
+ />
);
}
diff --git a/packages/gif/src/Gif.tsx b/packages/gif/src/Gif.tsx
index 42289f229c..f8ded44b4d 100644
--- a/packages/gif/src/Gif.tsx
+++ b/packages/gif/src/Gif.tsx
@@ -162,7 +162,7 @@ const GifInner = ({
_remotionInternalIsPostmounting={postmountingActive}
{...sequenceProps}
>
- <Internals.SequenceContent>{inner}</Internals.SequenceContent>
+ {inner}
</Sequence>
</Freeze>
);
@@ -260,12 +260,10 @@ const GifComponent = (
requestInit: props.requestInit,
});
return (
- <Internals.SequenceContent>
- <GifWithIntrinsicDuration
- key={`${cacheKey}-${props.trimBefore ?? 0}`}
- {...props}
- />
- </Internals.SequenceContent>
+ <GifWithIntrinsicDuration
+ {...props}
+ key={`${cacheKey}-${props.trimBefore ?? 0}`}
+ />
);
}
diff --git a/packages/light-leaks/src/LightLeak.tsx b/packages/light-leaks/src/LightLeak.tsx
index a31e435a00..1181b39dd9 100644
--- a/packages/light-leaks/src/LightLeak.tsx
+++ b/packages/light-leaks/src/LightLeak.tsx
@@ -296,9 +296,7 @@ const LightLeakInner: React.FC<
{...sequenceProps}
style={style}
>
- <Internals.SequenceContent>
- <LightLeakCanvas seed={seed} hueShift={hueShift} />
- </Internals.SequenceContent>
+ <LightLeakCanvas seed={seed} hueShift={hueShift} />
</Sequence>
);
};