EditSong.vue 20 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868
  1. <template>
  2. <div>
  3. <modal title="Edit Song">
  4. <div slot="body">
  5. <h5 class="has-text-centered">Video Preview</h5>
  6. <div class="video-container">
  7. <div id="player"></div>
  8. <canvas
  9. id="durationCanvas"
  10. height="40"
  11. width="560"
  12. ></canvas>
  13. <div class="controls">
  14. <form action="#">
  15. <p style="margin-top: 0; position: relative;">
  16. <input
  17. type="range"
  18. id="volumeSlider"
  19. min="0"
  20. max="100"
  21. class="active"
  22. v-on:change="changeVolume()"
  23. v-on:input="changeVolume()"
  24. />
  25. </p>
  26. </form>
  27. <p class="control has-addons">
  28. <button
  29. class="button"
  30. v-on:click="settings('pause')"
  31. v-if="!video.paused"
  32. >
  33. <i class="material-icons">pause</i>
  34. </button>
  35. <button
  36. class="button"
  37. v-on:click="settings('play')"
  38. v-if="video.paused"
  39. >
  40. <i class="material-icons">play_arrow</i>
  41. </button>
  42. <button
  43. class="button"
  44. v-on:click="settings('stop')"
  45. >
  46. <i class="material-icons">stop</i>
  47. </button>
  48. <button
  49. class="button"
  50. v-on:click="settings('skipToLast10Secs')"
  51. >
  52. <i class="material-icons">fast_forward</i>
  53. </button>
  54. </p>
  55. <p>
  56. YouTube:
  57. <span>{{ youtubeVideoCurrentTime }}</span> /
  58. <span>{{ youtubeVideoDuration }}</span>
  59. {{ youtubeVideoNote }}
  60. </p>
  61. </div>
  62. </div>
  63. <h5 class="has-text-centered">Thumbnail Preview</h5>
  64. <img
  65. class="thumbnail-preview"
  66. :src="editing.song.thumbnail"
  67. onerror="this.src='/assets/notes-transparent.png'"
  68. />
  69. <div class="control is-horizontal">
  70. <div class="control-label">
  71. <label class="label">Thumbnail URL</label>
  72. </div>
  73. <div class="control">
  74. <input
  75. class="input"
  76. type="text"
  77. v-model="editing.song.thumbnail"
  78. />
  79. </div>
  80. </div>
  81. <h5 class="has-text-centered">Edit Information</h5>
  82. <p class="control">
  83. <label class="checkbox">
  84. <input
  85. type="checkbox"
  86. v-model="editing.song.explicit"
  87. />
  88. Explicit
  89. </label>
  90. </p>
  91. <label class="label">Song ID & Title</label>
  92. <div class="control is-horizontal">
  93. <div class="control is-grouped">
  94. <p class="control is-expanded">
  95. <input
  96. class="input"
  97. type="text"
  98. v-model="editing.song.songId"
  99. />
  100. </p>
  101. <p class="control is-expanded">
  102. <input
  103. class="input"
  104. type="text"
  105. v-model="editing.song.title"
  106. autofocus
  107. />
  108. </p>
  109. </div>
  110. </div>
  111. <label class="label">Artists & Genres</label>
  112. <div class="control is-horizontal">
  113. <div class="control is-grouped artist-genres">
  114. <div>
  115. <p class="control has-addons">
  116. <input
  117. class="input"
  118. id="new-artist"
  119. type="text"
  120. placeholder="Artist"
  121. />
  122. <button
  123. class="button is-info"
  124. v-on:click="addTag('artists')"
  125. >
  126. Add Artist
  127. </button>
  128. </p>
  129. <span
  130. class="tag is-info"
  131. v-for="(artist, index) in editing.song.artists"
  132. :key="index"
  133. >
  134. {{ artist }}
  135. <button
  136. class="delete is-info"
  137. v-on:click="removeTag('artists', index)"
  138. ></button>
  139. </span>
  140. </div>
  141. <div>
  142. <p class="control has-addons">
  143. <input
  144. class="input"
  145. id="new-genre"
  146. type="text"
  147. placeholder="Genre"
  148. />
  149. <button
  150. class="button is-info"
  151. v-on:click="addTag('genres')"
  152. >
  153. Add Genre
  154. </button>
  155. </p>
  156. <span
  157. class="tag is-info"
  158. v-for="(genre, index) in editing.song.genres"
  159. :key="index"
  160. >
  161. {{ genre }}
  162. <button
  163. class="delete is-info"
  164. v-on:click="removeTag('genres', index)"
  165. ></button>
  166. </span>
  167. </div>
  168. </div>
  169. </div>
  170. <label class="label">Song Duration</label>
  171. <p class="control">
  172. <input
  173. class="input"
  174. type="text"
  175. v-model="editing.song.duration"
  176. />
  177. </p>
  178. <label class="label">Skip Duration</label>
  179. <p class="control">
  180. <input
  181. class="input"
  182. type="text"
  183. v-model="editing.song.skipDuration"
  184. />
  185. </p>
  186. <article class="message" v-if="editing.type === 'songs'">
  187. <div class="message-body">
  188. <span class="reports-length">
  189. {{ reports.length }}
  190. <span
  191. v-if="reports.length > 1 || reports.length <= 0"
  192. >&nbsp;Reports</span
  193. >
  194. <span v-else>&nbsp;Report</span>
  195. </span>
  196. <div v-for="(report, index) in reports" :key="index">
  197. <router-link
  198. :to="{
  199. path: '/admin/reports',
  200. query: { id: report, returnToSong: true }
  201. }"
  202. class="report-link"
  203. >
  204. Report - {{ report }}
  205. </router-link>
  206. </div>
  207. </div>
  208. </article>
  209. <hr />
  210. <h5 class="has-text-centered">Spotify Information</h5>
  211. <label class="label">Song title</label>
  212. <p class="control">
  213. <input class="input" type="text" v-model="spotify.title" />
  214. </p>
  215. <label class="label">Song artist (1 artist full name)</label>
  216. <p class="control">
  217. <input class="input" type="text" v-model="spotify.artist" />
  218. </p>
  219. <button
  220. class="button is-success"
  221. v-on:click="getSpotifySongs()"
  222. >
  223. Get Spotify songs
  224. </button>
  225. <hr />
  226. <article
  227. class="media"
  228. v-for="(song, index) in spotify.songs"
  229. :key="index"
  230. >
  231. <figure class="media-left">
  232. <p class="image is-64x64">
  233. <img
  234. :src="song.thumbnail"
  235. onerror="this.src='/assets/notes-transparent.png'"
  236. />
  237. </p>
  238. </figure>
  239. <div class="media-content">
  240. <div class="content">
  241. <p>
  242. <strong>{{ song.title }}</strong>
  243. <br />
  244. <small>Artists: {{ song.artists }}</small
  245. >, <small>Duration: {{ song.duration }}</small
  246. >,
  247. <small>Explicit: {{ song.explicit }}</small>
  248. <br />
  249. <small>Thumbnail: {{ song.thumbnail }}</small>
  250. </p>
  251. </div>
  252. </div>
  253. </article>
  254. </div>
  255. <div slot="footer">
  256. <button
  257. class="button is-success"
  258. v-on:click="save(editing.song, false)"
  259. >
  260. <i class="material-icons save-changes">done</i>
  261. <span>&nbsp;Save</span>
  262. </button>
  263. <button
  264. class="button is-success"
  265. v-on:click="save(editing.song, true)"
  266. >
  267. <i class="material-icons save-changes">done</i>
  268. <span>&nbsp;Save and close</span>
  269. </button>
  270. <button
  271. class="button is-danger"
  272. v-on:click="
  273. toggleModal({ sector: 'admin', modal: 'editSong' })
  274. "
  275. >
  276. <span>&nbsp;Close</span>
  277. </button>
  278. </div>
  279. </modal>
  280. </div>
  281. </template>
  282. <script>
  283. import { mapState, mapActions } from "vuex";
  284. import io from "../../io";
  285. import validation from "../../validation";
  286. import { Toast } from "vue-roaster";
  287. import Modal from "./Modal.vue";
  288. export default {
  289. components: { Modal },
  290. data() {
  291. return {
  292. reports: 0,
  293. spotify: {
  294. title: "",
  295. artist: "",
  296. songs: []
  297. },
  298. youtubeVideoDuration: 0.0,
  299. youtubeVideoCurrentTime: 0.0,
  300. youtubeVideoNote: "",
  301. useHTTPS: false
  302. };
  303. },
  304. computed: {
  305. ...mapState("admin/songs", {
  306. video: state => state.video,
  307. editing: state => state.editing
  308. }),
  309. ...mapState("modals", {
  310. modals: state => state.modals.admin
  311. })
  312. },
  313. methods: {
  314. save: function(song, close) {
  315. let _this = this;
  316. if (!song.title)
  317. return Toast.methods.addToast(
  318. "Please fill in all fields",
  319. 8000
  320. );
  321. if (!song.thumbnail)
  322. return Toast.methods.addToast(
  323. "Please fill in all fields",
  324. 8000
  325. );
  326. // Duration
  327. if (
  328. Number(song.skipDuration) + Number(song.duration) >
  329. this.youtubeVideoDuration
  330. ) {
  331. return Toast.methods.addToast(
  332. "Duration can't be higher than the length of the video",
  333. 8000
  334. );
  335. }
  336. // Title
  337. if (!validation.isLength(song.title, 1, 100))
  338. return Toast.methods.addToast(
  339. "Title must have between 1 and 100 characters.",
  340. 8000
  341. );
  342. /*if (!validation.regex.ascii.test(song.title))
  343. return Toast.methods.addToast(
  344. "Invalid title format. Only ascii characters are allowed.",
  345. 8000
  346. );*/
  347. // Artists
  348. if (song.artists.length < 1 || song.artists.length > 10)
  349. return Toast.methods.addToast(
  350. "Invalid artists. You must have at least 1 artist and a maximum of 10 artists.",
  351. 8000
  352. );
  353. let error;
  354. song.artists.forEach(artist => {
  355. if (!validation.isLength(artist, 1, 32))
  356. return (error =
  357. "Artist must have between 1 and 32 characters.");
  358. if (!validation.regex.ascii.test(artist))
  359. return (error =
  360. "Invalid artist format. Only ascii characters are allowed.");
  361. if (artist === "NONE")
  362. return (error =
  363. 'Invalid artist format. Artists are not allowed to be named "NONE".');
  364. });
  365. if (error) return Toast.methods.addToast(error, 8000);
  366. // Genres
  367. error = undefined;
  368. song.genres.forEach(genre => {
  369. if (!validation.isLength(genre, 1, 16))
  370. return (error =
  371. "Genre must have between 1 and 16 characters.");
  372. if (!validation.regex.az09_.test(genre))
  373. return (error =
  374. "Invalid genre format. Only ascii characters are allowed.");
  375. });
  376. if (error) return Toast.methods.addToast(error, 8000);
  377. // Thumbnail
  378. if (!validation.isLength(song.thumbnail, 8, 256))
  379. return Toast.methods.addToast(
  380. "Thumbnail must have between 8 and 256 characters.",
  381. 8000
  382. );
  383. if (this.useHTTPS && song.thumbnail.indexOf("https://") !== 0) {
  384. return Toast.methods.addToast(
  385. 'Thumbnail must start with "https://".',
  386. 8000
  387. );
  388. }
  389. if (!this.useHTTPS && song.thumbnail.indexOf("http://") !== 0) {
  390. return Toast.methods.addToast(
  391. 'Thumbnail must start with "http://".',
  392. 8000
  393. );
  394. }
  395. this.socket.emit(
  396. `${_this.editing.type}.update`,
  397. song._id,
  398. song,
  399. res => {
  400. Toast.methods.addToast(res.message, 4000);
  401. if (res.status === "success") {
  402. _this.$parent.songs.forEach(lSong => {
  403. if (song._id === lSong._id) {
  404. for (let n in song) {
  405. lSong[n] = song[n];
  406. }
  407. }
  408. });
  409. }
  410. if (close) _this.closeCurrentModal();
  411. }
  412. );
  413. },
  414. settings: function(type) {
  415. let _this = this;
  416. switch (type) {
  417. case "stop":
  418. _this.stopVideo();
  419. _this.pauseVideo(true);
  420. break;
  421. case "pause":
  422. _this.pauseVideo(true);
  423. break;
  424. case "play":
  425. _this.pauseVideo(false);
  426. break;
  427. case "skipToLast10Secs":
  428. _this.video.player.seekTo(
  429. _this.editing.song.duration -
  430. 10 +
  431. _this.editing.song.skipDuration
  432. );
  433. break;
  434. }
  435. },
  436. changeVolume: function() {
  437. let local = this;
  438. let volume = document.getElementById("volumeSlider").value;
  439. localStorage.setItem("volume", volume);
  440. local.video.player.setVolume(volume);
  441. if (volume > 0) local.video.player.unMute();
  442. },
  443. addTag: function(type) {
  444. if (type == "genres") {
  445. let genre = document
  446. .getElementById("new-genre")
  447. .value.toLowerCase()
  448. .trim();
  449. if (this.editing.song.genres.indexOf(genre) !== -1)
  450. return Toast.methods.addToast("Genre already exists", 3000);
  451. if (genre) {
  452. this.editing.song.genres.push(genre);
  453. document.getElementById("new-genre").value = "";
  454. } else Toast.methods.addToast("Genre cannot be empty", 3000);
  455. } else if (type == "artists") {
  456. let artist = document.getElementById("new-artist").value;
  457. if (this.editing.song.artists.indexOf(artist) !== -1)
  458. return Toast.methods.addToast(
  459. "Artist already exists",
  460. 3000
  461. );
  462. if (document.getElementById("new-artist").value !== "") {
  463. this.editing.song.artists.push(artist);
  464. document.getElementById("new-artist").value = "";
  465. } else Toast.methods.addToast("Artist cannot be empty", 3000);
  466. }
  467. },
  468. removeTag: function(type, index) {
  469. if (type == "genres") this.editing.song.genres.splice(index, 1);
  470. else if (type == "artists")
  471. this.editing.song.artists.splice(index, 1);
  472. },
  473. getSpotifySongs: function() {
  474. this.socket.emit(
  475. "apis.getSpotifySongs",
  476. this.spotify.title,
  477. this.spotify.artist,
  478. res => {
  479. if (res.status === "success") {
  480. Toast.methods.addToast(
  481. `Succesfully got ${res.songs.length} song${
  482. res.songs.length !== 1 ? "s" : ""
  483. }.`,
  484. 3000
  485. );
  486. this.spotify.songs = res.songs;
  487. } else
  488. Toast.methods.addToast(
  489. `Failed to get songs. ${res.message}`,
  490. 3000
  491. );
  492. }
  493. );
  494. },
  495. initCanvas: function() {
  496. let canvasElement = document.getElementById("durationCanvas");
  497. let ctx = canvasElement.getContext("2d");
  498. const skipDurationColor = "#ef4a1c";
  499. const durationColor = "#1dc146";
  500. const afterDurationColor = "#ef731a";
  501. ctx.font = "16px Arial";
  502. ctx.fillStyle = skipDurationColor;
  503. ctx.fillRect(0, 25, 20, 15);
  504. ctx.fillStyle = "#000000";
  505. ctx.fillText("Skip duration", 25, 38);
  506. ctx.fillStyle = durationColor;
  507. ctx.fillRect(130, 25, 20, 15);
  508. ctx.fillStyle = "#000000";
  509. ctx.fillText("Duration", 155, 38);
  510. ctx.fillStyle = afterDurationColor;
  511. ctx.fillRect(230, 25, 20, 15);
  512. ctx.fillStyle = "#000000";
  513. ctx.fillText("After duration", 255, 38);
  514. },
  515. drawCanvas: function() {
  516. let canvasElement = document.getElementById("durationCanvas");
  517. let ctx = canvasElement.getContext("2d");
  518. const videoDuration = Number(this.youtubeVideoDuration);
  519. const skipDuration = Number(this.editing.song.skipDuration);
  520. const duration = Number(this.editing.song.duration);
  521. const afterDuration = videoDuration - (skipDuration + duration);
  522. const width = 560;
  523. const currentTime = this.video.player.getCurrentTime();
  524. let widthSkipDuration = (skipDuration / videoDuration) * width;
  525. let widthDuration = (duration / videoDuration) * width;
  526. let widthAfterDuration = (afterDuration / videoDuration) * width;
  527. let widthCurrentTime = (currentTime / videoDuration) * width;
  528. const skipDurationColor = "#ef4a1c";
  529. const durationColor = "#1dc146";
  530. const afterDurationColor = "#ef731a";
  531. const currentDurationColor = "#3b25e8";
  532. ctx.fillStyle = skipDurationColor;
  533. ctx.fillRect(0, 0, widthSkipDuration, 20);
  534. ctx.fillStyle = durationColor;
  535. ctx.fillRect(widthSkipDuration, 0, widthDuration, 20);
  536. ctx.fillStyle = afterDurationColor;
  537. ctx.fillRect(
  538. widthSkipDuration + widthDuration,
  539. 0,
  540. widthAfterDuration,
  541. 20
  542. );
  543. ctx.fillStyle = currentDurationColor;
  544. ctx.fillRect(widthCurrentTime, 0, 1, 20);
  545. },
  546. ...mapActions("admin/songs", [
  547. "stopVideo",
  548. "loadVideoById",
  549. "pauseVideo",
  550. "getCurrentTime",
  551. "editSong"
  552. ]),
  553. ...mapActions("modals", ["toggleModal", "closeCurrentModal"])
  554. },
  555. mounted: function() {
  556. let _this = this;
  557. // if (this.modals.editSong = false) this.video.player.stopVideo();
  558. // this.loadVideoById(
  559. // this.editing.song.songId,
  560. // this.editing.song.skipDuration
  561. // );
  562. this.initCanvas();
  563. lofig.get("cookie.secure", res => {
  564. _this.useHTTPS = res;
  565. });
  566. io.getSocket(socket => {
  567. this.socket = socket;
  568. if (this.editing.type === "songs") {
  569. socket.emit(
  570. "reports.getReportsForSong",
  571. this.editing.song.songId,
  572. res => {
  573. this.reports = res.data;
  574. }
  575. );
  576. }
  577. });
  578. setInterval(() => {
  579. if (
  580. _this.video.paused === false &&
  581. _this.playerReady &&
  582. _this.video.player.getCurrentTime() -
  583. _this.editing.song.skipDuration >
  584. _this.editing.song.duration
  585. ) {
  586. _this.video.paused = false;
  587. _this.video.player.stopVideo();
  588. }
  589. if (this.playerReady) {
  590. _this
  591. .getCurrentTime(3)
  592. .then(time => (this.youtubeVideoCurrentTime = time));
  593. }
  594. if (_this.video.paused === false) _this.drawCanvas();
  595. }, 200);
  596. this.video.player = new window.YT.Player("player", {
  597. height: 315,
  598. width: 560,
  599. videoId: this.editing.song.songId,
  600. playerVars: {
  601. controls: 0,
  602. iv_load_policy: 3,
  603. rel: 0,
  604. showinfo: 0,
  605. autoplay: 1
  606. },
  607. startSeconds: _this.editing.song.skipDuration,
  608. events: {
  609. onReady: () => {
  610. let volume = parseInt(localStorage.getItem("volume"));
  611. volume = typeof volume === "number" ? volume : 20;
  612. console.log("Seekto: " + _this.editing.song.skipDuration);
  613. _this.video.player.seekTo(_this.editing.song.skipDuration);
  614. _this.video.player.setVolume(volume);
  615. if (volume > 0) _this.video.player.unMute();
  616. this.youtubeVideoDuration = _this.video.player.getDuration();
  617. this.youtubeVideoNote = "(~)";
  618. _this.playerReady = true;
  619. _this.drawCanvas();
  620. },
  621. onStateChange: event => {
  622. if (event.data === 1) {
  623. if (!_this.video.autoPlayed) {
  624. _this.video.autoPlayed = true;
  625. return _this.video.player.stopVideo();
  626. }
  627. _this.video.paused = false;
  628. let youtubeDuration = _this.video.player.getDuration();
  629. this.youtubeVideoDuration = youtubeDuration;
  630. this.youtubeVideoNote = "";
  631. youtubeDuration -= _this.editing.song.skipDuration;
  632. if (_this.editing.song.duration > youtubeDuration + 1) {
  633. this.video.player.stopVideo();
  634. _this.video.paused = true;
  635. Toast.methods.addToast(
  636. "Video can't play. Specified duration is bigger than the YouTube song duration.",
  637. 4000
  638. );
  639. } else if (_this.editing.song.duration <= 0) {
  640. this.video.player.stopVideo();
  641. _this.video.paused = true;
  642. Toast.methods.addToast(
  643. "Video can't play. Specified duration has to be more than 0 seconds.",
  644. 4000
  645. );
  646. }
  647. if (
  648. _this.video.player.getCurrentTime() <
  649. _this.editing.song.skipDuration
  650. ) {
  651. _this.video.player.seekTo(
  652. _this.editing.song.skipDuration
  653. );
  654. }
  655. } else if (event.data === 2) {
  656. this.video.paused = true;
  657. }
  658. }
  659. }
  660. });
  661. let volume = parseInt(localStorage.getItem("volume"));
  662. document.getElementById("volumeSlider").value = volume =
  663. typeof volume === "number" ? volume : 20;
  664. }
  665. };
  666. </script>
  667. <style lang="scss" scoped>
  668. input[type="range"] {
  669. -webkit-appearance: none;
  670. width: 100%;
  671. margin: 7.3px 0;
  672. }
  673. input[type="range"]:focus {
  674. outline: none;
  675. }
  676. input[type="range"]::-webkit-slider-runnable-track {
  677. width: 100%;
  678. height: 5.2px;
  679. cursor: pointer;
  680. box-shadow: 0;
  681. background: #c2c0c2;
  682. border-radius: 0;
  683. border: 0;
  684. }
  685. input[type="range"]::-webkit-slider-thumb {
  686. box-shadow: 0;
  687. border: 0;
  688. height: 19px;
  689. width: 19px;
  690. border-radius: 15px;
  691. background: #03a9f4;
  692. cursor: pointer;
  693. -webkit-appearance: none;
  694. margin-top: -6.5px;
  695. }
  696. input[type="range"]::-moz-range-track {
  697. width: 100%;
  698. height: 5.2px;
  699. cursor: pointer;
  700. box-shadow: 0;
  701. background: #c2c0c2;
  702. border-radius: 0;
  703. border: 0;
  704. }
  705. input[type="range"]::-moz-range-thumb {
  706. box-shadow: 0;
  707. border: 0;
  708. height: 19px;
  709. width: 19px;
  710. border-radius: 15px;
  711. background: #03a9f4;
  712. cursor: pointer;
  713. -webkit-appearance: none;
  714. margin-top: -6.5px;
  715. }
  716. input[type="range"]::-ms-track {
  717. width: 100%;
  718. height: 5.2px;
  719. cursor: pointer;
  720. box-shadow: 0;
  721. background: #c2c0c2;
  722. border-radius: 1.3px;
  723. }
  724. input[type="range"]::-ms-fill-lower {
  725. background: #c2c0c2;
  726. border: 0;
  727. border-radius: 0;
  728. box-shadow: 0;
  729. }
  730. input[type="range"]::-ms-fill-upper {
  731. background: #c2c0c2;
  732. border: 0;
  733. border-radius: 0;
  734. box-shadow: 0;
  735. }
  736. input[type="range"]::-ms-thumb {
  737. box-shadow: 0;
  738. border: 0;
  739. height: 15px;
  740. width: 15px;
  741. border-radius: 15px;
  742. background: #03a9f4;
  743. cursor: pointer;
  744. -webkit-appearance: none;
  745. margin-top: 1.5px;
  746. }
  747. .controls {
  748. display: flex;
  749. flex-direction: column;
  750. align-items: center;
  751. }
  752. .artist-genres {
  753. display: flex;
  754. justify-content: space-between;
  755. }
  756. #volumeSlider {
  757. margin-bottom: 15px;
  758. }
  759. .has-text-centered {
  760. padding: 10px;
  761. }
  762. .thumbnail-preview {
  763. display: flex;
  764. margin: 0 auto 25px auto;
  765. max-width: 200px;
  766. width: 100%;
  767. }
  768. .modal-card-body,
  769. .modal-card-foot {
  770. border-top: 0;
  771. }
  772. .label,
  773. .checkbox,
  774. h5 {
  775. font-weight: normal;
  776. }
  777. .video-container {
  778. display: flex;
  779. flex-direction: column;
  780. align-items: center;
  781. padding: 10px;
  782. iframe {
  783. pointer-events: none;
  784. }
  785. }
  786. .save-changes {
  787. color: #fff;
  788. }
  789. .tag:not(:last-child) {
  790. margin-right: 5px;
  791. }
  792. .reports-length {
  793. color: #ff4545;
  794. font-weight: bold;
  795. display: flex;
  796. justify-content: center;
  797. }
  798. .report-link {
  799. color: #000;
  800. }
  801. </style>