Answer First
The question "Who made this video?" is answered by a big "A pull request.". A free, MIT-licensed Remotion text animation.
$ pnpm dlx shadcn@latest add @remocn/answer-firstUsage
// src/Root.tsx
import { Composition } from "remotion";
import { AnswerFirst } from "@/components/remocn/answer-first";
const AnswerFirstScene = () => <AnswerFirst answer="A pull request." question="Who made this video?" />;
export const RemotionRoot = () => (
<Composition
id="AnswerFirst"
component={AnswerFirstScene}
durationInFrames={240}
fps={60}
width={1280}
height={720}
/>
);A big answer rises word by word first, then slides up and shrinks as the question types in below it, so the reader sees the answer before the question. Pass answer and question.
Props12
| Prop | Type | Default |
|---|---|---|
| answer | string"A pull request." The big answer line shown first. | |
| question | string"Who made this video?" The question that types in beneath the answer. | |
| accent | string— Color of the question text; defaults to the theme accent. | |
| ink | string— Text color; overrides the theme ink. | |
| background | string— Stage fill color; pass "transparent" to overlay your own footage. | |
| fontFamily | string"Outfit" Typeface for the copy. Load the font in your project first. | |
| moveAt | number34 Frame the answer starts shrinking into the corner; the question follows it. | |
| stagger | number4 Frames between words of the question. | |
| scale | number1 Size of the foreground around the frame's center; the background stays put. | |
| delay | number0 Frames to hold the first frame before anything moves. | |
| speed | number1 Playback multiplier for the whole timeline. | |
| theme | "dark" | "light""dark" Color scheme; ships dark and light. | |
- answerstring
The big answer line shown first.
Default
"A pull request." - questionstring
The question that types in beneath the answer.
Default
"Who made this video?" - accentstring
Color of the question text; defaults to the theme accent.
- inkstring
Text color; overrides the theme ink.
- backgroundstring
Stage fill color; pass "transparent" to overlay your own footage.
- fontFamilystring
Typeface for the copy. Load the font in your project first.
Default
"Outfit" - moveAtnumber
Frame the answer starts shrinking into the corner; the question follows it.
Default
34 - staggernumber
Frames between words of the question.
Default
4 - scalenumber
Size of the foreground around the frame's center; the background stays put.
Default
1 - delaynumber
Frames to hold the first frame before anything moves.
Default
0 - speednumber
Playback multiplier for the whole timeline.
Default
1 - theme"dark" | "light"
Color scheme; ships dark and light.
Default
"dark"