Column Reflow
A justified paragraph reflows its column width, redistributing lines with even word spacing. A free, MIT-licensed Remotion text animation.
$ pnpm dlx shadcn@latest add @remocn/column-reflowUsage
// src/Root.tsx
import { Composition } from "remotion";
import { ColumnReflow } from "@/components/remocn/column-reflow";
const ColumnReflowScene = () => <ColumnReflow text="Good motion starts with good typography." accentWord="typography" direction="widen" />;
export const RemotionRoot = () => (
<Composition
id="ColumnReflow"
component={ColumnReflowScene}
durationInFrames={240}
fps={60}
width={1280}
height={720}
/>
);A justified serif paragraph sits in a column, then the column widens (or narrows) while words glide to new lines and the spacing is redistributed evenly, ending with one accent word in italic. Pass text, accentWord and direction.
Props13
| Prop | Type | Default |
|---|---|---|
| text | stringDEFAULT_TEXT The paragraph to set and reflow. | |
| accentWord | string"room" Word set in accent color and italic. | |
| direction | "widen" | "narrow""widen" Whether the column starts narrow and widens, or the reverse. | |
| measure | number9.6 Width of the narrow column, in ems of the type. | |
| theme | "dark" | "light""dark" Color scheme; ships dark and light. | |
| fontFamily | string"Newsreader" Typeface for the copy. Load the font in your project first. | |
| 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. | |
| grain | booleantrue Film grain over the scene. | |
| speed | number1 Playback multiplier for the whole timeline. | |
| accent | string— Accepted for parity with the other pieces; not used. The accent word is set apart by its italic serif, not by color. | |
| ink | string— Text color; overrides the theme ink. | |
| background | string— Background fill; pass "transparent" to drop it. | |
- textstring
The paragraph to set and reflow.
Default
DEFAULT_TEXT - accentWordstring
Word set in accent color and italic.
Default
"room" - direction"widen" | "narrow"
Whether the column starts narrow and widens, or the reverse.
Default
"widen" - measurenumber
Width of the narrow column, in ems of the type.
Default
9.6 - theme"dark" | "light"
Color scheme; ships dark and light.
Default
"dark" - fontFamilystring
Typeface for the copy. Load the font in your project first.
Default
"Newsreader" - 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 - grainboolean
Film grain over the scene.
Default
true - speednumber
Playback multiplier for the whole timeline.
Default
1 - accentstring
Accepted for parity with the other pieces; not used. The accent word is set apart by its italic serif, not by color.
- inkstring
Text color; overrides the theme ink.
- backgroundstring
Background fill; pass "transparent" to drop it.