remotion 4.0.481 → 4.0.483
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/cjs/CompositionManager.d.ts +1 -0
- package/dist/cjs/HtmlInCanvas.d.ts +74 -0
- package/dist/cjs/HtmlInCanvas.js +68 -26
- package/dist/cjs/Img.d.ts +7 -0
- package/dist/cjs/Img.js +5 -5
- package/dist/cjs/Interactive.d.ts +86 -1
- package/dist/cjs/Interactive.js +4 -2
- package/dist/cjs/Sequence.d.ts +1 -0
- package/dist/cjs/Sequence.js +25 -6
- package/dist/cjs/audio/AudioForPreview.js +3 -3
- package/dist/cjs/audio/html5-audio.js +6 -2
- package/dist/cjs/canvas-image/CanvasImage.d.ts +7 -0
- package/dist/cjs/canvas-image/CanvasImage.js +2 -2
- package/dist/cjs/easing.d.ts +5 -2
- package/dist/cjs/easing.js +19 -3
- package/dist/cjs/effects/Solid.d.ts +95 -0
- package/dist/cjs/effects/Solid.js +14 -5
- package/dist/cjs/effects/use-memoized-effects.js +1 -0
- package/dist/cjs/get-effective-visual-mode-value.js +2 -0
- package/dist/cjs/interactivity-schema.d.ts +116 -1
- package/dist/cjs/interactivity-schema.js +81 -1
- package/dist/cjs/internals.d.ts +88 -2
- package/dist/cjs/internals.js +2 -1
- package/dist/cjs/interpolate-keyframed-status.d.ts +2 -1
- package/dist/cjs/interpolate-keyframed-status.js +14 -11
- package/dist/cjs/interpolate.d.ts +3 -1
- package/dist/cjs/interpolate.js +56 -12
- package/dist/cjs/no-react.d.ts +7 -0
- package/dist/cjs/prefetch.js +15 -10
- package/dist/cjs/use-media-in-timeline.js +1 -0
- package/dist/cjs/use-schema.d.ts +2 -0
- package/dist/cjs/use-schema.js +20 -0
- package/dist/cjs/version.d.ts +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/cjs/video/VideoForPreview.js +2 -2
- package/dist/cjs/volume-position-state.d.ts +4 -4
- package/dist/cjs/volume-position-state.js +9 -9
- package/dist/esm/index.mjs +351 -79
- package/dist/esm/no-react.mjs +70 -11
- package/dist/esm/version.mjs +1 -1
- package/package.json +2 -2
|
@@ -281,7 +281,7 @@ const CanvasImageContent = (0, react_1.forwardRef)(({ src, width, height, fit =
|
|
|
281
281
|
return (jsx_runtime_1.jsx("canvas", { ...canvasProps, ref: canvasRef, width: width, height: height, className: className, style: style, id: id }));
|
|
282
282
|
});
|
|
283
283
|
CanvasImageContent.displayName = 'CanvasImageContent';
|
|
284
|
-
const CanvasImageInner = (0, react_1.forwardRef)(({ src, width, height, fit, effects = [], className, style, id, onError, pauseWhenLoading, maxRetries, delayRenderRetries, delayRenderTimeoutInMilliseconds, durationInFrames, from, freeze, hidden, name, showInTimeline, stack, controls, _remotionInternalDocumentationLink, outlineRef, ...canvasProps }, ref) => {
|
|
284
|
+
const CanvasImageInner = (0, react_1.forwardRef)(({ src, width, height, fit, effects = [], className, style, id, onError, pauseWhenLoading, maxRetries, delayRenderRetries, delayRenderTimeoutInMilliseconds, durationInFrames, from, trimBefore, freeze, hidden, name, showInTimeline, stack, controls, _remotionInternalDocumentationLink, outlineRef, ...canvasProps }, ref) => {
|
|
285
285
|
if (!src) {
|
|
286
286
|
throw new Error('No "src" prop was passed to <CanvasImage>.');
|
|
287
287
|
}
|
|
@@ -290,7 +290,7 @@ const CanvasImageInner = (0, react_1.forwardRef)(({ src, width, height, fit, eff
|
|
|
290
290
|
(0, react_1.useImperativeHandle)(ref, () => {
|
|
291
291
|
return actualRef.current;
|
|
292
292
|
}, []);
|
|
293
|
-
return (jsx_runtime_1.jsx(Sequence_js_1.Sequence, { layout: "none", from: from !== null && from !== void 0 ? from : 0, durationInFrames: durationInFrames !== null && durationInFrames !== void 0 ? durationInFrames : Infinity, freeze: freeze, hidden: hidden, showInTimeline: showInTimeline !== null && showInTimeline !== void 0 ? showInTimeline : true, name: name !== null && name !== void 0 ? name : '<CanvasImage>', _remotionInternalDocumentationLink: _remotionInternalDocumentationLink !== null && _remotionInternalDocumentationLink !== void 0 ? _remotionInternalDocumentationLink : 'https://www.remotion.dev/docs/canvasimage', controls: controls, _remotionInternalEffects: memoizedEffectDefinitions, _remotionInternalIsMedia: { type: 'image', src }, _remotionInternalStack: stack, outlineRef: outlineRef !== null && outlineRef !== void 0 ? outlineRef : actualRef, children: jsx_runtime_1.jsx(CanvasImageContent, { ref: actualRef, src: src, width: width, height: height, fit: fit, effects: effects, controls: controls, className: className, style: style, id: id, onError: onError, pauseWhenLoading: pauseWhenLoading, maxRetries: maxRetries, delayRenderRetries: delayRenderRetries, delayRenderTimeoutInMilliseconds: delayRenderTimeoutInMilliseconds, refForOutline: outlineRef !== null && outlineRef !== void 0 ? outlineRef : null, ...canvasProps }) }));
|
|
293
|
+
return (jsx_runtime_1.jsx(Sequence_js_1.Sequence, { layout: "none", from: from !== null && from !== void 0 ? from : 0, trimBefore: trimBefore, durationInFrames: durationInFrames !== null && durationInFrames !== void 0 ? durationInFrames : Infinity, freeze: freeze, hidden: hidden, showInTimeline: showInTimeline !== null && showInTimeline !== void 0 ? showInTimeline : true, name: name !== null && name !== void 0 ? name : '<CanvasImage>', _remotionInternalDocumentationLink: _remotionInternalDocumentationLink !== null && _remotionInternalDocumentationLink !== void 0 ? _remotionInternalDocumentationLink : 'https://www.remotion.dev/docs/canvasimage', controls: controls, _remotionInternalEffects: memoizedEffectDefinitions, _remotionInternalIsMedia: { type: 'image', src }, _remotionInternalStack: stack, outlineRef: outlineRef !== null && outlineRef !== void 0 ? outlineRef : actualRef, children: jsx_runtime_1.jsx(CanvasImageContent, { ref: actualRef, src: src, width: width, height: height, fit: fit, effects: effects, controls: controls, className: className, style: style, id: id, onError: onError, pauseWhenLoading: pauseWhenLoading, maxRetries: maxRetries, delayRenderRetries: delayRenderRetries, delayRenderTimeoutInMilliseconds: delayRenderTimeoutInMilliseconds, refForOutline: outlineRef !== null && outlineRef !== void 0 ? outlineRef : null, ...canvasProps }) }));
|
|
294
294
|
});
|
|
295
295
|
/*
|
|
296
296
|
* @description Renders a static image to a `<canvas>` and applies Remotion effects.
|
package/dist/cjs/easing.d.ts
CHANGED
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
import type { SpringConfig } from './spring/spring-utils.js';
|
|
2
|
-
export type EasingSpringConfig = Partial<Pick<SpringConfig, 'damping' | 'mass' | 'stiffness' | 'overshootClamping'
|
|
2
|
+
export type EasingSpringConfig = Partial<Pick<SpringConfig, 'damping' | 'mass' | 'stiffness' | 'overshootClamping'>> & {
|
|
3
|
+
readonly allowTail?: boolean;
|
|
4
|
+
readonly durationRestThreshold?: number;
|
|
5
|
+
};
|
|
3
6
|
/**
|
|
4
7
|
* @description The Easing module implements common easing functions. You can use it with the interpolate() API.
|
|
5
8
|
* @see [Documentation](https://www.remotion.dev/docs/easing)
|
|
@@ -17,7 +20,7 @@ export declare class Easing {
|
|
|
17
20
|
static exp(t: number): number;
|
|
18
21
|
static elastic(bounciness?: number): (t: number) => number;
|
|
19
22
|
static back(s?: number): (t: number) => number;
|
|
20
|
-
static spring(config?: EasingSpringConfig): (t: number) => number;
|
|
23
|
+
static spring({ allowTail, durationRestThreshold, ...config }?: EasingSpringConfig): (t: number) => number;
|
|
21
24
|
static bounce(t: number): number;
|
|
22
25
|
static bezier(x1: number, y1: number, x2: number, y2: number): (t: number) => number;
|
|
23
26
|
static in(easing: (t: number) => number): (t: number) => number;
|
package/dist/cjs/easing.js
CHANGED
|
@@ -52,21 +52,37 @@ class Easing {
|
|
|
52
52
|
static back(s = 1.70158) {
|
|
53
53
|
return (t) => t * t * ((s + 1) * t - s);
|
|
54
54
|
}
|
|
55
|
-
static spring(config = {}) {
|
|
56
|
-
|
|
55
|
+
static spring({ allowTail = false, durationRestThreshold, ...config } = {}) {
|
|
56
|
+
const easing = (t) => {
|
|
57
57
|
if (t <= 0) {
|
|
58
58
|
return 0;
|
|
59
59
|
}
|
|
60
|
-
if (t >= 1) {
|
|
60
|
+
if (!allowTail && t >= 1) {
|
|
61
61
|
return 1;
|
|
62
62
|
}
|
|
63
|
+
if (allowTail) {
|
|
64
|
+
return (0, index_js_1.spring)({
|
|
65
|
+
fps: springEasingDurationInFrames,
|
|
66
|
+
frame: t *
|
|
67
|
+
(0, index_js_1.measureSpring)({
|
|
68
|
+
fps: springEasingDurationInFrames,
|
|
69
|
+
config,
|
|
70
|
+
threshold: durationRestThreshold,
|
|
71
|
+
}),
|
|
72
|
+
config,
|
|
73
|
+
});
|
|
74
|
+
}
|
|
63
75
|
return (0, index_js_1.spring)({
|
|
64
76
|
fps: springEasingDurationInFrames,
|
|
65
77
|
frame: t * springEasingDurationInFrames,
|
|
66
78
|
config,
|
|
67
79
|
durationInFrames: springEasingDurationInFrames,
|
|
80
|
+
durationRestThreshold,
|
|
68
81
|
});
|
|
69
82
|
};
|
|
83
|
+
return Object.assign(easing, {
|
|
84
|
+
remotionShouldExtendRight: allowTail,
|
|
85
|
+
});
|
|
70
86
|
}
|
|
71
87
|
static bounce(t) {
|
|
72
88
|
const u = clampUnit(t);
|
|
@@ -13,5 +13,100 @@ type OptionalProps = {
|
|
|
13
13
|
readonly pixelDensity: number | undefined;
|
|
14
14
|
};
|
|
15
15
|
export type SolidProps = MandatoryProps & Partial<OptionalProps>;
|
|
16
|
+
export declare const solidSchema: {
|
|
17
|
+
readonly 'style.transformOrigin': {
|
|
18
|
+
readonly type: "transform-origin";
|
|
19
|
+
readonly step: 1;
|
|
20
|
+
readonly default: "50% 50%";
|
|
21
|
+
readonly description: "Transform origin";
|
|
22
|
+
};
|
|
23
|
+
readonly 'style.translate': {
|
|
24
|
+
readonly type: "translate";
|
|
25
|
+
readonly step: 1;
|
|
26
|
+
readonly default: "0px 0px";
|
|
27
|
+
readonly description: "Offset";
|
|
28
|
+
};
|
|
29
|
+
readonly 'style.scale': {
|
|
30
|
+
readonly type: "scale";
|
|
31
|
+
readonly max: 100;
|
|
32
|
+
readonly step: 0.01;
|
|
33
|
+
readonly default: 1;
|
|
34
|
+
readonly description: "Scale";
|
|
35
|
+
};
|
|
36
|
+
readonly 'style.rotate': {
|
|
37
|
+
readonly type: "rotation-css";
|
|
38
|
+
readonly step: 1;
|
|
39
|
+
readonly default: "0deg";
|
|
40
|
+
readonly description: "Rotation";
|
|
41
|
+
};
|
|
42
|
+
readonly 'style.opacity': {
|
|
43
|
+
readonly type: "number";
|
|
44
|
+
readonly min: 0;
|
|
45
|
+
readonly max: 1;
|
|
46
|
+
readonly step: 0.01;
|
|
47
|
+
readonly default: 1;
|
|
48
|
+
readonly description: "Opacity";
|
|
49
|
+
readonly hiddenFromList: false;
|
|
50
|
+
};
|
|
51
|
+
readonly durationInFrames: {
|
|
52
|
+
readonly type: "number";
|
|
53
|
+
readonly default: undefined;
|
|
54
|
+
readonly min: 1;
|
|
55
|
+
readonly step: 1;
|
|
56
|
+
readonly hiddenFromList: true;
|
|
57
|
+
};
|
|
58
|
+
readonly from: {
|
|
59
|
+
readonly type: "number";
|
|
60
|
+
readonly default: 0;
|
|
61
|
+
readonly step: 1;
|
|
62
|
+
readonly hiddenFromList: true;
|
|
63
|
+
};
|
|
64
|
+
readonly trimBefore: {
|
|
65
|
+
readonly type: "number";
|
|
66
|
+
readonly default: 0;
|
|
67
|
+
readonly min: 0;
|
|
68
|
+
readonly step: 1;
|
|
69
|
+
readonly hiddenFromList: true;
|
|
70
|
+
};
|
|
71
|
+
readonly freeze: {
|
|
72
|
+
readonly type: "number";
|
|
73
|
+
readonly default: null;
|
|
74
|
+
readonly step: 1;
|
|
75
|
+
readonly hiddenFromList: true;
|
|
76
|
+
};
|
|
77
|
+
readonly hidden: import("../interactivity-schema.js").BooleanFieldSchema;
|
|
78
|
+
readonly name: import("../interactivity-schema.js").HiddenFieldSchema;
|
|
79
|
+
readonly showInTimeline: import("../interactivity-schema.js").HiddenFieldSchema;
|
|
80
|
+
readonly color: {
|
|
81
|
+
readonly type: "color";
|
|
82
|
+
readonly default: "transparent";
|
|
83
|
+
readonly description: "Color";
|
|
84
|
+
};
|
|
85
|
+
readonly width: {
|
|
86
|
+
readonly type: "number";
|
|
87
|
+
readonly min: 1;
|
|
88
|
+
readonly step: 1;
|
|
89
|
+
readonly default: 1920;
|
|
90
|
+
readonly description: "Width";
|
|
91
|
+
readonly hiddenFromList: false;
|
|
92
|
+
};
|
|
93
|
+
readonly height: {
|
|
94
|
+
readonly type: "number";
|
|
95
|
+
readonly min: 1;
|
|
96
|
+
readonly step: 1;
|
|
97
|
+
readonly default: 1080;
|
|
98
|
+
readonly description: "Height";
|
|
99
|
+
readonly hiddenFromList: false;
|
|
100
|
+
};
|
|
101
|
+
readonly pixelDensity: {
|
|
102
|
+
readonly type: "number";
|
|
103
|
+
readonly min: 1;
|
|
104
|
+
readonly max: 3;
|
|
105
|
+
readonly step: 0.1;
|
|
106
|
+
readonly default: 1;
|
|
107
|
+
readonly description: "Pixel density";
|
|
108
|
+
readonly hiddenFromList: false;
|
|
109
|
+
};
|
|
110
|
+
};
|
|
16
111
|
export declare const Solid: React.ComponentType<MandatoryProps & Partial<OptionalProps> & InteractiveBaseProps & React.RefAttributes<HTMLCanvasElement>>;
|
|
17
112
|
export {};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.Solid = void 0;
|
|
3
|
+
exports.Solid = exports.solidSchema = void 0;
|
|
4
4
|
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
5
5
|
const react_1 = require("react");
|
|
6
6
|
const enable_sequence_stack_traces_js_1 = require("../enable-sequence-stack-traces.js");
|
|
@@ -22,7 +22,7 @@ const resolveSolidPixelDensity = (pixelDensity) => {
|
|
|
22
22
|
}
|
|
23
23
|
return pixelDensity;
|
|
24
24
|
};
|
|
25
|
-
|
|
25
|
+
exports.solidSchema = {
|
|
26
26
|
...interactivity_schema_js_1.baseSchema,
|
|
27
27
|
color: {
|
|
28
28
|
type: 'color',
|
|
@@ -45,6 +45,15 @@ const solidSchema = {
|
|
|
45
45
|
description: 'Height',
|
|
46
46
|
hiddenFromList: false,
|
|
47
47
|
},
|
|
48
|
+
pixelDensity: {
|
|
49
|
+
type: 'number',
|
|
50
|
+
min: 1,
|
|
51
|
+
max: 3,
|
|
52
|
+
step: 0.1,
|
|
53
|
+
default: 1,
|
|
54
|
+
description: 'Pixel density',
|
|
55
|
+
hiddenFromList: false,
|
|
56
|
+
},
|
|
48
57
|
...interactivity_schema_js_1.transformSchema,
|
|
49
58
|
};
|
|
50
59
|
const SolidInner = ({ color, width, height, effects = [], className, style, pixelDensity, overrideId, reference, }) => {
|
|
@@ -138,7 +147,7 @@ const SolidInner = ({ color, width, height, effects = [], className, style, pixe
|
|
|
138
147
|
}, [height, style, width]);
|
|
139
148
|
return (jsx_runtime_1.jsx("canvas", { ref: canvasRef, width: canvasWidth, height: canvasHeight, className: className, style: canvasStyle }));
|
|
140
149
|
};
|
|
141
|
-
const SolidOuter = (0, react_1.forwardRef)(({ effects = [], controls, color, height, width, className, durationInFrames, style, name, from, freeze, hidden, showInTimeline, pixelDensity, ...props }, ref) => {
|
|
150
|
+
const SolidOuter = (0, react_1.forwardRef)(({ effects = [], controls, color, height, width, className, durationInFrames, style, name, from, trimBefore, freeze, hidden, showInTimeline, pixelDensity, ...props }, ref) => {
|
|
142
151
|
var _a;
|
|
143
152
|
props;
|
|
144
153
|
const memoizedEffectDefinitions = (0, use_memoized_effects_js_1.useMemoizedEffectDefinitions)(effects);
|
|
@@ -146,13 +155,13 @@ const SolidOuter = (0, react_1.forwardRef)(({ effects = [], controls, color, hei
|
|
|
146
155
|
(0, react_1.useImperativeHandle)(ref, () => {
|
|
147
156
|
return actualRef.current;
|
|
148
157
|
}, []);
|
|
149
|
-
return (jsx_runtime_1.jsx(Sequence_js_1.Sequence, { layout: "none", from: from, freeze: freeze, hidden: hidden, showInTimeline: showInTimeline, controls: controls, _remotionInternalEffects: memoizedEffectDefinitions, durationInFrames: durationInFrames, name: name !== null && name !== void 0 ? name : '<Solid>', outlineRef: actualRef, _remotionInternalDocumentationLink: "https://www.remotion.dev/docs/solid", ...props, children: jsx_runtime_1.jsx(SolidInner, { reference: actualRef, overrideId: (_a = controls === null || controls === void 0 ? void 0 : controls.overrideId) !== null && _a !== void 0 ? _a : null, color: color, height: height, width: width, className: className, style: style, effects: effects, pixelDensity: pixelDensity }) }));
|
|
158
|
+
return (jsx_runtime_1.jsx(Sequence_js_1.Sequence, { layout: "none", from: from, trimBefore: trimBefore, freeze: freeze, hidden: hidden, showInTimeline: showInTimeline, controls: controls, _remotionInternalEffects: memoizedEffectDefinitions, durationInFrames: durationInFrames, name: name !== null && name !== void 0 ? name : '<Solid>', outlineRef: actualRef, _remotionInternalDocumentationLink: "https://www.remotion.dev/docs/solid", ...props, children: jsx_runtime_1.jsx(SolidInner, { reference: actualRef, overrideId: (_a = controls === null || controls === void 0 ? void 0 : controls.overrideId) !== null && _a !== void 0 ? _a : null, color: color, height: height, width: width, className: className, style: style, effects: effects, pixelDensity: pixelDensity }) }));
|
|
150
159
|
});
|
|
151
160
|
exports.Solid = (0, with_interactivity_schema_js_1.withInteractivitySchema)({
|
|
152
161
|
Component: SolidOuter,
|
|
153
162
|
componentName: '<Solid>',
|
|
154
163
|
componentIdentity: 'dev.remotion.remotion.Solid',
|
|
155
|
-
schema: solidSchema,
|
|
164
|
+
schema: exports.solidSchema,
|
|
156
165
|
supportsEffects: true,
|
|
157
166
|
});
|
|
158
167
|
exports.Solid.displayName = 'Solid';
|
|
@@ -13,6 +13,7 @@ const resolveDragOverrideValue = ({ dragOverrideValue, frame, }) => {
|
|
|
13
13
|
return { type: 'none' };
|
|
14
14
|
}
|
|
15
15
|
const interpolated = (0, interpolate_keyframed_status_1.interpolateKeyframedStatus)({
|
|
16
|
+
forceSpringAllowTail: null,
|
|
16
17
|
frame,
|
|
17
18
|
status: dragOverrideValue.status,
|
|
18
19
|
});
|
|
@@ -33,6 +34,7 @@ const getEffectiveVisualModeValue = ({ propStatus, dragOverrideValue, defaultVal
|
|
|
33
34
|
if (propStatus.status === 'keyframed') {
|
|
34
35
|
if (frame !== null) {
|
|
35
36
|
return (0, interpolate_keyframed_status_1.interpolateKeyframedStatus)({
|
|
37
|
+
forceSpringAllowTail: null,
|
|
36
38
|
frame,
|
|
37
39
|
status: propStatus,
|
|
38
40
|
});
|
|
@@ -62,7 +62,16 @@ export type UvCoordinateFieldSchema = {
|
|
|
62
62
|
min?: number;
|
|
63
63
|
max?: number;
|
|
64
64
|
step?: number;
|
|
65
|
-
|
|
65
|
+
visual?: {
|
|
66
|
+
readonly type: 'line';
|
|
67
|
+
readonly to: string;
|
|
68
|
+
} | {
|
|
69
|
+
readonly type: 'ellipse';
|
|
70
|
+
readonly width: string;
|
|
71
|
+
readonly height: string;
|
|
72
|
+
readonly rotation?: string;
|
|
73
|
+
readonly innerScale?: string;
|
|
74
|
+
};
|
|
66
75
|
default: readonly [number, number] | undefined;
|
|
67
76
|
description?: string;
|
|
68
77
|
keyframable?: boolean;
|
|
@@ -180,6 +189,77 @@ export declare const sequenceVisualStyleSchema: {
|
|
|
180
189
|
readonly hiddenFromList: false;
|
|
181
190
|
};
|
|
182
191
|
};
|
|
192
|
+
export declare const textSchema: {
|
|
193
|
+
readonly 'style.color': {
|
|
194
|
+
readonly type: "color";
|
|
195
|
+
readonly default: undefined;
|
|
196
|
+
readonly description: "Color";
|
|
197
|
+
};
|
|
198
|
+
readonly 'style.fontSize': {
|
|
199
|
+
readonly type: "number";
|
|
200
|
+
readonly default: undefined;
|
|
201
|
+
readonly min: 0;
|
|
202
|
+
readonly step: 1;
|
|
203
|
+
readonly description: "Font size";
|
|
204
|
+
readonly hiddenFromList: false;
|
|
205
|
+
};
|
|
206
|
+
readonly 'style.lineHeight': {
|
|
207
|
+
readonly type: "number";
|
|
208
|
+
readonly default: undefined;
|
|
209
|
+
readonly min: 0;
|
|
210
|
+
readonly step: 0.05;
|
|
211
|
+
readonly description: "Line height";
|
|
212
|
+
readonly hiddenFromList: false;
|
|
213
|
+
};
|
|
214
|
+
readonly 'style.fontWeight': {
|
|
215
|
+
readonly type: "enum";
|
|
216
|
+
readonly default: "400";
|
|
217
|
+
readonly description: "Font weight";
|
|
218
|
+
readonly variants: {
|
|
219
|
+
readonly '100': {};
|
|
220
|
+
readonly '200': {};
|
|
221
|
+
readonly '300': {};
|
|
222
|
+
readonly '400': {};
|
|
223
|
+
readonly '500': {};
|
|
224
|
+
readonly '600': {};
|
|
225
|
+
readonly '700': {};
|
|
226
|
+
readonly '800': {};
|
|
227
|
+
readonly '900': {};
|
|
228
|
+
readonly normal: {};
|
|
229
|
+
readonly bold: {};
|
|
230
|
+
};
|
|
231
|
+
};
|
|
232
|
+
readonly 'style.fontStyle': {
|
|
233
|
+
readonly type: "enum";
|
|
234
|
+
readonly default: "normal";
|
|
235
|
+
readonly description: "Font style";
|
|
236
|
+
readonly variants: {
|
|
237
|
+
readonly normal: {};
|
|
238
|
+
readonly italic: {};
|
|
239
|
+
readonly oblique: {};
|
|
240
|
+
};
|
|
241
|
+
};
|
|
242
|
+
readonly 'style.textAlign': {
|
|
243
|
+
readonly type: "enum";
|
|
244
|
+
readonly default: "left";
|
|
245
|
+
readonly description: "Text align";
|
|
246
|
+
readonly variants: {
|
|
247
|
+
readonly left: {};
|
|
248
|
+
readonly center: {};
|
|
249
|
+
readonly right: {};
|
|
250
|
+
readonly justify: {};
|
|
251
|
+
readonly start: {};
|
|
252
|
+
readonly end: {};
|
|
253
|
+
};
|
|
254
|
+
};
|
|
255
|
+
readonly 'style.letterSpacing': {
|
|
256
|
+
readonly type: "number";
|
|
257
|
+
readonly default: undefined;
|
|
258
|
+
readonly step: 0.1;
|
|
259
|
+
readonly description: "Letter spacing";
|
|
260
|
+
readonly hiddenFromList: false;
|
|
261
|
+
};
|
|
262
|
+
};
|
|
183
263
|
export declare const premountSchema: {
|
|
184
264
|
readonly premountFor: {
|
|
185
265
|
readonly type: "number";
|
|
@@ -301,6 +381,13 @@ export declare const fromField: {
|
|
|
301
381
|
readonly step: 1;
|
|
302
382
|
readonly hiddenFromList: true;
|
|
303
383
|
};
|
|
384
|
+
export declare const trimBeforeField: {
|
|
385
|
+
readonly type: "number";
|
|
386
|
+
readonly default: 0;
|
|
387
|
+
readonly min: 0;
|
|
388
|
+
readonly step: 1;
|
|
389
|
+
readonly hiddenFromList: true;
|
|
390
|
+
};
|
|
304
391
|
export declare const freezeField: {
|
|
305
392
|
readonly type: "number";
|
|
306
393
|
readonly default: null;
|
|
@@ -321,6 +408,13 @@ export declare const baseSchema: {
|
|
|
321
408
|
readonly step: 1;
|
|
322
409
|
readonly hiddenFromList: true;
|
|
323
410
|
};
|
|
411
|
+
readonly trimBefore: {
|
|
412
|
+
readonly type: "number";
|
|
413
|
+
readonly default: 0;
|
|
414
|
+
readonly min: 0;
|
|
415
|
+
readonly step: 1;
|
|
416
|
+
readonly hiddenFromList: true;
|
|
417
|
+
};
|
|
324
418
|
readonly freeze: {
|
|
325
419
|
readonly type: "number";
|
|
326
420
|
readonly default: null;
|
|
@@ -345,6 +439,13 @@ export declare const sequenceSchema: {
|
|
|
345
439
|
readonly step: 1;
|
|
346
440
|
readonly hiddenFromList: true;
|
|
347
441
|
};
|
|
442
|
+
readonly trimBefore: {
|
|
443
|
+
readonly type: "number";
|
|
444
|
+
readonly default: 0;
|
|
445
|
+
readonly min: 0;
|
|
446
|
+
readonly step: 1;
|
|
447
|
+
readonly hiddenFromList: true;
|
|
448
|
+
};
|
|
348
449
|
readonly freeze: {
|
|
349
450
|
readonly type: "number";
|
|
350
451
|
readonly default: null;
|
|
@@ -428,6 +529,13 @@ export declare const baseSchemaWithoutFrom: {
|
|
|
428
529
|
readonly step: 1;
|
|
429
530
|
readonly hiddenFromList: true;
|
|
430
531
|
};
|
|
532
|
+
readonly trimBefore: {
|
|
533
|
+
readonly type: "number";
|
|
534
|
+
readonly default: 0;
|
|
535
|
+
readonly min: 0;
|
|
536
|
+
readonly step: 1;
|
|
537
|
+
readonly hiddenFromList: true;
|
|
538
|
+
};
|
|
431
539
|
readonly freeze: {
|
|
432
540
|
readonly type: "number";
|
|
433
541
|
readonly default: null;
|
|
@@ -446,6 +554,13 @@ export declare const sequenceSchemaWithoutFrom: {
|
|
|
446
554
|
readonly step: 1;
|
|
447
555
|
readonly hiddenFromList: true;
|
|
448
556
|
};
|
|
557
|
+
readonly trimBefore: {
|
|
558
|
+
readonly type: "number";
|
|
559
|
+
readonly default: 0;
|
|
560
|
+
readonly min: 0;
|
|
561
|
+
readonly step: 1;
|
|
562
|
+
readonly hiddenFromList: true;
|
|
563
|
+
};
|
|
449
564
|
readonly freeze: {
|
|
450
565
|
readonly type: "number";
|
|
451
566
|
readonly default: null;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.sequenceSchemaDefaultLayoutNone = exports.sequenceSchemaWithoutFrom = exports.baseSchemaWithoutFrom = exports.sequenceSchema = exports.baseSchema = exports.freezeField = exports.fromField = exports.durationInFramesField = exports.extendSchemaWithSequenceName = exports.sequenceNameField = exports.hiddenField = exports.sequenceStyleSchema = exports.sequencePremountSchema = exports.premountSchema = exports.sequenceVisualStyleSchema = exports.transformSchema = void 0;
|
|
3
|
+
exports.sequenceSchemaDefaultLayoutNone = exports.sequenceSchemaWithoutFrom = exports.baseSchemaWithoutFrom = exports.sequenceSchema = exports.baseSchema = exports.freezeField = exports.trimBeforeField = exports.fromField = exports.durationInFramesField = exports.extendSchemaWithSequenceName = exports.sequenceNameField = exports.hiddenField = exports.sequenceStyleSchema = exports.sequencePremountSchema = exports.premountSchema = exports.textSchema = exports.sequenceVisualStyleSchema = exports.transformSchema = void 0;
|
|
4
4
|
exports.transformSchema = {
|
|
5
5
|
'style.transformOrigin': {
|
|
6
6
|
type: 'transform-origin',
|
|
@@ -38,6 +38,77 @@ exports.transformSchema = {
|
|
|
38
38
|
},
|
|
39
39
|
};
|
|
40
40
|
exports.sequenceVisualStyleSchema = exports.transformSchema;
|
|
41
|
+
exports.textSchema = {
|
|
42
|
+
'style.color': {
|
|
43
|
+
type: 'color',
|
|
44
|
+
default: undefined,
|
|
45
|
+
description: 'Color',
|
|
46
|
+
},
|
|
47
|
+
'style.fontSize': {
|
|
48
|
+
type: 'number',
|
|
49
|
+
default: undefined,
|
|
50
|
+
min: 0,
|
|
51
|
+
step: 1,
|
|
52
|
+
description: 'Font size',
|
|
53
|
+
hiddenFromList: false,
|
|
54
|
+
},
|
|
55
|
+
'style.lineHeight': {
|
|
56
|
+
type: 'number',
|
|
57
|
+
default: undefined,
|
|
58
|
+
min: 0,
|
|
59
|
+
step: 0.05,
|
|
60
|
+
description: 'Line height',
|
|
61
|
+
hiddenFromList: false,
|
|
62
|
+
},
|
|
63
|
+
'style.fontWeight': {
|
|
64
|
+
type: 'enum',
|
|
65
|
+
default: '400',
|
|
66
|
+
description: 'Font weight',
|
|
67
|
+
variants: {
|
|
68
|
+
'100': {},
|
|
69
|
+
'200': {},
|
|
70
|
+
'300': {},
|
|
71
|
+
'400': {},
|
|
72
|
+
'500': {},
|
|
73
|
+
'600': {},
|
|
74
|
+
'700': {},
|
|
75
|
+
'800': {},
|
|
76
|
+
'900': {},
|
|
77
|
+
normal: {},
|
|
78
|
+
bold: {},
|
|
79
|
+
},
|
|
80
|
+
},
|
|
81
|
+
'style.fontStyle': {
|
|
82
|
+
type: 'enum',
|
|
83
|
+
default: 'normal',
|
|
84
|
+
description: 'Font style',
|
|
85
|
+
variants: {
|
|
86
|
+
normal: {},
|
|
87
|
+
italic: {},
|
|
88
|
+
oblique: {},
|
|
89
|
+
},
|
|
90
|
+
},
|
|
91
|
+
'style.textAlign': {
|
|
92
|
+
type: 'enum',
|
|
93
|
+
default: 'left',
|
|
94
|
+
description: 'Text align',
|
|
95
|
+
variants: {
|
|
96
|
+
left: {},
|
|
97
|
+
center: {},
|
|
98
|
+
right: {},
|
|
99
|
+
justify: {},
|
|
100
|
+
start: {},
|
|
101
|
+
end: {},
|
|
102
|
+
},
|
|
103
|
+
},
|
|
104
|
+
'style.letterSpacing': {
|
|
105
|
+
type: 'number',
|
|
106
|
+
default: undefined,
|
|
107
|
+
step: 0.1,
|
|
108
|
+
description: 'Letter spacing',
|
|
109
|
+
hiddenFromList: false,
|
|
110
|
+
},
|
|
111
|
+
};
|
|
41
112
|
exports.premountSchema = {
|
|
42
113
|
premountFor: {
|
|
43
114
|
type: 'number',
|
|
@@ -97,6 +168,13 @@ exports.fromField = {
|
|
|
97
168
|
step: 1,
|
|
98
169
|
hiddenFromList: true,
|
|
99
170
|
};
|
|
171
|
+
exports.trimBeforeField = {
|
|
172
|
+
type: 'number',
|
|
173
|
+
default: 0,
|
|
174
|
+
min: 0,
|
|
175
|
+
step: 1,
|
|
176
|
+
hiddenFromList: true,
|
|
177
|
+
};
|
|
100
178
|
exports.freezeField = {
|
|
101
179
|
type: 'number',
|
|
102
180
|
default: null,
|
|
@@ -106,6 +184,7 @@ exports.freezeField = {
|
|
|
106
184
|
exports.baseSchema = {
|
|
107
185
|
durationInFrames: exports.durationInFramesField,
|
|
108
186
|
from: exports.fromField,
|
|
187
|
+
trimBefore: exports.trimBeforeField,
|
|
109
188
|
freeze: exports.freezeField,
|
|
110
189
|
hidden: exports.hiddenField,
|
|
111
190
|
name: exports.sequenceNameField,
|
|
@@ -125,6 +204,7 @@ exports.sequenceSchema = {
|
|
|
125
204
|
};
|
|
126
205
|
exports.baseSchemaWithoutFrom = {
|
|
127
206
|
durationInFrames: exports.durationInFramesField,
|
|
207
|
+
trimBefore: exports.trimBeforeField,
|
|
128
208
|
freeze: exports.freezeField,
|
|
129
209
|
hidden: exports.hiddenField,
|
|
130
210
|
name: exports.sequenceNameField,
|
package/dist/cjs/internals.d.ts
CHANGED
|
@@ -91,6 +91,13 @@ export declare const Internals: {
|
|
|
91
91
|
readonly step: 1;
|
|
92
92
|
readonly hiddenFromList: true;
|
|
93
93
|
};
|
|
94
|
+
readonly trimBefore: {
|
|
95
|
+
readonly type: "number";
|
|
96
|
+
readonly default: 0;
|
|
97
|
+
readonly min: 0;
|
|
98
|
+
readonly step: 1;
|
|
99
|
+
readonly hiddenFromList: true;
|
|
100
|
+
};
|
|
94
101
|
readonly freeze: {
|
|
95
102
|
readonly type: "number";
|
|
96
103
|
readonly default: null;
|
|
@@ -115,6 +122,13 @@ export declare const Internals: {
|
|
|
115
122
|
readonly step: 1;
|
|
116
123
|
readonly hiddenFromList: true;
|
|
117
124
|
};
|
|
125
|
+
readonly trimBefore: {
|
|
126
|
+
readonly type: "number";
|
|
127
|
+
readonly default: 0;
|
|
128
|
+
readonly min: 0;
|
|
129
|
+
readonly step: 1;
|
|
130
|
+
readonly hiddenFromList: true;
|
|
131
|
+
};
|
|
118
132
|
readonly freeze: {
|
|
119
133
|
readonly type: "number";
|
|
120
134
|
readonly default: null;
|
|
@@ -307,6 +321,77 @@ export declare const Internals: {
|
|
|
307
321
|
readonly type: "hidden";
|
|
308
322
|
};
|
|
309
323
|
};
|
|
324
|
+
readonly textSchema: {
|
|
325
|
+
readonly 'style.color': {
|
|
326
|
+
readonly type: "color";
|
|
327
|
+
readonly default: undefined;
|
|
328
|
+
readonly description: "Color";
|
|
329
|
+
};
|
|
330
|
+
readonly 'style.fontSize': {
|
|
331
|
+
readonly type: "number";
|
|
332
|
+
readonly default: undefined;
|
|
333
|
+
readonly min: 0;
|
|
334
|
+
readonly step: 1;
|
|
335
|
+
readonly description: "Font size";
|
|
336
|
+
readonly hiddenFromList: false;
|
|
337
|
+
};
|
|
338
|
+
readonly 'style.lineHeight': {
|
|
339
|
+
readonly type: "number";
|
|
340
|
+
readonly default: undefined;
|
|
341
|
+
readonly min: 0;
|
|
342
|
+
readonly step: 0.05;
|
|
343
|
+
readonly description: "Line height";
|
|
344
|
+
readonly hiddenFromList: false;
|
|
345
|
+
};
|
|
346
|
+
readonly 'style.fontWeight': {
|
|
347
|
+
readonly type: "enum";
|
|
348
|
+
readonly default: "400";
|
|
349
|
+
readonly description: "Font weight";
|
|
350
|
+
readonly variants: {
|
|
351
|
+
readonly '100': {};
|
|
352
|
+
readonly '200': {};
|
|
353
|
+
readonly '300': {};
|
|
354
|
+
readonly '400': {};
|
|
355
|
+
readonly '500': {};
|
|
356
|
+
readonly '600': {};
|
|
357
|
+
readonly '700': {};
|
|
358
|
+
readonly '800': {};
|
|
359
|
+
readonly '900': {};
|
|
360
|
+
readonly normal: {};
|
|
361
|
+
readonly bold: {};
|
|
362
|
+
};
|
|
363
|
+
};
|
|
364
|
+
readonly 'style.fontStyle': {
|
|
365
|
+
readonly type: "enum";
|
|
366
|
+
readonly default: "normal";
|
|
367
|
+
readonly description: "Font style";
|
|
368
|
+
readonly variants: {
|
|
369
|
+
readonly normal: {};
|
|
370
|
+
readonly italic: {};
|
|
371
|
+
readonly oblique: {};
|
|
372
|
+
};
|
|
373
|
+
};
|
|
374
|
+
readonly 'style.textAlign': {
|
|
375
|
+
readonly type: "enum";
|
|
376
|
+
readonly default: "left";
|
|
377
|
+
readonly description: "Text align";
|
|
378
|
+
readonly variants: {
|
|
379
|
+
readonly left: {};
|
|
380
|
+
readonly center: {};
|
|
381
|
+
readonly right: {};
|
|
382
|
+
readonly justify: {};
|
|
383
|
+
readonly start: {};
|
|
384
|
+
readonly end: {};
|
|
385
|
+
};
|
|
386
|
+
};
|
|
387
|
+
readonly 'style.letterSpacing': {
|
|
388
|
+
readonly type: "number";
|
|
389
|
+
readonly default: undefined;
|
|
390
|
+
readonly step: 0.1;
|
|
391
|
+
readonly description: "Letter spacing";
|
|
392
|
+
readonly hiddenFromList: false;
|
|
393
|
+
};
|
|
394
|
+
};
|
|
310
395
|
readonly transformSchema: {
|
|
311
396
|
readonly 'style.transformOrigin': {
|
|
312
397
|
readonly type: "transform-origin";
|
|
@@ -390,7 +475,7 @@ export declare const Internals: {
|
|
|
390
475
|
}) | null;
|
|
391
476
|
readonly getRoot: () => import("react").FC<{}> | null;
|
|
392
477
|
readonly useMediaVolumeState: () => readonly [number, (u: number) => void];
|
|
393
|
-
readonly
|
|
478
|
+
readonly usePlayerMutedState: () => readonly [boolean, (u: import("react").SetStateAction<boolean>) => void];
|
|
394
479
|
readonly useMediaInTimeline: ({ volume, mediaVolume, src, mediaType, playbackRate, displayName, id, getStack, showInTimeline, premountDisplay, postmountDisplay, loopDisplay, documentationLink, refForOutline, }: {
|
|
395
480
|
volume: import("./volume-prop.js").VolumeProp | undefined;
|
|
396
481
|
mediaVolume: number;
|
|
@@ -774,8 +859,9 @@ export declare const Internals: {
|
|
|
774
859
|
merged: Record<string, unknown>;
|
|
775
860
|
propsToDelete: Set<string>;
|
|
776
861
|
};
|
|
777
|
-
readonly interpolateKeyframedStatus: ({ frame, status, }: {
|
|
862
|
+
readonly interpolateKeyframedStatus: ({ frame, forceSpringAllowTail, status, }: {
|
|
778
863
|
frame: number;
|
|
864
|
+
forceSpringAllowTail: boolean | null;
|
|
779
865
|
status: CanUpdateSequencePropStatusKeyframed;
|
|
780
866
|
}) => string | number | readonly number[] | null;
|
|
781
867
|
readonly makeStaticDragOverride: (value: unknown) => DragOverrideValue;
|