@remotion/promo-pages 4.0.387 → 4.0.390
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/Homepage.js +92 -91
- package/dist/Users/jonathanburger/remotion/packages/promo-pages/dist/Homepage.js +92 -91
- package/dist/Users/jonathanburger/remotion/packages/promo-pages/dist/design.js +52 -51
- package/dist/Users/jonathanburger/remotion/packages/promo-pages/dist/homepage/Pricing.js +52 -51
- package/dist/Users/jonathanburger/remotion/packages/promo-pages/dist/template-modal-content.js +58 -57
- package/dist/Users/jonathanburger/remotion/packages/promo-pages/dist/templates.js +52 -51
- package/dist/design.js +52 -51
- package/dist/homepage/Pricing.js +52 -51
- package/dist/template-modal-content.js +58 -57
- package/dist/templates.js +52 -51
- package/package.json +12 -12
|
@@ -96,9 +96,9 @@ import {
|
|
|
96
96
|
useImperativeHandle as useImperativeHandle5,
|
|
97
97
|
useLayoutEffect as useLayoutEffect3,
|
|
98
98
|
useMemo as useMemo11,
|
|
99
|
+
useRef as useRef5,
|
|
99
100
|
useState as useState8
|
|
100
101
|
} from "react";
|
|
101
|
-
import { flushSync } from "react-dom";
|
|
102
102
|
import { jsx as jsx12 } from "react/jsx-runtime";
|
|
103
103
|
import { forwardRef as forwardRef6, useCallback as useCallback11, useContext as useContext27 } from "react";
|
|
104
104
|
import React12, { createContext as createContext13, useMemo as useMemo12 } from "react";
|
|
@@ -114,22 +114,22 @@ import {
|
|
|
114
114
|
useEffect as useEffect12,
|
|
115
115
|
useImperativeHandle as useImperativeHandle6,
|
|
116
116
|
useMemo as useMemo21,
|
|
117
|
-
useRef as
|
|
117
|
+
useRef as useRef13,
|
|
118
118
|
useState as useState15
|
|
119
119
|
} from "react";
|
|
120
|
-
import { useContext as useContext17, useLayoutEffect as useLayoutEffect5, useRef as
|
|
120
|
+
import { useContext as useContext17, useLayoutEffect as useLayoutEffect5, useRef as useRef8 } from "react";
|
|
121
121
|
import React15, {
|
|
122
122
|
createContext as createContext16,
|
|
123
123
|
createRef as createRef2,
|
|
124
124
|
useCallback as useCallback7,
|
|
125
125
|
useContext as useContext16,
|
|
126
126
|
useMemo as useMemo15,
|
|
127
|
-
useRef as
|
|
127
|
+
useRef as useRef6,
|
|
128
128
|
useState as useState11
|
|
129
129
|
} from "react";
|
|
130
130
|
import { useMemo as useMemo14 } from "react";
|
|
131
131
|
import { jsx as jsx16, jsxs as jsxs2 } from "react/jsx-runtime";
|
|
132
|
-
import { useRef as
|
|
132
|
+
import { useRef as useRef7 } from "react";
|
|
133
133
|
import { useContext as useContext19, useEffect as useEffect6, useMemo as useMemo16, useState as useState12 } from "react";
|
|
134
134
|
import { useContext as useContext18 } from "react";
|
|
135
135
|
import {
|
|
@@ -137,9 +137,9 @@ import {
|
|
|
137
137
|
useContext as useContext22,
|
|
138
138
|
useEffect as useEffect10,
|
|
139
139
|
useLayoutEffect as useLayoutEffect7,
|
|
140
|
-
useRef as
|
|
140
|
+
useRef as useRef12
|
|
141
141
|
} from "react";
|
|
142
|
-
import { useCallback as useCallback9, useMemo as useMemo19, useRef as
|
|
142
|
+
import { useCallback as useCallback9, useMemo as useMemo19, useRef as useRef10 } from "react";
|
|
143
143
|
import { useContext as useContext21, useMemo as useMemo18 } from "react";
|
|
144
144
|
import React16, {
|
|
145
145
|
useCallback as useCallback8,
|
|
@@ -147,13 +147,13 @@ import React16, {
|
|
|
147
147
|
useEffect as useEffect7,
|
|
148
148
|
useLayoutEffect as useLayoutEffect6,
|
|
149
149
|
useMemo as useMemo17,
|
|
150
|
-
useRef as
|
|
150
|
+
useRef as useRef9,
|
|
151
151
|
useState as useState13
|
|
152
152
|
} from "react";
|
|
153
153
|
import { jsx as jsx17 } from "react/jsx-runtime";
|
|
154
154
|
import React17 from "react";
|
|
155
155
|
import { useEffect as useEffect8, useState as useState14 } from "react";
|
|
156
|
-
import { useEffect as useEffect9, useRef as
|
|
156
|
+
import { useEffect as useEffect9, useRef as useRef11 } from "react";
|
|
157
157
|
import { useContext as useContext23, useEffect as useEffect11 } from "react";
|
|
158
158
|
import { createContext as createContext17, useContext as useContext24, useMemo as useMemo20 } from "react";
|
|
159
159
|
import { jsx as jsx18 } from "react/jsx-runtime";
|
|
@@ -164,7 +164,7 @@ import {
|
|
|
164
164
|
useImperativeHandle as useImperativeHandle7,
|
|
165
165
|
useLayoutEffect as useLayoutEffect8,
|
|
166
166
|
useMemo as useMemo222,
|
|
167
|
-
useRef as
|
|
167
|
+
useRef as useRef14
|
|
168
168
|
} from "react";
|
|
169
169
|
import { jsx as jsx19 } from "react/jsx-runtime";
|
|
170
170
|
import { jsx as jsx20 } from "react/jsx-runtime";
|
|
@@ -183,7 +183,7 @@ import {
|
|
|
183
183
|
useContext as useContext30,
|
|
184
184
|
useImperativeHandle as useImperativeHandle8,
|
|
185
185
|
useLayoutEffect as useLayoutEffect9,
|
|
186
|
-
useRef as
|
|
186
|
+
useRef as useRef15
|
|
187
187
|
} from "react";
|
|
188
188
|
import { jsx as jsx25 } from "react/jsx-runtime";
|
|
189
189
|
import { createRef as createRef3 } from "react";
|
|
@@ -192,7 +192,7 @@ import {
|
|
|
192
192
|
useCallback as useCallback14,
|
|
193
193
|
useImperativeHandle as useImperativeHandle9,
|
|
194
194
|
useMemo as useMemo25,
|
|
195
|
-
useRef as
|
|
195
|
+
useRef as useRef16,
|
|
196
196
|
useState as useState17
|
|
197
197
|
} from "react";
|
|
198
198
|
import { jsx as jsx26 } from "react/jsx-runtime";
|
|
@@ -218,7 +218,7 @@ import {
|
|
|
218
218
|
useEffect as useEffect19,
|
|
219
219
|
useImperativeHandle as useImperativeHandle10,
|
|
220
220
|
useMemo as useMemo29,
|
|
221
|
-
useRef as
|
|
221
|
+
useRef as useRef17,
|
|
222
222
|
useState as useState20
|
|
223
223
|
} from "react";
|
|
224
224
|
import { useEffect as useEffect18 } from "react";
|
|
@@ -240,7 +240,7 @@ import {
|
|
|
240
240
|
useImperativeHandle as useImperativeHandle11,
|
|
241
241
|
useLayoutEffect as useLayoutEffect11,
|
|
242
242
|
useMemo as useMemo32,
|
|
243
|
-
useRef as
|
|
243
|
+
useRef as useRef18
|
|
244
244
|
} from "react";
|
|
245
245
|
import { jsx as jsx35 } from "react/jsx-runtime";
|
|
246
246
|
import { jsx as jsx36 } from "react/jsx-runtime";
|
|
@@ -755,7 +755,7 @@ var __defProp2, __export2 = (target, all) => {
|
|
|
755
755
|
});
|
|
756
756
|
}, useIsPlayer = () => {
|
|
757
757
|
return useContext(IsPlayerContext);
|
|
758
|
-
}, VERSION = "4.0.
|
|
758
|
+
}, VERSION = "4.0.390", checkMultipleRemotionVersions = () => {
|
|
759
759
|
if (typeof globalThis === "undefined") {
|
|
760
760
|
return;
|
|
761
761
|
}
|
|
@@ -2430,37 +2430,38 @@ Check that all your Remotion packages are on the same version. If your dependenc
|
|
|
2430
2430
|
validateContent(artifact.content);
|
|
2431
2431
|
}, RenderAssetManager, RenderAssetManagerProvider = ({ children, collectAssets }) => {
|
|
2432
2432
|
const [renderAssets, setRenderAssets] = useState8([]);
|
|
2433
|
+
const renderAssetsRef = useRef5([]);
|
|
2433
2434
|
const registerRenderAsset = useCallback6((renderAsset) => {
|
|
2434
2435
|
validateRenderAsset(renderAsset);
|
|
2435
|
-
|
|
2436
|
-
|
|
2437
|
-
});
|
|
2436
|
+
renderAssetsRef.current = [...renderAssetsRef.current, renderAsset];
|
|
2437
|
+
setRenderAssets(renderAssetsRef.current);
|
|
2438
2438
|
}, []);
|
|
2439
2439
|
if (collectAssets) {
|
|
2440
2440
|
useImperativeHandle5(collectAssets, () => {
|
|
2441
2441
|
return {
|
|
2442
2442
|
collectAssets: () => {
|
|
2443
|
-
|
|
2444
|
-
|
|
2445
|
-
|
|
2446
|
-
return
|
|
2443
|
+
const assets = renderAssetsRef.current;
|
|
2444
|
+
renderAssetsRef.current = [];
|
|
2445
|
+
setRenderAssets([]);
|
|
2446
|
+
return assets;
|
|
2447
2447
|
}
|
|
2448
2448
|
};
|
|
2449
|
-
}, [
|
|
2449
|
+
}, []);
|
|
2450
2450
|
}
|
|
2451
2451
|
const unregisterRenderAsset = useCallback6((id) => {
|
|
2452
|
-
|
|
2453
|
-
|
|
2454
|
-
});
|
|
2452
|
+
renderAssetsRef.current = renderAssetsRef.current.filter((a) => a.id !== id);
|
|
2453
|
+
setRenderAssets(renderAssetsRef.current);
|
|
2455
2454
|
}, []);
|
|
2456
2455
|
useLayoutEffect3(() => {
|
|
2457
2456
|
if (typeof window !== "undefined") {
|
|
2458
2457
|
window.remotion_collectAssets = () => {
|
|
2458
|
+
const assets = renderAssetsRef.current;
|
|
2459
|
+
renderAssetsRef.current = [];
|
|
2459
2460
|
setRenderAssets([]);
|
|
2460
|
-
return
|
|
2461
|
+
return assets;
|
|
2461
2462
|
};
|
|
2462
2463
|
}
|
|
2463
|
-
}, [
|
|
2464
|
+
}, []);
|
|
2464
2465
|
const contextValue = useMemo11(() => {
|
|
2465
2466
|
return {
|
|
2466
2467
|
registerRenderAsset,
|
|
@@ -3061,7 +3062,7 @@ Check that all your Remotion packages are on the same version. If your dependenc
|
|
|
3061
3062
|
}
|
|
3062
3063
|
return true;
|
|
3063
3064
|
}, SharedAudioContext, SharedAudioContextProvider = ({ children, numberOfAudioTags, audioLatencyHint }) => {
|
|
3064
|
-
const audios =
|
|
3065
|
+
const audios = useRef6([]);
|
|
3065
3066
|
const [initialNumberOfAudioTags] = useState11(numberOfAudioTags);
|
|
3066
3067
|
if (numberOfAudioTags !== initialNumberOfAudioTags) {
|
|
3067
3068
|
throw new Error("The number of shared audio tags has changed dynamically. Once you have set this property, you cannot change it afterwards.");
|
|
@@ -3081,7 +3082,7 @@ Check that all your Remotion packages are on the same version. If your dependenc
|
|
|
3081
3082
|
};
|
|
3082
3083
|
});
|
|
3083
3084
|
}, [audioContext, numberOfAudioTags]);
|
|
3084
|
-
const takenAudios =
|
|
3085
|
+
const takenAudios = useRef6(new Array(numberOfAudioTags).fill(false));
|
|
3085
3086
|
const rerenderAudios = useCallback7(() => {
|
|
3086
3087
|
refs.forEach(({ ref, id }) => {
|
|
3087
3088
|
const data = audios.current?.find((a) => a.id === id);
|
|
@@ -3337,9 +3338,9 @@ Check that all your Remotion packages are on the same version. If your dependenc
|
|
|
3337
3338
|
duration: initialDuration,
|
|
3338
3339
|
fps
|
|
3339
3340
|
}) => {
|
|
3340
|
-
const actualFromRef =
|
|
3341
|
-
const actualDuration =
|
|
3342
|
-
const actualSrc =
|
|
3341
|
+
const actualFromRef = useRef7(initialActualFrom);
|
|
3342
|
+
const actualDuration = useRef7(initialDuration);
|
|
3343
|
+
const actualSrc = useRef7(initialActualSrc);
|
|
3343
3344
|
if (!isSubsetOfDuration({
|
|
3344
3345
|
prevStartFrom: actualFromRef.current,
|
|
3345
3346
|
newStartFrom: initialActualFrom,
|
|
@@ -3373,8 +3374,8 @@ Check that all your Remotion packages are on the same version. If your dependenc
|
|
|
3373
3374
|
source,
|
|
3374
3375
|
shouldUseWebAudioApi
|
|
3375
3376
|
}) => {
|
|
3376
|
-
const audioStuffRef =
|
|
3377
|
-
const currentVolumeRef =
|
|
3377
|
+
const audioStuffRef = useRef8(null);
|
|
3378
|
+
const currentVolumeRef = useRef8(volume);
|
|
3378
3379
|
currentVolumeRef.current = volume;
|
|
3379
3380
|
const sharedAudioContext = useContext17(SharedAudioContext);
|
|
3380
3381
|
if (!sharedAudioContext) {
|
|
@@ -3623,7 +3624,7 @@ Check that all your Remotion packages are on the same version. If your dependenc
|
|
|
3623
3624
|
const [blocks, setBlocks] = useState13([]);
|
|
3624
3625
|
const [onBufferingCallbacks, setOnBufferingCallbacks] = useState13([]);
|
|
3625
3626
|
const [onResumeCallbacks, setOnResumeCallbacks] = useState13([]);
|
|
3626
|
-
const buffering =
|
|
3627
|
+
const buffering = useRef9(false);
|
|
3627
3628
|
const addBlock = useCallback8((block) => {
|
|
3628
3629
|
setBlocks((b) => [...b, block]);
|
|
3629
3630
|
return {
|
|
@@ -3734,7 +3735,7 @@ Check that all your Remotion packages are on the same version. If your dependenc
|
|
|
3734
3735
|
logLevel,
|
|
3735
3736
|
mountTime
|
|
3736
3737
|
}) => {
|
|
3737
|
-
const bufferingRef =
|
|
3738
|
+
const bufferingRef = useRef10(false);
|
|
3738
3739
|
const { delayPlayback } = useBufferState();
|
|
3739
3740
|
const bufferUntilFirstFrame = useCallback9((requestedTime) => {
|
|
3740
3741
|
if (mediaType !== "video") {
|
|
@@ -3984,7 +3985,7 @@ Check that all your Remotion packages are on the same version. If your dependenc
|
|
|
3984
3985
|
lastSeek,
|
|
3985
3986
|
onVariableFpsVideoDetected
|
|
3986
3987
|
}) => {
|
|
3987
|
-
const currentTime =
|
|
3988
|
+
const currentTime = useRef11(null);
|
|
3988
3989
|
useEffect9(() => {
|
|
3989
3990
|
const { current } = mediaRef;
|
|
3990
3991
|
if (current) {
|
|
@@ -4108,14 +4109,14 @@ Check that all your Remotion packages are on the same version. If your dependenc
|
|
|
4108
4109
|
const buffering = useContext22(BufferingContextReact);
|
|
4109
4110
|
const { fps } = useVideoConfig();
|
|
4110
4111
|
const mediaStartsAt = useMediaStartsAt();
|
|
4111
|
-
const lastSeekDueToShift =
|
|
4112
|
-
const lastSeek =
|
|
4112
|
+
const lastSeekDueToShift = useRef12(null);
|
|
4113
|
+
const lastSeek = useRef12(null);
|
|
4113
4114
|
const logLevel = useLogLevel();
|
|
4114
4115
|
const mountTime = useMountTime();
|
|
4115
4116
|
if (!buffering) {
|
|
4116
4117
|
throw new Error("useMediaPlayback must be used inside a <BufferingContext>");
|
|
4117
4118
|
}
|
|
4118
|
-
const isVariableFpsVideoMap =
|
|
4119
|
+
const isVariableFpsVideoMap = useRef12({});
|
|
4119
4120
|
const onVariableFpsVideoDetected = useCallback10(() => {
|
|
4120
4121
|
if (!src) {
|
|
4121
4122
|
return;
|
|
@@ -4531,7 +4532,7 @@ Check that all your Remotion packages are on the same version. If your dependenc
|
|
|
4531
4532
|
useImperativeHandle6(ref, () => {
|
|
4532
4533
|
return audioRef.current;
|
|
4533
4534
|
}, [audioRef]);
|
|
4534
|
-
const currentOnDurationCallback =
|
|
4535
|
+
const currentOnDurationCallback = useRef13(onDuration);
|
|
4535
4536
|
currentOnDurationCallback.current = onDuration;
|
|
4536
4537
|
useEffect12(() => {
|
|
4537
4538
|
const { current } = audioRef;
|
|
@@ -4560,7 +4561,7 @@ Check that all your Remotion packages are on the same version. If your dependenc
|
|
|
4560
4561
|
...propsToPass
|
|
4561
4562
|
});
|
|
4562
4563
|
}, AudioForPreview, AudioForRenderingRefForwardingFunction = (props, ref) => {
|
|
4563
|
-
const audioRef =
|
|
4564
|
+
const audioRef = useRef14(null);
|
|
4564
4565
|
const {
|
|
4565
4566
|
volume: volumeProp,
|
|
4566
4567
|
playbackRate,
|
|
@@ -5067,8 +5068,8 @@ Check that all your Remotion packages are on the same version. If your dependenc
|
|
|
5067
5068
|
crossOrigin,
|
|
5068
5069
|
...props2
|
|
5069
5070
|
}, ref) => {
|
|
5070
|
-
const imageRef =
|
|
5071
|
-
const errors =
|
|
5071
|
+
const imageRef = useRef15(null);
|
|
5072
|
+
const errors = useRef15({});
|
|
5072
5073
|
const { delayPlayback } = useBufferState();
|
|
5073
5074
|
const sequenceContext = useContext30(SequenceContext);
|
|
5074
5075
|
if (!src) {
|
|
@@ -5207,7 +5208,7 @@ Check that all your Remotion packages are on the same version. If your dependenc
|
|
|
5207
5208
|
const [folders, setFolders] = useState17([]);
|
|
5208
5209
|
const [canvasContent, setCanvasContent] = useState17(initialCanvasContent);
|
|
5209
5210
|
const [compositions, setCompositions] = useState17(initialCompositions);
|
|
5210
|
-
const currentcompositionsRef =
|
|
5211
|
+
const currentcompositionsRef = useRef16(compositions);
|
|
5211
5212
|
const updateCompositions = useCallback14((updateComps) => {
|
|
5212
5213
|
setCompositions((comps) => {
|
|
5213
5214
|
const updated = updateComps(comps);
|
|
@@ -5726,7 +5727,7 @@ Check that all your Remotion packages are on the same version. If your dependenc
|
|
|
5726
5727
|
if (!context) {
|
|
5727
5728
|
throw new Error("SharedAudioContext not found");
|
|
5728
5729
|
}
|
|
5729
|
-
const videoRef =
|
|
5730
|
+
const videoRef = useRef17(null);
|
|
5730
5731
|
const sharedSource = useMemo29(() => {
|
|
5731
5732
|
if (!context.audioContext) {
|
|
5732
5733
|
return null;
|
|
@@ -5874,7 +5875,7 @@ Check that all your Remotion packages are on the same version. If your dependenc
|
|
|
5874
5875
|
current.removeEventListener("error", errorHandler);
|
|
5875
5876
|
};
|
|
5876
5877
|
}, [onError, src]);
|
|
5877
|
-
const currentOnDurationCallback =
|
|
5878
|
+
const currentOnDurationCallback = useRef17(onDuration);
|
|
5878
5879
|
currentOnDurationCallback.current = onDuration;
|
|
5879
5880
|
useEmitVideoFrame({ ref: videoRef, onVideoFrame });
|
|
5880
5881
|
useEffect19(() => {
|
|
@@ -6450,7 +6451,7 @@ Check that all your Remotion packages are on the same version. If your dependenc
|
|
|
6450
6451
|
const frame = useCurrentFrame();
|
|
6451
6452
|
const volumePropsFrame = useFrameForVolumeProp(loopVolumeCurveBehavior ?? "repeat");
|
|
6452
6453
|
const videoConfig = useUnsafeVideoConfig();
|
|
6453
|
-
const videoRef =
|
|
6454
|
+
const videoRef = useRef18(null);
|
|
6454
6455
|
const sequenceContext = useContext34(SequenceContext);
|
|
6455
6456
|
const mediaStartsAt = useMediaStartsAt();
|
|
6456
6457
|
const environment = useRemotionEnvironment();
|
|
@@ -12724,7 +12725,7 @@ var extrudeAndTransformElement = (options) => {
|
|
|
12724
12725
|
init_esm();
|
|
12725
12726
|
import { jsx as jsx37, Fragment } from "react/jsx-runtime";
|
|
12726
12727
|
import { jsx as jsx210, jsxs as jsxs3 } from "react/jsx-runtime";
|
|
12727
|
-
import { useEffect as useEffect22, useMemo as useMemo210, useRef as
|
|
12728
|
+
import { useEffect as useEffect22, useMemo as useMemo210, useRef as useRef19 } from "react";
|
|
12728
12729
|
import { jsx as jsx38 } from "react/jsx-runtime";
|
|
12729
12730
|
import { jsx as jsx43, jsxs as jsxs23 } from "react/jsx-runtime";
|
|
12730
12731
|
import React42 from "react";
|
|
@@ -13079,7 +13080,7 @@ var Spinner = ({ size, duration }) => {
|
|
|
13079
13080
|
height: size
|
|
13080
13081
|
};
|
|
13081
13082
|
}, [size]);
|
|
13082
|
-
const pathsRef =
|
|
13083
|
+
const pathsRef = useRef19([]);
|
|
13083
13084
|
useEffect22(() => {
|
|
13084
13085
|
const animate = () => {
|
|
13085
13086
|
const now = performance.now();
|
|
@@ -96,9 +96,9 @@ import {
|
|
|
96
96
|
useImperativeHandle as useImperativeHandle5,
|
|
97
97
|
useLayoutEffect as useLayoutEffect3,
|
|
98
98
|
useMemo as useMemo11,
|
|
99
|
+
useRef as useRef5,
|
|
99
100
|
useState as useState8
|
|
100
101
|
} from "react";
|
|
101
|
-
import { flushSync } from "react-dom";
|
|
102
102
|
import { jsx as jsx12 } from "react/jsx-runtime";
|
|
103
103
|
import { forwardRef as forwardRef6, useCallback as useCallback11, useContext as useContext27 } from "react";
|
|
104
104
|
import React12, { createContext as createContext13, useMemo as useMemo12 } from "react";
|
|
@@ -114,22 +114,22 @@ import {
|
|
|
114
114
|
useEffect as useEffect12,
|
|
115
115
|
useImperativeHandle as useImperativeHandle6,
|
|
116
116
|
useMemo as useMemo21,
|
|
117
|
-
useRef as
|
|
117
|
+
useRef as useRef13,
|
|
118
118
|
useState as useState15
|
|
119
119
|
} from "react";
|
|
120
|
-
import { useContext as useContext17, useLayoutEffect as useLayoutEffect5, useRef as
|
|
120
|
+
import { useContext as useContext17, useLayoutEffect as useLayoutEffect5, useRef as useRef8 } from "react";
|
|
121
121
|
import React15, {
|
|
122
122
|
createContext as createContext16,
|
|
123
123
|
createRef as createRef2,
|
|
124
124
|
useCallback as useCallback7,
|
|
125
125
|
useContext as useContext16,
|
|
126
126
|
useMemo as useMemo15,
|
|
127
|
-
useRef as
|
|
127
|
+
useRef as useRef6,
|
|
128
128
|
useState as useState11
|
|
129
129
|
} from "react";
|
|
130
130
|
import { useMemo as useMemo14 } from "react";
|
|
131
131
|
import { jsx as jsx16, jsxs as jsxs2 } from "react/jsx-runtime";
|
|
132
|
-
import { useRef as
|
|
132
|
+
import { useRef as useRef7 } from "react";
|
|
133
133
|
import { useContext as useContext19, useEffect as useEffect6, useMemo as useMemo16, useState as useState12 } from "react";
|
|
134
134
|
import { useContext as useContext18 } from "react";
|
|
135
135
|
import {
|
|
@@ -137,9 +137,9 @@ import {
|
|
|
137
137
|
useContext as useContext22,
|
|
138
138
|
useEffect as useEffect10,
|
|
139
139
|
useLayoutEffect as useLayoutEffect7,
|
|
140
|
-
useRef as
|
|
140
|
+
useRef as useRef12
|
|
141
141
|
} from "react";
|
|
142
|
-
import { useCallback as useCallback9, useMemo as useMemo19, useRef as
|
|
142
|
+
import { useCallback as useCallback9, useMemo as useMemo19, useRef as useRef10 } from "react";
|
|
143
143
|
import { useContext as useContext21, useMemo as useMemo18 } from "react";
|
|
144
144
|
import React16, {
|
|
145
145
|
useCallback as useCallback8,
|
|
@@ -147,13 +147,13 @@ import React16, {
|
|
|
147
147
|
useEffect as useEffect7,
|
|
148
148
|
useLayoutEffect as useLayoutEffect6,
|
|
149
149
|
useMemo as useMemo17,
|
|
150
|
-
useRef as
|
|
150
|
+
useRef as useRef9,
|
|
151
151
|
useState as useState13
|
|
152
152
|
} from "react";
|
|
153
153
|
import { jsx as jsx17 } from "react/jsx-runtime";
|
|
154
154
|
import React17 from "react";
|
|
155
155
|
import { useEffect as useEffect8, useState as useState14 } from "react";
|
|
156
|
-
import { useEffect as useEffect9, useRef as
|
|
156
|
+
import { useEffect as useEffect9, useRef as useRef11 } from "react";
|
|
157
157
|
import { useContext as useContext23, useEffect as useEffect11 } from "react";
|
|
158
158
|
import { createContext as createContext17, useContext as useContext24, useMemo as useMemo20 } from "react";
|
|
159
159
|
import { jsx as jsx18 } from "react/jsx-runtime";
|
|
@@ -164,7 +164,7 @@ import {
|
|
|
164
164
|
useImperativeHandle as useImperativeHandle7,
|
|
165
165
|
useLayoutEffect as useLayoutEffect8,
|
|
166
166
|
useMemo as useMemo222,
|
|
167
|
-
useRef as
|
|
167
|
+
useRef as useRef14
|
|
168
168
|
} from "react";
|
|
169
169
|
import { jsx as jsx19 } from "react/jsx-runtime";
|
|
170
170
|
import { jsx as jsx20 } from "react/jsx-runtime";
|
|
@@ -183,7 +183,7 @@ import {
|
|
|
183
183
|
useContext as useContext30,
|
|
184
184
|
useImperativeHandle as useImperativeHandle8,
|
|
185
185
|
useLayoutEffect as useLayoutEffect9,
|
|
186
|
-
useRef as
|
|
186
|
+
useRef as useRef15
|
|
187
187
|
} from "react";
|
|
188
188
|
import { jsx as jsx25 } from "react/jsx-runtime";
|
|
189
189
|
import { createRef as createRef3 } from "react";
|
|
@@ -192,7 +192,7 @@ import {
|
|
|
192
192
|
useCallback as useCallback14,
|
|
193
193
|
useImperativeHandle as useImperativeHandle9,
|
|
194
194
|
useMemo as useMemo25,
|
|
195
|
-
useRef as
|
|
195
|
+
useRef as useRef16,
|
|
196
196
|
useState as useState17
|
|
197
197
|
} from "react";
|
|
198
198
|
import { jsx as jsx26 } from "react/jsx-runtime";
|
|
@@ -218,7 +218,7 @@ import {
|
|
|
218
218
|
useEffect as useEffect19,
|
|
219
219
|
useImperativeHandle as useImperativeHandle10,
|
|
220
220
|
useMemo as useMemo29,
|
|
221
|
-
useRef as
|
|
221
|
+
useRef as useRef17,
|
|
222
222
|
useState as useState20
|
|
223
223
|
} from "react";
|
|
224
224
|
import { useEffect as useEffect18 } from "react";
|
|
@@ -240,7 +240,7 @@ import {
|
|
|
240
240
|
useImperativeHandle as useImperativeHandle11,
|
|
241
241
|
useLayoutEffect as useLayoutEffect11,
|
|
242
242
|
useMemo as useMemo32,
|
|
243
|
-
useRef as
|
|
243
|
+
useRef as useRef18
|
|
244
244
|
} from "react";
|
|
245
245
|
import { jsx as jsx35 } from "react/jsx-runtime";
|
|
246
246
|
import { jsx as jsx36 } from "react/jsx-runtime";
|
|
@@ -755,7 +755,7 @@ var __defProp2, __export2 = (target, all) => {
|
|
|
755
755
|
});
|
|
756
756
|
}, useIsPlayer = () => {
|
|
757
757
|
return useContext(IsPlayerContext);
|
|
758
|
-
}, VERSION = "4.0.
|
|
758
|
+
}, VERSION = "4.0.390", checkMultipleRemotionVersions = () => {
|
|
759
759
|
if (typeof globalThis === "undefined") {
|
|
760
760
|
return;
|
|
761
761
|
}
|
|
@@ -2430,37 +2430,38 @@ Check that all your Remotion packages are on the same version. If your dependenc
|
|
|
2430
2430
|
validateContent(artifact.content);
|
|
2431
2431
|
}, RenderAssetManager, RenderAssetManagerProvider = ({ children, collectAssets }) => {
|
|
2432
2432
|
const [renderAssets, setRenderAssets] = useState8([]);
|
|
2433
|
+
const renderAssetsRef = useRef5([]);
|
|
2433
2434
|
const registerRenderAsset = useCallback6((renderAsset) => {
|
|
2434
2435
|
validateRenderAsset(renderAsset);
|
|
2435
|
-
|
|
2436
|
-
|
|
2437
|
-
});
|
|
2436
|
+
renderAssetsRef.current = [...renderAssetsRef.current, renderAsset];
|
|
2437
|
+
setRenderAssets(renderAssetsRef.current);
|
|
2438
2438
|
}, []);
|
|
2439
2439
|
if (collectAssets) {
|
|
2440
2440
|
useImperativeHandle5(collectAssets, () => {
|
|
2441
2441
|
return {
|
|
2442
2442
|
collectAssets: () => {
|
|
2443
|
-
|
|
2444
|
-
|
|
2445
|
-
|
|
2446
|
-
return
|
|
2443
|
+
const assets = renderAssetsRef.current;
|
|
2444
|
+
renderAssetsRef.current = [];
|
|
2445
|
+
setRenderAssets([]);
|
|
2446
|
+
return assets;
|
|
2447
2447
|
}
|
|
2448
2448
|
};
|
|
2449
|
-
}, [
|
|
2449
|
+
}, []);
|
|
2450
2450
|
}
|
|
2451
2451
|
const unregisterRenderAsset = useCallback6((id) => {
|
|
2452
|
-
|
|
2453
|
-
|
|
2454
|
-
});
|
|
2452
|
+
renderAssetsRef.current = renderAssetsRef.current.filter((a) => a.id !== id);
|
|
2453
|
+
setRenderAssets(renderAssetsRef.current);
|
|
2455
2454
|
}, []);
|
|
2456
2455
|
useLayoutEffect3(() => {
|
|
2457
2456
|
if (typeof window !== "undefined") {
|
|
2458
2457
|
window.remotion_collectAssets = () => {
|
|
2458
|
+
const assets = renderAssetsRef.current;
|
|
2459
|
+
renderAssetsRef.current = [];
|
|
2459
2460
|
setRenderAssets([]);
|
|
2460
|
-
return
|
|
2461
|
+
return assets;
|
|
2461
2462
|
};
|
|
2462
2463
|
}
|
|
2463
|
-
}, [
|
|
2464
|
+
}, []);
|
|
2464
2465
|
const contextValue = useMemo11(() => {
|
|
2465
2466
|
return {
|
|
2466
2467
|
registerRenderAsset,
|
|
@@ -3061,7 +3062,7 @@ Check that all your Remotion packages are on the same version. If your dependenc
|
|
|
3061
3062
|
}
|
|
3062
3063
|
return true;
|
|
3063
3064
|
}, SharedAudioContext, SharedAudioContextProvider = ({ children, numberOfAudioTags, audioLatencyHint }) => {
|
|
3064
|
-
const audios =
|
|
3065
|
+
const audios = useRef6([]);
|
|
3065
3066
|
const [initialNumberOfAudioTags] = useState11(numberOfAudioTags);
|
|
3066
3067
|
if (numberOfAudioTags !== initialNumberOfAudioTags) {
|
|
3067
3068
|
throw new Error("The number of shared audio tags has changed dynamically. Once you have set this property, you cannot change it afterwards.");
|
|
@@ -3081,7 +3082,7 @@ Check that all your Remotion packages are on the same version. If your dependenc
|
|
|
3081
3082
|
};
|
|
3082
3083
|
});
|
|
3083
3084
|
}, [audioContext, numberOfAudioTags]);
|
|
3084
|
-
const takenAudios =
|
|
3085
|
+
const takenAudios = useRef6(new Array(numberOfAudioTags).fill(false));
|
|
3085
3086
|
const rerenderAudios = useCallback7(() => {
|
|
3086
3087
|
refs.forEach(({ ref, id }) => {
|
|
3087
3088
|
const data = audios.current?.find((a) => a.id === id);
|
|
@@ -3337,9 +3338,9 @@ Check that all your Remotion packages are on the same version. If your dependenc
|
|
|
3337
3338
|
duration: initialDuration,
|
|
3338
3339
|
fps
|
|
3339
3340
|
}) => {
|
|
3340
|
-
const actualFromRef =
|
|
3341
|
-
const actualDuration =
|
|
3342
|
-
const actualSrc =
|
|
3341
|
+
const actualFromRef = useRef7(initialActualFrom);
|
|
3342
|
+
const actualDuration = useRef7(initialDuration);
|
|
3343
|
+
const actualSrc = useRef7(initialActualSrc);
|
|
3343
3344
|
if (!isSubsetOfDuration({
|
|
3344
3345
|
prevStartFrom: actualFromRef.current,
|
|
3345
3346
|
newStartFrom: initialActualFrom,
|
|
@@ -3373,8 +3374,8 @@ Check that all your Remotion packages are on the same version. If your dependenc
|
|
|
3373
3374
|
source,
|
|
3374
3375
|
shouldUseWebAudioApi
|
|
3375
3376
|
}) => {
|
|
3376
|
-
const audioStuffRef =
|
|
3377
|
-
const currentVolumeRef =
|
|
3377
|
+
const audioStuffRef = useRef8(null);
|
|
3378
|
+
const currentVolumeRef = useRef8(volume);
|
|
3378
3379
|
currentVolumeRef.current = volume;
|
|
3379
3380
|
const sharedAudioContext = useContext17(SharedAudioContext);
|
|
3380
3381
|
if (!sharedAudioContext) {
|
|
@@ -3623,7 +3624,7 @@ Check that all your Remotion packages are on the same version. If your dependenc
|
|
|
3623
3624
|
const [blocks, setBlocks] = useState13([]);
|
|
3624
3625
|
const [onBufferingCallbacks, setOnBufferingCallbacks] = useState13([]);
|
|
3625
3626
|
const [onResumeCallbacks, setOnResumeCallbacks] = useState13([]);
|
|
3626
|
-
const buffering =
|
|
3627
|
+
const buffering = useRef9(false);
|
|
3627
3628
|
const addBlock = useCallback8((block) => {
|
|
3628
3629
|
setBlocks((b) => [...b, block]);
|
|
3629
3630
|
return {
|
|
@@ -3734,7 +3735,7 @@ Check that all your Remotion packages are on the same version. If your dependenc
|
|
|
3734
3735
|
logLevel,
|
|
3735
3736
|
mountTime
|
|
3736
3737
|
}) => {
|
|
3737
|
-
const bufferingRef =
|
|
3738
|
+
const bufferingRef = useRef10(false);
|
|
3738
3739
|
const { delayPlayback } = useBufferState();
|
|
3739
3740
|
const bufferUntilFirstFrame = useCallback9((requestedTime) => {
|
|
3740
3741
|
if (mediaType !== "video") {
|
|
@@ -3984,7 +3985,7 @@ Check that all your Remotion packages are on the same version. If your dependenc
|
|
|
3984
3985
|
lastSeek,
|
|
3985
3986
|
onVariableFpsVideoDetected
|
|
3986
3987
|
}) => {
|
|
3987
|
-
const currentTime =
|
|
3988
|
+
const currentTime = useRef11(null);
|
|
3988
3989
|
useEffect9(() => {
|
|
3989
3990
|
const { current } = mediaRef;
|
|
3990
3991
|
if (current) {
|
|
@@ -4108,14 +4109,14 @@ Check that all your Remotion packages are on the same version. If your dependenc
|
|
|
4108
4109
|
const buffering = useContext22(BufferingContextReact);
|
|
4109
4110
|
const { fps } = useVideoConfig();
|
|
4110
4111
|
const mediaStartsAt = useMediaStartsAt();
|
|
4111
|
-
const lastSeekDueToShift =
|
|
4112
|
-
const lastSeek =
|
|
4112
|
+
const lastSeekDueToShift = useRef12(null);
|
|
4113
|
+
const lastSeek = useRef12(null);
|
|
4113
4114
|
const logLevel = useLogLevel();
|
|
4114
4115
|
const mountTime = useMountTime();
|
|
4115
4116
|
if (!buffering) {
|
|
4116
4117
|
throw new Error("useMediaPlayback must be used inside a <BufferingContext>");
|
|
4117
4118
|
}
|
|
4118
|
-
const isVariableFpsVideoMap =
|
|
4119
|
+
const isVariableFpsVideoMap = useRef12({});
|
|
4119
4120
|
const onVariableFpsVideoDetected = useCallback10(() => {
|
|
4120
4121
|
if (!src) {
|
|
4121
4122
|
return;
|
|
@@ -4531,7 +4532,7 @@ Check that all your Remotion packages are on the same version. If your dependenc
|
|
|
4531
4532
|
useImperativeHandle6(ref, () => {
|
|
4532
4533
|
return audioRef.current;
|
|
4533
4534
|
}, [audioRef]);
|
|
4534
|
-
const currentOnDurationCallback =
|
|
4535
|
+
const currentOnDurationCallback = useRef13(onDuration);
|
|
4535
4536
|
currentOnDurationCallback.current = onDuration;
|
|
4536
4537
|
useEffect12(() => {
|
|
4537
4538
|
const { current } = audioRef;
|
|
@@ -4560,7 +4561,7 @@ Check that all your Remotion packages are on the same version. If your dependenc
|
|
|
4560
4561
|
...propsToPass
|
|
4561
4562
|
});
|
|
4562
4563
|
}, AudioForPreview, AudioForRenderingRefForwardingFunction = (props, ref) => {
|
|
4563
|
-
const audioRef =
|
|
4564
|
+
const audioRef = useRef14(null);
|
|
4564
4565
|
const {
|
|
4565
4566
|
volume: volumeProp,
|
|
4566
4567
|
playbackRate,
|
|
@@ -5067,8 +5068,8 @@ Check that all your Remotion packages are on the same version. If your dependenc
|
|
|
5067
5068
|
crossOrigin,
|
|
5068
5069
|
...props2
|
|
5069
5070
|
}, ref) => {
|
|
5070
|
-
const imageRef =
|
|
5071
|
-
const errors =
|
|
5071
|
+
const imageRef = useRef15(null);
|
|
5072
|
+
const errors = useRef15({});
|
|
5072
5073
|
const { delayPlayback } = useBufferState();
|
|
5073
5074
|
const sequenceContext = useContext30(SequenceContext);
|
|
5074
5075
|
if (!src) {
|
|
@@ -5207,7 +5208,7 @@ Check that all your Remotion packages are on the same version. If your dependenc
|
|
|
5207
5208
|
const [folders, setFolders] = useState17([]);
|
|
5208
5209
|
const [canvasContent, setCanvasContent] = useState17(initialCanvasContent);
|
|
5209
5210
|
const [compositions, setCompositions] = useState17(initialCompositions);
|
|
5210
|
-
const currentcompositionsRef =
|
|
5211
|
+
const currentcompositionsRef = useRef16(compositions);
|
|
5211
5212
|
const updateCompositions = useCallback14((updateComps) => {
|
|
5212
5213
|
setCompositions((comps) => {
|
|
5213
5214
|
const updated = updateComps(comps);
|
|
@@ -5726,7 +5727,7 @@ Check that all your Remotion packages are on the same version. If your dependenc
|
|
|
5726
5727
|
if (!context) {
|
|
5727
5728
|
throw new Error("SharedAudioContext not found");
|
|
5728
5729
|
}
|
|
5729
|
-
const videoRef =
|
|
5730
|
+
const videoRef = useRef17(null);
|
|
5730
5731
|
const sharedSource = useMemo29(() => {
|
|
5731
5732
|
if (!context.audioContext) {
|
|
5732
5733
|
return null;
|
|
@@ -5874,7 +5875,7 @@ Check that all your Remotion packages are on the same version. If your dependenc
|
|
|
5874
5875
|
current.removeEventListener("error", errorHandler);
|
|
5875
5876
|
};
|
|
5876
5877
|
}, [onError, src]);
|
|
5877
|
-
const currentOnDurationCallback =
|
|
5878
|
+
const currentOnDurationCallback = useRef17(onDuration);
|
|
5878
5879
|
currentOnDurationCallback.current = onDuration;
|
|
5879
5880
|
useEmitVideoFrame({ ref: videoRef, onVideoFrame });
|
|
5880
5881
|
useEffect19(() => {
|
|
@@ -6450,7 +6451,7 @@ Check that all your Remotion packages are on the same version. If your dependenc
|
|
|
6450
6451
|
const frame = useCurrentFrame();
|
|
6451
6452
|
const volumePropsFrame = useFrameForVolumeProp(loopVolumeCurveBehavior ?? "repeat");
|
|
6452
6453
|
const videoConfig = useUnsafeVideoConfig();
|
|
6453
|
-
const videoRef =
|
|
6454
|
+
const videoRef = useRef18(null);
|
|
6454
6455
|
const sequenceContext = useContext34(SequenceContext);
|
|
6455
6456
|
const mediaStartsAt = useMediaStartsAt();
|
|
6456
6457
|
const environment = useRemotionEnvironment();
|
|
@@ -12724,7 +12725,7 @@ var extrudeAndTransformElement = (options) => {
|
|
|
12724
12725
|
init_esm();
|
|
12725
12726
|
import { jsx as jsx37, Fragment } from "react/jsx-runtime";
|
|
12726
12727
|
import { jsx as jsx210, jsxs as jsxs3 } from "react/jsx-runtime";
|
|
12727
|
-
import { useEffect as useEffect22, useMemo as useMemo210, useRef as
|
|
12728
|
+
import { useEffect as useEffect22, useMemo as useMemo210, useRef as useRef19 } from "react";
|
|
12728
12729
|
import { jsx as jsx38 } from "react/jsx-runtime";
|
|
12729
12730
|
import { jsx as jsx43, jsxs as jsxs23 } from "react/jsx-runtime";
|
|
12730
12731
|
import React42 from "react";
|
|
@@ -13079,7 +13080,7 @@ var Spinner = ({ size, duration }) => {
|
|
|
13079
13080
|
height: size
|
|
13080
13081
|
};
|
|
13081
13082
|
}, [size]);
|
|
13082
|
-
const pathsRef =
|
|
13083
|
+
const pathsRef = useRef19([]);
|
|
13083
13084
|
useEffect22(() => {
|
|
13084
13085
|
const animate = () => {
|
|
13085
13086
|
const now = performance.now();
|