diff --git a/src/components/FileList/Preview/index.js b/src/components/FileList/Preview/index.js
index 16499a0..1131f7f 100644
--- a/src/components/FileList/Preview/index.js
+++ b/src/components/FileList/Preview/index.js
@@ -4,10 +4,12 @@ import MediaDisplayer from '../../MediaDisplayer'
import styles from './index.module.css'
+const PLAYBACK_RATE = 5
+
export default function Preview ({ file }) {
return (
-
+
)
}
diff --git a/src/components/MediaDisplayer/index.js b/src/components/MediaDisplayer/index.js
index 7573b4e..0510bb4 100644
--- a/src/components/MediaDisplayer/index.js
+++ b/src/components/MediaDisplayer/index.js
@@ -6,7 +6,8 @@ const MediaDisplayer = ({
displayerRef = {},
file,
isMuted,
- onVideoUpdate = () => {}
+ onVideoUpdate = () => {},
+ playbackRate
}) => {
const videoRef = useRef()
@@ -34,6 +35,10 @@ const MediaDisplayer = ({
if (file.type === 'video') {
const video = videoRef.current
+ if (playbackRate) {
+ video.defaultPlaybackRate = playbackRate
+ }
+
const timeupdateListener = () => {
const elapsedTime = video.currentTime
const elapsedRatioCalc = video.currentTime / video.duration