Letter Gate

The camera pushes into a giant letter pair and the gap opens like a gate onto the next scene. A free, MIT-licensed Remotion transition.

Installation
$ pnpm dlx shadcn@latest add @remocn/letter-gate

Usage

tsx
// src/Root.tsx
import { Composition } from "remotion";
import { LetterGateDemo } from "@/components/remocn/letter-gate";
 
const LetterGateDemoScene = () => (
  <LetterGateDemo
    text="Start building"
    gate="bu"
    prompt="A launch film for v2"
  />
);
 
export const RemotionRoot = () => (
  <Composition
    id="LetterGateDemo"
    component={LetterGateDemoScene}
    durationInFrames={236}
    fps={60}
    width={1280}
    height={720}
  />
);

Scene A shows a short headline while the camera punches in twice. It then pushes into the letter pair named by gate, and the pair opens like a gate onto scene B, a prompt box with a label and a next step. Set text and make sure gate is a two-letter run inside it, then pass prompt, placeholder, label and nextLabel for scene B; it ships light and dark.

The ground is a live gradients.sh shader (GshGround), installed with the component as @remocn/gsh. Pick another look with the ground preset prop.

Props21

PropTypeDefault
theme
"dark" | "light""dark"

Light or dark palette for both scenes

accent
string—

Accent color; defaults to the theme accent

ink
string—

Text color of the pill, the gate letters and the prompt; overrides the theme ink.

background
string—

Solid fill in place of both gradient grounds; pass "transparent" to drop it.

fontFamily
string"Geist"

Typeface for the pill and the gate letters. Load the font in your project first.

fontWeight
number400

Weight of the pill and the gate letters

text
string"Start building"

Headline shown in scene A; the gate letters are taken from it

gate
string"bu"

Two-letter run inside text that the camera pushes into

prompt
string"A launch film for v2"

Text typed into the scene B prompt box

placeholder
string"Describe your launch"

Placeholder shown in the prompt box before typing

label
string"Prompt"

Label above the prompt box in scene B

nextLabel
string"Script"

Label typed into the next-step node after the press

logo
React.ReactNode—

Replaces the remocn mark above the pill.

ground
GshPresetId—

Preset id for the scene A gradients.sh shader ground

groundParams
Partial<GradientParams>—

Overrides for the scene A shader parameters

groundB
GshPresetId—

Preset id for the scene B gradients.sh shader ground

groundParamsB
Partial<GradientParams>—

Overrides for the scene B shader parameters

transition
LetterGateProps—

Overrides for the transition presentation props

scale
number1

Size of both scenes' foreground around the frame's center; the grounds stay put.

delay
number0

Frames to hold the first frame before anything moves.

speed
number1

Playback speed multiplier for the whole timeline.

  • theme"dark" | "light"

    Light or dark palette for both scenes

    Default"dark"

  • accentstring

    Accent color; defaults to the theme accent

  • inkstring

    Text color of the pill, the gate letters and the prompt; overrides the theme ink.

  • backgroundstring

    Solid fill in place of both gradient grounds; pass "transparent" to drop it.

  • fontFamilystring

    Typeface for the pill and the gate letters. Load the font in your project first.

    Default"Geist"

  • fontWeightnumber

    Weight of the pill and the gate letters

    Default400

  • textstring

    Headline shown in scene A; the gate letters are taken from it

    Default"Start building"

  • gatestring

    Two-letter run inside text that the camera pushes into

    Default"bu"

  • promptstring

    Text typed into the scene B prompt box

    Default"A launch film for v2"

  • placeholderstring

    Placeholder shown in the prompt box before typing

    Default"Describe your launch"

  • labelstring

    Label above the prompt box in scene B

    Default"Prompt"

  • nextLabelstring

    Label typed into the next-step node after the press

    Default"Script"

  • logoReact.ReactNode

    Replaces the remocn mark above the pill.

  • groundGshPresetId

    Preset id for the scene A gradients.sh shader ground

  • groundParamsPartial<GradientParams>

    Overrides for the scene A shader parameters

  • groundBGshPresetId

    Preset id for the scene B gradients.sh shader ground

  • groundParamsBPartial<GradientParams>

    Overrides for the scene B shader parameters

  • transitionLetterGateProps

    Overrides for the transition presentation props

  • scalenumber

    Size of both scenes' foreground around the frame's center; the grounds stay put.

    Default1

  • delaynumber

    Frames to hold the first frame before anything moves.

    Default0

  • speednumber

    Playback speed multiplier for the whole timeline.

    Default1