@remotion/promo-pages 4.0.494 → 4.0.496

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 CHANGED
@@ -911,7 +911,7 @@ var experts = [
911
911
  }
912
912
  ];
913
913
  // src/components/experts/ExpertsPage.tsx
914
- import { useMemo as useMemo40 } from "react";
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 useContext17,
948
+ useContext as useContext18,
949
949
  useEffect as useEffect3,
950
- useMemo as useMemo14,
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 createContext15 } from "react";
971
+ import React13, { createContext as createContext14 } from "react";
973
972
  import { jsx as jsx11 } from "react/jsx-runtime";
974
- import React14, { forwardRef as forwardRef2, useContext as useContext16, useMemo as useMemo13, useState as useState4 } from "react";
975
- import { useContext as useContext15, useRef as useRef5 } from "react";
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 useMemo16, useRef as useRef8 } from "react";
987
- import { useEffect as useEffect4, useMemo as useMemo15, useRef as useRef7 } from "react";
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 useContext18, useLayoutEffect as useLayoutEffect4, useState as useState8 } from "react";
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 useMemo17,
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 useContext30 } from "react";
1002
- import React17, { createContext as createContext18, useMemo as useMemo18 } from "react";
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 useContext19 } from "react";
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 useMemo19, useReducer } from "react";
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 useContext28,
1013
+ useContext as useContext29,
1013
1014
  useEffect as useEffect14,
1014
1015
  useImperativeHandle as useImperativeHandle4,
1015
- useMemo as useMemo27,
1016
+ useMemo as useMemo28,
1016
1017
  useRef as useRef19,
1017
1018
  useState as useState14
1018
1019
  } from "react";
1019
- import { useContext as useContext21, useLayoutEffect as useLayoutEffect5, useRef as useRef14 } from "react";
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 useContext20,
1025
+ useContext as useContext21,
1025
1026
  useEffect as useEffect7,
1026
- useMemo as useMemo21,
1027
+ useMemo as useMemo22,
1027
1028
  useRef as useRef12,
1028
1029
  useState as useState10
1029
1030
  } from "react";
1030
- import { useMemo as useMemo20, useRef as useRef11 } from "react";
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 useContext23, useEffect as useEffect8, useMemo as useMemo22, useState as useState11 } from "react";
1034
- import { useContext as useContext22 } from "react";
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 useContext26,
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 useMemo25, useRef as useRef16 } from "react";
1043
- import { useContext as useContext25, useMemo as useMemo24 } from "react";
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 useContext24,
1047
+ useContext as useContext25,
1047
1048
  useEffect as useEffect9,
1048
1049
  useLayoutEffect as useLayoutEffect6,
1049
- useMemo as useMemo23,
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 useContext27, useMemo as useMemo26 } from "react";
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 useContext29,
1063
+ useContext as useContext30,
1063
1064
  useEffect as useEffect15,
1064
1065
  useImperativeHandle as useImperativeHandle5,
1065
1066
  useLayoutEffect as useLayoutEffect8,
1066
- useMemo as useMemo28,
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 useMemo29,
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 useContext31,
1086
+ useContext as useContext32,
1086
1087
  useLayoutEffect as useLayoutEffect9,
1087
- useMemo as useMemo30,
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 useContext32,
1095
+ useContext as useContext33,
1095
1096
  useImperativeHandle as useImperativeHandle7,
1096
1097
  useLayoutEffect as useLayoutEffect10,
1097
- useMemo as useMemo31,
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 useContext33,
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 useMemo32,
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 useMemo34 } from "react";
1126
- import { createContext as createContext24, useContext as useContext34, useMemo as useMemo33 } from "react";
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 useContext35 } from "react";
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 useContext36,
1136
+ useContext as useContext37,
1136
1137
  useEffect as useEffect17,
1137
1138
  useLayoutEffect as useLayoutEffect12,
1138
- useMemo as useMemo35,
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 useContext37,
1146
+ useContext as useContext38,
1146
1147
  useEffect as useEffect19,
1147
1148
  useImperativeHandle as useImperativeHandle9,
1148
- useMemo as useMemo36,
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 useMemo37 } from "react";
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 useMemo38
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 useContext39 } from "react";
1165
+ import { forwardRef as forwardRef16, useCallback as useCallback25, useContext as useContext40 } from "react";
1165
1166
  import {
1166
1167
  forwardRef as forwardRef15,
1167
- useContext as useContext38,
1168
+ useContext as useContext39,
1168
1169
  useEffect as useEffect20,
1169
1170
  useImperativeHandle as useImperativeHandle10,
1170
1171
  useLayoutEffect as useLayoutEffect13,
1171
- useMemo as useMemo39,
1172
+ useMemo as useMemo40,
1172
1173
  useRef as useRef28
1173
1174
  } from "react";
1174
1175
  import { jsx as jsx38 } from "react/jsx-runtime";
