Skip to content

Repository files navigation

Transcript Editor

Overview

The Transcript Editor is a web application built with React and Tailwind CSS, allowing users to interact with a transcript where each word has a designated start time and duration for playback. The user can play the transcript, which will highlight words in real-time based on their timing, and edit the transcript without deleting any words.

Features

  • Transcript Playback:

    • Words in the transcript are highlighted based on their start time and duration.
    • Playback is sequential and provides a real-time visual representation of the spoken words.
  • Transcript Editing:

    • Users can click on any word to edit its text.
    • Word deletions are not allowed to maintain the integrity of the transcript.
  • Responsive Design:

    • The application is styled using Tailwind CSS to ensure a responsive and user-friendly interface.

Project Structure

src/
│
├── components/
│   └── TranscriptEditor.js    # Main component to handle transcript playback and editing
├── App.js                     # Entry point for the application
├── index.js                   # Renders the React application
└── styles/
    └── index.css              # Global styles

Example Transcript Structure

Here’s an example of how a transcript is structured in the application:

[
  { "word": "Hello", "start_time": 0, "duration": 500 },
  { "word": "world", "start_time": 500, "duration": 700 },
  { "word": "This", "start_time": 1200, "duration": 300 },
  { "word": "is", "start_time": 1500, "duration": 200 },
  { "word": "a", "start_time": 1700, "duration": 100 },
  { "word": "test", "start_time": 1800, "duration": 400 }
]

Each word has:

  • start_time: The time (in milliseconds) when the word should start being highlighted during playback.
  • duration: The duration (in milliseconds) the word remains highlighted.

Getting Started

Prerequisites

Installation

  1. Clone the repository:

    git clone https://github.com/your-username/transcript-editor.git
    cd transcript-editor
  2. Install the dependencies:

    npm install
    # or
    yarn install

Running the Application

To start the development server, run:

npm start
# or
yarn start

This will launch the application on http://localhost:3000/.

Building the Application

To build the application for production, run:

npm run build
# or
yarn build

The build files will be output to the build/ directory, which you can deploy to any static hosting platform.

Usage

  1. Once the app is running, a transcript will be displayed with each word clickable for editing.
  2. Press the Play button to begin the playback, and the words will be highlighted sequentially based on their timing.
  3. To edit a word, click on it and change the text, but note that words cannot be deleted.

Technologies Used

  • React: JavaScript library for building user interfaces.
  • Tailwind CSS: Utility-first CSS framework for styling.
  • Additional libraries may be used for enhancing the playback and editing experience.

Future Enhancements

  • Real-time Playback Control: Add the ability to pause, skip forward/backward, and adjust playback speed.
  • Multiple Transcript Support: Allow loading and switching between multiple transcripts.
  • Advanced Editing: Include more comprehensive editing features, such as time adjustment for each word.

License

This project is licensed under the MIT License. See the LICENSE file for details.

Contributing

If you would like to contribute to this project, please fork the repository and submit a pull request with your changes. Contributions and suggestions are always welcome!


This README.md provides a clear introduction to the project, how to use it, and how to contribute.

This is a Next.js project bootstrapped with create-next-app.

Getting Started

First, run the development server:

npm run dev
# or
yarn dev
# or
pnpm dev
# or
bun dev

Open http://localhost:3000 with your browser to see the result.

You can start editing the page by modifying app/page.js. The page auto-updates as you edit the file.

This project uses next/font to automatically optimize and load Inter, a custom Google Font.

Learn More

To learn more about Next.js, take a look at the following resources:

You can check out the Next.js GitHub repository - your feedback and contributions are welcome!

Deploy on Vercel

The easiest way to deploy your Next.js app is to use the Vercel Platform from the creators of Next.js.

Check out our Next.js deployment documentation for more details.

About

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages