@depths/waves 0.1.0 → 0.3.0

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.
@@ -1,284 +0,0 @@
1
- import {
2
- VideoIRSchema,
3
- WavesRenderError,
4
- globalRegistry,
5
- registerBuiltInComponents,
6
- zodSchemaToJsonSchema
7
- } from "./chunk-TGAL5RQN.mjs";
8
-
9
- // src/version.ts
10
- var __wavesVersion = "0.1.0";
11
-
12
- // src/llm/prompt.ts
13
- var RULES = {
14
- timing: [
15
- "All timing is in frames (integers).",
16
- "Every component has timing: { from, durationInFrames }.",
17
- "Scenes must be sequential: scene[0].timing.from = 0 and each next scene starts where the previous ends (no gaps/overlaps).",
18
- "Sum of all scene durations must equal video.durationInFrames.",
19
- "Child components inside a Scene must fit within the Scene duration."
20
- ],
21
- assets: [
22
- 'Asset paths must be either full URLs (http:// or https://) or absolute public paths starting with "/".',
23
- 'When using absolute public paths ("/assets/..."), the renderer resolves them relative to the --publicDir passed at render time.'
24
- ],
25
- ids: [
26
- "Every component must have a stable string id.",
27
- "Ids should be unique within the whole IR."
28
- ],
29
- output: [
30
- "Return only a single JSON object (no markdown fences, no commentary).",
31
- "The JSON must validate against the provided JSON Schemas.",
32
- 'Only use component "type" values that exist in schemas.components.'
33
- ]
34
- };
35
- function getSystemPrompt(registeredTypes) {
36
- const typesLine = registeredTypes.length ? registeredTypes.join(", ") : "(none)";
37
- return [
38
- "You generate JSON for @depths/waves Video IR (version 1.0).",
39
- "",
40
- "Goal:",
41
- "- Produce a single JSON object that conforms to the provided Video IR JSON Schema and uses only registered component types.",
42
- "",
43
- "Registered component types:",
44
- `- ${typesLine}`,
45
- "",
46
- "Authoring rules:",
47
- ...RULES.output.map((r) => `- ${r}`),
48
- ...RULES.timing.map((r) => `- ${r}`),
49
- ...RULES.assets.map((r) => `- ${r}`),
50
- ...RULES.ids.map((r) => `- ${r}`),
51
- "",
52
- "If you are unsure about an asset, prefer a solid color Scene background and omit optional props to use defaults.",
53
- ""
54
- ].join("\n");
55
- }
56
- function getPromptPayload(options) {
57
- registerBuiltInComponents();
58
- const registry = options?.registry ?? globalRegistry;
59
- const types = registry.getTypes().sort();
60
- return {
61
- package: "@depths/waves",
62
- version: __wavesVersion,
63
- irVersion: "1.0",
64
- systemPrompt: getSystemPrompt(types),
65
- schemas: {
66
- videoIR: zodSchemaToJsonSchema(VideoIRSchema),
67
- components: registry.getJSONSchemaForLLM()
68
- },
69
- rules: {
70
- timing: [...RULES.timing],
71
- assets: [...RULES.assets],
72
- ids: [...RULES.ids],
73
- output: [...RULES.output]
74
- }
75
- };
76
- }
77
-
78
- // src/core/validator.ts
79
- var IRValidator = class {
80
- validateSchema(ir) {
81
- const result = VideoIRSchema.safeParse(ir);
82
- if (!result.success) {
83
- return {
84
- success: false,
85
- errors: result.error.issues.map((issue) => ({
86
- path: issue.path.map((p) => String(p)),
87
- message: issue.message,
88
- code: issue.code
89
- }))
90
- };
91
- }
92
- return { success: true, data: result.data };
93
- }
94
- validateSemantics(ir) {
95
- const errors = [];
96
- const totalSceneDuration = ir.scenes.reduce((sum, scene) => sum + scene.timing.durationInFrames, 0);
97
- if (totalSceneDuration !== ir.video.durationInFrames) {
98
- errors.push({
99
- path: ["scenes"],
100
- message: `Sum of scene durations (${totalSceneDuration}) does not match video duration (${ir.video.durationInFrames})`,
101
- code: "DURATION_MISMATCH"
102
- });
103
- }
104
- let expectedFrame = 0;
105
- for (const [i, scene] of ir.scenes.entries()) {
106
- if (scene.timing.from !== expectedFrame) {
107
- errors.push({
108
- path: ["scenes", String(i), "timing", "from"],
109
- message: `Scene ${i} starts at frame ${scene.timing.from}, expected ${expectedFrame}`,
110
- code: "TIMING_GAP_OR_OVERLAP"
111
- });
112
- }
113
- expectedFrame += scene.timing.durationInFrames;
114
- }
115
- for (const [i, scene] of ir.scenes.entries()) {
116
- if (scene.children && scene.children.length > 0) {
117
- this.validateComponentTimingRecursive(
118
- scene.children,
119
- scene.timing.durationInFrames,
120
- ["scenes", String(i)],
121
- errors
122
- );
123
- }
124
- }
125
- if (errors.length > 0) {
126
- return { success: false, errors };
127
- }
128
- return { success: true };
129
- }
130
- validate(ir) {
131
- const schemaResult = this.validateSchema(ir);
132
- if (!schemaResult.success) {
133
- return schemaResult;
134
- }
135
- const semanticsResult = this.validateSemantics(schemaResult.data);
136
- if (!semanticsResult.success) {
137
- return { success: false, errors: semanticsResult.errors ?? [] };
138
- }
139
- return schemaResult;
140
- }
141
- validateComponentTimingRecursive(components, parentDuration, pathPrefix, errors) {
142
- for (const [i, component] of components.entries()) {
143
- const componentEnd = component.timing.from + component.timing.durationInFrames;
144
- if (componentEnd > parentDuration) {
145
- errors.push({
146
- path: [...pathPrefix, "children", String(i), "timing"],
147
- message: `Component extends beyond parent duration (${componentEnd} > ${parentDuration})`,
148
- code: "COMPONENT_EXCEEDS_PARENT"
149
- });
150
- }
151
- if (component.type === "Scene" && component.children && component.children.length > 0) {
152
- this.validateComponentTimingRecursive(
153
- component.children,
154
- component.timing.durationInFrames,
155
- [...pathPrefix, "children", String(i)],
156
- errors
157
- );
158
- }
159
- }
160
- }
161
- };
162
-
163
- // src/core/engine.ts
164
- import { bundle } from "@remotion/bundler";
165
- import { renderMedia, selectComposition } from "@remotion/renderer";
166
- import fs from "fs/promises";
167
- import path from "path";
168
- var WavesEngine = class {
169
- constructor(registry, validator) {
170
- this.registry = registry;
171
- this.validator = validator;
172
- }
173
- async render(ir, options) {
174
- if (this.registry !== globalRegistry) {
175
- throw new WavesRenderError("WavesEngine currently requires using globalRegistry", {
176
- hint: "Use `registerBuiltInComponents()` + `globalRegistry` for both validation and rendering."
177
- });
178
- }
179
- const validationResult = this.validator.validate(ir);
180
- if (!validationResult.success) {
181
- throw new WavesRenderError("IR validation failed", { errors: validationResult.errors });
182
- }
183
- const validatedIR = validationResult.data;
184
- const requiredTypes = collectComponentTypes(validatedIR);
185
- for (const type of requiredTypes) {
186
- if (!this.registry.has(type)) {
187
- throw new WavesRenderError("Unknown component type", { type });
188
- }
189
- }
190
- const rootDir = options.rootDir ?? process.cwd();
191
- const tmpDir = await fs.mkdtemp(path.join(rootDir, ".waves-tmp-"));
192
- const entryPoint = path.join(tmpDir, "entry.tsx");
193
- try {
194
- await fs.writeFile(entryPoint, generateEntryPoint(validatedIR, options), "utf-8");
195
- await fs.mkdir(path.dirname(options.outputPath), { recursive: true });
196
- const bundleLocation = await bundle({
197
- entryPoint,
198
- rootDir,
199
- publicDir: options.publicDir ?? null,
200
- onProgress: () => void 0
201
- });
202
- const compositionId = validatedIR.video.id ?? "main";
203
- const composition = await selectComposition({
204
- serveUrl: bundleLocation,
205
- id: compositionId,
206
- inputProps: {}
207
- });
208
- await renderMedia({
209
- composition,
210
- serveUrl: bundleLocation,
211
- codec: options.codec ?? "h264",
212
- outputLocation: options.outputPath,
213
- crf: options.crf ?? null,
214
- concurrency: options.concurrency ?? null,
215
- overwrite: true
216
- });
217
- } catch (error) {
218
- throw new WavesRenderError("Rendering failed", { originalError: error });
219
- } finally {
220
- await fs.rm(tmpDir, { recursive: true, force: true });
221
- }
222
- }
223
- };
224
- function collectComponentTypes(ir) {
225
- const types = /* @__PURE__ */ new Set();
226
- for (const scene of ir.scenes) {
227
- walkComponent(scene, types);
228
- }
229
- return types;
230
- }
231
- function walkComponent(component, types) {
232
- types.add(component.type);
233
- const children = component.children;
234
- if (children) {
235
- for (const child of children) {
236
- walkComponent(child, types);
237
- }
238
- }
239
- }
240
- function generateEntryPoint(ir, options) {
241
- const compositionId = ir.video.id ?? "main";
242
- const width = ir.video.width;
243
- const height = ir.video.height;
244
- const fps = ir.video.fps ?? 30;
245
- const durationInFrames = ir.video.durationInFrames;
246
- const registrationImports = (options.registrationModules ?? []).map((m) => `import ${JSON.stringify(m)};`).join("\n");
247
- return `import React from 'react';
248
- import { Composition, registerRoot } from 'remotion';
249
- import { WavesComposition, globalRegistry, registerBuiltInComponents } from '@depths/waves/remotion';
250
- ${registrationImports}
251
-
252
- registerBuiltInComponents();
253
-
254
- const ir = ${JSON.stringify(ir, null, 2)};
255
- const compositionId = ${JSON.stringify(compositionId)};
256
-
257
- const Root = () => {
258
- return <WavesComposition ir={ir} registry={globalRegistry} />;
259
- };
260
-
261
- export const RemotionRoot = () => {
262
- return (
263
- <Composition
264
- id={compositionId}
265
- component={Root}
266
- durationInFrames={${durationInFrames}}
267
- fps={${fps}}
268
- width={${width}}
269
- height={${height}}
270
- />
271
- );
272
- };
273
-
274
- registerRoot(RemotionRoot);
275
- `;
276
- }
277
-
278
- export {
279
- __wavesVersion,
280
- getSystemPrompt,
281
- getPromptPayload,
282
- IRValidator,
283
- WavesEngine
284
- };
@@ -1,355 +0,0 @@
1
- import { z } from 'zod';
2
- import { ComponentType } from 'react';
3
-
4
- interface ComponentMetadata {
5
- category: 'primitive' | 'composite' | 'template';
6
- description: string;
7
- llmGuidance?: string;
8
- examples?: Array<Record<string, unknown>>;
9
- }
10
- interface RegisteredComponent<P = unknown> {
11
- type: string;
12
- component: ComponentType<P>;
13
- propsSchema: z.ZodType<P>;
14
- metadata: ComponentMetadata;
15
- }
16
- type PropsValidationResult = {
17
- success: true;
18
- data: unknown;
19
- } | {
20
- success: false;
21
- error: z.ZodError;
22
- };
23
- declare class ComponentRegistry {
24
- private readonly components;
25
- register<P>(registration: RegisteredComponent<P>): void;
26
- get(type: string): RegisteredComponent | undefined;
27
- getTypes(): string[];
28
- has(type: string): boolean;
29
- getJSONSchemaForLLM(): Record<string, unknown>;
30
- validateProps(type: string, props: unknown): PropsValidationResult;
31
- }
32
- declare const globalRegistry: ComponentRegistry;
33
-
34
- type TimingSpec = {
35
- from: number;
36
- durationInFrames: number;
37
- };
38
- type BackgroundSpec = {
39
- type: 'color';
40
- value: string;
41
- } | {
42
- type: 'image';
43
- value: string;
44
- } | {
45
- type: 'video';
46
- value: string;
47
- };
48
- type BaseComponentIR = {
49
- id: string;
50
- type: string;
51
- timing: TimingSpec;
52
- metadata?: Record<string, unknown> | undefined;
53
- };
54
- type TextIR = BaseComponentIR & {
55
- type: 'Text';
56
- props: {
57
- content: string;
58
- fontSize?: number;
59
- color?: string;
60
- position?: 'top' | 'center' | 'bottom' | 'left' | 'right';
61
- animation?: 'none' | 'fade' | 'slide' | 'zoom';
62
- };
63
- };
64
- type AudioIR = BaseComponentIR & {
65
- type: 'Audio';
66
- props: {
67
- src: string;
68
- volume?: number;
69
- startFrom?: number;
70
- fadeIn?: number;
71
- fadeOut?: number;
72
- };
73
- };
74
- type SceneIR = BaseComponentIR & {
75
- type: 'Scene';
76
- props: {
77
- background: BackgroundSpec;
78
- };
79
- children?: ComponentIR[] | undefined;
80
- };
81
- type ComponentIR = SceneIR | TextIR | AudioIR;
82
- type VideoIR = {
83
- version: '1.0';
84
- video: {
85
- id?: string;
86
- width: number;
87
- height: number;
88
- fps?: number;
89
- durationInFrames: number;
90
- };
91
- audio?: {
92
- background?: string | undefined;
93
- volume?: number | undefined;
94
- } | undefined;
95
- scenes: SceneIR[];
96
- };
97
- declare const TimingSpecSchema: z.ZodObject<{
98
- from: z.ZodNumber;
99
- durationInFrames: z.ZodNumber;
100
- }, z.core.$strip>;
101
- declare const AssetPathSchema: z.ZodString;
102
- declare const BackgroundSpecSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
103
- type: z.ZodLiteral<"color">;
104
- value: z.ZodString;
105
- }, z.core.$strip>, z.ZodObject<{
106
- type: z.ZodLiteral<"image">;
107
- value: z.ZodString;
108
- }, z.core.$strip>, z.ZodObject<{
109
- type: z.ZodLiteral<"video">;
110
- value: z.ZodString;
111
- }, z.core.$strip>], "type">;
112
- declare const BaseComponentIRSchema: z.ZodObject<{
113
- id: z.ZodString;
114
- type: z.ZodString;
115
- timing: z.ZodObject<{
116
- from: z.ZodNumber;
117
- durationInFrames: z.ZodNumber;
118
- }, z.core.$strip>;
119
- metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
120
- }, z.core.$strip>;
121
- declare const TextComponentIRSchema: z.ZodObject<{
122
- id: z.ZodString;
123
- timing: z.ZodObject<{
124
- from: z.ZodNumber;
125
- durationInFrames: z.ZodNumber;
126
- }, z.core.$strip>;
127
- metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
128
- type: z.ZodLiteral<"Text">;
129
- props: z.ZodObject<{
130
- content: z.ZodString;
131
- fontSize: z.ZodDefault<z.ZodNumber>;
132
- color: z.ZodDefault<z.ZodString>;
133
- position: z.ZodDefault<z.ZodEnum<{
134
- top: "top";
135
- center: "center";
136
- bottom: "bottom";
137
- left: "left";
138
- right: "right";
139
- }>>;
140
- animation: z.ZodDefault<z.ZodEnum<{
141
- fade: "fade";
142
- none: "none";
143
- slide: "slide";
144
- zoom: "zoom";
145
- }>>;
146
- }, z.core.$strip>;
147
- }, z.core.$strip>;
148
- declare const AudioComponentIRSchema: z.ZodObject<{
149
- id: z.ZodString;
150
- timing: z.ZodObject<{
151
- from: z.ZodNumber;
152
- durationInFrames: z.ZodNumber;
153
- }, z.core.$strip>;
154
- metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
155
- type: z.ZodLiteral<"Audio">;
156
- props: z.ZodObject<{
157
- src: z.ZodString;
158
- volume: z.ZodDefault<z.ZodNumber>;
159
- startFrom: z.ZodDefault<z.ZodNumber>;
160
- fadeIn: z.ZodDefault<z.ZodNumber>;
161
- fadeOut: z.ZodDefault<z.ZodNumber>;
162
- }, z.core.$strip>;
163
- }, z.core.$strip>;
164
- declare const SceneComponentIRSchema: z.ZodObject<{
165
- id: z.ZodString;
166
- timing: z.ZodObject<{
167
- from: z.ZodNumber;
168
- durationInFrames: z.ZodNumber;
169
- }, z.core.$strip>;
170
- metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
171
- type: z.ZodLiteral<"Scene">;
172
- props: z.ZodObject<{
173
- background: z.ZodDiscriminatedUnion<[z.ZodObject<{
174
- type: z.ZodLiteral<"color">;
175
- value: z.ZodString;
176
- }, z.core.$strip>, z.ZodObject<{
177
- type: z.ZodLiteral<"image">;
178
- value: z.ZodString;
179
- }, z.core.$strip>, z.ZodObject<{
180
- type: z.ZodLiteral<"video">;
181
- value: z.ZodString;
182
- }, z.core.$strip>], "type">;
183
- }, z.core.$strip>;
184
- children: z.ZodOptional<z.ZodLazy<z.ZodArray<z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>>;
185
- }, z.core.$strip>;
186
- declare const ComponentIRSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
187
- id: z.ZodString;
188
- timing: z.ZodObject<{
189
- from: z.ZodNumber;
190
- durationInFrames: z.ZodNumber;
191
- }, z.core.$strip>;
192
- metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
193
- type: z.ZodLiteral<"Scene">;
194
- props: z.ZodObject<{
195
- background: z.ZodDiscriminatedUnion<[z.ZodObject<{
196
- type: z.ZodLiteral<"color">;
197
- value: z.ZodString;
198
- }, z.core.$strip>, z.ZodObject<{
199
- type: z.ZodLiteral<"image">;
200
- value: z.ZodString;
201
- }, z.core.$strip>, z.ZodObject<{
202
- type: z.ZodLiteral<"video">;
203
- value: z.ZodString;
204
- }, z.core.$strip>], "type">;
205
- }, z.core.$strip>;
206
- children: z.ZodOptional<z.ZodLazy<z.ZodArray<z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>>;
207
- }, z.core.$strip>, z.ZodObject<{
208
- id: z.ZodString;
209
- timing: z.ZodObject<{
210
- from: z.ZodNumber;
211
- durationInFrames: z.ZodNumber;
212
- }, z.core.$strip>;
213
- metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
214
- type: z.ZodLiteral<"Text">;
215
- props: z.ZodObject<{
216
- content: z.ZodString;
217
- fontSize: z.ZodDefault<z.ZodNumber>;
218
- color: z.ZodDefault<z.ZodString>;
219
- position: z.ZodDefault<z.ZodEnum<{
220
- top: "top";
221
- center: "center";
222
- bottom: "bottom";
223
- left: "left";
224
- right: "right";
225
- }>>;
226
- animation: z.ZodDefault<z.ZodEnum<{
227
- fade: "fade";
228
- none: "none";
229
- slide: "slide";
230
- zoom: "zoom";
231
- }>>;
232
- }, z.core.$strip>;
233
- }, z.core.$strip>, z.ZodObject<{
234
- id: z.ZodString;
235
- timing: z.ZodObject<{
236
- from: z.ZodNumber;
237
- durationInFrames: z.ZodNumber;
238
- }, z.core.$strip>;
239
- metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
240
- type: z.ZodLiteral<"Audio">;
241
- props: z.ZodObject<{
242
- src: z.ZodString;
243
- volume: z.ZodDefault<z.ZodNumber>;
244
- startFrom: z.ZodDefault<z.ZodNumber>;
245
- fadeIn: z.ZodDefault<z.ZodNumber>;
246
- fadeOut: z.ZodDefault<z.ZodNumber>;
247
- }, z.core.$strip>;
248
- }, z.core.$strip>], "type">;
249
- declare const VideoIRSchema: z.ZodObject<{
250
- version: z.ZodLiteral<"1.0">;
251
- video: z.ZodObject<{
252
- id: z.ZodDefault<z.ZodString>;
253
- width: z.ZodNumber;
254
- height: z.ZodNumber;
255
- fps: z.ZodDefault<z.ZodNumber>;
256
- durationInFrames: z.ZodNumber;
257
- }, z.core.$strip>;
258
- audio: z.ZodOptional<z.ZodObject<{
259
- background: z.ZodOptional<z.ZodString>;
260
- volume: z.ZodDefault<z.ZodNumber>;
261
- }, z.core.$strip>>;
262
- scenes: z.ZodArray<z.ZodObject<{
263
- id: z.ZodString;
264
- timing: z.ZodObject<{
265
- from: z.ZodNumber;
266
- durationInFrames: z.ZodNumber;
267
- }, z.core.$strip>;
268
- metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
269
- type: z.ZodLiteral<"Scene">;
270
- props: z.ZodObject<{
271
- background: z.ZodDiscriminatedUnion<[z.ZodObject<{
272
- type: z.ZodLiteral<"color">;
273
- value: z.ZodString;
274
- }, z.core.$strip>, z.ZodObject<{
275
- type: z.ZodLiteral<"image">;
276
- value: z.ZodString;
277
- }, z.core.$strip>, z.ZodObject<{
278
- type: z.ZodLiteral<"video">;
279
- value: z.ZodString;
280
- }, z.core.$strip>], "type">;
281
- }, z.core.$strip>;
282
- children: z.ZodOptional<z.ZodLazy<z.ZodArray<z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>>;
283
- }, z.core.$strip>>;
284
- }, z.core.$strip>;
285
- declare const ComponentSchemas: {
286
- readonly Scene: z.ZodObject<{
287
- id: z.ZodString;
288
- timing: z.ZodObject<{
289
- from: z.ZodNumber;
290
- durationInFrames: z.ZodNumber;
291
- }, z.core.$strip>;
292
- metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
293
- type: z.ZodLiteral<"Scene">;
294
- props: z.ZodObject<{
295
- background: z.ZodDiscriminatedUnion<[z.ZodObject<{
296
- type: z.ZodLiteral<"color">;
297
- value: z.ZodString;
298
- }, z.core.$strip>, z.ZodObject<{
299
- type: z.ZodLiteral<"image">;
300
- value: z.ZodString;
301
- }, z.core.$strip>, z.ZodObject<{
302
- type: z.ZodLiteral<"video">;
303
- value: z.ZodString;
304
- }, z.core.$strip>], "type">;
305
- }, z.core.$strip>;
306
- children: z.ZodOptional<z.ZodLazy<z.ZodArray<z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>>;
307
- }, z.core.$strip>;
308
- readonly Text: z.ZodObject<{
309
- id: z.ZodString;
310
- timing: z.ZodObject<{
311
- from: z.ZodNumber;
312
- durationInFrames: z.ZodNumber;
313
- }, z.core.$strip>;
314
- metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
315
- type: z.ZodLiteral<"Text">;
316
- props: z.ZodObject<{
317
- content: z.ZodString;
318
- fontSize: z.ZodDefault<z.ZodNumber>;
319
- color: z.ZodDefault<z.ZodString>;
320
- position: z.ZodDefault<z.ZodEnum<{
321
- top: "top";
322
- center: "center";
323
- bottom: "bottom";
324
- left: "left";
325
- right: "right";
326
- }>>;
327
- animation: z.ZodDefault<z.ZodEnum<{
328
- fade: "fade";
329
- none: "none";
330
- slide: "slide";
331
- zoom: "zoom";
332
- }>>;
333
- }, z.core.$strip>;
334
- }, z.core.$strip>;
335
- readonly Audio: z.ZodObject<{
336
- id: z.ZodString;
337
- timing: z.ZodObject<{
338
- from: z.ZodNumber;
339
- durationInFrames: z.ZodNumber;
340
- }, z.core.$strip>;
341
- metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
342
- type: z.ZodLiteral<"Audio">;
343
- props: z.ZodObject<{
344
- src: z.ZodString;
345
- volume: z.ZodDefault<z.ZodNumber>;
346
- startFrom: z.ZodDefault<z.ZodNumber>;
347
- fadeIn: z.ZodDefault<z.ZodNumber>;
348
- fadeOut: z.ZodDefault<z.ZodNumber>;
349
- }, z.core.$strip>;
350
- }, z.core.$strip>;
351
- };
352
-
353
- declare function registerBuiltInComponents(): void;
354
-
355
- export { AssetPathSchema as A, type BackgroundSpec as B, ComponentRegistry as C, SceneComponentIRSchema as S, TextComponentIRSchema as T, type VideoIR as V, AudioComponentIRSchema as a, type AudioIR as b, BackgroundSpecSchema as c, type BaseComponentIR as d, BaseComponentIRSchema as e, type ComponentIR as f, ComponentIRSchema as g, ComponentSchemas as h, type SceneIR as i, type TextIR as j, type TimingSpec as k, TimingSpecSchema as l, VideoIRSchema as m, globalRegistry as n, registerBuiltInComponents as r };