remotion 4.1.0-alpha1 → 4.1.0-alpha11

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.
Files changed (49) hide show
  1. package/dist/cjs/Composition.d.ts +26 -10
  2. package/dist/cjs/Composition.js +8 -18
  3. package/dist/cjs/CompositionManager.d.ts +11 -12
  4. package/dist/cjs/CompositionManagerContext.d.ts +4 -3
  5. package/dist/cjs/Img.d.ts +1 -1
  6. package/dist/cjs/Img.js +2 -2
  7. package/dist/cjs/NativeLayers.js +5 -4
  8. package/dist/cjs/RemotionRoot.js +6 -4
  9. package/dist/cjs/ResolveCompositionConfig.js +24 -7
  10. package/dist/cjs/Still.d.ts +1 -1
  11. package/dist/cjs/audio/AudioForDevelopment.js +1 -1
  12. package/dist/cjs/audio/shared-audio-tags.d.ts +1 -1
  13. package/dist/cjs/audio/shared-audio-tags.js +5 -1
  14. package/dist/cjs/config/input-props.d.ts +1 -1
  15. package/dist/cjs/config/input-props.js +2 -1
  16. package/dist/cjs/delay-render.js +22 -14
  17. package/dist/cjs/freeze.js +6 -2
  18. package/dist/cjs/index.d.ts +17 -7
  19. package/dist/cjs/index.js +1 -1
  20. package/dist/cjs/input-props-serialization.d.ts +15 -0
  21. package/dist/cjs/input-props-serialization.js +49 -0
  22. package/dist/cjs/internals.d.ts +80 -62
  23. package/dist/cjs/internals.js +13 -0
  24. package/dist/cjs/loop/index.js +1 -2
  25. package/dist/cjs/props-if-has-props.d.ts +2 -2
  26. package/dist/cjs/resolve-video-config.d.ts +3 -2
  27. package/dist/cjs/resolve-video-config.js +23 -33
  28. package/dist/cjs/series/index.js +2 -3
  29. package/dist/cjs/spring/index.js +1 -1
  30. package/dist/cjs/static-file.js +11 -2
  31. package/dist/cjs/timeline-position-state.d.ts +5 -3
  32. package/dist/cjs/timeline-position-state.js +25 -7
  33. package/dist/cjs/use-unsafe-video-config.js +2 -1
  34. package/dist/cjs/use-video.d.ts +1 -1
  35. package/dist/cjs/use-video.js +3 -3
  36. package/dist/cjs/validation/validate-dimensions.d.ts +1 -1
  37. package/dist/cjs/validation/validate-dimensions.js +2 -2
  38. package/dist/cjs/validation/validate-duration-in-frames.d.ts +2 -3
  39. package/dist/cjs/validation/validate-duration-in-frames.js +6 -2
  40. package/dist/cjs/validation/validate-fps.d.ts +1 -1
  41. package/dist/cjs/validation/validate-fps.js +2 -2
  42. package/dist/cjs/version.d.ts +1 -1
  43. package/dist/cjs/version.js +1 -1
  44. package/dist/cjs/video/OffthreadVideo.js +6 -3
  45. package/dist/cjs/video/OffthreadVideoForRendering.js +8 -2
  46. package/dist/cjs/video-config.d.ts +2 -1
  47. package/dist/esm/index.mjs +323 -214
  48. package/dist/esm/version.mjs +1 -1
  49. package/package.json +2 -2
@@ -1,4 +1,4 @@
1
- import type { ComponentType } from 'react';
1
+ import type { ComponentType, PropsWithChildren } from 'react';
2
2
  import React from 'react';
3
3
  import type { AnyZodObject } from 'zod';
4
4
  import type { InferProps, PropsIfHasProps } from './props-if-has-props.js';
@@ -10,32 +10,48 @@ export type CompProps<Props> = {
10
10
  } | {
11
11
  component: LooseComponentType<Props>;
12
12
  };
