App.vue 37 KB

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