like ban
This commit is contained in:
		@@ -78,7 +78,14 @@ export default class MusicList {
 | 
				
			|||||||
                    innerText: '喜欢',
 | 
					                    innerText: '喜欢',
 | 
				
			||||||
                    onclick: event => {
 | 
					                    onclick: event => {
 | 
				
			||||||
                        event.stopPropagation()
 | 
					                        event.stopPropagation()
 | 
				
			||||||
                        // 留存到本地
 | 
					                        this.like(item)
 | 
				
			||||||
 | 
					                    }
 | 
				
			||||||
 | 
					                }),
 | 
				
			||||||
 | 
					                Button({
 | 
				
			||||||
 | 
					                    innerText: '禁止',
 | 
				
			||||||
 | 
					                    onclick: event => {
 | 
				
			||||||
 | 
					                        event.stopPropagation()
 | 
				
			||||||
 | 
					                        // BAN
 | 
				
			||||||
                    }
 | 
					                    }
 | 
				
			||||||
                })
 | 
					                })
 | 
				
			||||||
            ]
 | 
					            ]
 | 
				
			||||||
@@ -116,6 +123,15 @@ export default class MusicList {
 | 
				
			|||||||
        this.audio.src = ''
 | 
					        this.audio.src = ''
 | 
				
			||||||
        this._on('stop')
 | 
					        this._on('stop')
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					    like(item) {
 | 
				
			||||||
 | 
					        if (!item.arrayBuffer) {
 | 
				
			||||||
 | 
					            console.log('载入缓存:', item)
 | 
				
			||||||
 | 
					            return
 | 
				
			||||||
 | 
					        } else {
 | 
				
			||||||
 | 
					            console.log('移除缓存:', item)
 | 
				
			||||||
 | 
					            return
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
    next() { }
 | 
					    next() { }
 | 
				
			||||||
    prev() { }
 | 
					    prev() { }
 | 
				
			||||||
    // 添加回调函数
 | 
					    // 添加回调函数
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user