diff --git a/src/components/cards/DownloadingCard.vue b/src/components/cards/DownloadingCard.vue index da32bb40..05b4a556 100644 --- a/src/components/cards/DownloadingCard.vue +++ b/src/components/cards/DownloadingCard.vue @@ -23,6 +23,11 @@ function getSpeedText() { // 下载状态 const isDownloading = ref(props.info?.state === 'downloading') +// 监听props.info?.state的变化 +watch(() => props.info?.state, (newValue) => { + isDownloading.value = newValue === 'downloading'; +}); + // 图片是否加载完成 const imageLoaded = ref(false)