EditSong.vue 20 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855
  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. <hr />
  187. <h5 class="has-text-centered">Spotify Information</h5>
  188. <label class="label">Song title</label>
  189. <p class="control">
  190. <input class="input" type="text" v-model="spotify.title" />
  191. </p>
  192. <label class="label">Song artist (1 artist full name)</label>
  193. <p class="control">
  194. <input class="input" type="text" v-model="spotify.artist" />
  195. </p>
  196. <button
  197. class="button is-success"
  198. v-on:click="getSpotifySongs()"
  199. >
  200. Get Spotify songs
  201. </button>
  202. <hr />
  203. <article
  204. class="media"
  205. v-for="(song, index) in spotify.songs"
  206. :key="index"
  207. >
  208. <figure class="media-left">
  209. <p class="image is-64x64">
  210. <img
  211. :src="song.thumbnail"
  212. onerror="this.src='/assets/notes-transparent.png'"
  213. />
  214. </p>
  215. </figure>
  216. <div class="media-content">
  217. <div class="content">
  218. <p>
  219. <strong>{{ song.title }}</strong>
  220. <br />
  221. <small>Artists: {{ song.artists }}</small
  222. >, <small>Duration: {{ song.duration }}</small
  223. >,
  224. <small>Explicit: {{ song.explicit }}</small>
  225. <br />
  226. <small>Thumbnail: {{ song.thumbnail }}</small>
  227. </p>
  228. </div>
  229. </div>
  230. </article>
  231. </div>
  232. <div slot="footer">
  233. <button
  234. class="button is-success"
  235. v-on:click="save(editing.song, false)"
  236. >
  237. <i class="material-icons save-changes">done</i>
  238. <span>&nbsp;Save</span>
  239. </button>
  240. <button
  241. class="button is-success"
  242. v-on:click="save(editing.song, true)"
  243. >
  244. <i class="material-icons save-changes">done</i>
  245. <span>&nbsp;Save and close</span>
  246. </button>
  247. <button
  248. class="button is-danger"
  249. v-on:click="
  250. closeModal({ sector: 'admin', modal: 'editSong' })
  251. "
  252. >
  253. <span>&nbsp;Close</span>
  254. </button>
  255. </div>
  256. </modal>
  257. </div>
  258. </template>
  259. <script>
  260. import { mapState, mapActions } from "vuex";
  261. import { Toast } from "vue-roaster";
  262. import io from "../../io";
  263. import validation from "../../validation";
  264. import Modal from "./Modal.vue";
  265. export default {
  266. components: { Modal },
  267. data() {
  268. return {
  269. spotify: {
  270. title: "",
  271. artist: "",
  272. songs: []
  273. },
  274. youtubeVideoDuration: 0.0,
  275. youtubeVideoCurrentTime: 0.0,
  276. youtubeVideoNote: "",
  277. useHTTPS: false
  278. };
  279. },
  280. computed: {
  281. ...mapState("admin/songs", {
  282. video: state => state.video,
  283. editing: state => state.editing
  284. }),
  285. ...mapState("modals", {
  286. modals: state => state.modals.admin
  287. })
  288. },
  289. methods: {
  290. save(song, close) {
  291. const _this = this;
  292. if (!song.title)
  293. return Toast.methods.addToast(
  294. "Please fill in all fields",
  295. 8000
  296. );
  297. if (!song.thumbnail)
  298. return Toast.methods.addToast(
  299. "Please fill in all fields",
  300. 8000
  301. );
  302. // Duration
  303. if (
  304. Number(song.skipDuration) + Number(song.duration) >
  305. this.youtubeVideoDuration
  306. ) {
  307. return Toast.methods.addToast(
  308. "Duration can't be higher than the length of the video",
  309. 8000
  310. );
  311. }
  312. // Title
  313. if (!validation.isLength(song.title, 1, 100))
  314. return Toast.methods.addToast(
  315. "Title must have between 1 and 100 characters.",
  316. 8000
  317. );
  318. /* if (!validation.regex.ascii.test(song.title))
  319. return Toast.methods.addToast(
  320. "Invalid title format. Only ascii characters are allowed.",
  321. 8000
  322. ); */
  323. // Artists
  324. if (song.artists.length < 1 || song.artists.length > 10)
  325. return Toast.methods.addToast(
  326. "Invalid artists. You must have at least 1 artist and a maximum of 10 artists.",
  327. 8000
  328. );
  329. let error;
  330. song.artists.forEach(artist => {
  331. if (!validation.isLength(artist, 1, 32)) {
  332. error = "Artist must have between 1 and 32 characters.";
  333. return error;
  334. }
  335. if (!validation.regex.ascii.test(artist)) {
  336. error =
  337. "Invalid artist format. Only ascii characters are allowed.";
  338. return error;
  339. }
  340. if (artist === "NONE") {
  341. error =
  342. 'Invalid artist format. Artists are not allowed to be named "NONE".';
  343. return error;
  344. }
  345. return false;
  346. });
  347. if (error) return Toast.methods.addToast(error, 8000);
  348. // Genres
  349. error = undefined;
  350. song.genres.forEach(genre => {
  351. if (!validation.isLength(genre, 1, 16)) {
  352. error = "Genre must have between 1 and 16 characters.";
  353. return error;
  354. }
  355. if (!validation.regex.az09_.test(genre)) {
  356. error =
  357. "Invalid genre format. Only ascii characters are allowed.";
  358. return error;
  359. }
  360. return false;
  361. });
  362. if (error) return Toast.methods.addToast(error, 8000);
  363. // Thumbnail
  364. if (!validation.isLength(song.thumbnail, 8, 256))
  365. return Toast.methods.addToast(
  366. "Thumbnail must have between 8 and 256 characters.",
  367. 8000
  368. );
  369. if (this.useHTTPS && song.thumbnail.indexOf("https://") !== 0) {
  370. return Toast.methods.addToast(
  371. 'Thumbnail must start with "https://".',
  372. 8000
  373. );
  374. }
  375. if (!this.useHTTPS && song.thumbnail.indexOf("http://") !== 0) {
  376. return Toast.methods.addToast(
  377. 'Thumbnail must start with "http://".',
  378. 8000
  379. );
  380. }
  381. return this.socket.emit(
  382. `${_this.editing.type}.update`,
  383. song._id,
  384. song,
  385. res => {
  386. Toast.methods.addToast(res.message, 4000);
  387. if (res.status === "success") {
  388. _this.$parent.songs.forEach(originalSong => {
  389. const updatedSong = song;
  390. if (originalSong._id === updatedSong._id) {
  391. Object.keys(originalSong).forEach(n => {
  392. updatedSong[n] = originalSong[n];
  393. return originalSong[n];
  394. });
  395. }
  396. });
  397. }
  398. if (close)
  399. _this.closeModal({
  400. sector: "admin",
  401. modal: "editSong"
  402. });
  403. }
  404. );
  405. },
  406. settings(type) {
  407. const _this = this;
  408. switch (type) {
  409. default:
  410. break;
  411. case "stop":
  412. _this.stopVideo();
  413. _this.pauseVideo(true);
  414. break;
  415. case "pause":
  416. _this.pauseVideo(true);
  417. break;
  418. case "play":
  419. _this.pauseVideo(false);
  420. break;
  421. case "skipToLast10Secs":
  422. _this.video.player.seekTo(
  423. _this.editing.song.duration -
  424. 10 +
  425. _this.editing.song.skipDuration
  426. );
  427. break;
  428. }
  429. },
  430. changeVolume() {
  431. const local = this;
  432. const volume = document.getElementById("volumeSlider").value;
  433. localStorage.setItem("volume", volume);
  434. local.video.player.setVolume(volume);
  435. if (volume > 0) local.video.player.unMute();
  436. },
  437. addTag(type) {
  438. if (type === "genres") {
  439. const genre = document
  440. .getElementById("new-genre")
  441. .value.toLowerCase()
  442. .trim();
  443. if (this.editing.song.genres.indexOf(genre) !== -1)
  444. return Toast.methods.addToast("Genre already exists", 3000);
  445. if (genre) {
  446. this.editing.song.genres.push(genre);
  447. document.getElementById("new-genre").value = "";
  448. return false;
  449. }
  450. return Toast.methods.addToast("Genre cannot be empty", 3000);
  451. }
  452. if (type === "artists") {
  453. const artist = document.getElementById("new-artist").value;
  454. if (this.editing.song.artists.indexOf(artist) !== -1)
  455. return Toast.methods.addToast(
  456. "Artist already exists",
  457. 3000
  458. );
  459. if (document.getElementById("new-artist").value !== "") {
  460. this.editing.song.artists.push(artist);
  461. document.getElementById("new-artist").value = "";
  462. return false;
  463. }
  464. return Toast.methods.addToast("Artist cannot be empty", 3000);
  465. }
  466. return false;
  467. },
  468. removeTag(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() {
  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() {
  496. const canvasElement = document.getElementById("durationCanvas");
  497. const 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() {
  516. const canvasElement = document.getElementById("durationCanvas");
  517. const 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. const widthSkipDuration = (skipDuration / videoDuration) * width;
  525. const widthDuration = (duration / videoDuration) * width;
  526. const widthAfterDuration = (afterDuration / videoDuration) * width;
  527. const 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", ["closeModal"])
  554. },
  555. mounted() {
  556. const _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. });
  569. setInterval(() => {
  570. if (
  571. _this.video.paused === false &&
  572. _this.playerReady &&
  573. _this.video.player.getCurrentTime() -
  574. _this.editing.song.skipDuration >
  575. _this.editing.song.duration
  576. ) {
  577. _this.video.paused = false;
  578. _this.video.player.stopVideo();
  579. }
  580. if (this.playerReady) {
  581. _this.getCurrentTime(3).then(time => {
  582. this.youtubeVideoCurrentTime = time;
  583. return time;
  584. });
  585. }
  586. if (_this.video.paused === false) _this.drawCanvas();
  587. }, 200);
  588. this.video.player = new window.YT.Player("player", {
  589. height: 315,
  590. width: 560,
  591. videoId: this.editing.song.songId,
  592. playerVars: {
  593. controls: 0,
  594. iv_load_policy: 3,
  595. rel: 0,
  596. showinfo: 0,
  597. autoplay: 1
  598. },
  599. startSeconds: _this.editing.song.skipDuration,
  600. events: {
  601. onReady: () => {
  602. let volume = parseInt(localStorage.getItem("volume"));
  603. volume = typeof volume === "number" ? volume : 20;
  604. console.log(`Seekto: ${_this.editing.song.skipDuration}`);
  605. _this.video.player.seekTo(_this.editing.song.skipDuration);
  606. _this.video.player.setVolume(volume);
  607. if (volume > 0) _this.video.player.unMute();
  608. this.youtubeVideoDuration = _this.video.player.getDuration();
  609. this.youtubeVideoNote = "(~)";
  610. _this.playerReady = true;
  611. _this.drawCanvas();
  612. },
  613. onStateChange: event => {
  614. if (event.data === 1) {
  615. if (!_this.video.autoPlayed) {
  616. _this.video.autoPlayed = true;
  617. return _this.video.player.stopVideo();
  618. }
  619. _this.video.paused = false;
  620. let youtubeDuration = _this.video.player.getDuration();
  621. this.youtubeVideoDuration = youtubeDuration;
  622. this.youtubeVideoNote = "";
  623. youtubeDuration -= _this.editing.song.skipDuration;
  624. if (_this.editing.song.duration > youtubeDuration + 1) {
  625. this.video.player.stopVideo();
  626. _this.video.paused = true;
  627. return Toast.methods.addToast(
  628. "Video can't play. Specified duration is bigger than the YouTube song duration.",
  629. 4000
  630. );
  631. }
  632. if (_this.editing.song.duration <= 0) {
  633. this.video.player.stopVideo();
  634. _this.video.paused = true;
  635. return Toast.methods.addToast(
  636. "Video can't play. Specified duration has to be more than 0 seconds.",
  637. 4000
  638. );
  639. }
  640. if (
  641. _this.video.player.getCurrentTime() <
  642. _this.editing.song.skipDuration
  643. ) {
  644. return _this.video.player.seekTo(
  645. _this.editing.song.skipDuration
  646. );
  647. }
  648. } else if (event.data === 2) {
  649. this.video.paused = true;
  650. }
  651. return false;
  652. }
  653. }
  654. });
  655. let volume = parseInt(localStorage.getItem("volume"));
  656. document.getElementById("volumeSlider").value = volume =
  657. typeof volume === "number" ? volume : 20;
  658. }
  659. };
  660. </script>
  661. <style lang="scss" scoped>
  662. input[type="range"] {
  663. -webkit-appearance: none;
  664. width: 100%;
  665. margin: 7.3px 0;
  666. }
  667. input[type="range"]:focus {
  668. outline: none;
  669. }
  670. input[type="range"]::-webkit-slider-runnable-track {
  671. width: 100%;
  672. height: 5.2px;
  673. cursor: pointer;
  674. box-shadow: 0;
  675. background: #c2c0c2;
  676. border-radius: 0;
  677. border: 0;
  678. }
  679. input[type="range"]::-webkit-slider-thumb {
  680. box-shadow: 0;
  681. border: 0;
  682. height: 19px;
  683. width: 19px;
  684. border-radius: 15px;
  685. background: #03a9f4;
  686. cursor: pointer;
  687. -webkit-appearance: none;
  688. margin-top: -6.5px;
  689. }
  690. input[type="range"]::-moz-range-track {
  691. width: 100%;
  692. height: 5.2px;
  693. cursor: pointer;
  694. box-shadow: 0;
  695. background: #c2c0c2;
  696. border-radius: 0;
  697. border: 0;
  698. }
  699. input[type="range"]::-moz-range-thumb {
  700. box-shadow: 0;
  701. border: 0;
  702. height: 19px;
  703. width: 19px;
  704. border-radius: 15px;
  705. background: #03a9f4;
  706. cursor: pointer;
  707. -webkit-appearance: none;
  708. margin-top: -6.5px;
  709. }
  710. input[type="range"]::-ms-track {
  711. width: 100%;
  712. height: 5.2px;
  713. cursor: pointer;
  714. box-shadow: 0;
  715. background: #c2c0c2;
  716. border-radius: 1.3px;
  717. }
  718. input[type="range"]::-ms-fill-lower {
  719. background: #c2c0c2;
  720. border: 0;
  721. border-radius: 0;
  722. box-shadow: 0;
  723. }
  724. input[type="range"]::-ms-fill-upper {
  725. background: #c2c0c2;
  726. border: 0;
  727. border-radius: 0;
  728. box-shadow: 0;
  729. }
  730. input[type="range"]::-ms-thumb {
  731. box-shadow: 0;
  732. border: 0;
  733. height: 15px;
  734. width: 15px;
  735. border-radius: 15px;
  736. background: #03a9f4;
  737. cursor: pointer;
  738. -webkit-appearance: none;
  739. margin-top: 1.5px;
  740. }
  741. .controls {
  742. display: flex;
  743. flex-direction: column;
  744. align-items: center;
  745. }
  746. .artist-genres {
  747. display: flex;
  748. justify-content: space-between;
  749. }
  750. #volumeSlider {
  751. margin-bottom: 15px;
  752. }
  753. .has-text-centered {
  754. padding: 10px;
  755. }
  756. .thumbnail-preview {
  757. display: flex;
  758. margin: 0 auto 25px auto;
  759. max-width: 200px;
  760. width: 100%;
  761. }
  762. .modal-card-body,
  763. .modal-card-foot {
  764. border-top: 0;
  765. }
  766. .label,
  767. .checkbox,
  768. h5 {
  769. font-weight: normal;
  770. }
  771. .video-container {
  772. display: flex;
  773. flex-direction: column;
  774. align-items: center;
  775. padding: 10px;
  776. iframe {
  777. pointer-events: none;
  778. }
  779. }
  780. .save-changes {
  781. color: #fff;
  782. }
  783. .tag:not(:last-child) {
  784. margin-right: 5px;
  785. }
  786. </style>