13
- export type CalcMetadataReturnType<T extends Record<string, unknown> | undefined> = {
13
+ export type CalcMetadataReturnType<T extends Record<string, unknown>> = {
14
14
  durationInFrames?: number;
15
15
  fps?: number;
16
16
  width?: number;
17
17
  height?: number;
18
18
  props?: T;
19
19
  };
20
- export type CalculateMetadataFunction<T extends Record<string, unknown> | undefined> = (options: {
20
+ export type CalculateMetadataFunction<T extends Record<string, unknown>> = (options: {
21
21
  defaultProps: T;
22
22
  props: T;
23
23
  abortSignal: AbortSignal;
24
24
  }) => Promise<CalcMetadataReturnType<T>> | CalcMetadataReturnType<T>;
25
- export type StillProps<Schema extends AnyZodObject, Props extends Record<string, unknown> | undefined> = {
25
+ type OptionalDimensions<Schema extends AnyZodObject, Props extends Record<string, unknown>> = {
26
+ width?: number;
27
+ height?: number;
28
+ calculateMetadata: CalculateMetadataFunction<InferProps<Schema, Props>>;
29
+ };
30
+ type MandatoryDimensions<Schema extends AnyZodObject, Props extends Record<string, unknown>> = {
26
31
  width: number;
27
32
  height: number;
28
- id: string;
29
33
  calculateMetadata?: CalculateMetadataFunction<InferProps<Schema, Props>>;
30
- schema?: Schema;
31
- } & CompProps<Props> & PropsIfHasProps<Schema, Props>;
32
- export type CompositionProps<Schema extends AnyZodObject, Props extends Record<string, unknown> | undefined> = StillProps<Schema, Props> & {
34
+ };
35
+ type StillCalculateMetadataOrExplicit<Schema extends AnyZodObject, Props extends Record<string, unknown>> = OptionalDimensions<Schema, Props> | MandatoryDimensions<Schema, Props>;
36
+ type CompositionCalculateMetadataOrExplicit<Schema extends AnyZodObject, Props extends Record<string, unknown>> = (OptionalDimensions<Schema, Props> & {
37
+ fps?: number;
38
+ durationInFrames?: number;
39
+ }) | (MandatoryDimensions<Schema, Props> & {
33
40
  fps: number;
34
41
  durationInFrames: number;
35
- };
42
+ });
43
+ export type StillProps<Schema extends AnyZodObject, Props extends Record<string, unknown>> = {
44
+ id: string;
45
+ schema?: Schema;
46
+ } & StillCalculateMetadataOrExplicit<Schema, Props> & CompProps<Props> & PropsIfHasProps<Schema, Props>;
47
+ export type CompositionProps<Schema extends AnyZodObject, Props extends Record<string, unknown>> = {
48
+ id: string;
49
+ schema?: Schema;
50
+ } & CompositionCalculateMetadataOrExplicit<Schema, Props> & CompProps<Props> & PropsIfHasProps<Schema, Props>;
36
51
  /**
37
52
  * @description This component is used to register a video to make it renderable and make it show in the sidebar, in dev mode.
38
53
  * @see [Documentation](https://www.remotion.dev/docs/composition)
39
54
  */
40
- export declare const Composition: <Schema extends AnyZodObject, Props extends Record<string, unknown> | undefined>({ width, height, fps, durationInFrames, id, defaultProps, schema, ...compProps }: CompositionProps<Schema, Props>) => React.ReactPortal | null;
55
+ export declare const Composition: <Schema extends AnyZodObject, Props extends Record<string, unknown>>({ width, height, fps, durationInFrames, id, defaultProps, schema, ...compProps }: CompositionProps<Schema, Props>) => React.ReactPortal | null;
56
+ export declare const ClipComposition: React.FC<PropsWithChildren>;
41
57
  export {};
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.Composition = void 0;
3
+ exports.ClipComposition = exports.Composition = void 0;
4
4
  const jsx_runtime_1 = require("react/jsx-runtime");
5
5
  const react_1 = require("react");
6
6
  const react_dom_1 = require("react-dom");
@@ -19,9 +19,6 @@ const use_lazy_component_js_1 = require("./use-lazy-component.js");
19
19
  const use_video_js_1 = require("./use-video.js");
20
20
  const validate_composition_id_js_1 = require("./validation/validate-composition-id.js");
21
21
  const validate_default_props_js_1 = require("./validation/validate-default-props.js");
22
- const validate_dimensions_js_1 = require("./validation/validate-dimensions.js");
23
- const validate_duration_in_frames_js_1 = require("./validation/validate-duration-in-frames.js");
24
- const validate_fps_js_1 = require("./validation/validate-fps.js");
25
22
  const Fallback = () => {
26
23
  (0, react_1.useEffect)(() => {
27
24
  const fallback = (0, delay_render_js_1.delayRender)('Waiting for Root component to unsuspend');
@@ -56,20 +53,12 @@ const Composition = ({ width, height, fps, durationInFrames, id, defaultProps, s
56
53
  throw new Error('No id for composition passed.');
57
54
  }
58
55
  (0, validate_composition_id_js_1.validateCompositionId)(id);
59
- (0, validate_dimensions_js_1.validateDimension)(width, 'width', 'of the <Composition/> component');
60
- (0, validate_dimensions_js_1.validateDimension)(height, 'height', 'of the <Composition/> component');
61
- (0, validate_duration_in_frames_js_1.validateDurationInFrames)({
62
- durationInFrames,
63
- component: 'of the <Composition/> component',
64
- allowFloats: false,
65
- });
66
- (0, validate_fps_js_1.validateFps)(fps, 'as a prop of the <Composition/> component', false);
67
56
  (0, validate_default_props_js_1.validateDefaultAndInputProps)(defaultProps, 'defaultProps', id);
68
57
  registerComposition({
69
- durationInFrames,
70
- fps,
71
- height,
72
- width,
58
+ durationInFrames: durationInFrames !== null && durationInFrames !== void 0 ? durationInFrames : undefined,
59
+ fps: fps !== null && fps !== void 0 ? fps : undefined,
60
+ height: height !== null && height !== void 0 ? height : undefined,
61
+ width: width !== null && width !== void 0 ? width : undefined,
73
62
  id,
74
63
  folderName,
75
64
  component: lazy,
@@ -104,14 +93,14 @@ const Composition = ({ width, height, fps, durationInFrames, id, defaultProps, s
104
93
  if (resolved === null || resolved.type !== 'success') {
105
94
  return null;
106
95
  }
107
- return (0, react_dom_1.createPortal)((0, jsx_runtime_1.jsx)(ClipComposition, { children: (0, jsx_runtime_1.jsx)(CanUseRemotionHooks_js_1.CanUseRemotionHooksProvider, { children: (0, jsx_runtime_1.jsx)(react_1.Suspense, { fallback: (0, jsx_runtime_1.jsx)(loading_indicator_js_1.Loading, {}), children: (0, jsx_runtime_1.jsx)(Comp, { ...((_a = resolved.result.defaultProps) !== null && _a !== void 0 ? _a : {}) }) }) }) }), (0, portal_node_js_1.portalNode)());
96
+ return (0, react_dom_1.createPortal)((0, jsx_runtime_1.jsx)(exports.ClipComposition, { children: (0, jsx_runtime_1.jsx)(CanUseRemotionHooks_js_1.CanUseRemotionHooksProvider, { children: (0, jsx_runtime_1.jsx)(react_1.Suspense, { fallback: (0, jsx_runtime_1.jsx)(loading_indicator_js_1.Loading, {}), children: (0, jsx_runtime_1.jsx)(Comp, { ...((_a = resolved.result.props) !== null && _a !== void 0 ? _a : {}) }) }) }) }), (0, portal_node_js_1.portalNode)());
108
97
  }
109
98
  if (environment === 'rendering' && video && video.component === lazy) {
110
99
  const Comp = lazy;
111
100
  if (resolved === null || resolved.type !== 'success') {
112
101
  return null;
113
102
  }
114
- return (0, react_dom_1.createPortal)((0, jsx_runtime_1.jsx)(CanUseRemotionHooks_js_1.CanUseRemotionHooksProvider, { children: (0, jsx_runtime_1.jsx)(react_1.Suspense, { fallback: (0, jsx_runtime_1.jsx)(Fallback, {}), children: (0, jsx_runtime_1.jsx)(Comp, { ...((_b = resolved.result.defaultProps) !== null && _b !== void 0 ? _b : {}) }) }) }), (0, portal_node_js_1.portalNode)());
103
+ return (0, react_dom_1.createPortal)((0, jsx_runtime_1.jsx)(CanUseRemotionHooks_js_1.CanUseRemotionHooksProvider, { children: (0, jsx_runtime_1.jsx)(react_1.Suspense, { fallback: (0, jsx_runtime_1.jsx)(Fallback, {}), children: (0, jsx_runtime_1.jsx)(Comp, { ...((_b = resolved.result.props) !== null && _b !== void 0 ? _b : {}) }) }) }), (0, portal_node_js_1.portalNode)());
115
104
  }
116
105
  return null;
117
106
  };
@@ -130,3 +119,4 @@ const ClipComposition = ({ children }) => {
130
119
  }, [clipRegion]);
131
120
  return (0, jsx_runtime_1.jsx)(AbsoluteFill_js_1.AbsoluteFill, { style: style, children: children });
132
121
  };
122
+ exports.ClipComposition = ClipComposition;
@@ -3,11 +3,11 @@ import React from 'react';
3
3
  import type { AnyZodObject } from 'zod';
4
4
  import type { CalculateMetadataFunction } from './Composition.js';
5
5
  import type { InferProps, PropsIfHasProps } from './props-if-has-props.js';
6
- export type TComposition<Schema extends AnyZodObject, Props extends Record<string, unknown> | undefined> = {
7
- width: number;
8
- height: number;
9
- fps: number;
10
- durationInFrames: number;
6
+ export type TComposition<Schema extends AnyZodObject, Props extends Record<string, unknown>> = {
7
+ width: number | undefined;
8
+ height: number | undefined;
9
+ fps: number | undefined;
10
+ durationInFrames: number | undefined;
11
11
  id: string;
12
12
  folderName: string | null;
13
13
  parentFolderName: string | null;
@@ -16,12 +16,11 @@ export type TComposition<Schema extends AnyZodObject, Props extends Record<strin
16
16
  schema: Schema | null;
17
17
  calculateMetadata: CalculateMetadataFunction<InferProps<Schema, Props>> | null;
18
18
  } & PropsIfHasProps<Schema, Props>;
19
- export type AnyComposition = TComposition<AnyZodObject, Record<string, unknown> | undefined>;
20
- export type TCompMetadataWithCalcFunction<Schema extends AnyZodObject, Props extends Record<string, unknown> | undefined> = Pick<TComposition<Schema, Props>, 'id' | 'height' | 'width' | 'fps' | 'durationInFrames' | 'defaultProps' | 'calculateMetadata'>;
21
- export type TCompMetadata<Schema extends AnyZodObject, Props extends Record<string, unknown> | undefined> = Pick<TComposition<Schema, Props>, 'id' | 'height' | 'width' | 'fps' | 'durationInFrames' | 'defaultProps'>;
22
- export type AnyCompMetadata = TCompMetadata<AnyZodObject, Record<string, unknown> | undefined>;
23
- export type SmallTCompMetadata<T extends AnyZodObject, Props extends Record<string, unknown> | undefined> = Pick<TComposition<T, Props>, 'id' | 'height' | 'width' | 'fps' | 'durationInFrames'> & Partial<Pick<TComposition<T, Props>, 'defaultProps'>>;
24
- export type AnySmallCompMetadata = SmallTCompMetadata<AnyZodObject, Record<string, unknown> | undefined>;
19
+ export type AnyComposition = TComposition<AnyZodObject, Record<string, unknown>>;
20
+ export type TCompMetadataWithCalcFunction<Schema extends AnyZodObject, Props extends Record<string, unknown>> = Pick<TComposition<Schema, Props>, 'id' | 'height' | 'width' | 'fps' | 'durationInFrames' | 'defaultProps' | 'calculateMetadata'>;
21
+ export type TCompMetadata<Schema extends AnyZodObject, Props extends Record<string, unknown>> = Pick<TComposition<Schema, Props>, 'id' | 'height' | 'width' | 'fps' | 'durationInFrames' | 'defaultProps'>;
22
+ export type AnyCompMetadata = TCompMetadata<AnyZodObject, Record<string, unknown>>;
23
+ export type SmallTCompMetadata<T extends AnyZodObject, Props extends Record<string, unknown>> = Pick<TComposition<T, Props>, 'id' | 'height' | 'width' | 'fps' | 'durationInFrames'> & Partial<Pick<TComposition<T, Props>, 'defaultProps'>>;
25
24
  type EnhancedTSequenceData = {
26
25
  type: 'sequence';
27
26
  } | {
@@ -66,7 +65,7 @@ export type TAsset = {
66
65
  allowAmplificationDuringRender: boolean;
67
66
  };
68
67
  export declare const compositionsRef: React.RefObject<{
69
- getCompositions: () => TCompMetadataWithCalcFunction<AnyZodObject, Record<string, unknown> | undefined>[];
68
+ getCompositions: () => TCompMetadataWithCalcFunction<AnyZodObject, Record<string, unknown>>[];
70
69
  }>;
71
70
  export declare const CompositionManagerProvider: React.FC<{
72
71
  children: React.ReactNode;
@@ -1,11 +1,12 @@
1
1
  /// <reference types="react" />
2
2
  import type { AnyZodObject } from 'zod';
3
- import type { AnyCompMetadata, AnyComposition, TComposition } from './CompositionManager.js';
3
+ import type { AnyComposition, TComposition } from './CompositionManager.js';
4
4
  import type { TFolder } from './Folder.js';
5
- export type BaseMetadata = Pick<AnyCompMetadata, 'durationInFrames' | 'fps' | 'defaultProps' | 'height' | 'width'>;
5
+ import type { VideoConfig } from './video-config.js';
6
+ export type BaseMetadata = Pick<VideoConfig, 'durationInFrames' | 'fps' | 'props' | 'height' | 'width'>;
6
7
  export type CompositionManagerContext = {
7
8
  compositions: AnyComposition[];
8
- registerComposition: <Schema extends AnyZodObject, Props extends Record<string, unknown> | undefined>(comp: TComposition<Schema, Props>) => void;
9
+ registerComposition: <Schema extends AnyZodObject, Props extends Record<string, unknown>>(comp: TComposition<Schema, Props>) => void;
9
10
  unregisterComposition: (name: string) => void;
10
11
  registerFolder: (name: string, parent: string | null) => void;
11
12
  unregisterFolder: (name: string, parent: string | null) => void;
package/dist/cjs/Img.d.ts CHANGED
@@ -6,4 +6,4 @@ import React from 'react';
6
6
  export declare const Img: React.ForwardRefExoticComponent<Pick<Omit<React.DetailedHTMLProps<React.ImgHTMLAttributes<HTMLImageElement>, HTMLImageElement>, "src"> & {
7
7
  maxRetries?: number | undefined;
8
8
  src: string;
9
- }, "id" | "height" | "width" | "key" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "className" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "lang" | "nonce" | "placeholder" | "slot" | "spellCheck" | "style" | "tabIndex" | "title" | "translate" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "children" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onResize" | "onResizeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "crossOrigin" | "src" | "loading" | "referrerPolicy" | "alt" | "decoding" | "sizes" | "srcSet" | "useMap" | "maxRetries"> & React.RefAttributes<HTMLImageElement>>;
9
+ }, "width" | "height" | "id" | "key" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "className" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "lang" | "nonce" | "placeholder" | "slot" | "spellCheck" | "style" | "tabIndex" | "title" | "translate" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "children" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onResize" | "onResizeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "crossOrigin" | "src" | "loading" | "referrerPolicy" | "alt" | "decoding" | "sizes" | "srcSet" | "useMap" | "maxRetries"> & React.RefAttributes<HTMLImageElement>>;
package/dist/cjs/Img.js CHANGED
@@ -65,7 +65,7 @@ const ImgRefForwarding = ({ onError, maxRetries = 2, src, ...props }, ref) => {
65
65
  if (process.env.NODE_ENV === 'test') {
66
66
  return;
67
67
  }
68
- const newHandle = (0, delay_render_js_1.delayRender)('Loading <Img> with src=' + src);
68
+ const newHandle = (0, delay_render_js_1.delayRender)('Loading <Img> with src=' + actualSrc);
69
69
  const { current } = imageRef;
70
70
  const onComplete = () => {
71
71
  var _a, _b, _c, _d;
@@ -89,7 +89,7 @@ const ImgRefForwarding = ({ onError, maxRetries = 2, src, ...props }, ref) => {
89
89
  current === null || current === void 0 ? void 0 : current.removeEventListener('load', didLoad);
90
90
  (0, delay_render_js_1.continueRender)(newHandle);
91
91
  };
92
- }, [src]);
92
+ }, [actualSrc]);
93
93
  }
94
94
  return ((0, jsx_runtime_1.jsx)("img", { ...props, ref: imageRef, src: actualSrc, onError: didGetError }));
95
95
  };
@@ -17,13 +17,14 @@ const NativeLayersProvider = ({ children, }) => {
17
17
  clipRegion,
18
18
  };
19
19
  }, [clipRegion, setClipRegion]);
20
- (0, react_1.useLayoutEffect)(() => {
21
- if (typeof window !== 'undefined') {
20
+ if (typeof window !== 'undefined') {
21
+ // eslint-disable-next-line react-hooks/rules-of-hooks
22
+ (0, react_1.useLayoutEffect)(() => {
22
23
  window.remotion_getClipRegion = () => {
23
24
  return clipRegion;
24
25
  };
25
- }
26
- }, [clipRegion, setClipRegion]);
26
+ }, [clipRegion, setClipRegion]);
27
+ }
27
28
  return ((0, jsx_runtime_1.jsx)(exports.NativeLayersContext.Provider, { value: context, children: children }));
28
29
  };
29
30
  exports.NativeLayersProvider = NativeLayersProvider;
@@ -13,9 +13,8 @@ const random_js_1 = require("./random.js");
13
13
  const timeline_position_state_js_1 = require("./timeline-position-state.js");
14
14
  const duration_state_js_1 = require("./video/duration-state.js");
15
15
  const RemotionRoot = ({ children, numberOfAudioTags }) => {
16
- var _a;
17
16
  const [remotionRootId] = (0, react_1.useState)(() => String((0, random_js_1.random)(null)));
18
- const [frame, setFrame] = (0, react_1.useState)((_a = window.remotion_initialFrame) !== null && _a !== void 0 ? _a : 0);
17
+ const [frame, setFrame] = (0, react_1.useState)({});
19
18
  const [playing, setPlaying] = (0, react_1.useState)(false);
20
19
  const imperativePlaying = (0, react_1.useRef)(false);
21
20
  const [fastRefreshes, setFastRefreshes] = (0, react_1.useState)(0);
@@ -24,9 +23,12 @@ const RemotionRoot = ({ children, numberOfAudioTags }) => {
24
23
  if (typeof window !== 'undefined') {
25
24
  // eslint-disable-next-line react-hooks/rules-of-hooks
26
25
  (0, react_1.useLayoutEffect)(() => {
27
- window.remotion_setFrame = (f) => {
26
+ window.remotion_setFrame = (f, composition) => {
28
27
  const id = (0, delay_render_js_1.delayRender)(`Setting the current frame to ${f}`);
29
- setFrame(f);
28
+ setFrame((s) => ({
29
+ ...s,
30
+ [composition]: f,
31
+ }));
30
32
  requestAnimationFrame(() => (0, delay_render_js_1.continueRender)(id));
31
33
  };
32
34
  window.remotion_isPlayer = false;
@@ -30,12 +30,23 @@ const ResolveCompositionConfig = ({ children }) => {
30
30
  : {};
31
31
  }, [allEditorProps, renderModalComposition]);
32
32
  const doResolution = (0, react_1.useCallback)((composition, editorProps) => {
33
+ var _a;
33
34
  const controller = new AbortController();
34
35
  if (currentCompositionMetadata) {
35
36
  return controller;
36
37
  }
38
+ const inputProps = typeof window === 'undefined' ||
39
+ (0, get_environment_js_1.getRemotionEnvironment)() === 'player-development' ||
40
+ (0, get_environment_js_1.getRemotionEnvironment)() === 'player-production'
41
+ ? {}
42
+ : (_a = (0, input_props_js_1.getInputProps)()) !== null && _a !== void 0 ? _a : {};
37
43
  const { signal } = controller;
38
- const promOrNot = (0, resolve_video_config_js_1.resolveVideoConfig)({ composition, editorProps, signal });
44
+ const promOrNot = (0, resolve_video_config_js_1.resolveVideoConfig)({
45
+ composition,
46
+ editorProps,
47
+ inputProps,
48
+ signal,
49
+ });
39
50
  if (typeof promOrNot === 'object' && 'then' in promOrNot) {
40
51
  setResolvedConfigs((r) => ({
41
52
  ...r,
@@ -152,7 +163,7 @@ const useResolvedVideoConfig = (preferredCompositionId) => {
152
163
  return composition ? (_a = allEditorProps[composition.id]) !== null && _a !== void 0 ? _a : {} : {};
153
164
  }, [allEditorProps, composition]);
154
165
  return (0, react_1.useMemo)(() => {
155
- var _a, _b, _c;
166
+ var _a, _b, _c, _d;
156
167
  if (!composition) {
157
168
  return null;
158
169
  }
@@ -162,7 +173,8 @@ const useResolvedVideoConfig = (preferredCompositionId) => {
162
173
  result: {
163
174
  ...currentCompositionMetadata,
164
175
  id: composition.id,
165
- defaultProps: (_a = currentCompositionMetadata.defaultProps) !== null && _a !== void 0 ? _a : {},
176
+ props: currentCompositionMetadata.props,
177
+ defaultProps: (_a = composition.defaultProps) !== null && _a !== void 0 ? _a : {},
166
178
  },
167
179
  };
168
180
  }
@@ -170,15 +182,20 @@ const useResolvedVideoConfig = (preferredCompositionId) => {
170
182
  return {
171
183
  type: 'success',
172
184
  result: {
173
- ...composition,
174
- defaultProps: {
175
- ...((_b = composition.defaultProps) !== null && _b !== void 0 ? _b : {}),
185
+ width: composition.width,
186
+ height: composition.height,
187
+ fps: composition.fps,
188
+ id: composition.id,
189
+ durationInFrames: composition.durationInFrames,
190
+ defaultProps: (_b = composition.defaultProps) !== null && _b !== void 0 ? _b : {},
191
+ props: {
192
+ ...((_c = composition.defaultProps) !== null && _c !== void 0 ? _c : {}),
176
193
  ...(selectedEditorProps !== null && selectedEditorProps !== void 0 ? selectedEditorProps : {}),
177
194
  ...(typeof window === 'undefined' ||
178
195
  (0, get_environment_js_1.getRemotionEnvironment)() === 'player-development' ||
179
196
  (0, get_environment_js_1.getRemotionEnvironment)() === 'player-production'
180
197
  ? {}
181
- : (_c = (0, input_props_js_1.getInputProps)()) !== null && _c !== void 0 ? _c : {}),
198
+ : (_d = (0, input_props_js_1.getInputProps)()) !== null && _d !== void 0 ? _d : {}),
182
199
  },
183
200
  },
184
201
  };
@@ -5,4 +5,4 @@ import type { StillProps } from './Composition.js';
5
5
  * @description A `<Still />` is a `<Composition />` that is only 1 frame long.
6
6
  * @see [Documentation](https://www.remotion.dev/docs/still)
7
7
  */
8
- export declare const Still: <Schema extends AnyZodObject, Props extends Record<string, unknown> | undefined>(props: StillProps<Schema, Props>) => React.DetailedReactHTMLElement<React.InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>;
8
+ export declare const Still: <Schema extends AnyZodObject, Props extends Record<string, unknown>>(props: StillProps<Schema, Props>) => React.DetailedReactHTMLElement<React.InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>;
@@ -96,6 +96,6 @@ const AudioForDevelopmentForwardRefFunction = (props, ref) => {
96
96
  if (initialShouldPreMountAudioElements) {
97
97
  return null;
98
98
  }
99
- return (0, jsx_runtime_1.jsx)("audio", { ref: audioRef, ...propsToPass });
99
+ return (0, jsx_runtime_1.jsx)("audio", { ref: audioRef, preload: "metadata", ...propsToPass });
100
100
  };
101
101
  exports.AudioForDevelopment = (0, react_1.forwardRef)(AudioForDevelopmentForwardRefFunction);
@@ -33,7 +33,7 @@ export declare const SharedAudioContext: React.Context<SharedContext | null>;
33
33
  export declare const SharedAudioContextProvider: React.FC<{
34
34
  numberOfAudioTags: number;
35
35
  children: React.ReactNode;
36
- component: LazyExoticComponent<ComponentType<Record<string, unknown> | undefined>> | null;
36
+ component: LazyExoticComponent<ComponentType<Record<string, unknown>>> | null;
37
37
  }>;
38
38
  export declare const useSharedAudio: (aud: RemotionAudioProps, audioId: string) => AudioElem;
39
39
  export {};
@@ -193,7 +193,11 @@ const SharedAudioContextProvider = ({ children, numberOfAudioTags, component })
193
193
  };
194
194
  }, [component, resetAudio]);
195
195
  return ((0, jsx_runtime_1.jsxs)(exports.SharedAudioContext.Provider, { value: value, children: [refs.map(({ id, ref }) => {
196
- return (0, jsx_runtime_1.jsx)("audio", { ref: ref, src: EMPTY_AUDIO }, id);
196
+ return (
197
+ // Without preload="metadata", iOS will seek the time internally
198
+ // but not actually with sound. Adding `preload="metadata"` helps here.
199
+ // https://discord.com/channels/809501355504959528/817306414069710848/1130519583367888906
200
+ (0, jsx_runtime_1.jsx)("audio", { ref: ref, preload: "metadata", src: EMPTY_AUDIO }, id));
197
201
  }), children] }));
198
202
  };
199
203
  exports.SharedAudioContextProvider = SharedAudioContextProvider;
@@ -1 +1 @@
1
- export declare const getInputProps: () => any;
1
+ export declare const getInputProps: () => Record<string, unknown>;
@@ -2,6 +2,7 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.getInputProps = void 0;
4
4
  const get_environment_js_1 = require("../get-environment.js");
5
+ const input_props_serialization_js_1 = require("../input-props-serialization.js");
5
6
  let didWarnSSRImport = false;
6
7
  const warnOnceSSRImport = () => {
7
8
  if (didWarnSSRImport) {
@@ -25,7 +26,7 @@ const getInputProps = () => {
25
26
  if (!param) {
26
27
  return {};
27
28
  }
28
- const parsed = JSON.parse(param);
29
+ const parsed = (0, input_props_serialization_js_1.deserializeJSONWithCustomFields)(param);
29
30
  return parsed;
30
31
  };
31
32
  exports.getInputProps = getInputProps;
@@ -7,7 +7,9 @@ if (typeof window !== 'undefined') {
7
7
  window.remotion_renderReady = false;
8
8
  }
9
9
  let handles = [];
10
- const timeouts = {};
10
+ if (typeof window !== 'undefined') {
11
+ window.remotion_delayRenderTimeouts = {};
12
+ }
11
13
  exports.DELAY_RENDER_CALLSTACK_TOKEN = 'The delayRender was called:';
12
14
  const defaultTimeout = 30000;
13
15
  /**
@@ -29,18 +31,23 @@ const delayRender = (label) => {
29
31
  const timeoutToUse = typeof window === 'undefined'
30
32
  ? defaultTimeout
31
33
  : ((_c = window.remotion_puppeteerTimeout) !== null && _c !== void 0 ? _c : defaultTimeout) - 2000;
32
- timeouts[handle] = setTimeout(() => {
33
- const message = [
34
- `A delayRender()`,
35
- label ? `"${label}"` : null,
36
- `was called but not cleared after ${timeoutToUse}ms. See https://remotion.dev/docs/timeout for help.`,
37
- exports.DELAY_RENDER_CALLSTACK_TOKEN,
38
- called,
39
- ]
40
- .filter(truthy_js_1.truthy)
41
- .join(' ');
42
- throw new Error(message);
43
- }, timeoutToUse);
34
+ if (typeof window !== 'undefined') {
35
+ window.remotion_delayRenderTimeouts[handle] = {
36
+ label: label !== null && label !== void 0 ? label : null,
37
+ timeout: setTimeout(() => {
38
+ const message = [
39
+ `A delayRender()`,
40
+ label ? `"${label}"` : null,
41
+ `was called but not cleared after ${timeoutToUse}ms. See https://remotion.dev/docs/timeout for help.`,
42
+ exports.DELAY_RENDER_CALLSTACK_TOKEN,
43
+ called,
44
+ ]
45
+ .filter(truthy_js_1.truthy)
46
+ .join(' ');
47
+ throw new Error(message);
48
+ }, timeoutToUse),
49
+ };
50
+ }
44
51
  }
45
52
  if (typeof window !== 'undefined') {
46
53
  window.remotion_renderReady = false;
@@ -64,7 +71,8 @@ const continueRender = (handle) => {
64
71
  handles = handles.filter((h) => {
65
72
  if (h === handle) {
66
73
  if ((0, get_environment_js_1.getRemotionEnvironment)() === 'rendering') {
67
- clearTimeout(timeouts[handle]);
74
+ clearTimeout(window.remotion_delayRenderTimeouts[handle].timeout);
75
+ delete window.remotion_delayRenderTimeouts[handle];
68
76
  }
69
77
  return false;
70
78
  }
@@ -5,11 +5,13 @@ const jsx_runtime_1 = require("react/jsx-runtime");
5
5
  const react_1 = require("react");
6
6
  const SequenceContext_js_1 = require("./SequenceContext.js");
7
7
  const timeline_position_state_js_1 = require("./timeline-position-state.js");
8
+ const use_video_config_js_1 = require("./use-video-config.js");
8
9
  /**
9
10
  * @description This method freezes all of its children to the frame that you specify as a prop
10
11
  * @see [Documentation](https://www.remotion.dev/docs/freeze)
11
12
  */
12
13
  const Freeze = ({ frame, children }) => {
14
+ const videoConfig = (0, use_video_config_js_1.useVideoConfig)();
13
15
  if (typeof frame === 'undefined') {
14
16
  throw new Error(`The <Freeze /> component requires a 'frame' prop, but none was passed.`);
15
17
  }
@@ -30,9 +32,11 @@ const Freeze = ({ frame, children }) => {
30
32
  imperativePlaying: {
31
33
  current: false,
32
34
  },
33
- frame,
35
+ frame: {
36
+ [videoConfig.id]: frame,
37
+ },
34
38
  };
35
- }, [context, frame]);
39
+ }, [context, frame, videoConfig.id]);
36
40
  return ((0, jsx_runtime_1.jsx)(timeline_position_state_js_1.TimelineContext.Provider, { value: value, children: (0, jsx_runtime_1.jsx)(SequenceContext_js_1.SequenceContext.Provider, { value: null, children: children }) }));
37
41
  };
38
42
  exports.Freeze = Freeze;
@@ -1,15 +1,25 @@
1
+ /// <reference types="node" />
1
2
  import './asset-types.js';
2
- import type { AnyCompMetadata, TAsset } from './CompositionManager.js';
3
+ import type { TAsset } from './CompositionManager.js';
3
4
  import type { StaticFile } from './get-static-files.js';
4
5
  import type { ClipRegion } from './NativeLayers.js';
5
6
  import type { VideoConfig } from './video-config.js';
6
7
  declare global {
7
8
  interface Window {
8
9
  remotion_renderReady: boolean;
10
+ remotion_delayRenderTimeouts: {
11
+ [key: string]: {
12
+ label: string | null;
13
+ timeout: number | NodeJS.Timeout;
14
+ };
15
+ };
9
16
  remotion_cancelledError: string | undefined;
10
17
  remotion_getCompositionNames: () => string[];
11
- getStaticCompositions: () => Promise<AnyCompMetadata[]>;
12
- remotion_calculateComposition: (compId: string) => Promise<VideoConfig>;
18
+ getStaticCompositions: () => Promise<VideoConfig[]>;
19
+ remotion_calculateComposition: (compId: string) => Promise<Omit<VideoConfig, 'defaultProps' | 'props'> & {
20
+ serializedDefaultPropsWithCustomSchema: string;
21
+ serializedResolvedPropsWithCustomSchema: string;
22
+ }>;
13
23
  remotion_setBundleMode: (bundleMode: BundleState) => void;
14
24
  remotion_staticBase: string;
15
25
  remotion_staticFiles: StaticFile[];
@@ -18,7 +28,7 @@ declare global {
18
28
  remotion_projectName: string;
19
29
  remotion_cwd: string;
20
30
  remotion_studioServerCommand: string;
21
- remotion_setFrame: (frame: number) => void;
31
+ remotion_setFrame: (frame: number, composition: string) => void;
22
32
  remotion_initialFrame: number;
23
33
  remotion_proxyPort: number;
24
34
  remotion_audioEnabled: boolean;
@@ -31,7 +41,7 @@ declare global {
31
41
  remotion_isPlayer: boolean;
32
42
  remotion_isBuilding: undefined | (() => void);
33
43
  remotion_finishedBuilding: undefined | (() => void);
34
- siteVersion: '5';
44
+ siteVersion: '9';
35
45
  remotion_version: string;
36
46
  remotion_imported: string | boolean;
37
47
  }
@@ -43,7 +53,7 @@ export type BundleState = {
43
53
  } | {
44
54
  type: 'composition';
45
55
  compositionName: string;
46
- compositionDefaultProps: Record<string, unknown>;
56
+ serializedResolvedPropsWithSchema: string;
47
57
  compositionHeight: number;
48
58
  compositionDurationInFrames: number;
49
59
  compositionWidth: number;
@@ -53,7 +63,7 @@ export * from './AbsoluteFill.js';
53
63
  export * from './audio/index.js';
54
64
  export { cancelRender } from './cancel-render.js';
55
65
  export { CalculateMetadataFunction, Composition, CompositionProps, CompProps, StillProps, } from './Composition.js';
56
- export { AnyCompMetadata, AnyComposition, AnySmallCompMetadata, SmallTCompMetadata, TAsset, TCompMetadata, } from './CompositionManager.js';
66
+ export { AnyCompMetadata, AnyComposition, SmallTCompMetadata, TAsset, TCompMetadata, } from './CompositionManager.js';
57
67
  export { getInputProps } from './config/input-props.js';
58
68
  export { continueRender, delayRender } from './delay-render.js';
59
69
  export * from './easing.js';
package/dist/cjs/index.js CHANGED
@@ -98,7 +98,7 @@ exports.Config = new Proxy(proxyObj, {
98
98
  console.warn('+ Replace:');
99
99
  console.warn('import {Config} from "@remotion/cli/config";');
100
100
  console.warn();
101
- console.warn('For more information, see https://v4.remotion.dev/docs/4-0-migration.');
101
+ console.warn('For more information, see https://www.remotion.dev/docs/4-0-migration.');
102
102
  process.exit(1);
103
103
  };
104
104
  },
@@ -0,0 +1,15 @@
1
+ export type SerializedJSONWithCustomFields = {
2
+ serializedString: string;
3
+ customDateUsed: boolean;
4
+ customFileUsed: boolean;
5
+ mapUsed: boolean;
6
+ setUsed: boolean;
7
+ };
8
+ export declare const DATE_TOKEN = "remotion-date:";
9
+ export declare const FILE_TOKEN = "remotion-file:";
10
+ export declare const serializeJSONWithDate: ({ data, indent, staticBase, }: {
11
+ data: Record<string, unknown>;
12
+ indent: number | undefined;
13
+ staticBase: string | null;
14
+ }) => SerializedJSONWithCustomFields;
15
+ export declare const deserializeJSONWithCustomFields: (data: string) => Record<string, unknown>;