Merge pull request '[PR]: Fix Quicktime (.mov) Video Player on Chrome' (#10503) from dvd/calckey:fix/quicktime-on-chrome into develop

Reviewed-on: https://codeberg.org/calckey/calckey/pulls/10503
This commit is contained in:
Kainoa Kanter 2023-07-16 18:14:51 +00:00
commit 58cd156a54

View File

@ -54,7 +54,7 @@
controls controls
@contextmenu.stop @contextmenu.stop
> >
<source :src="media.url" :type="media.type" /> <source :src="media.url" :type="mediaType" />
</video> </video>
</VuePlyr> </VuePlyr>
</template> </template>
@ -80,7 +80,7 @@
</template> </template>
<script lang="ts" setup> <script lang="ts" setup>
import { watch, ref } from "vue"; import { watch, ref, computed } from "vue";
import VuePlyr from "vue-plyr"; import VuePlyr from "vue-plyr";
import "vue-plyr/dist/vue-plyr.css"; import "vue-plyr/dist/vue-plyr.css";
import type * as misskey from "calckey-js"; import type * as misskey from "calckey-js";
@ -107,6 +107,10 @@ const url =
? getStaticImageUrl(props.media.thumbnailUrl) ? getStaticImageUrl(props.media.thumbnailUrl)
: props.media.thumbnailUrl; : props.media.thumbnailUrl;
const mediaType = computed(() => {
return props.media.type === 'video/quicktime' ? 'video/mp4' : props.media.type;
});
function captionPopup() { function captionPopup() {
os.alert({ os.alert({
type: "info", type: "info",