Skip to Content
Kokonut UI

MD-02Media

Synced Transcript

A transcript that follows the spoken word, lets you click any word to jump there, and waits when you scroll away.

Install with
lucide-react

PROAudio Player Card and more like it are in Kokonut UI Pro

Installation

Synced Transcript is a free, open-source React component in the Kokonut UI Media collection. Add it with the shadcn CLI, which copies the source into components/kokonutui/synced-transcript.tsx, so the code is yours to change.

npx shadcn@latest add @kokonutui/synced-transcript

Or add it by hand: install its packages, then copy the source from Copy code above into components/kokonutui/synced-transcript.tsx.

npm install lucide-react

Usage

import SyncedTranscript from "@/components/kokonutui/synced-transcript";

export default function Example() {
  return <SyncedTranscript />;
}

Props

title
stringDefault "Frame Rate · Episode 48"
segments
TranscriptSegment[]Default built-in
duration
number

Seconds. Defaults to the end of the last segment. Playback is simulated; drive it from your own audio with onTimeChange.

onTimeChange
(seconds: number) => void
className
string

Extra classes for the root element.

TranscriptSegment

speakerrequired
string
startrequired
number

Seconds from the start.

endrequired
number
textrequired
string

Dependencies

NeedsVersionComes from
lucide-react^0.556.0npm, installed by the CLI
cn from lib/utils.tsshadcn init
React19Your app
Tailwind CSS4Your app

No provider, font or global CSS to set up: the file works as soon as it lands.