Skip to content

Commit

Permalink
fix: thumbnailを追加
Browse files Browse the repository at this point in the history
(cherry picked from commit a81a50d)
  • Loading branch information
nacika-ins committed Sep 19, 2024
1 parent 4cee9f5 commit 74758a5
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
2 changes: 2 additions & 0 deletions packages/frontend/src/components/MkMediaVideo.vue
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,14 @@
</div>
<div v-else class="kkjnbbplepmiyuadieoenjgutgcmtsvu">
<MkVideoPlayer
:poster="video.thumbnailUrl"
:options="{
autoplay: false,
controls: true,
sources: [
{
src: video.url,
poster: video.thumbnailUrl,
type: video.type === 'video/quicktime' ? 'video/mp4' : video.type,
},
],
Expand Down
6 changes: 5 additions & 1 deletion packages/frontend/src/components/MkVideoPlayer.vue
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<template>
<div>
<video ref="videoPlayer" class="video-js" vjs-default-skin playsinline></video>
<video ref="videoPlayer" class="video-js" vjs-default-skin playsinline :poster="poster"></video>
</div>
</template>

Expand All @@ -16,6 +16,10 @@ export default {
default() {
return {};
},
poster: {
type: String,
default: '',
},
},
},
data() {
Expand Down

0 comments on commit 74758a5

Please sign in to comment.