@@ -2028,17 +2029,6 @@ var delayRenderInternal = ({
2028
2029
  scope.remotion_renderReady = false;
2029
2030
  return handle;
2030
2031
  };
2031
- var delayRender = (label2, options) => {
2032
- if (typeof window === "undefined") {
2033
- return Math.random();
2034
- }
2035
- return delayRenderInternal({
2036
- scope: window,
2037
- environment: getRemotionEnvironment(),
2038
- label: label2 ?? null,
2039
- options: options ?? {}
2040
- });
2041
- };
2042
2032
  var continueRenderInternal = ({
2043
2033
  scope,
2044
2034
  handle,
@@ -2359,7 +2349,7 @@ var getSingleChildComponent = (children) => {
2359
2349
  }
2360
2350
  return child.type;
2361
2351
  };
2362
- var VERSION = "4.0.494";
2352
+ var VERSION = "4.0.496";
2363
2353
  var checkMultipleRemotionVersions = () => {
2364
2354
  if (typeof globalThis === "undefined") {
2365
2355
  return;
@@ -2852,15 +2842,19 @@ var premountSchema = {
2852
2842
  description: "Premount For",
2853
2843
  min: 0,
2854
2844
  step: 1,
2855
- hiddenFromList: false
2845
+ hiddenFromList: false,
2846
+ keyframable: false
2856
2847
  },
2857
2848
  postmountFor: {
2858
2849
  type: "number",
2859
2850
  default: 0,
2860
2851
  min: 0,
2861
2852
  step: 1,
2862
- hiddenFromList: true
2863
- },
2853
+ hiddenFromList: true,
2854
+ keyframable: false
2855
+ }
2856
+ };
2857
+ var premountStyleSchema = {
2864
2858
  styleWhilePremounted: {
2865
2859
  type: "hidden"
2866
2860
  },
@@ -2868,10 +2862,13 @@ var premountSchema = {
2868
2862
  type: "hidden"
2869
2863
  }
2870
2864
  };
2871
- var sequencePremountSchema = premountSchema;
2865
+ var sequencePremountSchema = {
2866
+ ...premountSchema,
2867
+ ...premountStyleSchema
2868
+ };
2872
2869
  var sequenceStyleSchema = {
2873
2870
  ...transformSchema,
2874
- ...premountSchema
2871
+ ...sequencePremountSchema
2875
2872
  };
2876
2873
  var hiddenField = {
2877
2874
  type: "boolean",
@@ -2956,9 +2953,6 @@ var sequenceSchemaDefaultLayoutNone = {
2956
2953
  default: "none"
2957
2954
  }
2958
2955
  };
2959
- var PremountContext = createContext14({
2960
- premountFramesRemaining: 0
2961
- });
2962
2956
  var SequenceManager = React12.createContext({
2963
2957
  registerSequence: () => {
2964
2958
  throw new Error("SequenceManagerContext not initialized");
@@ -3138,7 +3132,7 @@ var SequenceManagerProvider = ({ children }) => {
3138
3132
  })
3139
3133
  });
3140
3134
  };
3141
- var IsInsideSeriesContext = createContext15(false);
3135
+ var IsInsideSeriesContext = createContext14(false);
3142
3136
  var IsInsideSeriesContainer = ({ children }) => {
3143
3137
  return /* @__PURE__ */ jsx11(IsInsideSeriesContext.Provider, {
3144
3138
  value: true,
@@ -3157,7 +3151,61 @@ var useRequireToBeInsideSeries = () => {
3157
3151
  throw new Error("This component must be inside a <Series /> component.");
3158
3152
  }
3159
3153
  };
3154
+ var PremountContext = createContext15({
3155
+ premountFramesRemaining: 0
3156
+ });
3160
3157
  var ENABLE_V5_BREAKING_CHANGES = false;
3158
+ var usePremounting = ({
3159
+ from,
3160
+ durationInFrames,
3161
+ premountFor,
3162
+ postmountFor,
3163
+ style,
3164
+ styleWhilePremounted,
3165
+ styleWhilePostmounted,
3166
+ hideWhilePremounted
3167
+ }) => {
3168
+ const parentPremountContext = useContext15(PremountContext);
3169
+ const frame = useCurrentFrame() - parentPremountContext.premountFramesRemaining;
3170
+ const environment = useRemotionEnvironment();
3171
+ const { fps } = useVideoConfig();
3172
+ const effectivePremountFor = ENABLE_V5_BREAKING_CHANGES ? premountFor ?? fps : premountFor ?? 0;
3173
+ const effectivePostmountFor = postmountFor ?? 0;
3174
+ const endThreshold = Math.ceil(from + durationInFrames - 1);
3175
+ const premountingActive = !environment.isRendering && frame < from && frame >= from - effectivePremountFor;
3176
+ const postmountingActive = !environment.isRendering && frame > endThreshold && frame <= endThreshold + effectivePostmountFor;
3177
+ const isPremountingOrPostmounting = premountingActive || postmountingActive;
3178
+ const freezeFrame = premountingActive ? from : postmountingActive ? from + durationInFrames - 1 : 0;
3179
+ const premountingStyle = useMemo13(() => {
3180
+ if (!isPremountingOrPostmounting) {
3181
+ return style;
3182
+ }
3183
+ return {
3184
+ ...style,
3185
+ ...hideWhilePremounted === "opacity" ? { opacity: 0 } : { display: "none" },
3186
+ pointerEvents: "none",
3187
+ ...premountingActive ? styleWhilePremounted : {},
3188
+ ...postmountingActive ? styleWhilePostmounted : {}
3189
+ };
3190
+ }, [
3191
+ isPremountingOrPostmounting,
3192
+ hideWhilePremounted,
3193
+ postmountingActive,
3194
+ premountingActive,
3195
+ style,
3196
+ styleWhilePostmounted,
3197
+ styleWhilePremounted
3198
+ ]);
3199
+ return {
3200
+ effectivePremountFor,
3201
+ effectivePostmountFor,
3202
+ premountingActive,
3203
+ postmountingActive,
3204
+ isPremountingOrPostmounting,
3205
+ freezeFrame,
3206
+ premountingStyle
3207
+ };
3208
+ };
3161
3209
  var deleteNestedKey = (obj, keysToRemove) => {
3162
3210
  for (const key of keysToRemove) {
3163
3211
  const parts = key.split(".");
@@ -4981,10 +5029,10 @@ var useMemoizedEffects = ({
4981
5029
  overrideId
4982
5030
  }) => {
4983
5031
  const previousRef = useRef5(null);
4984
- const { propStatuses } = useContext15(VisualModePropStatusesContext);
4985
- const { getEffectDragOverrides } = useContext15(VisualModeDragOverridesContext);
5032
+ const { propStatuses } = useContext16(VisualModePropStatusesContext);
5033
+ const { getEffectDragOverrides } = useContext16(VisualModeDragOverridesContext);
4986
5034
  const frame = useCurrentFrame();
4987
- const { overrideIdToNodePathMappings } = useContext15(OverrideIdsToNodePathsGettersContext);
5035
+ const { overrideIdToNodePathMappings } = useContext16(OverrideIdsToNodePathsGettersContext);
4988
5036
  const previous = previousRef.current;
4989
5037
  const nodePath = overrideId ? overrideIdToNodePathMappings[overrideId] ?? null : null;
4990
5038
  const resolved = effects.map((descriptor, index) => {
@@ -5328,9 +5376,9 @@ var withInteractivitySchema = ({
5328
5376
  ref
5329
5377
  });
5330
5378
  }
5331
- const { propStatuses } = useContext16(VisualModePropStatusesContext);
5332
- const { getDragOverrides } = useContext16(VisualModeDragOverridesContext);
5333
- const nodePathMapping = useContext16(OverrideIdsToNodePathsGettersContext);
5379
+ const { propStatuses } = useContext17(VisualModePropStatusesContext);
5380
+ const { getDragOverrides } = useContext17(VisualModeDragOverridesContext);
5381
+ const nodePathMapping = useContext17(OverrideIdsToNodePathsGettersContext);
5334
5382
  const frame = useCurrentFrame();
5335
5383
  if (props.controls) {
5336
5384
  return React14.createElement(Component, {
@@ -5357,8 +5405,8 @@ var withInteractivitySchema = ({
5357
5405
  key,
5358
5406
  props
5359
5407
  }));
5360
- const currentRuntimeValueDotNotation = useMemo13(() => readValuesFromProps(props, flatKeys, flatSchema), runtimeValues);
5361
- const controls = useMemo13(() => {
5408
+ const currentRuntimeValueDotNotation = useMemo14(() => readValuesFromProps(props, flatKeys, flatSchema), runtimeValues);
5409
+ const controls = useMemo14(() => {
5362
5410
  return {
5363
5411
  schema: schemaWithSequenceName,
5364
5412
  currentRuntimeValueDotNotation,
@@ -5368,7 +5416,7 @@ var withInteractivitySchema = ({
5368
5416
  componentName
5369
5417
  };
5370
5418
  }, [currentRuntimeValueDotNotation, overrideId]);
5371
- const { merged: valuesDotNotation, propsToDelete } = useMemo13(() => {
5419
+ const { merged: valuesDotNotation, propsToDelete } = useMemo14(() => {
5372
5420
  return computeEffectiveSchemaValuesDotNotation({
5373
5421
  schema: schemaWithSequenceName,
5374
5422
  currentValue: currentRuntimeValueDotNotation,
@@ -5426,7 +5474,7 @@ var RegularSequenceRefForwardingFunction = ({
5426
5474
  }, ref) => {
5427
5475
  const { layout = "absolute-fill" } = other;
5428
5476
  const [id] = useState5(() => String(Math.random()));
5429
- const parentSequence = useContext17(SequenceContext);
5477
+ const parentSequence = useContext18(SequenceContext);
5430
5478
  const { rootId } = useTimelineContext();
5431
5479
  const cumulatedFrom = parentSequence ? parentSequence.cumulatedFrom + parentSequence.relativeFrom : 0;
5432
5480
  const nonce = useNonce();
@@ -5477,13 +5525,13 @@ var RegularSequenceRefForwardingFunction = ({
5477
5525
  const absoluteFrom = (parentSequence?.absoluteFrom ?? 0) + effectiveRelativeFrom;
5478
5526
  const parentSequenceDuration = parentSequence ? Math.min(parentSequence.durationInFrames - effectiveRelativeFrom, durationInFrames) : durationInFrames;
5479
5527
  const actualDurationInFrames = Math.max(0, Math.min(videoConfig.durationInFrames - from, parentSequenceDuration));
5480
- const { registerSequence, unregisterSequence } = useContext17(SequenceManager);
5528
+ const { registerSequence, unregisterSequence } = useContext18(SequenceManager);
5481
5529
  const wrapperRefForOutline = useRef6(null);
5482
5530
  const refForOutline = other.layout === "none" ? passedRefForOutline ?? null : passedRefForOutline ?? wrapperRefForOutline;
5483
- const premounting = useMemo14(() => {
5531
+ const premounting = useMemo15(() => {
5484
5532
  return parentSequence?.premounting || Boolean(other._remotionInternalIsPremounting);
5485
5533
  }, [other._remotionInternalIsPremounting, parentSequence?.premounting]);
5486
- const postmounting = useMemo14(() => {
5534
+ const postmounting = useMemo15(() => {
5487
5535
  return parentSequence?.postmounting || Boolean(other._remotionInternalIsPostmounting);
5488
5536
  }, [other._remotionInternalIsPostmounting, parentSequence?.postmounting]);
5489
5537
  const currentSequenceStart = cumulatedFrom + effectiveRelativeFrom;
@@ -5491,7 +5539,7 @@ var RegularSequenceRefForwardingFunction = ({
5491
5539
  const parentFirstFrame = parentSequence ? parentSequenceStart - parentSequence.cumulatedNegativeFrom : 0;
5492
5540
  const firstFrame = Math.max(0, parentFirstFrame, currentSequenceStart);
5493
5541
  const cumulatedNegativeFrom = currentSequenceStart - firstFrame;
5494
- const contextValue = useMemo14(() => {
5542
+ const contextValue = useMemo15(() => {
5495
5543
  return {
5496
5544
  absoluteFrom,
5497
5545
  cumulatedFrom,
@@ -5522,12 +5570,12 @@ var RegularSequenceRefForwardingFunction = ({
5522
5570
  postmountDisplay,
5523
5571
  cumulatedNegativeFrom
5524
5572
  ]);
5525
- const timelineClipName = useMemo14(() => {
5573
+ const timelineClipName = useMemo15(() => {
5526
5574
  return name ?? "";
5527
5575
  }, [name]);
5528
5576
  const resolvedDocumentationLink = documentationLink ?? "https://www.remotion.dev/docs/sequence";
5529
5577
  const env = useRemotionEnvironment();
5530
- const isInsideSeries = useContext17(IsInsideSeriesContext);
5578
+ const isInsideSeries = useContext18(IsInsideSeriesContext);
5531
5579
  const inheritedStack = other?.stack ?? null;
5532
5580
  const stackRef = useRef6(null);
5533
5581
  stackRef.current = stack ?? inheritedStack;
@@ -5675,7 +5723,7 @@ var RegularSequenceRefForwardingFunction = ({
5675
5723
  ref.current = node;
5676
5724
  }
5677
5725
  }, [ref]);
5678
- const defaultStyle = useMemo14(() => {
5726
+ const defaultStyle = useMemo15(() => {
5679
5727
  return {
5680
5728
  flexDirection: undefined,
5681
5729
  ...width ? { width } : {},
@@ -5701,8 +5749,6 @@ var RegularSequenceRefForwardingFunction = ({
5701
5749
  };
5702
5750
  var RegularSequence = forwardRef3(RegularSequenceRefForwardingFunction);
5703
5751
  var PremountedPostmountedSequenceRefForwardingFunction = (props, ref) => {
5704
- const parentPremountContext = useContext17(PremountContext);
5705
- const frame = useCurrentFrame() - parentPremountContext.premountFramesRemaining;
5706
5752
  if (props.layout === "none") {
5707
5753
  throw new Error('`<Sequence>` with `premountFor` and `postmountFor` props does not support layout="none"');
5708
5754
  }
@@ -5716,34 +5762,30 @@ var PremountedPostmountedSequenceRefForwardingFunction = (props, ref) => {
5716
5762
  styleWhilePostmounted,
5717
5763
  ...otherProps
5718
5764
  } = props;
5719
- const endThreshold = Math.ceil(from + durationInFrames - 1);
5720
- const premountingActive = frame < from && frame >= from - premountFor;
5721
- const postmountingActive = frame > endThreshold && frame <= endThreshold + postmountFor;
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,
5765
+ const {
5766
+ freezeFrame,
5767
+ isPremountingOrPostmounting,
5735
5768
  postmountingActive,
5736
- styleWhilePremounted,
5737
- styleWhilePostmounted
5738
- ]);
5769
+ premountingActive,
5770
+ premountingStyle
5771
+ } = usePremounting({
5772
+ from,
5773
+ durationInFrames,
5774
+ premountFor,
5775
+ postmountFor,
5776
+ style: passedStyle ?? null,
5777
+ styleWhilePremounted: styleWhilePremounted ?? null,
5778
+ styleWhilePostmounted: styleWhilePostmounted ?? null,
5779
+ hideWhilePremounted: "opacity"
5780
+ });
5739
5781
  return /* @__PURE__ */ jsx12(Freeze, {
5740
5782
  frame: freezeFrame,
5741
- active: isFreezingActive,
5783
+ active: isPremountingOrPostmounting,
5742
5784
  children: /* @__PURE__ */ jsx12(SequenceInner, {
5743
5785
  ref,
5744
5786
  from,
5745
5787
  durationInFrames,
5746
- style,
5788
+ style: premountingStyle ?? undefined,
5747
5789
  _remotionInternalPremountDisplay: premountFor,
5748
5790
  _remotionInternalPostmountDisplay: postmountFor,
5749
5791
  _remotionInternalIsPremounting: premountingActive,
@@ -6079,7 +6121,7 @@ var useEffectChainState = () => {
6079
6121
  }
6080
6122
  };
6081
6123
  }, []);
6082
- return useMemo15(() => ({
6124
+ return useMemo16(() => ({
6083
6125
  get: (width, height) => {
6084
6126
  if (!sizeRef.current || sizeRef.current.width !== width || sizeRef.current.height !== height) {
6085
6127
  if (chainStateRef.current) {
@@ -6095,7 +6137,7 @@ var useEffectChainState = () => {
6095
6137
  var CanvasRefForwardingFunction = ({ width, height, fit, className, style, effects, ...props }, ref) => {
6096
6138
  const canvasRef = useRef8(null);
6097
6139
  const chainState = useEffectChainState();
6098
- const sourceCanvas = useMemo16(() => {
6140
+ const sourceCanvas = useMemo17(() => {
6099
6141
  if (typeof document === "undefined") {
6100
6142
  return null;
6101
6143
  }
@@ -6652,7 +6694,7 @@ var RenderAssetManagerProvider = ({ children, collectAssets }) => {
6652
6694
  };
6653
6695
  }
6654
6696
  }, []);
6655
- const contextValue = useMemo17(() => {
6697
+ const contextValue = useMemo18(() => {
6656
6698
  return {
6657
6699
  registerRenderAsset,
6658
6700
  unregisterRenderAsset,
@@ -6666,7 +6708,7 @@ var RenderAssetManagerProvider = ({ children, collectAssets }) => {
6666
6708
  };
6667
6709
  var ArtifactThumbnail = Symbol("Thumbnail");
6668
6710
  var Artifact = ({ filename, content, downloadBehavior }) => {
6669
- const { registerRenderAsset, unregisterRenderAsset } = useContext18(RenderAssetManager);
6711
+ const { registerRenderAsset, unregisterRenderAsset } = useContext19(RenderAssetManager);
6670
6712
  const env = useRemotionEnvironment();
6671
6713
  const frame = useCurrentFrame();
6672
6714
  const [id] = useState8(() => {
@@ -6781,14 +6823,14 @@ var Loop = ({
6781
6823
  const iteration = Math.floor(currentFrame / durationInFrames);
6782
6824
  const start = iteration * durationInFrames;
6783
6825
  const from = Math.min(start, maxFrame);
6784
- const loopDisplay = useMemo18(() => {
6826
+ const loopDisplay = useMemo19(() => {
6785
6827
  return {
6786
6828
  numberOfTimes: Math.min(compDuration / durationInFrames, times),
6787
6829
  startOffset: -from,
6788
6830
  durationInFrames
6789
6831
  };
6790
6832
  }, [compDuration, durationInFrames, from, times]);
6791
- const loopContext = useMemo18(() => {
6833
+ const loopContext = useMemo19(() => {
6792
6834
  return {
6793
6835
  iteration: Math.floor(currentFrame / durationInFrames),
6794
6836
  durationInFrames
@@ -6857,7 +6899,7 @@ var getSrcWithoutHash = (src) => {
6857
6899
  return src.slice(0, hashIndex);
6858
6900
  };
6859
6901
  var usePreload = (src) => {
6860
- const preloads2 = useContext19(PreloadContext);
6902
+ const preloads2 = useContext20(PreloadContext);
6861
6903
  const hashFragmentIndex = removeAndGetHashFragment(src);
6862
6904
  const withoutHashFragment = getSrcWithoutHash(src);
6863
6905
  if (!preloads2[withoutHashFragment]) {
@@ -7160,7 +7202,7 @@ var DurationsContext = createContext20({
7160
7202
  });
7161
7203
  var DurationsContextProvider = ({ children }) => {
7162
7204
  const [durations, setDurations] = useReducer(durationReducer, {});
7163
- const value = useMemo19(() => {
7205
+ const value = useMemo20(() => {
7164
7206
  return {
7165
7207
  durations,
7166
7208
  setDurations
@@ -7299,7 +7341,7 @@ var useSingletonAudioContext = ({
7299
7341
  if (sampleRate !== initialSampleRate.current) {
7300
7342
  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
7343
  }
7302
- const context = useMemo20(() => {
7344
+ const context = useMemo21(() => {
7303
7345
  if (env.isRendering) {
7304
7346
  return null;
7305
7347
  }
@@ -7433,9 +7475,9 @@ var SharedAudioContextProvider = ({ children, audioLatencyHint, audioEnabled, pr
7433
7475
  });
7434
7476
  const audioContextIsPlayingEventually = useRef12(false);
7435
7477
  const isResuming = useRef12(null);
7436
- const audioSyncAnchor = useMemo21(() => ({ value: 0 }), []);
7478
+ const audioSyncAnchor = useMemo22(() => ({ value: 0 }), []);
7437
7479
  const audioSyncAnchorListeners = useRef12([]);
7438
- const audioSyncAnchorEmitter = useMemo21(() => {
7480
+ const audioSyncAnchorEmitter = useMemo22(() => {
7439
7481
  return {
7440
7482
  dispatch: (event) => {
7441
7483
  audioSyncAnchorListeners.current.forEach((l) => l(event));
@@ -7455,7 +7497,7 @@ var SharedAudioContextProvider = ({ children, audioLatencyHint, audioEnabled, pr
7455
7497
  const unscheduleAudioNode = useCallback9((node) => {
7456
7498
  nodesToResume.current.delete(node);
7457
7499
  }, []);
7458
- const scheduleAudioNode = useMemo21(() => {
7500
+ const scheduleAudioNode = useMemo22(() => {
7459
7501
  return ({
7460
7502
  node,
7461
7503
  mediaTimestamp,
@@ -7547,7 +7589,7 @@ var SharedAudioContextProvider = ({ children, audioLatencyHint, audioEnabled, pr
7547
7589
  audioContextIsPlayingEventually.current = false;
7548
7590
  return ctxAndGain.suspend();
7549
7591
  }, [ctxAndGain]);
7550
- const audioContextValue = useMemo21(() => {
7592
+ const audioContextValue = useMemo22(() => {
7551
7593
  return {
7552
7594
  audioContext: ctxAndGain?.audioContext ?? null,
7553
7595
  getAudioContextState: () => ctxAndGain?.getState() ?? null,
@@ -7584,10 +7626,10 @@ var SharedAudioTagsContextProvider = ({ children, numberOfAudioTags }) => {
7584
7626
  const logLevel = useLogLevel();
7585
7627
  const mountTime = useMountTime();
7586
7628
  const env = useRemotionEnvironment();
7587
- const audioCtx = useContext20(SharedAudioContext);
7629
+ const audioCtx = useContext21(SharedAudioContext);
7588
7630
  const audioContext = audioCtx?.audioContext ?? null;
7589
7631
  const resume = audioCtx?.resume;
7590
- const refs = useMemo21(() => {
7632
+ const refs = useMemo22(() => {
7591
7633
  return new Array(numberOfAudioTags).fill(true).map(() => {
7592
7634
  const ref = createRef2();
7593
7635
  return {
@@ -7726,7 +7768,7 @@ var SharedAudioTagsContextProvider = ({ children, numberOfAudioTags }) => {
7726
7768
  });
7727
7769
  resume?.();
7728
7770
  }, [logLevel, mountTime, refs, env.isPlayer, resume]);
7729
- const audioTagsValue = useMemo21(() => {
7771
+ const audioTagsValue = useMemo22(() => {
7730
7772
  return {
7731
7773
  registerAudio,
7732
7774
  unregisterAudio,
@@ -7741,7 +7783,7 @@ var SharedAudioTagsContextProvider = ({ children, numberOfAudioTags }) => {
7741
7783
  unregisterAudio,
7742
7784
  updateAudio
7743
7785
  ]);
7744
- const sharedAudioTagElements = useMemo21(() => {
7786
+ const sharedAudioTagElements = useMemo22(() => {
7745
7787
  return refs.map(({ id, ref }) => {
7746
7788
  return /* @__PURE__ */ jsx19("audio", {
7747
7789
  ref,
@@ -7764,8 +7806,8 @@ var useSharedAudio = ({
7764
7806
  premounting,
7765
7807
  postmounting
7766
7808
  }) => {
7767
- const audioCtx = useContext20(SharedAudioContext);
7768
- const tagsCtx = useContext20(SharedAudioTagsContext);
7809
+ const audioCtx = useContext21(SharedAudioContext);
7810
+ const tagsCtx = useContext21(SharedAudioTagsContext);
7769
7811
  const [elem] = useState10(() => {
7770
7812
  if (tagsCtx && tagsCtx.numberOfAudioTags > 0) {
7771
7813
  return tagsCtx.registerAudio({ aud, audioId, premounting, postmounting });
@@ -7944,7 +7986,7 @@ var useVolume = ({
7944
7986
  const audioStuffRef = useRef14(null);
7945
7987
  const currentVolumeRef = useRef14(volume);
7946
7988
  currentVolumeRef.current = volume;
7947
- const sharedAudioContext = useContext21(SharedAudioContext);
7989
+ const sharedAudioContext = useContext22(SharedAudioContext);
7948
7990
  if (!sharedAudioContext) {
7949
7991
  throw new Error("useAmplification must be used within a SharedAudioContext");
7950
7992
  }
@@ -8009,7 +8051,7 @@ var useVolume = ({
8009
8051
  return audioStuffRef;
8010
8052
  };
8011
8053
  var useMediaStartsAt = () => {
8012
- const parentSequence = useContext22(SequenceContext);
8054
+ const parentSequence = useContext23(SequenceContext);
8013
8055
  return parentSequence?.cumulatedNegativeFrom ?? 0;
8014
8056
  };
8015
8057
  var useFrameForVolumeProp = (behavior) => {
@@ -8098,7 +8140,7 @@ var useBasicMediaInTimeline = ({
8098
8140
  if (!src) {
8099
8141
  throw new Error("No src passed");
8100
8142
  }
8101
- const parentSequence = useContext23(SequenceContext);
8143
+ const parentSequence = useContext24(SequenceContext);
8102
8144
  const [initialVolume] = useState11(() => volume);
8103
8145
  const duration = getTimelineDuration({
8104
8146
  compositionDurationInFrames: sequenceDurationInFrames,
@@ -8108,7 +8150,7 @@ var useBasicMediaInTimeline = ({
8108
8150
  parentSequenceDurationInFrames: parentSequence?.durationInFrames ?? null,
8109
8151
  loop
8110
8152
  });
8111
- const volumes = useMemo22(() => {
8153
+ const volumes = useMemo23(() => {
8112
8154
  if (typeof volume === "number") {
8113
8155
  return volume;
8114
8156
  }
@@ -8129,7 +8171,7 @@ var useBasicMediaInTimeline = ({
8129
8171
  const nonce = useNonce();
8130
8172
  const { rootId } = useTimelineContext();
8131
8173
  const startMediaFrom = 0 - mediaStartsAt + (trimBefore ?? 0);
8132
- const memoizedResult = useMemo22(() => {
8174
+ const memoizedResult = useMemo23(() => {
8133
8175
  return {
8134
8176
  volumes,
8135
8177
  duration,
@@ -8170,9 +8212,9 @@ var useMediaInTimeline = ({
8170
8212
  documentationLink,
8171
8213
  refForOutline
8172
8214
  }) => {
8173
- const parentSequence = useContext23(SequenceContext);
8215
+ const parentSequence = useContext24(SequenceContext);
8174
8216
  const startsAt = useMediaStartsAt();
8175
- const { registerSequence, unregisterSequence } = useContext23(SequenceManager);
8217
+ const { registerSequence, unregisterSequence } = useContext24(SequenceManager);
8176
8218
  const { durationInFrames } = useVideoConfig();
8177
8219
  const mediaStartsAt = useMediaStartsAt();
8178
8220
  const { volumes, duration, doesVolumeChange, nonce, rootId, finalDisplayName } = useBasicMediaInTimeline({
@@ -8337,13 +8379,13 @@ var useBufferManager = (logLevel, mountTime) => {
8337
8379
  }
8338
8380
  }, [blocks]);
8339
8381
  }
8340
- return useMemo23(() => {
8382
+ return useMemo24(() => {
8341
8383
  return { addBlock, listenForBuffering, listenForResume, buffering };
8342
8384
  }, [addBlock, buffering, listenForBuffering, listenForResume]);
8343
8385
  };
8344
8386
  var BufferingContextReact = React21.createContext(null);
8345
8387
  var BufferingProvider = ({ children }) => {
8346
- const { logLevel, mountTime } = useContext24(LogLevelContext);
8388
+ const { logLevel, mountTime } = useContext25(LogLevelContext);
8347
8389
  const bufferManager = useBufferManager(logLevel ?? "info", mountTime);
8348
8390
  return /* @__PURE__ */ jsx20(BufferingContextReact.Provider, {
8349
8391
  value: bufferManager,
@@ -8369,10 +8411,10 @@ var useIsPlayerBuffering = (bufferManager) => {
8369
8411
  return isBuffering;
8370
8412
  };
8371
8413
  var useBufferState = () => {
8372
- const buffer = useContext25(BufferingContextReact);
8414
+ const buffer = useContext26(BufferingContextReact);
8373
8415
  const logLevel = useLogLevel();
8374
8416
  const addBlock = buffer ? buffer.addBlock : null;
8375
- return useMemo24(() => ({
8417
+ return useMemo25(() => ({
8376
8418
  delayPlayback: () => {
8377
8419
  if (!addBlock) {
8378
8420
  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 +8522,7 @@ var useBufferUntilFirstFrame = ({
8480
8522
  onVariableFpsVideoDetected,
8481
8523
  pauseWhenBuffering
8482
8524
  ]);
8483
- return useMemo25(() => {
8525
+ return useMemo26(() => {
8484
8526
  return {
8485
8527
  isBuffering: () => bufferingRef.current,
8486
8528
  bufferUntilFirstFrame
@@ -8854,7 +8896,7 @@ var useMediaPlayback = ({
8854
8896
  const frame = useCurrentFrame();
8855
8897
  const absoluteFrame = useTimelinePosition();
8856
8898
  const [playing] = usePlayingState();
8857
- const buffering = useContext26(BufferingContextReact);
8899
+ const buffering = useContext27(BufferingContextReact);
8858
8900
  const { fps } = useVideoConfig();
8859
8901
  const mediaStartsAt = useMediaStartsAt();
8860
8902
  const lastSeekDueToShift = useRef18(null);
@@ -9149,16 +9191,16 @@ var SetMediaVolumeContext = createContext22({
9149
9191
  }
9150
9192
  });
9151
9193
  var useMediaVolumeState = () => {
9152
- const { mediaVolume } = useContext27(MediaVolumeContext);
9153
- const { setMediaVolume } = useContext27(SetMediaVolumeContext);
9154
- return useMemo26(() => {
9194
+ const { mediaVolume } = useContext28(MediaVolumeContext);
9195
+ const { setMediaVolume } = useContext28(SetMediaVolumeContext);
9196
+ return useMemo27(() => {
9155
9197
  return [mediaVolume, setMediaVolume];
9156
9198
  }, [mediaVolume, setMediaVolume]);
9157
9199
  };
9158
9200
  var usePlayerMutedState = () => {
9159
- const { playerMuted } = useContext27(MediaVolumeContext);
9160
- const { setPlayerMuted } = useContext27(SetMediaVolumeContext);
9161
- return useMemo26(() => {
9201
+ const { playerMuted } = useContext28(MediaVolumeContext);
9202
+ const { setPlayerMuted } = useContext28(SetMediaVolumeContext);
9203
+ return useMemo27(() => {
9162
9204
  return [playerMuted, setPlayerMuted];
9163
9205
  }, [playerMuted, setPlayerMuted]);
9164
9206
  };
@@ -9212,7 +9254,7 @@ var AudioForDevelopmentForwardRefFunction = (props, ref) => {
9212
9254
  throw new TypeError("No 'src' was passed to <Html5Audio>.");
9213
9255
  }
9214
9256
  const preloadedSrc = usePreload(src);
9215
- const sequenceContext = useContext28(SequenceContext);
9257
+ const sequenceContext = useContext29(SequenceContext);
9216
9258
  const [timelineId] = useState14(() => String(Math.random()));
9217
9259
  const userPreferredVolume = evaluateVolume({
9218
9260
  frame: volumePropFrame,
@@ -9225,7 +9267,7 @@ var AudioForDevelopmentForwardRefFunction = (props, ref) => {
9225
9267
  requestsVideoFrame: false,
9226
9268
  isClientSideRendering: false
9227
9269
  });
9228
- const propsToPass = useMemo27(() => {
9270
+ const propsToPass = useMemo28(() => {
9229
9271
  return {
9230
9272
  muted: muted || playerMuted || userPreferredVolume <= 0,
9231
9273
  src: preloadedSrc,
@@ -9242,7 +9284,7 @@ var AudioForDevelopmentForwardRefFunction = (props, ref) => {
9242
9284
  userPreferredVolume,
9243
9285
  crossOriginValue
9244
9286
  ]);
9245
- const id = useMemo27(() => `audio-${random(src ?? "")}-${sequenceContext?.relativeFrom}-${sequenceContext?.cumulatedFrom}-${sequenceContext?.durationInFrames}-muted:${props.muted}-loop:${props.loop}`, [
9287
+ const id = useMemo28(() => `audio-${random(src ?? "")}-${sequenceContext?.relativeFrom}-${sequenceContext?.cumulatedFrom}-${sequenceContext?.durationInFrames}-muted:${props.muted}-loop:${props.loop}`, [
9246
9288
  src,
9247
9289
  sequenceContext?.relativeFrom,
9248
9290
  sequenceContext?.cumulatedFrom,
@@ -9372,10 +9414,10 @@ var AudioForRenderingRefForwardingFunction = (props, ref) => {
9372
9414
  const absoluteFrame = useTimelinePosition();
9373
9415
  const volumePropFrame = useFrameForVolumeProp(loopVolumeCurveBehavior ?? "repeat");
9374
9416
  const frame = useCurrentFrame();
9375
- const sequenceContext = useContext29(SequenceContext);
9376
- const { registerRenderAsset, unregisterRenderAsset } = useContext29(RenderAssetManager);
9417
+ const sequenceContext = useContext30(SequenceContext);
9418
+ const { registerRenderAsset, unregisterRenderAsset } = useContext30(RenderAssetManager);
9377
9419
  const { delayRender: delayRender2, continueRender: continueRender2 } = useDelayRender();
9378
- const id = useMemo28(() => `audio-${random(props.src ?? "")}-${sequenceContext?.relativeFrom}-${sequenceContext?.cumulatedFrom}-${sequenceContext?.durationInFrames}`, [
9420
+ const id = useMemo29(() => `audio-${random(props.src ?? "")}-${sequenceContext?.relativeFrom}-${sequenceContext?.cumulatedFrom}-${sequenceContext?.durationInFrames}`, [
9379
9421
  props.src,
9380
9422
  sequenceContext?.relativeFrom,
9381
9423
  sequenceContext?.cumulatedFrom,
@@ -9482,7 +9524,7 @@ var AudioForRenderingRefForwardingFunction = (props, ref) => {
9482
9524
  };
9483
9525
  var AudioForRendering = forwardRef6(AudioForRenderingRefForwardingFunction);
9484
9526
  var AudioRefForwardingFunction = (props, ref) => {
9485
- const audioTagsContext = useContext30(SharedAudioTagsContext);
9527
+ const audioTagsContext = useContext31(SharedAudioTagsContext);
9486
9528
  const propsWithFreeze = props;
9487
9529
  const {
9488
9530
  startFrom,
@@ -9506,7 +9548,7 @@ var AudioRefForwardingFunction = (props, ref) => {
9506
9548
  if (typeof freeze !== "undefined") {
9507
9549
  throw new TypeError('The "freeze" prop is not supported on <Html5Audio />. Use <Sequence freeze={...}> to freeze media playback.');
9508
9550
  }
9509
- const { durations, setDurations } = useContext30(DurationsContext);
9551
+ const { durations, setDurations } = useContext31(DurationsContext);
9510
9552
  if (typeof props.src !== "string") {
9511
9553
  throw new TypeError(`The \`<Html5Audio>\` tag requires a string for \`src\`, but got ${JSON.stringify(props.src)} instead.`);
9512
9554
  }
@@ -9668,7 +9710,7 @@ var SolidInner = ({
9668
9710
  effects,
9669
9711
  overrideId: overrideId ?? null
9670
9712
  });
9671
- const sourceCanvas = useMemo29(() => {
9713
+ const sourceCanvas = useMemo30(() => {
9672
9714
  if (typeof document === "undefined") {
9673
9715
  return null;
9674
9716
  }
@@ -9736,7 +9778,7 @@ var SolidInner = ({
9736
9778
  cancelRender2,
9737
9779
  memoizedEffects
9738
9780
  ]);
9739
- const canvasStyle = useMemo29(() => {
9781
+ const canvasStyle = useMemo30(() => {
9740
9782
  return {
9741
9783
  width,
9742
9784
  height,
@@ -9885,12 +9927,12 @@ var HtmlInCanvasContent = forwardRef9(({
9885
9927
  controls,
9886
9928
  style
9887
9929
  }, ref) => {
9888
- const ancestor = useContext31(HtmlInCanvasAncestorContext);
9930
+ const ancestor = useContext32(HtmlInCanvasAncestorContext);
9889
9931
  assertHtmlInCanvasDimensions(width, height);
9890
9932
  const resolvedPixelDensity = resolveHtmlInCanvasPixelDensity(pixelDensity);
9891
9933
  const canvasWidth = Math.ceil(width * resolvedPixelDensity);
9892
9934
  const canvasHeight = Math.ceil(height * resolvedPixelDensity);
9893
- const { continueRender: continueRender2, cancelRender: cancelRender2 } = useDelayRender();
9935
+ const { delayRender: delayRender2, continueRender: continueRender2, cancelRender: cancelRender2 } = useDelayRender();
9894
9936
  const { isClientSideRendering, isRendering } = useRemotionEnvironment();
9895
9937
  const canRetryMissingPaintRecord = !isRendering || isClientSideRendering;
9896
9938
  const usesDirectLayoutCanvas = onPaint === undefined && onInit === undefined;
@@ -9944,7 +9986,7 @@ var HtmlInCanvasContent = forwardRef9(({
9944
9986
  if (!placeholderCanvas) {
9945
9987
  throw new Error("Canvas not found");
9946
9988
  }
9947
- const handle = delayRender("onPaint");
9989
+ const handle = delayRender2("onPaint");
9948
9990
  if (!initializedRef.current) {
9949
9991
  const currentOnInit = onInitRef.current;
9950
9992
  if (!currentOnInit) {
@@ -10045,6 +10087,7 @@ var HtmlInCanvasContent = forwardRef9(({
10045
10087
  chainState,
10046
10088
  continueRender2,
10047
10089
  cancelRender2,
10090
+ delayRender2,
10048
10091
  resolvedPixelDensity,
10049
10092
  canRetryMissingPaintRecord
10050
10093
  ]);
@@ -10096,28 +10139,28 @@ var HtmlInCanvasContent = forwardRef9(({
10096
10139
  if (!canvas) {
10097
10140
  return;
10098
10141
  }
10099
- const handle = delayRender("waiting for first paint after canvas resize");
10142
+ const handle = delayRender2("waiting for first paint after canvas resize");
10100
10143
  canvas.addEventListener("paint", () => {
10101
10144
  continueRender2(handle);
10102
10145
  }, { once: true });
10103
10146
  return () => {
10104
10147
  continueRender2(handle);
10105
10148
  };
10106
- }, [width, height, continueRender2, canvasSizeKey]);
10107
- const innerStyle = useMemo30(() => {
10149
+ }, [width, height, continueRender2, delayRender2, canvasSizeKey]);
10150
+ const innerStyle = useMemo31(() => {
10108
10151
  return {
10109
10152
  width,
10110
10153
  height
10111
10154
  };
10112
10155
  }, [width, height]);
10113
- const canvasStyle = useMemo30(() => {
10156
+ const canvasStyle = useMemo31(() => {
10114
10157
  return {
10115
10158
  width,
10116
10159
  height,
10117
10160
  ...style ?? {}
10118
10161
  };
10119
10162
  }, [height, style, width]);
10120
- const ancestorValue = useMemo30(() => {
10163
+ const ancestorValue = useMemo31(() => {
10121
10164
  return {
10122
10165
  requestParentPaint: () => {
10123
10166
  canvas2dRef.current?.requestPaint?.();
@@ -10331,7 +10374,7 @@ var CanvasImageContent = forwardRef10(({
10331
10374
  effects,
10332
10375
  overrideId: controls?.overrideId ?? null
10333
10376
  });
10334
- const sequenceContext = useContext32(SequenceContext);
10377
+ const sequenceContext = useContext33(SequenceContext);
10335
10378
  const pendingLoadDelayRef = useRef23(null);
10336
10379
  const [isLoadPending, setIsLoadPending] = useState16(false);
10337
10380
  const isPremounting = Boolean(sequenceContext?.premounting);
@@ -10348,7 +10391,7 @@ var CanvasImageContent = forwardRef10(({
10348
10391
  continueRender2(pending.handle);
10349
10392
  pendingLoadDelayRef.current = null;
10350
10393
  }, [continueRender2]);
10351
- const sourceCanvas = useMemo31(() => {
10394
+ const sourceCanvas = useMemo32(() => {
10352
10395
  if (typeof document === "undefined") {
10353
10396
  return null;
10354
10397
  }
@@ -10670,7 +10713,7 @@ var ImgContent = ({
10670
10713
  const imageRef = useRef24(null);
10671
10714
  const errors = useRef24({});
10672
10715
  const { delayPlayback } = useBufferState();
10673
- const sequenceContext = useContext33(SequenceContext);
10716
+ const sequenceContext = useContext34(SequenceContext);
10674
10717
  const [isLoading, setIsLoading] = useState18(false);
10675
10718
  const _propsValid = true;
10676
10719
  if (!_propsValid) {
@@ -11019,7 +11062,10 @@ var makeRemotionComponentIdentity = ({
11019
11062
  };
11020
11063
  var interactiveElementSchema = {
11021
11064
  ...baseSchema,
11022
- ...transformSchema,
11065
+ ...transformSchema
11066
+ };
11067
+ var interactiveTextElementSchema = {
11068
+ ...interactiveElementSchema,
11023
11069
  ...textSchema,
11024
11070
  ...textContentSchema
11025
11071
  };
@@ -11035,7 +11081,7 @@ var withSchema = (options) => {
11035
11081
  addSequenceStackTraces(Wrapped);
11036
11082
  return Wrapped;
11037
11083
  };
11038
- var makeInteractiveElement = (tag, displayName) => {
11084
+ var makeInteractiveElement = (tag, displayName, schema) => {
11039
11085
  const Inner = forwardRef12((propsWithControls, ref) => {
11040
11086
  const {
11041
11087
  durationInFrames,
@@ -11081,12 +11127,18 @@ var makeInteractiveElement = (tag, displayName) => {
11081
11127
  packageName: "remotion",
11082
11128
  componentName: displayName.slice(1, -1)
11083
11129
  }),
11084
- schema: interactiveElementSchema,
11130
+ schema,
11085
11131
  supportsEffects: false
11086
11132
  });
11087
11133
  Wrapped.displayName = displayName;
11088
11134
  return Wrapped;
11089
11135
  };
11136
+ var makeInteractiveTextElement = (tag, displayName) => {
11137
+ return makeInteractiveElement(tag, displayName, interactiveTextElementSchema);
11138
+ };
11139
+ var makeInteractiveNonTextElement = (tag, displayName) => {
11140
+ return makeInteractiveElement(tag, displayName, interactiveElementSchema);
11141
+ };
11090
11142
  var Interactive = {
11091
11143
  baseSchema,
11092
11144
  transformSchema,
@@ -11095,41 +11147,41 @@ var Interactive = {
11095
11147
  sequenceSchema,
11096
11148
  withSchema,
11097
11149
  _internalMakeRemotionComponentIdentity: makeRemotionComponentIdentity,
11098
- A: makeInteractiveElement("a", "<Interactive.A>"),
11099
- Article: makeInteractiveElement("article", "<Interactive.Article>"),
11100
- Aside: makeInteractiveElement("aside", "<Interactive.Aside>"),
11101
- Button: makeInteractiveElement("button", "<Interactive.Button>"),
11102
- Circle: makeInteractiveElement("circle", "<Interactive.Circle>"),
11103
- Code: makeInteractiveElement("code", "<Interactive.Code>"),
11104
- Div: makeInteractiveElement("div", "<Interactive.Div>"),
11105
- Ellipse: makeInteractiveElement("ellipse", "<Interactive.Ellipse>"),
11106
- Em: makeInteractiveElement("em", "<Interactive.Em>"),
11107
- Footer: makeInteractiveElement("footer", "<Interactive.Footer>"),
11108
- G: makeInteractiveElement("g", "<Interactive.G>"),
11109
- H1: makeInteractiveElement("h1", "<Interactive.H1>"),
11110
- H2: makeInteractiveElement("h2", "<Interactive.H2>"),
11111
- H3: makeInteractiveElement("h3", "<Interactive.H3>"),
11112
- H4: makeInteractiveElement("h4", "<Interactive.H4>"),
11113
- H5: makeInteractiveElement("h5", "<Interactive.H5>"),
11114
- H6: makeInteractiveElement("h6", "<Interactive.H6>"),
11115
- Header: makeInteractiveElement("header", "<Interactive.Header>"),
11116
- Label: makeInteractiveElement("label", "<Interactive.Label>"),
11117
- Li: makeInteractiveElement("li", "<Interactive.Li>"),
11118
- Line: makeInteractiveElement("line", "<Interactive.Line>"),
11119
- Main: makeInteractiveElement("main", "<Interactive.Main>"),
11120
- Nav: makeInteractiveElement("nav", "<Interactive.Nav>"),
11121
- Ol: makeInteractiveElement("ol", "<Interactive.Ol>"),
11122
- P: makeInteractiveElement("p", "<Interactive.P>"),
11123
- Path: makeInteractiveElement("path", "<Interactive.Path>"),
11124
- Pre: makeInteractiveElement("pre", "<Interactive.Pre>"),
11125
- Rect: makeInteractiveElement("rect", "<Interactive.Rect>"),
11126
- Section: makeInteractiveElement("section", "<Interactive.Section>"),
11127
- Small: makeInteractiveElement("small", "<Interactive.Small>"),
11128
- Span: makeInteractiveElement("span", "<Interactive.Span>"),
11129
- Strong: makeInteractiveElement("strong", "<Interactive.Strong>"),
11130
- Svg: makeInteractiveElement("svg", "<Interactive.Svg>"),
11131
- Text: makeInteractiveElement("text", "<Interactive.Text>"),
11132
- Ul: makeInteractiveElement("ul", "<Interactive.Ul>")
11150
+ A: makeInteractiveTextElement("a", "<Interactive.A>"),
11151
+ Article: makeInteractiveTextElement("article", "<Interactive.Article>"),
11152
+ Aside: makeInteractiveTextElement("aside", "<Interactive.Aside>"),
11153
+ Button: makeInteractiveTextElement("button", "<Interactive.Button>"),
11154
+ Circle: makeInteractiveNonTextElement("circle", "<Interactive.Circle>"),
11155
+ Code: makeInteractiveTextElement("code", "<Interactive.Code>"),
11156
+ Div: makeInteractiveTextElement("div", "<Interactive.Div>"),
11157
+ Ellipse: makeInteractiveNonTextElement("ellipse", "<Interactive.Ellipse>"),
11158
+ Em: makeInteractiveTextElement("em", "<Interactive.Em>"),
11159
+ Footer: makeInteractiveTextElement("footer", "<Interactive.Footer>"),
11160
+ G: makeInteractiveNonTextElement("g", "<Interactive.G>"),
11161
+ H1: makeInteractiveTextElement("h1", "<Interactive.H1>"),
11162
+ H2: makeInteractiveTextElement("h2", "<Interactive.H2>"),
11163
+ H3: makeInteractiveTextElement("h3", "<Interactive.H3>"),
11164
+ H4: makeInteractiveTextElement("h4", "<Interactive.H4>"),
11165
+ H5: makeInteractiveTextElement("h5", "<Interactive.H5>"),
11166
+ H6: makeInteractiveTextElement("h6", "<Interactive.H6>"),
11167
+ Header: makeInteractiveTextElement("header", "<Interactive.Header>"),
11168
+ Label: makeInteractiveTextElement("label", "<Interactive.Label>"),
11169
+ Li: makeInteractiveTextElement("li", "<Interactive.Li>"),
11170
+ Line: makeInteractiveNonTextElement("line", "<Interactive.Line>"),
11171
+ Main: makeInteractiveTextElement("main", "<Interactive.Main>"),
11172
+ Nav: makeInteractiveTextElement("nav", "<Interactive.Nav>"),
11173
+ Ol: makeInteractiveTextElement("ol", "<Interactive.Ol>"),
11174
+ P: makeInteractiveTextElement("p", "<Interactive.P>"),
11175
+ Path: makeInteractiveNonTextElement("path", "<Interactive.Path>"),
11176
+ Pre: makeInteractiveTextElement("pre", "<Interactive.Pre>"),
11177
+ Rect: makeInteractiveNonTextElement("rect", "<Interactive.Rect>"),
11178
+ Section: makeInteractiveTextElement("section", "<Interactive.Section>"),
11179
+ Small: makeInteractiveTextElement("small", "<Interactive.Small>"),
11180
+ Span: makeInteractiveTextElement("span", "<Interactive.Span>"),
11181
+ Strong: makeInteractiveTextElement("strong", "<Interactive.Strong>"),
11182
+ Svg: makeInteractiveNonTextElement("svg", "<Interactive.Svg>"),
11183
+ Text: makeInteractiveTextElement("text", "<Interactive.Text>"),
11184
+ Ul: makeInteractiveTextElement("ul", "<Interactive.Ul>")
11133
11185
  };
11134
11186
  var compositionsRef = React31.createRef();
11135
11187
  var CompositionManagerProvider = ({
@@ -11186,7 +11238,7 @@ var CompositionManagerProvider = ({
11186
11238
  getCompositions: () => currentcompositionsRef.current
11187
11239
  };
11188
11240
  }, []);
11189
- const compositionManagerSetters = useMemo32(() => {
11241
+ const compositionManagerSetters = useMemo33(() => {
11190
11242
  return {
11191
11243
  registerComposition,
11192
11244
  unregisterComposition,
@@ -11202,7 +11254,7 @@ var CompositionManagerProvider = ({
11202
11254
  unregisterFolder,
11203
11255
  onlyRenderComposition
11204
11256
  ]);
11205
- const compositionManagerContextValue = useMemo32(() => {
11257
+ const compositionManagerContextValue = useMemo33(() => {
11206
11258
  return {
11207
11259
  compositions,
11208
11260
  folders,
@@ -11300,7 +11352,7 @@ var waitForRoot = (fn) => {
11300
11352
  };
11301
11353
  var MediaEnabledContext = createContext24(null);
11302
11354
  var useVideoEnabled = () => {
11303
- const context = useContext34(MediaEnabledContext);
11355
+ const context = useContext35(MediaEnabledContext);
11304
11356
  if (!context) {
11305
11357
  return window.remotion_videoEnabled;
11306
11358
  }
@@ -11310,7 +11362,7 @@ var useVideoEnabled = () => {
11310
11362
  return context.videoEnabled;
11311
11363
  };
11312
11364
  var useAudioEnabled = () => {
11313
- const context = useContext34(MediaEnabledContext);
11365
+ const context = useContext35(MediaEnabledContext);
11314
11366
  if (!context) {
11315
11367
  return window.remotion_audioEnabled;
11316
11368
  }
@@ -11324,7 +11376,7 @@ var MediaEnabledProvider = ({
11324
11376
  videoEnabled,
11325
11377
  audioEnabled
11326
11378
  }) => {
11327
- const value = useMemo33(() => ({ videoEnabled, audioEnabled }), [videoEnabled, audioEnabled]);
11379
+ const value = useMemo34(() => ({ videoEnabled, audioEnabled }), [videoEnabled, audioEnabled]);
11328
11380
  return /* @__PURE__ */ jsx31(MediaEnabledContext.Provider, {
11329
11381
  value,
11330
11382
  children
@@ -11340,13 +11392,13 @@ var RemotionRootContexts = ({
11340
11392
  audioEnabled,
11341
11393
  frameState
11342
11394
  }) => {
11343
- const nonceContext = useMemo34(() => {
11395
+ const nonceContext = useMemo35(() => {
11344
11396
  let counter = 0;
11345
11397
  return {
11346
11398
  getNonce: () => counter++
11347
11399
  };
11348
11400
  }, []);
11349
- const logging = useMemo34(() => {
11401
+ const logging = useMemo35(() => {
11350
11402
  return { logLevel, mountTime: Date.now() };
11351
11403
  }, [logLevel]);
11352
11404
  return /* @__PURE__ */ jsx32(LogLevelContext.Provider, {
@@ -11647,13 +11699,13 @@ var OffthreadVideoForRendering = ({
11647
11699
  const frame = useCurrentFrame();
11648
11700
  const volumePropsFrame = useFrameForVolumeProp(loopVolumeCurveBehavior);
11649
11701
  const videoConfig = useUnsafeVideoConfig();
11650
- const sequenceContext = useContext36(SequenceContext);
11702
+ const sequenceContext = useContext37(SequenceContext);
11651
11703
  const mediaStartsAt = useMediaStartsAt();
11652
- const { registerRenderAsset, unregisterRenderAsset } = useContext36(RenderAssetManager);
11704
+ const { registerRenderAsset, unregisterRenderAsset } = useContext37(RenderAssetManager);
11653
11705
  if (!src) {
11654
11706
  throw new TypeError("No `src` was passed to <OffthreadVideo>.");
11655
11707
  }
11656
- const id = useMemo35(() => `offthreadvideo-${random(src)}-${sequenceContext?.cumulatedFrom}-${sequenceContext?.relativeFrom}-${sequenceContext?.durationInFrames}`, [
11708
+ const id = useMemo36(() => `offthreadvideo-${random(src)}-${sequenceContext?.cumulatedFrom}-${sequenceContext?.relativeFrom}-${sequenceContext?.durationInFrames}`, [
11657
11709
  src,
11658
11710
  sequenceContext?.cumulatedFrom,
11659
11711
  sequenceContext?.relativeFrom,
@@ -11708,14 +11760,14 @@ var OffthreadVideoForRendering = ({
11708
11760
  sequenceContext?.cumulatedNegativeFrom,
11709
11761
  audioStreamIndex
11710
11762
  ]);
11711
- const currentTime = useMemo35(() => {
11763
+ const currentTime = useMemo36(() => {
11712
11764
  return getExpectedMediaFrameUncorrected({
11713
11765
  frame,
11714
11766
  playbackRate: playbackRate || 1,
11715
11767
  startFrom: -mediaStartsAt
11716
11768
  }) / videoConfig.fps;
11717
11769
  }, [frame, mediaStartsAt, playbackRate, videoConfig.fps]);
11718
- const actualSrc = useMemo35(() => {
11770
+ const actualSrc = useMemo36(() => {
11719
11771
  return getOffthreadVideoSource({
11720
11772
  src,
11721
11773
  currentTime,
@@ -11803,7 +11855,7 @@ var OffthreadVideoForRendering = ({
11803
11855
  cancelRender("Failed to load image with src " + imageSrc);
11804
11856
  }
11805
11857
  }, [imageSrc, onError]);
11806
- const className = useMemo35(() => {
11858
+ const className = useMemo36(() => {
11807
11859
  return [OBJECTFIT_CONTAIN_CLASS_NAME, props2.className].filter(truthy).join(" ");
11808
11860
  }, [props2.className]);
11809
11861
  const onImageFrame = useCallback22((img) => {
@@ -11867,12 +11919,12 @@ class MediaPlaybackError extends Error {
11867
11919
  }
11868
11920
  }
11869
11921
  var VideoForDevelopmentRefForwardingFunction = (props2, ref) => {
11870
- const context = useContext37(SharedAudioContext);
11922
+ const context = useContext38(SharedAudioContext);
11871
11923
  if (!context) {
11872
11924
  throw new Error("SharedAudioContext not found");
11873
11925
  }
11874
11926
  const videoRef = useRef27(null);
11875
- const sharedSource = useMemo36(() => {
11927
+ const sharedSource = useMemo37(() => {
11876
11928
  if (!context.audioContext) {
11877
11929
  return null;
11878
11930
  }
@@ -11924,7 +11976,7 @@ var VideoForDevelopmentRefForwardingFunction = (props2, ref) => {
11924
11976
  }
11925
11977
  const volumePropFrame = useFrameForVolumeProp(loopVolumeCurveBehavior ?? "repeat");
11926
11978
  const { fps, durationInFrames } = useVideoConfig();
11927
- const parentSequence = useContext37(SequenceContext);
11979
+ const parentSequence = useContext38(SequenceContext);
11928
11980
  const logLevel = useLogLevel();
11929
11981
  const mountTime = useMountTime();
11930
11982
  const [timelineId] = useState21(() => String(Math.random()));
@@ -12075,7 +12127,7 @@ var VideoForDevelopmentRefForwardingFunction = (props2, ref) => {
12075
12127
  current.preload = "auto";
12076
12128
  }
12077
12129
  }, []);
12078
- const actualStyle = useMemo36(() => {
12130
+ const actualStyle = useMemo37(() => {
12079
12131
  return {
12080
12132
  ...style
12081
12133
  };
@@ -12271,7 +12323,7 @@ function useRemotionContexts() {
12271
12323
  const visualModePropStatusesRefContext = React40.useContext(VisualModePropStatusesRefContext);
12272
12324
  const bufferManagerContext = React40.useContext(BufferingContextReact);
12273
12325
  const logLevelContext = React40.useContext(LogLevelContext);
12274
- return useMemo37(() => ({
12326
+ return useMemo38(() => ({
12275
12327
  compositionManagerCtx,
12276
12328
  timelineContext,
12277
12329
  setTimelineContext,
@@ -12382,6 +12434,7 @@ var Internals = {
12382
12434
  textSchema,
12383
12435
  transformSchema,
12384
12436
  premountSchema,
12437
+ premountStyleSchema,
12385
12438
  flattenActiveSchema,
12386
12439
  getFlatSchemaWithAllKeys,
12387
12440
  RemotionRootContexts,
@@ -12395,6 +12448,7 @@ var Internals = {
12395
12448
  truthy,
12396
12449
  SequenceContext,
12397
12450
  PremountContext,
12451
+ usePremounting,
12398
12452
  useRemotionContexts,
12399
12453
  RemotionContextProvider,
12400
12454
  CSSUtils: exports_default_css,
@@ -12570,7 +12624,7 @@ var validateSeriesSequenceProps = ({
12570
12624
  return offset;
12571
12625
  };
12572
12626
  var SeriesInner = (props2) => {
12573
- const childrenValue = useMemo38(() => {
12627
+ const childrenValue = useMemo39(() => {
12574
12628
  const flattenedChildren = flattenChildren(props2.children);
12575
12629
  const renderChildren = (i, startFrame) => {
12576
12630
  if (i === flattenedChildren.length) {
@@ -12899,14 +12953,14 @@ var VideoForRenderingForwardFunction = ({
12899
12953
  const volumePropsFrame = useFrameForVolumeProp(loopVolumeCurveBehavior ?? "repeat");
12900
12954
  const videoConfig = useUnsafeVideoConfig();
12901
12955
  const videoRef = useRef28(null);
12902
- const sequenceContext = useContext38(SequenceContext);
12956
+ const sequenceContext = useContext39(SequenceContext);
12903
12957
  const mediaStartsAt = useMediaStartsAt();
12904
12958
  const environment = useRemotionEnvironment();
12905
12959
  const logLevel = useLogLevel();
12906
12960
  const mountTime = useMountTime();
12907
12961
  const { delayRender: delayRender2, continueRender: continueRender2 } = useDelayRender();
12908
- const { registerRenderAsset, unregisterRenderAsset } = useContext38(RenderAssetManager);
12909
- const id = useMemo39(() => `video-${random(props2.src ?? "")}-${sequenceContext?.cumulatedFrom}-${sequenceContext?.relativeFrom}-${sequenceContext?.durationInFrames}`, [
12962
+ const { registerRenderAsset, unregisterRenderAsset } = useContext39(RenderAssetManager);
12963
+ const id = useMemo40(() => `video-${random(props2.src ?? "")}-${sequenceContext?.cumulatedFrom}-${sequenceContext?.relativeFrom}-${sequenceContext?.durationInFrames}`, [
12910
12964
  props2.src,
12911
12965
  sequenceContext?.cumulatedFrom,
12912
12966
  sequenceContext?.relativeFrom,
@@ -13117,7 +13171,7 @@ var VideoForwardingFunction = (props2, ref) => {
13117
13171
  if (environment.isClientSideRendering) {
13118
13172
  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
13173
  }
13120
- const { durations, setDurations } = useContext39(DurationsContext);
13174
+ const { durations, setDurations } = useContext40(DurationsContext);
13121
13175
  if (typeof ref === "string") {
13122
13176
  throw new Error("string refs are not supported");
13123
13177
  }
@@ -13573,7 +13627,7 @@ var ExpertCard = ({ expert, Link }) => {
13573
13627
  });
13574
13628
  };
13575
13629
  var ExpertsPageContent = ({ Link }) => {
13576
- const expertsInRandomOrder = useMemo40(() => {
13630
+ const expertsInRandomOrder = useMemo41(() => {
13577
13631
  if (typeof window === "undefined") {
13578
13632
  return [];
13579
13633
  }
@@ -13671,7 +13725,7 @@ var ExpertsPageContent = ({ Link }) => {
13671
13725
  });
13672
13726
  };
13673
13727
  // src/components/homepage/Pricing.tsx
13674
- import { useMemo as useMemo53 } from "react";
13728
+ import { useMemo as useMemo54 } from "react";
13675
13729
 
13676
13730
  // ../design/dist/esm/index.mjs
13677
13731
  import * as React24 from "react";
@@ -15019,7 +15073,7 @@ var getDefaultConfig = () => {
15019
15073
  var twMerge = /* @__PURE__ */ createTailwindMerge(getDefaultConfig);
15020
15074
 
15021
15075
  // ../design/dist/esm/index.mjs
15022
- import React33, { useEffect as useEffect21, useMemo as useMemo43, useState as useState23 } from "react";
15076
+ import React33, { useEffect as useEffect21, useMemo as useMemo44, useState as useState23 } from "react";
15023
15077
 
15024
15078
  // ../paths/dist/esm/index.mjs
15025
15079
  var cutLInstruction = ({
@@ -17785,7 +17839,7 @@ var PathInternals = {
17785
17839
  };
17786
17840
 
17787
17841
  // ../shapes/dist/esm/index.mjs
17788
- import React3, { useCallback as useCallback26, useMemo as useMemo42, useRef as useRef29 } from "react";
17842
+ import React3, { useCallback as useCallback26, useMemo as useMemo43, useRef as useRef29 } from "react";
17789
17843
  import { version } from "react-dom";
17790
17844
  import { jsx as jsx44, jsxs as jsxs7 } from "react/jsx-runtime";
17791
17845
  import { jsx as jsx210 } from "react/jsx-runtime";
@@ -17967,13 +18021,13 @@ var RenderSvg = ({
17967
18021
  stack,
17968
18022
  ...props
17969
18023
  }) => {
17970
- const actualStyle = useMemo42(() => {
18024
+ const actualStyle = useMemo43(() => {
17971
18025
  return {
17972
18026
  overflow: "visible",
17973
18027
  ...style ?? {}
17974
18028
  };
17975
18029
  }, [style]);
17976
- const actualPathStyle = useMemo42(() => {
18030
+ const actualPathStyle = useMemo43(() => {
17977
18031
  return {
17978
18032
  transformBox: "fill-box",
17979
18033
  ...pathStyle ?? {}
@@ -20952,7 +21006,7 @@ var useHoverTransforms = (ref, disabled) => {
20952
21006
  progress: 0,
20953
21007
  isActive: false
20954
21008
  });
20955
- const eventTarget = useMemo43(() => new EventTarget, []);
21009
+ const eventTarget = useMemo44(() => new EventTarget, []);
20956
21010
  useEffect21(() => {
20957
21011
  if (disabled) {
20958
21012
  eventTarget.dispatchEvent(new Event("disabled"));
@@ -27399,7 +27453,7 @@ var Triangle22 = (props) => {
27399
27453
  };
27400
27454
 
27401
27455
  // src/components/homepage/FreePricing.tsx
27402
- import React53, { useCallback as useCallback38, useMemo as useMemo52 } from "react";
27456
+ import React53, { useCallback as useCallback38, useMemo as useMemo53 } from "react";
27403
27457
 
27404
27458
  // ../../node_modules/.bun/tailwind-merge@2.5.2/node_modules/tailwind-merge/dist/bundle-mjs.mjs
27405
27459
  var CLASS_PART_SEPARATOR2 = "-";
@@ -29056,14 +29110,14 @@ var CompanyPricing = () => {
29056
29110
  }, []);
29057
29111
  const creatorsPrice = creatorsSelected ? devSeatCount * SEAT_PRICE : 0;
29058
29112
  const automatorsPrice = automatorsSelected ? Math.ceil(cloudRenders / 1000) * RENDER_UNIT_PRICE : 0;
29059
- const totalPrice = useMemo52(() => {
29113
+ const totalPrice = useMemo53(() => {
29060
29114
  const basePrice = creatorsPrice + automatorsPrice;
29061
29115
  if (automatorsSelected) {
29062
29116
  return Math.max(100, basePrice);
29063
29117
  }
29064
29118
  return basePrice;
29065
29119
  }, [creatorsPrice, automatorsPrice, automatorsSelected]);
29066
- const totalPriceString = useMemo52(() => {
29120
+ const totalPriceString = useMemo53(() => {
29067
29121
  return formatPrice(totalPrice);
29068
29122
  }, [formatPrice, totalPrice]);
29069
29123
  const showMinimumMessage = automatorsSelected && creatorsPrice + automatorsPrice < 100;
@@ -29293,13 +29347,13 @@ var Pricing = ({
29293
29347
  licenseHref = "https://github.com/remotion-dev/remotion/blob/main/LICENSE.md",
29294
29348
  termsHref = "/docs/license/terms"
29295
29349
  }) => {
29296
- const faqLinkTarget = useMemo53(() => {
29350
+ const faqLinkTarget = useMemo54(() => {
29297
29351
  return faqHref.startsWith("http") ? "_blank" : undefined;
29298
29352
  }, [faqHref]);
29299
- const licenseLinkTarget = useMemo53(() => {
29353
+ const licenseLinkTarget = useMemo54(() => {
29300
29354
  return licenseHref.startsWith("http") ? "_blank" : undefined;
29301
29355
  }, [licenseHref]);
29302
- const termsLinkTarget = useMemo53(() => {
29356
+ const termsLinkTarget = useMemo54(() => {
29303
29357
  return termsHref.startsWith("http") ? "_blank" : undefined;
29304
29358
  }, [termsHref]);
29305
29359
  return /* @__PURE__ */ jsxs11("div", {
@@ -30123,13 +30177,13 @@ import { jsx as jsx59, jsxs as jsxs16 } from "react/jsx-runtime";
30123
30177
  import { jsx as jsx214, jsxs as jsxs24, Fragment as Fragment13 } from "react/jsx-runtime";
30124
30178
  import React57 from "react";
30125
30179
  import { useContext as useContext210, useEffect as useEffect41, useState as useState40 } from "react";
30126
- import { useContext as useContext46, useLayoutEffect as useLayoutEffect18 } from "react";
30180
+ import { useContext as useContext47, useLayoutEffect as useLayoutEffect18 } from "react";
30127
30181
  import { jsx as jsx314 } from "react/jsx-runtime";
30128
30182
  import { useEffect as useEffect210, useState as useState24 } from "react";
30129
30183
  import { useLayoutEffect as useLayoutEffect23 } from "react";
30130
- import { useContext as useContext47, useEffect as useEffect52, useRef as useRef47 } from "react";
30184
+ import { useContext as useContext42, useEffect as useEffect52, useRef as useRef47 } from "react";
30131
30185
  import { useEffect as useEffect310, useRef as useRef212 } from "react";
30132
- import { useCallback as useCallback39, useContext as useContext310, useMemo as useMemo54, useRef as useRef48, useState as useState310 } from "react";
30186
+ import { useCallback as useCallback39, useContext as useContext310, useMemo as useMemo55, useRef as useRef48, useState as useState310 } from "react";
30133
30187
  import { useEffect as useEffect42, useRef as useRef310 } from "react";
30134
30188
  import { useCallback as useCallback210, useEffect as useEffect62, useMemo as useMemo212, useState as useState42 } from "react";
30135
30189
  import {
@@ -30158,11 +30212,11 @@ import React410, { useEffect as useEffect72 } from "react";
30158
30212
  import { jsx as jsx55 } from "react/jsx-runtime";
30159
30213
  import { useCallback as useCallback72, useEffect as useEffect112, useMemo as useMemo92, useRef as useRef82, useState as useState102 } from "react";
30160
30214
  import { jsx as jsx64 } from "react/jsx-runtime";
30161
- import { useCallback as useCallback42, useMemo as useMemo410, useRef as useRef52, useState as useState62 } from "react";
30215
+ import { useCallback as useCallback42, useMemo as useMemo42, useRef as useRef52, useState as useState62 } from "react";
30162
30216
  import React54, { useCallback as useCallback310, useMemo as useMemo310, useState as useState52 } from "react";
30163
30217
  import { jsx as jsx74, jsxs as jsxs33 } from "react/jsx-runtime";
30164
30218
  import { jsx as jsx84, jsxs as jsxs43 } from "react/jsx-runtime";
30165
- import { useCallback as useCallback52, useEffect as useEffect92, useMemo as useMemo55, useState as useState82 } from "react";
30219
+ import { useCallback as useCallback52, useEffect as useEffect92, useMemo as useMemo56, useState as useState82 } from "react";
30166
30220
  import { useEffect as useEffect83, useRef as useRef62, useState as useState72 } from "react";
30167
30221
  import { jsx as jsx94, jsxs as jsxs52 } from "react/jsx-runtime";
30168
30222
  import { useCallback as useCallback62, useEffect as useEffect102, useMemo as useMemo62, useRef as useRef72, useState as useState92 } from "react";
@@ -30903,15 +30957,19 @@ var premountSchema2 = {
30903
30957
  description: "Premount For",
30904
30958
  min: 0,
30905
30959
  step: 1,
30906
- hiddenFromList: false
30960
+ hiddenFromList: false,
30961
+ keyframable: false
30907
30962
  },
30908
30963
  postmountFor: {
30909
30964
  type: "number",
30910
30965
  default: 0,
30911
30966
  min: 0,
30912
30967
  step: 1,
30913
- hiddenFromList: true
30914
- },
30968
+ hiddenFromList: true,
30969
+ keyframable: false
30970
+ }
30971
+ };
30972
+ var premountStyleSchema2 = {
30915
30973
  styleWhilePremounted: {
30916
30974
  type: "hidden"
30917
30975
  },
@@ -30919,9 +30977,13 @@ var premountSchema2 = {
30919
30977
  type: "hidden"
30920
30978
  }
30921
30979
  };
30980
+ var sequencePremountSchema2 = {
30981
+ ...premountSchema2,
30982
+ ...premountStyleSchema2
30983
+ };
30922
30984
  var sequenceStyleSchema2 = {
30923
30985
  ...transformSchema2,
30924
- ...premountSchema2
30986
+ ...sequencePremountSchema2
30925
30987
  };
30926
30988
  var hiddenField2 = {
30927
30989
  type: "boolean",
@@ -32134,7 +32196,7 @@ class ThumbnailEmitter {
32134
32196
  };
32135
32197
  }
32136
32198
  var useBufferStateEmitter = (emitter) => {
32137
- const bufferManager = useContext46(Internals.BufferingContextReact);
32199
+ const bufferManager = useContext47(Internals.BufferingContextReact);
32138
32200
  if (!bufferManager) {
32139
32201
  throw new Error("BufferingContextReact not found");
32140
32202
  }
@@ -32348,7 +32410,7 @@ var usePlayer = () => {
32348
32410
  const isBuffering = useCallback39(() => {
32349
32411
  return buffering.current;
32350
32412
  }, [buffering]);
32351
- const returnValue = useMemo54(() => {
32413
+ const returnValue = useMemo55(() => {
32352
32414
  return {
32353
32415
  frameBack,
32354
32416
  frameForward,
@@ -32592,11 +32654,11 @@ var usePlayback = ({
32592
32654
  const frame = Internals.Timeline.useTimelinePosition();
32593
32655
  const { playing, pause, emitter, isPlaying } = usePlayer();
32594
32656
  const setFrame = Internals.Timeline.useTimelineSetFrame();
32595
- const sharedAudioContext = useContext47(Internals.SharedAudioContext);
32657
+ const sharedAudioContext = useContext42(Internals.SharedAudioContext);
32596
32658
  const logLevel = Internals.useLogLevel();
32597
32659
  const isBackgroundedRef = useIsBackgrounded();
32598
32660
  const lastTimeUpdateTimestamp = useRef47(0);
32599
- const context = useContext47(Internals.BufferingContextReact);
32661
+ const context = useContext42(Internals.BufferingContextReact);
32600
32662
  if (!context) {
32601
32663
  throw new Error("Missing the buffering context. Most likely you have a Remotion version mismatch.");
32602
32664
  }
@@ -33194,7 +33256,7 @@ var MediaVolumeSlider = ({ displayVerticalVolumeSlider, renderMuteButton, render
33194
33256
  }
33195
33257
  setPlayerMuted((mute) => !mute);
33196
33258
  }, [isVolume0, setPlayerMuted, setMediaVolume]);
33197
- const parentDivStyle = useMemo410(() => {
33259
+ const parentDivStyle = useMemo42(() => {
33198
33260
  return {
33199
33261
  display: "inline-flex",
33200
33262
  background: "none",
@@ -33205,7 +33267,7 @@ var MediaVolumeSlider = ({ displayVerticalVolumeSlider, renderMuteButton, render
33205
33267
  ...displayVerticalVolumeSlider && { position: "relative" }
33206
33268
  };
33207
33269
  }, [displayVerticalVolumeSlider]);
33208
- const volumeContainer = useMemo410(() => {
33270
+ const volumeContainer = useMemo42(() => {
33209
33271
  return {
33210
33272
  display: "inline",
33211
33273
  width: ICON_SIZE2,
@@ -33230,10 +33292,10 @@ var MediaVolumeSlider = ({ displayVerticalVolumeSlider, renderMuteButton, render
33230
33292
  children: isMutedOrZero ? /* @__PURE__ */ jsx84(VolumeOffIcon, {}) : /* @__PURE__ */ jsx84(VolumeOnIcon, {})
33231
33293
  });
33232
33294
  }, [onBlur, onClick, volumeContainer]);
33233
- const muteButton = useMemo410(() => {
33295
+ const muteButton = useMemo42(() => {
33234
33296
  return renderMuteButton ? renderMuteButton({ muted: playerMuted, volume: mediaVolume }) : renderDefaultMuteButton({ muted: playerMuted, volume: mediaVolume });
33235
33297
  }, [playerMuted, mediaVolume, renderDefaultMuteButton, renderMuteButton]);
33236
- const volumeSlider = useMemo410(() => {
33298
+ const volumeSlider = useMemo42(() => {
33237
33299
  return (focused || hover) && !playerMuted && !Internals.isIosSafari() ? (renderVolumeSlider ?? renderDefaultVolumeSlider)({
33238
33300
  isVertical: displayVerticalVolumeSlider,
33239
33301
  volume: mediaVolume,
@@ -33321,7 +33383,7 @@ var PlaybackrateOption = ({ rate, onSelect, selectedRate, keyboardSelectedRate }
33321
33383
  setHovered(false);
33322
33384
  }, []);
33323
33385
  const isFocused = keyboardSelectedRate === rate;
33324
- const actualStyle = useMemo55(() => {
33386
+ const actualStyle = useMemo56(() => {
33325
33387
  return {
33326
33388
  ...rateDiv,
33327
33389
  backgroundColor: hovered || isFocused ? "#eee" : "transparent"
@@ -33388,7 +33450,7 @@ var PlaybackPopup = ({ setIsComponentVisible, playbackRates, canvasSize }) => {
33388
33450
  setPlaybackRate(rate);
33389
33451
  setIsComponentVisible(false);
33390
33452
  }, [setIsComponentVisible, setPlaybackRate]);
33391
- const playbackPopup = useMemo55(() => {
33453
+ const playbackPopup = useMemo56(() => {
33392
33454
  return {
33393
33455
  position: "absolute",
33394
33456
  right: 0,
@@ -35289,7 +35351,7 @@ var Thumbnail = forward2(ThumbnailFn);
35289
35351
  import {
35290
35352
  useCallback as useCallback55,
35291
35353
  useEffect as useEffect57,
35292
- useMemo as useMemo68,
35354
+ useMemo as useMemo69,
35293
35355
  useRef as useRef59,
35294
35356
  useState as useState56
35295
35357
  } from "react";
@@ -36040,7 +36102,7 @@ var UNDERLAY_RED = curriedTransparentize$1(0.9, RED);
36040
36102
  var BLUE_TEXT = curriedDarken$1(0.3, "#42e9f5");
36041
36103
 
36042
36104
  // src/components/homepage/layout/use-color-mode.tsx
36043
- import React58, { useContext as useContext48, useMemo as useMemo56 } from "react";
36105
+ import React58, { useContext as useContext48, useMemo as useMemo57 } from "react";
36044
36106
  import { jsx as jsx60 } from "react/jsx-runtime";
36045
36107
  var Context = React58.createContext(undefined);
36046
36108
  var ColorModeProvider = ({
@@ -36048,7 +36110,7 @@ var ColorModeProvider = ({
36048
36110
  colorMode,
36049
36111
  setColorMode
36050
36112
  }) => {
36051
- const value = useMemo56(() => {
36113
+ const value = useMemo57(() => {
36052
36114
  return { colorMode, setColorMode };
36053
36115
  }, [colorMode, setColorMode]);
36054
36116
  return /* @__PURE__ */ jsx60(Context.Provider, {
@@ -36066,14 +36128,14 @@ function useColorMode() {
36066
36128
 
36067
36129
  // ../media/dist/esm/index.mjs
36068
36130
  import { useMemo as useMemo312, useState as useState312 } from "react";
36069
- import { useContext as useContext212, useEffect as useEffect43, useMemo as useMemo58, useRef as useRef50, useState as useState41 } from "react";
36131
+ import { useContext as useContext212, useEffect as useEffect43, useMemo as useMemo59, useRef as useRef50, useState as useState41 } from "react";
36070
36132
  import {
36071
36133
  AudioBufferSink,
36072
36134
  InputDisposedError
36073
36135
  } from "mediabunny";
36074
36136
  import { ALL_FORMATS, Input as Input2, UrlSource } from "mediabunny";
36075
36137
  import { CanvasSink } from "mediabunny";
36076
- import { useContext as useContext50, useLayoutEffect as useLayoutEffect19 } from "react";
36138
+ import { useContext as useContext49, useLayoutEffect as useLayoutEffect19 } from "react";
36077
36139
  import { jsx as jsx61 } from "react/jsx-runtime";
36078
36140
  import { useContext as useContext312, useLayoutEffect as useLayoutEffect24, useMemo as useMemo213, useState as useState210 } from "react";
36079
36141
  import React211 from "react";
@@ -36092,10 +36154,10 @@ import { jsx as jsx316 } from "react/jsx-runtime";
36092
36154
  import React63, { useMemo as useMemo63, useState as useState63 } from "react";
36093
36155
  import {
36094
36156
  useCallback as useCallback40,
36095
- useContext as useContext49,
36157
+ useContext as useContext410,
36096
36158
  useEffect as useEffect212,
36097
36159
  useLayoutEffect as useLayoutEffect34,
36098
- useMemo as useMemo412,
36160
+ useMemo as useMemo410,
36099
36161
  useRef as useRef213,
36100
36162
  useState as useState43
36101
36163
  } from "react";
@@ -36103,7 +36165,7 @@ import { jsx as jsx412 } from "react/jsx-runtime";
36103
36165
  import {
36104
36166
  useContext as useContext53,
36105
36167
  useLayoutEffect as useLayoutEffect43,
36106
- useMemo as useMemo57,
36168
+ useMemo as useMemo58,
36107
36169
  useRef as useRef312,
36108
36170
  useState as useState53
36109
36171
  } from "react";
@@ -38250,7 +38312,7 @@ var useCommonEffects = ({
38250
38312
  logLevel,
38251
38313
  label: label3
38252
38314
  }) => {
38253
- const sharedAudioContext = useContext50(Internals.SharedAudioContext);
38315
+ const sharedAudioContext = useContext49(Internals.SharedAudioContext);
38254
38316
  useLayoutEffect19(() => {
38255
38317
  const mediaPlayer = mediaPlayerRef.current;
38256
38318
  if (!mediaPlayer)
@@ -38403,7 +38465,8 @@ var AudioForPreviewAssertedShowing = ({
38403
38465
  onError,
38404
38466
  credentials,
38405
38467
  requestInit,
38406
- setMediaDurationInSeconds
38468
+ setMediaDurationInSeconds,
38469
+ style: style2
38407
38470
  }) => {
38408
38471
  const videoConfig = useUnsafeVideoConfig2();
38409
38472
  const frame = useCurrentFrame();
@@ -38633,6 +38696,7 @@ var AudioForPreviewAssertedShowing = ({
38633
38696
  name,
38634
38697
  loop,
38635
38698
  showInTimeline,
38699
+ style: style2 ?? undefined,
38636
38700
  stack: stack ?? undefined,
38637
38701
  toneFrequency,
38638
38702
  audioStreamIndex,
@@ -38663,14 +38727,15 @@ var AudioForPreview2 = ({
38663
38727
  onError,
38664
38728
  credentials,
38665
38729
  requestInit,
38666
- setMediaDurationInSeconds
38730
+ setMediaDurationInSeconds,
38731
+ style: style2
38667
38732
  }) => {
38668
38733
  const preloadedSrc = usePreload2(src);
38669
38734
  const defaultLogLevel = Internals.useLogLevel();
38670
38735
  const frame = useCurrentFrame();
38671
38736
  const videoConfig = useVideoConfig();
38672
38737
  const currentTime = frame / videoConfig.fps;
38673
- const showShow = useMemo58(() => {
38738
+ const showShow = useMemo59(() => {
38674
38739
  return getTimeInSeconds({
38675
38740
  unloopedTimeInSeconds: currentTime,
38676
38741
  playbackRate,
@@ -38717,7 +38782,8 @@ var AudioForPreview2 = ({
38717
38782
  credentials,
38718
38783
  requestInit,
38719
38784
  fallbackHtml5AudioProps,
38720
- setMediaDurationInSeconds
38785
+ setMediaDurationInSeconds,
38786
+ style: style2
38721
38787
  });
38722
38788
  };
38723
38789
  var makeAudioCache = () => {
@@ -40627,7 +40693,7 @@ var AudioForRendering2 = ({
40627
40693
  throw new TypeError("No `src` was passed to <Audio>.");
40628
40694
  }
40629
40695
  const { fps } = videoConfig;
40630
- const { delayRender: delayRender2, continueRender } = useDelayRender();
40696
+ const { delayRender, continueRender } = useDelayRender();
40631
40697
  const [replaceWithHtml5Audio, setReplaceWithHtml5Audio] = useState210(false);
40632
40698
  const [initialRequestInit] = useState210(requestInit);
40633
40699
  const sequenceContext = useContext312(Internals.SequenceContext);
@@ -40657,7 +40723,7 @@ var AudioForRendering2 = ({
40657
40723
  if (replaceWithHtml5Audio) {
40658
40724
  return;
40659
40725
  }
40660
- const newHandle = delayRender2(`Extracting audio for frame ${frame}`, {
40726
+ const newHandle = delayRender(`Extracting audio for frame ${frame}`, {
40661
40727
  retries: delayRenderRetries ?? undefined,
40662
40728
  timeoutInMilliseconds: delayRenderTimeoutInMilliseconds ?? undefined
40663
40729
  });
@@ -40749,7 +40815,7 @@ var AudioForRendering2 = ({
40749
40815
  }, [
40750
40816
  absoluteFrame,
40751
40817
  continueRender,
40752
- delayRender2,
40818
+ delayRender,
40753
40819
  delayRenderRetries,
40754
40820
  delayRenderTimeoutInMilliseconds,
40755
40821
  disallowFallbackToHtml5Audio,
@@ -40810,6 +40876,7 @@ var audioSchema = {
40810
40876
  keyframable: false
40811
40877
  },
40812
40878
  ...Internals.baseSchema,
40879
+ ...Internals.premountSchema,
40813
40880
  volume: {
40814
40881
  type: "number",
40815
40882
  min: 0,
@@ -40840,6 +40907,9 @@ var AudioInner = (props) => {
40840
40907
  durationInFrames,
40841
40908
  freeze,
40842
40909
  hidden,
40910
+ style: style2,
40911
+ premountFor,
40912
+ postmountFor,
40843
40913
  ...otherProps
40844
40914
  } = props;
40845
40915
  const environment = useRemotionEnvironment();
@@ -40882,6 +40952,24 @@ var AudioInner = (props) => {
40882
40952
  type: "audio",
40883
40953
  data: basicInfo
40884
40954
  }), [basicInfo]);
40955
+ const {
40956
+ effectivePostmountFor,
40957
+ effectivePremountFor,
40958
+ freezeFrame,
40959
+ isPremountingOrPostmounting,
40960
+ postmountingActive,
40961
+ premountingActive,
40962
+ premountingStyle
40963
+ } = Internals.usePremounting({
40964
+ from: from ?? 0,
40965
+ durationInFrames: basicInfo.duration,
40966
+ premountFor: premountFor ?? null,
40967
+ postmountFor: postmountFor ?? null,
40968
+ style: style2 ?? null,
40969
+ styleWhilePremounted: null,
40970
+ styleWhilePostmounted: null,
40971
+ hideWhilePremounted: "display-none"
40972
+ });
40885
40973
  if (typeof props.src !== "string") {
40886
40974
  throw new TypeError(`The \`<Audio>\` tag requires a string for \`src\`, but got ${JSON.stringify(props.src)} instead.`);
40887
40975
  }
@@ -40889,26 +40977,36 @@ var AudioInner = (props) => {
40889
40977
  if (sequenceDurationInFrames === 0) {
40890
40978
  return null;
40891
40979
  }
40892
- return /* @__PURE__ */ jsx316(Sequence, {
40893
- layout: "none",
40894
- from: from ?? 0,
40895
- durationInFrames: basicInfo.duration,
40896
- freeze,
40897
- _remotionInternalStack: stack,
40898
- _remotionInternalIsMedia: isMedia,
40899
- name: name ?? "<Audio>",
40900
- _remotionInternalDocumentationLink: name === undefined ? "https://www.remotion.dev/docs/media/audio" : undefined,
40901
- controls,
40902
- _remotionInternalLoopDisplay: loopDisplay,
40903
- showInTimeline: showInTimeline ?? true,
40904
- hidden,
40905
- children: environment.isRendering ? /* @__PURE__ */ jsx316(AudioForRendering2, {
40906
- ...otherProps
40907
- }) : /* @__PURE__ */ jsx316(AudioForPreview2, {
40908
- name,
40909
- ...otherProps,
40910
- stack: stack ?? null,
40911
- setMediaDurationInSeconds
40980
+ return /* @__PURE__ */ jsx316(Freeze, {
40981
+ frame: freezeFrame,
40982
+ active: isPremountingOrPostmounting,
40983
+ children: /* @__PURE__ */ jsx316(Sequence, {
40984
+ layout: "none",
40985
+ from: from ?? 0,
40986
+ durationInFrames: basicInfo.duration,
40987
+ freeze,
40988
+ _remotionInternalStack: stack,
40989
+ _remotionInternalIsMedia: isMedia,
40990
+ _remotionInternalPremountDisplay: effectivePremountFor || null,
40991
+ _remotionInternalPostmountDisplay: effectivePostmountFor || null,
40992
+ _remotionInternalIsPremounting: premountingActive,
40993
+ _remotionInternalIsPostmounting: postmountingActive,
40994
+ name: name ?? "<Audio>",
40995
+ _remotionInternalDocumentationLink: name === undefined ? "https://www.remotion.dev/docs/media/audio" : undefined,
40996
+ controls,
40997
+ _remotionInternalLoopDisplay: loopDisplay,
40998
+ showInTimeline: showInTimeline ?? true,
40999
+ hidden,
41000
+ children: environment.isRendering ? /* @__PURE__ */ jsx316(AudioForRendering2, {
41001
+ ...otherProps,
41002
+ style: premountingStyle ?? undefined
41003
+ }) : /* @__PURE__ */ jsx316(AudioForPreview2, {
41004
+ name,
41005
+ ...otherProps,
41006
+ style: premountingStyle,
41007
+ stack: stack ?? null,
41008
+ setMediaDurationInSeconds
41009
+ })
40912
41010
  })
40913
41011
  });
40914
41012
  };
@@ -41042,7 +41140,7 @@ var VideoForPreviewAssertedShowing = ({
41042
41140
  const [shouldFallbackToNativeVideo, setShouldFallbackToNativeVideo] = useState43(false);
41043
41141
  const [playing] = Timeline2.usePlayingState();
41044
41142
  const { playbackRate: globalPlaybackRate } = Internals.usePlaybackRate();
41045
- const sharedAudioContext = useContext49(SharedAudioContext22);
41143
+ const sharedAudioContext = useContext410(SharedAudioContext22);
41046
41144
  const buffer = useBufferState();
41047
41145
  const canvasRefCallback = useCallback40((canvas) => {
41048
41146
  canvasRef.current = canvas;
@@ -41070,7 +41168,7 @@ var VideoForPreviewAssertedShowing = ({
41070
41168
  onErrorRef.current = onError;
41071
41169
  const effectChainStateRef = useRef213(effectChainState);
41072
41170
  effectChainStateRef.current = effectChainState;
41073
- const parentSequence = useContext49(SequenceContext22);
41171
+ const parentSequence = useContext410(SequenceContext22);
41074
41172
  const isPremounting = Boolean(parentSequence?.premounting);
41075
41173
  const isPostmounting = Boolean(parentSequence?.postmounting);
41076
41174
  const sequenceOffset = (parentSequence?.absoluteFrom ?? 0) / videoConfig.fps;
@@ -41078,7 +41176,7 @@ var VideoForPreviewAssertedShowing = ({
41078
41176
  const currentTimeRef = useRef213(currentTime);
41079
41177
  currentTimeRef.current = currentTime;
41080
41178
  const preloadedSrc = usePreload22(src);
41081
- const buffering = useContext49(Internals.BufferingContextReact);
41179
+ const buffering = useContext410(Internals.BufferingContextReact);
41082
41180
  if (!buffering) {
41083
41181
  throw new Error("useMediaPlayback must be used inside a <BufferingContext>");
41084
41182
  }
@@ -41265,7 +41363,7 @@ var VideoForPreviewAssertedShowing = ({
41265
41363
  setMediaDurationInSeconds
41266
41364
  ]);
41267
41365
  warnAboutObjectFitInStyleOrClassName({ style: style2, className: className2, logLevel });
41268
- const classNameValue = useMemo412(() => {
41366
+ const classNameValue = useMemo410(() => {
41269
41367
  return [Internals.OBJECTFIT_CONTAIN_CLASS_NAME, className2].filter(Internals.truthy).join(" ");
41270
41368
  }, [className2]);
41271
41369
  useCommonEffects({
@@ -41312,7 +41410,7 @@ var VideoForPreviewAssertedShowing = ({
41312
41410
  }
41313
41411
  mediaPlayer.redrawVideoEffects().catch(() => {});
41314
41412
  }, [effects, mediaPlayerReady, mediaPlayerRef]);
41315
- const actualStyle = useMemo412(() => {
41413
+ const actualStyle = useMemo410(() => {
41316
41414
  return {
41317
41415
  ...style2,
41318
41416
  objectFit: objectFitProp
@@ -41352,7 +41450,7 @@ var VideoForPreview2 = (props) => {
41352
41450
  const frame = useCurrentFrame();
41353
41451
  const videoConfig = useVideoConfig();
41354
41452
  const currentTime = frame / videoConfig.fps;
41355
- const showShow = useMemo412(() => {
41453
+ const showShow = useMemo410(() => {
41356
41454
  return getTimeInSeconds({
41357
41455
  unloopedTimeInSeconds: currentTime,
41358
41456
  playbackRate: props.playbackRate,
@@ -41417,14 +41515,14 @@ var VideoForRendering2 = ({
41417
41515
  const { registerRenderAsset, unregisterRenderAsset } = useContext53(Internals.RenderAssetManager);
41418
41516
  const startsAt = Internals.useMediaStartsAt();
41419
41517
  const sequenceContext = useContext53(Internals.SequenceContext);
41420
- const id = useMemo57(() => `media-video-${random(src)}-${sequenceContext?.cumulatedFrom}-${sequenceContext?.relativeFrom}-${sequenceContext?.durationInFrames}`, [
41518
+ const id = useMemo58(() => `media-video-${random(src)}-${sequenceContext?.cumulatedFrom}-${sequenceContext?.relativeFrom}-${sequenceContext?.durationInFrames}`, [
41421
41519
  src,
41422
41520
  sequenceContext?.cumulatedFrom,
41423
41521
  sequenceContext?.relativeFrom,
41424
41522
  sequenceContext?.durationInFrames
41425
41523
  ]);
41426
41524
  const environment = useRemotionEnvironment();
41427
- const { delayRender: delayRender2, continueRender, cancelRender: cancelRender3 } = useDelayRender();
41525
+ const { delayRender, continueRender, cancelRender: cancelRender3 } = useDelayRender();
41428
41526
  const canvasRef = useRef312(null);
41429
41527
  const [replaceWithOffthreadVideo, setReplaceWithOffthreadVideo] = useState53(false);
41430
41528
  const [initialRequestInit] = useState53(requestInit);
@@ -41448,7 +41546,7 @@ var VideoForRendering2 = ({
41448
41546
  }
41449
41547
  const timestamp = frame / fps;
41450
41548
  const durationInSeconds = 1 / fps;
41451
- const newHandle = delayRender2(`Extracting frame at time ${timestamp} from ${src}`, {
41549
+ const newHandle = delayRender(`Extracting frame at time ${timestamp} from ${src}`, {
41452
41550
  retries: delayRenderRetries ?? undefined,
41453
41551
  timeoutInMilliseconds: delayRenderTimeoutInMilliseconds ?? undefined
41454
41552
  });
@@ -41600,7 +41698,7 @@ var VideoForRendering2 = ({
41600
41698
  }, [
41601
41699
  absoluteFrame,
41602
41700
  continueRender,
41603
- delayRender2,
41701
+ delayRender,
41604
41702
  delayRenderRetries,
41605
41703
  delayRenderTimeoutInMilliseconds,
41606
41704
  environment.isClientSideRendering,
@@ -41636,10 +41734,10 @@ var VideoForRendering2 = ({
41636
41734
  initialRequestInit
41637
41735
  ]);
41638
41736
  warnAboutObjectFitInStyleOrClassName({ style: style2, className: className2, logLevel });
41639
- const classNameValue = useMemo57(() => {
41737
+ const classNameValue = useMemo58(() => {
41640
41738
  return [Internals.OBJECTFIT_CONTAIN_CLASS_NAME, className2].filter(Internals.truthy).join(" ");
41641
41739
  }, [className2]);
41642
- const styleWithObjectFit = useMemo57(() => {
41740
+ const styleWithObjectFit = useMemo58(() => {
41643
41741
  return {
41644
41742
  ...style2,
41645
41743
  objectFit: objectFitProp
@@ -41718,6 +41816,8 @@ var videoSchema = {
41718
41816
  keyframable: false
41719
41817
  },
41720
41818
  ...Internals.baseSchema,
41819
+ ...Internals.premountSchema,
41820
+ ...Internals.premountStyleSchema,
41721
41821
  volume: {
41722
41822
  type: "number",
41723
41823
  min: 0,
@@ -41888,6 +41988,10 @@ var VideoInner = ({
41888
41988
  from,
41889
41989
  freeze,
41890
41990
  hidden,
41991
+ premountFor,
41992
+ postmountFor,
41993
+ styleWhilePremounted,
41994
+ styleWhilePostmounted,
41891
41995
  ...props
41892
41996
  }) => {
41893
41997
  const fallbackLogLevel = Internals.useLogLevel();
@@ -41943,57 +42047,83 @@ var VideoInner = ({
41943
42047
  });
41944
42048
  const memoizedEffectDefinitions = Internals.useMemoizedEffectDefinitions(effects ?? []);
41945
42049
  const refForOutline = React63.useRef(null);
42050
+ const {
42051
+ effectivePostmountFor,
42052
+ effectivePremountFor,
42053
+ freezeFrame,
42054
+ isPremountingOrPostmounting,
42055
+ postmountingActive,
42056
+ premountingActive,
42057
+ premountingStyle
42058
+ } = Internals.usePremounting({
42059
+ from: from ?? 0,
42060
+ durationInFrames: videoSequenceDuration ?? Infinity,
42061
+ premountFor: premountFor ?? null,
42062
+ postmountFor: postmountFor ?? null,
42063
+ style: style2 ?? null,
42064
+ styleWhilePremounted: styleWhilePremounted ?? null,
42065
+ styleWhilePostmounted: styleWhilePostmounted ?? null,
42066
+ hideWhilePremounted: "display-none"
42067
+ });
41946
42068
  if (sequenceDurationInFrames === 0) {
41947
42069
  return null;
41948
42070
  }
41949
- return /* @__PURE__ */ jsx65(Sequence, {
41950
- layout: "none",
41951
- from: from ?? 0,
41952
- durationInFrames: videoSequenceDuration,
41953
- freeze,
41954
- _remotionInternalStack: stack,
41955
- _remotionInternalIsMedia: isMedia,
41956
- name: name ?? "<Video>",
41957
- _remotionInternalDocumentationLink: name === undefined ? "https://www.remotion.dev/docs/media/video" : undefined,
41958
- controls,
41959
- _remotionInternalLoopDisplay: loopDisplay,
41960
- _remotionInternalEffects: memoizedEffectDefinitions,
41961
- outlineRef: refForOutline,
41962
- showInTimeline: showInTimeline ?? true,
41963
- hidden,
41964
- children: /* @__PURE__ */ jsx65(InnerVideo, {
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,
42071
+ return /* @__PURE__ */ jsx65(Freeze, {
42072
+ frame: freezeFrame,
42073
+ active: isPremountingOrPostmounting,
42074
+ children: /* @__PURE__ */ jsx65(Sequence, {
42075
+ layout: "none",
42076
+ from: from ?? 0,
42077
+ durationInFrames: videoSequenceDuration,
42078
+ freeze,
42079
+ _remotionInternalStack: stack,
42080
+ _remotionInternalIsMedia: isMedia,
42081
+ _remotionInternalPremountDisplay: effectivePremountFor || null,
42082
+ _remotionInternalPostmountDisplay: effectivePostmountFor || null,
42083
+ _remotionInternalIsPremounting: premountingActive,
42084
+ _remotionInternalIsPostmounting: postmountingActive,
42085
+ name: name ?? "<Video>",
42086
+ _remotionInternalDocumentationLink: name === undefined ? "https://www.remotion.dev/docs/media/video" : undefined,
41991
42087
  controls,
41992
- objectFit: objectFit ?? "contain",
41993
- _experimentalInitiallyDrawCachedFrame: _experimentalInitiallyDrawCachedFrame ?? false,
41994
- effects: memoizedEffects,
41995
- setMediaDurationInSeconds,
41996
- refForOutline
42088
+ _remotionInternalLoopDisplay: loopDisplay,
42089
+ _remotionInternalEffects: memoizedEffectDefinitions,
42090
+ outlineRef: refForOutline,
42091
+ showInTimeline: showInTimeline ?? true,
42092
+ hidden,
42093
+ children: /* @__PURE__ */ jsx65(InnerVideo, {
42094
+ ...props,
42095
+ audioStreamIndex: audioStreamIndex ?? 0,
42096
+ className: className2,
42097
+ delayRenderRetries: delayRenderRetries ?? null,
42098
+ delayRenderTimeoutInMilliseconds: delayRenderTimeoutInMilliseconds ?? null,
42099
+ disallowFallbackToOffthreadVideo: disallowFallbackToOffthreadVideo ?? false,
42100
+ fallbackOffthreadVideoProps: fallbackOffthreadVideoProps ?? {},
42101
+ logLevel: logLevel ?? fallbackLogLevel,
42102
+ loop: loop ?? false,
42103
+ loopVolumeCurveBehavior: loopVolumeCurveBehavior ?? "repeat",
42104
+ muted: muted ?? false,
42105
+ onVideoFrame,
42106
+ playbackRate: playbackRate ?? 1,
42107
+ showInTimeline: showInTimeline ?? true,
42108
+ src,
42109
+ style: premountingStyle ?? {},
42110
+ trimAfter,
42111
+ trimBefore,
42112
+ volume: volume ?? 1,
42113
+ toneFrequency: toneFrequency ?? 1,
42114
+ stack,
42115
+ debugOverlay: debugOverlay ?? false,
42116
+ headless: headless ?? false,
42117
+ onError,
42118
+ credentials,
42119
+ requestInit,
42120
+ controls,
42121
+ objectFit: objectFit ?? "contain",
42122
+ _experimentalInitiallyDrawCachedFrame: _experimentalInitiallyDrawCachedFrame ?? false,
42123
+ effects: memoizedEffects,
42124
+ setMediaDurationInSeconds,
42125
+ refForOutline
42126
+ })
41997
42127
  })
41998
42128
  });
41999
42129
  };
@@ -42006,7 +42136,7 @@ var Video = Interactive.withSchema({
42006
42136
  });
42007
42137
 
42008
42138
  // src/components/homepage/Demo/Comp.tsx
42009
- import { useCallback as useCallback47, useEffect as useEffect49, useMemo as useMemo61, useState as useState48 } from "react";
42139
+ import { useCallback as useCallback47, useEffect as useEffect49, useMemo as useMemo64, useState as useState48 } from "react";
42010
42140
 
42011
42141
  // src/components/homepage/Demo/Cards.tsx
42012
42142
  import {
@@ -42461,8 +42591,8 @@ var Lottie = ({
42461
42591
  const containerRef = useRef53(null);
42462
42592
  const onAnimationLoadedRef = useRef53(onAnimationLoaded);
42463
42593
  onAnimationLoadedRef.current = onAnimationLoaded;
42464
- const { delayRender: delayRender2, continueRender } = useDelayRender();
42465
- const [handle] = useState44(() => delayRender2("Waiting for Lottie animation to load"));
42594
+ const { delayRender, continueRender } = useDelayRender();
42595
+ const [handle] = useState44(() => delayRender("Waiting for Lottie animation to load"));
42466
42596
  useEffect45(() => {
42467
42597
  return () => {
42468
42598
  continueRender(handle);
@@ -42543,13 +42673,13 @@ var Lottie = ({
42543
42673
  if (currentHref && currentHref === img.href.baseVal) {
42544
42674
  return;
42545
42675
  }
42546
- const imgHandle = delayRender2(`Waiting for lottie image with src="${img.href.baseVal}" to load`);
42676
+ const imgHandle = delayRender(`Waiting for lottie image with src="${img.href.baseVal}" to load`);
42547
42677
  img.addEventListener("load", () => {
42548
42678
  continueRender(imgHandle);
42549
42679
  }, { once: true });
42550
42680
  img.setAttributeNS("http://www.w3.org/1999/xlink", "xlink:href", img.href.baseVal);
42551
42681
  });
42552
- }, [direction, frame, loop, playbackRate, delayRender2, continueRender]);
42682
+ }, [direction, frame, loop, playbackRate, delayRender, continueRender]);
42553
42683
  return /* @__PURE__ */ jsx70("div", {
42554
42684
  ref: containerRef,
42555
42685
  className: className2,
@@ -42558,15 +42688,15 @@ var Lottie = ({
42558
42688
  };
42559
42689
 
42560
42690
  // src/components/homepage/Demo/DisplayedEmoji.tsx
42561
- import { useEffect as useEffect46, useMemo as useMemo59, useState as useState46 } from "react";
42691
+ import { useEffect as useEffect46, useMemo as useMemo60, useState as useState46 } from "react";
42562
42692
  import { jsx as jsx71 } from "react/jsx-runtime";
42563
42693
  var DisplayedEmoji = ({ emoji }) => {
42564
42694
  const [data, setData] = useState46(null);
42565
42695
  const { durationInFrames, fps } = useVideoConfig();
42566
42696
  const [browser, setBrowser] = useState46(typeof document !== "undefined");
42567
- const { delayRender: delayRender2, continueRender, cancelRender: cancelRender2 } = useDelayRender();
42697
+ const { delayRender, continueRender, cancelRender: cancelRender2 } = useDelayRender();
42568
42698
  const { isRendering } = useRemotionEnvironment();
42569
- const src = useMemo59(() => {
42699
+ const src = useMemo60(() => {
42570
42700
  if (emoji === "melting") {
42571
42701
  return "https://fonts.gstatic.com/s/e/notoemoji/latest/1fae0/lottie.json";
42572
42702
  }
@@ -42578,7 +42708,7 @@ var DisplayedEmoji = ({ emoji }) => {
42578
42708
  }
42579
42709
  throw new Error("Unknown emoji");
42580
42710
  }, [emoji]);
42581
- const [handle] = useState46(() => delayRender2("Loading emojis!"));
42711
+ const [handle] = useState46(() => delayRender("Loading emojis!"));
42582
42712
  useEffect46(() => {
42583
42713
  fetch(src).then((res) => res.json()).then((json) => {
42584
42714
  setData({
@@ -42997,7 +43127,7 @@ var Temperature = ({ theme, city, temperatureInCelsius }) => {
42997
43127
  };
42998
43128
 
42999
43129
  // src/components/homepage/Demo/TrendingRepos.tsx
43000
- import { useMemo as useMemo60 } from "react";
43130
+ import { useMemo as useMemo61 } from "react";
43001
43131
  import { jsx as jsx81, jsxs as jsxs28 } from "react/jsx-runtime";
43002
43132
  var TrendingRepoItem = ({ repo, theme, number }) => {
43003
43133
  const frame = useCurrentFrame();
@@ -43010,7 +43140,7 @@ var TrendingRepoItem = ({ repo, theme, number }) => {
43010
43140
  },
43011
43141
  delay: number * 10 + 20
43012
43142
  });
43013
- const item = useMemo60(() => {
43143
+ const item = useMemo61(() => {
43014
43144
  return {
43015
43145
  lineHeight: 1.1,
43016
43146
  fontFamily: "GTPlanar",
@@ -43217,7 +43347,7 @@ var HomepageVideoComp = ({
43217
43347
  setRerenders(rerenders + 1);
43218
43348
  updateCardOrder(newIndices);
43219
43349
  }, [rerenders, updateCardOrder]);
43220
- const emoji = useMemo61(() => {
43350
+ const emoji = useMemo64(() => {
43221
43351
  if ((emojiIndex + 1e4 * 3) % 3 === 1) {
43222
43352
  return "melting";
43223
43353
  }
@@ -43226,7 +43356,7 @@ var HomepageVideoComp = ({
43226
43356
  }
43227
43357
  return "partying-face";
43228
43358
  }, [emojiIndex]);
43229
- const audioSrc = useMemo61(() => {
43359
+ const audioSrc = useMemo64(() => {
43230
43360
  if (emoji === "fire") {
43231
43361
  return fireAudio;
43232
43362
  }
@@ -43311,7 +43441,7 @@ import {
43311
43441
  import { BufferTarget, StreamTarget } from "mediabunny";
43312
43442
 
43313
43443
  // ../core/dist/esm/version.mjs
43314
- var VERSION2 = "4.0.494";
43444
+ var VERSION2 = "4.0.496";
43315
43445
 
43316
43446
  // ../web-renderer/dist/esm/index.mjs
43317
43447
  import { AudioSample, VideoSample } from "mediabunny";
@@ -44204,6 +44334,7 @@ function createScaffold({
44204
44334
  wrapper.style.inset = "0";
44205
44335
  wrapper.style.overflow = "hidden";
44206
44336
  wrapper.style.visibility = "hidden";
44337
+ wrapper.style.filter = "opacity(0)";
44207
44338
  wrapper.style.pointerEvents = "none";
44208
44339
  wrapper.style.zIndex = "-9999";
44209
44340
  const div = document.createElement("div");
@@ -44221,6 +44352,14 @@ function createScaffold({
44221
44352
  wrapper.appendChild(div);
44222
44353
  document.body.appendChild(wrapper);
44223
44354
  const htmlInCanvasContext = useHtmlInCanvas ? setupHtmlInCanvas({ wrapper, div, width: width2, height: height2 }) : null;
44355
+ const updateFallbackScaffoldVisibility = () => {
44356
+ if (htmlInCanvasContext) {
44357
+ return;
44358
+ }
44359
+ div.style.visibility = containsLayoutSubtreeCanvas(div) ? "visible" : "";
44360
+ };
44361
+ const fallbackScaffoldObserver = htmlInCanvasContext ? null : new MutationObserver(updateFallbackScaffoldVisibility);
44362
+ fallbackScaffoldObserver?.observe(div, { childList: true, subtree: true });
44224
44363
  const errorHolder = { error: null };
44225
44364
  const root = ReactDOM6.createRoot(div, {
44226
44365
  onUncaughtError: (err, errorInfo) => {
@@ -44311,12 +44450,14 @@ function createScaffold({
44311
44450
  })
44312
44451
  }));
44313
44452
  });
44453
+ updateFallbackScaffoldVisibility();
44314
44454
  return {
44315
44455
  delayRenderScope,
44316
44456
  div,
44317
44457
  errorHolder,
44318
44458
  htmlInCanvasContext,
44319
44459
  [Symbol.dispose]: () => {
44460
+ fallbackScaffoldObserver?.disconnect();
44320
44461
  root.unmount();
44321
44462
  if (htmlInCanvasContext) {
44322
44463
  teardownHtmlInCanvas({ htmlInCanvasContext, wrapper, div });
@@ -48535,7 +48676,7 @@ var Progress = ({ progress }) => {
48535
48676
  };
48536
48677
 
48537
48678
  // src/components/homepage/Demo/Spinner.tsx
48538
- import { useMemo as useMemo64 } from "react";
48679
+ import { useMemo as useMemo66 } from "react";
48539
48680
  import { jsx as jsx97, jsxs as jsxs34, Fragment as Fragment16 } from "react/jsx-runtime";
48540
48681
  var viewBox2 = 100;
48541
48682
  var lines2 = 8;
@@ -48543,7 +48684,7 @@ var className2 = "__remotion_spinner_line";
48543
48684
  var remotionSpinnerAnimation = "__remotion_spinner_animation";
48544
48685
  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
48686
  var Spinner2 = ({ size: size4, duration }) => {
48546
- const style2 = useMemo64(() => {
48687
+ const style2 = useMemo66(() => {
48547
48688
  return {
48548
48689
  width: size4,
48549
48690
  height: size4
@@ -48805,13 +48946,13 @@ var DragAndDropNudge = () => {
48805
48946
  };
48806
48947
 
48807
48948
  // src/components/homepage/Demo/PlayerSeekBar.tsx
48808
- import { useCallback as useCallback50, useEffect as useEffect51, useMemo as useMemo67, useRef as useRef57, useState as useState51 } from "react";
48949
+ import { useCallback as useCallback50, useEffect as useEffect51, useMemo as useMemo68, useRef as useRef57, useState as useState51 } from "react";
48809
48950
 
48810
48951
  // src/components/homepage/layout/use-el-size.ts
48811
- import { useCallback as useCallback49, useEffect as useEffect50, useMemo as useMemo66, useState as useState50 } from "react";
48952
+ import { useCallback as useCallback49, useEffect as useEffect50, useMemo as useMemo67, useState as useState50 } from "react";
48812
48953
  var useElementSize2 = (ref) => {
48813
48954
  const [size4, setSize] = useState50(null);
48814
- const observer = useMemo66(() => {
48955
+ const observer = useMemo67(() => {
48815
48956
  if (typeof ResizeObserver === "undefined") {
48816
48957
  return;
48817
48958
  }
@@ -49025,7 +49166,7 @@ var PlayerSeekBar2 = ({
49025
49166
  body.removeEventListener("pointerup", onPointerUp);
49026
49167
  };
49027
49168
  }, [dragging.dragging, onPointerMove, onPointerUp]);
49028
- const knobStyle = useMemo67(() => {
49169
+ const knobStyle = useMemo68(() => {
49029
49170
  return {
49030
49171
  height: KNOB_SIZE3,
49031
49172
  width: KNOB_SIZE3,
@@ -49039,7 +49180,7 @@ var PlayerSeekBar2 = ({
49039
49180
  transition: "opacity 0.s ease"
49040
49181
  };
49041
49182
  }, [barHovered, durationInFrames, frame, width2]);
49042
- const fillStyle = useMemo67(() => {
49183
+ const fillStyle = useMemo68(() => {
49043
49184
  return {
49044
49185
  height: BAR_HEIGHT3,
49045
49186
  backgroundColor: "var(--ifm-font-color-base)",
@@ -49048,7 +49189,7 @@ var PlayerSeekBar2 = ({
49048
49189
  borderRadius: BAR_HEIGHT3 / 2
49049
49190
  };
49050
49191
  }, [durationInFrames, frame, inFrame]);
49051
- const active = useMemo67(() => {
49192
+ const active = useMemo68(() => {
49052
49193
  return {
49053
49194
  height: BAR_HEIGHT3,
49054
49195
  backgroundColor: "var(--ifm-font-color-base)",
@@ -49462,7 +49603,7 @@ var Demo = () => {
49462
49603
  const updateCardOrder = useCallback55((newCardOrder) => {
49463
49604
  setCardOrder(newCardOrder);
49464
49605
  }, []);
49465
- const props = useMemo68(() => {
49606
+ const props = useMemo69(() => {
49466
49607
  return {
49467
49608
  theme: colorMode,
49468
49609
  onToggle: () => {