-
Notifications
You must be signed in to change notification settings - Fork 0
/
templates.html
112 lines (103 loc) · 2.08 KB
/
templates.html
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
<head>
<meta name="viewport" content="width=device-width,initial-scale=1">
<script src="https://connect.soundcloud.com/sdk/sdk-3.0.0.js"></script>
<title>Collaborative Playlist</title>
</head>
<template name="rooms">
<div class="rooms">
<ul>
{{#each this}}
{{> roomsItem}}
{{/each}}
</ul>
<input placeholder="Room Name" />
<button>Create Room</button>
</div>
</template>
<template name="roomsItem">
<li>{{name}}</li>
</template>
<template name="room">
<div class="room">
{{> search}}
{{> results}}
{{> playlist}}
{{> player}}
</div>
</template>
<template name="playlist">
<div class="playlist">
<ul>
{{#each songs}}
{{> playlistItem}}
{{/each}}
</ul>
</div>
</template>
<template name="playlistItem">
<li class="{{selected}}">
<div class="title" onclick>{{title}}</div>
<div class="actions">
<div class="play" onclick>
<i class="fa fa-play"></i>
</div>
<div class="up" onclick>
<i class="fa fa-arrow-up"></i>
</div>
<div class="down" onclick>
<i class="fa fa-arrow-down"></i>
</div>
<div class="remove" onclick>
<i class="fa fa-remove"></i>
</div>
</div>
</li>
</template>
<template name="search">
<div class="search">
<input placeholder="Search for songz" value="{{query}}" />
</div>
</template>
<template name="results">
{{#if query}}
<div class="results">
<ul>
{{#each results}}
{{> result}}
{{/each}}
</ul>
</div>
{{/if}}
</template>
<template name="result">
<div class="result">
<li>
{{title}}
</li>
</div>
</template>
<template name="player">
<div class="player">
<div class="play-pause" onclick>
{{#if playing}}
<i class="fa fa-pause"></i>
{{else}}
<i class="fa fa-play"></i>
{{/if}}
</div>
<div class="title">
{{#if currentSong}}
{{currentSong.title}}
{{else}}
(Nothing Playing)
{{/if}}
</div>
<div class="host">
{{#if hosting}}
<i class="fa fa-volume-up"></i>
{{else}}
<i class="fa fa-volume-off"></i>
{{/if}}
</div>
</div>
</template>