Station.vue 23 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823
  1. <template>
  2. <official-header v-if='type == "official"'></official-header>
  3. <community-header v-if='type == "community"'></community-header>
  4. <song-queue v-if='modals.addSongToQueue'></song-queue>
  5. <edit-playlist v-if='modals.editPlaylist'></edit-playlist>
  6. <create-playlist v-if='modals.createPlaylist'></create-playlist>
  7. <edit-station v-if='modals.editStation'></edit-station>
  8. <report v-if='modals.report'></report>
  9. <queue-sidebar v-if='sidebars.queue'></queue-sidebar>
  10. <playlist-sidebar v-if='sidebars.playlist'></playlist-sidebar>
  11. <users-sidebar v-if='sidebars.users'></users-sidebar>
  12. <div class="station">
  13. <div v-show="noSong" class="no-song">
  14. <h1>No song is currently playing</h1>
  15. <h4 v-if='type === "community" && station.partyMode'>
  16. <a href='#' class='no-song' @click='sidebars.queue = true'>Add a Song to the Queue</a>
  17. </h4>
  18. <h4 v-if='type === "community" && !station.partyMode && $parent.userId === station.owner && !station.privatePlaylist'>
  19. <a href='#' class='no-song' @click='sidebars.playlist = true'>Play a private playlist</a>
  20. </h4>
  21. <h1 v-if='type === "community" && !station.partyMode && $parent.userId === station.owner && station.privatePlaylist'>Maybe you can add some songs to your selected private playlist</h1>
  22. </div>
  23. <div class="columns is-mobile" v-show="!noSong">
  24. <div class="column is-8-desktop is-offset-2-desktop is-12-mobile">
  25. <div class="video-container">
  26. <div id="player"></div>
  27. <div class="seeker-bar-container white" id="preview-progress">
  28. <div class="seeker-bar light-blue" style="width: 0%;"></div>
  29. </div>
  30. </div>
  31. </div>
  32. </div>
  33. <div class="columns is-mobile" v-show="!noSong">
  34. <div class="column is-8-desktop is-offset-2-desktop is-12-mobile">
  35. <div class="columns is-mobile">
  36. <div class="column is-12-mobile" v-bind:class="{'is-8-desktop': !simpleSong}">
  37. <h4 id="time-display">{{timeElapsed}} / {{formatTime(currentSong.duration)}}</h4>
  38. <h3>{{currentSong.title}}</h3>
  39. <h4 class="thin" style="margin-left: 0">{{currentSong.artists}}</h4>
  40. <div class="columns is-mobile">
  41. <form style="margin-top: 12px; margin-bottom: 0;" action="#" class="column is-7-desktop is-4-mobile">
  42. <p style="margin-top: 0; position: relative; display: flex;">
  43. <i class="material-icons">volume_down</i>
  44. <input type="range" id="volumeSlider" min="0" max="100" class="active" v-on:change="changeVolume()" v-on:input="changeVolume()">
  45. <i class="material-icons">volume_up</i>
  46. </p>
  47. </form>
  48. <div class="column is-8-mobile is-5-desktop" style="float: right;">
  49. <ul id="ratings" v-if="currentSong.likes !== -1 && currentSong.dislikes !== -1">
  50. <li id="like" class="right" @click="toggleLike()">
  51. <span class="flow-text">{{currentSong.likes}} </span>
  52. <i id="thumbs_up" class="material-icons grey-text" v-bind:class="{ liked: liked }">thumb_up</i>
  53. <a class='absolute-a behind' @click="toggleLike()" href='#'></a>
  54. </li>
  55. <li style="margin-right: 10px;" id="dislike" class="right" @click="toggleDislike()">
  56. <span class="flow-text">{{currentSong.dislikes}} </span>
  57. <i id="thumbs_down" class="material-icons grey-text" v-bind:class="{ disliked: disliked }">thumb_down</i>
  58. <a class='absolute-a behind' @click="toggleDislike()" href='#'></a>
  59. </li>
  60. </ul>
  61. </div>
  62. </div>
  63. </div>
  64. <div class="column is-4-desktop" v-if="!simpleSong">
  65. <img class="image" id="song-thumbnail" style="margin-top: 10px !important" :src="currentSong.thumbnail" alt="Song Thumbnail" onerror="this.src='/assets/notes-transparent.png'" />
  66. </div>
  67. </div>
  68. </div>
  69. </div>
  70. </div>
  71. </template>
  72. <script>
  73. import { Toast } from 'vue-roaster';
  74. import SongQueue from '../Modals/AddSongToQueue.vue';
  75. import EditPlaylist from '../Modals/Playlists/Edit.vue';
  76. import CreatePlaylist from '../Modals/Playlists/Create.vue';
  77. import EditStation from '../Modals/EditStation.vue';
  78. import Report from '../Modals/Report.vue';
  79. import QueueSidebar from '../Sidebars/Queue.vue';
  80. import PlaylistSidebar from '../Sidebars/Playlist.vue';
  81. import UsersSidebar from '../Sidebars/UsersList.vue';
  82. import OfficialHeader from './OfficialHeader.vue';
  83. import CommunityHeader from './CommunityHeader.vue';
  84. import io from '../../io';
  85. export default {
  86. data() {
  87. return {
  88. type: '',
  89. playerReady: false,
  90. previousSong: null,
  91. currentSong: {},
  92. player: undefined,
  93. timePaused: 0,
  94. paused: false,
  95. timeElapsed: '0:00',
  96. liked: false,
  97. disliked: false,
  98. modals: {
  99. addSongToQueue: false,
  100. editPlaylist: false,
  101. createPlaylist: false,
  102. editStation: false,
  103. report: false
  104. },
  105. sidebars: {
  106. queue: false,
  107. users: false,
  108. playlist: false
  109. },
  110. noSong: false,
  111. simpleSong: false,
  112. queue: [],
  113. timeBeforePause: 0,
  114. station: {},
  115. skipVotes: 0,
  116. privatePlaylistQueueSelected: null,
  117. automaticallyRequestedSongId: null
  118. }
  119. },
  120. methods: {
  121. editPlaylist: function (id) {
  122. this.playlistBeingEdited = id;
  123. this.toggleModal('editPlaylist');
  124. },
  125. toggleModal: function (type) {
  126. if (type == 'addSongToQueue') this.modals.addSongToQueue = !this.modals.addSongToQueue;
  127. else if (type == 'editPlaylist') this.modals.editPlaylist = !this.modals.editPlaylist;
  128. else if (type == 'createPlaylist') this.modals.createPlaylist = !this.modals.createPlaylist;
  129. else if (type == 'editStation') this.modals.editStation = !this.modals.editStation;
  130. else if (type == 'report') this.modals.report = !this.modals.report;
  131. },
  132. youtubeReady: function() {
  133. let local = this;
  134. if (!local.player) {
  135. local.player = new YT.Player("player", {
  136. height: 270,
  137. width: 480,
  138. videoId: local.currentSong._id,
  139. startSeconds: local.getTimeElapsed() / 1000 + local.currentSong.skipDuration,
  140. playerVars: {controls: 0, iv_load_policy: 3, rel: 0, showinfo: 0},
  141. events: {
  142. 'onReady': function (event) {
  143. local.playerReady = true;
  144. let volume = parseInt(localStorage.getItem("volume"));
  145. volume = (typeof volume === "number") ? volume : 20;
  146. local.player.setVolume(volume);
  147. if (volume > 0) local.player.unMute();
  148. local.playVideo();
  149. },
  150. 'onStateChange': function (event) {
  151. if (event.data === 1 && local.videoLoading === true) {
  152. local.videoLoading = false;
  153. local.player.seekTo(local.getTimeElapsed() / 1000 + local.currentSong.skipDuration, true);
  154. if (local.paused) local.player.pauseVideo();
  155. } else if (event.data === 1 && local.paused) {
  156. local.player.seekTo(local.timeBeforePause / 1000, true);
  157. local.player.pauseVideo();
  158. }
  159. if (event.data === 2 && !local.paused && !local.noSong) {
  160. local.player.seekTo(local.getTimeElapsed() / 1000 + local.currentSong.skipDuration, true);
  161. local.player.playVideo();
  162. }
  163. }
  164. }
  165. });
  166. }
  167. },
  168. getTimeElapsed: function() {
  169. let local = this;
  170. if (local.currentSong) return Date.now() - local.startedAt - local.timePaused;
  171. else return 0;
  172. },
  173. playVideo: function() {
  174. let local = this;
  175. if (local.playerReady) {
  176. local.videoLoading = true;
  177. local.player.loadVideoById(local.currentSong._id, local.getTimeElapsed() / 1000 + local.currentSong.skipDuration);
  178. if (local.currentSong.artists) local.currentSong.artists = local.currentSong.artists.join(", ");
  179. if (window.stationInterval !== 0) clearInterval(window.stationInterval);
  180. window.stationInterval = setInterval(function () {
  181. local.resizeSeekerbar();
  182. local.calculateTimeElapsed();
  183. }, 250);
  184. }
  185. },
  186. resizeSeekerbar: function() {
  187. let local = this;
  188. if (!local.paused) {
  189. $(".seeker-bar").width(parseInt(((local.getTimeElapsed() / 1000) / local.currentSong.duration * 100)) + "%");
  190. }
  191. },
  192. formatTime: function(duration) {
  193. let d = moment.duration(duration, 'seconds');
  194. return ((d.hours() > 0) ? (d.hours() < 10 ? ("0" + d.hours() + ":") : (d.hours() + ":")) : "") + (d.minutes() + ":") + (d.seconds() < 10 ? ("0" + d.seconds()) : d.seconds());
  195. },
  196. calculateTimeElapsed: function() {
  197. let local = this;
  198. let currentTime = Date.now();
  199. if (local.currentTime !== undefined && local.paused) {
  200. local.timePaused += (Date.now() - local.currentTime);
  201. local.currentTime = undefined;
  202. }
  203. let duration = (Date.now() - local.startedAt - local.timePaused) / 1000;
  204. let songDuration = local.currentSong.duration;
  205. if (songDuration <= duration) local.player.pauseVideo();
  206. if ((!local.paused) && duration <= songDuration) local.timeElapsed = local.formatTime(duration);
  207. },
  208. changeVolume: function() {
  209. let local = this;
  210. let volume = $("#volumeSlider").val();
  211. localStorage.setItem("volume", volume);
  212. if (local.playerReady) {
  213. local.player.setVolume(volume);
  214. if (volume > 0) local.player.unMute();
  215. }
  216. },
  217. resumeLocalStation: function() {
  218. this.paused = false;
  219. if (!this.noSong) {
  220. if (this.playerReady) {
  221. this.player.seekTo(this.getTimeElapsed() / 1000 + this.currentSong.skipDuration);
  222. this.player.playVideo();
  223. }
  224. }
  225. },
  226. pauseLocalStation: function() {
  227. this.paused = true;
  228. if (!this.noSong) {
  229. this.timeBeforePause = this.getTimeElapsed();
  230. if (this.playerReady) this.player.pauseVideo();
  231. }
  232. },
  233. skipStation: function () {
  234. let _this = this;
  235. _this.socket.emit('stations.forceSkip', _this.stationId, data => {
  236. if (data.status !== 'success') Toast.methods.addToast(`Error: ${data.message}`, 8000);
  237. else Toast.methods.addToast('Successfully skipped the station\'s current song.', 4000);
  238. });
  239. },
  240. voteSkipStation: function () {
  241. let _this = this;
  242. _this.socket.emit('stations.voteSkip', _this.stationId, data => {
  243. if (data.status !== 'success') Toast.methods.addToast(`Error: ${data.message}`, 8000);
  244. else Toast.methods.addToast('Successfully voted to skip the current song.', 4000);
  245. });
  246. },
  247. resumeStation: function () {
  248. let _this = this;
  249. _this.socket.emit('stations.resume', _this.stationId, data => {
  250. if (data.status !== 'success') Toast.methods.addToast(`Error: ${data.message}`, 8000);
  251. else Toast.methods.addToast('Successfully resumed the station.', 4000);
  252. });
  253. },
  254. pauseStation: function () {
  255. let _this = this;
  256. _this.socket.emit('stations.pause', _this.stationId, data => {
  257. if (data.status !== 'success') Toast.methods.addToast(`Error: ${data.message}`, 8000);
  258. else Toast.methods.addToast('Successfully paused the station.', 4000);
  259. });
  260. },
  261. toggleLike: function() {
  262. let _this = this;
  263. if (_this.liked) _this.socket.emit('songs.unlike', _this.currentSong._id, data => {
  264. if (data.status !== 'success') Toast.methods.addToast(`Error: ${data.message}`, 8000);
  265. }); else _this.socket.emit('songs.like', _this.currentSong._id, data => {
  266. if (data.status !== 'success') Toast.methods.addToast(`Error: ${data.message}`, 8000);
  267. });
  268. },
  269. toggleDislike: function() {
  270. let _this = this;
  271. if (_this.disliked) return _this.socket.emit('songs.undislike', _this.currentSong._id, data => {
  272. if (data.status !== 'success') Toast.methods.addToast(`Error: ${data.message}`, 8000);
  273. });
  274. _this.socket.emit('songs.dislike', _this.currentSong._id, data => {
  275. if (data.status !== 'success') Toast.methods.addToast(`Error: ${data.message}`, 8000);
  276. });
  277. },
  278. addFirstPrivatePlaylistSongToQueue: function() {
  279. let _this = this;
  280. let isInQueue = false;
  281. let userId = _this.$parent.userId;
  282. _this.queue.forEach((queueSong) => {
  283. if (queueSong.requestedBy === userId) isInQueue = true;
  284. });
  285. if (!isInQueue && _this.privatePlaylistQueueSelected) {
  286. _this.socket.emit('playlists.getFirstSong', _this.privatePlaylistQueueSelected, data => {
  287. if (data.status === 'success') {
  288. let songId = data.song._id;
  289. _this.automaticallyRequestedSongId = songId;
  290. _this.socket.emit('stations.addToQueue', _this.stationId, songId, data => {
  291. if (data.status === 'success') {
  292. _this.socket.emit('playlists.moveSongToBottom', _this.privatePlaylistQueueSelected, songId, data => {
  293. if (data.status === 'success') {
  294. console.log("Added first song to queue!");
  295. }
  296. });
  297. }
  298. });
  299. }
  300. });
  301. }
  302. },
  303. joinStation: function () {
  304. let _this = this;
  305. _this.socket.emit('stations.join', _this.stationId, res => {
  306. if (res.status === 'success') {
  307. _this.station = {
  308. displayName: res.data.displayName,
  309. description: res.data.description,
  310. privacy: res.data.privacy,
  311. partyMode: res.data.partyMode,
  312. owner: res.data.owner,
  313. privatePlaylist: res.data.privatePlaylist
  314. };
  315. _this.currentSong = (res.data.currentSong) ? res.data.currentSong : {};
  316. _this.type = res.data.type;
  317. _this.startedAt = res.data.startedAt;
  318. _this.paused = res.data.paused;
  319. _this.timePaused = res.data.timePaused;
  320. if (res.data.currentSong) {
  321. _this.noSong = false;
  322. _this.simpleSong = (res.data.currentSong.likes === -1 && res.data.currentSong.dislikes === -1);
  323. if (_this.simpleSong) {
  324. _this.currentSong.skipDuration = 0;
  325. }
  326. _this.youtubeReady();
  327. _this.playVideo();
  328. _this.socket.emit('songs.getOwnSongRatings', res.data.currentSong._id, data => {
  329. if (_this.currentSong._id === data.songId) {
  330. _this.liked = data.liked;
  331. _this.disliked = data.disliked;
  332. }
  333. });
  334. } else {
  335. if (_this.playerReady) _this.player.pauseVideo();
  336. _this.noSong = true;
  337. }
  338. if (_this.type === 'community') {
  339. _this.socket.emit('stations.getQueue', _this.stationId, data => {
  340. if (data.status === 'success') _this.queue = data.queue;
  341. });
  342. }
  343. }
  344. });
  345. }
  346. },
  347. ready: function() {
  348. let _this = this;
  349. _this.stationId = _this.$route.params.id;
  350. window.stationInterval = 0;
  351. io.getSocket((socket) => {
  352. _this.socket = socket;
  353. io.removeAllListeners();
  354. if (_this.socket.connected) _this.joinStation();
  355. io.onConnect(() => {
  356. _this.joinStation();
  357. });
  358. _this.socket.emit('stations.find', _this.stationId, res => {
  359. if (res.status === 'error') {
  360. _this.$router.go('/404');
  361. Toast.methods.addToast(res.message, 3000);
  362. }
  363. });
  364. _this.socket.on('event:songs.next', data => {
  365. _this.previousSong = (_this.currentSong._id) ? _this.currentSong : null;
  366. _this.currentSong = (data.currentSong) ? data.currentSong : {};
  367. _this.startedAt = data.startedAt;
  368. _this.paused = data.paused;
  369. _this.timePaused = data.timePaused;
  370. if (data.currentSong) {
  371. _this.noSong = false;
  372. _this.simpleSong = (data.currentSong.likes === -1 && data.currentSong.dislikes === -1);
  373. if (_this.simpleSong) _this.currentSong.skipDuration = 0;
  374. if (!_this.playerReady) _this.youtubeReady();
  375. else _this.playVideo();
  376. _this.socket.emit('songs.getOwnSongRatings', data.currentSong._id, (data) => {
  377. if (_this.currentSong._id === data.songId) {
  378. _this.liked = data.liked;
  379. _this.disliked = data.disliked;
  380. }
  381. });
  382. } else {
  383. if (_this.playerReady) _this.player.pauseVideo();
  384. _this.noSong = true;
  385. }
  386. let isInQueue = false;
  387. let userId = _this.$parent.userId;
  388. _this.queue.forEach((queueSong) => {
  389. if (queueSong.requestedBy === userId) isInQueue = true;
  390. });
  391. if (!isInQueue && _this.privatePlaylistQueueSelected && (_this.automaticallyRequestedSongId !== _this.currentSong._id || !_this.currentSong._id)) {
  392. _this.addFirstPrivatePlaylistSongToQueue();
  393. }
  394. });
  395. _this.socket.on('event:stations.pause', data => {
  396. _this.pauseLocalStation();
  397. });
  398. _this.socket.on('event:stations.resume', data => {
  399. _this.timePaused = data.timePaused;
  400. _this.resumeLocalStation();
  401. });
  402. _this.socket.on('event:song.like', data => {
  403. if (!this.noSong) {
  404. if (data.songId === _this.currentSong._id) {
  405. _this.currentSong.likes++;
  406. if (data.undisliked) _this.currentSong.dislikes--;
  407. }
  408. }
  409. });
  410. _this.socket.on('event:song.dislike', data => {
  411. if (!this.noSong) {
  412. if (data.songId === _this.currentSong._id) {
  413. _this.currentSong.dislikes++;
  414. if (data.unliked) _this.currentSong.likes--;
  415. }
  416. }
  417. });
  418. _this.socket.on('event:song.unlike', data => {
  419. if (!this.noSong) {
  420. if (data.songId === _this.currentSong._id) _this.currentSong.likes--;
  421. }
  422. });
  423. _this.socket.on('event:song.undislike', data => {
  424. if (!this.noSong) {
  425. if (data.songId === _this.currentSong._id) _this.currentSong.dislikes--;
  426. }
  427. });
  428. _this.socket.on('event:song.newRatings', data => {
  429. if (!this.noSong) {
  430. if (data.songId === _this.currentSong._id) {
  431. _this.liked = data.liked;
  432. _this.disliked = data.disliked;
  433. }
  434. }
  435. });
  436. _this.socket.on('event:queue.update', queue => {
  437. if (this.type === 'community') this.queue = queue;
  438. });
  439. _this.socket.on('event:song.voteSkipSong', () => {
  440. if (this.currentSong) this.currentSong.skipVotes++;
  441. });
  442. _this.socket.on('event:privatePlaylist.selected', (playlistId) => {
  443. if (this.type === 'community') {
  444. this.station.privatePlaylist = playlistId;
  445. }
  446. });
  447. _this.socket.on('event:partyMode.updated', (partyMode) => {
  448. if (this.type === 'community') {
  449. this.station.partyMode = partyMode;
  450. }
  451. });
  452. });
  453. let volume = parseInt(localStorage.getItem("volume"));
  454. volume = (typeof volume === "number") ? volume : 20;
  455. localStorage.setItem("volume", volume);
  456. $("#volumeSlider").val(volume);
  457. },
  458. components: {
  459. OfficialHeader,
  460. CommunityHeader,
  461. SongQueue,
  462. EditPlaylist,
  463. CreatePlaylist,
  464. EditStation,
  465. Report,
  466. QueueSidebar,
  467. PlaylistSidebar,
  468. UsersSidebar
  469. }
  470. }
  471. </script>
  472. <style lang="scss">
  473. .no-song {
  474. color: #03A9F4;
  475. text-align: center;
  476. }
  477. #volumeSlider {
  478. padding: 0 15px;
  479. background: transparent;
  480. }
  481. .stationDisplayName {
  482. color: white !important;
  483. }
  484. .slideout {
  485. top: 50px;
  486. height: 100%;
  487. position: fixed;
  488. right: 0;
  489. width: 350px;
  490. background-color: white;
  491. box-shadow: 0 2px 5px 0 rgba(0, 0, 0, 0.16), 0 2px 10px 0 rgba(0, 0, 0, 0.12);
  492. .slideout-header {
  493. text-align: center;
  494. background-color: rgb(3, 169, 244) !important;
  495. margin: 0;
  496. padding-top: 5px;
  497. padding-bottom: 7px;
  498. color: white;
  499. }
  500. .slideout-content {
  501. height: 100%;
  502. }
  503. }
  504. .modal-large {
  505. width: 75%;
  506. }
  507. .station {
  508. flex: 1 0 auto;
  509. padding-top: 0.5vw;
  510. transition: all 0.1s;
  511. margin: 0 auto;
  512. max-width: 1280px;
  513. width: 90%;
  514. @media only screen and (min-width: 993px) {
  515. width: 70%;
  516. }
  517. @media only screen and (min-width: 601px) {
  518. width: 85%;
  519. }
  520. input[type=range] {
  521. -webkit-appearance: none;
  522. width: 100%;
  523. margin: 7.3px 0;
  524. }
  525. input[type=range]:focus {
  526. outline: none;
  527. }
  528. input[type=range]::-webkit-slider-runnable-track {
  529. width: 100%;
  530. height: 5.2px;
  531. cursor: pointer;
  532. box-shadow: 0;
  533. background: #c2c0c2;
  534. border-radius: 0;
  535. border: 0;
  536. }
  537. input[type=range]::-webkit-slider-thumb {
  538. box-shadow: 0;
  539. border: 0;
  540. height: 19px;
  541. width: 19px;
  542. border-radius: 15px;
  543. background: #03a9f4;
  544. cursor: pointer;
  545. -webkit-appearance: none;
  546. margin-top: -6.5px;
  547. }
  548. input[type=range]::-moz-range-track {
  549. width: 100%;
  550. height: 5.2px;
  551. cursor: pointer;
  552. box-shadow: 0;
  553. background: #c2c0c2;
  554. border-radius: 0;
  555. border: 0;
  556. }
  557. input[type=range]::-moz-range-thumb {
  558. box-shadow: 0;
  559. border: 0;
  560. height: 19px;
  561. width: 19px;
  562. border-radius: 15px;
  563. background: #03a9f4;
  564. cursor: pointer;
  565. -webkit-appearance: none;
  566. margin-top: -6.5px;
  567. }
  568. input[type=range]::-ms-track {
  569. width: 100%;
  570. height: 5.2px;
  571. cursor: pointer;
  572. box-shadow: 0;
  573. background: #c2c0c2;
  574. border-radius: 1.3px;
  575. }
  576. input[type=range]::-ms-fill-lower {
  577. background: #c2c0c2;
  578. border: 0;
  579. border-radius: 0;
  580. box-shadow: 0;
  581. }
  582. input[type=range]::-ms-fill-upper {
  583. background: #c2c0c2;
  584. border: 0;
  585. border-radius: 0;
  586. box-shadow: 0;
  587. }
  588. input[type=range]::-ms-thumb {
  589. box-shadow: 0;
  590. border: 0;
  591. height: 15px;
  592. width: 15px;
  593. border-radius: 15px;
  594. background: #03a9f4;
  595. cursor: pointer;
  596. -webkit-appearance: none;
  597. margin-top: 1.5px;
  598. }
  599. .video-container {
  600. position: relative;
  601. padding-bottom: 56.25%;
  602. height: 0;
  603. overflow: hidden;
  604. iframe {
  605. position: absolute;
  606. top: 0;
  607. left: 0;
  608. width: 100%;
  609. height: 100%;
  610. }
  611. }
  612. .video-col {
  613. padding-right: 0.75rem;
  614. padding-left: 0.75rem;
  615. }
  616. }
  617. .room-title {
  618. left: 50%;
  619. -webkit-transform: translateX(-50%);
  620. transform: translateX(-50%);
  621. font-size: 2.1em;
  622. }
  623. #ratings {
  624. span {
  625. font-size: 1.68rem;
  626. }
  627. i {
  628. color: #9e9e9e !important;
  629. cursor: pointer;
  630. transition: 0.1s color;
  631. }
  632. }
  633. #time-display {
  634. margin-top: 30px;
  635. float: right;
  636. }
  637. #thumbs_up:hover, #thumbs_up.liked {
  638. color: #87D37C !important;
  639. }
  640. #thumbs_down:hover, #thumbs_down.disliked {
  641. color: #EC644B !important;
  642. }
  643. #song-thumbnail {
  644. max-width: 100%;
  645. width: 85%;
  646. }
  647. .seeker-bar-container {
  648. position: relative;
  649. height: 5px;
  650. display: block;
  651. width: 100%;
  652. overflow: hidden;
  653. }
  654. .seeker-bar {
  655. top: 0;
  656. left: 0;
  657. bottom: 0;
  658. position: absolute;
  659. }
  660. ul {
  661. list-style: none;
  662. margin: 0;
  663. display: block;
  664. }
  665. h1, h2, h3, h4, h5, h6 {
  666. font-weight: 400;
  667. line-height: 1.1;
  668. }
  669. h1 a, h2 a, h3 a, h4 a, h5 a, h6 a {
  670. font-weight: inherit;
  671. }
  672. h1 {
  673. font-size: 4.2rem;
  674. line-height: 110%;
  675. margin: 2.1rem 0 1.68rem 0;
  676. }
  677. h2 {
  678. font-size: 3.56rem;
  679. line-height: 110%;
  680. margin: 1.78rem 0 1.424rem 0;
  681. }
  682. h3 {
  683. font-size: 2.92rem;
  684. line-height: 110%;
  685. margin: 1.46rem 0 1.168rem 0;
  686. }
  687. h4 {
  688. font-size: 2.28rem;
  689. line-height: 110%;
  690. margin: 1.14rem 0 0.912rem 0;
  691. }
  692. h5 {
  693. font-size: 1.64rem;
  694. line-height: 110%;
  695. margin: 0.82rem 0 0.656rem 0;
  696. }
  697. h6 {
  698. font-size: 1rem;
  699. line-height: 110%;
  700. margin: 0.5rem 0 0.4rem 0;
  701. }
  702. .thin {
  703. font-weight: 200;
  704. }
  705. .left {
  706. float: left !important;
  707. }
  708. .right {
  709. float: right !important;
  710. }
  711. .light-blue {
  712. background-color: #03a9f4 !important;
  713. }
  714. .white {
  715. background-color: #FFFFFF !important;
  716. }
  717. .btn-search {
  718. font-size: 14px;
  719. }
  720. .menu { padding: 0 10px; }
  721. .menu-list li a:hover { color: #000 !important; }
  722. .menu-list li {
  723. display: flex;
  724. justify-content: space-between;
  725. }
  726. .menu-list a {
  727. padding: 0 10px !important;
  728. }
  729. .icons-group { display: flex; }
  730. #like, #dislike {
  731. position: relative;
  732. }
  733. .behind {
  734. z-index: -1;
  735. }
  736. .behind:focus {
  737. z-index: 0;
  738. }
  739. </style>