Files
hermes-agent-mission-control/src/remotion/index.tsx
T

26 lines
706 B
TypeScript
Raw Normal View History

2026-09-22 20:16:25 +07:00
import { registerRoot, Composition } from "remotion";
import { ShortsVideo, useTotalDuration } from "./ShortsVideo";
const DEFAULT_SEGMENTS = [
{ text: "Demo shorts — configure --props to customize.", duration: 60 },
];
const Shorts: React.FC = () => {
return (
<Composition
id="Shorts"
component={ShortsVideo as any}
durationInFrames={60}
fps={30}
width={1080}
height={1920}
defaultProps={{ segments: DEFAULT_SEGMENTS }}
calculateMetadata={({ props }) => {
const segs = props.segments?.length ? props.segments : DEFAULT_SEGMENTS;
return { durationInFrames: useTotalDuration(segs) };
}}
/>
);
};
registerRoot(Shorts);