From 15fa6f3bfb7a1d67589d2beb9b157a4a74e5d67c Mon Sep 17 00:00:00 2001 From: hunlongyu Date: Thu, 7 May 2020 21:17:50 +0800 Subject: [PATCH] =?UTF-8?q?=F0=9F=91=94=20=E5=A2=9E=E5=8A=A0=E5=88=87?= =?UTF-8?q?=E6=8D=A2=E8=A7=86=E9=A2=91=E7=9A=84=E9=81=AE=E7=BD=A9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- package.json | 2 +- src/assets/scss/theme/light.scss | 3 +++ src/components/Play.vue | 21 ++++++++++++++++++--- 3 files changed, 22 insertions(+), 4 deletions(-) diff --git a/package.json b/package.json index e78f01a..740064c 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "zy", - "version": "0.9.24", + "version": "0.9.25", "private": true, "author": { "name": "Hunlongyu", diff --git a/src/assets/scss/theme/light.scss b/src/assets/scss/theme/light.scss index a455796..fb1265a 100644 --- a/src/assets/scss/theme/light.scss +++ b/src/assets/scss/theme/light.scss @@ -221,6 +221,9 @@ } } } + .mask{ + background-color: var(--l-bgc-1); + } } .list{ border: 1px solid var(--l-c-3); diff --git a/src/components/Play.vue b/src/components/Play.vue index 812fe7c..fb98985 100644 --- a/src/components/Play.vue +++ b/src/components/Play.vue @@ -3,6 +3,9 @@
{{name}}
+
+
+
@@ -134,7 +137,8 @@ export default { more: true, showNext: false, isStar: false, - isTop: false + isTop: false, + mask: false } }, computed: { @@ -191,6 +195,7 @@ export default { methods: { ...mapMutations(['SET_VIEW', 'SET_DETAIL', 'SET_VIDEO', 'SET_SHARE']), getUrls () { + this.mask = true if (this.timer !== null) { clearInterval(this.timer) this.timer = null @@ -225,6 +230,9 @@ export default { } else { this.xg.play() } + this.xg.once('play', () => { + this.mask = false + }) this.onPlayVideo() this.xg.once('ended', () => { if (res.m3u8_urls.length > 1 && (res.m3u8_urls.length - 1 > this.video.index)) { @@ -233,8 +241,6 @@ export default { } this.xg.off('ended') }) - }).catch(err => { - this.$m.error(err) }) }, changeVideo () { @@ -292,6 +298,7 @@ export default { const v = { ...this.video } const i = v.index + 1 if (i < this.right.listData.length) { + this.video.currentTime = 0 this.video.index++ } else { this.$m.warning(this.$t('last_video')) @@ -430,6 +437,14 @@ export default { cursor: pointer; } } + .mask{ + position: absolute; + top: 0; + left: 0; + width: 100%; + height: 100%; + z-index: 600; + } } .list{ position: absolute;