remotion 4.0.76 → 4.0.77
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/cjs/prefetch.js +1 -0
- package/dist/cjs/resolve-video-config.js +14 -17
- package/dist/cjs/version.d.ts +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/esm/index.mjs +16 -18
- package/dist/esm/version.mjs +1 -1
- package/package.json +1 -1
package/dist/cjs/prefetch.js
CHANGED
|
@@ -65,6 +65,7 @@ const prefetch = (src, options) => {
|
|
|
65
65
|
}
|
|
66
66
|
if (!buf.type.startsWith('video/') &&
|
|
67
67
|
!buf.type.startsWith('audio/') &&
|
|
68
|
+
!buf.type.startsWith('image/') &&
|
|
68
69
|
!(options === null || options === void 0 ? void 0 : options.contentType)) {
|
|
69
70
|
// eslint-disable-next-line no-console
|
|
70
71
|
console.warn(`Called prefetch() on ${src} which returned a "Content-Type" of ${buf.type}. Prefetched content should have a proper content type (video/... or audio/...) or a contentType passed the options of prefetch(). Otherwise, prefetching will not work properly in all browsers.`);
|
|
@@ -25,22 +25,19 @@ const validateCalculated = ({ composition, calculated, }) => {
|
|
|
25
25
|
return { width, height, fps, durationInFrames, defaultCodec };
|
|
26
26
|
};
|
|
27
27
|
const resolveVideoConfig = ({ composition, editorProps: editorPropsOrUndefined, signal, inputProps, }) => {
|
|
28
|
-
var _a, _b, _c, _d, _e, _f
|
|
28
|
+
var _a, _b, _c, _d, _e, _f;
|
|
29
|
+
const originalProps = {
|
|
30
|
+
...((_a = composition.defaultProps) !== null && _a !== void 0 ? _a : {}),
|
|
31
|
+
...(editorPropsOrUndefined !== null && editorPropsOrUndefined !== void 0 ? editorPropsOrUndefined : {}),
|
|
32
|
+
...(inputProps !== null && inputProps !== void 0 ? inputProps : {}),
|
|
33
|
+
};
|
|
29
34
|
const calculatedProm = composition.calculateMetadata
|
|
30
35
|
? composition.calculateMetadata({
|
|
31
|
-
defaultProps: (
|
|
32
|
-
props:
|
|
33
|
-
...((_b = composition.defaultProps) !== null && _b !== void 0 ? _b : {}),
|
|
34
|
-
...(editorPropsOrUndefined !== null && editorPropsOrUndefined !== void 0 ? editorPropsOrUndefined : {}),
|
|
35
|
-
...inputProps,
|
|
36
|
-
},
|
|
36
|
+
defaultProps: (_b = composition.defaultProps) !== null && _b !== void 0 ? _b : {},
|
|
37
|
+
props: originalProps,
|
|
37
38
|
abortSignal: signal,
|
|
38
39
|
})
|
|
39
40
|
: null;
|
|
40
|
-
const fallbackProps = {
|
|
41
|
-
...((_c = composition.defaultProps) !== null && _c !== void 0 ? _c : {}),
|
|
42
|
-
...(inputProps !== null && inputProps !== void 0 ? inputProps : {}),
|
|
43
|
-
};
|
|
44
41
|
if (calculatedProm !== null &&
|
|
45
42
|
typeof calculatedProm === 'object' &&
|
|
46
43
|
'then' in calculatedProm) {
|
|
@@ -57,7 +54,7 @@ const resolveVideoConfig = ({ composition, editorProps: editorPropsOrUndefined,
|
|
|
57
54
|
durationInFrames,
|
|
58
55
|
id: composition.id,
|
|
59
56
|
defaultProps: (_a = composition.defaultProps) !== null && _a !== void 0 ? _a : {},
|
|
60
|
-
props: (_b = c.props) !== null && _b !== void 0 ? _b :
|
|
57
|
+
props: (_b = c.props) !== null && _b !== void 0 ? _b : originalProps,
|
|
61
58
|
defaultCodec: defaultCodec !== null && defaultCodec !== void 0 ? defaultCodec : null,
|
|
62
59
|
};
|
|
63
60
|
});
|
|
@@ -70,17 +67,17 @@ const resolveVideoConfig = ({ composition, editorProps: editorPropsOrUndefined,
|
|
|
70
67
|
return {
|
|
71
68
|
...data,
|
|
72
69
|
id: composition.id,
|
|
73
|
-
defaultProps: (
|
|
74
|
-
props:
|
|
70
|
+
defaultProps: (_c = composition.defaultProps) !== null && _c !== void 0 ? _c : {},
|
|
71
|
+
props: originalProps,
|
|
75
72
|
defaultCodec: null,
|
|
76
73
|
};
|
|
77
74
|
}
|
|
78
75
|
return {
|
|
79
76
|
...data,
|
|
80
77
|
id: composition.id,
|
|
81
|
-
defaultProps: (
|
|
82
|
-
props: (
|
|
83
|
-
defaultCodec: (
|
|
78
|
+
defaultProps: (_d = composition.defaultProps) !== null && _d !== void 0 ? _d : {},
|
|
79
|
+
props: (_e = calculatedProm.props) !== null && _e !== void 0 ? _e : originalProps,
|
|
80
|
+
defaultCodec: (_f = calculatedProm.defaultCodec) !== null && _f !== void 0 ? _f : null,
|
|
84
81
|
};
|
|
85
82
|
};
|
|
86
83
|
exports.resolveVideoConfig = resolveVideoConfig;
|
package/dist/cjs/version.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const VERSION = "4.0.
|
|
1
|
+
export declare const VERSION = "4.0.77";
|
package/dist/cjs/version.js
CHANGED
package/dist/esm/index.mjs
CHANGED
|
@@ -59,7 +59,7 @@ function truthy(value) {
|
|
|
59
59
|
}
|
|
60
60
|
|
|
61
61
|
// Automatically generated on publish
|
|
62
|
-
const VERSION = '4.0.
|
|
62
|
+
const VERSION = '4.0.77';
|
|
63
63
|
|
|
64
64
|
const checkMultipleRemotionVersions = () => {
|
|
65
65
|
if (typeof globalThis === 'undefined') {
|
|
@@ -593,22 +593,19 @@ const validateCalculated = ({ composition, calculated, }) => {
|
|
|
593
593
|
return { width, height, fps, durationInFrames, defaultCodec };
|
|
594
594
|
};
|
|
595
595
|
const resolveVideoConfig = ({ composition, editorProps: editorPropsOrUndefined, signal, inputProps, }) => {
|
|
596
|
-
var _a, _b, _c, _d, _e, _f
|
|
596
|
+
var _a, _b, _c, _d, _e, _f;
|
|
597
|
+
const originalProps = {
|
|
598
|
+
...((_a = composition.defaultProps) !== null && _a !== void 0 ? _a : {}),
|
|
599
|
+
...(editorPropsOrUndefined !== null && editorPropsOrUndefined !== void 0 ? editorPropsOrUndefined : {}),
|
|
600
|
+
...(inputProps !== null && inputProps !== void 0 ? inputProps : {}),
|
|
601
|
+
};
|
|
597
602
|
const calculatedProm = composition.calculateMetadata
|
|
598
603
|
? composition.calculateMetadata({
|
|
599
|
-
defaultProps: (
|
|
600
|
-
props:
|
|
601
|
-
...((_b = composition.defaultProps) !== null && _b !== void 0 ? _b : {}),
|
|
602
|
-
...(editorPropsOrUndefined !== null && editorPropsOrUndefined !== void 0 ? editorPropsOrUndefined : {}),
|
|
603
|
-
...inputProps,
|
|
604
|
-
},
|
|
604
|
+
defaultProps: (_b = composition.defaultProps) !== null && _b !== void 0 ? _b : {},
|
|
605
|
+
props: originalProps,
|
|
605
606
|
abortSignal: signal,
|
|
606
607
|
})
|
|
607
608
|
: null;
|
|
608
|
-
const fallbackProps = {
|
|
609
|
-
...((_c = composition.defaultProps) !== null && _c !== void 0 ? _c : {}),
|
|
610
|
-
...(inputProps !== null && inputProps !== void 0 ? inputProps : {}),
|
|
611
|
-
};
|
|
612
609
|
if (calculatedProm !== null &&
|
|
613
610
|
typeof calculatedProm === 'object' &&
|
|
614
611
|
'then' in calculatedProm) {
|
|
@@ -625,7 +622,7 @@ const resolveVideoConfig = ({ composition, editorProps: editorPropsOrUndefined,
|
|
|
625
622
|
durationInFrames,
|
|
626
623
|
id: composition.id,
|
|
627
624
|
defaultProps: (_a = composition.defaultProps) !== null && _a !== void 0 ? _a : {},
|
|
628
|
-
props: (_b = c.props) !== null && _b !== void 0 ? _b :
|
|
625
|
+
props: (_b = c.props) !== null && _b !== void 0 ? _b : originalProps,
|
|
629
626
|
defaultCodec: defaultCodec !== null && defaultCodec !== void 0 ? defaultCodec : null,
|
|
630
627
|
};
|
|
631
628
|
});
|
|
@@ -638,17 +635,17 @@ const resolveVideoConfig = ({ composition, editorProps: editorPropsOrUndefined,
|
|
|
638
635
|
return {
|
|
639
636
|
...data,
|
|
640
637
|
id: composition.id,
|
|
641
|
-
defaultProps: (
|
|
642
|
-
props:
|
|
638
|
+
defaultProps: (_c = composition.defaultProps) !== null && _c !== void 0 ? _c : {},
|
|
639
|
+
props: originalProps,
|
|
643
640
|
defaultCodec: null,
|
|
644
641
|
};
|
|
645
642
|
}
|
|
646
643
|
return {
|
|
647
644
|
...data,
|
|
648
645
|
id: composition.id,
|
|
649
|
-
defaultProps: (
|
|
650
|
-
props: (
|
|
651
|
-
defaultCodec: (
|
|
646
|
+
defaultProps: (_d = composition.defaultProps) !== null && _d !== void 0 ? _d : {},
|
|
647
|
+
props: (_e = calculatedProm.props) !== null && _e !== void 0 ? _e : originalProps,
|
|
648
|
+
defaultCodec: (_f = calculatedProm.defaultCodec) !== null && _f !== void 0 ? _f : null,
|
|
652
649
|
};
|
|
653
650
|
};
|
|
654
651
|
|
|
@@ -1269,6 +1266,7 @@ const prefetch = (src, options) => {
|
|
|
1269
1266
|
}
|
|
1270
1267
|
if (!buf.type.startsWith('video/') &&
|
|
1271
1268
|
!buf.type.startsWith('audio/') &&
|
|
1269
|
+
!buf.type.startsWith('image/') &&
|
|
1272
1270
|
!(options === null || options === void 0 ? void 0 : options.contentType)) {
|
|
1273
1271
|
// eslint-disable-next-line no-console
|
|
1274
1272
|
console.warn(`Called prefetch() on ${src} which returned a "Content-Type" of ${buf.type}. Prefetched content should have a proper content type (video/... or audio/...) or a contentType passed the options of prefetch(). Otherwise, prefetching will not work properly in all browsers.`);
|
package/dist/esm/version.mjs
CHANGED