合并行
This commit is contained in:
parent
cd6b0bc4e5
commit
9871408e40
@ -3,8 +3,7 @@ import { Span, Button, List, ListItem, UploadMusic } from './weigets.js'
|
|||||||
export default class MusicList {
|
export default class MusicList {
|
||||||
constructor({ list = [], EventListeners = {}, onplay, onstop, onadd, onremove, onlike, onunlike, onban, onload }) {
|
constructor({ list = [], EventListeners = {}, onplay, onstop, onadd, onremove, onlike, onunlike, onban, onload }) {
|
||||||
this.event = { onplay, onstop, onadd, onremove, onlike, onunlike, onban, onload }
|
this.event = { onplay, onstop, onadd, onremove, onlike, onunlike, onban, onload }
|
||||||
this.ul = List({})
|
this.ul = List({ classList: ['music-list'] })
|
||||||
this.ul.classList.add('music-list')
|
|
||||||
this.EventListeners = EventListeners
|
this.EventListeners = EventListeners
|
||||||
this.list = []
|
this.list = []
|
||||||
list.forEach(item => this.add(item)) // 列表逐一添加
|
list.forEach(item => this.add(item)) // 列表逐一添加
|
||||||
|
Loading…
Reference in New Issue
Block a user