App.vue 37 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113
  1. <script setup lang="ts">
  2. import { useRoute, useRouter } from "vue-router";
  3. import { defineAsyncComponent, ref, computed, watch, onMounted } from "vue";
  4. import Toast from "toasters";
  5. import { storeToRefs } from "pinia";
  6. import { useWebsocketsStore } from "@/stores/websockets";
  7. import { useUserAuthStore } from "@/stores/userAuth";
  8. import { useUserPreferencesStore } from "@/stores/userPreferences";
  9. import { useModalsStore } from "@/stores/modals";
  10. import ws from "@/ws";
  11. import aw from "@/aw";
  12. import keyboardShortcuts from "@/keyboardShortcuts";
  13. const ModalManager = defineAsyncComponent(
  14. () => import("@/components/ModalManager.vue")
  15. );
  16. const LongJobs = defineAsyncComponent(
  17. () => import("@/components/LongJobs.vue")
  18. );
  19. const BannedPage = defineAsyncComponent(() => import("@/pages/Banned.vue"));
  20. const FallingSnow = defineAsyncComponent(
  21. () => import("@/components/FallingSnow.vue")
  22. );
  23. const route = useRoute();
  24. const router = useRouter();
  25. const { socket } = useWebsocketsStore();
  26. const userAuthStore = useUserAuthStore();
  27. const userPreferencesStore = useUserPreferencesStore();
  28. const modalsStore = useModalsStore();
  29. const apiDomain = ref("");
  30. const socketConnected = ref(true);
  31. const keyIsDown = ref("");
  32. const scrollPosition = ref({ y: 0, x: 0 });
  33. const aModalIsOpen2 = ref(false);
  34. const broadcastChannel = ref();
  35. const christmas = ref(false);
  36. const disconnectedMessage = ref();
  37. const { loggedIn, banned } = storeToRefs(userAuthStore);
  38. const { nightmode, activityWatch } = storeToRefs(userPreferencesStore);
  39. const {
  40. changeNightmode,
  41. changeAutoSkipDisliked,
  42. changeActivityLogPublic,
  43. changeAnonymousSongRequests,
  44. changeActivityWatch
  45. } = userPreferencesStore;
  46. const { modals, activeModals } = storeToRefs(modalsStore);
  47. const { openModal, closeCurrentModal } = modalsStore;
  48. const aModalIsOpen = computed(() => Object.keys(activeModals.value).length > 0);
  49. const toggleNightMode = () => {
  50. localStorage.setItem("nightmode", `${!nightmode.value}`);
  51. if (loggedIn.value) {
  52. socket.dispatch(
  53. "users.updatePreferences",
  54. { nightmode: !nightmode.value },
  55. res => {
  56. if (res.status !== "success") new Toast(res.message);
  57. }
  58. );
  59. }
  60. changeNightmode(!nightmode.value);
  61. };
  62. const enableNightmode = () => {
  63. document.getElementsByTagName("html")[0].classList.add("night-mode");
  64. };
  65. const disableNightmode = () => {
  66. document.getElementsByTagName("html")[0].classList.remove("night-mode");
  67. };
  68. const enableChristmasMode = () => {
  69. document.getElementsByTagName("html")[0].classList.add("christmas-mode");
  70. };
  71. watch(socketConnected, connected => {
  72. if (!connected && !userAuthStore.banned) disconnectedMessage.value.show();
  73. else disconnectedMessage.value.hide();
  74. });
  75. watch(banned, () => {
  76. disconnectedMessage.value.hide();
  77. });
  78. watch(nightmode, enabled => {
  79. if (enabled) enableNightmode();
  80. else disableNightmode();
  81. });
  82. watch(activityWatch, enabled => {
  83. if (enabled) aw.enable();
  84. else aw.disable();
  85. });
  86. watch(aModalIsOpen, isOpen => {
  87. if (isOpen) {
  88. scrollPosition.value = {
  89. x: window.scrollX,
  90. y: window.scrollY
  91. };
  92. aModalIsOpen2.value = true;
  93. } else {
  94. aModalIsOpen2.value = false;
  95. setTimeout(() => {
  96. window.scrollTo(scrollPosition.value.x, scrollPosition.value.y);
  97. }, 10);
  98. }
  99. });
  100. onMounted(async () => {
  101. window
  102. .matchMedia("(prefers-color-scheme: dark)")
  103. .addEventListener("change", e => {
  104. if (e.matches === !nightmode.value) toggleNightMode();
  105. });
  106. if (!loggedIn.value) {
  107. lofig.get("cookie.SIDname").then(sid => {
  108. broadcastChannel.value = new BroadcastChannel(`${sid}.user_login`);
  109. broadcastChannel.value.onmessage = data => {
  110. if (data) {
  111. broadcastChannel.value.close();
  112. window.location.reload();
  113. }
  114. };
  115. });
  116. }
  117. document.onkeydown = (ev: any) => {
  118. const event = ev || window.event;
  119. const { keyCode } = event;
  120. const shift = event.shiftKey;
  121. const ctrl = event.ctrlKey;
  122. const alt = event.altKey;
  123. const identifier = `${keyCode}.${shift}.${ctrl}`;
  124. if (keyIsDown.value === identifier) return;
  125. keyIsDown.value = identifier;
  126. keyboardShortcuts.handleKeyDown(event, keyCode, shift, ctrl, alt);
  127. };
  128. document.onkeyup = () => {
  129. keyIsDown.value = "";
  130. };
  131. // ctrl + alt + n
  132. keyboardShortcuts.registerShortcut("nightmode", {
  133. keyCode: 78,
  134. ctrl: true,
  135. alt: true,
  136. handler: () => toggleNightMode()
  137. });
  138. keyboardShortcuts.registerShortcut("closeModal", {
  139. keyCode: 27,
  140. shift: false,
  141. ctrl: false,
  142. handler: () => {
  143. if (
  144. Object.keys(activeModals.value).length !== 0 &&
  145. modals.value[
  146. activeModals.value[activeModals.value.length - 1]
  147. ] !== "editSong" &&
  148. modals.value[
  149. activeModals.value[activeModals.value.length - 1]
  150. ] !== "editSongs"
  151. )
  152. closeCurrentModal();
  153. }
  154. });
  155. disconnectedMessage.value = new Toast({
  156. content: "Could not connect to the server.",
  157. persistent: true,
  158. interactable: false
  159. });
  160. disconnectedMessage.value.hide();
  161. ws.onConnect(() => {
  162. socketConnected.value = true;
  163. socket.dispatch("users.getPreferences", res => {
  164. if (res.status === "success") {
  165. const { preferences } = res.data;
  166. changeAutoSkipDisliked(preferences.autoSkipDisliked);
  167. changeNightmode(preferences.nightmode);
  168. changeActivityLogPublic(preferences.activityLogPublic);
  169. changeAnonymousSongRequests(preferences.anonymousSongRequests);
  170. changeActivityWatch(preferences.activityWatch);
  171. if (nightmode.value) enableNightmode();
  172. else disableNightmode();
  173. }
  174. });
  175. socket.on("keep.event:user.session.deleted", () =>
  176. window.location.reload()
  177. );
  178. const newUser = !localStorage.getItem("firstVisited");
  179. socket.dispatch("news.newest", newUser, res => {
  180. if (res.status !== "success") return;
  181. const { news } = res.data;
  182. if (news) {
  183. if (newUser) {
  184. openModal({ modal: "whatIsNew", data: { news } });
  185. } else if (localStorage.getItem("whatIsNew")) {
  186. if (
  187. parseInt(localStorage.getItem("whatIsNew")) <
  188. news.createdAt
  189. ) {
  190. openModal({
  191. modal: "whatIsNew",
  192. data: { news }
  193. });
  194. localStorage.setItem("whatIsNew", news.createdAt);
  195. }
  196. } else {
  197. if (
  198. parseInt(localStorage.getItem("firstVisited")) <
  199. news.createdAt
  200. )
  201. openModal({
  202. modal: "whatIsNew",
  203. data: { news }
  204. });
  205. localStorage.setItem("whatIsNew", news.createdAt);
  206. }
  207. }
  208. if (!localStorage.getItem("firstVisited"))
  209. localStorage.setItem("firstVisited", Date.now().toString());
  210. });
  211. });
  212. ws.onDisconnect(true, () => {
  213. socketConnected.value = false;
  214. });
  215. apiDomain.value = await lofig.get("backend.apiDomain");
  216. router.isReady().then(() => {
  217. if (route.query.err) {
  218. let { err } = route.query;
  219. err = JSON.stringify(err)
  220. .replace(/</g, "&lt;")
  221. .replace(/>/g, "&gt;");
  222. router.push({ query: {} });
  223. new Toast({ content: err, timeout: 20000 });
  224. }
  225. if (route.query.msg) {
  226. let { msg } = route.query;
  227. msg = JSON.stringify(msg)
  228. .replace(/</g, "&lt;")
  229. .replace(/>/g, "&gt;");
  230. router.push({ query: {} });
  231. new Toast({ content: msg, timeout: 20000 });
  232. }
  233. lofig.get("siteSettings.githubAuthentication").then(enabled => {
  234. if (enabled && localStorage.getItem("github_redirect")) {
  235. router.push(localStorage.getItem("github_redirect"));
  236. localStorage.removeItem("github_redirect");
  237. }
  238. });
  239. });
  240. if (localStorage.getItem("nightmode") === "true") {
  241. changeNightmode(true);
  242. enableNightmode();
  243. }
  244. lofig.get("siteSettings.christmas").then(enabled => {
  245. if (enabled) {
  246. christmas.value = true;
  247. enableChristmasMode();
  248. }
  249. });
  250. });
  251. </script>
  252. <template>
  253. <div class="upper-container">
  254. <banned-page v-if="banned" />
  255. <div v-else class="upper-container">
  256. <router-view
  257. :key="$route.fullPath"
  258. class="main-container"
  259. :class="{ 'main-container-modal-active': aModalIsOpen2 }"
  260. />
  261. </div>
  262. <falling-snow v-if="christmas" />
  263. <modal-manager />
  264. <long-jobs />
  265. </div>
  266. </template>
  267. <style lang="less">
  268. @import "normalize.css/normalize.css";
  269. @import "tippy.js/dist/tippy.css";
  270. @import "tippy.js/animations/scale.css";
  271. :root {
  272. --primary-color: var(--blue);
  273. --blue: rgb(2, 166, 242);
  274. --light-blue: rgb(163, 224, 255);
  275. --dark-blue: rgb(0, 102, 244);
  276. --teal: rgb(0, 209, 178);
  277. --purple: rgb(143, 40, 140);
  278. --light-purple: rgb(170, 141, 216);
  279. --yellow: rgb(241, 196, 15);
  280. --light-pink: rgb(228, 155, 166);
  281. --dark-pink: rgb(234, 72, 97);
  282. --orange: rgb(255, 94, 0);
  283. --dark-orange: rgb(250, 50, 0);
  284. --green: rgb(68, 189, 50);
  285. --red: rgb(231, 77, 60);
  286. --dark-red: rgb(235, 41, 19);
  287. --white: rgb(255, 255, 255);
  288. --black: rgb(0, 0, 0);
  289. --light-grey: rgb(245, 245, 245);
  290. --light-grey-2: rgb(221, 221, 221);
  291. --light-grey-3: rgb(195, 193, 195);
  292. --grey: rgb(107, 107, 107);
  293. --grey-2: rgb(113, 113, 113);
  294. --grey-3: rgb(126, 126, 126);
  295. --dark-grey: rgb(77, 77, 77);
  296. --dark-grey-2: rgb(51, 51, 51);
  297. --dark-grey-3: rgb(34, 34, 34);
  298. --dark-grey-4: rgb(26, 26, 26);
  299. --youtube: rgb(189, 46, 46);
  300. }
  301. .night-mode {
  302. body {
  303. background-color: var(--black) !important;
  304. }
  305. div {
  306. color: var(--light-grey-2);
  307. }
  308. .input,
  309. .textarea,
  310. .select select {
  311. background-color: var(--dark-grey);
  312. border-color: var(--grey-3);
  313. color: var(--white);
  314. &::placeholder {
  315. color: var(--light-grey-3);
  316. }
  317. }
  318. .control.has-addons .button {
  319. background-color: var(--dark-grey-2);
  320. border: 0;
  321. i {
  322. color: var(--white);
  323. }
  324. }
  325. h1,
  326. h2,
  327. h3,
  328. h4,
  329. h5,
  330. h6 {
  331. color: var(--white) !important;
  332. }
  333. p:not(.help),
  334. label,
  335. .label {
  336. color: var(--light-grey-2) !important;
  337. }
  338. .section,
  339. .content {
  340. background-color: var(--dark-grey-3) !important;
  341. }
  342. .content-box,
  343. .step:not(.selected) {
  344. background-color: var(--dark-grey-3) !important;
  345. }
  346. .tippy-box[data-theme~="songActions"] {
  347. background-color: var(--dark-grey);
  348. }
  349. code {
  350. background-color: var(--dark-grey-2) !important;
  351. }
  352. .button.is-dark {
  353. background-color: var(--light-grey) !important;
  354. color: var(--dark-grey-2) !important;
  355. }
  356. .checkbox input[type="checkbox"] {
  357. background-color: var(--dark-grey);
  358. border-color: transparent;
  359. &:checked:before,
  360. &:checked:after {
  361. background-color: var(--white);
  362. }
  363. }
  364. .pill {
  365. background-color: var(--dark-grey);
  366. color: var(--primary-color);
  367. }
  368. }
  369. .christmas-mode {
  370. --primary-color: var(--red);
  371. }
  372. /* inter-regular - latin */
  373. @font-face {
  374. font-family: "Inter";
  375. font-style: normal;
  376. font-weight: 400;
  377. src: url("/fonts/inter-v3-latin-regular.eot"); /* IE9 Compat Modes */
  378. src: local(""),
  379. url("/fonts/inter-v3-latin-regular.eot?#iefix")
  380. format("embedded-opentype"),
  381. /* IE6-IE8 */ url("/fonts/inter-v3-latin-regular.woff2") format("woff2"),
  382. /* Super Modern Browsers */ url("/fonts/inter-v3-latin-regular.woff")
  383. format("woff"),
  384. /* Modern Browsers */ url("/fonts/inter-v3-latin-regular.ttf")
  385. format("truetype"),
  386. /* Safari, Android, iOS */
  387. url("/fonts/inter-v3-latin-regular.svg#Inter") format("svg"); /* Legacy iOS */
  388. }
  389. /* inter-200 - latin */
  390. @font-face {
  391. font-family: "Inter";
  392. font-style: normal;
  393. font-weight: 200;
  394. src: url("/fonts/inter-v3-latin-200.eot"); /* IE9 Compat Modes */
  395. src: local(""),
  396. url("/fonts/inter-v3-latin-200.eot?#iefix") format("embedded-opentype"),
  397. /* IE6-IE8 */ url("/fonts/inter-v3-latin-200.woff2") format("woff2"),
  398. /* Super Modern Browsers */ url("/fonts/inter-v3-latin-200.woff")
  399. format("woff"),
  400. /* Modern Browsers */ url("/fonts/inter-v3-latin-200.ttf")
  401. format("truetype"),
  402. /* Safari, Android, iOS */ url("/fonts/inter-v3-latin-200.svg#Inter")
  403. format("svg"); /* Legacy iOS */
  404. }
  405. /* inter-800 - latin */
  406. @font-face {
  407. font-family: "Inter";
  408. font-style: normal;
  409. font-weight: 800;
  410. src: url("/fonts/inter-v3-latin-800.eot"); /* IE9 Compat Modes */
  411. src: local(""),
  412. url("/fonts/inter-v3-latin-800.eot?#iefix") format("embedded-opentype"),
  413. /* IE6-IE8 */ url("/fonts/inter-v3-latin-800.woff2") format("woff2"),
  414. /* Super Modern Browsers */ url("/fonts/inter-v3-latin-800.woff")
  415. format("woff"),
  416. /* Modern Browsers */ url("/fonts/inter-v3-latin-800.ttf")
  417. format("truetype"),
  418. /* Safari, Android, iOS */ url("/fonts/inter-v3-latin-800.svg#Inter")
  419. format("svg"); /* Legacy iOS */
  420. }
  421. /* inter-600 - latin */
  422. @font-face {
  423. font-family: "Inter";
  424. font-style: normal;
  425. font-weight: 600;
  426. src: url("/fonts/inter-v3-latin-600.eot"); /* IE9 Compat Modes */
  427. src: local(""),
  428. url("/fonts/inter-v3-latin-600.eot?#iefix") format("embedded-opentype"),
  429. /* IE6-IE8 */ url("/fonts/inter-v3-latin-600.woff2") format("woff2"),
  430. /* Super Modern Browsers */ url("/fonts/inter-v3-latin-600.woff")
  431. format("woff"),
  432. /* Modern Browsers */ url("/fonts/inter-v3-latin-600.ttf")
  433. format("truetype"),
  434. /* Safari, Android, iOS */ url("/fonts/inter-v3-latin-600.svg#Inter")
  435. format("svg"); /* Legacy iOS */
  436. }
  437. /* pacifico-regular - latin */
  438. @font-face {
  439. font-family: "Pacifico";
  440. font-style: normal;
  441. font-weight: 400;
  442. src: url("/fonts/pacifico-v17-latin-regular.eot"); /* IE9 Compat Modes */
  443. src: local(""),
  444. url("/fonts/pacifico-v17-latin-regular.eot?#iefix")
  445. format("embedded-opentype"),
  446. /* IE6-IE8 */ url("/fonts/pacifico-v17-latin-regular.woff2")
  447. format("woff2"),
  448. /* Super Modern Browsers */
  449. url("/fonts/pacifico-v17-latin-regular.woff") format("woff"),
  450. /* Modern Browsers */ url("/fonts/pacifico-v17-latin-regular.ttf")
  451. format("truetype"),
  452. /* Safari, Android, iOS */
  453. url("/fonts/pacifico-v17-latin-regular.svg#Pacifico") format("svg"); /* Legacy iOS */
  454. }
  455. @font-face {
  456. font-family: "Material Icons";
  457. font-style: normal;
  458. font-weight: 400;
  459. src: url(/fonts/MaterialIcons-Regular.ttf); /* For IE6-8 */
  460. src: local("Material Icons"), local("MaterialIcons-Regular"),
  461. url(/fonts/MaterialIcons-Regular.ttf) format("truetype");
  462. }
  463. .material-icons {
  464. font-family: "Material Icons";
  465. font-weight: normal;
  466. font-style: normal;
  467. font-size: 24px; /* Preferred icon size */
  468. display: inline-block;
  469. line-height: 1;
  470. text-transform: none;
  471. letter-spacing: normal;
  472. word-wrap: normal;
  473. white-space: nowrap;
  474. direction: ltr;
  475. /* Support for all WebKit browsers. */
  476. -webkit-font-smoothing: antialiased;
  477. /* Support for Safari and Chrome. */
  478. text-rendering: optimizeLegibility;
  479. /* Support for Firefox. */
  480. -moz-osx-font-smoothing: grayscale;
  481. /* Support for IE. */
  482. font-feature-settings: "liga";
  483. }
  484. code {
  485. background-color: var(--light-grey) !important;
  486. color: var(--dark-red) !important;
  487. }
  488. #toasts-container {
  489. z-index: 10000 !important;
  490. .toast {
  491. font-weight: 600;
  492. z-index: 10000 !important;
  493. }
  494. }
  495. html {
  496. overflow: auto !important;
  497. height: 100%;
  498. background-color: inherit;
  499. font-size: 14px;
  500. }
  501. body {
  502. background-color: var(--light-grey);
  503. color: var(--dark-grey);
  504. height: 100%;
  505. line-height: 1.4285714;
  506. font-size: 1rem;
  507. font-family: "Inter", Helvetica, Arial, sans-serif;
  508. }
  509. .app {
  510. min-height: 100vh;
  511. position: relative;
  512. }
  513. #root {
  514. height: 100%;
  515. }
  516. .content-wrapper {
  517. /* padding: 60px 0 calc(230px + 60px) 0; */
  518. padding-top: 60px;
  519. }
  520. .column {
  521. display: flex;
  522. flex: 1 1 0;
  523. flex-direction: column;
  524. padding: 10px;
  525. }
  526. ul {
  527. list-style: none;
  528. margin: 0;
  529. display: block;
  530. }
  531. h1,
  532. h2,
  533. h3,
  534. h4,
  535. h5,
  536. h6 {
  537. font-family: "Inter", Helvetica, Arial, sans-serif;
  538. font-weight: 400;
  539. line-height: 1.1;
  540. a {
  541. font-weight: inherit;
  542. }
  543. }
  544. h1 {
  545. font-size: 4.2rem;
  546. line-height: 110%;
  547. margin: 2.1rem 0 1.68rem 0;
  548. }
  549. h2 {
  550. font-size: 3.56rem;
  551. line-height: 110%;
  552. margin: 1.78rem 0 1.424rem 0;
  553. }
  554. h3 {
  555. font-size: 2.92rem;
  556. line-height: 110%;
  557. margin: 1.46rem 0 1.168rem 0;
  558. }
  559. h4 {
  560. font-size: 2.28rem;
  561. line-height: 110%;
  562. margin: 1.14rem 0 0.912rem 0;
  563. }
  564. h5 {
  565. font-size: 1.64rem;
  566. line-height: 110%;
  567. margin: 0.82rem 0 0.656rem 0;
  568. }
  569. h6 {
  570. font-size: 1rem;
  571. line-height: 110%;
  572. margin: 0.5rem 0 0.4rem 0;
  573. }
  574. .content {
  575. h4 {
  576. line-height: 1.125;
  577. }
  578. }
  579. .thin {
  580. font-weight: 200;
  581. }
  582. .left {
  583. float: left !important;
  584. }
  585. .right {
  586. float: right !important;
  587. }
  588. .white {
  589. background-color: var(--white) !important;
  590. }
  591. .btn-search {
  592. font-size: 14px;
  593. }
  594. a.nav-item.is-tab {
  595. border-bottom: 1px solid transparent;
  596. border-top: 1px solid transparent;
  597. }
  598. .button.is-info {
  599. border-width: 0;
  600. color: var(--white);
  601. }
  602. strong {
  603. color: inherit;
  604. }
  605. hr {
  606. background-color: var(--light-grey-2);
  607. border: none;
  608. height: 1px;
  609. }
  610. p,
  611. button,
  612. input,
  613. select,
  614. textarea {
  615. font-family: "Inter", Helvetica, Arial, sans-serif;
  616. }
  617. input,
  618. select,
  619. textarea {
  620. outline: none;
  621. }
  622. .label {
  623. display: flex;
  624. font-weight: 700;
  625. &:not(:last-child) {
  626. margin-bottom: 5px;
  627. }
  628. }
  629. #page-title {
  630. margin-top: 0;
  631. font-size: 35px;
  632. text-align: center;
  633. }
  634. @media only screen and (min-width: 700px) {
  635. #page-title {
  636. margin: 0;
  637. margin-bottom: 30px;
  638. font-size: 40px;
  639. }
  640. }
  641. @media screen and (min-width: 980px) {
  642. .container {
  643. max-width: 960px;
  644. margin-left: auto;
  645. margin-right: auto;
  646. }
  647. }
  648. @media screen and (min-width: 1180px) {
  649. .container {
  650. max-width: 1200px;
  651. }
  652. }
  653. .upper-container {
  654. height: 100%;
  655. }
  656. .main-container {
  657. height: 100%;
  658. min-height: 100vh;
  659. display: flex;
  660. flex-direction: column;
  661. &.main-container-modal-active {
  662. height: 100% !important;
  663. overflow: hidden !important;
  664. }
  665. > .container {
  666. position: relative;
  667. flex: 1 0 auto;
  668. margin: 0 auto;
  669. max-width: 1200px;
  670. }
  671. }
  672. a {
  673. color: var(--primary-color);
  674. text-decoration: none;
  675. cursor: pointer;
  676. &:hover,
  677. &:focus {
  678. filter: brightness(90%);
  679. }
  680. }
  681. table {
  682. border-collapse: collapse;
  683. width: 100%;
  684. thead {
  685. td {
  686. border-width: 0 0 2px;
  687. }
  688. }
  689. td {
  690. border: 1px solid var(--light-grey-2);
  691. border-width: 0 0 1px;
  692. padding: 8px 10px;
  693. }
  694. tbody {
  695. tr:last-child {
  696. td {
  697. border-bottom-width: 0;
  698. }
  699. }
  700. }
  701. }
  702. img {
  703. max-width: 100%;
  704. }
  705. .absolute-a {
  706. width: 100%;
  707. height: 100%;
  708. position: absolute;
  709. top: 0;
  710. left: 0;
  711. }
  712. .alert {
  713. padding: 20px;
  714. color: var(--white);
  715. background-color: var(--dark-red);
  716. position: fixed;
  717. top: 50px;
  718. right: 50px;
  719. font-size: 2em;
  720. border-radius: @border-radius;
  721. z-index: 10000000;
  722. }
  723. .night-mode {
  724. .tippy-box {
  725. border: 1px solid var(--light-grey-3);
  726. box-shadow: @box-shadow-dropdown;
  727. background-color: var(--white);
  728. .tippy-content {
  729. color: var(--black);
  730. }
  731. &[data-theme~="songActions"],
  732. &[data-theme~="dropdown"],
  733. &[data-theme~="search"],
  734. &[data-theme~="stationSettings"] {
  735. background-color: var(--dark-grey-2);
  736. border: 0 !important;
  737. }
  738. &[data-theme~="songActions"] {
  739. background-color: var(--dark-grey-2);
  740. border: 0 !important;
  741. i,
  742. a {
  743. color: var(--white);
  744. }
  745. .youtube-icon {
  746. background-color: var(--white);
  747. }
  748. }
  749. &[data-theme~="dropdown"] {
  750. background-color: var(--dark-grey-2);
  751. border: 0 !important;
  752. .nav-dropdown-items {
  753. .nav-item {
  754. background-color: var(--dark-grey);
  755. &:focus {
  756. outline-color: var(--dark-grey);
  757. }
  758. p {
  759. color: var(--white);
  760. }
  761. }
  762. }
  763. }
  764. &[data-theme~="search"] {
  765. background-color: var(--dark-grey-2);
  766. border: 0 !important;
  767. }
  768. &[data-theme~="info"] p {
  769. color: var(--black) !important;
  770. }
  771. }
  772. .tippy-box[data-placement^="top"] {
  773. &[data-theme~="songActions"],
  774. &[data-theme~="dropdown"],
  775. &[data-theme~="search"] {
  776. > .tippy-arrow::before {
  777. border-top-color: var(--dark-grey-2);
  778. }
  779. }
  780. }
  781. .tippy-box[data-placement^="bottom"] {
  782. &[data-theme~="songActions"],
  783. &[data-theme~="dropdown"],
  784. &[data-theme~="search"],
  785. &[data-theme~="stationSettings"] {
  786. > .tippy-arrow::before {
  787. border-bottom-color: var(--dark-grey-2);
  788. }
  789. }
  790. }
  791. .tippy-box[data-placement^="left"] {
  792. &[data-theme~="songActions"],
  793. &[data-theme~="dropdown"],
  794. &[data-theme~="search"] {
  795. > .tippy-arrow::before {
  796. border-left-color: var(--dark-grey-2);
  797. }
  798. }
  799. }
  800. .tippy-box[data-placement^="right"] {
  801. &[data-theme~="songActions"],
  802. &[data-theme~="dropdown"],
  803. &[data-theme~="search"] {
  804. > .tippy-arrow::before {
  805. border-right-color: var(--dark-grey-2);
  806. }
  807. }
  808. }
  809. }
  810. .tippy-box[data-theme~="info"] {
  811. font-size: 12px;
  812. letter-spacing: 1px;
  813. }
  814. .tippy-box[data-theme~="quickConfirm"] {
  815. background-color: var(--dark-red);
  816. border: 0;
  817. .tippy-content {
  818. padding: 0;
  819. }
  820. a {
  821. padding: 15px;
  822. line-height: 30px;
  823. color: var(--white);
  824. border-bottom: 0;
  825. font-size: 15px;
  826. font-weight: 600;
  827. &:hover,
  828. &:focus {
  829. filter: brightness(90%);
  830. }
  831. }
  832. }
  833. .tippy-box[data-theme~="songActions"] {
  834. font-size: 15px;
  835. padding: 5px 10px;
  836. border: 1px solid var(--light-grey-3);
  837. box-shadow: @box-shadow-dropdown;
  838. background-color: var(--white);
  839. .button {
  840. width: 146px;
  841. }
  842. i,
  843. a {
  844. display: inline-block;
  845. cursor: pointer;
  846. color: var(--dark-grey);
  847. vertical-align: middle;
  848. &:hover,
  849. &:focus {
  850. filter: brightness(90%);
  851. }
  852. &:not(:first) {
  853. margin-left: 5px;
  854. }
  855. }
  856. .play-icon,
  857. .added-to-playlist-icon {
  858. color: var(--green);
  859. }
  860. .edit-icon,
  861. .view-icon,
  862. .add-to-playlist-icon,
  863. .add-to-queue-icon {
  864. color: var(--primary-color);
  865. }
  866. .hide-icon {
  867. color: var(--light-grey-3);
  868. }
  869. .stop-icon,
  870. .delete-icon {
  871. color: var(--dark-red);
  872. }
  873. .report-icon {
  874. color: var(--yellow);
  875. }
  876. }
  877. .tippy-box[data-placement^="top"] {
  878. &[data-theme~="songActions"],
  879. &[data-theme~="dropdown"],
  880. &[data-theme~="search"] {
  881. > .tippy-arrow::before {
  882. border-top-color: var(--white);
  883. }
  884. }
  885. &[data-theme~="quickConfirm"] > .tippy-arrow::before {
  886. border-top-color: var(--dark-red);
  887. }
  888. }
  889. .tippy-box[data-placement^="bottom"] {
  890. &[data-theme~="songActions"],
  891. &[data-theme~="dropdown"],
  892. &[data-theme~="stationSettings"],
  893. &[data-theme~="search"] {
  894. > .tippy-arrow::before {
  895. border-bottom-color: var(--white);
  896. }
  897. }
  898. &[data-theme~="quickConfirm"] > .tippy-arrow::before {
  899. border-bottom-color: var(--dark-red);
  900. }
  901. }
  902. .tippy-box[data-placement^="left"] {
  903. &[data-theme~="songActions"],
  904. &[data-theme~="dropdown"],
  905. &[data-theme~="search"] {
  906. > .tippy-arrow::before {
  907. border-left-color: var(--white);
  908. }
  909. }
  910. &[data-theme~="quickConfirm"] > .tippy-arrow::before {
  911. border-left-color: var(--dark-red);
  912. }
  913. }
  914. .tippy-box[data-placement^="right"] {
  915. &[data-theme~="songActions"],
  916. &[data-theme~="dropdown"],
  917. &[data-theme~="search"] {
  918. > .tippy-arrow::before {
  919. border-right-color: var(--white);
  920. }
  921. }
  922. &[data-theme~="quickConfirm"] > .tippy-arrow::before {
  923. border-right-color: var(--dark-red);
  924. }
  925. }
  926. .tippy-box[data-theme~="stationSettings"] {
  927. border: 1px solid var(--light-grey-3);
  928. box-shadow: @box-shadow-dropdown;
  929. background-color: var(--white);
  930. button:not(:last-of-type) {
  931. margin-bottom: 5px;
  932. }
  933. }
  934. .tippy-box[data-theme~="dropdown"] {
  935. font-size: 15px;
  936. padding: 0;
  937. border: 1px solid var(--light-grey-3);
  938. box-shadow: @box-shadow-dropdown;
  939. background-color: var(--white);
  940. color: var(--dark-grey);
  941. width: 350px;
  942. .tippy-content {
  943. padding: 0;
  944. }
  945. .nav-dropdown-items {
  946. max-height: 220px;
  947. overflow-y: auto;
  948. padding: 10px;
  949. .nav-item {
  950. width: 100%;
  951. justify-content: flex-start;
  952. border: 0;
  953. padding: 8px 4px;
  954. font-size: 15.5px;
  955. min-height: 36px;
  956. background: var(--light-grey);
  957. border-radius: @border-radius;
  958. cursor: pointer;
  959. .checkbox-control {
  960. display: flex;
  961. flex-direction: row;
  962. align-items: center;
  963. overflow-wrap: anywhere;
  964. margin: 0 !important;
  965. p {
  966. margin-left: 10px;
  967. }
  968. .switch {
  969. position: relative;
  970. display: inline-block;
  971. flex-shrink: 0;
  972. width: 40px;
  973. height: 24px;
  974. }
  975. .switch input {
  976. opacity: 0;
  977. width: 0;
  978. height: 0;
  979. }
  980. .slider {
  981. width: 100%;
  982. position: absolute;
  983. cursor: pointer;
  984. top: 0;
  985. left: 0;
  986. right: 0;
  987. bottom: 0;
  988. background-color: var(--light-grey-3);
  989. transition: 0.2s;
  990. border-radius: 34px;
  991. }
  992. .slider:before {
  993. position: absolute;
  994. content: "";
  995. height: 16px;
  996. width: 16px;
  997. left: 4px;
  998. bottom: 4px;
  999. background-color: var(--white);
  1000. transition: 0.2s;
  1001. border-radius: 50%;
  1002. }
  1003. input:checked + .slider {
  1004. background-color: var(--primary-color);
  1005. }
  1006. input:focus + .slider {
  1007. box-shadow: 0 0 1px var(--primary-color);
  1008. }
  1009. input:checked + .slider:before {
  1010. transform: translateX(16px);
  1011. }
  1012. }
  1013. &:focus {
  1014. outline-color: var(--light-grey-3);
  1015. }
  1016. &:not(:last-of-type) {
  1017. margin-bottom: 5px;
  1018. }
  1019. }
  1020. }
  1021. .tippy-content > span {
  1022. display: flex;
  1023. flex-direction: column;
  1024. button.nav-item {
  1025. &:not(:last-of-type) {
  1026. margin-bottom: 10px;
  1027. }
  1028. }
  1029. }
  1030. #create-playlist {
  1031. margin: 10px 10px 10px 10px;
  1032. width: calc(100% - 20px);
  1033. }
  1034. }
  1035. .tippy-box[data-theme~="search"] {
  1036. font-size: 15px;
  1037. padding: 0;
  1038. border: 1px solid var(--light-grey-3);
  1039. box-shadow: @box-shadow-dropdown;
  1040. background-color: var(--white);
  1041. color: var(--dark-grey);
  1042. width: 100% !important;
  1043. max-width: 600px !important;
  1044. max-height: calc(100vh - 300px);
  1045. overflow-y: auto;
  1046. .tippy-content {
  1047. padding: 0;
  1048. & > span {
  1049. display: flex;
  1050. flex-direction: column;
  1051. padding: 5px;
  1052. }
  1053. }
  1054. }
  1055. .has-text-centered {
  1056. text-align: center;
  1057. }
  1058. .select {
  1059. position: relative;
  1060. &.is-expanded {
  1061. width: 100%;
  1062. }
  1063. &.disabled,
  1064. .disabled {
  1065. filter: grayscale(1);
  1066. cursor: not-allowed;
  1067. }
  1068. &:after {
  1069. content: " ";
  1070. border: 1.5px solid var(--primary-color);
  1071. border-right: 0;
  1072. border-top: 0;
  1073. height: 7px;
  1074. pointer-events: none;
  1075. position: absolute;
  1076. transform: rotate(-45deg);
  1077. width: 7px;
  1078. margin-top: -6px;
  1079. right: 16px;
  1080. top: 50%;
  1081. }
  1082. select {
  1083. height: 36px;
  1084. width: 100%;
  1085. background-color: var(--white);
  1086. border: 1px solid var(--light-grey-2);
  1087. color: var(--dark-grey-2);
  1088. appearance: none;
  1089. border-radius: @border-radius;
  1090. font-size: 14px;
  1091. line-height: 24px;
  1092. padding-left: 8px;
  1093. position: relative;
  1094. padding-right: 36px;
  1095. cursor: pointer;
  1096. }
  1097. }
  1098. .checkbox {
  1099. height: 25px;
  1100. width: 25px;
  1101. input[type="checkbox"] {
  1102. height: 25px;
  1103. width: 25px;
  1104. background-color: var(--white);
  1105. border: 1px solid var(--light-grey-2);
  1106. appearance: none;
  1107. border-radius: @border-radius;
  1108. cursor: pointer;
  1109. position: relative;
  1110. &:checked {
  1111. &:before {
  1112. content: "";
  1113. position: absolute;
  1114. top: 4px;
  1115. right: 7px;
  1116. background-color: var(--primary-color);
  1117. width: 4px;
  1118. height: 16px;
  1119. transform: rotate(45deg);
  1120. }
  1121. &:after {
  1122. content: "";
  1123. position: absolute;
  1124. top: 12px;
  1125. left: 2px;
  1126. background-color: var(--primary-color);
  1127. width: 10px;
  1128. height: 4px;
  1129. transform: rotate(45deg);
  1130. }
  1131. }
  1132. }
  1133. }
  1134. .button:focus,
  1135. .button:active {
  1136. border-color: var(--light-grey-2) !important;
  1137. }
  1138. .input:focus,
  1139. .input:active,
  1140. .textarea:focus,
  1141. .textarea:active,
  1142. .select select:focus,
  1143. .select select:active {
  1144. border-color: var(--primary-color) !important;
  1145. }
  1146. button.delete:focus {
  1147. background-color: rgba(10, 10, 10, 0.3);
  1148. }
  1149. .tag {
  1150. padding-right: 6px !important;
  1151. }
  1152. #tab-selection,
  1153. .tab-selection {
  1154. overflow-x: auto;
  1155. .button {
  1156. white-space: nowrap;
  1157. }
  1158. }
  1159. .table {
  1160. background-color: var(--white);
  1161. color: var(--dark-grey);
  1162. width: 100%;
  1163. border-collapse: collapse;
  1164. border-spacing: 0;
  1165. border-radius: @border-radius;
  1166. thead th {
  1167. padding: 5px 10px;
  1168. text-align: left;
  1169. font-weight: 600;
  1170. color: var(--grey-3);
  1171. }
  1172. tr {
  1173. &:nth-child(even) {
  1174. background-color: #fafafa;
  1175. }
  1176. &:hover,
  1177. &:focus {
  1178. background-color: var(--light-grey);
  1179. }
  1180. }
  1181. }
  1182. .button {
  1183. border: 1px solid var(--light-grey-2);
  1184. background-color: var(--white);
  1185. color: var(--dark-grey-2);
  1186. border-radius: @border-radius;
  1187. line-height: 24px;
  1188. align-items: center;
  1189. display: inline-flex;
  1190. font-size: 14px;
  1191. padding-left: 10px;
  1192. padding-right: 10px;
  1193. justify-content: center;
  1194. cursor: pointer;
  1195. user-select: none;
  1196. white-space: nowrap;
  1197. &:hover,
  1198. &:focus {
  1199. filter: brightness(95%);
  1200. }
  1201. &.is-success {
  1202. background-color: var(--green) !important;
  1203. border-width: 0;
  1204. color: var(--white);
  1205. }
  1206. &.is-primary {
  1207. background-color: var(--primary-color) !important;
  1208. border-width: 0;
  1209. color: var(--white);
  1210. }
  1211. &.is-danger {
  1212. background-color: var(--dark-red) !important;
  1213. border-width: 0;
  1214. color: var(--white);
  1215. }
  1216. &.is-info {
  1217. background-color: var(--primary-color) !important;
  1218. border-width: 0;
  1219. color: var(--white);
  1220. }
  1221. &.is-warning {
  1222. background-color: var(--yellow) !important;
  1223. border-width: 0;
  1224. color: rgba(0, 0, 0, 0.7);
  1225. }
  1226. &.is-dark {
  1227. background-color: var(--dark-grey-2);
  1228. border-width: 0;
  1229. color: var(--light-grey);
  1230. }
  1231. &.is-fullwidth {
  1232. display: flex;
  1233. width: 100%;
  1234. }
  1235. &.disabled {
  1236. filter: grayscale(1);
  1237. cursor: not-allowed;
  1238. }
  1239. }
  1240. .input,
  1241. .textarea {
  1242. width: 100%;
  1243. padding-left: 8px;
  1244. padding-right: 8px;
  1245. line-height: 24px;
  1246. font-size: 14px;
  1247. border-radius: @border-radius;
  1248. box-shadow: inset 0 1px 2px rgba(10, 10, 10, 0.1);
  1249. border: 1px solid var(--light-grey-2);
  1250. }
  1251. .input,
  1252. .button {
  1253. height: 36px;
  1254. }
  1255. .textarea {
  1256. display: block;
  1257. line-height: 1.2;
  1258. padding: 10px;
  1259. max-height: 600px;
  1260. min-height: 120px;
  1261. min-width: 100%;
  1262. resize: vertical;
  1263. }
  1264. .icon {
  1265. height: 24px;
  1266. width: 24px;
  1267. line-height: 24px;
  1268. margin-left: 4px;
  1269. margin-right: -2px;
  1270. }
  1271. .fadein-helpbox-enter-active {
  1272. transition-duration: 0.3s;
  1273. transition-timing-function: ease-in;
  1274. }
  1275. .fadein-helpbox-leave-active {
  1276. transition-duration: 0.3s;
  1277. transition-timing-function: cubic-bezier(0, 1, 0.5, 1);
  1278. }
  1279. .fadein-helpbox-enter-to,
  1280. .fadein-helpbox-leave {
  1281. max-height: 100px;
  1282. overflow: hidden;
  1283. }
  1284. .fadein-helpbox-enter,
  1285. .fadein-helpbox-leave-to {
  1286. overflow: hidden;
  1287. max-height: 0;
  1288. }
  1289. .control {
  1290. margin-bottom: 5px !important;
  1291. &.is-grouped {
  1292. display: flex;
  1293. & > .control {
  1294. &.select.is-expanded > select {
  1295. width: 100%;
  1296. }
  1297. & > input,
  1298. & > select,
  1299. & > .button,
  1300. &.label {
  1301. border-radius: 0;
  1302. }
  1303. &:first-child {
  1304. & > input,
  1305. & > select,
  1306. & > .button,
  1307. &.label {
  1308. border-radius: @border-radius 0 0 @border-radius;
  1309. }
  1310. }
  1311. &:last-child {
  1312. & > input,
  1313. & > select,
  1314. & > .button,
  1315. &.label {
  1316. border-radius: 0 @border-radius @border-radius 0;
  1317. }
  1318. }
  1319. }
  1320. }
  1321. &.is-expanded {
  1322. flex: 1;
  1323. }
  1324. &.has-addons {
  1325. display: flex;
  1326. .button {
  1327. border-radius: 0;
  1328. margin-right: -1px;
  1329. &:first-child {
  1330. border-radius: @border-radius 0 0 @border-radius;
  1331. }
  1332. &:last-child {
  1333. border-radius: 0 @border-radius @border-radius 0;
  1334. padding-left: 10px;
  1335. }
  1336. &.dropdown-toggle {
  1337. padding-left: 5px;
  1338. padding-right: 5px;
  1339. }
  1340. }
  1341. .input {
  1342. margin-right: -1px;
  1343. &:first-child {
  1344. border-radius: @border-radius 0 0 @border-radius;
  1345. }
  1346. }
  1347. }
  1348. }
  1349. .input-with-button {
  1350. .control {
  1351. margin-right: 0px !important;
  1352. }
  1353. input,
  1354. select {
  1355. width: 100%;
  1356. height: 36px;
  1357. border-radius: @border-radius 0 0 @border-radius;
  1358. border-right: 0;
  1359. border-color: var(--light-grey-3);
  1360. }
  1361. .button {
  1362. height: 36px;
  1363. border-radius: 0 @border-radius @border-radius 0;
  1364. }
  1365. }
  1366. .page-title {
  1367. margin: 0 0 50px 0;
  1368. }
  1369. .material-icons {
  1370. user-select: none;
  1371. -webkit-user-select: none;
  1372. }
  1373. .icon-with-button {
  1374. margin-right: 3px;
  1375. font-size: 18px;
  1376. }
  1377. .verified-song {
  1378. font-size: 17px;
  1379. color: var(--primary-color);
  1380. }
  1381. .section-title,
  1382. h4.section-title {
  1383. font-size: 26px;
  1384. font-weight: 600;
  1385. margin: 0px;
  1386. }
  1387. .section-description {
  1388. font-size: 16px;
  1389. font-weight: 400;
  1390. margin-bottom: 10px !important;
  1391. }
  1392. .section-horizontal-rule {
  1393. margin: 15px 0 30px 0;
  1394. }
  1395. .section-margin-bottom {
  1396. height: 30px;
  1397. }
  1398. .margin-top-zero {
  1399. margin-top: 0 !important;
  1400. }
  1401. .margin-bottom-zero {
  1402. margin-bottom: 0 !important;
  1403. }
  1404. /** Universial items e.g. playlist items, queue items, activity items */
  1405. .item-draggable {
  1406. cursor: move;
  1407. }
  1408. .universal-item {
  1409. display: flex;
  1410. flex-direction: row;
  1411. flex-grow: 1;
  1412. align-items: center;
  1413. justify-content: space-between;
  1414. padding: 7.5px;
  1415. border: 1px solid var(--light-grey-3);
  1416. border-radius: @border-radius;
  1417. overflow: hidden;
  1418. .item-thumbnail {
  1419. width: 65px;
  1420. height: 65px;
  1421. margin: -7.5px;
  1422. border-radius: @border-radius 0 0 @border-radius;
  1423. }
  1424. .item-title {
  1425. font-size: 20px;
  1426. overflow: hidden;
  1427. text-overflow: ellipsis;
  1428. white-space: nowrap;
  1429. }
  1430. .item-description {
  1431. font-size: 14px;
  1432. overflow: hidden;
  1433. text-overflow: ellipsis;
  1434. white-space: nowrap;
  1435. }
  1436. .universal-item-actions {
  1437. display: flex;
  1438. flex-direction: row;
  1439. margin-left: 10px;
  1440. justify-content: center;
  1441. @media screen and (max-width: 800px) {
  1442. flex-wrap: wrap;
  1443. }
  1444. .action-dropdown-icon {
  1445. display: flex;
  1446. color: var(--primary-color);
  1447. }
  1448. .icons-group {
  1449. display: flex;
  1450. align-items: center;
  1451. a {
  1452. padding: 0;
  1453. }
  1454. }
  1455. .button {
  1456. width: 146px;
  1457. }
  1458. i,
  1459. span {
  1460. cursor: pointer;
  1461. &:not(:first-child) {
  1462. margin-left: 5px;
  1463. }
  1464. }
  1465. .play-icon,
  1466. .added-to-playlist-icon {
  1467. color: var(--green);
  1468. }
  1469. .edit-icon,
  1470. .view-icon,
  1471. .add-to-playlist-icon,
  1472. .add-to-queue-icon {
  1473. color: var(--primary-color);
  1474. }
  1475. .hide-icon {
  1476. color: var(--light-grey-3);
  1477. }
  1478. .stop-icon,
  1479. .delete-icon {
  1480. color: var(--dark-red);
  1481. }
  1482. .report-icon {
  1483. color: var(--yellow);
  1484. }
  1485. }
  1486. }
  1487. .save-button-mixin {
  1488. min-width: 200px;
  1489. &:disabled {
  1490. background-color: var(--light-grey) !important;
  1491. color: var(--black);
  1492. }
  1493. }
  1494. .save-button-transition-enter-active {
  1495. transition: all 0.1s ease;
  1496. }
  1497. .save-button-transition-enter {
  1498. transform: translateX(20px);
  1499. opacity: 0;
  1500. }
  1501. .youtube-icon {
  1502. margin-right: 3px;
  1503. height: 20px;
  1504. width: 20px;
  1505. -webkit-mask: url("/assets/social/youtube.svg") no-repeat center;
  1506. mask: url("/assets/social/youtube.svg") no-repeat center;
  1507. background-color: var(--youtube);
  1508. }
  1509. #forgot-password {
  1510. justify-content: flex-start;
  1511. margin: 5px 0;
  1512. }
  1513. .steps-fade-leave-active {
  1514. display: none;
  1515. }
  1516. .steps-fade-enter-active,
  1517. .steps-fade-leave-active {
  1518. transition: all 0.3s ease;
  1519. }
  1520. .steps-fade-enter-from,
  1521. .steps-fade-leave-to {
  1522. opacity: 0;
  1523. }
  1524. .skip-step {
  1525. background-color: var(--grey-3);
  1526. color: var(--white);
  1527. }
  1528. #steps {
  1529. display: flex;
  1530. align-items: center;
  1531. justify-content: center;
  1532. height: 50px;
  1533. margin-top: 36px;
  1534. @media screen and (max-width: 300px) {
  1535. display: none;
  1536. }
  1537. .step {
  1538. display: flex;
  1539. align-items: center;
  1540. justify-content: center;
  1541. border-radius: 100%;
  1542. border: 1px solid var(--dark-grey);
  1543. min-width: 50px;
  1544. min-height: 50px;
  1545. background-color: var(--white);
  1546. font-size: 30px;
  1547. user-select: none;
  1548. &.selected {
  1549. background-color: var(--primary-color);
  1550. color: var(--white) !important;
  1551. border: 0;
  1552. }
  1553. }
  1554. .divider {
  1555. display: flex;
  1556. justify-content: center;
  1557. width: 180px;
  1558. height: 1px;
  1559. background-color: var(--dark-grey);
  1560. }
  1561. }
  1562. /* This class is used for content-box in ResetPassword, but not in RemoveAccount. This is because ResetPassword uses transitions and RemoveAccount does not */
  1563. .content-box-wrapper {
  1564. margin-top: 90px;
  1565. width: 100%;
  1566. display: flex;
  1567. align-items: center;
  1568. }
  1569. .content-box {
  1570. border-radius: @border-radius;
  1571. background-color: var(--white);
  1572. border: 1px solid var(--dark-grey);
  1573. max-width: 580px;
  1574. padding: 40px;
  1575. flex: 1;
  1576. @media screen and (max-width: 300px) {
  1577. margin-top: 30px;
  1578. padding: 30px 20px;
  1579. }
  1580. }
  1581. .content-box-optional-helper {
  1582. margin-top: 15px;
  1583. color: var(--primary-color);
  1584. font-size: 16px;
  1585. a {
  1586. color: var(--primary-color);
  1587. }
  1588. }
  1589. .content-box-title {
  1590. font-size: 25px;
  1591. color: var(--black);
  1592. }
  1593. .content-box-description {
  1594. font-size: 14px;
  1595. color: var(--dark-grey);
  1596. }
  1597. .content-box-inputs {
  1598. margin-top: 35px;
  1599. .input-with-button {
  1600. .button {
  1601. width: 105px;
  1602. }
  1603. @media screen and (max-width: 450px) {
  1604. flex-direction: column;
  1605. }
  1606. }
  1607. label {
  1608. font-size: 11px;
  1609. }
  1610. #change-password-button {
  1611. margin-top: 36px;
  1612. width: 175px;
  1613. }
  1614. }
  1615. #password-visibility-container {
  1616. display: flex;
  1617. align-items: center;
  1618. a {
  1619. width: 0;
  1620. margin-left: -30px;
  1621. z-index: 0;
  1622. top: 2px;
  1623. position: relative;
  1624. color: var(--light-grey-1);
  1625. }
  1626. }
  1627. .news-item {
  1628. font-family: "Karla";
  1629. border-radius: @border-radius;
  1630. padding: 20px;
  1631. border: unset !important;
  1632. box-shadow: @box-shadow;
  1633. * {
  1634. font-family: Karla, Arial, sans-serif;
  1635. font-size: 16px;
  1636. }
  1637. h1 {
  1638. font-size: 40px;
  1639. &:first-of-type {
  1640. margin-top: 0;
  1641. }
  1642. }
  1643. h2 {
  1644. font-size: 30px;
  1645. }
  1646. h3 {
  1647. font-size: 25px;
  1648. }
  1649. h4,
  1650. h5,
  1651. h6 {
  1652. font-size: 20px;
  1653. }
  1654. h1,
  1655. h2,
  1656. h3,
  1657. h4,
  1658. h5,
  1659. h6 {
  1660. margin: 10px 0;
  1661. }
  1662. ul {
  1663. list-style: unset;
  1664. }
  1665. li {
  1666. margin-left: 30px;
  1667. }
  1668. blockquote {
  1669. padding: 0px 15px;
  1670. color: var(--grey-2);
  1671. border-left: 0.25em solid var(--light-grey-2);
  1672. }
  1673. code {
  1674. font-style: italic;
  1675. }
  1676. hr {
  1677. margin: 10px 0;
  1678. }
  1679. }
  1680. .checkbox-control {
  1681. display: flex;
  1682. flex-direction: row;
  1683. align-items: center;
  1684. p {
  1685. margin-left: 10px;
  1686. }
  1687. .switch {
  1688. position: relative;
  1689. display: inline-block;
  1690. flex-shrink: 0;
  1691. width: 40px;
  1692. height: 24px;
  1693. }
  1694. .switch input {
  1695. opacity: 0;
  1696. width: 0;
  1697. height: 0;
  1698. }
  1699. .slider {
  1700. position: absolute;
  1701. cursor: pointer;
  1702. top: 0;
  1703. left: 0;
  1704. right: 0;
  1705. bottom: 0;
  1706. background-color: var(--light-grey-3);
  1707. transition: 0.2s;
  1708. border-radius: 34px;
  1709. &.disabled {
  1710. cursor: not-allowed;
  1711. }
  1712. }
  1713. .slider:before {
  1714. position: absolute;
  1715. content: "";
  1716. height: 16px;
  1717. width: 16px;
  1718. left: 4px;
  1719. bottom: 4px;
  1720. background-color: var(--white);
  1721. transition: 0.2s;
  1722. border-radius: 50%;
  1723. }
  1724. input:checked + .slider {
  1725. background-color: var(--primary-color);
  1726. }
  1727. input:focus + .slider {
  1728. box-shadow: 0 0 1px var(--primary-color);
  1729. }
  1730. input:checked + .slider:before {
  1731. transform: translateX(16px);
  1732. }
  1733. }
  1734. html {
  1735. &,
  1736. * {
  1737. scrollbar-color: var(--primary-color) transparent;
  1738. scrollbar-width: thin;
  1739. }
  1740. &.night-mode {
  1741. &,
  1742. * {
  1743. scrollbar-color: var(--light-grey) transparent !important;
  1744. }
  1745. &::-webkit-scrollbar-thumb,
  1746. ::-webkit-scrollbar-thumb {
  1747. background-color: var(--light-grey);
  1748. }
  1749. ::-webkit-scrollbar-track {
  1750. background-color: var(--dark-grey-3);
  1751. }
  1752. }
  1753. div {
  1754. ::-webkit-scrollbar-track {
  1755. background-color: transparent !important;
  1756. }
  1757. }
  1758. }
  1759. ::-webkit-scrollbar {
  1760. height: 10px;
  1761. width: 10px;
  1762. }
  1763. ::-webkit-scrollbar-track {
  1764. background-color: var(--light-grey-2);
  1765. }
  1766. ::-webkit-scrollbar-thumb {
  1767. background-color: var(--primary-color);
  1768. }
  1769. ::-webkit-scrollbar-corner {
  1770. background-color: transparent;
  1771. }
  1772. :disabled,
  1773. .disabled {
  1774. cursor: not-allowed;
  1775. }
  1776. .pill {
  1777. background-color: var(--light-grey);
  1778. color: var(--primary-color);
  1779. padding: 5px 10px;
  1780. border-radius: @border-radius;
  1781. font-size: 14px;
  1782. font-weight: 600;
  1783. white-space: nowrap;
  1784. margin-top: 5px;
  1785. box-shadow: @box-shadow;
  1786. transition: all 0.2s ease-in-out;
  1787. &:hover,
  1788. &:focus {
  1789. filter: brightness(95%);
  1790. }
  1791. &:not(:last-of-type) {
  1792. margin-right: 5px;
  1793. }
  1794. }
  1795. </style>