@remotion/promo-pages 4.0.494 → 4.0.495
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 +494 -354
- package/dist/design.js +284 -220
- package/dist/experts.js +281 -217
- package/dist/homepage/Pricing.js +291 -227
- package/dist/prompts/PromptsGallery.js +284 -220
- package/dist/prompts/PromptsShow.js +308 -244
- package/dist/prompts/PromptsSubmit.js +284 -220
- package/dist/team.js +284 -220
- package/dist/template-modal-content.js +286 -222
- package/dist/templates.js +284 -220
- package/package.json +13 -13
package/dist/Homepage.js
CHANGED
|
@@ -911,7 +911,7 @@ var experts = [
|
|
|
911
911
|
}
|
|
912
912
|
];
|
|
913
913
|
// src/components/experts/ExpertsPage.tsx
|
|
914
|
-
import { useMemo as
|
|
914
|
+
import { useMemo as useMemo41 } from "react";
|
|
915
915
|
|
|
916
916
|
// ../core/dist/esm/index.mjs
|
|
917
917
|
import { createContext } from "react";
|
|
@@ -945,9 +945,9 @@ import React9 from "react";
|
|
|
945
945
|
import {
|
|
946
946
|
forwardRef as forwardRef3,
|
|
947
947
|
useCallback as useCallback6,
|
|
948
|
-
useContext as
|
|
948
|
+
useContext as useContext18,
|
|
949
949
|
useEffect as useEffect3,
|
|
950
|
-
useMemo as
|
|
950
|
+
useMemo as useMemo15,
|
|
951
951
|
useRef as useRef6,
|
|
952
952
|
useState as useState5
|
|
953
953
|
} from "react";
|
|
@@ -966,13 +966,14 @@ import { useContext as useContext11 } from "react";
|
|
|
966
966
|
import { useContext as useContext13 } from "react";
|
|
967
967
|
import { useContext as useContext12, useMemo as useMemo10 } from "react";
|
|
968
968
|
import { jsx as jsx9 } from "react/jsx-runtime";
|
|
969
|
-
import { createContext as createContext14 } from "react";
|
|
970
969
|
import React12, { useCallback as useCallback5, useMemo as useMemo12, useRef as useRef4, useState as useState3 } from "react";
|
|
971
970
|
import { jsx as jsx10 } from "react/jsx-runtime";
|
|
972
|
-
import React13, { createContext as
|
|
971
|
+
import React13, { createContext as createContext14 } from "react";
|
|
973
972
|
import { jsx as jsx11 } from "react/jsx-runtime";
|
|
974
|
-
import
|
|
975
|
-
import {
|
|
973
|
+
import { useContext as useContext15, useMemo as useMemo13 } from "react";
|
|
974
|
+
import { createContext as createContext15 } from "react";
|
|
975
|
+
import React14, { forwardRef as forwardRef2, useContext as useContext17, useMemo as useMemo14, useState as useState4 } from "react";
|
|
976
|
+
import { useContext as useContext16, useRef as useRef5 } from "react";
|
|
976
977
|
import { createContext as createContext16 } from "react";
|
|
977
978
|
import { jsx as jsx12 } from "react/jsx-runtime";
|
|
978
979
|
import {
|
|
@@ -983,70 +984,70 @@ import {
|
|
|
983
984
|
useRef as useRef9,
|
|
984
985
|
useState as useState6
|
|
985
986
|
} from "react";
|
|
986
|
-
import React16, { useCallback as useCallback7, useImperativeHandle, useMemo as
|
|
987
|
-
import { useEffect as useEffect4, useMemo as
|
|
987
|
+
import React16, { useCallback as useCallback7, useImperativeHandle, useMemo as useMemo17, useRef as useRef8 } from "react";
|
|
988
|
+
import { useEffect as useEffect4, useMemo as useMemo16, useRef as useRef7 } from "react";
|
|
988
989
|
import { jsx as jsx13 } from "react/jsx-runtime";
|
|
989
990
|
import { jsx as jsx14 } from "react/jsx-runtime";
|
|
990
|
-
import { useContext as
|
|
991
|
+
import { useContext as useContext19, useLayoutEffect as useLayoutEffect4, useState as useState8 } from "react";
|
|
991
992
|
import {
|
|
992
993
|
createContext as createContext17,
|
|
993
994
|
useCallback as useCallback8,
|
|
994
995
|
useImperativeHandle as useImperativeHandle3,
|
|
995
996
|
useLayoutEffect as useLayoutEffect3,
|
|
996
|
-
useMemo as
|
|
997
|
+
useMemo as useMemo18,
|
|
997
998
|
useRef as useRef10,
|
|
998
999
|
useState as useState7
|
|
999
1000
|
} from "react";
|
|
1000
1001
|
import { jsx as jsx15 } from "react/jsx-runtime";
|
|
1001
|
-
import { forwardRef as forwardRef7, useCallback as useCallback14, useContext as
|
|
1002
|
-
import React17, { createContext as createContext18, useMemo as
|
|
1002
|
+
import { forwardRef as forwardRef7, useCallback as useCallback14, useContext as useContext31 } from "react";
|
|
1003
|
+
import React17, { createContext as createContext18, useMemo as useMemo19 } from "react";
|
|
1003
1004
|
import { jsx as jsx16 } from "react/jsx-runtime";
|
|
1004
|
-
import { useContext as
|
|
1005
|
+
import { useContext as useContext20 } from "react";
|
|
1005
1006
|
import { createContext as createContext19, useEffect as useEffect6, useState as useState9 } from "react";
|
|
1006
1007
|
import { jsx as jsx17 } from "react/jsx-runtime";
|
|
1007
|
-
import { createContext as createContext20, useMemo as
|
|
1008
|
+
import { createContext as createContext20, useMemo as useMemo20, useReducer } from "react";
|
|
1008
1009
|
import { jsx as jsx18 } from "react/jsx-runtime";
|
|
1009
1010
|
import { useCallback as useCallback13 } from "react";
|
|
1010
1011
|
import React23, {
|
|
1011
1012
|
forwardRef as forwardRef5,
|
|
1012
|
-
useContext as
|
|
1013
|
+
useContext as useContext29,
|
|
1013
1014
|
useEffect as useEffect14,
|
|
1014
1015
|
useImperativeHandle as useImperativeHandle4,
|
|
1015
|
-
useMemo as
|
|
1016
|
+
useMemo as useMemo28,
|
|
1016
1017
|
useRef as useRef19,
|
|
1017
1018
|
useState as useState14
|
|
1018
1019
|
} from "react";
|
|
1019
|
-
import { useContext as
|
|
1020
|
+
import { useContext as useContext22, useLayoutEffect as useLayoutEffect5, useRef as useRef14 } from "react";
|
|
1020
1021
|
import React20, {
|
|
1021
1022
|
createContext as createContext21,
|
|
1022
1023
|
createRef as createRef2,
|
|
1023
1024
|
useCallback as useCallback9,
|
|
1024
|
-
useContext as
|
|
1025
|
+
useContext as useContext21,
|
|
1025
1026
|
useEffect as useEffect7,
|
|
1026
|
-
useMemo as
|
|
1027
|
+
useMemo as useMemo22,
|
|
1027
1028
|
useRef as useRef12,
|
|
1028
1029
|
useState as useState10
|
|
1029
1030
|
} from "react";
|
|
1030
|
-
import { useMemo as
|
|
1031
|
+
import { useMemo as useMemo21, useRef as useRef11 } from "react";
|
|
1031
1032
|
import { jsx as jsx19, jsxs as jsxs22 } from "react/jsx-runtime";
|
|
1032
1033
|
import { useRef as useRef13 } from "react";
|
|
1033
|
-
import { useContext as
|
|
1034
|
-
import { useContext as
|
|
1034
|
+
import { useContext as useContext24, useEffect as useEffect8, useMemo as useMemo23, useState as useState11 } from "react";
|
|
1035
|
+
import { useContext as useContext23 } from "react";
|
|
1035
1036
|
import {
|
|
1036
1037
|
useCallback as useCallback12,
|
|
1037
|
-
useContext as
|
|
1038
|
+
useContext as useContext27,
|
|
1038
1039
|
useEffect as useEffect12,
|
|
1039
1040
|
useLayoutEffect as useLayoutEffect7,
|
|
1040
1041
|
useRef as useRef18
|
|
1041
1042
|
} from "react";
|
|
1042
|
-
import { useCallback as useCallback11, useMemo as
|
|
1043
|
-
import { useContext as
|
|
1043
|
+
import { useCallback as useCallback11, useMemo as useMemo26, useRef as useRef16 } from "react";
|
|
1044
|
+
import { useContext as useContext26, useMemo as useMemo25 } from "react";
|
|
1044
1045
|
import React21, {
|
|
1045
1046
|
useCallback as useCallback10,
|
|
1046
|
-
useContext as
|
|
1047
|
+
useContext as useContext25,
|
|
1047
1048
|
useEffect as useEffect9,
|
|
1048
1049
|
useLayoutEffect as useLayoutEffect6,
|
|
1049
|
-
useMemo as
|
|
1050
|
+
useMemo as useMemo24,
|
|
1050
1051
|
useRef as useRef15,
|
|
1051
1052
|
useState as useState12
|
|
1052
1053
|
} from "react";
|
|
@@ -1055,15 +1056,15 @@ import React22 from "react";
|
|
|
1055
1056
|
import { useEffect as useEffect10, useState as useState13 } from "react";
|
|
1056
1057
|
import { useEffect as useEffect11, useRef as useRef17 } from "react";
|
|
1057
1058
|
import { useEffect as useEffect13 } from "react";
|
|
1058
|
-
import { createContext as createContext22, useContext as
|
|
1059
|
+
import { createContext as createContext22, useContext as useContext28, useMemo as useMemo27 } from "react";
|
|
1059
1060
|
import { jsx as jsx21 } from "react/jsx-runtime";
|
|
1060
1061
|
import {
|
|
1061
1062
|
forwardRef as forwardRef6,
|
|
1062
|
-
useContext as
|
|
1063
|
+
useContext as useContext30,
|
|
1063
1064
|
useEffect as useEffect15,
|
|
1064
1065
|
useImperativeHandle as useImperativeHandle5,
|
|
1065
1066
|
useLayoutEffect as useLayoutEffect8,
|
|
1066
|
-
useMemo as
|
|
1067
|
+
useMemo as useMemo29,
|
|
1067
1068
|
useRef as useRef20
|
|
1068
1069
|
} from "react";
|
|
1069
1070
|
import { jsx as jsx222 } from "react/jsx-runtime";
|
|
@@ -1073,7 +1074,7 @@ import {
|
|
|
1073
1074
|
useCallback as useCallback15,
|
|
1074
1075
|
useEffect as useEffect16,
|
|
1075
1076
|
useImperativeHandle as useImperativeHandle6,
|
|
1076
|
-
useMemo as
|
|
1077
|
+
useMemo as useMemo30,
|
|
1077
1078
|
useRef as useRef21,
|
|
1078
1079
|
useState as useState15
|
|
1079
1080
|
} from "react";
|
|
@@ -1082,19 +1083,19 @@ import {
|
|
|
1082
1083
|
createContext as createContext23,
|
|
1083
1084
|
forwardRef as forwardRef9,
|
|
1084
1085
|
useCallback as useCallback16,
|
|
1085
|
-
useContext as
|
|
1086
|
+
useContext as useContext32,
|
|
1086
1087
|
useLayoutEffect as useLayoutEffect9,
|
|
1087
|
-
useMemo as
|
|
1088
|
+
useMemo as useMemo31,
|
|
1088
1089
|
useRef as useRef22
|
|
1089
1090
|
} from "react";
|
|
1090
1091
|
import { jsx as jsx25 } from "react/jsx-runtime";
|
|
1091
1092
|
import {
|
|
1092
1093
|
forwardRef as forwardRef10,
|
|
1093
1094
|
useCallback as useCallback17,
|
|
1094
|
-
useContext as
|
|
1095
|
+
useContext as useContext33,
|
|
1095
1096
|
useImperativeHandle as useImperativeHandle7,
|
|
1096
1097
|
useLayoutEffect as useLayoutEffect10,
|
|
1097
|
-
useMemo as
|
|
1098
|
+
useMemo as useMemo32,
|
|
1098
1099
|
useRef as useRef23,
|
|
1099
1100
|
useState as useState16
|
|
1100
1101
|
} from "react";
|
|
@@ -1103,7 +1104,7 @@ import { forwardRef as forwardRef11, useCallback as useCallback18, useState as u
|
|
|
1103
1104
|
import { jsx as jsx27 } from "react/jsx-runtime";
|
|
1104
1105
|
import {
|
|
1105
1106
|
useCallback as useCallback19,
|
|
1106
|
-
useContext as
|
|
1107
|
+
useContext as useContext34,
|
|
1107
1108
|
useLayoutEffect as useLayoutEffect11,
|
|
1108
1109
|
useRef as useRef24,
|
|
1109
1110
|
useState as useState18
|
|
@@ -1116,59 +1117,59 @@ import React31 from "react";
|
|
|
1116
1117
|
import {
|
|
1117
1118
|
useCallback as useCallback21,
|
|
1118
1119
|
useImperativeHandle as useImperativeHandle8,
|
|
1119
|
-
useMemo as
|
|
1120
|
+
useMemo as useMemo33,
|
|
1120
1121
|
useRef as useRef26,
|
|
1121
1122
|
useState as useState19
|
|
1122
1123
|
} from "react";
|
|
1123
1124
|
import { jsx as jsx30 } from "react/jsx-runtime";
|
|
1124
1125
|
import React32 from "react";
|
|
1125
|
-
import { useMemo as
|
|
1126
|
-
import { createContext as createContext24, useContext as
|
|
1126
|
+
import { useMemo as useMemo35 } from "react";
|
|
1127
|
+
import { createContext as createContext24, useContext as useContext35, useMemo as useMemo34 } from "react";
|
|
1127
1128
|
import { jsx as jsx31 } from "react/jsx-runtime";
|
|
1128
1129
|
import { jsx as jsx32 } from "react/jsx-runtime";
|
|
1129
1130
|
import React34 from "react";
|
|
1130
1131
|
import React35, { createContext as createContext25 } from "react";
|
|
1131
|
-
import React36, { useContext as
|
|
1132
|
+
import React36, { useContext as useContext36 } from "react";
|
|
1132
1133
|
import { useCallback as useCallback24 } from "react";
|
|
1133
1134
|
import {
|
|
1134
1135
|
useCallback as useCallback22,
|
|
1135
|
-
useContext as
|
|
1136
|
+
useContext as useContext37,
|
|
1136
1137
|
useEffect as useEffect17,
|
|
1137
1138
|
useLayoutEffect as useLayoutEffect12,
|
|
1138
|
-
useMemo as
|
|
1139
|
+
useMemo as useMemo36,
|
|
1139
1140
|
useState as useState20
|
|
1140
1141
|
} from "react";
|
|
1141
1142
|
import { jsx as jsx33 } from "react/jsx-runtime";
|
|
1142
1143
|
import React38, {
|
|
1143
1144
|
forwardRef as forwardRef13,
|
|
1144
1145
|
useCallback as useCallback23,
|
|
1145
|
-
useContext as
|
|
1146
|
+
useContext as useContext38,
|
|
1146
1147
|
useEffect as useEffect19,
|
|
1147
1148
|
useImperativeHandle as useImperativeHandle9,
|
|
1148
|
-
useMemo as
|
|
1149
|
+
useMemo as useMemo37,
|
|
1149
1150
|
useRef as useRef27,
|
|
1150
1151
|
useState as useState21
|
|
1151
1152
|
} from "react";
|
|
1152
1153
|
import { useEffect as useEffect18 } from "react";
|
|
1153
1154
|
import { jsx as jsx34 } from "react/jsx-runtime";
|
|
1154
1155
|
import { jsx as jsx35 } from "react/jsx-runtime";
|
|
1155
|
-
import React40, { useMemo as
|
|
1156
|
+
import React40, { useMemo as useMemo38 } from "react";
|
|
1156
1157
|
import { jsx as jsx36 } from "react/jsx-runtime";
|
|
1157
1158
|
import React42, {
|
|
1158
1159
|
forwardRef as forwardRef14,
|
|
1159
|
-
useMemo as
|
|
1160
|
+
useMemo as useMemo39
|
|
1160
1161
|
} from "react";
|
|
1161
1162
|
import React41 from "react";
|
|
1162
1163
|
import { jsx as jsx37, jsxs as jsxs3, Fragment } from "react/jsx-runtime";
|
|
1163
1164
|
import React43 from "react";
|
|
1164
|
-
import { forwardRef as forwardRef16, useCallback as useCallback25, useContext as
|
|
1165
|
+
import { forwardRef as forwardRef16, useCallback as useCallback25, useContext as useContext40 } from "react";
|
|
1165
1166
|
import {
|
|
1166
1167
|
forwardRef as forwardRef15,
|
|
1167
|
-
useContext as
|
|
1168
|
+
useContext as useContext39,
|
|
1168
1169
|
useEffect as useEffect20,
|
|
1169
1170
|
useImperativeHandle as useImperativeHandle10,
|
|
1170
1171
|
useLayoutEffect as useLayoutEffect13,
|
|
1171
|
-
useMemo as
|
|
1172
|
+
useMemo as useMemo40,
|
|
1172
1173
|
useRef as useRef28
|
|
1173
1174
|
} from "react";
|
|
1174
1175
|
import { jsx as jsx38 } from "react/jsx-runtime";
|
|
@@ -2359,7 +2360,7 @@ var getSingleChildComponent = (children) => {
|
|
|
2359
2360
|
}
|
|
2360
2361
|
return child.type;
|
|
2361
2362
|
};
|
|
2362
|
-
var VERSION = "4.0.
|
|
2363
|
+
var VERSION = "4.0.495";
|
|
2363
2364
|
var checkMultipleRemotionVersions = () => {
|
|
2364
2365
|
if (typeof globalThis === "undefined") {
|
|
2365
2366
|
return;
|
|
@@ -2852,15 +2853,19 @@ var premountSchema = {
|
|
|
2852
2853
|
description: "Premount For",
|
|
2853
2854
|
min: 0,
|
|
2854
2855
|
step: 1,
|
|
2855
|
-
hiddenFromList: false
|
|
2856
|
+
hiddenFromList: false,
|
|
2857
|
+
keyframable: false
|
|
2856
2858
|
},
|
|
2857
2859
|
postmountFor: {
|
|
2858
2860
|
type: "number",
|
|
2859
2861
|
default: 0,
|
|
2860
2862
|
min: 0,
|
|
2861
2863
|
step: 1,
|
|
2862
|
-
hiddenFromList: true
|
|
2863
|
-
|
|
2864
|
+
hiddenFromList: true,
|
|
2865
|
+
keyframable: false
|
|
2866
|
+
}
|
|
2867
|
+
};
|
|
2868
|
+
var premountStyleSchema = {
|
|
2864
2869
|
styleWhilePremounted: {
|
|
2865
2870
|
type: "hidden"
|
|
2866
2871
|
},
|
|
@@ -2868,10 +2873,13 @@ var premountSchema = {
|
|
|
2868
2873
|
type: "hidden"
|
|
2869
2874
|
}
|
|
2870
2875
|
};
|
|
2871
|
-
var sequencePremountSchema =
|
|
2876
|
+
var sequencePremountSchema = {
|
|
2877
|
+
...premountSchema,
|
|
2878
|
+
...premountStyleSchema
|
|
2879
|
+
};
|
|
2872
2880
|
var sequenceStyleSchema = {
|
|
2873
2881
|
...transformSchema,
|
|
2874
|
-
...
|
|
2882
|
+
...sequencePremountSchema
|
|
2875
2883
|
};
|
|
2876
2884
|
var hiddenField = {
|
|
2877
2885
|
type: "boolean",
|
|
@@ -2956,9 +2964,6 @@ var sequenceSchemaDefaultLayoutNone = {
|
|
|
2956
2964
|
default: "none"
|
|
2957
2965
|
}
|
|
2958
2966
|
};
|
|
2959
|
-
var PremountContext = createContext14({
|
|
2960
|
-
premountFramesRemaining: 0
|
|
2961
|
-
});
|
|
2962
2967
|
var SequenceManager = React12.createContext({
|
|
2963
2968
|
registerSequence: () => {
|
|
2964
2969
|
throw new Error("SequenceManagerContext not initialized");
|
|
@@ -3138,7 +3143,7 @@ var SequenceManagerProvider = ({ children }) => {
|
|
|
3138
3143
|
})
|
|
3139
3144
|
});
|
|
3140
3145
|
};
|
|
3141
|
-
var IsInsideSeriesContext =
|
|
3146
|
+
var IsInsideSeriesContext = createContext14(false);
|
|
3142
3147
|
var IsInsideSeriesContainer = ({ children }) => {
|
|
3143
3148
|
return /* @__PURE__ */ jsx11(IsInsideSeriesContext.Provider, {
|
|
3144
3149
|
value: true,
|
|
@@ -3157,7 +3162,61 @@ var useRequireToBeInsideSeries = () => {
|
|
|
3157
3162
|
throw new Error("This component must be inside a <Series /> component.");
|
|
3158
3163
|
}
|
|
3159
3164
|
};
|
|
3165
|
+
var PremountContext = createContext15({
|
|
3166
|
+
premountFramesRemaining: 0
|
|
3167
|
+
});
|
|
3160
3168
|
var ENABLE_V5_BREAKING_CHANGES = false;
|
|
3169
|
+
var usePremounting = ({
|
|
3170
|
+
from,
|
|
3171
|
+
durationInFrames,
|
|
3172
|
+
premountFor,
|
|
3173
|
+
postmountFor,
|
|
3174
|
+
style,
|
|
3175
|
+
styleWhilePremounted,
|
|
3176
|
+
styleWhilePostmounted,
|
|
3177
|
+
hideWhilePremounted
|
|
3178
|
+
}) => {
|
|
3179
|
+
const parentPremountContext = useContext15(PremountContext);
|
|
3180
|
+
const frame = useCurrentFrame() - parentPremountContext.premountFramesRemaining;
|
|
3181
|
+
const environment = useRemotionEnvironment();
|
|
3182
|
+
const { fps } = useVideoConfig();
|
|
3183
|
+
const effectivePremountFor = ENABLE_V5_BREAKING_CHANGES ? premountFor ?? fps : premountFor ?? 0;
|
|
3184
|
+
const effectivePostmountFor = postmountFor ?? 0;
|
|
3185
|
+
const endThreshold = Math.ceil(from + durationInFrames - 1);
|
|
3186
|
+
const premountingActive = !environment.isRendering && frame < from && frame >= from - effectivePremountFor;
|
|
3187
|
+
const postmountingActive = !environment.isRendering && frame > endThreshold && frame <= endThreshold + effectivePostmountFor;
|
|
3188
|
+
const isPremountingOrPostmounting = premountingActive || postmountingActive;
|
|
3189
|
+
const freezeFrame = premountingActive ? from : postmountingActive ? from + durationInFrames - 1 : 0;
|
|
3190
|
+
const premountingStyle = useMemo13(() => {
|
|
3191
|
+
if (!isPremountingOrPostmounting) {
|
|
3192
|
+
return style;
|
|
3193
|
+
}
|
|
3194
|
+
return {
|
|
3195
|
+
...style,
|
|
3196
|
+
...hideWhilePremounted === "opacity" ? { opacity: 0 } : { display: "none" },
|
|
3197
|
+
pointerEvents: "none",
|
|
3198
|
+
...premountingActive ? styleWhilePremounted : {},
|
|
3199
|
+
...postmountingActive ? styleWhilePostmounted : {}
|
|
3200
|
+
};
|
|
3201
|
+
}, [
|
|
3202
|
+
isPremountingOrPostmounting,
|
|
3203
|
+
hideWhilePremounted,
|
|
3204
|
+
postmountingActive,
|
|
3205
|
+
premountingActive,
|
|
3206
|
+
style,
|
|
3207
|
+
styleWhilePostmounted,
|
|
3208
|
+
styleWhilePremounted
|
|
3209
|
+
]);
|
|
3210
|
+
return {
|
|
3211
|
+
effectivePremountFor,
|
|
3212
|
+
effectivePostmountFor,
|
|
3213
|
+
premountingActive,
|
|
3214
|
+
postmountingActive,
|
|
3215
|
+
isPremountingOrPostmounting,
|
|
3216
|
+
freezeFrame,
|
|
3217
|
+
premountingStyle
|
|
3218
|
+
};
|
|
3219
|
+
};
|
|
3161
3220
|
var deleteNestedKey = (obj, keysToRemove) => {
|
|
3162
3221
|
for (const key of keysToRemove) {
|
|
3163
3222
|
const parts = key.split(".");
|
|
@@ -4981,10 +5040,10 @@ var useMemoizedEffects = ({
|
|
|
4981
5040
|
overrideId
|
|
4982
5041
|
}) => {
|
|
4983
5042
|
const previousRef = useRef5(null);
|
|
4984
|
-
const { propStatuses } =
|
|
4985
|
-
const { getEffectDragOverrides } =
|
|
5043
|
+
const { propStatuses } = useContext16(VisualModePropStatusesContext);
|
|
5044
|
+
const { getEffectDragOverrides } = useContext16(VisualModeDragOverridesContext);
|
|
4986
5045
|
const frame = useCurrentFrame();
|
|
4987
|
-
const { overrideIdToNodePathMappings } =
|
|
5046
|
+
const { overrideIdToNodePathMappings } = useContext16(OverrideIdsToNodePathsGettersContext);
|
|
4988
5047
|
const previous = previousRef.current;
|
|
4989
5048
|
const nodePath = overrideId ? overrideIdToNodePathMappings[overrideId] ?? null : null;
|
|
4990
5049
|
const resolved = effects.map((descriptor, index) => {
|
|
@@ -5328,9 +5387,9 @@ var withInteractivitySchema = ({
|
|
|
5328
5387
|
ref
|
|
5329
5388
|
});
|
|
5330
5389
|
}
|
|
5331
|
-
const { propStatuses } =
|
|
5332
|
-
const { getDragOverrides } =
|
|
5333
|
-
const nodePathMapping =
|
|
5390
|
+
const { propStatuses } = useContext17(VisualModePropStatusesContext);
|
|
5391
|
+
const { getDragOverrides } = useContext17(VisualModeDragOverridesContext);
|
|
5392
|
+
const nodePathMapping = useContext17(OverrideIdsToNodePathsGettersContext);
|
|
5334
5393
|
const frame = useCurrentFrame();
|
|
5335
5394
|
if (props.controls) {
|
|
5336
5395
|
return React14.createElement(Component, {
|
|
@@ -5357,8 +5416,8 @@ var withInteractivitySchema = ({
|
|
|
5357
5416
|
key,
|
|
5358
5417
|
props
|
|
5359
5418
|
}));
|
|
5360
|
-
const currentRuntimeValueDotNotation =
|
|
5361
|
-
const controls =
|
|
5419
|
+
const currentRuntimeValueDotNotation = useMemo14(() => readValuesFromProps(props, flatKeys, flatSchema), runtimeValues);
|
|
5420
|
+
const controls = useMemo14(() => {
|
|
5362
5421
|
return {
|
|
5363
5422
|
schema: schemaWithSequenceName,
|
|
5364
5423
|
currentRuntimeValueDotNotation,
|
|
@@ -5368,7 +5427,7 @@ var withInteractivitySchema = ({
|
|
|
5368
5427
|
componentName
|
|
5369
5428
|
};
|
|
5370
5429
|
}, [currentRuntimeValueDotNotation, overrideId]);
|
|
5371
|
-
const { merged: valuesDotNotation, propsToDelete } =
|
|
5430
|
+
const { merged: valuesDotNotation, propsToDelete } = useMemo14(() => {
|
|
5372
5431
|
return computeEffectiveSchemaValuesDotNotation({
|
|
5373
5432
|
schema: schemaWithSequenceName,
|
|
5374
5433
|
currentValue: currentRuntimeValueDotNotation,
|
|
@@ -5426,7 +5485,7 @@ var RegularSequenceRefForwardingFunction = ({
|
|
|
5426
5485
|
}, ref) => {
|
|
5427
5486
|
const { layout = "absolute-fill" } = other;
|
|
5428
5487
|
const [id] = useState5(() => String(Math.random()));
|
|
5429
|
-
const parentSequence =
|
|
5488
|
+
const parentSequence = useContext18(SequenceContext);
|
|
5430
5489
|
const { rootId } = useTimelineContext();
|
|
5431
5490
|
const cumulatedFrom = parentSequence ? parentSequence.cumulatedFrom + parentSequence.relativeFrom : 0;
|
|
5432
5491
|
const nonce = useNonce();
|
|
@@ -5477,13 +5536,13 @@ var RegularSequenceRefForwardingFunction = ({
|
|
|
5477
5536
|
const absoluteFrom = (parentSequence?.absoluteFrom ?? 0) + effectiveRelativeFrom;
|
|
5478
5537
|
const parentSequenceDuration = parentSequence ? Math.min(parentSequence.durationInFrames - effectiveRelativeFrom, durationInFrames) : durationInFrames;
|
|
5479
5538
|
const actualDurationInFrames = Math.max(0, Math.min(videoConfig.durationInFrames - from, parentSequenceDuration));
|
|
5480
|
-
const { registerSequence, unregisterSequence } =
|
|
5539
|
+
const { registerSequence, unregisterSequence } = useContext18(SequenceManager);
|
|
5481
5540
|
const wrapperRefForOutline = useRef6(null);
|
|
5482
5541
|
const refForOutline = other.layout === "none" ? passedRefForOutline ?? null : passedRefForOutline ?? wrapperRefForOutline;
|
|
5483
|
-
const premounting =
|
|
5542
|
+
const premounting = useMemo15(() => {
|
|
5484
5543
|
return parentSequence?.premounting || Boolean(other._remotionInternalIsPremounting);
|
|
5485
5544
|
}, [other._remotionInternalIsPremounting, parentSequence?.premounting]);
|
|
5486
|
-
const postmounting =
|
|
5545
|
+
const postmounting = useMemo15(() => {
|
|
5487
5546
|
return parentSequence?.postmounting || Boolean(other._remotionInternalIsPostmounting);
|
|
5488
5547
|
}, [other._remotionInternalIsPostmounting, parentSequence?.postmounting]);
|
|
5489
5548
|
const currentSequenceStart = cumulatedFrom + effectiveRelativeFrom;
|
|
@@ -5491,7 +5550,7 @@ var RegularSequenceRefForwardingFunction = ({
|
|
|
5491
5550
|
const parentFirstFrame = parentSequence ? parentSequenceStart - parentSequence.cumulatedNegativeFrom : 0;
|
|
5492
5551
|
const firstFrame = Math.max(0, parentFirstFrame, currentSequenceStart);
|
|
5493
5552
|
const cumulatedNegativeFrom = currentSequenceStart - firstFrame;
|
|
5494
|
-
const contextValue =
|
|
5553
|
+
const contextValue = useMemo15(() => {
|
|
5495
5554
|
return {
|
|
5496
5555
|
absoluteFrom,
|
|
5497
5556
|
cumulatedFrom,
|
|
@@ -5522,12 +5581,12 @@ var RegularSequenceRefForwardingFunction = ({
|
|
|
5522
5581
|
postmountDisplay,
|
|
5523
5582
|
cumulatedNegativeFrom
|
|
5524
5583
|
]);
|
|
5525
|
-
const timelineClipName =
|
|
5584
|
+
const timelineClipName = useMemo15(() => {
|
|
5526
5585
|
return name ?? "";
|
|
5527
5586
|
}, [name]);
|
|
5528
5587
|
const resolvedDocumentationLink = documentationLink ?? "https://www.remotion.dev/docs/sequence";
|
|
5529
5588
|
const env = useRemotionEnvironment();
|
|
5530
|
-
const isInsideSeries =
|
|
5589
|
+
const isInsideSeries = useContext18(IsInsideSeriesContext);
|
|
5531
5590
|
const inheritedStack = other?.stack ?? null;
|
|
5532
5591
|
const stackRef = useRef6(null);
|
|
5533
5592
|
stackRef.current = stack ?? inheritedStack;
|
|
@@ -5675,7 +5734,7 @@ var RegularSequenceRefForwardingFunction = ({
|
|
|
5675
5734
|
ref.current = node;
|
|
5676
5735
|
}
|
|
5677
5736
|
}, [ref]);
|
|
5678
|
-
const defaultStyle =
|
|
5737
|
+
const defaultStyle = useMemo15(() => {
|
|
5679
5738
|
return {
|
|
5680
5739
|
flexDirection: undefined,
|
|
5681
5740
|
...width ? { width } : {},
|
|
@@ -5701,8 +5760,6 @@ var RegularSequenceRefForwardingFunction = ({
|
|
|
5701
5760
|
};
|
|
5702
5761
|
var RegularSequence = forwardRef3(RegularSequenceRefForwardingFunction);
|
|
5703
5762
|
var PremountedPostmountedSequenceRefForwardingFunction = (props, ref) => {
|
|
5704
|
-
const parentPremountContext = useContext17(PremountContext);
|
|
5705
|
-
const frame = useCurrentFrame() - parentPremountContext.premountFramesRemaining;
|
|
5706
5763
|
if (props.layout === "none") {
|
|
5707
5764
|
throw new Error('`<Sequence>` with `premountFor` and `postmountFor` props does not support layout="none"');
|
|
5708
5765
|
}
|
|
@@ -5716,34 +5773,30 @@ var PremountedPostmountedSequenceRefForwardingFunction = (props, ref) => {
|
|
|
5716
5773
|
styleWhilePostmounted,
|
|
5717
5774
|
...otherProps
|
|
5718
5775
|
} = props;
|
|
5719
|
-
const
|
|
5720
|
-
|
|
5721
|
-
|
|
5722
|
-
const freezeFrame = premountingActive ? from : postmountingActive ? from + durationInFrames - 1 : 0;
|
|
5723
|
-
const isFreezingActive = premountingActive || postmountingActive;
|
|
5724
|
-
const style = useMemo14(() => {
|
|
5725
|
-
return {
|
|
5726
|
-
...passedStyle,
|
|
5727
|
-
opacity: premountingActive || postmountingActive ? 0 : passedStyle?.opacity,
|
|
5728
|
-
pointerEvents: premountingActive || postmountingActive ? "none" : passedStyle?.pointerEvents ?? undefined,
|
|
5729
|
-
...premountingActive ? styleWhilePremounted : {},
|
|
5730
|
-
...postmountingActive ? styleWhilePostmounted : {}
|
|
5731
|
-
};
|
|
5732
|
-
}, [
|
|
5733
|
-
passedStyle,
|
|
5734
|
-
premountingActive,
|
|
5776
|
+
const {
|
|
5777
|
+
freezeFrame,
|
|
5778
|
+
isPremountingOrPostmounting,
|
|
5735
5779
|
postmountingActive,
|
|
5736
|
-
|
|
5737
|
-
|
|
5738
|
-
|
|
5780
|
+
premountingActive,
|
|
5781
|
+
premountingStyle
|
|
5782
|
+
} = usePremounting({
|
|
5783
|
+
from,
|
|
5784
|
+
durationInFrames,
|
|
5785
|
+
premountFor,
|
|
5786
|
+
postmountFor,
|
|
5787
|
+
style: passedStyle ?? null,
|
|
5788
|
+
styleWhilePremounted: styleWhilePremounted ?? null,
|
|
5789
|
+
styleWhilePostmounted: styleWhilePostmounted ?? null,
|
|
5790
|
+
hideWhilePremounted: "opacity"
|
|
5791
|
+
});
|
|
5739
5792
|
return /* @__PURE__ */ jsx12(Freeze, {
|
|
5740
5793
|
frame: freezeFrame,
|
|
5741
|
-
active:
|
|
5794
|
+
active: isPremountingOrPostmounting,
|
|
5742
5795
|
children: /* @__PURE__ */ jsx12(SequenceInner, {
|
|
5743
5796
|
ref,
|
|
5744
5797
|
from,
|
|
5745
5798
|
durationInFrames,
|
|
5746
|
-
style,
|
|
5799
|
+
style: premountingStyle ?? undefined,
|
|
5747
5800
|
_remotionInternalPremountDisplay: premountFor,
|
|
5748
5801
|
_remotionInternalPostmountDisplay: postmountFor,
|
|
5749
5802
|
_remotionInternalIsPremounting: premountingActive,
|
|
@@ -6079,7 +6132,7 @@ var useEffectChainState = () => {
|
|
|
6079
6132
|
}
|
|
6080
6133
|
};
|
|
6081
6134
|
}, []);
|
|
6082
|
-
return
|
|
6135
|
+
return useMemo16(() => ({
|
|
6083
6136
|
get: (width, height) => {
|
|
6084
6137
|
if (!sizeRef.current || sizeRef.current.width !== width || sizeRef.current.height !== height) {
|
|
6085
6138
|
if (chainStateRef.current) {
|
|
@@ -6095,7 +6148,7 @@ var useEffectChainState = () => {
|
|
|
6095
6148
|
var CanvasRefForwardingFunction = ({ width, height, fit, className, style, effects, ...props }, ref) => {
|
|
6096
6149
|
const canvasRef = useRef8(null);
|
|
6097
6150
|
const chainState = useEffectChainState();
|
|
6098
|
-
const sourceCanvas =
|
|
6151
|
+
const sourceCanvas = useMemo17(() => {
|
|
6099
6152
|
if (typeof document === "undefined") {
|
|
6100
6153
|
return null;
|
|
6101
6154
|
}
|
|
@@ -6652,7 +6705,7 @@ var RenderAssetManagerProvider = ({ children, collectAssets }) => {
|
|
|
6652
6705
|
};
|
|
6653
6706
|
}
|
|
6654
6707
|
}, []);
|
|
6655
|
-
const contextValue =
|
|
6708
|
+
const contextValue = useMemo18(() => {
|
|
6656
6709
|
return {
|
|
6657
6710
|
registerRenderAsset,
|
|
6658
6711
|
unregisterRenderAsset,
|
|
@@ -6666,7 +6719,7 @@ var RenderAssetManagerProvider = ({ children, collectAssets }) => {
|
|
|
6666
6719
|
};
|
|
6667
6720
|
var ArtifactThumbnail = Symbol("Thumbnail");
|
|
6668
6721
|
var Artifact = ({ filename, content, downloadBehavior }) => {
|
|
6669
|
-
const { registerRenderAsset, unregisterRenderAsset } =
|
|
6722
|
+
const { registerRenderAsset, unregisterRenderAsset } = useContext19(RenderAssetManager);
|
|
6670
6723
|
const env = useRemotionEnvironment();
|
|
6671
6724
|
const frame = useCurrentFrame();
|
|
6672
6725
|
const [id] = useState8(() => {
|
|
@@ -6781,14 +6834,14 @@ var Loop = ({
|
|
|
6781
6834
|
const iteration = Math.floor(currentFrame / durationInFrames);
|
|
6782
6835
|
const start = iteration * durationInFrames;
|
|
6783
6836
|
const from = Math.min(start, maxFrame);
|
|
6784
|
-
const loopDisplay =
|
|
6837
|
+
const loopDisplay = useMemo19(() => {
|
|
6785
6838
|
return {
|
|
6786
6839
|
numberOfTimes: Math.min(compDuration / durationInFrames, times),
|
|
6787
6840
|
startOffset: -from,
|
|
6788
6841
|
durationInFrames
|
|
6789
6842
|
};
|
|
6790
6843
|
}, [compDuration, durationInFrames, from, times]);
|
|
6791
|
-
const loopContext =
|
|
6844
|
+
const loopContext = useMemo19(() => {
|
|
6792
6845
|
return {
|
|
6793
6846
|
iteration: Math.floor(currentFrame / durationInFrames),
|
|
6794
6847
|
durationInFrames
|
|
@@ -6857,7 +6910,7 @@ var getSrcWithoutHash = (src) => {
|
|
|
6857
6910
|
return src.slice(0, hashIndex);
|
|
6858
6911
|
};
|
|
6859
6912
|
var usePreload = (src) => {
|
|
6860
|
-
const preloads2 =
|
|
6913
|
+
const preloads2 = useContext20(PreloadContext);
|
|
6861
6914
|
const hashFragmentIndex = removeAndGetHashFragment(src);
|
|
6862
6915
|
const withoutHashFragment = getSrcWithoutHash(src);
|
|
6863
6916
|
if (!preloads2[withoutHashFragment]) {
|
|
@@ -7160,7 +7213,7 @@ var DurationsContext = createContext20({
|
|
|
7160
7213
|
});
|
|
7161
7214
|
var DurationsContextProvider = ({ children }) => {
|
|
7162
7215
|
const [durations, setDurations] = useReducer(durationReducer, {});
|
|
7163
|
-
const value =
|
|
7216
|
+
const value = useMemo20(() => {
|
|
7164
7217
|
return {
|
|
7165
7218
|
durations,
|
|
7166
7219
|
setDurations
|
|
@@ -7299,7 +7352,7 @@ var useSingletonAudioContext = ({
|
|
|
7299
7352
|
if (sampleRate !== initialSampleRate.current) {
|
|
7300
7353
|
throw new Error(`Changing the AudioContext sample rate dynamically is not supported. The sample rate was initialized with ${initialSampleRate.current} Hz, but ${sampleRate} Hz was passed later.`);
|
|
7301
7354
|
}
|
|
7302
|
-
const context =
|
|
7355
|
+
const context = useMemo21(() => {
|
|
7303
7356
|
if (env.isRendering) {
|
|
7304
7357
|
return null;
|
|
7305
7358
|
}
|
|
@@ -7433,9 +7486,9 @@ var SharedAudioContextProvider = ({ children, audioLatencyHint, audioEnabled, pr
|
|
|
7433
7486
|
});
|
|
7434
7487
|
const audioContextIsPlayingEventually = useRef12(false);
|
|
7435
7488
|
const isResuming = useRef12(null);
|
|
7436
|
-
const audioSyncAnchor =
|
|
7489
|
+
const audioSyncAnchor = useMemo22(() => ({ value: 0 }), []);
|
|
7437
7490
|
const audioSyncAnchorListeners = useRef12([]);
|
|
7438
|
-
const audioSyncAnchorEmitter =
|
|
7491
|
+
const audioSyncAnchorEmitter = useMemo22(() => {
|
|
7439
7492
|
return {
|
|
7440
7493
|
dispatch: (event) => {
|
|
7441
7494
|
audioSyncAnchorListeners.current.forEach((l) => l(event));
|
|
@@ -7455,7 +7508,7 @@ var SharedAudioContextProvider = ({ children, audioLatencyHint, audioEnabled, pr
|
|
|
7455
7508
|
const unscheduleAudioNode = useCallback9((node) => {
|
|
7456
7509
|
nodesToResume.current.delete(node);
|
|
7457
7510
|
}, []);
|
|
7458
|
-
const scheduleAudioNode =
|
|
7511
|
+
const scheduleAudioNode = useMemo22(() => {
|
|
7459
7512
|
return ({
|
|
7460
7513
|
node,
|
|
7461
7514
|
mediaTimestamp,
|
|
@@ -7547,7 +7600,7 @@ var SharedAudioContextProvider = ({ children, audioLatencyHint, audioEnabled, pr
|
|
|
7547
7600
|
audioContextIsPlayingEventually.current = false;
|
|
7548
7601
|
return ctxAndGain.suspend();
|
|
7549
7602
|
}, [ctxAndGain]);
|
|
7550
|
-
const audioContextValue =
|
|
7603
|
+
const audioContextValue = useMemo22(() => {
|
|
7551
7604
|
return {
|
|
7552
7605
|
audioContext: ctxAndGain?.audioContext ?? null,
|
|
7553
7606
|
getAudioContextState: () => ctxAndGain?.getState() ?? null,
|
|
@@ -7584,10 +7637,10 @@ var SharedAudioTagsContextProvider = ({ children, numberOfAudioTags }) => {
|
|
|
7584
7637
|
const logLevel = useLogLevel();
|
|
7585
7638
|
const mountTime = useMountTime();
|
|
7586
7639
|
const env = useRemotionEnvironment();
|
|
7587
|
-
const audioCtx =
|
|
7640
|
+
const audioCtx = useContext21(SharedAudioContext);
|
|
7588
7641
|
const audioContext = audioCtx?.audioContext ?? null;
|
|
7589
7642
|
const resume = audioCtx?.resume;
|
|
7590
|
-
const refs =
|
|
7643
|
+
const refs = useMemo22(() => {
|
|
7591
7644
|
return new Array(numberOfAudioTags).fill(true).map(() => {
|
|
7592
7645
|
const ref = createRef2();
|
|
7593
7646
|
return {
|
|
@@ -7726,7 +7779,7 @@ var SharedAudioTagsContextProvider = ({ children, numberOfAudioTags }) => {
|
|
|
7726
7779
|
});
|
|
7727
7780
|
resume?.();
|
|
7728
7781
|
}, [logLevel, mountTime, refs, env.isPlayer, resume]);
|
|
7729
|
-
const audioTagsValue =
|
|
7782
|
+
const audioTagsValue = useMemo22(() => {
|
|
7730
7783
|
return {
|
|
7731
7784
|
registerAudio,
|
|
7732
7785
|
unregisterAudio,
|
|
@@ -7741,7 +7794,7 @@ var SharedAudioTagsContextProvider = ({ children, numberOfAudioTags }) => {
|
|
|
7741
7794
|
unregisterAudio,
|
|
7742
7795
|
updateAudio
|
|
7743
7796
|
]);
|
|
7744
|
-
const sharedAudioTagElements =
|
|
7797
|
+
const sharedAudioTagElements = useMemo22(() => {
|
|
7745
7798
|
return refs.map(({ id, ref }) => {
|
|
7746
7799
|
return /* @__PURE__ */ jsx19("audio", {
|
|
7747
7800
|
ref,
|
|
@@ -7764,8 +7817,8 @@ var useSharedAudio = ({
|
|
|
7764
7817
|
premounting,
|
|
7765
7818
|
postmounting
|
|
7766
7819
|
}) => {
|
|
7767
|
-
const audioCtx =
|
|
7768
|
-
const tagsCtx =
|
|
7820
|
+
const audioCtx = useContext21(SharedAudioContext);
|
|
7821
|
+
const tagsCtx = useContext21(SharedAudioTagsContext);
|
|
7769
7822
|
const [elem] = useState10(() => {
|
|
7770
7823
|
if (tagsCtx && tagsCtx.numberOfAudioTags > 0) {
|
|
7771
7824
|
return tagsCtx.registerAudio({ aud, audioId, premounting, postmounting });
|
|
@@ -7944,7 +7997,7 @@ var useVolume = ({
|
|
|
7944
7997
|
const audioStuffRef = useRef14(null);
|
|
7945
7998
|
const currentVolumeRef = useRef14(volume);
|
|
7946
7999
|
currentVolumeRef.current = volume;
|
|
7947
|
-
const sharedAudioContext =
|
|
8000
|
+
const sharedAudioContext = useContext22(SharedAudioContext);
|
|
7948
8001
|
if (!sharedAudioContext) {
|
|
7949
8002
|
throw new Error("useAmplification must be used within a SharedAudioContext");
|
|
7950
8003
|
}
|
|
@@ -8009,7 +8062,7 @@ var useVolume = ({
|
|
|
8009
8062
|
return audioStuffRef;
|
|
8010
8063
|
};
|
|
8011
8064
|
var useMediaStartsAt = () => {
|
|
8012
|
-
const parentSequence =
|
|
8065
|
+
const parentSequence = useContext23(SequenceContext);
|
|
8013
8066
|
return parentSequence?.cumulatedNegativeFrom ?? 0;
|
|
8014
8067
|
};
|
|
8015
8068
|
var useFrameForVolumeProp = (behavior) => {
|
|
@@ -8098,7 +8151,7 @@ var useBasicMediaInTimeline = ({
|
|
|
8098
8151
|
if (!src) {
|
|
8099
8152
|
throw new Error("No src passed");
|
|
8100
8153
|
}
|
|
8101
|
-
const parentSequence =
|
|
8154
|
+
const parentSequence = useContext24(SequenceContext);
|
|
8102
8155
|
const [initialVolume] = useState11(() => volume);
|
|
8103
8156
|
const duration = getTimelineDuration({
|
|
8104
8157
|
compositionDurationInFrames: sequenceDurationInFrames,
|
|
@@ -8108,7 +8161,7 @@ var useBasicMediaInTimeline = ({
|
|
|
8108
8161
|
parentSequenceDurationInFrames: parentSequence?.durationInFrames ?? null,
|
|
8109
8162
|
loop
|
|
8110
8163
|
});
|
|
8111
|
-
const volumes =
|
|
8164
|
+
const volumes = useMemo23(() => {
|
|
8112
8165
|
if (typeof volume === "number") {
|
|
8113
8166
|
return volume;
|
|
8114
8167
|
}
|
|
@@ -8129,7 +8182,7 @@ var useBasicMediaInTimeline = ({
|
|
|
8129
8182
|
const nonce = useNonce();
|
|
8130
8183
|
const { rootId } = useTimelineContext();
|
|
8131
8184
|
const startMediaFrom = 0 - mediaStartsAt + (trimBefore ?? 0);
|
|
8132
|
-
const memoizedResult =
|
|
8185
|
+
const memoizedResult = useMemo23(() => {
|
|
8133
8186
|
return {
|
|
8134
8187
|
volumes,
|
|
8135
8188
|
duration,
|
|
@@ -8170,9 +8223,9 @@ var useMediaInTimeline = ({
|
|
|
8170
8223
|
documentationLink,
|
|
8171
8224
|
refForOutline
|
|
8172
8225
|
}) => {
|
|
8173
|
-
const parentSequence =
|
|
8226
|
+
const parentSequence = useContext24(SequenceContext);
|
|
8174
8227
|
const startsAt = useMediaStartsAt();
|
|
8175
|
-
const { registerSequence, unregisterSequence } =
|
|
8228
|
+
const { registerSequence, unregisterSequence } = useContext24(SequenceManager);
|
|
8176
8229
|
const { durationInFrames } = useVideoConfig();
|
|
8177
8230
|
const mediaStartsAt = useMediaStartsAt();
|
|
8178
8231
|
const { volumes, duration, doesVolumeChange, nonce, rootId, finalDisplayName } = useBasicMediaInTimeline({
|
|
@@ -8337,13 +8390,13 @@ var useBufferManager = (logLevel, mountTime) => {
|
|
|
8337
8390
|
}
|
|
8338
8391
|
}, [blocks]);
|
|
8339
8392
|
}
|
|
8340
|
-
return
|
|
8393
|
+
return useMemo24(() => {
|
|
8341
8394
|
return { addBlock, listenForBuffering, listenForResume, buffering };
|
|
8342
8395
|
}, [addBlock, buffering, listenForBuffering, listenForResume]);
|
|
8343
8396
|
};
|
|
8344
8397
|
var BufferingContextReact = React21.createContext(null);
|
|
8345
8398
|
var BufferingProvider = ({ children }) => {
|
|
8346
|
-
const { logLevel, mountTime } =
|
|
8399
|
+
const { logLevel, mountTime } = useContext25(LogLevelContext);
|
|
8347
8400
|
const bufferManager = useBufferManager(logLevel ?? "info", mountTime);
|
|
8348
8401
|
return /* @__PURE__ */ jsx20(BufferingContextReact.Provider, {
|
|
8349
8402
|
value: bufferManager,
|
|
@@ -8369,10 +8422,10 @@ var useIsPlayerBuffering = (bufferManager) => {
|
|
|
8369
8422
|
return isBuffering;
|
|
8370
8423
|
};
|
|
8371
8424
|
var useBufferState = () => {
|
|
8372
|
-
const buffer =
|
|
8425
|
+
const buffer = useContext26(BufferingContextReact);
|
|
8373
8426
|
const logLevel = useLogLevel();
|
|
8374
8427
|
const addBlock = buffer ? buffer.addBlock : null;
|
|
8375
|
-
return
|
|
8428
|
+
return useMemo25(() => ({
|
|
8376
8429
|
delayPlayback: () => {
|
|
8377
8430
|
if (!addBlock) {
|
|
8378
8431
|
throw new Error("Tried to enable the buffering state, but a Remotion context was not found. This API can only be called in a component that was passed to the Remotion Player or a <Composition>. Or you might have experienced a version mismatch - run `npx remotion versions` and ensure all packages have the same version. This error is thrown by the buffer state https://remotion.dev/docs/player/buffer-state");
|
|
@@ -8480,7 +8533,7 @@ var useBufferUntilFirstFrame = ({
|
|
|
8480
8533
|
onVariableFpsVideoDetected,
|
|
8481
8534
|
pauseWhenBuffering
|
|
8482
8535
|
]);
|
|
8483
|
-
return
|
|
8536
|
+
return useMemo26(() => {
|
|
8484
8537
|
return {
|
|
8485
8538
|
isBuffering: () => bufferingRef.current,
|
|
8486
8539
|
bufferUntilFirstFrame
|
|
@@ -8854,7 +8907,7 @@ var useMediaPlayback = ({
|
|
|
8854
8907
|
const frame = useCurrentFrame();
|
|
8855
8908
|
const absoluteFrame = useTimelinePosition();
|
|
8856
8909
|
const [playing] = usePlayingState();
|
|
8857
|
-
const buffering =
|
|
8910
|
+
const buffering = useContext27(BufferingContextReact);
|
|
8858
8911
|
const { fps } = useVideoConfig();
|
|
8859
8912
|
const mediaStartsAt = useMediaStartsAt();
|
|
8860
8913
|
const lastSeekDueToShift = useRef18(null);
|
|
@@ -9149,16 +9202,16 @@ var SetMediaVolumeContext = createContext22({
|
|
|
9149
9202
|
}
|
|
9150
9203
|
});
|
|
9151
9204
|
var useMediaVolumeState = () => {
|
|
9152
|
-
const { mediaVolume } =
|
|
9153
|
-
const { setMediaVolume } =
|
|
9154
|
-
return
|
|
9205
|
+
const { mediaVolume } = useContext28(MediaVolumeContext);
|
|
9206
|
+
const { setMediaVolume } = useContext28(SetMediaVolumeContext);
|
|
9207
|
+
return useMemo27(() => {
|
|
9155
9208
|
return [mediaVolume, setMediaVolume];
|
|
9156
9209
|
}, [mediaVolume, setMediaVolume]);
|
|
9157
9210
|
};
|
|
9158
9211
|
var usePlayerMutedState = () => {
|
|
9159
|
-
const { playerMuted } =
|
|
9160
|
-
const { setPlayerMuted } =
|
|
9161
|
-
return
|
|
9212
|
+
const { playerMuted } = useContext28(MediaVolumeContext);
|
|
9213
|
+
const { setPlayerMuted } = useContext28(SetMediaVolumeContext);
|
|
9214
|
+
return useMemo27(() => {
|
|
9162
9215
|
return [playerMuted, setPlayerMuted];
|
|
9163
9216
|
}, [playerMuted, setPlayerMuted]);
|
|
9164
9217
|
};
|
|
@@ -9212,7 +9265,7 @@ var AudioForDevelopmentForwardRefFunction = (props, ref) => {
|
|
|
9212
9265
|
throw new TypeError("No 'src' was passed to <Html5Audio>.");
|
|
9213
9266
|
}
|
|
9214
9267
|
const preloadedSrc = usePreload(src);
|
|
9215
|
-
const sequenceContext =
|
|
9268
|
+
const sequenceContext = useContext29(SequenceContext);
|
|
9216
9269
|
const [timelineId] = useState14(() => String(Math.random()));
|
|
9217
9270
|
const userPreferredVolume = evaluateVolume({
|
|
9218
9271
|
frame: volumePropFrame,
|
|
@@ -9225,7 +9278,7 @@ var AudioForDevelopmentForwardRefFunction = (props, ref) => {
|
|
|
9225
9278
|
requestsVideoFrame: false,
|
|
9226
9279
|
isClientSideRendering: false
|
|
9227
9280
|
});
|
|
9228
|
-
const propsToPass =
|
|
9281
|
+
const propsToPass = useMemo28(() => {
|
|
9229
9282
|
return {
|
|
9230
9283
|
muted: muted || playerMuted || userPreferredVolume <= 0,
|
|
9231
9284
|
src: preloadedSrc,
|
|
@@ -9242,7 +9295,7 @@ var AudioForDevelopmentForwardRefFunction = (props, ref) => {
|
|
|
9242
9295
|
userPreferredVolume,
|
|
9243
9296
|
crossOriginValue
|
|
9244
9297
|
]);
|
|
9245
|
-
const id =
|
|
9298
|
+
const id = useMemo28(() => `audio-${random(src ?? "")}-${sequenceContext?.relativeFrom}-${sequenceContext?.cumulatedFrom}-${sequenceContext?.durationInFrames}-muted:${props.muted}-loop:${props.loop}`, [
|
|
9246
9299
|
src,
|
|
9247
9300
|
sequenceContext?.relativeFrom,
|
|
9248
9301
|
sequenceContext?.cumulatedFrom,
|
|
@@ -9372,10 +9425,10 @@ var AudioForRenderingRefForwardingFunction = (props, ref) => {
|
|
|
9372
9425
|
const absoluteFrame = useTimelinePosition();
|
|
9373
9426
|
const volumePropFrame = useFrameForVolumeProp(loopVolumeCurveBehavior ?? "repeat");
|
|
9374
9427
|
const frame = useCurrentFrame();
|
|
9375
|
-
const sequenceContext =
|
|
9376
|
-
const { registerRenderAsset, unregisterRenderAsset } =
|
|
9428
|
+
const sequenceContext = useContext30(SequenceContext);
|
|
9429
|
+
const { registerRenderAsset, unregisterRenderAsset } = useContext30(RenderAssetManager);
|
|
9377
9430
|
const { delayRender: delayRender2, continueRender: continueRender2 } = useDelayRender();
|
|
9378
|
-
const id =
|
|
9431
|
+
const id = useMemo29(() => `audio-${random(props.src ?? "")}-${sequenceContext?.relativeFrom}-${sequenceContext?.cumulatedFrom}-${sequenceContext?.durationInFrames}`, [
|
|
9379
9432
|
props.src,
|
|
9380
9433
|
sequenceContext?.relativeFrom,
|
|
9381
9434
|
sequenceContext?.cumulatedFrom,
|
|
@@ -9482,7 +9535,7 @@ var AudioForRenderingRefForwardingFunction = (props, ref) => {
|
|
|
9482
9535
|
};
|
|
9483
9536
|
var AudioForRendering = forwardRef6(AudioForRenderingRefForwardingFunction);
|
|
9484
9537
|
var AudioRefForwardingFunction = (props, ref) => {
|
|
9485
|
-
const audioTagsContext =
|
|
9538
|
+
const audioTagsContext = useContext31(SharedAudioTagsContext);
|
|
9486
9539
|
const propsWithFreeze = props;
|
|
9487
9540
|
const {
|
|
9488
9541
|
startFrom,
|
|
@@ -9506,7 +9559,7 @@ var AudioRefForwardingFunction = (props, ref) => {
|
|
|
9506
9559
|
if (typeof freeze !== "undefined") {
|
|
9507
9560
|
throw new TypeError('The "freeze" prop is not supported on <Html5Audio />. Use <Sequence freeze={...}> to freeze media playback.');
|
|
9508
9561
|
}
|
|
9509
|
-
const { durations, setDurations } =
|
|
9562
|
+
const { durations, setDurations } = useContext31(DurationsContext);
|
|
9510
9563
|
if (typeof props.src !== "string") {
|
|
9511
9564
|
throw new TypeError(`The \`<Html5Audio>\` tag requires a string for \`src\`, but got ${JSON.stringify(props.src)} instead.`);
|
|
9512
9565
|
}
|
|
@@ -9668,7 +9721,7 @@ var SolidInner = ({
|
|
|
9668
9721
|
effects,
|
|
9669
9722
|
overrideId: overrideId ?? null
|
|
9670
9723
|
});
|
|
9671
|
-
const sourceCanvas =
|
|
9724
|
+
const sourceCanvas = useMemo30(() => {
|
|
9672
9725
|
if (typeof document === "undefined") {
|
|
9673
9726
|
return null;
|
|
9674
9727
|
}
|
|
@@ -9736,7 +9789,7 @@ var SolidInner = ({
|
|
|
9736
9789
|
cancelRender2,
|
|
9737
9790
|
memoizedEffects
|
|
9738
9791
|
]);
|
|
9739
|
-
const canvasStyle =
|
|
9792
|
+
const canvasStyle = useMemo30(() => {
|
|
9740
9793
|
return {
|
|
9741
9794
|
width,
|
|
9742
9795
|
height,
|
|
@@ -9885,7 +9938,7 @@ var HtmlInCanvasContent = forwardRef9(({
|
|
|
9885
9938
|
controls,
|
|
9886
9939
|
style
|
|
9887
9940
|
}, ref) => {
|
|
9888
|
-
const ancestor =
|
|
9941
|
+
const ancestor = useContext32(HtmlInCanvasAncestorContext);
|
|
9889
9942
|
assertHtmlInCanvasDimensions(width, height);
|
|
9890
9943
|
const resolvedPixelDensity = resolveHtmlInCanvasPixelDensity(pixelDensity);
|
|
9891
9944
|
const canvasWidth = Math.ceil(width * resolvedPixelDensity);
|
|
@@ -10104,20 +10157,20 @@ var HtmlInCanvasContent = forwardRef9(({
|
|
|
10104
10157
|
continueRender2(handle);
|
|
10105
10158
|
};
|
|
10106
10159
|
}, [width, height, continueRender2, canvasSizeKey]);
|
|
10107
|
-
const innerStyle =
|
|
10160
|
+
const innerStyle = useMemo31(() => {
|
|
10108
10161
|
return {
|
|
10109
10162
|
width,
|
|
10110
10163
|
height
|
|
10111
10164
|
};
|
|
10112
10165
|
}, [width, height]);
|
|
10113
|
-
const canvasStyle =
|
|
10166
|
+
const canvasStyle = useMemo31(() => {
|
|
10114
10167
|
return {
|
|
10115
10168
|
width,
|
|
10116
10169
|
height,
|
|
10117
10170
|
...style ?? {}
|
|
10118
10171
|
};
|
|
10119
10172
|
}, [height, style, width]);
|
|
10120
|
-
const ancestorValue =
|
|
10173
|
+
const ancestorValue = useMemo31(() => {
|
|
10121
10174
|
return {
|
|
10122
10175
|
requestParentPaint: () => {
|
|
10123
10176
|
canvas2dRef.current?.requestPaint?.();
|
|
@@ -10331,7 +10384,7 @@ var CanvasImageContent = forwardRef10(({
|
|
|
10331
10384
|
effects,
|
|
10332
10385
|
overrideId: controls?.overrideId ?? null
|
|
10333
10386
|
});
|
|
10334
|
-
const sequenceContext =
|
|
10387
|
+
const sequenceContext = useContext33(SequenceContext);
|
|
10335
10388
|
const pendingLoadDelayRef = useRef23(null);
|
|
10336
10389
|
const [isLoadPending, setIsLoadPending] = useState16(false);
|
|
10337
10390
|
const isPremounting = Boolean(sequenceContext?.premounting);
|
|
@@ -10348,7 +10401,7 @@ var CanvasImageContent = forwardRef10(({
|
|
|
10348
10401
|
continueRender2(pending.handle);
|
|
10349
10402
|
pendingLoadDelayRef.current = null;
|
|
10350
10403
|
}, [continueRender2]);
|
|
10351
|
-
const sourceCanvas =
|
|
10404
|
+
const sourceCanvas = useMemo32(() => {
|
|
10352
10405
|
if (typeof document === "undefined") {
|
|
10353
10406
|
return null;
|
|
10354
10407
|
}
|
|
@@ -10670,7 +10723,7 @@ var ImgContent = ({
|
|
|
10670
10723
|
const imageRef = useRef24(null);
|
|
10671
10724
|
const errors = useRef24({});
|
|
10672
10725
|
const { delayPlayback } = useBufferState();
|
|
10673
|
-
const sequenceContext =
|
|
10726
|
+
const sequenceContext = useContext34(SequenceContext);
|
|
10674
10727
|
const [isLoading, setIsLoading] = useState18(false);
|
|
10675
10728
|
const _propsValid = true;
|
|
10676
10729
|
if (!_propsValid) {
|
|
@@ -11019,7 +11072,10 @@ var makeRemotionComponentIdentity = ({
|
|
|
11019
11072
|
};
|
|
11020
11073
|
var interactiveElementSchema = {
|
|
11021
11074
|
...baseSchema,
|
|
11022
|
-
...transformSchema
|
|
11075
|
+
...transformSchema
|
|
11076
|
+
};
|
|
11077
|
+
var interactiveTextElementSchema = {
|
|
11078
|
+
...interactiveElementSchema,
|
|
11023
11079
|
...textSchema,
|
|
11024
11080
|
...textContentSchema
|
|
11025
11081
|
};
|
|
@@ -11035,7 +11091,7 @@ var withSchema = (options) => {
|
|
|
11035
11091
|
addSequenceStackTraces(Wrapped);
|
|
11036
11092
|
return Wrapped;
|
|
11037
11093
|
};
|
|
11038
|
-
var makeInteractiveElement = (tag, displayName) => {
|
|
11094
|
+
var makeInteractiveElement = (tag, displayName, schema) => {
|
|
11039
11095
|
const Inner = forwardRef12((propsWithControls, ref) => {
|
|
11040
11096
|
const {
|
|
11041
11097
|
durationInFrames,
|
|
@@ -11081,12 +11137,18 @@ var makeInteractiveElement = (tag, displayName) => {
|
|
|
11081
11137
|
packageName: "remotion",
|
|
11082
11138
|
componentName: displayName.slice(1, -1)
|
|
11083
11139
|
}),
|
|
11084
|
-
schema
|
|
11140
|
+
schema,
|
|
11085
11141
|
supportsEffects: false
|
|
11086
11142
|
});
|
|
11087
11143
|
Wrapped.displayName = displayName;
|
|
11088
11144
|
return Wrapped;
|
|
11089
11145
|
};
|
|
11146
|
+
var makeInteractiveTextElement = (tag, displayName) => {
|
|
11147
|
+
return makeInteractiveElement(tag, displayName, interactiveTextElementSchema);
|
|
11148
|
+
};
|
|
11149
|
+
var makeInteractiveNonTextElement = (tag, displayName) => {
|
|
11150
|
+
return makeInteractiveElement(tag, displayName, interactiveElementSchema);
|
|
11151
|
+
};
|
|
11090
11152
|
var Interactive = {
|
|
11091
11153
|
baseSchema,
|
|
11092
11154
|
transformSchema,
|
|
@@ -11095,41 +11157,41 @@ var Interactive = {
|
|
|
11095
11157
|
sequenceSchema,
|
|
11096
11158
|
withSchema,
|
|
11097
11159
|
_internalMakeRemotionComponentIdentity: makeRemotionComponentIdentity,
|
|
11098
|
-
A:
|
|
11099
|
-
Article:
|
|
11100
|
-
Aside:
|
|
11101
|
-
Button:
|
|
11102
|
-
Circle:
|
|
11103
|
-
Code:
|
|
11104
|
-
Div:
|
|
11105
|
-
Ellipse:
|
|
11106
|
-
Em:
|
|
11107
|
-
Footer:
|
|
11108
|
-
G:
|
|
11109
|
-
H1:
|
|
11110
|
-
H2:
|
|
11111
|
-
H3:
|
|
11112
|
-
H4:
|
|
11113
|
-
H5:
|
|
11114
|
-
H6:
|
|
11115
|
-
Header:
|
|
11116
|
-
Label:
|
|
11117
|
-
Li:
|
|
11118
|
-
Line:
|
|
11119
|
-
Main:
|
|
11120
|
-
Nav:
|
|
11121
|
-
Ol:
|
|
11122
|
-
P:
|
|
11123
|
-
Path:
|
|
11124
|
-
Pre:
|
|
11125
|
-
Rect:
|
|
11126
|
-
Section:
|
|
11127
|
-
Small:
|
|
11128
|
-
Span:
|
|
11129
|
-
Strong:
|
|
11130
|
-
Svg:
|
|
11131
|
-
Text:
|
|
11132
|
-
Ul:
|
|
11160
|
+
A: makeInteractiveTextElement("a", "<Interactive.A>"),
|
|
11161
|
+
Article: makeInteractiveTextElement("article", "<Interactive.Article>"),
|
|
11162
|
+
Aside: makeInteractiveTextElement("aside", "<Interactive.Aside>"),
|
|
11163
|
+
Button: makeInteractiveTextElement("button", "<Interactive.Button>"),
|
|
11164
|
+
Circle: makeInteractiveNonTextElement("circle", "<Interactive.Circle>"),
|
|
11165
|
+
Code: makeInteractiveTextElement("code", "<Interactive.Code>"),
|
|
11166
|
+
Div: makeInteractiveTextElement("div", "<Interactive.Div>"),
|
|
11167
|
+
Ellipse: makeInteractiveNonTextElement("ellipse", "<Interactive.Ellipse>"),
|
|
11168
|
+
Em: makeInteractiveTextElement("em", "<Interactive.Em>"),
|
|
11169
|
+
Footer: makeInteractiveTextElement("footer", "<Interactive.Footer>"),
|
|
11170
|
+
G: makeInteractiveNonTextElement("g", "<Interactive.G>"),
|
|
11171
|
+
H1: makeInteractiveTextElement("h1", "<Interactive.H1>"),
|
|
11172
|
+
H2: makeInteractiveTextElement("h2", "<Interactive.H2>"),
|
|
11173
|
+
H3: makeInteractiveTextElement("h3", "<Interactive.H3>"),
|
|
11174
|
+
H4: makeInteractiveTextElement("h4", "<Interactive.H4>"),
|
|
11175
|
+
H5: makeInteractiveTextElement("h5", "<Interactive.H5>"),
|
|
11176
|
+
H6: makeInteractiveTextElement("h6", "<Interactive.H6>"),
|
|
11177
|
+
Header: makeInteractiveTextElement("header", "<Interactive.Header>"),
|
|
11178
|
+
Label: makeInteractiveTextElement("label", "<Interactive.Label>"),
|
|
11179
|
+
Li: makeInteractiveTextElement("li", "<Interactive.Li>"),
|
|
11180
|
+
Line: makeInteractiveNonTextElement("line", "<Interactive.Line>"),
|
|
11181
|
+
Main: makeInteractiveTextElement("main", "<Interactive.Main>"),
|
|
11182
|
+
Nav: makeInteractiveTextElement("nav", "<Interactive.Nav>"),
|
|
11183
|
+
Ol: makeInteractiveTextElement("ol", "<Interactive.Ol>"),
|
|
11184
|
+
P: makeInteractiveTextElement("p", "<Interactive.P>"),
|
|
11185
|
+
Path: makeInteractiveNonTextElement("path", "<Interactive.Path>"),
|
|
11186
|
+
Pre: makeInteractiveTextElement("pre", "<Interactive.Pre>"),
|
|
11187
|
+
Rect: makeInteractiveNonTextElement("rect", "<Interactive.Rect>"),
|
|
11188
|
+
Section: makeInteractiveTextElement("section", "<Interactive.Section>"),
|
|
11189
|
+
Small: makeInteractiveTextElement("small", "<Interactive.Small>"),
|
|
11190
|
+
Span: makeInteractiveTextElement("span", "<Interactive.Span>"),
|
|
11191
|
+
Strong: makeInteractiveTextElement("strong", "<Interactive.Strong>"),
|
|
11192
|
+
Svg: makeInteractiveNonTextElement("svg", "<Interactive.Svg>"),
|
|
11193
|
+
Text: makeInteractiveTextElement("text", "<Interactive.Text>"),
|
|
11194
|
+
Ul: makeInteractiveTextElement("ul", "<Interactive.Ul>")
|
|
11133
11195
|
};
|
|
11134
11196
|
var compositionsRef = React31.createRef();
|
|
11135
11197
|
var CompositionManagerProvider = ({
|
|
@@ -11186,7 +11248,7 @@ var CompositionManagerProvider = ({
|
|
|
11186
11248
|
getCompositions: () => currentcompositionsRef.current
|
|
11187
11249
|
};
|
|
11188
11250
|
}, []);
|
|
11189
|
-
const compositionManagerSetters =
|
|
11251
|
+
const compositionManagerSetters = useMemo33(() => {
|
|
11190
11252
|
return {
|
|
11191
11253
|
registerComposition,
|
|
11192
11254
|
unregisterComposition,
|
|
@@ -11202,7 +11264,7 @@ var CompositionManagerProvider = ({
|
|
|
11202
11264
|
unregisterFolder,
|
|
11203
11265
|
onlyRenderComposition
|
|
11204
11266
|
]);
|
|
11205
|
-
const compositionManagerContextValue =
|
|
11267
|
+
const compositionManagerContextValue = useMemo33(() => {
|
|
11206
11268
|
return {
|
|
11207
11269
|
compositions,
|
|
11208
11270
|
folders,
|
|
@@ -11300,7 +11362,7 @@ var waitForRoot = (fn) => {
|
|
|
11300
11362
|
};
|
|
11301
11363
|
var MediaEnabledContext = createContext24(null);
|
|
11302
11364
|
var useVideoEnabled = () => {
|
|
11303
|
-
const context =
|
|
11365
|
+
const context = useContext35(MediaEnabledContext);
|
|
11304
11366
|
if (!context) {
|
|
11305
11367
|
return window.remotion_videoEnabled;
|
|
11306
11368
|
}
|
|
@@ -11310,7 +11372,7 @@ var useVideoEnabled = () => {
|
|
|
11310
11372
|
return context.videoEnabled;
|
|
11311
11373
|
};
|
|
11312
11374
|
var useAudioEnabled = () => {
|
|
11313
|
-
const context =
|
|
11375
|
+
const context = useContext35(MediaEnabledContext);
|
|
11314
11376
|
if (!context) {
|
|
11315
11377
|
return window.remotion_audioEnabled;
|
|
11316
11378
|
}
|
|
@@ -11324,7 +11386,7 @@ var MediaEnabledProvider = ({
|
|
|
11324
11386
|
videoEnabled,
|
|
11325
11387
|
audioEnabled
|
|
11326
11388
|
}) => {
|
|
11327
|
-
const value =
|
|
11389
|
+
const value = useMemo34(() => ({ videoEnabled, audioEnabled }), [videoEnabled, audioEnabled]);
|
|
11328
11390
|
return /* @__PURE__ */ jsx31(MediaEnabledContext.Provider, {
|
|
11329
11391
|
value,
|
|
11330
11392
|
children
|
|
@@ -11340,13 +11402,13 @@ var RemotionRootContexts = ({
|
|
|
11340
11402
|
audioEnabled,
|
|
11341
11403
|
frameState
|
|
11342
11404
|
}) => {
|
|
11343
|
-
const nonceContext =
|
|
11405
|
+
const nonceContext = useMemo35(() => {
|
|
11344
11406
|
let counter = 0;
|
|
11345
11407
|
return {
|
|
11346
11408
|
getNonce: () => counter++
|
|
11347
11409
|
};
|
|
11348
11410
|
}, []);
|
|
11349
|
-
const logging =
|
|
11411
|
+
const logging = useMemo35(() => {
|
|
11350
11412
|
return { logLevel, mountTime: Date.now() };
|
|
11351
11413
|
}, [logLevel]);
|
|
11352
11414
|
return /* @__PURE__ */ jsx32(LogLevelContext.Provider, {
|
|
@@ -11647,13 +11709,13 @@ var OffthreadVideoForRendering = ({
|
|
|
11647
11709
|
const frame = useCurrentFrame();
|
|
11648
11710
|
const volumePropsFrame = useFrameForVolumeProp(loopVolumeCurveBehavior);
|
|
11649
11711
|
const videoConfig = useUnsafeVideoConfig();
|
|
11650
|
-
const sequenceContext =
|
|
11712
|
+
const sequenceContext = useContext37(SequenceContext);
|
|
11651
11713
|
const mediaStartsAt = useMediaStartsAt();
|
|
11652
|
-
const { registerRenderAsset, unregisterRenderAsset } =
|
|
11714
|
+
const { registerRenderAsset, unregisterRenderAsset } = useContext37(RenderAssetManager);
|
|
11653
11715
|
if (!src) {
|
|
11654
11716
|
throw new TypeError("No `src` was passed to <OffthreadVideo>.");
|
|
11655
11717
|
}
|
|
11656
|
-
const id =
|
|
11718
|
+
const id = useMemo36(() => `offthreadvideo-${random(src)}-${sequenceContext?.cumulatedFrom}-${sequenceContext?.relativeFrom}-${sequenceContext?.durationInFrames}`, [
|
|
11657
11719
|
src,
|
|
11658
11720
|
sequenceContext?.cumulatedFrom,
|
|
11659
11721
|
sequenceContext?.relativeFrom,
|
|
@@ -11708,14 +11770,14 @@ var OffthreadVideoForRendering = ({
|
|
|
11708
11770
|
sequenceContext?.cumulatedNegativeFrom,
|
|
11709
11771
|
audioStreamIndex
|
|
11710
11772
|
]);
|
|
11711
|
-
const currentTime =
|
|
11773
|
+
const currentTime = useMemo36(() => {
|
|
11712
11774
|
return getExpectedMediaFrameUncorrected({
|
|
11713
11775
|
frame,
|
|
11714
11776
|
playbackRate: playbackRate || 1,
|
|
11715
11777
|
startFrom: -mediaStartsAt
|
|
11716
11778
|
}) / videoConfig.fps;
|
|
11717
11779
|
}, [frame, mediaStartsAt, playbackRate, videoConfig.fps]);
|
|
11718
|
-
const actualSrc =
|
|
11780
|
+
const actualSrc = useMemo36(() => {
|
|
11719
11781
|
return getOffthreadVideoSource({
|
|
11720
11782
|
src,
|
|
11721
11783
|
currentTime,
|
|
@@ -11803,7 +11865,7 @@ var OffthreadVideoForRendering = ({
|
|
|
11803
11865
|
cancelRender("Failed to load image with src " + imageSrc);
|
|
11804
11866
|
}
|
|
11805
11867
|
}, [imageSrc, onError]);
|
|
11806
|
-
const className =
|
|
11868
|
+
const className = useMemo36(() => {
|
|
11807
11869
|
return [OBJECTFIT_CONTAIN_CLASS_NAME, props2.className].filter(truthy).join(" ");
|
|
11808
11870
|
}, [props2.className]);
|
|
11809
11871
|
const onImageFrame = useCallback22((img) => {
|
|
@@ -11867,12 +11929,12 @@ class MediaPlaybackError extends Error {
|
|
|
11867
11929
|
}
|
|
11868
11930
|
}
|
|
11869
11931
|
var VideoForDevelopmentRefForwardingFunction = (props2, ref) => {
|
|
11870
|
-
const context =
|
|
11932
|
+
const context = useContext38(SharedAudioContext);
|
|
11871
11933
|
if (!context) {
|
|
11872
11934
|
throw new Error("SharedAudioContext not found");
|
|
11873
11935
|
}
|
|
11874
11936
|
const videoRef = useRef27(null);
|
|
11875
|
-
const sharedSource =
|
|
11937
|
+
const sharedSource = useMemo37(() => {
|
|
11876
11938
|
if (!context.audioContext) {
|
|
11877
11939
|
return null;
|
|
11878
11940
|
}
|
|
@@ -11924,7 +11986,7 @@ var VideoForDevelopmentRefForwardingFunction = (props2, ref) => {
|
|
|
11924
11986
|
}
|
|
11925
11987
|
const volumePropFrame = useFrameForVolumeProp(loopVolumeCurveBehavior ?? "repeat");
|
|
11926
11988
|
const { fps, durationInFrames } = useVideoConfig();
|
|
11927
|
-
const parentSequence =
|
|
11989
|
+
const parentSequence = useContext38(SequenceContext);
|
|
11928
11990
|
const logLevel = useLogLevel();
|
|
11929
11991
|
const mountTime = useMountTime();
|
|
11930
11992
|
const [timelineId] = useState21(() => String(Math.random()));
|
|
@@ -12075,7 +12137,7 @@ var VideoForDevelopmentRefForwardingFunction = (props2, ref) => {
|
|
|
12075
12137
|
current.preload = "auto";
|
|
12076
12138
|
}
|
|
12077
12139
|
}, []);
|
|
12078
|
-
const actualStyle =
|
|
12140
|
+
const actualStyle = useMemo37(() => {
|
|
12079
12141
|
return {
|
|
12080
12142
|
...style
|
|
12081
12143
|
};
|
|
@@ -12271,7 +12333,7 @@ function useRemotionContexts() {
|
|
|
12271
12333
|
const visualModePropStatusesRefContext = React40.useContext(VisualModePropStatusesRefContext);
|
|
12272
12334
|
const bufferManagerContext = React40.useContext(BufferingContextReact);
|
|
12273
12335
|
const logLevelContext = React40.useContext(LogLevelContext);
|
|
12274
|
-
return
|
|
12336
|
+
return useMemo38(() => ({
|
|
12275
12337
|
compositionManagerCtx,
|
|
12276
12338
|
timelineContext,
|
|
12277
12339
|
setTimelineContext,
|
|
@@ -12382,6 +12444,7 @@ var Internals = {
|
|
|
12382
12444
|
textSchema,
|
|
12383
12445
|
transformSchema,
|
|
12384
12446
|
premountSchema,
|
|
12447
|
+
premountStyleSchema,
|
|
12385
12448
|
flattenActiveSchema,
|
|
12386
12449
|
getFlatSchemaWithAllKeys,
|
|
12387
12450
|
RemotionRootContexts,
|
|
@@ -12395,6 +12458,7 @@ var Internals = {
|
|
|
12395
12458
|
truthy,
|
|
12396
12459
|
SequenceContext,
|
|
12397
12460
|
PremountContext,
|
|
12461
|
+
usePremounting,
|
|
12398
12462
|
useRemotionContexts,
|
|
12399
12463
|
RemotionContextProvider,
|
|
12400
12464
|
CSSUtils: exports_default_css,
|
|
@@ -12570,7 +12634,7 @@ var validateSeriesSequenceProps = ({
|
|
|
12570
12634
|
return offset;
|
|
12571
12635
|
};
|
|
12572
12636
|
var SeriesInner = (props2) => {
|
|
12573
|
-
const childrenValue =
|
|
12637
|
+
const childrenValue = useMemo39(() => {
|
|
12574
12638
|
const flattenedChildren = flattenChildren(props2.children);
|
|
12575
12639
|
const renderChildren = (i, startFrame) => {
|
|
12576
12640
|
if (i === flattenedChildren.length) {
|
|
@@ -12899,14 +12963,14 @@ var VideoForRenderingForwardFunction = ({
|
|
|
12899
12963
|
const volumePropsFrame = useFrameForVolumeProp(loopVolumeCurveBehavior ?? "repeat");
|
|
12900
12964
|
const videoConfig = useUnsafeVideoConfig();
|
|
12901
12965
|
const videoRef = useRef28(null);
|
|
12902
|
-
const sequenceContext =
|
|
12966
|
+
const sequenceContext = useContext39(SequenceContext);
|
|
12903
12967
|
const mediaStartsAt = useMediaStartsAt();
|
|
12904
12968
|
const environment = useRemotionEnvironment();
|
|
12905
12969
|
const logLevel = useLogLevel();
|
|
12906
12970
|
const mountTime = useMountTime();
|
|
12907
12971
|
const { delayRender: delayRender2, continueRender: continueRender2 } = useDelayRender();
|
|
12908
|
-
const { registerRenderAsset, unregisterRenderAsset } =
|
|
12909
|
-
const id =
|
|
12972
|
+
const { registerRenderAsset, unregisterRenderAsset } = useContext39(RenderAssetManager);
|
|
12973
|
+
const id = useMemo40(() => `video-${random(props2.src ?? "")}-${sequenceContext?.cumulatedFrom}-${sequenceContext?.relativeFrom}-${sequenceContext?.durationInFrames}`, [
|
|
12910
12974
|
props2.src,
|
|
12911
12975
|
sequenceContext?.cumulatedFrom,
|
|
12912
12976
|
sequenceContext?.relativeFrom,
|
|
@@ -13117,7 +13181,7 @@ var VideoForwardingFunction = (props2, ref) => {
|
|
|
13117
13181
|
if (environment.isClientSideRendering) {
|
|
13118
13182
|
throw new Error("<Html5Video> is not supported in @remotion/web-renderer. Use <Video> from @remotion/media instead. See https://remotion.dev/docs/client-side-rendering/limitations");
|
|
13119
13183
|
}
|
|
13120
|
-
const { durations, setDurations } =
|
|
13184
|
+
const { durations, setDurations } = useContext40(DurationsContext);
|
|
13121
13185
|
if (typeof ref === "string") {
|
|
13122
13186
|
throw new Error("string refs are not supported");
|
|
13123
13187
|
}
|
|
@@ -13573,7 +13637,7 @@ var ExpertCard = ({ expert, Link }) => {
|
|
|
13573
13637
|
});
|
|
13574
13638
|
};
|
|
13575
13639
|
var ExpertsPageContent = ({ Link }) => {
|
|
13576
|
-
const expertsInRandomOrder =
|
|
13640
|
+
const expertsInRandomOrder = useMemo41(() => {
|
|
13577
13641
|
if (typeof window === "undefined") {
|
|
13578
13642
|
return [];
|
|
13579
13643
|
}
|
|
@@ -13671,7 +13735,7 @@ var ExpertsPageContent = ({ Link }) => {
|
|
|
13671
13735
|
});
|
|
13672
13736
|
};
|
|
13673
13737
|
// src/components/homepage/Pricing.tsx
|
|
13674
|
-
import { useMemo as
|
|
13738
|
+
import { useMemo as useMemo54 } from "react";
|
|
13675
13739
|
|
|
13676
13740
|
// ../design/dist/esm/index.mjs
|
|
13677
13741
|
import * as React24 from "react";
|
|
@@ -15019,7 +15083,7 @@ var getDefaultConfig = () => {
|
|
|
15019
15083
|
var twMerge = /* @__PURE__ */ createTailwindMerge(getDefaultConfig);
|
|
15020
15084
|
|
|
15021
15085
|
// ../design/dist/esm/index.mjs
|
|
15022
|
-
import React33, { useEffect as useEffect21, useMemo as
|
|
15086
|
+
import React33, { useEffect as useEffect21, useMemo as useMemo44, useState as useState23 } from "react";
|
|
15023
15087
|
|
|
15024
15088
|
// ../paths/dist/esm/index.mjs
|
|
15025
15089
|
var cutLInstruction = ({
|
|
@@ -17785,7 +17849,7 @@ var PathInternals = {
|
|
|
17785
17849
|
};
|
|
17786
17850
|
|
|
17787
17851
|
// ../shapes/dist/esm/index.mjs
|
|
17788
|
-
import React3, { useCallback as useCallback26, useMemo as
|
|
17852
|
+
import React3, { useCallback as useCallback26, useMemo as useMemo43, useRef as useRef29 } from "react";
|
|
17789
17853
|
import { version } from "react-dom";
|
|
17790
17854
|
import { jsx as jsx44, jsxs as jsxs7 } from "react/jsx-runtime";
|
|
17791
17855
|
import { jsx as jsx210 } from "react/jsx-runtime";
|
|
@@ -17967,13 +18031,13 @@ var RenderSvg = ({
|
|
|
17967
18031
|
stack,
|
|
17968
18032
|
...props
|
|
17969
18033
|
}) => {
|
|
17970
|
-
const actualStyle =
|
|
18034
|
+
const actualStyle = useMemo43(() => {
|
|
17971
18035
|
return {
|
|
17972
18036
|
overflow: "visible",
|
|
17973
18037
|
...style ?? {}
|
|
17974
18038
|
};
|
|
17975
18039
|
}, [style]);
|
|
17976
|
-
const actualPathStyle =
|
|
18040
|
+
const actualPathStyle = useMemo43(() => {
|
|
17977
18041
|
return {
|
|
17978
18042
|
transformBox: "fill-box",
|
|
17979
18043
|
...pathStyle ?? {}
|
|
@@ -20952,7 +21016,7 @@ var useHoverTransforms = (ref, disabled) => {
|
|
|
20952
21016
|
progress: 0,
|
|
20953
21017
|
isActive: false
|
|
20954
21018
|
});
|
|
20955
|
-
const eventTarget =
|
|
21019
|
+
const eventTarget = useMemo44(() => new EventTarget, []);
|
|
20956
21020
|
useEffect21(() => {
|
|
20957
21021
|
if (disabled) {
|
|
20958
21022
|
eventTarget.dispatchEvent(new Event("disabled"));
|
|
@@ -27399,7 +27463,7 @@ var Triangle22 = (props) => {
|
|
|
27399
27463
|
};
|
|
27400
27464
|
|
|
27401
27465
|
// src/components/homepage/FreePricing.tsx
|
|
27402
|
-
import React53, { useCallback as useCallback38, useMemo as
|
|
27466
|
+
import React53, { useCallback as useCallback38, useMemo as useMemo53 } from "react";
|
|
27403
27467
|
|
|
27404
27468
|
// ../../node_modules/.bun/tailwind-merge@2.5.2/node_modules/tailwind-merge/dist/bundle-mjs.mjs
|
|
27405
27469
|
var CLASS_PART_SEPARATOR2 = "-";
|
|
@@ -29056,14 +29120,14 @@ var CompanyPricing = () => {
|
|
|
29056
29120
|
}, []);
|
|
29057
29121
|
const creatorsPrice = creatorsSelected ? devSeatCount * SEAT_PRICE : 0;
|
|
29058
29122
|
const automatorsPrice = automatorsSelected ? Math.ceil(cloudRenders / 1000) * RENDER_UNIT_PRICE : 0;
|
|
29059
|
-
const totalPrice =
|
|
29123
|
+
const totalPrice = useMemo53(() => {
|
|
29060
29124
|
const basePrice = creatorsPrice + automatorsPrice;
|
|
29061
29125
|
if (automatorsSelected) {
|
|
29062
29126
|
return Math.max(100, basePrice);
|
|
29063
29127
|
}
|
|
29064
29128
|
return basePrice;
|
|
29065
29129
|
}, [creatorsPrice, automatorsPrice, automatorsSelected]);
|
|
29066
|
-
const totalPriceString =
|
|
29130
|
+
const totalPriceString = useMemo53(() => {
|
|
29067
29131
|
return formatPrice(totalPrice);
|
|
29068
29132
|
}, [formatPrice, totalPrice]);
|
|
29069
29133
|
const showMinimumMessage = automatorsSelected && creatorsPrice + automatorsPrice < 100;
|
|
@@ -29293,13 +29357,13 @@ var Pricing = ({
|
|
|
29293
29357
|
licenseHref = "https://github.com/remotion-dev/remotion/blob/main/LICENSE.md",
|
|
29294
29358
|
termsHref = "/docs/license/terms"
|
|
29295
29359
|
}) => {
|
|
29296
|
-
const faqLinkTarget =
|
|
29360
|
+
const faqLinkTarget = useMemo54(() => {
|
|
29297
29361
|
return faqHref.startsWith("http") ? "_blank" : undefined;
|
|
29298
29362
|
}, [faqHref]);
|
|
29299
|
-
const licenseLinkTarget =
|
|
29363
|
+
const licenseLinkTarget = useMemo54(() => {
|
|
29300
29364
|
return licenseHref.startsWith("http") ? "_blank" : undefined;
|
|
29301
29365
|
}, [licenseHref]);
|
|
29302
|
-
const termsLinkTarget =
|
|
29366
|
+
const termsLinkTarget = useMemo54(() => {
|
|
29303
29367
|
return termsHref.startsWith("http") ? "_blank" : undefined;
|
|
29304
29368
|
}, [termsHref]);
|
|
29305
29369
|
return /* @__PURE__ */ jsxs11("div", {
|
|
@@ -30123,13 +30187,13 @@ import { jsx as jsx59, jsxs as jsxs16 } from "react/jsx-runtime";
|
|
|
30123
30187
|
import { jsx as jsx214, jsxs as jsxs24, Fragment as Fragment13 } from "react/jsx-runtime";
|
|
30124
30188
|
import React57 from "react";
|
|
30125
30189
|
import { useContext as useContext210, useEffect as useEffect41, useState as useState40 } from "react";
|
|
30126
|
-
import { useContext as
|
|
30190
|
+
import { useContext as useContext47, useLayoutEffect as useLayoutEffect18 } from "react";
|
|
30127
30191
|
import { jsx as jsx314 } from "react/jsx-runtime";
|
|
30128
30192
|
import { useEffect as useEffect210, useState as useState24 } from "react";
|
|
30129
30193
|
import { useLayoutEffect as useLayoutEffect23 } from "react";
|
|
30130
|
-
import { useContext as
|
|
30194
|
+
import { useContext as useContext42, useEffect as useEffect52, useRef as useRef47 } from "react";
|
|
30131
30195
|
import { useEffect as useEffect310, useRef as useRef212 } from "react";
|
|
30132
|
-
import { useCallback as useCallback39, useContext as useContext310, useMemo as
|
|
30196
|
+
import { useCallback as useCallback39, useContext as useContext310, useMemo as useMemo55, useRef as useRef48, useState as useState310 } from "react";
|
|
30133
30197
|
import { useEffect as useEffect42, useRef as useRef310 } from "react";
|
|
30134
30198
|
import { useCallback as useCallback210, useEffect as useEffect62, useMemo as useMemo212, useState as useState42 } from "react";
|
|
30135
30199
|
import {
|
|
@@ -30158,11 +30222,11 @@ import React410, { useEffect as useEffect72 } from "react";
|
|
|
30158
30222
|
import { jsx as jsx55 } from "react/jsx-runtime";
|
|
30159
30223
|
import { useCallback as useCallback72, useEffect as useEffect112, useMemo as useMemo92, useRef as useRef82, useState as useState102 } from "react";
|
|
30160
30224
|
import { jsx as jsx64 } from "react/jsx-runtime";
|
|
30161
|
-
import { useCallback as useCallback42, useMemo as
|
|
30225
|
+
import { useCallback as useCallback42, useMemo as useMemo42, useRef as useRef52, useState as useState62 } from "react";
|
|
30162
30226
|
import React54, { useCallback as useCallback310, useMemo as useMemo310, useState as useState52 } from "react";
|
|
30163
30227
|
import { jsx as jsx74, jsxs as jsxs33 } from "react/jsx-runtime";
|
|
30164
30228
|
import { jsx as jsx84, jsxs as jsxs43 } from "react/jsx-runtime";
|
|
30165
|
-
import { useCallback as useCallback52, useEffect as useEffect92, useMemo as
|
|
30229
|
+
import { useCallback as useCallback52, useEffect as useEffect92, useMemo as useMemo56, useState as useState82 } from "react";
|
|
30166
30230
|
import { useEffect as useEffect83, useRef as useRef62, useState as useState72 } from "react";
|
|
30167
30231
|
import { jsx as jsx94, jsxs as jsxs52 } from "react/jsx-runtime";
|
|
30168
30232
|
import { useCallback as useCallback62, useEffect as useEffect102, useMemo as useMemo62, useRef as useRef72, useState as useState92 } from "react";
|
|
@@ -30903,15 +30967,19 @@ var premountSchema2 = {
|
|
|
30903
30967
|
description: "Premount For",
|
|
30904
30968
|
min: 0,
|
|
30905
30969
|
step: 1,
|
|
30906
|
-
hiddenFromList: false
|
|
30970
|
+
hiddenFromList: false,
|
|
30971
|
+
keyframable: false
|
|
30907
30972
|
},
|
|
30908
30973
|
postmountFor: {
|
|
30909
30974
|
type: "number",
|
|
30910
30975
|
default: 0,
|
|
30911
30976
|
min: 0,
|
|
30912
30977
|
step: 1,
|
|
30913
|
-
hiddenFromList: true
|
|
30914
|
-
|
|
30978
|
+
hiddenFromList: true,
|
|
30979
|
+
keyframable: false
|
|
30980
|
+
}
|
|
30981
|
+
};
|
|
30982
|
+
var premountStyleSchema2 = {
|
|
30915
30983
|
styleWhilePremounted: {
|
|
30916
30984
|
type: "hidden"
|
|
30917
30985
|
},
|
|
@@ -30919,9 +30987,13 @@ var premountSchema2 = {
|
|
|
30919
30987
|
type: "hidden"
|
|
30920
30988
|
}
|
|
30921
30989
|
};
|
|
30990
|
+
var sequencePremountSchema2 = {
|
|
30991
|
+
...premountSchema2,
|
|
30992
|
+
...premountStyleSchema2
|
|
30993
|
+
};
|
|
30922
30994
|
var sequenceStyleSchema2 = {
|
|
30923
30995
|
...transformSchema2,
|
|
30924
|
-
...
|
|
30996
|
+
...sequencePremountSchema2
|
|
30925
30997
|
};
|
|
30926
30998
|
var hiddenField2 = {
|
|
30927
30999
|
type: "boolean",
|
|
@@ -32134,7 +32206,7 @@ class ThumbnailEmitter {
|
|
|
32134
32206
|
};
|
|
32135
32207
|
}
|
|
32136
32208
|
var useBufferStateEmitter = (emitter) => {
|
|
32137
|
-
const bufferManager =
|
|
32209
|
+
const bufferManager = useContext47(Internals.BufferingContextReact);
|
|
32138
32210
|
if (!bufferManager) {
|
|
32139
32211
|
throw new Error("BufferingContextReact not found");
|
|
32140
32212
|
}
|
|
@@ -32348,7 +32420,7 @@ var usePlayer = () => {
|
|
|
32348
32420
|
const isBuffering = useCallback39(() => {
|
|
32349
32421
|
return buffering.current;
|
|
32350
32422
|
}, [buffering]);
|
|
32351
|
-
const returnValue =
|
|
32423
|
+
const returnValue = useMemo55(() => {
|
|
32352
32424
|
return {
|
|
32353
32425
|
frameBack,
|
|
32354
32426
|
frameForward,
|
|
@@ -32592,11 +32664,11 @@ var usePlayback = ({
|
|
|
32592
32664
|
const frame = Internals.Timeline.useTimelinePosition();
|
|
32593
32665
|
const { playing, pause, emitter, isPlaying } = usePlayer();
|
|
32594
32666
|
const setFrame = Internals.Timeline.useTimelineSetFrame();
|
|
32595
|
-
const sharedAudioContext =
|
|
32667
|
+
const sharedAudioContext = useContext42(Internals.SharedAudioContext);
|
|
32596
32668
|
const logLevel = Internals.useLogLevel();
|
|
32597
32669
|
const isBackgroundedRef = useIsBackgrounded();
|
|
32598
32670
|
const lastTimeUpdateTimestamp = useRef47(0);
|
|
32599
|
-
const context =
|
|
32671
|
+
const context = useContext42(Internals.BufferingContextReact);
|
|
32600
32672
|
if (!context) {
|
|
32601
32673
|
throw new Error("Missing the buffering context. Most likely you have a Remotion version mismatch.");
|
|
32602
32674
|
}
|
|
@@ -33194,7 +33266,7 @@ var MediaVolumeSlider = ({ displayVerticalVolumeSlider, renderMuteButton, render
|
|
|
33194
33266
|
}
|
|
33195
33267
|
setPlayerMuted((mute) => !mute);
|
|
33196
33268
|
}, [isVolume0, setPlayerMuted, setMediaVolume]);
|
|
33197
|
-
const parentDivStyle =
|
|
33269
|
+
const parentDivStyle = useMemo42(() => {
|
|
33198
33270
|
return {
|
|
33199
33271
|
display: "inline-flex",
|
|
33200
33272
|
background: "none",
|
|
@@ -33205,7 +33277,7 @@ var MediaVolumeSlider = ({ displayVerticalVolumeSlider, renderMuteButton, render
|
|
|
33205
33277
|
...displayVerticalVolumeSlider && { position: "relative" }
|
|
33206
33278
|
};
|
|
33207
33279
|
}, [displayVerticalVolumeSlider]);
|
|
33208
|
-
const volumeContainer =
|
|
33280
|
+
const volumeContainer = useMemo42(() => {
|
|
33209
33281
|
return {
|
|
33210
33282
|
display: "inline",
|
|
33211
33283
|
width: ICON_SIZE2,
|
|
@@ -33230,10 +33302,10 @@ var MediaVolumeSlider = ({ displayVerticalVolumeSlider, renderMuteButton, render
|
|
|
33230
33302
|
children: isMutedOrZero ? /* @__PURE__ */ jsx84(VolumeOffIcon, {}) : /* @__PURE__ */ jsx84(VolumeOnIcon, {})
|
|
33231
33303
|
});
|
|
33232
33304
|
}, [onBlur, onClick, volumeContainer]);
|
|
33233
|
-
const muteButton =
|
|
33305
|
+
const muteButton = useMemo42(() => {
|
|
33234
33306
|
return renderMuteButton ? renderMuteButton({ muted: playerMuted, volume: mediaVolume }) : renderDefaultMuteButton({ muted: playerMuted, volume: mediaVolume });
|
|
33235
33307
|
}, [playerMuted, mediaVolume, renderDefaultMuteButton, renderMuteButton]);
|
|
33236
|
-
const volumeSlider =
|
|
33308
|
+
const volumeSlider = useMemo42(() => {
|
|
33237
33309
|
return (focused || hover) && !playerMuted && !Internals.isIosSafari() ? (renderVolumeSlider ?? renderDefaultVolumeSlider)({
|
|
33238
33310
|
isVertical: displayVerticalVolumeSlider,
|
|
33239
33311
|
volume: mediaVolume,
|
|
@@ -33321,7 +33393,7 @@ var PlaybackrateOption = ({ rate, onSelect, selectedRate, keyboardSelectedRate }
|
|
|
33321
33393
|
setHovered(false);
|
|
33322
33394
|
}, []);
|
|
33323
33395
|
const isFocused = keyboardSelectedRate === rate;
|
|
33324
|
-
const actualStyle =
|
|
33396
|
+
const actualStyle = useMemo56(() => {
|
|
33325
33397
|
return {
|
|
33326
33398
|
...rateDiv,
|
|
33327
33399
|
backgroundColor: hovered || isFocused ? "#eee" : "transparent"
|
|
@@ -33388,7 +33460,7 @@ var PlaybackPopup = ({ setIsComponentVisible, playbackRates, canvasSize }) => {
|
|
|
33388
33460
|
setPlaybackRate(rate);
|
|
33389
33461
|
setIsComponentVisible(false);
|
|
33390
33462
|
}, [setIsComponentVisible, setPlaybackRate]);
|
|
33391
|
-
const playbackPopup =
|
|
33463
|
+
const playbackPopup = useMemo56(() => {
|
|
33392
33464
|
return {
|
|
33393
33465
|
position: "absolute",
|
|
33394
33466
|
right: 0,
|
|
@@ -35289,7 +35361,7 @@ var Thumbnail = forward2(ThumbnailFn);
|
|
|
35289
35361
|
import {
|
|
35290
35362
|
useCallback as useCallback55,
|
|
35291
35363
|
useEffect as useEffect57,
|
|
35292
|
-
useMemo as
|
|
35364
|
+
useMemo as useMemo69,
|
|
35293
35365
|
useRef as useRef59,
|
|
35294
35366
|
useState as useState56
|
|
35295
35367
|
} from "react";
|
|
@@ -36040,7 +36112,7 @@ var UNDERLAY_RED = curriedTransparentize$1(0.9, RED);
|
|
|
36040
36112
|
var BLUE_TEXT = curriedDarken$1(0.3, "#42e9f5");
|
|
36041
36113
|
|
|
36042
36114
|
// src/components/homepage/layout/use-color-mode.tsx
|
|
36043
|
-
import React58, { useContext as useContext48, useMemo as
|
|
36115
|
+
import React58, { useContext as useContext48, useMemo as useMemo57 } from "react";
|
|
36044
36116
|
import { jsx as jsx60 } from "react/jsx-runtime";
|
|
36045
36117
|
var Context = React58.createContext(undefined);
|
|
36046
36118
|
var ColorModeProvider = ({
|
|
@@ -36048,7 +36120,7 @@ var ColorModeProvider = ({
|
|
|
36048
36120
|
colorMode,
|
|
36049
36121
|
setColorMode
|
|
36050
36122
|
}) => {
|
|
36051
|
-
const value =
|
|
36123
|
+
const value = useMemo57(() => {
|
|
36052
36124
|
return { colorMode, setColorMode };
|
|
36053
36125
|
}, [colorMode, setColorMode]);
|
|
36054
36126
|
return /* @__PURE__ */ jsx60(Context.Provider, {
|
|
@@ -36066,14 +36138,14 @@ function useColorMode() {
|
|
|
36066
36138
|
|
|
36067
36139
|
// ../media/dist/esm/index.mjs
|
|
36068
36140
|
import { useMemo as useMemo312, useState as useState312 } from "react";
|
|
36069
|
-
import { useContext as useContext212, useEffect as useEffect43, useMemo as
|
|
36141
|
+
import { useContext as useContext212, useEffect as useEffect43, useMemo as useMemo59, useRef as useRef50, useState as useState41 } from "react";
|
|
36070
36142
|
import {
|
|
36071
36143
|
AudioBufferSink,
|
|
36072
36144
|
InputDisposedError
|
|
36073
36145
|
} from "mediabunny";
|
|
36074
36146
|
import { ALL_FORMATS, Input as Input2, UrlSource } from "mediabunny";
|
|
36075
36147
|
import { CanvasSink } from "mediabunny";
|
|
36076
|
-
import { useContext as
|
|
36148
|
+
import { useContext as useContext49, useLayoutEffect as useLayoutEffect19 } from "react";
|
|
36077
36149
|
import { jsx as jsx61 } from "react/jsx-runtime";
|
|
36078
36150
|
import { useContext as useContext312, useLayoutEffect as useLayoutEffect24, useMemo as useMemo213, useState as useState210 } from "react";
|
|
36079
36151
|
import React211 from "react";
|
|
@@ -36092,10 +36164,10 @@ import { jsx as jsx316 } from "react/jsx-runtime";
|
|
|
36092
36164
|
import React63, { useMemo as useMemo63, useState as useState63 } from "react";
|
|
36093
36165
|
import {
|
|
36094
36166
|
useCallback as useCallback40,
|
|
36095
|
-
useContext as
|
|
36167
|
+
useContext as useContext410,
|
|
36096
36168
|
useEffect as useEffect212,
|
|
36097
36169
|
useLayoutEffect as useLayoutEffect34,
|
|
36098
|
-
useMemo as
|
|
36170
|
+
useMemo as useMemo410,
|
|
36099
36171
|
useRef as useRef213,
|
|
36100
36172
|
useState as useState43
|
|
36101
36173
|
} from "react";
|
|
@@ -36103,7 +36175,7 @@ import { jsx as jsx412 } from "react/jsx-runtime";
|
|
|
36103
36175
|
import {
|
|
36104
36176
|
useContext as useContext53,
|
|
36105
36177
|
useLayoutEffect as useLayoutEffect43,
|
|
36106
|
-
useMemo as
|
|
36178
|
+
useMemo as useMemo58,
|
|
36107
36179
|
useRef as useRef312,
|
|
36108
36180
|
useState as useState53
|
|
36109
36181
|
} from "react";
|
|
@@ -38250,7 +38322,7 @@ var useCommonEffects = ({
|
|
|
38250
38322
|
logLevel,
|
|
38251
38323
|
label: label3
|
|
38252
38324
|
}) => {
|
|
38253
|
-
const sharedAudioContext =
|
|
38325
|
+
const sharedAudioContext = useContext49(Internals.SharedAudioContext);
|
|
38254
38326
|
useLayoutEffect19(() => {
|
|
38255
38327
|
const mediaPlayer = mediaPlayerRef.current;
|
|
38256
38328
|
if (!mediaPlayer)
|
|
@@ -38403,7 +38475,8 @@ var AudioForPreviewAssertedShowing = ({
|
|
|
38403
38475
|
onError,
|
|
38404
38476
|
credentials,
|
|
38405
38477
|
requestInit,
|
|
38406
|
-
setMediaDurationInSeconds
|
|
38478
|
+
setMediaDurationInSeconds,
|
|
38479
|
+
style: style2
|
|
38407
38480
|
}) => {
|
|
38408
38481
|
const videoConfig = useUnsafeVideoConfig2();
|
|
38409
38482
|
const frame = useCurrentFrame();
|
|
@@ -38633,6 +38706,7 @@ var AudioForPreviewAssertedShowing = ({
|
|
|
38633
38706
|
name,
|
|
38634
38707
|
loop,
|
|
38635
38708
|
showInTimeline,
|
|
38709
|
+
style: style2 ?? undefined,
|
|
38636
38710
|
stack: stack ?? undefined,
|
|
38637
38711
|
toneFrequency,
|
|
38638
38712
|
audioStreamIndex,
|
|
@@ -38663,14 +38737,15 @@ var AudioForPreview2 = ({
|
|
|
38663
38737
|
onError,
|
|
38664
38738
|
credentials,
|
|
38665
38739
|
requestInit,
|
|
38666
|
-
setMediaDurationInSeconds
|
|
38740
|
+
setMediaDurationInSeconds,
|
|
38741
|
+
style: style2
|
|
38667
38742
|
}) => {
|
|
38668
38743
|
const preloadedSrc = usePreload2(src);
|
|
38669
38744
|
const defaultLogLevel = Internals.useLogLevel();
|
|
38670
38745
|
const frame = useCurrentFrame();
|
|
38671
38746
|
const videoConfig = useVideoConfig();
|
|
38672
38747
|
const currentTime = frame / videoConfig.fps;
|
|
38673
|
-
const showShow =
|
|
38748
|
+
const showShow = useMemo59(() => {
|
|
38674
38749
|
return getTimeInSeconds({
|
|
38675
38750
|
unloopedTimeInSeconds: currentTime,
|
|
38676
38751
|
playbackRate,
|
|
@@ -38717,7 +38792,8 @@ var AudioForPreview2 = ({
|
|
|
38717
38792
|
credentials,
|
|
38718
38793
|
requestInit,
|
|
38719
38794
|
fallbackHtml5AudioProps,
|
|
38720
|
-
setMediaDurationInSeconds
|
|
38795
|
+
setMediaDurationInSeconds,
|
|
38796
|
+
style: style2
|
|
38721
38797
|
});
|
|
38722
38798
|
};
|
|
38723
38799
|
var makeAudioCache = () => {
|
|
@@ -40810,6 +40886,7 @@ var audioSchema = {
|
|
|
40810
40886
|
keyframable: false
|
|
40811
40887
|
},
|
|
40812
40888
|
...Internals.baseSchema,
|
|
40889
|
+
...Internals.premountSchema,
|
|
40813
40890
|
volume: {
|
|
40814
40891
|
type: "number",
|
|
40815
40892
|
min: 0,
|
|
@@ -40840,6 +40917,9 @@ var AudioInner = (props) => {
|
|
|
40840
40917
|
durationInFrames,
|
|
40841
40918
|
freeze,
|
|
40842
40919
|
hidden,
|
|
40920
|
+
style: style2,
|
|
40921
|
+
premountFor,
|
|
40922
|
+
postmountFor,
|
|
40843
40923
|
...otherProps
|
|
40844
40924
|
} = props;
|
|
40845
40925
|
const environment = useRemotionEnvironment();
|
|
@@ -40882,6 +40962,24 @@ var AudioInner = (props) => {
|
|
|
40882
40962
|
type: "audio",
|
|
40883
40963
|
data: basicInfo
|
|
40884
40964
|
}), [basicInfo]);
|
|
40965
|
+
const {
|
|
40966
|
+
effectivePostmountFor,
|
|
40967
|
+
effectivePremountFor,
|
|
40968
|
+
freezeFrame,
|
|
40969
|
+
isPremountingOrPostmounting,
|
|
40970
|
+
postmountingActive,
|
|
40971
|
+
premountingActive,
|
|
40972
|
+
premountingStyle
|
|
40973
|
+
} = Internals.usePremounting({
|
|
40974
|
+
from: from ?? 0,
|
|
40975
|
+
durationInFrames: basicInfo.duration,
|
|
40976
|
+
premountFor: premountFor ?? null,
|
|
40977
|
+
postmountFor: postmountFor ?? null,
|
|
40978
|
+
style: style2 ?? null,
|
|
40979
|
+
styleWhilePremounted: null,
|
|
40980
|
+
styleWhilePostmounted: null,
|
|
40981
|
+
hideWhilePremounted: "display-none"
|
|
40982
|
+
});
|
|
40885
40983
|
if (typeof props.src !== "string") {
|
|
40886
40984
|
throw new TypeError(`The \`<Audio>\` tag requires a string for \`src\`, but got ${JSON.stringify(props.src)} instead.`);
|
|
40887
40985
|
}
|
|
@@ -40889,26 +40987,36 @@ var AudioInner = (props) => {
|
|
|
40889
40987
|
if (sequenceDurationInFrames === 0) {
|
|
40890
40988
|
return null;
|
|
40891
40989
|
}
|
|
40892
|
-
return /* @__PURE__ */ jsx316(
|
|
40893
|
-
|
|
40894
|
-
|
|
40895
|
-
|
|
40896
|
-
|
|
40897
|
-
|
|
40898
|
-
|
|
40899
|
-
|
|
40900
|
-
|
|
40901
|
-
|
|
40902
|
-
|
|
40903
|
-
|
|
40904
|
-
|
|
40905
|
-
|
|
40906
|
-
|
|
40907
|
-
|
|
40908
|
-
|
|
40909
|
-
|
|
40910
|
-
|
|
40911
|
-
|
|
40990
|
+
return /* @__PURE__ */ jsx316(Freeze, {
|
|
40991
|
+
frame: freezeFrame,
|
|
40992
|
+
active: isPremountingOrPostmounting,
|
|
40993
|
+
children: /* @__PURE__ */ jsx316(Sequence, {
|
|
40994
|
+
layout: "none",
|
|
40995
|
+
from: from ?? 0,
|
|
40996
|
+
durationInFrames: basicInfo.duration,
|
|
40997
|
+
freeze,
|
|
40998
|
+
_remotionInternalStack: stack,
|
|
40999
|
+
_remotionInternalIsMedia: isMedia,
|
|
41000
|
+
_remotionInternalPremountDisplay: effectivePremountFor || null,
|
|
41001
|
+
_remotionInternalPostmountDisplay: effectivePostmountFor || null,
|
|
41002
|
+
_remotionInternalIsPremounting: premountingActive,
|
|
41003
|
+
_remotionInternalIsPostmounting: postmountingActive,
|
|
41004
|
+
name: name ?? "<Audio>",
|
|
41005
|
+
_remotionInternalDocumentationLink: name === undefined ? "https://www.remotion.dev/docs/media/audio" : undefined,
|
|
41006
|
+
controls,
|
|
41007
|
+
_remotionInternalLoopDisplay: loopDisplay,
|
|
41008
|
+
showInTimeline: showInTimeline ?? true,
|
|
41009
|
+
hidden,
|
|
41010
|
+
children: environment.isRendering ? /* @__PURE__ */ jsx316(AudioForRendering2, {
|
|
41011
|
+
...otherProps,
|
|
41012
|
+
style: premountingStyle ?? undefined
|
|
41013
|
+
}) : /* @__PURE__ */ jsx316(AudioForPreview2, {
|
|
41014
|
+
name,
|
|
41015
|
+
...otherProps,
|
|
41016
|
+
style: premountingStyle,
|
|
41017
|
+
stack: stack ?? null,
|
|
41018
|
+
setMediaDurationInSeconds
|
|
41019
|
+
})
|
|
40912
41020
|
})
|
|
40913
41021
|
});
|
|
40914
41022
|
};
|
|
@@ -41042,7 +41150,7 @@ var VideoForPreviewAssertedShowing = ({
|
|
|
41042
41150
|
const [shouldFallbackToNativeVideo, setShouldFallbackToNativeVideo] = useState43(false);
|
|
41043
41151
|
const [playing] = Timeline2.usePlayingState();
|
|
41044
41152
|
const { playbackRate: globalPlaybackRate } = Internals.usePlaybackRate();
|
|
41045
|
-
const sharedAudioContext =
|
|
41153
|
+
const sharedAudioContext = useContext410(SharedAudioContext22);
|
|
41046
41154
|
const buffer = useBufferState();
|
|
41047
41155
|
const canvasRefCallback = useCallback40((canvas) => {
|
|
41048
41156
|
canvasRef.current = canvas;
|
|
@@ -41070,7 +41178,7 @@ var VideoForPreviewAssertedShowing = ({
|
|
|
41070
41178
|
onErrorRef.current = onError;
|
|
41071
41179
|
const effectChainStateRef = useRef213(effectChainState);
|
|
41072
41180
|
effectChainStateRef.current = effectChainState;
|
|
41073
|
-
const parentSequence =
|
|
41181
|
+
const parentSequence = useContext410(SequenceContext22);
|
|
41074
41182
|
const isPremounting = Boolean(parentSequence?.premounting);
|
|
41075
41183
|
const isPostmounting = Boolean(parentSequence?.postmounting);
|
|
41076
41184
|
const sequenceOffset = (parentSequence?.absoluteFrom ?? 0) / videoConfig.fps;
|
|
@@ -41078,7 +41186,7 @@ var VideoForPreviewAssertedShowing = ({
|
|
|
41078
41186
|
const currentTimeRef = useRef213(currentTime);
|
|
41079
41187
|
currentTimeRef.current = currentTime;
|
|
41080
41188
|
const preloadedSrc = usePreload22(src);
|
|
41081
|
-
const buffering =
|
|
41189
|
+
const buffering = useContext410(Internals.BufferingContextReact);
|
|
41082
41190
|
if (!buffering) {
|
|
41083
41191
|
throw new Error("useMediaPlayback must be used inside a <BufferingContext>");
|
|
41084
41192
|
}
|
|
@@ -41265,7 +41373,7 @@ var VideoForPreviewAssertedShowing = ({
|
|
|
41265
41373
|
setMediaDurationInSeconds
|
|
41266
41374
|
]);
|
|
41267
41375
|
warnAboutObjectFitInStyleOrClassName({ style: style2, className: className2, logLevel });
|
|
41268
|
-
const classNameValue =
|
|
41376
|
+
const classNameValue = useMemo410(() => {
|
|
41269
41377
|
return [Internals.OBJECTFIT_CONTAIN_CLASS_NAME, className2].filter(Internals.truthy).join(" ");
|
|
41270
41378
|
}, [className2]);
|
|
41271
41379
|
useCommonEffects({
|
|
@@ -41312,7 +41420,7 @@ var VideoForPreviewAssertedShowing = ({
|
|
|
41312
41420
|
}
|
|
41313
41421
|
mediaPlayer.redrawVideoEffects().catch(() => {});
|
|
41314
41422
|
}, [effects, mediaPlayerReady, mediaPlayerRef]);
|
|
41315
|
-
const actualStyle =
|
|
41423
|
+
const actualStyle = useMemo410(() => {
|
|
41316
41424
|
return {
|
|
41317
41425
|
...style2,
|
|
41318
41426
|
objectFit: objectFitProp
|
|
@@ -41352,7 +41460,7 @@ var VideoForPreview2 = (props) => {
|
|
|
41352
41460
|
const frame = useCurrentFrame();
|
|
41353
41461
|
const videoConfig = useVideoConfig();
|
|
41354
41462
|
const currentTime = frame / videoConfig.fps;
|
|
41355
|
-
const showShow =
|
|
41463
|
+
const showShow = useMemo410(() => {
|
|
41356
41464
|
return getTimeInSeconds({
|
|
41357
41465
|
unloopedTimeInSeconds: currentTime,
|
|
41358
41466
|
playbackRate: props.playbackRate,
|
|
@@ -41417,7 +41525,7 @@ var VideoForRendering2 = ({
|
|
|
41417
41525
|
const { registerRenderAsset, unregisterRenderAsset } = useContext53(Internals.RenderAssetManager);
|
|
41418
41526
|
const startsAt = Internals.useMediaStartsAt();
|
|
41419
41527
|
const sequenceContext = useContext53(Internals.SequenceContext);
|
|
41420
|
-
const id =
|
|
41528
|
+
const id = useMemo58(() => `media-video-${random(src)}-${sequenceContext?.cumulatedFrom}-${sequenceContext?.relativeFrom}-${sequenceContext?.durationInFrames}`, [
|
|
41421
41529
|
src,
|
|
41422
41530
|
sequenceContext?.cumulatedFrom,
|
|
41423
41531
|
sequenceContext?.relativeFrom,
|
|
@@ -41636,10 +41744,10 @@ var VideoForRendering2 = ({
|
|
|
41636
41744
|
initialRequestInit
|
|
41637
41745
|
]);
|
|
41638
41746
|
warnAboutObjectFitInStyleOrClassName({ style: style2, className: className2, logLevel });
|
|
41639
|
-
const classNameValue =
|
|
41747
|
+
const classNameValue = useMemo58(() => {
|
|
41640
41748
|
return [Internals.OBJECTFIT_CONTAIN_CLASS_NAME, className2].filter(Internals.truthy).join(" ");
|
|
41641
41749
|
}, [className2]);
|
|
41642
|
-
const styleWithObjectFit =
|
|
41750
|
+
const styleWithObjectFit = useMemo58(() => {
|
|
41643
41751
|
return {
|
|
41644
41752
|
...style2,
|
|
41645
41753
|
objectFit: objectFitProp
|
|
@@ -41718,6 +41826,8 @@ var videoSchema = {
|
|
|
41718
41826
|
keyframable: false
|
|
41719
41827
|
},
|
|
41720
41828
|
...Internals.baseSchema,
|
|
41829
|
+
...Internals.premountSchema,
|
|
41830
|
+
...Internals.premountStyleSchema,
|
|
41721
41831
|
volume: {
|
|
41722
41832
|
type: "number",
|
|
41723
41833
|
min: 0,
|
|
@@ -41888,6 +41998,10 @@ var VideoInner = ({
|
|
|
41888
41998
|
from,
|
|
41889
41999
|
freeze,
|
|
41890
42000
|
hidden,
|
|
42001
|
+
premountFor,
|
|
42002
|
+
postmountFor,
|
|
42003
|
+
styleWhilePremounted,
|
|
42004
|
+
styleWhilePostmounted,
|
|
41891
42005
|
...props
|
|
41892
42006
|
}) => {
|
|
41893
42007
|
const fallbackLogLevel = Internals.useLogLevel();
|
|
@@ -41943,57 +42057,83 @@ var VideoInner = ({
|
|
|
41943
42057
|
});
|
|
41944
42058
|
const memoizedEffectDefinitions = Internals.useMemoizedEffectDefinitions(effects ?? []);
|
|
41945
42059
|
const refForOutline = React63.useRef(null);
|
|
42060
|
+
const {
|
|
42061
|
+
effectivePostmountFor,
|
|
42062
|
+
effectivePremountFor,
|
|
42063
|
+
freezeFrame,
|
|
42064
|
+
isPremountingOrPostmounting,
|
|
42065
|
+
postmountingActive,
|
|
42066
|
+
premountingActive,
|
|
42067
|
+
premountingStyle
|
|
42068
|
+
} = Internals.usePremounting({
|
|
42069
|
+
from: from ?? 0,
|
|
42070
|
+
durationInFrames: videoSequenceDuration ?? Infinity,
|
|
42071
|
+
premountFor: premountFor ?? null,
|
|
42072
|
+
postmountFor: postmountFor ?? null,
|
|
42073
|
+
style: style2 ?? null,
|
|
42074
|
+
styleWhilePremounted: styleWhilePremounted ?? null,
|
|
42075
|
+
styleWhilePostmounted: styleWhilePostmounted ?? null,
|
|
42076
|
+
hideWhilePremounted: "display-none"
|
|
42077
|
+
});
|
|
41946
42078
|
if (sequenceDurationInFrames === 0) {
|
|
41947
42079
|
return null;
|
|
41948
42080
|
}
|
|
41949
|
-
return /* @__PURE__ */ jsx65(
|
|
41950
|
-
|
|
41951
|
-
|
|
41952
|
-
|
|
41953
|
-
|
|
41954
|
-
|
|
41955
|
-
|
|
41956
|
-
|
|
41957
|
-
|
|
41958
|
-
|
|
41959
|
-
|
|
41960
|
-
|
|
41961
|
-
|
|
41962
|
-
|
|
41963
|
-
|
|
41964
|
-
|
|
41965
|
-
...props,
|
|
41966
|
-
audioStreamIndex: audioStreamIndex ?? 0,
|
|
41967
|
-
className: className2,
|
|
41968
|
-
delayRenderRetries: delayRenderRetries ?? null,
|
|
41969
|
-
delayRenderTimeoutInMilliseconds: delayRenderTimeoutInMilliseconds ?? null,
|
|
41970
|
-
disallowFallbackToOffthreadVideo: disallowFallbackToOffthreadVideo ?? false,
|
|
41971
|
-
fallbackOffthreadVideoProps: fallbackOffthreadVideoProps ?? {},
|
|
41972
|
-
logLevel: logLevel ?? fallbackLogLevel,
|
|
41973
|
-
loop: loop ?? false,
|
|
41974
|
-
loopVolumeCurveBehavior: loopVolumeCurveBehavior ?? "repeat",
|
|
41975
|
-
muted: muted ?? false,
|
|
41976
|
-
onVideoFrame,
|
|
41977
|
-
playbackRate: playbackRate ?? 1,
|
|
41978
|
-
showInTimeline: showInTimeline ?? true,
|
|
41979
|
-
src,
|
|
41980
|
-
style: style2 ?? {},
|
|
41981
|
-
trimAfter,
|
|
41982
|
-
trimBefore,
|
|
41983
|
-
volume: volume ?? 1,
|
|
41984
|
-
toneFrequency: toneFrequency ?? 1,
|
|
41985
|
-
stack,
|
|
41986
|
-
debugOverlay: debugOverlay ?? false,
|
|
41987
|
-
headless: headless ?? false,
|
|
41988
|
-
onError,
|
|
41989
|
-
credentials,
|
|
41990
|
-
requestInit,
|
|
42081
|
+
return /* @__PURE__ */ jsx65(Freeze, {
|
|
42082
|
+
frame: freezeFrame,
|
|
42083
|
+
active: isPremountingOrPostmounting,
|
|
42084
|
+
children: /* @__PURE__ */ jsx65(Sequence, {
|
|
42085
|
+
layout: "none",
|
|
42086
|
+
from: from ?? 0,
|
|
42087
|
+
durationInFrames: videoSequenceDuration,
|
|
42088
|
+
freeze,
|
|
42089
|
+
_remotionInternalStack: stack,
|
|
42090
|
+
_remotionInternalIsMedia: isMedia,
|
|
42091
|
+
_remotionInternalPremountDisplay: effectivePremountFor || null,
|
|
42092
|
+
_remotionInternalPostmountDisplay: effectivePostmountFor || null,
|
|
42093
|
+
_remotionInternalIsPremounting: premountingActive,
|
|
42094
|
+
_remotionInternalIsPostmounting: postmountingActive,
|
|
42095
|
+
name: name ?? "<Video>",
|
|
42096
|
+
_remotionInternalDocumentationLink: name === undefined ? "https://www.remotion.dev/docs/media/video" : undefined,
|
|
41991
42097
|
controls,
|
|
41992
|
-
|
|
41993
|
-
|
|
41994
|
-
|
|
41995
|
-
|
|
41996
|
-
|
|
42098
|
+
_remotionInternalLoopDisplay: loopDisplay,
|
|
42099
|
+
_remotionInternalEffects: memoizedEffectDefinitions,
|
|
42100
|
+
outlineRef: refForOutline,
|
|
42101
|
+
showInTimeline: showInTimeline ?? true,
|
|
42102
|
+
hidden,
|
|
42103
|
+
children: /* @__PURE__ */ jsx65(InnerVideo, {
|
|
42104
|
+
...props,
|
|
42105
|
+
audioStreamIndex: audioStreamIndex ?? 0,
|
|
42106
|
+
className: className2,
|
|
42107
|
+
delayRenderRetries: delayRenderRetries ?? null,
|
|
42108
|
+
delayRenderTimeoutInMilliseconds: delayRenderTimeoutInMilliseconds ?? null,
|
|
42109
|
+
disallowFallbackToOffthreadVideo: disallowFallbackToOffthreadVideo ?? false,
|
|
42110
|
+
fallbackOffthreadVideoProps: fallbackOffthreadVideoProps ?? {},
|
|
42111
|
+
logLevel: logLevel ?? fallbackLogLevel,
|
|
42112
|
+
loop: loop ?? false,
|
|
42113
|
+
loopVolumeCurveBehavior: loopVolumeCurveBehavior ?? "repeat",
|
|
42114
|
+
muted: muted ?? false,
|
|
42115
|
+
onVideoFrame,
|
|
42116
|
+
playbackRate: playbackRate ?? 1,
|
|
42117
|
+
showInTimeline: showInTimeline ?? true,
|
|
42118
|
+
src,
|
|
42119
|
+
style: premountingStyle ?? {},
|
|
42120
|
+
trimAfter,
|
|
42121
|
+
trimBefore,
|
|
42122
|
+
volume: volume ?? 1,
|
|
42123
|
+
toneFrequency: toneFrequency ?? 1,
|
|
42124
|
+
stack,
|
|
42125
|
+
debugOverlay: debugOverlay ?? false,
|
|
42126
|
+
headless: headless ?? false,
|
|
42127
|
+
onError,
|
|
42128
|
+
credentials,
|
|
42129
|
+
requestInit,
|
|
42130
|
+
controls,
|
|
42131
|
+
objectFit: objectFit ?? "contain",
|
|
42132
|
+
_experimentalInitiallyDrawCachedFrame: _experimentalInitiallyDrawCachedFrame ?? false,
|
|
42133
|
+
effects: memoizedEffects,
|
|
42134
|
+
setMediaDurationInSeconds,
|
|
42135
|
+
refForOutline
|
|
42136
|
+
})
|
|
41997
42137
|
})
|
|
41998
42138
|
});
|
|
41999
42139
|
};
|
|
@@ -42006,7 +42146,7 @@ var Video = Interactive.withSchema({
|
|
|
42006
42146
|
});
|
|
42007
42147
|
|
|
42008
42148
|
// src/components/homepage/Demo/Comp.tsx
|
|
42009
|
-
import { useCallback as useCallback47, useEffect as useEffect49, useMemo as
|
|
42149
|
+
import { useCallback as useCallback47, useEffect as useEffect49, useMemo as useMemo64, useState as useState48 } from "react";
|
|
42010
42150
|
|
|
42011
42151
|
// src/components/homepage/Demo/Cards.tsx
|
|
42012
42152
|
import {
|
|
@@ -42558,7 +42698,7 @@ var Lottie = ({
|
|
|
42558
42698
|
};
|
|
42559
42699
|
|
|
42560
42700
|
// src/components/homepage/Demo/DisplayedEmoji.tsx
|
|
42561
|
-
import { useEffect as useEffect46, useMemo as
|
|
42701
|
+
import { useEffect as useEffect46, useMemo as useMemo60, useState as useState46 } from "react";
|
|
42562
42702
|
import { jsx as jsx71 } from "react/jsx-runtime";
|
|
42563
42703
|
var DisplayedEmoji = ({ emoji }) => {
|
|
42564
42704
|
const [data, setData] = useState46(null);
|
|
@@ -42566,7 +42706,7 @@ var DisplayedEmoji = ({ emoji }) => {
|
|
|
42566
42706
|
const [browser, setBrowser] = useState46(typeof document !== "undefined");
|
|
42567
42707
|
const { delayRender: delayRender2, continueRender, cancelRender: cancelRender2 } = useDelayRender();
|
|
42568
42708
|
const { isRendering } = useRemotionEnvironment();
|
|
42569
|
-
const src =
|
|
42709
|
+
const src = useMemo60(() => {
|
|
42570
42710
|
if (emoji === "melting") {
|
|
42571
42711
|
return "https://fonts.gstatic.com/s/e/notoemoji/latest/1fae0/lottie.json";
|
|
42572
42712
|
}
|
|
@@ -42997,7 +43137,7 @@ var Temperature = ({ theme, city, temperatureInCelsius }) => {
|
|
|
42997
43137
|
};
|
|
42998
43138
|
|
|
42999
43139
|
// src/components/homepage/Demo/TrendingRepos.tsx
|
|
43000
|
-
import { useMemo as
|
|
43140
|
+
import { useMemo as useMemo61 } from "react";
|
|
43001
43141
|
import { jsx as jsx81, jsxs as jsxs28 } from "react/jsx-runtime";
|
|
43002
43142
|
var TrendingRepoItem = ({ repo, theme, number }) => {
|
|
43003
43143
|
const frame = useCurrentFrame();
|
|
@@ -43010,7 +43150,7 @@ var TrendingRepoItem = ({ repo, theme, number }) => {
|
|
|
43010
43150
|
},
|
|
43011
43151
|
delay: number * 10 + 20
|
|
43012
43152
|
});
|
|
43013
|
-
const item =
|
|
43153
|
+
const item = useMemo61(() => {
|
|
43014
43154
|
return {
|
|
43015
43155
|
lineHeight: 1.1,
|
|
43016
43156
|
fontFamily: "GTPlanar",
|
|
@@ -43217,7 +43357,7 @@ var HomepageVideoComp = ({
|
|
|
43217
43357
|
setRerenders(rerenders + 1);
|
|
43218
43358
|
updateCardOrder(newIndices);
|
|
43219
43359
|
}, [rerenders, updateCardOrder]);
|
|
43220
|
-
const emoji =
|
|
43360
|
+
const emoji = useMemo64(() => {
|
|
43221
43361
|
if ((emojiIndex + 1e4 * 3) % 3 === 1) {
|
|
43222
43362
|
return "melting";
|
|
43223
43363
|
}
|
|
@@ -43226,7 +43366,7 @@ var HomepageVideoComp = ({
|
|
|
43226
43366
|
}
|
|
43227
43367
|
return "partying-face";
|
|
43228
43368
|
}, [emojiIndex]);
|
|
43229
|
-
const audioSrc =
|
|
43369
|
+
const audioSrc = useMemo64(() => {
|
|
43230
43370
|
if (emoji === "fire") {
|
|
43231
43371
|
return fireAudio;
|
|
43232
43372
|
}
|
|
@@ -43311,7 +43451,7 @@ import {
|
|
|
43311
43451
|
import { BufferTarget, StreamTarget } from "mediabunny";
|
|
43312
43452
|
|
|
43313
43453
|
// ../core/dist/esm/version.mjs
|
|
43314
|
-
var VERSION2 = "4.0.
|
|
43454
|
+
var VERSION2 = "4.0.495";
|
|
43315
43455
|
|
|
43316
43456
|
// ../web-renderer/dist/esm/index.mjs
|
|
43317
43457
|
import { AudioSample, VideoSample } from "mediabunny";
|
|
@@ -48535,7 +48675,7 @@ var Progress = ({ progress }) => {
|
|
|
48535
48675
|
};
|
|
48536
48676
|
|
|
48537
48677
|
// src/components/homepage/Demo/Spinner.tsx
|
|
48538
|
-
import { useMemo as
|
|
48678
|
+
import { useMemo as useMemo66 } from "react";
|
|
48539
48679
|
import { jsx as jsx97, jsxs as jsxs34, Fragment as Fragment16 } from "react/jsx-runtime";
|
|
48540
48680
|
var viewBox2 = 100;
|
|
48541
48681
|
var lines2 = 8;
|
|
@@ -48543,7 +48683,7 @@ var className2 = "__remotion_spinner_line";
|
|
|
48543
48683
|
var remotionSpinnerAnimation = "__remotion_spinner_animation";
|
|
48544
48684
|
var translated3 = "M 44 0 L 50 0 a 6 6 0 0 1 6 6 L 56 26 a 6 6 0 0 1 -6 6 L 50 32 a 6 6 0 0 1 -6 -6 L 44 6 a 6 6 0 0 1 6 -6 Z";
|
|
48545
48685
|
var Spinner2 = ({ size: size4, duration }) => {
|
|
48546
|
-
const style2 =
|
|
48686
|
+
const style2 = useMemo66(() => {
|
|
48547
48687
|
return {
|
|
48548
48688
|
width: size4,
|
|
48549
48689
|
height: size4
|
|
@@ -48805,13 +48945,13 @@ var DragAndDropNudge = () => {
|
|
|
48805
48945
|
};
|
|
48806
48946
|
|
|
48807
48947
|
// src/components/homepage/Demo/PlayerSeekBar.tsx
|
|
48808
|
-
import { useCallback as useCallback50, useEffect as useEffect51, useMemo as
|
|
48948
|
+
import { useCallback as useCallback50, useEffect as useEffect51, useMemo as useMemo68, useRef as useRef57, useState as useState51 } from "react";
|
|
48809
48949
|
|
|
48810
48950
|
// src/components/homepage/layout/use-el-size.ts
|
|
48811
|
-
import { useCallback as useCallback49, useEffect as useEffect50, useMemo as
|
|
48951
|
+
import { useCallback as useCallback49, useEffect as useEffect50, useMemo as useMemo67, useState as useState50 } from "react";
|
|
48812
48952
|
var useElementSize2 = (ref) => {
|
|
48813
48953
|
const [size4, setSize] = useState50(null);
|
|
48814
|
-
const observer =
|
|
48954
|
+
const observer = useMemo67(() => {
|
|
48815
48955
|
if (typeof ResizeObserver === "undefined") {
|
|
48816
48956
|
return;
|
|
48817
48957
|
}
|
|
@@ -49025,7 +49165,7 @@ var PlayerSeekBar2 = ({
|
|
|
49025
49165
|
body.removeEventListener("pointerup", onPointerUp);
|
|
49026
49166
|
};
|
|
49027
49167
|
}, [dragging.dragging, onPointerMove, onPointerUp]);
|
|
49028
|
-
const knobStyle =
|
|
49168
|
+
const knobStyle = useMemo68(() => {
|
|
49029
49169
|
return {
|
|
49030
49170
|
height: KNOB_SIZE3,
|
|
49031
49171
|
width: KNOB_SIZE3,
|
|
@@ -49039,7 +49179,7 @@ var PlayerSeekBar2 = ({
|
|
|
49039
49179
|
transition: "opacity 0.s ease"
|
|
49040
49180
|
};
|
|
49041
49181
|
}, [barHovered, durationInFrames, frame, width2]);
|
|
49042
|
-
const fillStyle =
|
|
49182
|
+
const fillStyle = useMemo68(() => {
|
|
49043
49183
|
return {
|
|
49044
49184
|
height: BAR_HEIGHT3,
|
|
49045
49185
|
backgroundColor: "var(--ifm-font-color-base)",
|
|
@@ -49048,7 +49188,7 @@ var PlayerSeekBar2 = ({
|
|
|
49048
49188
|
borderRadius: BAR_HEIGHT3 / 2
|
|
49049
49189
|
};
|
|
49050
49190
|
}, [durationInFrames, frame, inFrame]);
|
|
49051
|
-
const active =
|
|
49191
|
+
const active = useMemo68(() => {
|
|
49052
49192
|
return {
|
|
49053
49193
|
height: BAR_HEIGHT3,
|
|
49054
49194
|
backgroundColor: "var(--ifm-font-color-base)",
|
|
@@ -49462,7 +49602,7 @@ var Demo = () => {
|
|
|
49462
49602
|
const updateCardOrder = useCallback55((newCardOrder) => {
|
|
49463
49603
|
setCardOrder(newCardOrder);
|
|
49464
49604
|
}, []);
|
|
49465
|
-
const props =
|
|
49605
|
+
const props = useMemo69(() => {
|
|
49466
49606
|
return {
|
|
49467
49607
|
theme: colorMode,
|
|
49468
49608
|
onToggle: () => {
|