A wordmark rendered as a window into a looping video (or a still photograph), with the rest of the canvas filled by a solid backdrop colour. The text IS the visible footage.
import TextVideoMask from '@crazygl/hero-text-video-mask';
export default function Page() {
return (
<TextVideoMask
heading="VIDEO"
media="/videos/launch-reel.mp4"
bgColor="#000000"
fontSize={320}
/>
);
}heading (the masked word), subheading, ctaLabel, onCTAClick.media (MP4/WebM/MOV video or JPG/PNG/WebP/AVIF still), autoplay, loop, muted.textAlign, fontSize, letterSpacing, headingFontFamily, headingFontWeight.bgColor, textColor (solid fallback when no media).npm install @crazygl/hero-text-video-maskThe component takes the same props you see in the live customizer on the right — every default ships poster-quality.
import TextVideoMask from '@crazygl/hero-text-video-mask';
export default function Landing() {
return (
<TextVideoMask />
);
}The wrapper renders static HTML on the server and only initialises the canvas after hydration, so search engines see your copy.
// app/page.tsx — works in SSR-first frameworks (Next, Remix, Astro, etc.)
'use client';
import TextVideoMask from '@crazygl/hero-text-video-mask';
export default function Page() {
return (
<section>
<TextVideoMask
heading="Say hi."
subheading="Your new hero."
/>
<article>
<h2>Welcome</h2>
<p>Your content keeps its own voice below the hero.</p>
</article>
</section>
);
}