Last active
April 24, 2025 13:45
-
-
Save ifindev/337e30a48f9ccde7a11a45a93311b17c to your computer and use it in GitHub Desktop.
AI Transcriber App
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { useState, useRef } from 'react'; | |
type AudioRecorderProps = { | |
onRetryRecording: () => void; | |
onRecordingComplete: (audioBlob: Blob) => void; | |
} | |
export function AudioRecorder({ | |
onRetryRecording, | |
onRecordingComplete, | |
}: AudioRecorderProps) { | |
const [isRecording, setIsRecording] = useState(false); | |
const [recordedAudioUrl, setRecordedAudioUrl] = useState<string | null>(null); | |
const audioChunksRef = useRef<Blob[]>([]); | |
const mediaRecorderRef = useRef<MediaRecorder | null>(null); | |
const handleStartRecording = async () => { | |
}; | |
const handleStopRecording = () => { | |
}; | |
const handleRecordAgain = () => { | |
}; | |
return ( | |
<div> | |
Audio Recorder | |
</div> | |
); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment