383331e8f1
Grows the scene-block library toward full template-type coverage: - LogoReveal: premium logo-motion — spring scale-in + glint sweep over the logo (image upload or a branded play-mark placeholder) + brand text + tagline, on the shared 2.5D Three backdrop. Fields: logoUrl, brandText, tagline. - StatCounter: animated count-up to a target (English-digit value → Persian display) + suffix + label. Fields: value, suffix, label. Registry now has 8 blocks. Both verified via FlexStory props-override stills. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
29 lines
1.2 KiB
TypeScript
29 lines
1.2 KiB
TypeScript
import type { SceneBlock } from "./types";
|
|
import { TitleCardBlock } from "./blocks/TitleCard";
|
|
import { CharacterSceneBlock } from "./blocks/CharacterScene";
|
|
import { ImageCaptionBlock } from "./blocks/ImageCaption";
|
|
import { KineticQuoteBlock } from "./blocks/KineticQuote";
|
|
import { SlideshowBlock } from "./blocks/Slideshow";
|
|
import { OutroCTABlock } from "./blocks/OutroCTA";
|
|
import { LogoRevealBlock } from "./blocks/LogoReveal";
|
|
import { StatCounterBlock } from "./blocks/StatCounter";
|
|
|
|
/**
|
|
* The scene-block registry. A FlexStory template is an ordered list of these
|
|
* blocks; new template types = new blocks. Each block declares its editable
|
|
* fields + duration range (so the studio can clamp per-block, not globally).
|
|
*/
|
|
export const SCENE_BLOCKS: Record<string, SceneBlock> = {
|
|
[TitleCardBlock.id]: TitleCardBlock,
|
|
[CharacterSceneBlock.id]: CharacterSceneBlock,
|
|
[ImageCaptionBlock.id]: ImageCaptionBlock,
|
|
[KineticQuoteBlock.id]: KineticQuoteBlock,
|
|
[SlideshowBlock.id]: SlideshowBlock,
|
|
[OutroCTABlock.id]: OutroCTABlock,
|
|
[LogoRevealBlock.id]: LogoRevealBlock,
|
|
[StatCounterBlock.id]: StatCounterBlock,
|
|
};
|
|
|
|
export const BLOCK_LIST = Object.values(SCENE_BLOCKS);
|
|
export const getBlock = (id: string): SceneBlock | undefined => SCENE_BLOCKS[id];
|