import PlayerModel from './player' ; export default class Song extends PlayerModel { album : string ; artist : string ; constructor ( id , title , listening , image , time , album , artist ) { super ( id , title , listening , image , time ) ; this . album = ! album ? 'Unknown Album' : album ; this . artist = ! artist ? 'Unknown Artist' : artist ; this . trayMessage = `${ this . artist } • ${ this . title }` ; this . notification = `${ this . title }\n${ this . album }\n${ this . artist }` ; } getId ( ) { return `SONG_${ this . id }` ; } getState ( ) { return this . artist ; } getStartTimestamp ( ) { return undefined ; } getEndTimestamp ( ) { return this . time ; } getImageText ( ) { return this . album ; } getButtons ( ) { return [ { label : 'Play on Deezer' , url : `https://www.deezer.com/track/${ this . id }` } ] ; } }