@microfox/remotion 1.2.0 → 1.2.2
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/CHANGELOG.md +14 -0
- package/dist/index.d.mts +1165 -0
- package/dist/index.d.ts +1165 -0
- package/dist/index.js +4641 -0
- package/dist/index.js.map +1 -0
- package/dist/index.mjs +4519 -0
- package/dist/index.mjs.map +1 -0
- package/package.json +18 -11
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,1165 @@
|
|
|
1
|
+
import React$1, { CSSProperties, ReactNode, ComponentType as ComponentType$1 } from 'react';
|
|
2
|
+
import { CalculateMetadataFunction, VideoConfig } from 'remotion';
|
|
3
|
+
import { z } from 'zod';
|
|
4
|
+
|
|
5
|
+
type Boundaries = {
|
|
6
|
+
left?: number | string;
|
|
7
|
+
top?: number | string;
|
|
8
|
+
width?: number | string;
|
|
9
|
+
height?: number | string;
|
|
10
|
+
right?: number | string;
|
|
11
|
+
bottom?: number | string;
|
|
12
|
+
zIndex?: number;
|
|
13
|
+
};
|
|
14
|
+
type Timing = {
|
|
15
|
+
start?: number;
|
|
16
|
+
duration?: number;
|
|
17
|
+
};
|
|
18
|
+
type CalculatedBoundaries = {
|
|
19
|
+
left?: number;
|
|
20
|
+
top?: number;
|
|
21
|
+
right?: number;
|
|
22
|
+
bottom?: number;
|
|
23
|
+
width?: number;
|
|
24
|
+
height?: number;
|
|
25
|
+
zIndex?: number;
|
|
26
|
+
reset?: boolean;
|
|
27
|
+
};
|
|
28
|
+
type CalculatedTiming = {
|
|
29
|
+
startInFrames?: number;
|
|
30
|
+
durationInFrames?: number;
|
|
31
|
+
start?: number;
|
|
32
|
+
duration?: number;
|
|
33
|
+
fitDurationTo?: string[] | string;
|
|
34
|
+
};
|
|
35
|
+
type Hierarchy = {
|
|
36
|
+
depth: number;
|
|
37
|
+
parentIds: string[];
|
|
38
|
+
};
|
|
39
|
+
interface BaseRenderableContext {
|
|
40
|
+
overrideStyle?: CSSProperties;
|
|
41
|
+
}
|
|
42
|
+
interface RenderableContext extends BaseRenderableContext {
|
|
43
|
+
boundaries?: CalculatedBoundaries;
|
|
44
|
+
timing?: CalculatedTiming;
|
|
45
|
+
hierarchy?: Hierarchy;
|
|
46
|
+
}
|
|
47
|
+
interface InternalRenderableContext extends BaseRenderableContext {
|
|
48
|
+
boundaries: CalculatedBoundaries;
|
|
49
|
+
timing?: CalculatedTiming;
|
|
50
|
+
hierarchy: Hierarchy;
|
|
51
|
+
}
|
|
52
|
+
type RenderableData = {
|
|
53
|
+
[key: string]: any;
|
|
54
|
+
};
|
|
55
|
+
interface BaseComponentData {
|
|
56
|
+
id: string;
|
|
57
|
+
componentId: string;
|
|
58
|
+
type: ComponentType;
|
|
59
|
+
data?: RenderableData;
|
|
60
|
+
context?: RenderableContext;
|
|
61
|
+
childrenData?: RenderableComponentData[];
|
|
62
|
+
effects?: BaseEffect[];
|
|
63
|
+
}
|
|
64
|
+
type BaseEffect = string | {
|
|
65
|
+
id: string;
|
|
66
|
+
componentId: string;
|
|
67
|
+
data?: RenderableData;
|
|
68
|
+
context?: RenderableContext;
|
|
69
|
+
};
|
|
70
|
+
type ComponentType = 'atom' | 'layout' | 'frame' | 'scene' | 'transition';
|
|
71
|
+
interface AtomComponentData extends BaseComponentData {
|
|
72
|
+
type: 'atom';
|
|
73
|
+
data?: RenderableData & {
|
|
74
|
+
boundaries?: Boundaries;
|
|
75
|
+
};
|
|
76
|
+
context?: RenderableContext;
|
|
77
|
+
}
|
|
78
|
+
interface LayoutComponentData extends BaseComponentData {
|
|
79
|
+
type: 'layout';
|
|
80
|
+
data?: RenderableData & {
|
|
81
|
+
boundaries?: Boundaries;
|
|
82
|
+
timing?: Timing;
|
|
83
|
+
};
|
|
84
|
+
context?: RenderableContext;
|
|
85
|
+
}
|
|
86
|
+
interface FrameComponentData extends BaseComponentData {
|
|
87
|
+
type: 'frame';
|
|
88
|
+
data?: RenderableData & {
|
|
89
|
+
boundaries?: Boundaries;
|
|
90
|
+
timing?: Timing;
|
|
91
|
+
};
|
|
92
|
+
context?: RenderableContext;
|
|
93
|
+
}
|
|
94
|
+
interface SceneComponentData extends BaseComponentData {
|
|
95
|
+
type: 'scene';
|
|
96
|
+
data?: RenderableData & {
|
|
97
|
+
timing?: Timing;
|
|
98
|
+
};
|
|
99
|
+
}
|
|
100
|
+
interface TransitionComponentData extends BaseComponentData {
|
|
101
|
+
type: 'transition';
|
|
102
|
+
data?: RenderableData & {
|
|
103
|
+
timing?: Timing;
|
|
104
|
+
};
|
|
105
|
+
}
|
|
106
|
+
type RenderableComponentData = AtomComponentData | LayoutComponentData | FrameComponentData | SceneComponentData | TransitionComponentData;
|
|
107
|
+
interface BaseRenderableProps {
|
|
108
|
+
id: string;
|
|
109
|
+
componentId: string;
|
|
110
|
+
type: ComponentType;
|
|
111
|
+
data?: RenderableData;
|
|
112
|
+
context?: InternalRenderableContext;
|
|
113
|
+
children?: ReactNode;
|
|
114
|
+
}
|
|
115
|
+
interface BaseRenderableData extends BaseComponentData {
|
|
116
|
+
childrenData?: RenderableComponentData[];
|
|
117
|
+
context?: RenderableContext;
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
interface BoundaryConstraints {
|
|
121
|
+
x?: number | string;
|
|
122
|
+
y?: number | string;
|
|
123
|
+
width?: number | string;
|
|
124
|
+
height?: number | string;
|
|
125
|
+
zIndex?: number;
|
|
126
|
+
}
|
|
127
|
+
interface TimingConstraints {
|
|
128
|
+
startFrame?: number;
|
|
129
|
+
durationFrames?: number;
|
|
130
|
+
delay?: number;
|
|
131
|
+
}
|
|
132
|
+
interface LayoutConstraints {
|
|
133
|
+
alignment?: 'top-left' | 'top-center' | 'top-right' | 'center-left' | 'center' | 'center-right' | 'bottom-left' | 'bottom-center' | 'bottom-right';
|
|
134
|
+
padding?: number;
|
|
135
|
+
spacing?: number;
|
|
136
|
+
columns?: number;
|
|
137
|
+
rows?: number;
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
interface CompositionContext {
|
|
141
|
+
childrenData?: RenderableComponentData[];
|
|
142
|
+
width: number;
|
|
143
|
+
height: number;
|
|
144
|
+
duration: number;
|
|
145
|
+
fps: number;
|
|
146
|
+
currentFrame: number;
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
interface ComponentConfig {
|
|
150
|
+
displayName: string;
|
|
151
|
+
type?: ComponentType;
|
|
152
|
+
isInnerSequence?: boolean;
|
|
153
|
+
[key: string]: any;
|
|
154
|
+
}
|
|
155
|
+
interface ComponentRegistry {
|
|
156
|
+
[key: string]: {
|
|
157
|
+
component: React$1.ComponentType<BaseRenderableProps>;
|
|
158
|
+
config: ComponentConfig;
|
|
159
|
+
};
|
|
160
|
+
}
|
|
161
|
+
interface RegistryEntry {
|
|
162
|
+
type: ComponentType;
|
|
163
|
+
component: React$1.ComponentType<BaseRenderableProps>;
|
|
164
|
+
config: ComponentConfig;
|
|
165
|
+
package?: string;
|
|
166
|
+
}
|
|
167
|
+
interface PackageRegistry {
|
|
168
|
+
[packageName: string]: {
|
|
169
|
+
[componentName: string]: {
|
|
170
|
+
component: React$1.ComponentType<BaseRenderableProps>;
|
|
171
|
+
config: ComponentConfig;
|
|
172
|
+
};
|
|
173
|
+
};
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
declare class ComponentRegistryManager {
|
|
177
|
+
private registry;
|
|
178
|
+
private packageRegistry;
|
|
179
|
+
registerComponent(name: string, component: React$1.ComponentType<any>, type: 'frame' | 'layout' | 'atom', config?: ComponentConfig, packageName?: string): void;
|
|
180
|
+
registerEffect(name: string, component: React$1.ComponentType<any>, config?: ComponentConfig, packageName?: string): void;
|
|
181
|
+
getComponent(name: string): React$1.ComponentType<any> | undefined;
|
|
182
|
+
getComponentConfig(name: string): ComponentConfig | undefined;
|
|
183
|
+
getComponentWithConfig(name: string): {
|
|
184
|
+
component: React$1.ComponentType<any>;
|
|
185
|
+
config: ComponentConfig;
|
|
186
|
+
} | undefined;
|
|
187
|
+
registerPackage(packageName: string, components: Record<string, {
|
|
188
|
+
component: React$1.ComponentType<any>;
|
|
189
|
+
config: ComponentConfig;
|
|
190
|
+
}>): void;
|
|
191
|
+
getPackageComponents(packageName: string): Record<string, {
|
|
192
|
+
component: React$1.ComponentType<any>;
|
|
193
|
+
config: ComponentConfig;
|
|
194
|
+
}> | undefined;
|
|
195
|
+
getAllComponents(): ComponentRegistry;
|
|
196
|
+
clear(): void;
|
|
197
|
+
}
|
|
198
|
+
declare const componentRegistry: ComponentRegistryManager;
|
|
199
|
+
declare const registerComponent: (name: string, component: React$1.ComponentType<any>, type: "frame" | "layout" | "atom", config?: ComponentConfig, packageName?: string) => void;
|
|
200
|
+
declare const registerEffect: (name: string, component: React$1.ComponentType<any>, config?: ComponentConfig, packageName?: string) => void;
|
|
201
|
+
declare const registerPackage: (packageName: string, components: Record<string, {
|
|
202
|
+
component: React$1.ComponentType<any>;
|
|
203
|
+
config: ComponentConfig;
|
|
204
|
+
}>) => void;
|
|
205
|
+
declare const getComponent: (name: string) => React$1.ComponentType<any>;
|
|
206
|
+
declare const getComponentConfig: (name: string) => ComponentConfig;
|
|
207
|
+
declare const getComponentWithConfig: (name: string) => {
|
|
208
|
+
component: React$1.ComponentType<any>;
|
|
209
|
+
config: ComponentConfig;
|
|
210
|
+
};
|
|
211
|
+
|
|
212
|
+
interface CompositionContextValue {
|
|
213
|
+
root?: RenderableComponentData[];
|
|
214
|
+
duration: number;
|
|
215
|
+
}
|
|
216
|
+
interface CompositionProviderProps {
|
|
217
|
+
children: React$1.ReactNode;
|
|
218
|
+
value: CompositionContextValue;
|
|
219
|
+
}
|
|
220
|
+
declare const CompositionProvider: React$1.FC<CompositionProviderProps>;
|
|
221
|
+
declare const useComposition: () => CompositionContextValue;
|
|
222
|
+
|
|
223
|
+
interface CompositionProps extends BaseRenderableData {
|
|
224
|
+
id: string;
|
|
225
|
+
style?: React$1.CSSProperties;
|
|
226
|
+
config: {
|
|
227
|
+
width: number;
|
|
228
|
+
height: number;
|
|
229
|
+
fps: number;
|
|
230
|
+
duration: number;
|
|
231
|
+
fitDurationTo?: string | string[];
|
|
232
|
+
};
|
|
233
|
+
}
|
|
234
|
+
type InputCompositionProps = {
|
|
235
|
+
childrenData?: RenderableComponentData[];
|
|
236
|
+
style?: React$1.CSSProperties;
|
|
237
|
+
config?: {
|
|
238
|
+
width?: number;
|
|
239
|
+
height?: number;
|
|
240
|
+
fps?: number;
|
|
241
|
+
duration?: number;
|
|
242
|
+
fitDurationTo?: string;
|
|
243
|
+
};
|
|
244
|
+
};
|
|
245
|
+
declare const CompositionLayout: ({ childrenData, style, config }: InputCompositionProps) => React$1.JSX.Element;
|
|
246
|
+
declare const calculateCompositionLayoutMetadata: CalculateMetadataFunction<InputCompositionProps>;
|
|
247
|
+
declare const Composition: ({ id, childrenData, config, style }: CompositionProps) => React$1.JSX.Element;
|
|
248
|
+
declare const Player: (props: any) => React$1.JSX.Element;
|
|
249
|
+
|
|
250
|
+
declare const findMatchingComponents: (childrenData: RenderableComponentData[], targetIds: string[]) => RenderableComponentData[];
|
|
251
|
+
declare const findMatchingComponentsByQuery: (childrenData: RenderableComponentData[], query: {
|
|
252
|
+
type?: string;
|
|
253
|
+
componentId?: string;
|
|
254
|
+
}) => RenderableComponentData[];
|
|
255
|
+
declare const calculateComponentDuration: (component: Pick<RenderableComponentData, "data" | "componentId">) => Promise<number | undefined>;
|
|
256
|
+
declare const calculateDuration: (childrenData: RenderableComponentData[], config: {
|
|
257
|
+
fitDurationTo: string[] | string;
|
|
258
|
+
}) => Promise<number | undefined>;
|
|
259
|
+
declare const setDurationsInContext: (root: InputCompositionProps) => Promise<{
|
|
260
|
+
childrenData: RenderableComponentData[];
|
|
261
|
+
style?: React.CSSProperties;
|
|
262
|
+
config?: {
|
|
263
|
+
width?: number;
|
|
264
|
+
height?: number;
|
|
265
|
+
fps?: number;
|
|
266
|
+
duration?: number;
|
|
267
|
+
fitDurationTo?: string;
|
|
268
|
+
};
|
|
269
|
+
}>;
|
|
270
|
+
|
|
271
|
+
declare const useRenderContext: () => RenderableContext;
|
|
272
|
+
declare const ComponentRenderer: React$1.FC<BaseRenderableData>;
|
|
273
|
+
|
|
274
|
+
interface FrameProps extends BaseRenderableProps {
|
|
275
|
+
data?: {
|
|
276
|
+
style?: React$1.CSSProperties;
|
|
277
|
+
};
|
|
278
|
+
}
|
|
279
|
+
declare const Frame: ({ children, data }: FrameProps) => React$1.JSX.Element;
|
|
280
|
+
|
|
281
|
+
interface SceneFrameProps extends BaseRenderableProps {
|
|
282
|
+
children?: ReactNode;
|
|
283
|
+
}
|
|
284
|
+
declare const SceneFrame: React$1.FC<SceneFrameProps>;
|
|
285
|
+
|
|
286
|
+
interface BaseLayoutProps extends BaseRenderableProps {
|
|
287
|
+
children?: ReactNode;
|
|
288
|
+
data: {
|
|
289
|
+
isAbsoluteFill?: boolean;
|
|
290
|
+
containerProps?: any;
|
|
291
|
+
childrenProps?: any[];
|
|
292
|
+
repeatChildrenProps?: boolean;
|
|
293
|
+
};
|
|
294
|
+
}
|
|
295
|
+
declare const Layout: ComponentType$1<BaseLayoutProps>;
|
|
296
|
+
declare const config$c: ComponentConfig;
|
|
297
|
+
|
|
298
|
+
type Shape = 'circle' | 'rectangle' | 'star' | 'triangle';
|
|
299
|
+
interface ShapeAtomProps extends BaseRenderableProps {
|
|
300
|
+
data: {
|
|
301
|
+
shape: Shape;
|
|
302
|
+
color: string;
|
|
303
|
+
rotation?: {
|
|
304
|
+
duration: number;
|
|
305
|
+
};
|
|
306
|
+
style?: React$1.CSSProperties;
|
|
307
|
+
};
|
|
308
|
+
}
|
|
309
|
+
declare const Atom$5: React$1.FC<ShapeAtomProps>;
|
|
310
|
+
declare const config$b: ComponentConfig;
|
|
311
|
+
|
|
312
|
+
interface ImageAtomProps extends BaseRenderableProps {
|
|
313
|
+
data: {
|
|
314
|
+
src: string;
|
|
315
|
+
style?: React$1.CSSProperties;
|
|
316
|
+
className?: string;
|
|
317
|
+
proxySrc?: string;
|
|
318
|
+
};
|
|
319
|
+
}
|
|
320
|
+
declare const Atom$4: React$1.FC<ImageAtomProps>;
|
|
321
|
+
declare const config$a: ComponentConfig;
|
|
322
|
+
|
|
323
|
+
interface FontConfig$1 {
|
|
324
|
+
family: string;
|
|
325
|
+
weights?: string[];
|
|
326
|
+
subsets?: string[];
|
|
327
|
+
display?: 'auto' | 'block' | 'swap' | 'fallback' | 'optional';
|
|
328
|
+
preload?: boolean;
|
|
329
|
+
}
|
|
330
|
+
interface TextAtomData {
|
|
331
|
+
text: string;
|
|
332
|
+
style?: React$1.CSSProperties;
|
|
333
|
+
className?: string;
|
|
334
|
+
gradient?: string;
|
|
335
|
+
font?: FontConfig$1;
|
|
336
|
+
fallbackFonts?: string[];
|
|
337
|
+
loadingState?: {
|
|
338
|
+
showLoadingIndicator?: boolean;
|
|
339
|
+
loadingText?: string;
|
|
340
|
+
loadingStyle?: React$1.CSSProperties;
|
|
341
|
+
};
|
|
342
|
+
errorState?: {
|
|
343
|
+
showErrorIndicator?: boolean;
|
|
344
|
+
errorText?: string;
|
|
345
|
+
errorStyle?: React$1.CSSProperties;
|
|
346
|
+
};
|
|
347
|
+
}
|
|
348
|
+
interface TextAtomProps extends BaseRenderableProps {
|
|
349
|
+
data: TextAtomData;
|
|
350
|
+
}
|
|
351
|
+
/**
|
|
352
|
+
* Enhanced TextAtom with comprehensive dynamic font loading capabilities
|
|
353
|
+
*
|
|
354
|
+
* Features:
|
|
355
|
+
* - Dynamic Google Font loading with simplified API
|
|
356
|
+
* - Loading states with visual indicators
|
|
357
|
+
* - Error handling with fallbacks
|
|
358
|
+
* - Multiple font weights and subsets support
|
|
359
|
+
* - Font preloading for performance
|
|
360
|
+
* - Graceful degradation to system fonts
|
|
361
|
+
*/
|
|
362
|
+
declare const Atom$3: React$1.FC<TextAtomProps>;
|
|
363
|
+
declare const config$9: ComponentConfig;
|
|
364
|
+
|
|
365
|
+
declare const VideoAtomDataProps: z.ZodObject<{
|
|
366
|
+
src: z.ZodString;
|
|
367
|
+
srcDuration: z.ZodOptional<z.ZodNumber>;
|
|
368
|
+
style: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
|
|
369
|
+
containerClassName: z.ZodOptional<z.ZodString>;
|
|
370
|
+
className: z.ZodOptional<z.ZodString>;
|
|
371
|
+
startFrom: z.ZodOptional<z.ZodNumber>;
|
|
372
|
+
endAt: z.ZodOptional<z.ZodNumber>;
|
|
373
|
+
playbackRate: z.ZodOptional<z.ZodNumber>;
|
|
374
|
+
volume: z.ZodOptional<z.ZodNumber>;
|
|
375
|
+
muted: z.ZodOptional<z.ZodBoolean>;
|
|
376
|
+
loop: z.ZodOptional<z.ZodBoolean>;
|
|
377
|
+
fit: z.ZodOptional<z.ZodEnum<{
|
|
378
|
+
fill: "fill";
|
|
379
|
+
none: "none";
|
|
380
|
+
contain: "contain";
|
|
381
|
+
cover: "cover";
|
|
382
|
+
"scale-down": "scale-down";
|
|
383
|
+
}>>;
|
|
384
|
+
}, z.core.$strip>;
|
|
385
|
+
type VideoAtomDataProps = z.infer<typeof VideoAtomDataProps>;
|
|
386
|
+
/**
|
|
387
|
+
* Props interface for the VideoAtom component
|
|
388
|
+
* Extends base renderable props with video-specific data
|
|
389
|
+
*/
|
|
390
|
+
interface VideoAtomProps extends BaseRenderableProps {
|
|
391
|
+
data: VideoAtomDataProps;
|
|
392
|
+
}
|
|
393
|
+
/**
|
|
394
|
+
* VideoAtom Component
|
|
395
|
+
*
|
|
396
|
+
* A Remotion component that renders video with advanced control features:
|
|
397
|
+
* - Time-based trimming (start/end points)
|
|
398
|
+
* - Playback rate and volume control
|
|
399
|
+
* - Flexible styling and object fit options
|
|
400
|
+
* - Loop functionality
|
|
401
|
+
*
|
|
402
|
+
* @param data - Video configuration object containing all playback and styling settings
|
|
403
|
+
* @returns Remotion Video component with applied configurations
|
|
404
|
+
*/
|
|
405
|
+
declare const Atom$2: React$1.FC<VideoAtomProps>;
|
|
406
|
+
declare const config$8: ComponentConfig;
|
|
407
|
+
|
|
408
|
+
declare const AudioAtomDataProps: z.ZodObject<{
|
|
409
|
+
src: z.ZodString;
|
|
410
|
+
startFrom: z.ZodOptional<z.ZodNumber>;
|
|
411
|
+
endAt: z.ZodOptional<z.ZodNumber>;
|
|
412
|
+
volume: z.ZodOptional<z.ZodNumber>;
|
|
413
|
+
playbackRate: z.ZodOptional<z.ZodNumber>;
|
|
414
|
+
muted: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
415
|
+
type: z.ZodLiteral<"full">;
|
|
416
|
+
value: z.ZodBoolean;
|
|
417
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
418
|
+
type: z.ZodLiteral<"range">;
|
|
419
|
+
values: z.ZodArray<z.ZodObject<{
|
|
420
|
+
start: z.ZodNumber;
|
|
421
|
+
end: z.ZodNumber;
|
|
422
|
+
}, z.core.$strip>>;
|
|
423
|
+
}, z.core.$strip>]>>;
|
|
424
|
+
}, z.core.$strip>;
|
|
425
|
+
type AudioAtomDataProps = z.infer<typeof AudioAtomDataProps>;
|
|
426
|
+
/**
|
|
427
|
+
* Props interface for the AudioAtom component
|
|
428
|
+
* Extends base renderable props with audio-specific data
|
|
429
|
+
*/
|
|
430
|
+
interface AudioAtomProps extends BaseRenderableProps {
|
|
431
|
+
data: AudioAtomDataProps;
|
|
432
|
+
}
|
|
433
|
+
/**
|
|
434
|
+
* AudioAtom Component
|
|
435
|
+
*
|
|
436
|
+
* A Remotion component that renders audio with advanced control features:
|
|
437
|
+
* - Time-based trimming (start/end points)
|
|
438
|
+
* - Volume and playback rate control
|
|
439
|
+
* - Flexible muting (full track or specific time ranges)
|
|
440
|
+
*
|
|
441
|
+
* @param data - Audio configuration object containing all playback settings
|
|
442
|
+
* @returns Remotion Audio component with applied configurations
|
|
443
|
+
*/
|
|
444
|
+
declare const Atom$1: React$1.FC<AudioAtomProps>;
|
|
445
|
+
declare const config$7: ComponentConfig;
|
|
446
|
+
|
|
447
|
+
declare const LottieAtomDataProps: z.ZodObject<{
|
|
448
|
+
src: z.ZodString;
|
|
449
|
+
style: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
|
|
450
|
+
className: z.ZodOptional<z.ZodString>;
|
|
451
|
+
loop: z.ZodOptional<z.ZodBoolean>;
|
|
452
|
+
playbackRate: z.ZodOptional<z.ZodNumber>;
|
|
453
|
+
direction: z.ZodOptional<z.ZodEnum<{
|
|
454
|
+
reverse: "reverse";
|
|
455
|
+
forward: "forward";
|
|
456
|
+
}>>;
|
|
457
|
+
}, z.core.$strip>;
|
|
458
|
+
type LottieAtomDataProps = z.infer<typeof LottieAtomDataProps>;
|
|
459
|
+
/**
|
|
460
|
+
* Props interface for the LottieAtom component
|
|
461
|
+
* Extends base renderable props with Lottie-specific data
|
|
462
|
+
*/
|
|
463
|
+
interface LottieAtomProps extends BaseRenderableProps {
|
|
464
|
+
data: LottieAtomDataProps;
|
|
465
|
+
}
|
|
466
|
+
/**
|
|
467
|
+
* LottieAtom Component
|
|
468
|
+
*
|
|
469
|
+
* A Remotion component that renders Lottie animations with advanced control features:
|
|
470
|
+
* - Supports both local and remote Lottie JSON files
|
|
471
|
+
* - Playback rate control for speed adjustments
|
|
472
|
+
* - Direction control (forward/reverse)
|
|
473
|
+
* - Flexible styling options
|
|
474
|
+
* - Integration with Remotion's animation effects system
|
|
475
|
+
*
|
|
476
|
+
* @param data - Lottie configuration object containing all playback and styling settings
|
|
477
|
+
* @param id - Unique identifier for the component (used for animation effects)
|
|
478
|
+
* @returns Remotion Lottie component with applied configurations
|
|
479
|
+
*/
|
|
480
|
+
declare const Atom: React$1.FC<LottieAtomProps>;
|
|
481
|
+
/**
|
|
482
|
+
* Static configuration for LottieAtom
|
|
483
|
+
* Used for component registration and identification
|
|
484
|
+
*/
|
|
485
|
+
declare const config$6: ComponentConfig;
|
|
486
|
+
|
|
487
|
+
interface AnimationRange {
|
|
488
|
+
key: string;
|
|
489
|
+
val: any;
|
|
490
|
+
prog: number;
|
|
491
|
+
}
|
|
492
|
+
interface UniversalEffectData {
|
|
493
|
+
start?: number;
|
|
494
|
+
duration?: number;
|
|
495
|
+
type?: 'spring' | 'linear' | 'ease-in' | 'ease-out' | 'ease-in-out';
|
|
496
|
+
ranges?: AnimationRange[];
|
|
497
|
+
targetIds?: string[];
|
|
498
|
+
mode?: 'wrapper' | 'provider';
|
|
499
|
+
props?: any;
|
|
500
|
+
[key: string]: any;
|
|
501
|
+
}
|
|
502
|
+
interface UniversalEffectContextType {
|
|
503
|
+
animatedStyles: React$1.CSSProperties;
|
|
504
|
+
targetIds: string[];
|
|
505
|
+
effectType: string;
|
|
506
|
+
}
|
|
507
|
+
declare const useUniversalEffect: () => UniversalEffectContextType;
|
|
508
|
+
declare const useUniversalEffectOptional: () => UniversalEffectContextType;
|
|
509
|
+
declare const useHasUniversalEffectProvider: () => boolean;
|
|
510
|
+
|
|
511
|
+
declare const UniversalEffect: React$1.FC<BaseRenderableProps & {
|
|
512
|
+
effectType?: string;
|
|
513
|
+
customAnimationLogic?: (effectData: UniversalEffectData, progress: number, frame: number) => React$1.CSSProperties;
|
|
514
|
+
}>;
|
|
515
|
+
declare const UniversalEffectProvider: React$1.FC<{
|
|
516
|
+
children: ReactNode;
|
|
517
|
+
data: UniversalEffectData;
|
|
518
|
+
effectType?: string;
|
|
519
|
+
customAnimationLogic?: (effectData: UniversalEffectData, progress: number, frame: number) => React$1.CSSProperties;
|
|
520
|
+
id?: string;
|
|
521
|
+
componentId?: string;
|
|
522
|
+
type?: string;
|
|
523
|
+
}>;
|
|
524
|
+
declare const useAnimatedStyles: (componentId: string) => React$1.CSSProperties;
|
|
525
|
+
|
|
526
|
+
declare const BlurEffect: React$1.FC<BaseRenderableProps>;
|
|
527
|
+
declare const config$5: {
|
|
528
|
+
displayName: string;
|
|
529
|
+
description: string;
|
|
530
|
+
isInnerSequence: boolean;
|
|
531
|
+
props: {
|
|
532
|
+
intensity: {
|
|
533
|
+
type: string;
|
|
534
|
+
default: number;
|
|
535
|
+
description: string;
|
|
536
|
+
};
|
|
537
|
+
direction: {
|
|
538
|
+
type: string;
|
|
539
|
+
values: string[];
|
|
540
|
+
default: string;
|
|
541
|
+
description: string;
|
|
542
|
+
};
|
|
543
|
+
};
|
|
544
|
+
};
|
|
545
|
+
|
|
546
|
+
declare const LoopEffect: React$1.FC<BaseRenderableProps>;
|
|
547
|
+
declare const config$4: ComponentConfig;
|
|
548
|
+
|
|
549
|
+
interface PanEffectData {
|
|
550
|
+
effectTiming?: 'start' | 'end';
|
|
551
|
+
panDuration?: number | string;
|
|
552
|
+
panStart?: number;
|
|
553
|
+
panEnd?: number;
|
|
554
|
+
panStartDelay?: number | string;
|
|
555
|
+
panEndDelay?: number | string;
|
|
556
|
+
panDirection?: 'left' | 'right' | 'up' | 'down' | 'diagonal' | 'custom';
|
|
557
|
+
panDistance?: number | [number, number][];
|
|
558
|
+
loopTimes?: number;
|
|
559
|
+
panStartPosition?: [number, number] | string;
|
|
560
|
+
panEndPosition?: [number, number] | string;
|
|
561
|
+
animationType?: 'linear' | 'spring' | 'ease-in' | 'ease-out' | 'ease-in-out';
|
|
562
|
+
}
|
|
563
|
+
declare const PanEffect: React$1.FC<BaseRenderableProps>;
|
|
564
|
+
declare const config$3: ComponentConfig;
|
|
565
|
+
|
|
566
|
+
interface ZoomEffectData {
|
|
567
|
+
effectTiming?: 'start' | 'end';
|
|
568
|
+
zoomDuration?: number | string;
|
|
569
|
+
zoomStart?: number;
|
|
570
|
+
zoomEnd?: number;
|
|
571
|
+
zoomStartDelay?: number | string;
|
|
572
|
+
zoomEndDelay?: number | string;
|
|
573
|
+
zoomDirection?: 'in' | 'out';
|
|
574
|
+
zoomDepth?: number | [number, number][];
|
|
575
|
+
loopTimes?: number;
|
|
576
|
+
zoomPosition?: [number, number] | string;
|
|
577
|
+
animationType?: 'linear' | 'spring' | 'ease-in' | 'ease-out' | 'ease-in-out';
|
|
578
|
+
}
|
|
579
|
+
declare const ZoomEffect: React$1.FC<BaseRenderableProps>;
|
|
580
|
+
declare const config$2: ComponentConfig;
|
|
581
|
+
|
|
582
|
+
interface ShakeEffectData extends UniversalEffectData {
|
|
583
|
+
amplitude?: number;
|
|
584
|
+
frequency?: number;
|
|
585
|
+
decay?: boolean;
|
|
586
|
+
axis?: 'x' | 'y' | 'both';
|
|
587
|
+
}
|
|
588
|
+
declare const ShakeEffect: React$1.FC<BaseRenderableProps>;
|
|
589
|
+
declare const config$1: {
|
|
590
|
+
displayName: string;
|
|
591
|
+
description: string;
|
|
592
|
+
isInnerSequence: boolean;
|
|
593
|
+
props: {
|
|
594
|
+
amplitude: {
|
|
595
|
+
type: string;
|
|
596
|
+
default: number;
|
|
597
|
+
description: string;
|
|
598
|
+
};
|
|
599
|
+
frequency: {
|
|
600
|
+
type: string;
|
|
601
|
+
default: number;
|
|
602
|
+
description: string;
|
|
603
|
+
};
|
|
604
|
+
decay: {
|
|
605
|
+
type: string;
|
|
606
|
+
default: boolean;
|
|
607
|
+
description: string;
|
|
608
|
+
};
|
|
609
|
+
axis: {
|
|
610
|
+
type: string;
|
|
611
|
+
values: string[];
|
|
612
|
+
default: string;
|
|
613
|
+
description: string;
|
|
614
|
+
};
|
|
615
|
+
};
|
|
616
|
+
};
|
|
617
|
+
|
|
618
|
+
interface StretchEffectData extends UniversalEffectData {
|
|
619
|
+
stretchFrom?: number;
|
|
620
|
+
stretchTo?: number;
|
|
621
|
+
springConfig?: {
|
|
622
|
+
stiffness?: number;
|
|
623
|
+
damping?: number;
|
|
624
|
+
mass?: number;
|
|
625
|
+
};
|
|
626
|
+
}
|
|
627
|
+
declare const StretchEffect: React$1.FC<BaseRenderableProps>;
|
|
628
|
+
declare const config: {
|
|
629
|
+
displayName: string;
|
|
630
|
+
description: string;
|
|
631
|
+
isInnerSequence: boolean;
|
|
632
|
+
props: {
|
|
633
|
+
stretchFrom: {
|
|
634
|
+
type: string;
|
|
635
|
+
default: number;
|
|
636
|
+
description: string;
|
|
637
|
+
};
|
|
638
|
+
stretchTo: {
|
|
639
|
+
type: string;
|
|
640
|
+
default: number;
|
|
641
|
+
description: string;
|
|
642
|
+
};
|
|
643
|
+
};
|
|
644
|
+
};
|
|
645
|
+
|
|
646
|
+
declare const GenericEffectPresets: {
|
|
647
|
+
fadeInPreset: AnimationRange[];
|
|
648
|
+
fadeOutPreset: AnimationRange[];
|
|
649
|
+
scaleInPreset: AnimationRange[];
|
|
650
|
+
scaleOutPreset: AnimationRange[];
|
|
651
|
+
slideInLeftPreset: AnimationRange[];
|
|
652
|
+
slideInRightPreset: AnimationRange[];
|
|
653
|
+
slideInTopPreset: AnimationRange[];
|
|
654
|
+
slideInBottomPreset: AnimationRange[];
|
|
655
|
+
bouncePreset: AnimationRange[];
|
|
656
|
+
pulsePreset: AnimationRange[];
|
|
657
|
+
rotateInPreset: AnimationRange[];
|
|
658
|
+
blurInPreset: AnimationRange[];
|
|
659
|
+
fadeInScalePreset: AnimationRange[];
|
|
660
|
+
slideInFadePreset: AnimationRange[];
|
|
661
|
+
slideInLeftStringPreset: AnimationRange[];
|
|
662
|
+
slideInRightStringPreset: AnimationRange[];
|
|
663
|
+
slideInTopStringPreset: AnimationRange[];
|
|
664
|
+
slideInBottomStringPreset: AnimationRange[];
|
|
665
|
+
rotateInStringPreset: AnimationRange[];
|
|
666
|
+
blurInStringPreset: AnimationRange[];
|
|
667
|
+
scaleInStringPreset: AnimationRange[];
|
|
668
|
+
slideInLeftResponsivePreset: AnimationRange[];
|
|
669
|
+
slideInTopResponsivePreset: AnimationRange[];
|
|
670
|
+
backgroundColorPreset: AnimationRange[];
|
|
671
|
+
borderRadiusPreset: AnimationRange[];
|
|
672
|
+
boxShadowPreset: AnimationRange[];
|
|
673
|
+
fontSizePreset: AnimationRange[];
|
|
674
|
+
letterSpacingPreset: AnimationRange[];
|
|
675
|
+
lineHeightPreset: AnimationRange[];
|
|
676
|
+
textShadowPreset: AnimationRange[];
|
|
677
|
+
widthPreset: AnimationRange[];
|
|
678
|
+
heightPreset: AnimationRange[];
|
|
679
|
+
marginPreset: AnimationRange[];
|
|
680
|
+
paddingPreset: AnimationRange[];
|
|
681
|
+
morphingCardPreset: AnimationRange[];
|
|
682
|
+
textRevealPreset: AnimationRange[];
|
|
683
|
+
};
|
|
684
|
+
|
|
685
|
+
type GenericEffectData = UniversalEffectData;
|
|
686
|
+
|
|
687
|
+
declare const useComponentRegistry: () => {
|
|
688
|
+
registerComponent: any;
|
|
689
|
+
registerPackage: any;
|
|
690
|
+
getComponent: any;
|
|
691
|
+
getAllComponents: any;
|
|
692
|
+
};
|
|
693
|
+
|
|
694
|
+
interface UseBoundaryCalculationProps {
|
|
695
|
+
parentBoundaries: {
|
|
696
|
+
x: number;
|
|
697
|
+
y: number;
|
|
698
|
+
width: number;
|
|
699
|
+
height: number;
|
|
700
|
+
};
|
|
701
|
+
constraints: BoundaryConstraints;
|
|
702
|
+
layout?: LayoutConstraints;
|
|
703
|
+
}
|
|
704
|
+
declare const useBoundaryCalculation: ({ parentBoundaries, constraints, layout, }: UseBoundaryCalculationProps) => {
|
|
705
|
+
x: number;
|
|
706
|
+
y: number;
|
|
707
|
+
width: number;
|
|
708
|
+
height: number;
|
|
709
|
+
zIndex: number;
|
|
710
|
+
};
|
|
711
|
+
|
|
712
|
+
declare function buildLayoutHook<T extends z.ZodSchema>(schema: T, defaultValue: z.infer<T>): () => z.core.output<T>;
|
|
713
|
+
|
|
714
|
+
interface FontConfig {
|
|
715
|
+
family: string;
|
|
716
|
+
weights?: string[];
|
|
717
|
+
subsets?: string[];
|
|
718
|
+
display?: 'auto' | 'block' | 'swap' | 'fallback' | 'optional';
|
|
719
|
+
preload?: boolean;
|
|
720
|
+
}
|
|
721
|
+
interface FontLoadingOptions {
|
|
722
|
+
subsets?: string[];
|
|
723
|
+
weights?: string[];
|
|
724
|
+
display?: 'auto' | 'block' | 'swap' | 'fallback' | 'optional';
|
|
725
|
+
preload?: boolean;
|
|
726
|
+
}
|
|
727
|
+
/**
|
|
728
|
+
* Load a Google Font dynamically using dynamic imports
|
|
729
|
+
* @param fontFamily - The font family name (e.g., 'Inter', 'Roboto')
|
|
730
|
+
* @param options - Font loading options
|
|
731
|
+
* @returns Promise that resolves with the fontFamily CSS value
|
|
732
|
+
*/
|
|
733
|
+
declare const loadGoogleFont: (fontFamily: string, options?: FontLoadingOptions) => Promise<string>;
|
|
734
|
+
/**
|
|
735
|
+
* Load multiple fonts in parallel
|
|
736
|
+
* @param fonts - Array of font configurations
|
|
737
|
+
* @returns Promise that resolves with a map of font family names to CSS values
|
|
738
|
+
*/
|
|
739
|
+
declare const loadMultipleFonts: (fonts: Array<{
|
|
740
|
+
family: string;
|
|
741
|
+
options?: FontLoadingOptions;
|
|
742
|
+
}>) => Promise<Map<string, string>>;
|
|
743
|
+
/**
|
|
744
|
+
* Get font family CSS value from cache
|
|
745
|
+
* @param fontFamily - The font family name
|
|
746
|
+
* @param options - Font loading options
|
|
747
|
+
* @returns CSS font-family value or undefined if not loaded
|
|
748
|
+
*/
|
|
749
|
+
declare const getLoadedFontFamily: (fontFamily: string, options?: FontLoadingOptions) => string | undefined;
|
|
750
|
+
/**
|
|
751
|
+
* Preload common fonts for better performance
|
|
752
|
+
*/
|
|
753
|
+
declare const preloadCommonFonts: () => Promise<Map<string, string>>;
|
|
754
|
+
/**
|
|
755
|
+
* Check if a font is already loaded
|
|
756
|
+
* @param fontFamily - The font family name
|
|
757
|
+
* @param options - Font loading options
|
|
758
|
+
* @returns boolean indicating if font is loaded
|
|
759
|
+
*/
|
|
760
|
+
declare const isFontLoaded: (fontFamily: string, options?: FontLoadingOptions) => boolean;
|
|
761
|
+
/**
|
|
762
|
+
* Clear font cache (useful for testing or memory management)
|
|
763
|
+
*/
|
|
764
|
+
declare const clearFontCache: () => void;
|
|
765
|
+
/**
|
|
766
|
+
* Get all loaded fonts
|
|
767
|
+
* @returns Map of loaded fonts
|
|
768
|
+
*/
|
|
769
|
+
declare const getLoadedFonts: () => Map<string, string>;
|
|
770
|
+
/**
|
|
771
|
+
* Check if a font is available in @remotion/google-fonts
|
|
772
|
+
* @param fontFamily - The font family name to check
|
|
773
|
+
* @returns Promise that resolves to boolean indicating if font is available
|
|
774
|
+
*/
|
|
775
|
+
declare const isFontAvailable: (fontFamily: string) => Promise<boolean>;
|
|
776
|
+
/**
|
|
777
|
+
* Get normalized font name for import
|
|
778
|
+
* @param fontFamily - The font family name
|
|
779
|
+
* @returns Normalized font name suitable for import
|
|
780
|
+
*/
|
|
781
|
+
declare const getNormalizedFontName: (fontFamily: string) => string;
|
|
782
|
+
|
|
783
|
+
interface UseFontLoaderOptions {
|
|
784
|
+
preload?: boolean;
|
|
785
|
+
onLoad?: (fontFamily: string, cssValue: string) => void;
|
|
786
|
+
onError?: (fontFamily: string, error: Error) => void;
|
|
787
|
+
}
|
|
788
|
+
interface FontLoaderState {
|
|
789
|
+
loadedFonts: Map<string, string>;
|
|
790
|
+
loadingFonts: Set<string>;
|
|
791
|
+
errorFonts: Map<string, Error>;
|
|
792
|
+
}
|
|
793
|
+
/**
|
|
794
|
+
* Hook for managing dynamic font loading in Remotion components
|
|
795
|
+
*/
|
|
796
|
+
declare const useFontLoader: (options?: UseFontLoaderOptions) => {
|
|
797
|
+
loadedFonts: Map<string, string>;
|
|
798
|
+
loadingFonts: Set<string>;
|
|
799
|
+
errorFonts: Map<string, Error>;
|
|
800
|
+
loadFont: (fontFamily: string, fontOptions?: FontLoadingOptions) => Promise<string>;
|
|
801
|
+
loadMultipleFonts: (fonts: Array<{
|
|
802
|
+
family: string;
|
|
803
|
+
options?: FontLoadingOptions;
|
|
804
|
+
}>) => Promise<Map<string, string>>;
|
|
805
|
+
isFontReady: (fontFamily: string, options?: FontLoadingOptions) => boolean;
|
|
806
|
+
areFontsReady: (fontFamilies: Array<{
|
|
807
|
+
family: string;
|
|
808
|
+
options?: FontLoadingOptions;
|
|
809
|
+
}>) => boolean;
|
|
810
|
+
getFontFamily: (fontFamily: string, options?: FontLoadingOptions) => string | undefined;
|
|
811
|
+
getFontError: (fontFamily: string) => Error | undefined;
|
|
812
|
+
clearErrors: () => void;
|
|
813
|
+
};
|
|
814
|
+
/**
|
|
815
|
+
* Hook for loading a single font with automatic loading and delayRender support
|
|
816
|
+
*/
|
|
817
|
+
declare const useFont: (fontFamily: string, options?: FontLoadingOptions & UseFontLoaderOptions) => {
|
|
818
|
+
loadedFonts: Map<string, string>;
|
|
819
|
+
loadingFonts: Set<string>;
|
|
820
|
+
errorFonts: Map<string, Error>;
|
|
821
|
+
loadMultipleFonts: (fonts: Array<{
|
|
822
|
+
family: string;
|
|
823
|
+
options?: FontLoadingOptions;
|
|
824
|
+
}>) => Promise<Map<string, string>>;
|
|
825
|
+
areFontsReady: (fontFamilies: Array<{
|
|
826
|
+
family: string;
|
|
827
|
+
options?: FontLoadingOptions;
|
|
828
|
+
}>) => boolean;
|
|
829
|
+
clearErrors: () => void;
|
|
830
|
+
isLoaded: boolean;
|
|
831
|
+
error: Error;
|
|
832
|
+
isReady: boolean;
|
|
833
|
+
fontFamily: string;
|
|
834
|
+
};
|
|
835
|
+
|
|
836
|
+
declare const createRootContext: (width: number, height: number, duration: number, fps: number) => RenderableContext;
|
|
837
|
+
declare const mergeContexts: (parent: RenderableContext, child: Partial<RenderableContext>) => RenderableContext;
|
|
838
|
+
|
|
839
|
+
declare const calculateGridPosition: (index: number, columns: number, cellWidth: number, cellHeight: number, spacing: number) => {
|
|
840
|
+
x: number;
|
|
841
|
+
y: number;
|
|
842
|
+
width: number;
|
|
843
|
+
height: number;
|
|
844
|
+
};
|
|
845
|
+
declare const calculateCircularPosition: (index: number, total: number, radius: number, centerX: number, centerY: number) => {
|
|
846
|
+
x: number;
|
|
847
|
+
y: number;
|
|
848
|
+
};
|
|
849
|
+
|
|
850
|
+
/**
|
|
851
|
+
* Image Proxy Utilities
|
|
852
|
+
*
|
|
853
|
+
* Helper functions for working with image proxying in Remotion components
|
|
854
|
+
*/
|
|
855
|
+
/**
|
|
856
|
+
* Creates a proxy URL for an external image
|
|
857
|
+
* @param imageUrl - The original image URL
|
|
858
|
+
* @param proxyEndpoint - The proxy endpoint (defaults to local API)
|
|
859
|
+
* @returns The proxied URL
|
|
860
|
+
*/
|
|
861
|
+
declare const createImageProxyUrl: (imageUrl: string, proxyEndpoint?: string) => string;
|
|
862
|
+
/**
|
|
863
|
+
* Creates image data with proxy fallback
|
|
864
|
+
* @param src - The original image source
|
|
865
|
+
* @param proxyEndpoint - Optional custom proxy endpoint
|
|
866
|
+
* @returns Image data object with proxySrc configured
|
|
867
|
+
*/
|
|
868
|
+
declare const createImageDataWithProxy: (src: string, proxyEndpoint?: string) => {
|
|
869
|
+
src: string;
|
|
870
|
+
proxySrc: string;
|
|
871
|
+
style: {};
|
|
872
|
+
className: string;
|
|
873
|
+
};
|
|
874
|
+
/**
|
|
875
|
+
* Checks if a URL needs proxying (external HTTP/HTTPS URLs)
|
|
876
|
+
* @param url - The URL to check
|
|
877
|
+
* @returns True if the URL needs proxying
|
|
878
|
+
*/
|
|
879
|
+
declare const needsProxying: (url: string) => boolean;
|
|
880
|
+
|
|
881
|
+
/**
|
|
882
|
+
* Finds a component in the root data by its ID
|
|
883
|
+
*/
|
|
884
|
+
declare const findComponentById: (root: RenderableComponentData[] | undefined, targetId: string) => RenderableComponentData | null;
|
|
885
|
+
/**
|
|
886
|
+
* Finds the parent component of a given component
|
|
887
|
+
*/
|
|
888
|
+
declare const findParentComponent: (root: RenderableComponentData[] | undefined, targetId: string) => RenderableComponentData | null;
|
|
889
|
+
/**
|
|
890
|
+
* Calculates the hierarchy for a component based on its position in the root data
|
|
891
|
+
*/
|
|
892
|
+
declare const calculateHierarchy: (root: RenderableComponentData[] | undefined, componentId: string, currentContext?: RenderableContext) => Hierarchy;
|
|
893
|
+
/**
|
|
894
|
+
* Calculates timing for a component, inheriting from parent if duration is not provided
|
|
895
|
+
*/
|
|
896
|
+
declare const calculateTimingWithInheritance: (component: RenderableComponentData, root: RenderableComponentData[] | undefined, videoConfig: VideoConfig) => CalculatedTiming;
|
|
897
|
+
|
|
898
|
+
declare const NextjsLogo: React$1.FC;
|
|
899
|
+
declare const nextjsLogoConfig: ComponentConfig;
|
|
900
|
+
|
|
901
|
+
declare const Rings: React$1.FC<{
|
|
902
|
+
context?: RenderableContext;
|
|
903
|
+
data?: RenderableData;
|
|
904
|
+
}>;
|
|
905
|
+
declare const ringsConfig: ComponentConfig;
|
|
906
|
+
|
|
907
|
+
interface LayoutProps$1 extends BaseRenderableProps {
|
|
908
|
+
children: React$1.ReactNode | React$1.ReactNode[];
|
|
909
|
+
}
|
|
910
|
+
|
|
911
|
+
declare const RippleOutTransitionSchema: z.ZodObject<{
|
|
912
|
+
progress: z.ZodNumber;
|
|
913
|
+
logoOut: z.ZodNumber;
|
|
914
|
+
}, z.core.$strip>;
|
|
915
|
+
declare const useRippleOutLayout: () => {
|
|
916
|
+
progress: number;
|
|
917
|
+
logoOut: number;
|
|
918
|
+
};
|
|
919
|
+
type RippleOutTransitionData = z.infer<typeof RippleOutTransitionSchema>;
|
|
920
|
+
declare const RippleOutLayout: React$1.FC<LayoutProps$1>;
|
|
921
|
+
declare const rippleOutLayoutConfig: ComponentConfig;
|
|
922
|
+
|
|
923
|
+
interface LayoutProps extends BaseRenderableProps {
|
|
924
|
+
children?: React$1.ReactNode;
|
|
925
|
+
}
|
|
926
|
+
declare const TextFade: (props: LayoutProps) => React$1.JSX.Element;
|
|
927
|
+
declare const textFadeConfig: ComponentConfig;
|
|
928
|
+
|
|
929
|
+
interface WaveformConfig {
|
|
930
|
+
audioSrc: string;
|
|
931
|
+
useFrequencyData?: boolean;
|
|
932
|
+
numberOfSamples?: number;
|
|
933
|
+
windowInSeconds?: number;
|
|
934
|
+
dataOffsetInSeconds?: number;
|
|
935
|
+
normalize?: boolean;
|
|
936
|
+
height?: number;
|
|
937
|
+
width?: number;
|
|
938
|
+
color?: string;
|
|
939
|
+
strokeWidth?: number;
|
|
940
|
+
backgroundColor?: string;
|
|
941
|
+
amplitude?: number;
|
|
942
|
+
smoothing?: boolean;
|
|
943
|
+
posterize?: number;
|
|
944
|
+
}
|
|
945
|
+
interface WaveformContextType {
|
|
946
|
+
waveformData: number[] | null;
|
|
947
|
+
frequencyData: number[] | null;
|
|
948
|
+
amplitudes: number[] | null;
|
|
949
|
+
audioData: any;
|
|
950
|
+
frame: number;
|
|
951
|
+
fps: number;
|
|
952
|
+
config: WaveformConfig;
|
|
953
|
+
width: number;
|
|
954
|
+
height: number;
|
|
955
|
+
bass: number | null;
|
|
956
|
+
mid: number | null;
|
|
957
|
+
treble: number | null;
|
|
958
|
+
bassValues?: number[] | null;
|
|
959
|
+
midValues?: number[] | null;
|
|
960
|
+
trebleValues?: number[] | null;
|
|
961
|
+
}
|
|
962
|
+
declare const useWaveformContext: () => WaveformContextType;
|
|
963
|
+
interface WaveformProps {
|
|
964
|
+
config: WaveformConfig;
|
|
965
|
+
children?: ReactNode;
|
|
966
|
+
className?: string;
|
|
967
|
+
style?: React$1.CSSProperties;
|
|
968
|
+
}
|
|
969
|
+
declare const Waveform: React$1.FC<WaveformProps>;
|
|
970
|
+
|
|
971
|
+
interface UseWaveformDataConfig {
|
|
972
|
+
audioSrc: string;
|
|
973
|
+
numberOfSamples: number;
|
|
974
|
+
windowInSeconds: number;
|
|
975
|
+
dataOffsetInSeconds?: number;
|
|
976
|
+
normalize?: boolean;
|
|
977
|
+
frame: number;
|
|
978
|
+
fps: number;
|
|
979
|
+
posterize?: number;
|
|
980
|
+
includeFrequencyData?: boolean;
|
|
981
|
+
minDb?: number;
|
|
982
|
+
maxDb?: number;
|
|
983
|
+
}
|
|
984
|
+
interface UseWaveformDataReturn {
|
|
985
|
+
waveformData: number[] | null;
|
|
986
|
+
frequencyData: number[] | null;
|
|
987
|
+
amplitudes: number[] | null;
|
|
988
|
+
audioData: any;
|
|
989
|
+
isLoading: boolean;
|
|
990
|
+
error: string | null;
|
|
991
|
+
bass: number | null;
|
|
992
|
+
bassValues?: number[] | null;
|
|
993
|
+
mid: number | null;
|
|
994
|
+
midValues?: number[] | null;
|
|
995
|
+
treble: number | null;
|
|
996
|
+
trebleValues?: number[] | null;
|
|
997
|
+
}
|
|
998
|
+
declare const useWaveformData: (config: UseWaveformDataConfig) => UseWaveformDataReturn;
|
|
999
|
+
|
|
1000
|
+
interface WaveformLineDataProps {
|
|
1001
|
+
config: WaveformConfig & {
|
|
1002
|
+
useFrequencyData?: boolean;
|
|
1003
|
+
};
|
|
1004
|
+
className?: string;
|
|
1005
|
+
style?: React$1.CSSProperties;
|
|
1006
|
+
strokeColor?: string;
|
|
1007
|
+
strokeWidth?: number;
|
|
1008
|
+
strokeLinecap?: 'butt' | 'round' | 'square';
|
|
1009
|
+
strokeLinejoin?: 'miter' | 'round' | 'bevel';
|
|
1010
|
+
fill?: string;
|
|
1011
|
+
opacity?: number;
|
|
1012
|
+
centerLine?: boolean;
|
|
1013
|
+
centerLineColor?: string;
|
|
1014
|
+
centerLineWidth?: number;
|
|
1015
|
+
beatSync?: boolean;
|
|
1016
|
+
bpm?: number;
|
|
1017
|
+
beatThreshold?: number;
|
|
1018
|
+
beatAmplitudeMultiplier?: number;
|
|
1019
|
+
beatAnimationDuration?: number;
|
|
1020
|
+
smoothAnimation?: boolean;
|
|
1021
|
+
waveSpacing?: number;
|
|
1022
|
+
waveSegments?: number;
|
|
1023
|
+
waveOffset?: number;
|
|
1024
|
+
waveDirection?: 'horizontal' | 'vertical';
|
|
1025
|
+
amplitudeCurve?: 'linear' | 'ease-in' | 'ease-out' | 'ease-in-out' | 'bounce';
|
|
1026
|
+
animationSpeed?: number;
|
|
1027
|
+
pulseOnBeat?: boolean;
|
|
1028
|
+
pulseColor?: string;
|
|
1029
|
+
pulseScale?: number;
|
|
1030
|
+
}
|
|
1031
|
+
interface WaveformLineProps extends BaseRenderableData {
|
|
1032
|
+
data: WaveformLineDataProps;
|
|
1033
|
+
}
|
|
1034
|
+
declare const WaveformLine: React$1.FC<WaveformLineProps>;
|
|
1035
|
+
|
|
1036
|
+
interface WaveformHistogramDataProps {
|
|
1037
|
+
config: any;
|
|
1038
|
+
className?: string;
|
|
1039
|
+
style?: React$1.CSSProperties;
|
|
1040
|
+
barColor?: string;
|
|
1041
|
+
barWidth?: number;
|
|
1042
|
+
barSpacing?: number;
|
|
1043
|
+
barBorderRadius?: number;
|
|
1044
|
+
opacity?: number;
|
|
1045
|
+
multiplier?: number;
|
|
1046
|
+
horizontalSymmetry?: boolean;
|
|
1047
|
+
verticalMirror?: boolean;
|
|
1048
|
+
waveDirection?: 'right-to-left' | 'left-to-right';
|
|
1049
|
+
histogramStyle?: 'centered' | 'full-width';
|
|
1050
|
+
amplitude?: number;
|
|
1051
|
+
gradientStartColor?: string;
|
|
1052
|
+
gradientEndColor?: string;
|
|
1053
|
+
gradientDirection?: 'vertical' | 'horizontal';
|
|
1054
|
+
gradientStyle?: 'mirrored' | 'normal';
|
|
1055
|
+
}
|
|
1056
|
+
interface WaveformHistogramProps extends BaseRenderableData {
|
|
1057
|
+
data: WaveformHistogramDataProps;
|
|
1058
|
+
}
|
|
1059
|
+
declare const WaveformHistogram: React$1.FC<WaveformHistogramProps>;
|
|
1060
|
+
|
|
1061
|
+
interface WaveformHistogramRangedDataProps {
|
|
1062
|
+
config: any;
|
|
1063
|
+
className?: string;
|
|
1064
|
+
style?: React$1.CSSProperties;
|
|
1065
|
+
barColor?: string;
|
|
1066
|
+
barWidth?: number;
|
|
1067
|
+
barSpacing?: number;
|
|
1068
|
+
barBorderRadius?: number;
|
|
1069
|
+
opacity?: number;
|
|
1070
|
+
horizontalSymmetry?: boolean;
|
|
1071
|
+
verticalMirror?: boolean;
|
|
1072
|
+
histogramStyle?: 'centered' | 'full-width';
|
|
1073
|
+
waveDirection?: 'right-to-left' | 'left-to-right';
|
|
1074
|
+
amplitude?: number;
|
|
1075
|
+
showFrequencyRanges?: boolean;
|
|
1076
|
+
rangeDividerColor?: string;
|
|
1077
|
+
rangeLabels?: boolean;
|
|
1078
|
+
bassBarColor?: string;
|
|
1079
|
+
midBarColor?: string;
|
|
1080
|
+
trebleBarColor?: string;
|
|
1081
|
+
gradientStartColor?: string;
|
|
1082
|
+
gradientEndColor?: string;
|
|
1083
|
+
gradientDirection?: 'vertical' | 'horizontal';
|
|
1084
|
+
gradientStyle?: 'mirrored' | 'normal';
|
|
1085
|
+
}
|
|
1086
|
+
interface WaveformHistogramRangedProps extends BaseRenderableData {
|
|
1087
|
+
data: WaveformHistogramRangedDataProps;
|
|
1088
|
+
}
|
|
1089
|
+
declare const WaveformHistogramRanged: React$1.FC<WaveformHistogramRangedProps>;
|
|
1090
|
+
|
|
1091
|
+
interface WaveformCircleDataProps {
|
|
1092
|
+
config: any;
|
|
1093
|
+
className?: string;
|
|
1094
|
+
style?: React$1.CSSProperties;
|
|
1095
|
+
strokeColor?: string;
|
|
1096
|
+
strokeWidth?: number;
|
|
1097
|
+
fill?: string;
|
|
1098
|
+
opacity?: number;
|
|
1099
|
+
radius?: number;
|
|
1100
|
+
centerX?: number;
|
|
1101
|
+
centerY?: number;
|
|
1102
|
+
startAngle?: number;
|
|
1103
|
+
endAngle?: number;
|
|
1104
|
+
amplitude?: number;
|
|
1105
|
+
rotationSpeed?: number;
|
|
1106
|
+
gradientStartColor?: string;
|
|
1107
|
+
gradientEndColor?: string;
|
|
1108
|
+
}
|
|
1109
|
+
interface WaveformCircleProps extends BaseRenderableData {
|
|
1110
|
+
data: WaveformCircleDataProps;
|
|
1111
|
+
}
|
|
1112
|
+
declare const WaveformCircle: React$1.FC<WaveformCircleProps>;
|
|
1113
|
+
|
|
1114
|
+
declare const WaveformPresets: {
|
|
1115
|
+
stopgapLine: (props: WaveformLineDataProps) => {
|
|
1116
|
+
componentId: string;
|
|
1117
|
+
type: string;
|
|
1118
|
+
data: {
|
|
1119
|
+
config: {
|
|
1120
|
+
audioSrc: string;
|
|
1121
|
+
useFrequencyData?: boolean;
|
|
1122
|
+
numberOfSamples: number;
|
|
1123
|
+
windowInSeconds: number;
|
|
1124
|
+
dataOffsetInSeconds?: number;
|
|
1125
|
+
normalize?: boolean;
|
|
1126
|
+
height: number;
|
|
1127
|
+
width: number;
|
|
1128
|
+
color?: string;
|
|
1129
|
+
strokeWidth?: number;
|
|
1130
|
+
backgroundColor?: string;
|
|
1131
|
+
amplitude: number;
|
|
1132
|
+
smoothing?: boolean;
|
|
1133
|
+
posterize: number;
|
|
1134
|
+
};
|
|
1135
|
+
className?: string;
|
|
1136
|
+
style?: React.CSSProperties;
|
|
1137
|
+
strokeColor: string;
|
|
1138
|
+
strokeWidth: number;
|
|
1139
|
+
strokeLinecap: string;
|
|
1140
|
+
strokeLinejoin?: "miter" | "round" | "bevel";
|
|
1141
|
+
fill?: string;
|
|
1142
|
+
opacity: number;
|
|
1143
|
+
centerLine?: boolean;
|
|
1144
|
+
centerLineColor?: string;
|
|
1145
|
+
centerLineWidth?: number;
|
|
1146
|
+
beatSync?: boolean;
|
|
1147
|
+
bpm?: number;
|
|
1148
|
+
beatThreshold?: number;
|
|
1149
|
+
beatAmplitudeMultiplier?: number;
|
|
1150
|
+
beatAnimationDuration?: number;
|
|
1151
|
+
smoothAnimation: boolean;
|
|
1152
|
+
waveSpacing?: number;
|
|
1153
|
+
waveSegments?: number;
|
|
1154
|
+
waveOffset?: number;
|
|
1155
|
+
waveDirection?: "horizontal" | "vertical";
|
|
1156
|
+
amplitudeCurve: string;
|
|
1157
|
+
animationSpeed: number;
|
|
1158
|
+
pulseOnBeat?: boolean;
|
|
1159
|
+
pulseColor?: string;
|
|
1160
|
+
pulseScale?: number;
|
|
1161
|
+
};
|
|
1162
|
+
};
|
|
1163
|
+
};
|
|
1164
|
+
|
|
1165
|
+
export { type AnimationRange, Atom$1 as AudioAtom, config$7 as AudioAtomConfig, AudioAtomDataProps, type BaseComponentData, type BaseEffect, Layout as BaseLayout, config$c as BaseLayoutConfig, type BaseRenderableData, type BaseRenderableProps, BlurEffect, config$5 as BlurEffectConfig, type Boundaries, type BoundaryConstraints, type CalculatedBoundaries, type CalculatedTiming, type ComponentConfig, type ComponentRegistry, ComponentRenderer, type ComponentType, Composition, type CompositionContext, CompositionLayout, CompositionProvider, type FontConfig, type FontLoaderState, type FontLoadingOptions, Frame, type GenericEffectData, GenericEffectPresets, type Hierarchy, Atom$4 as ImageAtom, config$a as ImageAtomConfig, type InputCompositionProps, type InternalRenderableContext, type LayoutConstraints, LoopEffect, config$4 as LoopEffectConfig, Atom as LottieAtom, config$6 as LottieAtomConfig, LottieAtomDataProps, NextjsLogo, type PackageRegistry, PanEffect, config$3 as PanEffectConfig, type PanEffectData, Player, type RegistryEntry, type RenderableComponentData, type RenderableContext, type RenderableData, Rings, RippleOutLayout, type RippleOutTransitionData, SceneFrame, ShakeEffect, config$1 as ShakeEffectConfig, type ShakeEffectData, Atom$5 as ShapeAtom, config$b as ShapeAtomConfig, StretchEffect, config as StretchEffectConfig, type StretchEffectData, Atom$3 as TextAtom, config$9 as TextAtomConfig, type TextAtomData, TextFade, type Timing, type TimingConstraints, UniversalEffect, type UniversalEffectData, UniversalEffectProvider, type UseFontLoaderOptions, type UseWaveformDataConfig, type UseWaveformDataReturn, Atom$2 as VideoAtom, config$8 as VideoAtomConfig, VideoAtomDataProps, Waveform, WaveformCircle, type WaveformCircleDataProps, type WaveformCircleProps, type WaveformConfig, type WaveformContextType, WaveformHistogram, type WaveformHistogramDataProps, type WaveformHistogramProps, WaveformHistogramRanged, type WaveformHistogramRangedDataProps, type WaveformHistogramRangedProps, WaveformLine, type WaveformLineDataProps, type WaveformLineProps, WaveformPresets, type WaveformProps, ZoomEffect, config$2 as ZoomEffectConfig, type ZoomEffectData, buildLayoutHook, calculateCircularPosition, calculateComponentDuration, calculateCompositionLayoutMetadata, calculateDuration, calculateGridPosition, calculateHierarchy, calculateTimingWithInheritance, clearFontCache, componentRegistry, createImageDataWithProxy, createImageProxyUrl, createRootContext, findComponentById, findMatchingComponents, findMatchingComponentsByQuery, findParentComponent, getComponent, getComponentConfig, getComponentWithConfig, getLoadedFontFamily, getLoadedFonts, getNormalizedFontName, isFontAvailable, isFontLoaded, loadGoogleFont, loadMultipleFonts, mergeContexts, needsProxying, nextjsLogoConfig, preloadCommonFonts, registerComponent, registerEffect, registerPackage, ringsConfig, rippleOutLayoutConfig, setDurationsInContext, textFadeConfig, useAnimatedStyles, useBoundaryCalculation, useComponentRegistry, useComposition, useFont, useFontLoader, useHasUniversalEffectProvider, useRenderContext, useRippleOutLayout, useUniversalEffect, useUniversalEffectOptional, useWaveformContext, useWaveformData };
|