remotion 4.0.346 → 4.0.348

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/bundle.ts CHANGED
@@ -39,7 +39,13 @@ const noReactOutput = await build({
39
39
  external: ['remotion', 'react', 'react-dom'],
40
40
  });
41
41
  const [noReactFile] = noReactOutput.outputs;
42
- await Bun.write('dist/esm/no-react.mjs', await noReactFile.text());
42
+ const noReactText = await noReactFile.text();
43
+
44
+ if (noReactText.includes('createContext')) {
45
+ throw new Error('remotion/no-react.mjs should not import React');
46
+ }
47
+
48
+ await Bun.write('dist/esm/no-react.mjs', noReactText);
43
49
 
44
50
  export {};
45
51
 
@@ -70,6 +70,16 @@ export type AudioOrVideoAsset = {
70
70
  audioStartFrame: number;
71
71
  audioStreamIndex: number;
72
72
  };
73
+ export type InlineAudioAsset = {
74
+ type: 'inline-audio';
75
+ id: string;
76
+ audio: number[];
77
+ frame: number;
78
+ sampleRate: number;
79
+ numberOfChannels: number;
80
+ timestamp: number;
81
+ duration: number;
82
+ };
73
83
  type DiscriminatedArtifact = {
74
84
  contentType: 'binary';
75
85
  content: string;
@@ -86,7 +96,7 @@ export type ArtifactAsset = {
86
96
  frame: number;
87
97
  downloadBehavior: DownloadBehavior | null;
88
98
  } & DiscriminatedArtifact;
89
- export type TRenderAsset = AudioOrVideoAsset | ArtifactAsset;
99
+ export type TRenderAsset = AudioOrVideoAsset | ArtifactAsset | InlineAudioAsset;
90
100
  export declare const compositionsRef: React.RefObject<{
91
101
  getCompositions: () => AnyComposition[];
92
102
  } | null>;
@@ -14,6 +14,7 @@ const use_media_in_timeline_js_1 = require("../use-media-in-timeline.js");
14
14
  const use_media_playback_js_1 = require("../use-media-playback.js");
15
15
  const volume_position_state_js_1 = require("../volume-position-state.js");
16
16
  const volume_prop_js_1 = require("../volume-prop.js");
17
+ const volume_safeguard_js_1 = require("../volume-safeguard.js");
17
18
  const shared_audio_tags_js_1 = require("./shared-audio-tags.js");
18
19
  const use_audio_frame_js_1 = require("./use-audio-frame.js");
19
20
  const AudioForDevelopmentForwardRefFunction = (props, ref) => {
@@ -46,6 +47,7 @@ const AudioForDevelopmentForwardRefFunction = (props, ref) => {
46
47
  volume,
47
48
  mediaVolume,
48
49
  });
50
+ (0, volume_safeguard_js_1.warnAboutTooHighVolume)(userPreferredVolume);
49
51
  const crossOriginValue = (0, get_cross_origin_value_js_1.getCrossOriginValue)({
50
52
  crossOrigin,
51
53
  requestsVideoFrame: false,
@@ -11,6 +11,7 @@ const timeline_position_state_js_1 = require("../timeline-position-state.js");
11
11
  const use_current_frame_js_1 = require("../use-current-frame.js");
12
12
  const use_delay_render_js_1 = require("../use-delay-render.js");
13
13
  const volume_prop_js_1 = require("../volume-prop.js");
14
+ const volume_safeguard_js_1 = require("../volume-safeguard.js");
14
15
  const use_audio_frame_js_1 = require("./use-audio-frame.js");
15
16
  const AudioForRenderingRefForwardingFunction = (props, ref) => {
16
17
  const audioRef = (0, react_1.useRef)(null);
@@ -37,6 +38,7 @@ const AudioForRenderingRefForwardingFunction = (props, ref) => {
37
38
  frame: volumePropFrame,
38
39
  mediaVolume: 1,
39
40
  });
41
+ (0, volume_safeguard_js_1.warnAboutTooHighVolume)(volume);
40
42
  (0, react_1.useImperativeHandle)(ref, () => {
41
43
  return audioRef.current;
42
44
  }, []);
@@ -1,4 +1,4 @@
1
- import type { RemotionEnvironment } from './get-remotion-environment.js';
1
+ import type { RemotionEnvironment } from './remotion-environment-context.js';
2
2
  export declare const DELAY_RENDER_CALLSTACK_TOKEN = "The delayRender was called:";
3
3
  export declare const DELAY_RENDER_RETRIES_LEFT = "Retries left: ";
4
4
  export declare const DELAY_RENDER_RETRY_TOKEN = "- Rendering the frame will be retried.";
@@ -1,10 +1,2 @@
1
- import React from 'react';
2
- export type RemotionEnvironment = {
3
- isStudio: boolean;
4
- isRendering: boolean;
5
- isClientSideRendering: boolean;
6
- isPlayer: boolean;
7
- isReadOnlyStudio: boolean;
8
- };
1
+ import type { RemotionEnvironment } from './remotion-environment-context';
9
2
  export declare const getRemotionEnvironment: () => RemotionEnvironment;
10
- export declare const RemotionEnvironmentContext: React.Context<RemotionEnvironment | null>;
@@ -1,10 +1,6 @@
1
1
  "use strict";
2
- var __importDefault = (this && this.__importDefault) || function (mod) {
3
- return (mod && mod.__esModule) ? mod : { "default": mod };
4
- };
5
2
  Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.RemotionEnvironmentContext = exports.getRemotionEnvironment = void 0;
7
- const react_1 = __importDefault(require("react"));
3
+ exports.getRemotionEnvironment = void 0;
8
4
  // Avoid VITE obfuscation
9
5
  function getNodeEnvString() {
10
6
  return ['NOD', 'E_EN', 'V'].join('');
@@ -37,4 +33,3 @@ const getRemotionEnvironment = () => {
37
33
  };
38
34
  };
39
35
  exports.getRemotionEnvironment = getRemotionEnvironment;
40
- exports.RemotionEnvironmentContext = react_1.default.createContext(null);
@@ -2,9 +2,9 @@ import { type CompProps } from './Composition.js';
2
2
  import type { TCompMetadata, TComposition, TRenderAsset, TSequence } from './CompositionManager.js';
3
3
  import type { CompositionManagerContext } from './CompositionManagerContext.js';
4
4
  import * as CSSUtils from './default-css.js';
5
- import type { RemotionEnvironment } from './get-remotion-environment.js';
6
5
  import type { SerializedJSONWithCustomFields } from './input-props-serialization.js';
7
6
  import type { LoggingContextValue } from './log-level-context.js';
7
+ import type { RemotionEnvironment } from './remotion-environment-context.js';
8
8
  import type { SetTimelineContextValue, TimelineContextValue } from './timeline-position-state.js';
9
9
  import * as TimelinePosition from './timeline-position-state.js';
10
10
  import { truthy } from './truthy.js';
@@ -264,5 +264,6 @@ export declare const Internals: {
264
264
  toggleFolder: (folderName: string, parentName: string | null) => void;
265
265
  } | null>;
266
266
  readonly RemotionEnvironmentContext: import("react").Context<RemotionEnvironment | null>;
267
+ readonly warnAboutTooHighVolume: (volume: number) => void;
267
268
  };
268
269
  export type { CompositionManagerContext, CompProps, LoggingContextValue, MediaVolumeContextValue, RemotionEnvironment, SerializedJSONWithCustomFields, SetMediaVolumeContextValue, SetTimelineContextValue, TCompMetadata, TComposition, TimelineContextValue, TRenderAsset, TSequence, WatchRemotionStaticFilesPayload, };
@@ -56,6 +56,7 @@ const portal_node_js_1 = require("./portal-node.js");
56
56
  const prefetch_state_js_1 = require("./prefetch-state.js");
57
57
  const prefetch_js_1 = require("./prefetch.js");
58
58
  const register_root_js_1 = require("./register-root.js");
59
+ const remotion_environment_context_js_1 = require("./remotion-environment-context.js");
59
60
  const RemotionRoot_js_1 = require("./RemotionRoot.js");
60
61
  const RenderAssetManager_js_1 = require("./RenderAssetManager.js");
61
62
  const resolve_video_config_js_1 = require("./resolve-video-config.js");
@@ -79,6 +80,7 @@ const video_fragment_js_1 = require("./video/video-fragment.js");
79
80
  const VideoForPreview_js_1 = require("./video/VideoForPreview.js");
80
81
  const volume_position_state_js_1 = require("./volume-position-state.js");
81
82
  const volume_prop_js_1 = require("./volume-prop.js");
83
+ const volume_safeguard_js_1 = require("./volume-safeguard.js");
82
84
  const watch_static_file_js_1 = require("./watch-static-file.js");
83
85
  const wrap_remotion_context_js_1 = require("./wrap-remotion-context.js");
84
86
  // needs to be in core package so gets deduplicated in studio
@@ -161,5 +163,6 @@ exports.Internals = {
161
163
  playbackLogging: playback_logging_js_1.playbackLogging,
162
164
  timeValueRef: EditorProps_js_1.timeValueRef,
163
165
  compositionSelectorRef,
164
- RemotionEnvironmentContext: get_remotion_environment_js_1.RemotionEnvironmentContext,
166
+ RemotionEnvironmentContext: remotion_environment_context_js_1.RemotionEnvironmentContext,
167
+ warnAboutTooHighVolume: volume_safeguard_js_1.warnAboutTooHighVolume,
165
168
  };
@@ -1,4 +1,4 @@
1
- export type { ArtifactAsset, AudioOrVideoAsset, TRenderAsset, } from './CompositionManager';
1
+ export type { ArtifactAsset, AudioOrVideoAsset, InlineAudioAsset, TRenderAsset, } from './CompositionManager';
2
2
  export { DownloadBehavior } from './download-behavior';
3
3
  export { EasingFunction, ExtrapolateType, interpolate, InterpolateOptions, } from './interpolate';
4
4
  export { random, RandomSeed } from './random.js';
@@ -0,0 +1,9 @@
1
+ import React from 'react';
2
+ export type RemotionEnvironment = {
3
+ isStudio: boolean;
4
+ isRendering: boolean;
5
+ isClientSideRendering: boolean;
6
+ isPlayer: boolean;
7
+ isReadOnlyStudio: boolean;
8
+ };
9
+ export declare const RemotionEnvironmentContext: React.Context<RemotionEnvironment | null>;
@@ -0,0 +1,8 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.RemotionEnvironmentContext = void 0;
7
+ const react_1 = __importDefault(require("react"));
8
+ exports.RemotionEnvironmentContext = react_1.default.createContext(null);
@@ -1,4 +1,4 @@
1
- import { type RemotionEnvironment } from './get-remotion-environment';
1
+ import type { RemotionEnvironment } from './remotion-environment-context';
2
2
  /**
3
3
  * @description A React hook that provides information about the current Remotion Environment. This is the preferred way to access environment information in React components as it will support future scoped contexts.
4
4
  * @see [Documentation](https://remotion.dev/docs/use-remotion-environment)
@@ -3,12 +3,13 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.useRemotionEnvironment = void 0;
4
4
  const react_1 = require("react");
5
5
  const get_remotion_environment_1 = require("./get-remotion-environment");
6
+ const remotion_environment_context_1 = require("./remotion-environment-context");
6
7
  /**
7
8
  * @description A React hook that provides information about the current Remotion Environment. This is the preferred way to access environment information in React components as it will support future scoped contexts.
8
9
  * @see [Documentation](https://remotion.dev/docs/use-remotion-environment)
9
10
  */
10
11
  const useRemotionEnvironment = () => {
11
- const context = (0, react_1.useContext)(get_remotion_environment_1.RemotionEnvironmentContext);
12
+ const context = (0, react_1.useContext)(remotion_environment_context_1.RemotionEnvironmentContext);
12
13
  const [env] = (0, react_1.useState)(() => (0, get_remotion_environment_1.getRemotionEnvironment)());
13
14
  return context !== null && context !== void 0 ? context : env;
14
15
  };
@@ -3,4 +3,4 @@
3
3
  * @see [Documentation](https://remotion.dev/docs/version)
4
4
  * @returns {string} The current version of the remotion package
5
5
  */
6
- export declare const VERSION = "4.0.346";
6
+ export declare const VERSION = "4.0.348";
@@ -7,4 +7,4 @@ exports.VERSION = void 0;
7
7
  * @see [Documentation](https://remotion.dev/docs/version)
8
8
  * @returns {string} The current version of the remotion package
9
9
  */
10
- exports.VERSION = '4.0.346';
10
+ exports.VERSION = '4.0.348';
@@ -17,6 +17,7 @@ const use_current_frame_js_1 = require("../use-current-frame.js");
17
17
  const use_delay_render_js_1 = require("../use-delay-render.js");
18
18
  const use_unsafe_video_config_js_1 = require("../use-unsafe-video-config.js");
19
19
  const volume_prop_js_1 = require("../volume-prop.js");
20
+ const volume_safeguard_js_1 = require("../volume-safeguard.js");
20
21
  const get_current_time_js_1 = require("./get-current-time.js");
21
22
  const offthread_video_source_js_1 = require("./offthread-video-source.js");
22
23
  const OffthreadVideoForRendering = ({ onError, volume: volumeProp, playbackRate, src, muted, allowAmplificationDuringRender, transparent = false, toneMapped = true, toneFrequency, name, loopVolumeCurveBehavior, delayRenderRetries, delayRenderTimeoutInMilliseconds, onVideoFrame,
@@ -49,6 +50,7 @@ crossOrigin, audioStreamIndex, ...props }) => {
49
50
  frame: volumePropsFrame,
50
51
  mediaVolume: 1,
51
52
  });
53
+ (0, volume_safeguard_js_1.warnAboutTooHighVolume)(volume);
52
54
  (0, react_1.useEffect)(() => {
53
55
  var _a;
54
56
  if (!src) {
@@ -19,6 +19,7 @@ const use_video_config_js_1 = require("../use-video-config.js");
19
19
  const version_js_1 = require("../version.js");
20
20
  const volume_position_state_js_1 = require("../volume-position-state.js");
21
21
  const volume_prop_js_1 = require("../volume-prop.js");
22
+ const volume_safeguard_js_1 = require("../volume-safeguard.js");
22
23
  const emit_video_frame_js_1 = require("./emit-video-frame.js");
23
24
  const video_fragment_js_1 = require("./video-fragment.js");
24
25
  const VideoForDevelopmentRefForwardingFunction = (props, ref) => {
@@ -62,6 +63,7 @@ const VideoForDevelopmentRefForwardingFunction = (props, ref) => {
62
63
  volume,
63
64
  mediaVolume,
64
65
  });
66
+ (0, volume_safeguard_js_1.warnAboutTooHighVolume)(userPreferredVolume);
65
67
  (0, use_media_in_timeline_js_1.useMediaInTimeline)({
66
68
  mediaRef: videoRef,
67
69
  volume,
@@ -16,6 +16,7 @@ const use_delay_render_js_1 = require("../use-delay-render.js");
16
16
  const use_remotion_environment_js_1 = require("../use-remotion-environment.js");
17
17
  const use_unsafe_video_config_js_1 = require("../use-unsafe-video-config.js");
18
18
  const volume_prop_js_1 = require("../volume-prop.js");
19
+ const volume_safeguard_js_1 = require("../volume-safeguard.js");
19
20
  const get_current_time_js_1 = require("./get-current-time.js");
20
21
  const seek_until_right_js_1 = require("./seek-until-right.js");
21
22
  const VideoForRenderingForwardFunction = ({ onError, volume: volumeProp, allowAmplificationDuringRender, playbackRate, onDuration, toneFrequency, name, acceptableTimeShiftInSeconds, delayRenderRetries, delayRenderTimeoutInMilliseconds, loopVolumeCurveBehavior, audioStreamIndex, ...props }, ref) => {
@@ -50,6 +51,7 @@ const VideoForRenderingForwardFunction = ({ onError, volume: volumeProp, allowAm
50
51
  frame: volumePropsFrame,
51
52
  mediaVolume: 1,
52
53
  });
54
+ (0, volume_safeguard_js_1.warnAboutTooHighVolume)(volume);
53
55
  (0, react_1.useEffect)(() => {
54
56
  var _a;
55
57
  if (!props.src) {
@@ -0,0 +1 @@
1
+ export declare const warnAboutTooHighVolume: (volume: number) => void;
@@ -0,0 +1,9 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.warnAboutTooHighVolume = void 0;
4
+ const warnAboutTooHighVolume = (volume) => {
5
+ if (volume >= 100) {
6
+ throw new Error(`Volume was set to ${volume}, but regular volume is 1, not 100. Did you forget to divide by 100? Set a volume of less than 100 to dismiss this error.`);
7
+ }
8
+ };
9
+ exports.warnAboutTooHighVolume = warnAboutTooHighVolume;
@@ -33,10 +33,9 @@ var Clipper = () => {
33
33
  };
34
34
 
35
35
  // src/enable-sequence-stack-traces.ts
36
- import React2 from "react";
36
+ import React from "react";
37
37
 
38
38
  // src/get-remotion-environment.ts
39
- import React from "react";
40
39
  function getNodeEnvString() {
41
40
  return ["NOD", "E_EN", "V"].join("");
42
41
  }
@@ -56,10 +55,9 @@ var getRemotionEnvironment = () => {
56
55
  isClientSideRendering: false
57
56
  };
58
57
  };
59
- var RemotionEnvironmentContext = React.createContext(null);
60
58
 
61
59
  // src/enable-sequence-stack-traces.ts
62
- var originalCreateElement = React2.createElement;
60
+ var originalCreateElement = React.createElement;
63
61
  var componentsToAddStacksTo = [];
64
62
  var enableSequenceStackTraces = () => {
65
63
  if (!getRemotionEnvironment().isStudio) {
@@ -78,7 +76,7 @@ var enableSequenceStackTraces = () => {
78
76
  return Reflect.apply(target, thisArg, argArray);
79
77
  }
80
78
  });
81
- React2.createElement = proxy;
79
+ React.createElement = proxy;
82
80
  };
83
81
  var addSequenceStackTraces = (component) => {
84
82
  componentsToAddStacksTo.push(component);
@@ -107,7 +105,7 @@ function truthy(value) {
107
105
  }
108
106
 
109
107
  // src/version.ts
110
- var VERSION = "4.0.346";
108
+ var VERSION = "4.0.348";
111
109
 
112
110
  // src/multiple-versions-warning.ts
113
111
  var checkMultipleRemotionVersions = () => {
@@ -253,9 +251,9 @@ import { createContext as createContext3 } from "react";
253
251
  var SequenceContext = createContext3(null);
254
252
 
255
253
  // src/SequenceManager.tsx
256
- import React4, { useCallback, useMemo as useMemo2, useState } from "react";
254
+ import React3, { useCallback, useMemo as useMemo2, useState } from "react";
257
255
  import { jsx as jsx3 } from "react/jsx-runtime";
258
- var SequenceManager = React4.createContext({
256
+ var SequenceManager = React3.createContext({
259
257
  registerSequence: () => {
260
258
  throw new Error("SequenceManagerContext not initialized");
261
259
  },
@@ -264,7 +262,7 @@ var SequenceManager = React4.createContext({
264
262
  },
265
263
  sequences: []
266
264
  });
267
- var SequenceVisibilityToggleContext = React4.createContext({
265
+ var SequenceVisibilityToggleContext = React3.createContext({
268
266
  hidden: {},
269
267
  setHidden: () => {
270
268
  throw new Error("SequenceVisibilityToggle not initialized");
@@ -343,6 +341,12 @@ import { createContext as createContext8, useContext as useContext6, useMemo as
343
341
 
344
342
  // src/use-remotion-environment.ts
345
343
  import { useContext as useContext3, useState as useState3 } from "react";
344
+
345
+ // src/remotion-environment-context.ts
346
+ import React4 from "react";
347
+ var RemotionEnvironmentContext = React4.createContext(null);
348
+
349
+ // src/use-remotion-environment.ts
346
350
  var useRemotionEnvironment = () => {
347
351
  const context = useContext3(RemotionEnvironmentContext);
348
352
  const [env] = useState3(() => getRemotionEnvironment());
@@ -4451,6 +4455,13 @@ var useMediaMutedState = () => {
4451
4455
  }, [mediaMuted, setMediaMuted]);
4452
4456
  };
4453
4457
 
4458
+ // src/volume-safeguard.ts
4459
+ var warnAboutTooHighVolume = (volume) => {
4460
+ if (volume >= 100) {
4461
+ throw new Error(`Volume was set to ${volume}, but regular volume is 1, not 100. Did you forget to divide by 100? Set a volume of less than 100 to dismiss this error.`);
4462
+ }
4463
+ };
4464
+
4454
4465
  // src/audio/AudioForPreview.tsx
4455
4466
  import { jsx as jsx17 } from "react/jsx-runtime";
4456
4467
  var AudioForDevelopmentForwardRefFunction = (props, ref) => {
@@ -4506,6 +4517,7 @@ var AudioForDevelopmentForwardRefFunction = (props, ref) => {
4506
4517
  volume,
4507
4518
  mediaVolume
4508
4519
  });
4520
+ warnAboutTooHighVolume(userPreferredVolume);
4509
4521
  const crossOriginValue = getCrossOriginValue({
4510
4522
  crossOrigin,
4511
4523
  requestsVideoFrame: false
@@ -4663,6 +4675,7 @@ var AudioForRenderingRefForwardingFunction = (props, ref) => {
4663
4675
  frame: volumePropFrame,
4664
4676
  mediaVolume: 1
4665
4677
  });
4678
+ warnAboutTooHighVolume(volume);
4666
4679
  useImperativeHandle6(ref, () => {
4667
4680
  return audioRef.current;
4668
4681
  }, []);
@@ -6131,6 +6144,7 @@ var VideoForDevelopmentRefForwardingFunction = (props2, ref) => {
6131
6144
  volume,
6132
6145
  mediaVolume
6133
6146
  });
6147
+ warnAboutTooHighVolume(userPreferredVolume);
6134
6148
  useMediaInTimeline({
6135
6149
  mediaRef: videoRef,
6136
6150
  volume,
@@ -6468,7 +6482,8 @@ var Internals = {
6468
6482
  playbackLogging,
6469
6483
  timeValueRef,
6470
6484
  compositionSelectorRef,
6471
- RemotionEnvironmentContext
6485
+ RemotionEnvironmentContext,
6486
+ warnAboutTooHighVolume
6472
6487
  };
6473
6488
  // src/interpolate-colors.ts
6474
6489
  var NUMBER = "[-+]?\\d*\\.?\\d+";
@@ -7356,6 +7371,7 @@ var OffthreadVideoForRendering = ({
7356
7371
  frame: volumePropsFrame,
7357
7372
  mediaVolume: 1
7358
7373
  });
7374
+ warnAboutTooHighVolume(volume);
7359
7375
  useEffect20(() => {
7360
7376
  if (!src) {
7361
7377
  throw new Error("No src passed");
@@ -7768,6 +7784,7 @@ var VideoForRenderingForwardFunction = ({
7768
7784
  frame: volumePropsFrame,
7769
7785
  mediaVolume: 1
7770
7786
  });
7787
+ warnAboutTooHighVolume(volume);
7771
7788
  useEffect21(() => {
7772
7789
  if (!props2.src) {
7773
7790
  throw new Error("No src passed");
@@ -131,10 +131,6 @@ var random = (seed, dummy) => {
131
131
  }
132
132
  throw new Error("random() argument must be a number or a string");
133
133
  };
134
- // src/get-remotion-environment.ts
135
- import React from "react";
136
- var RemotionEnvironmentContext = React.createContext(null);
137
-
138
134
  // src/truthy.ts
139
135
  function truthy(value) {
140
136
  return Boolean(value);
@@ -1,5 +1,5 @@
1
1
  // src/version.ts
2
- var VERSION = "4.0.346";
2
+ var VERSION = "4.0.348";
3
3
  export {
4
4
  VERSION
5
5
  };
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "url": "https://github.com/remotion-dev/remotion/tree/main/packages/core"
4
4
  },
5
5
  "name": "remotion",
6
- "version": "4.0.346",
6
+ "version": "4.0.348",
7
7
  "description": "Make videos programmatically",
8
8
  "main": "dist/cjs/index.js",
9
9
  "types": "dist/cjs/index.d.ts",
@@ -28,7 +28,7 @@
28
28
  "webpack": "5.96.1",
29
29
  "zod": "3.22.3",
30
30
  "eslint": "9.19.0",
31
- "@remotion/eslint-config-internal": "4.0.346"
31
+ "@remotion/eslint-config-internal": "4.0.348"
32
32
  },
33
33
  "keywords": [
34
34
  "video",
@@ -1,4 +0,0 @@
1
- export declare const useAudioChannelIndex: ({ ref, audioChannelIndex, }: {
2
- ref: React.RefObject<HTMLVideoElement | HTMLAudioElement | null>;
3
- audioChannelIndex: number;
4
- }) => void;
@@ -1,13 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.useAudioChannelIndex = void 0;
4
- const react_1 = require("react");
5
- const useAudioChannelIndex = ({ ref, audioChannelIndex, }) => {
6
- (0, react_1.useEffect)(() => {
7
- var _a;
8
- // @ts-expect-error
9
- const audioChannels = (_a = ref === null || ref === void 0 ? void 0 : ref.current) === null || _a === void 0 ? void 0 : _a.audioTracks;
10
- console.log({ audioChannels, audioChannelIndex });
11
- }, [ref, audioChannelIndex]);
12
- };
13
- exports.useAudioChannelIndex = useAudioChannelIndex;