()
| 654 | } |
| 655 | |
| 656 | const animateVideo = async () => { |
| 657 | if (!videoRef.current) return |
| 658 | if (!dragging) { |
| 659 | setProgress(videoRef.current.currentTime) |
| 660 | setDuration(videoRef.current.duration) |
| 661 | } |
| 662 | update() |
| 663 | draw() |
| 664 | if (paused) return |
| 665 | videoID = videoRef.current?.requestVideoFrameCallback(animateVideo) ?? 0 |
| 666 | } |
| 667 | |
| 668 | if (adjustedData) { |
| 669 | if (paused) draw() |