Skip to content

Media

Media Band

A full-width looping video or photo between two sections that drifts against the page as it scrolls past.

Layout and motion from the Kalme template — see it in context

Installation

$ npx shadcn@latest add https://framebrick.co/r/blocks/media-band.json

Usage

import { MediaBand } from "@/components/media-band";

<MediaBand video={{ src: "/video/studio.mp4", poster: "/video/studio.jpg" }} />

// or a photo
<MediaBand image={{ src: "/images/office.jpg" }} />

Props

PropTypeDefaultDescription
video{ src, poster? }a Pexels clipA muted loop; wins over image. The poster shows until it plays, and instead of it with reduced motion — use a still from the clip.
image{ src, alt? }—A photo instead of a video. With alt text the band is announced; otherwise it is decorative.
speednumber25How far the media drifts over one pass, as a percentage of the band's height (25 ≈ Framer's 150px); 0 holds it still.
classNamestring—Classes for the <section>.
  • Edge to edge, no container: the band is 480px tall (570px from 768px, 660px from 1024px) with 20px (30px, 40px) above and below; the media is 125% of its height and drifts a quarter of it with the scroll (165px on desktops, about Framer's 150px).
  • Framer ties the drift to the whole page's scroll; here it follows the band's own pass through the window, so the band works anywhere on a page of any length.
  • With reduced motion nothing moves and the video stays on its poster. The demo clip streams from Pexels; host your own file for production.

AI prompt

Paste into v0, Lovable, Bolt or Claude to rebuild this block in your own project.

Create a React + Tailwind CSS block called MediaBand (Next.js, client component).
- <section className="py-5 md:py-7.5 lg:py-10"> with no container: a full-width frame (overflow-hidden, bg-muted) 480px tall, 570px from
  768px, 660px from 1024px.
- Inside, a layer 125% of the frame's height (top and bottom -12.5%) holding a muted, looping, playsInline <video> with a poster (or an
  <img>), object-cover. On scroll, move the layer from +12.5% to -12.5% of the frame height as the frame passes through the window (translate3d,
  written straight to the element in a passive scroll listener).
- Reduced motion: no movement, and the video is paused on its poster. The section is aria-hidden unless the photo has alt text.
- Only shadcn variables and block tokens.

Be the first to know

Get new templates and components first

One short email when we release a template or a free component. No spam — unsubscribe anytime.

We use your email only for Framebrick updates. Privacy policy