🚲 修复一些Bug, 新增自动播放下一集

This commit is contained in:
hunlongyu
2020-04-22 13:44:32 +08:00
parent 0776147a89
commit 8ea52857a5
7 changed files with 41 additions and 14 deletions

View File

@@ -21,7 +21,6 @@
</div>
<!-- type -->
<div class="zy-select" @mouseleave="show.type = false" v-if="site.tags[tag].children.length > 0">
<!-- <div class="vs-placeholder" @click="show.type = true">{{site.tags[tag].children[type].title}}</div> -->
<div class="vs-placeholder" @click="show.type = true">{{typeName}}</div>
<div class="vs-options" v-show="show.type">
<ul>

View File

@@ -225,6 +225,11 @@ export default {
this.xg.play()
}
this.onPlayVideo()
this.xg.once('ended', () => {
if (res.m3u8_urls.length > 1 && (res.m3u8_urls.length - 1 > this.video.index)) {
this.video.index++
}
})
}).catch(err => {
this.$m.error(err)
})

View File

@@ -103,12 +103,10 @@ export default {
right: 20px;
width: 540px;
height: 360px;
background-color: #fff;
border-radius: 2px;
display: flex;
justify-content: space-between;
align-items: center;
border: 1px solid #cfcfcf;
padding: 20px;
z-index: 888;
.left, .right{
@@ -128,7 +126,6 @@ export default {
.right{
.title{
font-size: 18px;
color: #666;
margin-bottom: 10px;
overflow: hidden;
text-overflow: ellipsis;
@@ -140,7 +137,6 @@ export default {
.tips{
font-size: 14px;
text-align: center;
color: #808695;
img{
width: 50px;
}
@@ -158,7 +154,6 @@ export default {
display: flex;
justify-content: center;
align-items: center;
background-color: #fff;
.loader {
color: #823aa055;
font-size: 8px;