Comparing version 4.0.143 to 4.0.144
export declare const injectCSS: (css: string) => void; | ||
export declare const OFFTHREAD_VIDEO_CLASS_NAME = "__remotion_offthreadvideo"; | ||
export declare const makeDefaultCSS: (scope: string | null, backgroundColor: string) => string; | ||
export declare const makeDefaultPreviewCSS: (scope: string | null, backgroundColor: string) => string; |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.makeDefaultCSS = exports.OFFTHREAD_VIDEO_CLASS_NAME = exports.injectCSS = void 0; | ||
exports.makeDefaultPreviewCSS = exports.OFFTHREAD_VIDEO_CLASS_NAME = exports.injectCSS = void 0; | ||
const injected = {}; | ||
@@ -21,3 +21,3 @@ const injectCSS = (css) => { | ||
exports.OFFTHREAD_VIDEO_CLASS_NAME = '__remotion_offthreadvideo'; | ||
const makeDefaultCSS = (scope, backgroundColor) => { | ||
const makeDefaultPreviewCSS = (scope, backgroundColor) => { | ||
if (!scope) { | ||
@@ -50,2 +50,2 @@ return ` | ||
}; | ||
exports.makeDefaultCSS = makeDefaultCSS; | ||
exports.makeDefaultPreviewCSS = makeDefaultPreviewCSS; |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.getStaticFiles = void 0; | ||
const v5_flag_1 = require("./v5-flag"); | ||
let warnedServer = false; | ||
@@ -27,2 +28,5 @@ let warnedPlayer = false; | ||
const getStaticFiles = () => { | ||
if (v5_flag_1.ENABLE_V5_BREAKING_CHANGES) { | ||
throw new Error('getStaticFiles() has moved into the `@remotion/studio` package. Update your imports.'); | ||
} | ||
if (typeof document === 'undefined') { | ||
@@ -29,0 +33,0 @@ warnServerOnce(); |
@@ -93,3 +93,3 @@ /// <reference types="bun-types" /> | ||
export { registerRoot } from './register-root.js'; | ||
export { LayoutAndStyle, Sequence, SequenceProps, SequencePropsWithoutDuration, } from './Sequence.js'; | ||
export { AbsoluteFillLayout, LayoutAndStyle, Sequence, SequenceProps, SequencePropsWithoutDuration, } from './Sequence.js'; | ||
export { Series } from './series/index.js'; | ||
@@ -96,0 +96,0 @@ export * from './spring/index.js'; |
export type ExtrapolateType = 'extend' | 'identity' | 'clamp' | 'wrap'; | ||
/** | ||
* @description This function allows you to map a range of values to another with a conside syntax | ||
* @description This function allows you to map a range of values to another with a concise syntax | ||
* @see [Documentation](https://www.remotion.dev/docs/interpolate) | ||
@@ -5,0 +5,0 @@ */ |
import React from 'react'; | ||
import type { LoopDisplay } from './CompositionManager.js'; | ||
export type LayoutAndStyle = { | ||
export type AbsoluteFillLayout = { | ||
layout?: 'absolute-fill'; | ||
@@ -8,31 +8,32 @@ premountFor?: number; | ||
className?: string; | ||
} | { | ||
}; | ||
export type LayoutAndStyle = AbsoluteFillLayout | { | ||
layout: 'none'; | ||
}; | ||
export type SequencePropsWithoutDuration = { | ||
children: React.ReactNode; | ||
width?: number; | ||
height?: number; | ||
from?: number; | ||
name?: string; | ||
showInTimeline?: boolean; | ||
readonly children: React.ReactNode; | ||
readonly width?: number; | ||
readonly height?: number; | ||
readonly from?: number; | ||
readonly name?: string; | ||
readonly showInTimeline?: boolean; | ||
/** | ||
* @deprecated For internal use only. | ||
*/ | ||
_remotionInternalLoopDisplay?: LoopDisplay; | ||
readonly _remotionInternalLoopDisplay?: LoopDisplay; | ||
/** | ||
* @deprecated For internal use only. | ||
*/ | ||
_remotionInternalPremountDisplay?: number | null; | ||
readonly _remotionInternalPremountDisplay?: number | null; | ||
/** | ||
* @deprecated For internal use only. | ||
*/ | ||
_remotionInternalStack?: string; | ||
readonly _remotionInternalStack?: string; | ||
/** | ||
* @deprecated For internal use only. | ||
*/ | ||
_remotionInternalIsPremounting?: boolean; | ||
readonly _remotionInternalIsPremounting?: boolean; | ||
} & LayoutAndStyle; | ||
export type SequenceProps = { | ||
durationInFrames?: number; | ||
readonly durationInFrames?: number; | ||
} & SequencePropsWithoutDuration; | ||
@@ -39,0 +40,0 @@ /** |
@@ -10,6 +10,8 @@ "use strict"; | ||
const flatten_children_js_1 = require("./flatten-children.js"); | ||
const is_inside_series_js_1 = require("./is-inside-series.js"); | ||
const SeriesSequenceRefForwardingFunction = ({ children }, _ref) => { | ||
(0, is_inside_series_js_1.useRequireToBeInsideSeries)(); | ||
// Discard ref | ||
// eslint-disable-next-line react/jsx-no-useless-fragment | ||
return (0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, { children: children }); | ||
return (0, jsx_runtime_1.jsx)(is_inside_series_js_1.IsNotInsideSeriesProvider, { children: children }); | ||
}; | ||
@@ -66,4 +68,3 @@ const SeriesSequence = (0, react_1.forwardRef)(SeriesSequenceRefForwardingFunction); | ||
}, [children]); | ||
/* eslint-disable react/jsx-no-useless-fragment */ | ||
return (0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, { children: childrenValue }); | ||
return (0, jsx_runtime_1.jsx)(is_inside_series_js_1.IsInsideSeriesContainer, { children: childrenValue }); | ||
}; | ||
@@ -70,0 +71,0 @@ exports.Series = Series; |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.measureSpring = exports.spring = void 0; | ||
const interpolate_js_1 = require("../interpolate.js"); | ||
const validate_frame_js_1 = require("../validate-frame.js"); | ||
@@ -67,12 +68,10 @@ const validate_fps_js_1 = require("../validation/validate-fps.js"); | ||
config, | ||
from, | ||
to, | ||
}); | ||
if (!config.overshootClamping) { | ||
return spr.current; | ||
} | ||
if (to >= from) { | ||
return Math.min(spr.current, to); | ||
} | ||
return Math.max(spr.current, to); | ||
const inner = config.overshootClamping | ||
? to >= from | ||
? Math.min(spr.current, to) | ||
: Math.max(spr.current, to) | ||
: spr.current; | ||
const interpolated = from === 0 && to === 1 ? inner : (0, interpolate_js_1.interpolate)(inner, [0, 1], [from, to]); | ||
return interpolated; | ||
} | ||
@@ -79,0 +78,0 @@ exports.spring = spring; |
@@ -52,4 +52,2 @@ "use strict"; | ||
config, | ||
from, | ||
to, | ||
}); | ||
@@ -56,0 +54,0 @@ }; |
@@ -14,5 +14,3 @@ type AnimationNode = { | ||
}; | ||
export declare function springCalculation({ from, to, frame, fps, config, }: { | ||
from?: number; | ||
to?: number; | ||
export declare function springCalculation({ frame, fps, config, }: { | ||
frame: number; | ||
@@ -19,0 +17,0 @@ fps: number; |
@@ -63,6 +63,6 @@ "use strict"; | ||
const calculationCache = {}; | ||
function springCalculation({ from = 0, to = 1, frame, fps, config = {}, }) { | ||
function springCalculation({ frame, fps, config = {}, }) { | ||
const from = 0; | ||
const to = 1; | ||
const cacheKey = [ | ||
from, | ||
to, | ||
frame, | ||
@@ -69,0 +69,0 @@ fps, |
import type { VideoConfig } from './video-config.js'; | ||
/** | ||
* /** | ||
* @description Get some info about the context of the video that you are making. | ||
* @see [Documentation](https://www.remotion.dev/docs/use-video-config) | ||
* @returns Returns an object containing `fps`, `width`, `height` and `durationInFrames`, all of type `number`. | ||
* @returns Returns an object containing `fps`, `width`, `height`, `durationInFrames`, `id` and `defaultProps`. | ||
*/ | ||
export declare const useVideoConfig: () => VideoConfig; |
@@ -9,6 +9,5 @@ "use strict"; | ||
/** | ||
* /** | ||
* @description Get some info about the context of the video that you are making. | ||
* @see [Documentation](https://www.remotion.dev/docs/use-video-config) | ||
* @returns Returns an object containing `fps`, `width`, `height` and `durationInFrames`, all of type `number`. | ||
* @returns Returns an object containing `fps`, `width`, `height`, `durationInFrames`, `id` and `defaultProps`. | ||
*/ | ||
@@ -15,0 +14,0 @@ const useVideoConfig = () => { |
@@ -1,1 +0,6 @@ | ||
export declare const VERSION = "4.0.143"; | ||
/** | ||
* @description Provides the current version number of the Remotion library. | ||
* @see [Documentation](https://remotion.dev/docs/version) | ||
* @returns {string} The current version of the remotion package | ||
*/ | ||
export declare const VERSION = "4.0.144"; |
"use strict"; | ||
// Automatically generated on publish | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.VERSION = void 0; | ||
// Automatically generated on publish | ||
exports.VERSION = '4.0.143'; | ||
/** | ||
* @description Provides the current version number of the Remotion library. | ||
* @see [Documentation](https://remotion.dev/docs/version) | ||
* @returns {string} The current version of the remotion package | ||
*/ | ||
exports.VERSION = '4.0.144'; |
@@ -5,2 +5,3 @@ "use strict"; | ||
const get_remotion_environment_1 = require("./get-remotion-environment"); | ||
const v5_flag_1 = require("./v5-flag"); | ||
exports.WATCH_REMOTION_STATIC_FILES = 'remotion_staticFilesChanged'; | ||
@@ -15,2 +16,5 @@ /** | ||
const watchStaticFile = (fileName, callback) => { | ||
if (v5_flag_1.ENABLE_V5_BREAKING_CHANGES) { | ||
throw new Error('watchStaticFile() has moved into the `@remotion/studio` package. Update your imports.'); | ||
} | ||
// Check if function is called in Remotion Studio | ||
@@ -17,0 +21,0 @@ if (!(0, get_remotion_environment_1.getRemotionEnvironment)().isStudio) { |
@@ -10,2 +10,8 @@ const path = require('node:path'); | ||
// Automatically generated on publish | ||
/** | ||
* @description Provides the current version number of the Remotion library. | ||
* @see [Documentation](https://remotion.dev/docs/version) | ||
* @returns {string} The current version of the remotion package | ||
*/ | ||
export const VERSION = '${version}'; | ||
@@ -12,0 +18,0 @@ `.trim() + '\n'; |
# Remotion License | ||
In Remotion 5.0, the license will slightly change. [View the changes here](https://github.com/remotion-dev/remotion/pull/3750). | ||
--- | ||
Depending on the type of your legal entity, you are granted permission to use Remotion for your project. Individuals and small companies are allowed to use Remotion to create videos for free (even commercial), while a company license is required for for-profit organizations of a certain size. This two-tier system was designed to ensure funding for this project while still allowing the source code to be available and the program to be free for most. Read below for the exact terms of use. | ||
@@ -4,0 +8,0 @@ |
{ | ||
"name": "remotion", | ||
"version": "4.0.143", | ||
"version": "4.0.144", | ||
"description": "Render videos in React", | ||
@@ -5,0 +5,0 @@ "main": "dist/cjs/index.js", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
638454
245
14654