This commit is contained in:
jxxghp
2024-01-05 20:40:44 +08:00
parent 11e82582b8
commit 9b753a8f5b
4 changed files with 18 additions and 12 deletions
+6 -1
View File
@@ -16,6 +16,11 @@ function imageLoadHandler() {
imageLoaded.value = true
}
// 计算图片地址
const getImgUrl = computed(() => {
return props.media?.image || props.media?.image_list?.[0]
})
// 跳转播放
function goPlay() {
if (props.media?.link)
@@ -41,7 +46,7 @@ function goPlay() {
>
<template #image>
<VImg
:src="props.media?.image"
:src="getImgUrl"
aspect-ratio="2/3"
cover
@load="imageLoadHandler"