|
@@ -245,7 +245,7 @@ export default defineComponent({
|
|
|
}
|
|
|
}
|
|
|
|
|
|
- console.log(list, 'list')
|
|
|
+ // console.log(list, 'list')
|
|
|
|
|
|
let _firstIndex = list.findIndex(
|
|
|
(n: any) =>
|
|
@@ -254,7 +254,7 @@ export default defineComponent({
|
|
|
_firstIndex = _firstIndex > -1 ? _firstIndex : 0
|
|
|
const item = list[_firstIndex]
|
|
|
|
|
|
- console.log(_firstIndex, '_firstIndex', route.query.kId, 'route.query.kId', item)
|
|
|
+ // console.log(_firstIndex, '_firstIndex', route.query.kId, 'route.query.kId', item)
|
|
|
// 是否自动播放
|
|
|
if (activeData.isAutoPlay) {
|
|
|
item.autoPlay = true
|
|
@@ -447,8 +447,10 @@ export default defineComponent({
|
|
|
const activeItem = data.itemList[i]
|
|
|
|
|
|
if (activeItem.type === 'VIDEO') {
|
|
|
- activeItem.videoEle?.pause()
|
|
|
- activeItem.videoEle?.stop()
|
|
|
+ if (popupData.activeIndex !== i) {
|
|
|
+ activeItem.videoEle?.pause()
|
|
|
+ activeItem.videoEle?.stop()
|
|
|
+ }
|
|
|
}
|
|
|
// console.log('🚀 ~ activeItem:', activeItem)
|
|
|
// 停止曲谱的播放
|
|
@@ -503,7 +505,7 @@ export default defineComponent({
|
|
|
if (item && item.type === 'VIDEO') {
|
|
|
const videoEle: HTMLVideoElement = item.videoEle
|
|
|
if (videoEle) {
|
|
|
- if (videoEle.paused) {
|
|
|
+ if (videoEle?.paused) {
|
|
|
closeToast()
|
|
|
videoEle.play()
|
|
|
} else {
|
|
@@ -730,8 +732,10 @@ export default defineComponent({
|
|
|
>
|
|
|
<div class={styles.wraps}>
|
|
|
{data.itemList.map((m: any, mIndex: number) => {
|
|
|
- const isRender = Math.abs(popupData.activeIndex - mIndex) < 4
|
|
|
+ const isRender = Math.abs(popupData.activeIndex - mIndex) < 3
|
|
|
const isEmtry = Math.abs(popupData.activeIndex - mIndex) > 2
|
|
|
+ // const isRender = Math.abs(popupData.activeIndex - mIndex) < 2;
|
|
|
+ // const isEmtry = Math.abs(popupData.activeIndex - mIndex) > 4;
|
|
|
// if (isRender) {
|
|
|
// m.isRender = true
|
|
|
// }
|