Comparing version 4.0.251 to 4.0.252
@@ -6,2 +6,3 @@ import './_check-rsc.js'; | ||
import type { StaticFile } from './get-static-files.js'; | ||
import type { LogLevel } from './log.js'; | ||
import type { VideoConfig } from './video-config.js'; | ||
@@ -33,2 +34,3 @@ export type VideoConfigWithSerializedProps = Omit<VideoConfig, 'defaultProps' | 'props'> & { | ||
remotion_numberOfAudioTags: number; | ||
remotion_logLevel: LogLevel; | ||
remotion_projectName: string; | ||
@@ -35,0 +37,0 @@ remotion_cwd: string; |
@@ -22,2 +22,3 @@ import { type CompProps } from './Composition.js'; | ||
readonly numberOfAudioTags: number; | ||
readonly logLevel: import("./log.js").LogLevel; | ||
}>; | ||
@@ -177,4 +178,5 @@ readonly useVideo: () => (import("./video-config.js").VideoConfig & { | ||
}; | ||
readonly LogLevelContext: import("react").Context<"error" | "trace" | "verbose" | "info" | "warn" | null>; | ||
readonly LogLevelContext: import("react").Context<"trace" | "verbose" | "info" | "warn" | "error" | null>; | ||
readonly useLogLevel: () => import("./log.js").LogLevel; | ||
}; | ||
export type { CompositionManagerContext, CompProps, MediaVolumeContextValue, RemotionEnvironment, SerializedJSONWithCustomFields, SetMediaVolumeContextValue, SetTimelineContextValue, TRenderAsset as TAsset, TCompMetadata, TComposition, TimelinePosition as Timeline, TimelineContextValue, TSequence, WatchRemotionStaticFilesPayload, }; |
@@ -131,2 +131,3 @@ "use strict"; | ||
LogLevelContext: log_level_context_js_1.LogLevelContext, | ||
useLogLevel: log_level_context_js_1.useLogLevel, | ||
}; |
import type { LogLevel } from './log'; | ||
import React = require('react'); | ||
export declare const LogLevelContext: React.Context<"error" | "trace" | "verbose" | "info" | "warn" | null>; | ||
export declare const LogLevelContext: React.Context<"trace" | "verbose" | "info" | "warn" | "error" | null>; | ||
export declare const useLogLevel: () => LogLevel; |
import React from 'react'; | ||
import type { LogLevel } from './log.js'; | ||
export declare const RemotionRoot: React.FC<{ | ||
readonly children: React.ReactNode; | ||
readonly numberOfAudioTags: number; | ||
readonly logLevel: LogLevel; | ||
}>; |
@@ -16,3 +16,3 @@ "use strict"; | ||
const duration_state_js_1 = require("./video/duration-state.js"); | ||
const RemotionRoot = ({ children, numberOfAudioTags }) => { | ||
const RemotionRoot = ({ children, numberOfAudioTags, logLevel }) => { | ||
const [remotionRootId] = (0, react_1.useState)(() => String((0, random_js_1.random)(null))); | ||
@@ -91,4 +91,4 @@ const [frame, setFrame] = (0, react_1.useState)(() => (0, timeline_position_state_js_1.getInitialFrameState)()); | ||
}, []); | ||
return ((0, jsx_runtime_1.jsx)(log_level_context_js_1.LogLevelContext.Provider, { value: 'info', children: (0, jsx_runtime_1.jsx)(nonce_js_1.NonceContext.Provider, { value: nonceContext, children: (0, jsx_runtime_1.jsx)(timeline_position_state_js_1.TimelineContext.Provider, { value: timelineContextValue, children: (0, jsx_runtime_1.jsx)(timeline_position_state_js_1.SetTimelineContext.Provider, { value: setTimelineContextValue, children: (0, jsx_runtime_1.jsx)(EditorProps_js_1.EditorPropsProvider, { children: (0, jsx_runtime_1.jsx)(prefetch_state_js_1.PrefetchProvider, { children: (0, jsx_runtime_1.jsx)(CompositionManager_js_1.CompositionManagerProvider, { numberOfAudioTags: numberOfAudioTags, children: (0, jsx_runtime_1.jsx)(duration_state_js_1.DurationsContextProvider, { children: (0, jsx_runtime_1.jsx)(buffering_js_1.BufferingProvider, { children: children }) }) }) }) }) }) }) }) })); | ||
return ((0, jsx_runtime_1.jsx)(log_level_context_js_1.LogLevelContext.Provider, { value: logLevel, children: (0, jsx_runtime_1.jsx)(nonce_js_1.NonceContext.Provider, { value: nonceContext, children: (0, jsx_runtime_1.jsx)(timeline_position_state_js_1.TimelineContext.Provider, { value: timelineContextValue, children: (0, jsx_runtime_1.jsx)(timeline_position_state_js_1.SetTimelineContext.Provider, { value: setTimelineContextValue, children: (0, jsx_runtime_1.jsx)(EditorProps_js_1.EditorPropsProvider, { children: (0, jsx_runtime_1.jsx)(prefetch_state_js_1.PrefetchProvider, { children: (0, jsx_runtime_1.jsx)(CompositionManager_js_1.CompositionManagerProvider, { numberOfAudioTags: numberOfAudioTags, children: (0, jsx_runtime_1.jsx)(duration_state_js_1.DurationsContextProvider, { children: (0, jsx_runtime_1.jsx)(buffering_js_1.BufferingProvider, { children: children }) }) }) }) }) }) }) }) })); | ||
}; | ||
exports.RemotionRoot = RemotionRoot; |
@@ -7,2 +7,3 @@ import React from 'react'; | ||
style?: React.CSSProperties; | ||
styleWhilePremounted?: React.CSSProperties; | ||
className?: string; | ||
@@ -9,0 +10,0 @@ }; |
@@ -153,3 +153,3 @@ "use strict"; | ||
} | ||
const { style: passedStyle, from = 0, premountFor = 0, ...otherProps } = props; | ||
const { style: passedStyle, from = 0, premountFor = 0, styleWhilePremounted, ...otherProps } = props; | ||
const premountingActive = frame < from && frame >= from - premountFor; | ||
@@ -164,4 +164,5 @@ const style = (0, react_1.useMemo)(() => { | ||
: ((_a = passedStyle === null || passedStyle === void 0 ? void 0 : passedStyle.pointerEvents) !== null && _a !== void 0 ? _a : undefined), | ||
...(premountingActive ? styleWhilePremounted : {}), | ||
}; | ||
}, [premountingActive, passedStyle]); | ||
}, [passedStyle, premountingActive, styleWhilePremounted]); | ||
return ((0, jsx_runtime_1.jsx)(freeze_js_1.Freeze, { frame: from, active: premountingActive, children: (0, jsx_runtime_1.jsx)(exports.Sequence, { ref: ref, from: from, style: style, _remotionInternalPremountDisplay: premountFor, _remotionInternalIsPremounting: premountingActive, ...otherProps }) })); | ||
@@ -168,0 +169,0 @@ }; |
@@ -6,2 +6,2 @@ /** | ||
*/ | ||
export declare const VERSION = "4.0.251"; | ||
export declare const VERSION = "4.0.252"; |
@@ -10,2 +10,2 @@ "use strict"; | ||
*/ | ||
exports.VERSION = '4.0.251'; | ||
exports.VERSION = '4.0.252'; |
@@ -42,3 +42,3 @@ import React from 'react'; | ||
} | null; | ||
logLevelContext: "error" | "trace" | "verbose" | "info" | "warn" | null; | ||
logLevelContext: "trace" | "verbose" | "info" | "warn" | "error" | null; | ||
}; | ||
@@ -45,0 +45,0 @@ export interface RemotionContextProviderProps { |
@@ -6,3 +6,3 @@ { | ||
"name": "remotion", | ||
"version": "4.0.251", | ||
"version": "4.0.252", | ||
"description": "Make videos programmatically", | ||
@@ -32,3 +32,3 @@ "main": "dist/cjs/index.js", | ||
"eslint": "9.14.0", | ||
"@remotion/eslint-config-internal": "4.0.251" | ||
"@remotion/eslint-config-internal": "4.0.252" | ||
}, | ||
@@ -35,0 +35,0 @@ "keywords": [ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
689707
17631