-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathscript.js
253 lines (251 loc) · 7.3 KB
/
script.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
Amplitude.init({
songs: [
{
name: "Black & Blue",
artist: "Avicii feat. Aloe Blacc, Mac Davis",
album: "Single",
url: "./music/track/Black & Blue.mp3",
cover_art_url: "./music/cover/Black & Blue.jpg",
},
{
name: "Bright Lights (Version 1)",
artist: "Avicii, Syn Cole",
album: "Single",
url: "./music/track/Bright Lights (Version 1).mp3",
cover_art_url: "./music/cover/Bright Lights (Version 1).jpg",
},
{
name: "Bright Lights (Version 2)",
artist: "Avicii, Syn Cole",
album: "Single",
url: "./music/track/Bright Lights (Version 2).mp3",
cover_art_url: "./music/cover/Bright Lights (Version 2).jpg",
},
{
name: "Broken Heart & Hennessy",
artist: "Avicii feat. Mike Posner",
album: "Single",
url: "./music/track/Broken Heart & Hennessy.mp3",
cover_art_url: "./music/cover/Broken Heart & Hennessy.jpg",
},
{
name: "Can't Get Enough",
artist: "Avicii, Cazzette feat. The High",
album: "Single",
url: "./music/track/Can't Get Enough.mp3",
cover_art_url: "./music/cover/Can't Get Enough.jpg",
},
{
name: "Can't Love You Again",
artist: "Avicii, Tom Odell",
album: "Single",
url: "./music/track/Can't Love You Again.mp3",
cover_art_url: "./music/cover/Can't Love You Again.jpg",
},
{
name: "Chained",
artist: "Avicii, AlexST",
album: "Single",
url: "./music/track/Chained.mp3",
cover_art_url: "./music/cover/Chained.jpg",
},
{
name: "Enough is Enough",
artist: "Avicii",
album: "Single",
url: "./music/track/Enough is Enough.mp3",
cover_art_url: "./music/cover/Enough is Enough.jpg",
},
{
name: "Faster Than Light",
artist: "Avicii feat. Sandro Cavazza",
album: "Single",
url: "./music/track/Faster Than Light.mp3",
cover_art_url: "./music/cover/Faster Than Light.jpg",
},
{
name: "Finally",
artist: "Avicii, Kings Of Tomorrow Kings Of Tomorrow feat. Julie McKnight",
album: "Single",
url: "./music/track/Finally.mp3",
cover_art_url: "./music/cover/Finally.jpg",
},
{
name: "Heaven",
artist: "Avicii feat. Simon Aldred",
album: "Single",
url: "./music/track/Heaven.mp3",
cover_art_url: "./music/cover/Heaven.jpg",
},
{
name: "How Many Lovers",
artist: "Avicii feat. Simon Aldred",
album: "Single",
url: "./music/track/How Many Lovers.mp3",
cover_art_url: "./music/cover/How Many Lovers.jpg",
},
{
name: "I'll be Gone",
artist: "Avicii feat. Joakim Berg",
album: "Single",
url: "./music/track/I'll be Gone.mp3",
cover_art_url: "./music/cover/I'll be Gone.jpg",
},
{
name: "Unbreakable",
artist: "Avicii, BUNT feat. Sandro Cavazza & Clarece Coffee Jr",
album: "Single",
url: "./music/track/Unbreakable.mp3",
cover_art_url: "./music/cover/Unbreakable.jpg",
},
{
name: "Live Your Life",
artist: "Avicii, Afrojack, David Guetta, Ne-Yo",
album: "Single",
url: "./music/track/Live Your Life.mp3",
cover_art_url: "./music/cover/Live Your Life.jpg",
},
{
name: "Lord",
artist: "Avicii, Sandro Cavazza",
album: "Single",
url: "./music/track/Lord.mp3",
cover_art_url: "./music/cover/Lord.jpg",
},
{
name: "Make Your Move",
artist: "Avicii, Redroche, Dave Armstrong",
album: "Single",
url: "./music/track/Make Your Move.mp3",
cover_art_url: "./music/cover/Make Your Move.jpg",
},
{
name: "No Pleasing A Woman",
artist: "Avicii",
album: "Single",
url: "./music/track/No Pleasing A Woman.mp3",
cover_art_url: "./music/cover/No Pleasing A Woman.jpg",
},
{
name: "Our Love",
artist: "Avicii feat. Sandro Cavazza",
album: "Single",
url: "./music/track/Our Love.mp3",
cover_art_url: "./music/cover/Our Love.jpg",
},
{
name: "Revolver",
artist: "Avicii, Philter",
album: "Single",
url: "./music/track/Revolver.mp3",
cover_art_url: "./music/cover/Revolver.jpg",
},
{
name: "Rock Me",
artist: "Avicii, Mike Posner",
album: "Single",
url: "./music/track/Rock Me.mp3",
cover_art_url: "./music/cover/Rock Me.jpg",
},
{
name: "Silence",
artist: "Avicii",
album: "Single",
url: "./music/track/Silence.mp3",
cover_art_url: "./music/cover/Silence.jpg",
},
{
name: "Someone New",
artist: "Avicii, Triangle",
album: "Single",
url: "./music/track/Someone New.mp3",
cover_art_url: "./music/cover/Someone New.jpg",
},
{
name: "Somethings Got A Hold On Me vs Levels",
artist: "Avicii, Skrillex, Etta James",
album: "Single",
url: "./music/track/Somethings Got A Hold On Me vs Levels.mp3",
cover_art_url: "./music/cover/Somethings Got A Hold On Me vs Levels.jpg",
},
{
name: "Stepping Stone",
artist: "Avicii, AlexST",
album: "Single",
url: "./music/track/Stepping Stone.mp3",
cover_art_url: "./music/cover/Stepping Stone.jpg",
},
{
name: "Street Player",
artist: "Avicii, Chicago",
album: "Single",
url: "./music/track/Street Player.mp3",
cover_art_url: "./music/cover/Street Player.jpg",
},
{
name: "Sunshine vs Spectrum",
artist: "Avicii & David Guetta vs. Florence & Machine",
album: "Single",
url: "./music/track/Sunshine vs Spectrum.mp3",
cover_art_url: "./music/cover/Sunshine vs Spectrum.jpg",
},
{
name: "Take Me In Your Arms",
artist: "Avicii, The Isley Brothers",
album: "Single",
url: "./music/track/Take Me In Your Arms.mp3",
cover_art_url: "./music/cover/Take Me In Your Arms.jpg",
},
{
name: "T-Bone",
artist: "Avicii",
album: "Single",
url: "./music/track/T-Bone.mp3",
cover_art_url: "./music/cover/T-Bone.jpg",
},
{
name: "The Other Side",
artist: "Avicii feat. Cam",
album: "Single",
url: "./music/track/The Other Side.wav",
cover_art_url: "./music/cover/The Other Side.jpg",
},
{
name: "UMF 2013",
artist: "Avicii",
album: "Single",
url: "./music/track/UMF 2013.flac",
cover_art_url: "./music/cover/UMF 2013.jpg",
},
],
});
/*
Shows the playlist
*/
document
.getElementsByClassName("show-playlist")[0]
.addEventListener("click", function () {
document
.getElementById("white-player-playlist-container")
.classList.remove("slide-out-top");
document
.getElementById("white-player-playlist-container")
.classList.add("slide-in-top");
document.getElementById("white-player-playlist-container").style.display =
"block";
});
/*
Hides the playlist
*/
document
.getElementsByClassName("close-playlist")[0]
.addEventListener("click", function () {
document
.getElementById("white-player-playlist-container")
.classList.remove("slide-in-top");
document
.getElementById("white-player-playlist-container")
.classList.add("slide-out-top");
document.getElementById("white-player-playlist-container").style.display =
"none";
});