bis
This commit is contained in:
parent
7a7c04dbe4
commit
710cd0506d
@ -112,6 +112,7 @@ function updateVinylRotation() {
|
|||||||
// Rotation proportionnelle au temps courant
|
// Rotation proportionnelle au temps courant
|
||||||
currentRotation = (audio.currentTime / audio.duration) * 360 * rotationsPerTrack;
|
currentRotation = (audio.currentTime / audio.duration) * 360 * rotationsPerTrack;
|
||||||
vinyl.style.transform = `rotate(${currentRotation}deg)`;
|
vinyl.style.transform = `rotate(${currentRotation}deg)`;
|
||||||
|
console.log('Rotation:', currentRotation); // Debug
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -121,6 +122,7 @@ vinyl.addEventListener('click', togglePlay);
|
|||||||
audio.addEventListener('timeupdate', updateProgress);
|
audio.addEventListener('timeupdate', updateProgress);
|
||||||
audio.addEventListener('loadedmetadata', () => {
|
audio.addEventListener('loadedmetadata', () => {
|
||||||
durationEl.textContent = formatTime(audio.duration);
|
durationEl.textContent = formatTime(audio.duration);
|
||||||
|
console.log('Audio duration:', audio.duration);
|
||||||
});
|
});
|
||||||
progress.addEventListener('click', setProgress);
|
progress.addEventListener('click', setProgress);
|
||||||
|
|
||||||
|
|||||||
@ -78,8 +78,8 @@ body {
|
|||||||
height: 600px;
|
height: 600px;
|
||||||
border-radius: 50%;
|
border-radius: 50%;
|
||||||
background: radial-gradient(circle at center, #444 0%, #111 60%, #000 100%);
|
background: radial-gradient(circle at center, #444 0%, #111 60%, #000 100%);
|
||||||
animation: spin 4s linear infinite;
|
/*animation: spin 4s linear infinite;
|
||||||
animation-play-state: paused;
|
animation-play-state: paused;*/
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user