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
+1 -1
View File
@@ -1,6 +1,6 @@
{ {
"name": "moviepilot", "name": "moviepilot",
"version": "1.5.7", "version": "1.5.7-1",
"private": true, "private": true,
"bin": "dist/service.js", "bin": "dist/service.js",
"scripts": { "scripts": {
+3 -2
View File
@@ -34,9 +34,10 @@ function goPlay() {
v-bind="hover.props" v-bind="hover.props"
:height="props.height" :height="props.height"
:width="props.width" :width="props.width"
class="shadow ring-gray-500 ring-1" class="ring-gray-500"
:class="{ :class="{
'transition transform-cpu duration-300 scale-105 shadow-lg': hover.isHovering, 'transition transform-cpu duration-300 scale-105 shadow-lg': hover.isHovering,
'ring-1': imageLoaded,
}" }"
@click="goPlay" @click="goPlay"
> >
@@ -58,7 +59,7 @@ function goPlay() {
<h1 class="mb-1 text-white font-extrabold text-xl line-clamp-2 overflow-hidden text-ellipsis ..."> <h1 class="mb-1 text-white font-extrabold text-xl line-clamp-2 overflow-hidden text-ellipsis ...">
{{ props.media?.title }} {{ props.media?.title }}
</h1> </h1>
<span class="font-bold">{{ props.media?.subtitle }}</span> <span>{{ props.media?.subtitle }}</span>
</VCardText> </VCardText>
</VImg> </VImg>
</template> </template>
+6 -1
View File
@@ -16,6 +16,11 @@ function imageLoadHandler() {
imageLoaded.value = true imageLoaded.value = true
} }
// 计算图片地址
const getImgUrl = computed(() => {
return props.media?.image || props.media?.image_list?.[0]
})
// 跳转播放 // 跳转播放
function goPlay() { function goPlay() {
if (props.media?.link) if (props.media?.link)
@@ -41,7 +46,7 @@ function goPlay() {
> >
<template #image> <template #image>
<VImg <VImg
:src="props.media?.image" :src="getImgUrl"
aspect-ratio="2/3" aspect-ratio="2/3"
cover cover
@load="imageLoadHandler" @load="imageLoadHandler"
+8 -8
View File
@@ -30,15 +30,15 @@ const dialog = ref(false)
// 从localStorage中获取数据 // 从localStorage中获取数据
const default_config = { const default_config = {
mediaStatistic: true, mediaStatistic: true,
scheduler: true, scheduler: false,
speed: true, speed: false,
storage: true, storage: true,
weeklyOverview: true, weeklyOverview: false,
cpu: true, cpu: false,
memory: true, memory: false,
library: false, library: true,
playing: false, playing: true,
latest: false, latest: true,
} }
const config = ref(JSON.parse(localStorage.getItem('MP_DASHBOARD') || '{}')) const config = ref(JSON.parse(localStorage.getItem('MP_DASHBOARD') || '{}'))
if (Object.keys(config.value).length === 0) { if (Object.keys(config.value).length === 0) {