File size: 680 Bytes
f2f83b0
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
// Initialize recording functionality
document.addEventListener('DOMContentLoaded', () => {
    // Timer functionality for recording
    let seconds = 0;
    const timerElement = document.getElementById('recording-timer');
    
    const timer = setInterval(() => {
        seconds++;
        const mins = Math.floor(seconds / 60).toString().padStart(2, '0');
        const secs = (seconds % 60).toString().padStart(2, '0');
        timerElement.textContent = `${mins}:${secs}`;
    }, 1000);

    // Stop recording button
    document.getElementById('stop-recording').addEventListener('click', () => {
        clearInterval(timer);
        alert('Recording stopped');
    });
});